@freelog/tools-lib 0.1.165 → 0.1.166

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,34 +1,4 @@
1
- import { CommonReturn } from "./tools";
2
- interface IResourceInfo {
3
- baseUpcastResources: {
4
- resourceId: string;
5
- resourceName: string;
6
- }[];
7
- coverImages: string[];
8
- createDate: string;
9
- intro: string;
10
- latestVersion: string;
11
- policies: {
12
- policyId: string;
13
- policyName: string;
14
- status: 0 | 1;
15
- }[];
16
- resourceId: string;
17
- resourceName: string;
18
- resourceTitle: string;
19
- resourceType: string[];
20
- resourceVersions: {
21
- createDate: string;
22
- version: string;
23
- versionId: string;
24
- }[];
25
- status: 0 | 1 | 2 | 4;
26
- tags: string[];
27
- updateDate: string;
28
- userId: number;
29
- username: string;
30
- operationType: number;
31
- }
1
+ import { CommonReturn } from './tools';
32
2
  export interface CreateParamsType {
33
3
  name: string;
34
4
  subjectType?: 1 | 4;
@@ -151,10 +121,7 @@ interface InfoParamsType {
151
121
  projection?: string;
152
122
  isLoadFreezeReason?: 0 | 1;
153
123
  }
154
- interface InfoReturnType extends CommonReturn {
155
- data: IResourceInfo;
156
- }
157
- export declare function info({ resourceIdOrName, ...params }: InfoParamsType): Promise<InfoReturnType>;
124
+ export declare function info({ resourceIdOrName, ...params }: InfoParamsType): Promise<any>;
158
125
  interface BatchInfoParamsType {
159
126
  resourceIds?: string;
160
127
  resourceNames?: string;
@@ -164,10 +131,7 @@ interface BatchInfoParamsType {
164
131
  projection?: string;
165
132
  isLoadFreezeReason?: 0 | 1;
166
133
  }
167
- interface BatchInfoReturnType extends CommonReturn {
168
- data: IResourceInfo[];
169
- }
170
- export declare function batchInfo(params: BatchInfoParamsType): Promise<BatchInfoReturnType>;
134
+ export declare function batchInfo(params: BatchInfoParamsType): Promise<any>;
171
135
  interface DependencyTreeParamsType {
172
136
  resourceId: string;
173
137
  version?: string;
@@ -187,10 +151,6 @@ interface CreateVersionParamsType {
187
151
  fileSha1: string;
188
152
  filename: string;
189
153
  description?: string;
190
- dependencies?: {
191
- resourceId: string;
192
- versionRange: string;
193
- }[];
194
154
  customPropertyDescriptors?: {
195
155
  key: string;
196
156
  name: string;
@@ -199,18 +159,25 @@ interface CreateVersionParamsType {
199
159
  candidateItems?: string[];
200
160
  remark?: string;
201
161
  }[];
162
+ inputAttrs?: {
163
+ key: string;
164
+ value: string;
165
+ }[];
166
+ dependencies?: {
167
+ resourceId: string;
168
+ versionRange: string;
169
+ }[];
202
170
  baseUpcastResources?: {
203
171
  resourceId: string;
204
172
  }[];
205
- resolveResources: {
173
+ batchSignContracts?: {
206
174
  resourceId: string;
207
- contracts: {
208
- policyId: string;
209
- }[];
175
+ policyIds: string[];
210
176
  }[];
211
- inputAttrs?: {
212
- key: string;
213
- value: string;
177
+ authExcludedItems: {
178
+ resourceId: string;
179
+ excludedType: 'contract' | 'policy';
180
+ excludedValue: string;
214
181
  }[];
215
182
  }
216
183
  export declare function createVersion({ resourceId, ...params }: CreateVersionParamsType): Promise<any>;
@@ -225,6 +192,13 @@ interface ResourceVersionInfo2ParamsType {
225
192
  }
226
193
  export declare function resourceVersionInfo1({ resourceId, version, ...params }: ResourceVersionInfo1ParamsType): Promise<any>;
227
194
  export declare function resourceVersionInfo2(params: ResourceVersionInfo2ParamsType): Promise<any>;
195
+ interface getVersionListByResourceIDParamsType {
196
+ resourceId: string;
197
+ version?: string;
198
+ projection?: string;
199
+ sort?: string;
200
+ }
201
+ export declare function getVersionListByResourceID({ resourceId, ...params }: getVersionListByResourceIDParamsType): Promise<any>;
228
202
  interface GetVersionListParamsType {
229
203
  versionIds: string;
230
204
  projection?: string;
@@ -276,7 +250,7 @@ export declare function lookDraft(params: LookDraftParamsType): Promise<any>;
276
250
  interface DeleteResourceDraftParamsType {
277
251
  resourceId: string;
278
252
  }
279
- export declare function deleteResourceDraft({ resourceId }: DeleteResourceDraftParamsType): Promise<any>;
253
+ export declare function deleteResourceDraft({ resourceId, }: DeleteResourceDraftParamsType): Promise<any>;
280
254
  interface ResourceIsUsedByOtherParamsType {
281
255
  fileSha1: string;
282
256
  }
@@ -394,7 +368,7 @@ export declare function getAttrsInfoByKey({ ...params }: GetAttrsInfoByKeyParams
394
368
  interface GenerateResourceNamesParamsType {
395
369
  resourceNames: string[];
396
370
  }
397
- export declare function generateResourceNames({ resourceNames }: GenerateResourceNamesParamsType): Promise<any>;
371
+ export declare function generateResourceNames({ resourceNames, }: GenerateResourceNamesParamsType): Promise<any>;
398
372
  interface UpdateCollectionParamsType {
399
373
  resourceId: string;
400
374
  description?: string;
@@ -422,13 +396,17 @@ interface UpdateCollectionParamsType {
422
396
  collection_view?: 'collection_view_list' | 'collection_view_card';
423
397
  };
424
398
  isMergeCatalogueDraft?: 0 | 1;
399
+ inputAttrs?: {
400
+ key: string;
401
+ value: string;
402
+ }[];
425
403
  }
426
404
  export declare function updateCollection({ resourceId, ...params }: UpdateCollectionParamsType): Promise<any>;
427
405
  interface deleteCollectionUnitResourcesParamsType {
428
406
  resourceId: string;
429
407
  removeCollectionItemIds: string[];
430
408
  }
431
- export declare function deleteCollectionUnitResource({ resourceId, removeCollectionItemIds }: deleteCollectionUnitResourcesParamsType): Promise<any>;
409
+ export declare function deleteCollectionUnitResource({ resourceId, removeCollectionItemIds, }: deleteCollectionUnitResourcesParamsType): Promise<any>;
432
410
  interface GetCollectionItemsParamsType {
433
411
  resourceId: string;
434
412
  skip?: number;
@@ -497,7 +475,7 @@ export declare function getCollectionUpdateLogs({ resourceId, ...params }: GetCo
497
475
  interface GetCollectionCollectRulesParamsType {
498
476
  resourceId: string;
499
477
  }
500
- export declare function getCollectionCollectRules({ resourceId }: GetCollectionCollectRulesParamsType): Promise<any>;
478
+ export declare function getCollectionCollectRules({ resourceId, }: GetCollectionCollectRulesParamsType): Promise<any>;
501
479
  interface SetCollectRulesParamsType {
502
480
  resourceId: string;
503
481
  serializeStatus?: 0 | 1;
@@ -522,15 +500,15 @@ interface deleteCollectionItems_Draft_ParamsType {
522
500
  resourceId: string;
523
501
  removeCollectionItemIds: string[];
524
502
  }
525
- export declare function deleteCollectionItems_Draft({ resourceId, removeCollectionItemIds }: deleteCollectionItems_Draft_ParamsType): Promise<any>;
503
+ export declare function deleteCollectionItems_Draft({ resourceId, removeCollectionItemIds, }: deleteCollectionItems_Draft_ParamsType): Promise<any>;
526
504
  interface SetCollectionItemsSortID_Draft_ParamsType {
527
505
  resourceId: string;
528
506
  data: {
529
- itemId: string;
507
+ itemIds: string[];
530
508
  targetSortId: number;
531
509
  };
532
510
  }
533
- export declare function setCollectionItemsSortID_Draft({ resourceId, data }: SetCollectionItemsSortID_Draft_ParamsType): Promise<any>;
511
+ export declare function setCollectionItemsSortID_Draft({ resourceId, data, }: SetCollectionItemsSortID_Draft_ParamsType): Promise<any>;
534
512
  interface ReorderCollectionItems_Draft_ParamsType {
535
513
  resourceId: string;
536
514
  sortField: 'createDate' | 'itemTitle' | 'sortId' | 'resourceUpdateDate';
@@ -549,31 +527,19 @@ interface UpdateCollectionItemsInfo_Draft_ParamsType {
549
527
  itemTitle: string;
550
528
  }[];
551
529
  }
552
- export declare function updateCollectionItemsInfo_Draft({ resourceId, data }: UpdateCollectionItemsInfo_Draft_ParamsType): Promise<any>;
530
+ export declare function updateCollectionItemsInfo_Draft({ resourceId, data, }: UpdateCollectionItemsInfo_Draft_ParamsType): Promise<any>;
553
531
  interface UpdateCollectionItemAuthorization_Draft_ParamsType {
554
532
  resourceId: string;
555
533
  itemId: string;
556
- resolveResources: {
557
- resourceId: string;
558
- contracts: {
559
- policyId: string;
560
- }[];
561
- }[];
562
534
  }
563
- export declare function updateCollectionItemAuthorization_Draft({ resourceId, itemId, ...params }: UpdateCollectionItemAuthorization_Draft_ParamsType): Promise<any>;
535
+ export declare function updateCollectionItemAuthorization_Draft({ resourceId, itemId, ...data }: UpdateCollectionItemAuthorization_Draft_ParamsType): Promise<any>;
564
536
  interface AddResourceItems_Draft_ParamsType {
565
537
  resourceId: string;
566
538
  addCollectionItems: {
567
539
  resourceId: string;
568
540
  itemTitle: string;
569
- resolveResources?: {
570
- resourceId: string;
571
- contracts: {
572
- policyId: string;
573
- }[];
574
- }[];
575
541
  }[];
576
- isPublish: 1 | 0;
542
+ isPublish?: 1 | 0;
577
543
  }
578
544
  export declare function addResourceItems_Draft({ resourceId, ...params }: AddResourceItems_Draft_ParamsType): Promise<any>;
579
545
  interface GetCollectionItemsAuth_Draft_ParamsType {
@@ -30,7 +30,7 @@ interface ObjectListParamsType {
30
30
  sort?: string;
31
31
  omitResourceType?: string;
32
32
  mime?: string;
33
- extNames: string;
33
+ extNames?: string;
34
34
  }
35
35
  export declare function objectList({ bucketName, ...params }: ObjectListParamsType): Promise<any>;
36
36
  interface UserNodeDataListParamsType {
@@ -95,4 +95,10 @@ interface ThirdPartyIsBindParamsType {
95
95
  export declare function thirdPartyIsBind(params: ThirdPartyIsBindParamsType): Promise<any>;
96
96
  export declare function signForCoins(): Promise<any>;
97
97
  export declare function getSignInfo(): Promise<any>;
98
+ interface SearchForConsoleParamsType {
99
+ skip?: number;
100
+ limit?: number;
101
+ keywords?: string;
102
+ }
103
+ export declare function searchForConsole(params?: SearchForConsoleParamsType): Promise<any>;
98
104
  export {};