@freelog/tools-lib 0.1.116 → 0.1.119
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.
- package/dist/service-API/activities.d.ts +9 -0
- package/dist/tools-lib.cjs.development.js +37 -1
- package/dist/tools-lib.cjs.development.js.map +1 -1
- package/dist/tools-lib.cjs.production.min.js +1 -1
- package/dist/tools-lib.cjs.production.min.js.map +1 -1
- package/dist/tools-lib.esm.js +37 -1
- package/dist/tools-lib.esm.js.map +1 -1
- package/dist/utils/linkTo.d.ts +1 -1
- package/package.json +1 -1
- package/src/service-API/activities.ts +36 -1
- package/src/service-API/presentables.ts +287 -287
- package/src/utils/linkTo.ts +1 -1
package/dist/utils/linkTo.d.ts
CHANGED
|
@@ -58,7 +58,7 @@ interface NodeCreatorParamsType {
|
|
|
58
58
|
export declare function nodeCreator({}?: NodeCreatorParamsType): TReturnType;
|
|
59
59
|
interface NodeManagementParamsType {
|
|
60
60
|
nodeID: number;
|
|
61
|
-
showPage?: 'exhibit' | 'theme';
|
|
61
|
+
showPage?: 'exhibit' | 'theme' | 'mappingRule';
|
|
62
62
|
}
|
|
63
63
|
export declare function nodeManagement({ nodeID, showPage, ...params }: NodeManagementParamsType): TReturnType;
|
|
64
64
|
interface ExhibitManagementParamsType {
|
package/package.json
CHANGED
|
@@ -48,7 +48,6 @@ interface AdsDetailsParamsType {
|
|
|
48
48
|
skip?: number;
|
|
49
49
|
limit?: number;
|
|
50
50
|
place: 1 | 2 | 3 | 4; // 投放位置 1:顶部公告栏 2:右侧浮窗 3:概览页 4:发现页
|
|
51
|
-
|
|
52
51
|
}
|
|
53
52
|
|
|
54
53
|
export function adsDetails(params: AdsDetailsParamsType) {
|
|
@@ -58,3 +57,39 @@ export function adsDetails(params: AdsDetailsParamsType) {
|
|
|
58
57
|
params: params,
|
|
59
58
|
});
|
|
60
59
|
}
|
|
60
|
+
|
|
61
|
+
// 获取基本任务详情
|
|
62
|
+
interface GetBaseTaskInfoParamsType {
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
export function getBaseTaskInfo(params: GetBaseTaskInfoParamsType = {}) {
|
|
66
|
+
return FUtil.Request({
|
|
67
|
+
method: 'GET',
|
|
68
|
+
url: `/v2/activities/facade/getBaseTaskInfo`,
|
|
69
|
+
params: params,
|
|
70
|
+
});
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
// 获取资源任务详情
|
|
74
|
+
interface GetResourceTaskInfoParamsType {
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
export function getResourceTaskInfo(params: GetResourceTaskInfoParamsType = {}) {
|
|
78
|
+
return FUtil.Request({
|
|
79
|
+
method: 'GET',
|
|
80
|
+
url: `/v2/activities/facade/getResourceTaskInfo`,
|
|
81
|
+
params: params,
|
|
82
|
+
});
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
// 获取节点任务详情
|
|
86
|
+
interface GetNodeTaskInfoParamsType {
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
export function getNodeTaskInfo(params: GetNodeTaskInfoParamsType = {}) {
|
|
90
|
+
return FUtil.Request({
|
|
91
|
+
method: 'GET',
|
|
92
|
+
url: `/v2/activities/facade/getNodeTaskInfo`,
|
|
93
|
+
params: params,
|
|
94
|
+
});
|
|
95
|
+
}
|
|
@@ -1,287 +1,287 @@
|
|
|
1
|
-
import FUtil from '../utils';
|
|
2
|
-
|
|
3
|
-
// 创建展品
|
|
4
|
-
export interface CreatePresentableParamsType {
|
|
5
|
-
nodeId: number;
|
|
6
|
-
resourceId: string;
|
|
7
|
-
version: string;
|
|
8
|
-
resolveResources: {
|
|
9
|
-
resourceId: string;
|
|
10
|
-
contracts: {
|
|
11
|
-
policyId: string;
|
|
12
|
-
}[];
|
|
13
|
-
}[];
|
|
14
|
-
presentableName: string;
|
|
15
|
-
tags?: string[];
|
|
16
|
-
policies?: {
|
|
17
|
-
policyName: string;
|
|
18
|
-
policyText: string;
|
|
19
|
-
status?: 0 | 1;
|
|
20
|
-
}[];
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
export function createPresentable(params: CreatePresentableParamsType) {
|
|
24
|
-
// return FUtil.Axios.post(`/v2/presentables`, params);
|
|
25
|
-
return FUtil.Request({
|
|
26
|
-
method: 'POST',
|
|
27
|
-
url: `/v2/presentables`,
|
|
28
|
-
data: params,
|
|
29
|
-
});
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
// 更新展品
|
|
33
|
-
interface UpdatePresentableParamsType {
|
|
34
|
-
presentableId: string;
|
|
35
|
-
presentableTitle?: string;
|
|
36
|
-
tags?: string[];
|
|
37
|
-
coverImages?: string[];
|
|
38
|
-
addPolicies?: {
|
|
39
|
-
policyName: string;
|
|
40
|
-
policyText: string;
|
|
41
|
-
status?: 0 | 1;
|
|
42
|
-
}[];
|
|
43
|
-
updatePolicies?: {
|
|
44
|
-
policyId: string;
|
|
45
|
-
status: 0 | 1;
|
|
46
|
-
}[];
|
|
47
|
-
resolveResources?: {
|
|
48
|
-
resourceId: string;
|
|
49
|
-
contracts: {
|
|
50
|
-
policyId: string;
|
|
51
|
-
}[];
|
|
52
|
-
}[];
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
export function updatePresentable({presentableId, ...params}: UpdatePresentableParamsType) {
|
|
56
|
-
// return FUtil.Axios.put(`/v2/presentables/${presentableId}`, params);
|
|
57
|
-
return FUtil.Request({
|
|
58
|
-
method: 'PUT',
|
|
59
|
-
url: `/v2/presentables/${presentableId}`,
|
|
60
|
-
data: params,
|
|
61
|
-
});
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
// 上下线presentable
|
|
65
|
-
interface PresentablesOnlineParamsType {
|
|
66
|
-
presentableId: string;
|
|
67
|
-
onlineStatus: 0 | 1;
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
export function presentablesOnlineStatus({presentableId, ...params}: PresentablesOnlineParamsType) {
|
|
71
|
-
// return FUtil.Axios.put(`/v2/presentables/${presentableId}/onlineStatus`, params);
|
|
72
|
-
return FUtil.Request({
|
|
73
|
-
method: 'PUT',
|
|
74
|
-
url: `/v2/presentables/${presentableId}/onlineStatus`,
|
|
75
|
-
data: params,
|
|
76
|
-
});
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
// 查看展品详情
|
|
80
|
-
interface PresentableDetailsParamsType1 {
|
|
81
|
-
presentableId: string;
|
|
82
|
-
projection?: string;
|
|
83
|
-
isLoadVersionProperty?: 0 | 1;
|
|
84
|
-
isLoadPolicyInfo?: 0 | 1;
|
|
85
|
-
isTranslate?: 0 | 1;
|
|
86
|
-
isLoadCustomPropertyDescriptors?: 0 | 1;
|
|
87
|
-
isLoadResourceDetailInfo?: 0 | 1;
|
|
88
|
-
isLoadResourceVersionInfo?: 0 | 1;
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
interface PresentableDetailsParamsType2 {
|
|
92
|
-
nodeId: number;
|
|
93
|
-
resourceId?: string;
|
|
94
|
-
resourceName?: string;
|
|
95
|
-
presentableName?: string;
|
|
96
|
-
projection?: string;
|
|
97
|
-
isLoadVersionProperty?: 0 | 1;
|
|
98
|
-
isLoadPolicyInfo?: 0 | 1;
|
|
99
|
-
isLoadCustomPropertyDescriptors?: 0 | 1;
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
export function presentableDetails(params: PresentableDetailsParamsType1 | PresentableDetailsParamsType2) {
|
|
103
|
-
if ((params as PresentableDetailsParamsType2).nodeId) {
|
|
104
|
-
// return FUtil.Axios.get(`/v2/presentables/detail`, {
|
|
105
|
-
// params,
|
|
106
|
-
// });
|
|
107
|
-
return FUtil.Request({
|
|
108
|
-
method: 'GET',
|
|
109
|
-
url: `/v2/presentables/detail`,
|
|
110
|
-
params: params,
|
|
111
|
-
});
|
|
112
|
-
}
|
|
113
|
-
const {presentableId, ...p} = params as PresentableDetailsParamsType1;
|
|
114
|
-
// return FUtil.Axios.get(`/v2/presentables/${presentableId}`, {
|
|
115
|
-
// params: p,
|
|
116
|
-
// });
|
|
117
|
-
return FUtil.Request({
|
|
118
|
-
method: 'GET',
|
|
119
|
-
url: `/v2/presentables/${presentableId}`,
|
|
120
|
-
params: p,
|
|
121
|
-
});
|
|
122
|
-
}
|
|
123
|
-
|
|
124
|
-
// 查询展品分页列表
|
|
125
|
-
interface PresentablesParamsType {
|
|
126
|
-
nodeId: number;
|
|
127
|
-
skip?: number;
|
|
128
|
-
limit?: number;
|
|
129
|
-
resourceType?: string;
|
|
130
|
-
omitResourceType?: string;
|
|
131
|
-
onlineStatus?: number;
|
|
132
|
-
tags?: string;
|
|
133
|
-
projection?: string;
|
|
134
|
-
keywords?: string;
|
|
135
|
-
isLoadVersionProperty?: 0 | 1;
|
|
136
|
-
isLoadPolicyInfo?: 0 | 1;
|
|
137
|
-
}
|
|
138
|
-
|
|
139
|
-
export function presentables(params: PresentablesParamsType) {
|
|
140
|
-
return FUtil.Request({
|
|
141
|
-
method: 'GET',
|
|
142
|
-
url: `/v2/presentables`,
|
|
143
|
-
params: params,
|
|
144
|
-
});
|
|
145
|
-
}
|
|
146
|
-
|
|
147
|
-
// 批量查询展品列表
|
|
148
|
-
interface PresentableListParamsType {
|
|
149
|
-
nodeId?: number;
|
|
150
|
-
userId?: number;
|
|
151
|
-
presentableIds?: string;
|
|
152
|
-
resourceIds?: string;
|
|
153
|
-
resourceNames?: string;
|
|
154
|
-
isLoadVersionProperty?: 0 | 1;
|
|
155
|
-
isLoadPolicyInfo?: 0 | 1;
|
|
156
|
-
isTranslate?: 0 | 1;
|
|
157
|
-
projection?: string;
|
|
158
|
-
resolveResourceIds?: string;
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
export function presentableList(params: PresentableListParamsType) {
|
|
162
|
-
return FUtil.Request({
|
|
163
|
-
method: 'GET',
|
|
164
|
-
url: `/v2/presentables/list`,
|
|
165
|
-
params: params,
|
|
166
|
-
});
|
|
167
|
-
}
|
|
168
|
-
|
|
169
|
-
// 查看展品依赖树
|
|
170
|
-
interface DependencyTreeParamsType {
|
|
171
|
-
presentableId: string;
|
|
172
|
-
maxDeep?: number;
|
|
173
|
-
nid?: string;
|
|
174
|
-
isContainRootNode?: boolean;
|
|
175
|
-
version?: string;
|
|
176
|
-
}
|
|
177
|
-
|
|
178
|
-
export function dependencyTree({presentableId, ...params}: DependencyTreeParamsType) {
|
|
179
|
-
// return FUtil.Axios.get(`/v2/presentables/${presentableId}/dependencyTree`, {params});
|
|
180
|
-
return FUtil.Request({
|
|
181
|
-
method: 'GET',
|
|
182
|
-
url: `/v2/presentables/${presentableId}/dependencyTree`,
|
|
183
|
-
params: params,
|
|
184
|
-
});
|
|
185
|
-
}
|
|
186
|
-
|
|
187
|
-
// 查看展品关系树
|
|
188
|
-
interface RelationTreeParamsType {
|
|
189
|
-
presentableId: string;
|
|
190
|
-
version?: string;
|
|
191
|
-
}
|
|
192
|
-
|
|
193
|
-
export function relationTree({presentableId, ...params}: RelationTreeParamsType) {
|
|
194
|
-
// return FUtil.Axios.get(`/v2/presentables/${presentableId}/relationTree`, {params});
|
|
195
|
-
return FUtil.Request({
|
|
196
|
-
method: 'GET',
|
|
197
|
-
url: `/v2/presentables/${presentableId}/relationTree`,
|
|
198
|
-
params: params,
|
|
199
|
-
});
|
|
200
|
-
}
|
|
201
|
-
|
|
202
|
-
// 查看展品授权树
|
|
203
|
-
interface AuthTreeParamsType {
|
|
204
|
-
presentableId: string;
|
|
205
|
-
maxDeep?: number;
|
|
206
|
-
nid?: string;
|
|
207
|
-
isContainRootNode?: boolean;
|
|
208
|
-
version?: string;
|
|
209
|
-
}
|
|
210
|
-
|
|
211
|
-
export function authTree({presentableId, ...params}: AuthTreeParamsType) {
|
|
212
|
-
// return FUtil.Axios.get(`/v2/presentables/${presentableId}/authTree`, {params});
|
|
213
|
-
return FUtil.Request({
|
|
214
|
-
method: 'GET',
|
|
215
|
-
url: `/v2/presentables/${presentableId}/authTree`,
|
|
216
|
-
params: params,
|
|
217
|
-
});
|
|
218
|
-
}
|
|
219
|
-
|
|
220
|
-
// 切换展品版本
|
|
221
|
-
interface PresentablesVersionParamsType {
|
|
222
|
-
presentableId: string;
|
|
223
|
-
version: string;
|
|
224
|
-
}
|
|
225
|
-
|
|
226
|
-
export function presentablesVersion({presentableId, ...params}: PresentablesVersionParamsType) {
|
|
227
|
-
// return FUtil.Axios.put(`/v2/presentables/${presentableId}/version`, params);
|
|
228
|
-
return FUtil.Request({
|
|
229
|
-
method: 'PUT',
|
|
230
|
-
url: `/v2/presentables/${presentableId}/version`,
|
|
231
|
-
data: params,
|
|
232
|
-
});
|
|
233
|
-
}
|
|
234
|
-
|
|
235
|
-
// 设置展品自定义属性
|
|
236
|
-
interface UpdateRewritePropertyParamsType {
|
|
237
|
-
presentableId: string;
|
|
238
|
-
rewriteProperty: {
|
|
239
|
-
key: string;
|
|
240
|
-
value: string;
|
|
241
|
-
remark: string;
|
|
242
|
-
}[];
|
|
243
|
-
}
|
|
244
|
-
|
|
245
|
-
export function updateRewriteProperty({presentableId, ...params}: UpdateRewritePropertyParamsType) {
|
|
246
|
-
// return FUtil.Axios.put(`/v2/presentables/${presentableId}/rewriteProperty`, params);
|
|
247
|
-
return FUtil.Request({
|
|
248
|
-
method: 'PUT',
|
|
249
|
-
url: `/v2/presentables/${presentableId}/rewriteProperty`,
|
|
250
|
-
data: params,
|
|
251
|
-
});
|
|
252
|
-
}
|
|
253
|
-
|
|
254
|
-
// 批量获取展品授权结果
|
|
255
|
-
interface BatchAuthParamsType {
|
|
256
|
-
nodeId: number;
|
|
257
|
-
authType: 1 | 2 | 3; // 1:节点侧授权 2:资源侧授权 3:节点+资源侧授权
|
|
258
|
-
presentableIds: string;
|
|
259
|
-
}
|
|
260
|
-
|
|
261
|
-
export function batchAuth({nodeId, ...params}: BatchAuthParamsType) {
|
|
262
|
-
// return FUtil.Axios.get(`/v2/auths/presentables/nodes/${nodeId}/batchAuth/result`, {
|
|
263
|
-
// params,
|
|
264
|
-
// });
|
|
265
|
-
return FUtil.Request({
|
|
266
|
-
method: 'GET',
|
|
267
|
-
url: `/v2/auths/presentables/nodes/${nodeId}/batchAuth/result`,
|
|
268
|
-
params: params,
|
|
269
|
-
});
|
|
270
|
-
}
|
|
271
|
-
|
|
272
|
-
// 查看合约应用的展品列表
|
|
273
|
-
interface ContractAppliedPresentableParamsType {
|
|
274
|
-
nodeId: number;
|
|
275
|
-
contractIds: string;
|
|
276
|
-
}
|
|
277
|
-
|
|
278
|
-
export function contractAppliedPresentable({nodeId, ...params}: ContractAppliedPresentableParamsType) {
|
|
279
|
-
// return FUtil.Axios.get(`/v2/presentables/${nodeId}/contractAppliedPresentable`, {
|
|
280
|
-
// params,
|
|
281
|
-
// });
|
|
282
|
-
return FUtil.Request({
|
|
283
|
-
method: 'GET',
|
|
284
|
-
url: `/v2/presentables/${nodeId}/contractAppliedPresentable`,
|
|
285
|
-
params: params,
|
|
286
|
-
});
|
|
287
|
-
}
|
|
1
|
+
import FUtil from '../utils';
|
|
2
|
+
|
|
3
|
+
// 创建展品
|
|
4
|
+
export interface CreatePresentableParamsType {
|
|
5
|
+
nodeId: number;
|
|
6
|
+
resourceId: string;
|
|
7
|
+
version: string;
|
|
8
|
+
resolveResources: {
|
|
9
|
+
resourceId: string;
|
|
10
|
+
contracts: {
|
|
11
|
+
policyId: string;
|
|
12
|
+
}[];
|
|
13
|
+
}[];
|
|
14
|
+
presentableName: string;
|
|
15
|
+
tags?: string[];
|
|
16
|
+
policies?: {
|
|
17
|
+
policyName: string;
|
|
18
|
+
policyText: string;
|
|
19
|
+
status?: 0 | 1;
|
|
20
|
+
}[];
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
export function createPresentable(params: CreatePresentableParamsType) {
|
|
24
|
+
// return FUtil.Axios.post(`/v2/presentables`, params);
|
|
25
|
+
return FUtil.Request({
|
|
26
|
+
method: 'POST',
|
|
27
|
+
url: `/v2/presentables`,
|
|
28
|
+
data: params,
|
|
29
|
+
});
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
// 更新展品
|
|
33
|
+
interface UpdatePresentableParamsType {
|
|
34
|
+
presentableId: string;
|
|
35
|
+
presentableTitle?: string;
|
|
36
|
+
tags?: string[];
|
|
37
|
+
coverImages?: string[];
|
|
38
|
+
addPolicies?: {
|
|
39
|
+
policyName: string;
|
|
40
|
+
policyText: string;
|
|
41
|
+
status?: 0 | 1;
|
|
42
|
+
}[];
|
|
43
|
+
updatePolicies?: {
|
|
44
|
+
policyId: string;
|
|
45
|
+
status: 0 | 1;
|
|
46
|
+
}[];
|
|
47
|
+
resolveResources?: {
|
|
48
|
+
resourceId: string;
|
|
49
|
+
contracts: {
|
|
50
|
+
policyId: string;
|
|
51
|
+
}[];
|
|
52
|
+
}[];
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
export function updatePresentable({presentableId, ...params}: UpdatePresentableParamsType) {
|
|
56
|
+
// return FUtil.Axios.put(`/v2/presentables/${presentableId}`, params);
|
|
57
|
+
return FUtil.Request({
|
|
58
|
+
method: 'PUT',
|
|
59
|
+
url: `/v2/presentables/${presentableId}`,
|
|
60
|
+
data: params,
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
// 上下线presentable
|
|
65
|
+
interface PresentablesOnlineParamsType {
|
|
66
|
+
presentableId: string;
|
|
67
|
+
onlineStatus: 0 | 1;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
export function presentablesOnlineStatus({presentableId, ...params}: PresentablesOnlineParamsType) {
|
|
71
|
+
// return FUtil.Axios.put(`/v2/presentables/${presentableId}/onlineStatus`, params);
|
|
72
|
+
return FUtil.Request({
|
|
73
|
+
method: 'PUT',
|
|
74
|
+
url: `/v2/presentables/${presentableId}/onlineStatus`,
|
|
75
|
+
data: params,
|
|
76
|
+
});
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
// 查看展品详情
|
|
80
|
+
interface PresentableDetailsParamsType1 {
|
|
81
|
+
presentableId: string;
|
|
82
|
+
projection?: string;
|
|
83
|
+
isLoadVersionProperty?: 0 | 1;
|
|
84
|
+
isLoadPolicyInfo?: 0 | 1;
|
|
85
|
+
isTranslate?: 0 | 1;
|
|
86
|
+
isLoadCustomPropertyDescriptors?: 0 | 1;
|
|
87
|
+
isLoadResourceDetailInfo?: 0 | 1;
|
|
88
|
+
isLoadResourceVersionInfo?: 0 | 1;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
interface PresentableDetailsParamsType2 {
|
|
92
|
+
nodeId: number;
|
|
93
|
+
resourceId?: string;
|
|
94
|
+
resourceName?: string;
|
|
95
|
+
presentableName?: string;
|
|
96
|
+
projection?: string;
|
|
97
|
+
isLoadVersionProperty?: 0 | 1;
|
|
98
|
+
isLoadPolicyInfo?: 0 | 1;
|
|
99
|
+
isLoadCustomPropertyDescriptors?: 0 | 1;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
export function presentableDetails(params: PresentableDetailsParamsType1 | PresentableDetailsParamsType2) {
|
|
103
|
+
if ((params as PresentableDetailsParamsType2).nodeId) {
|
|
104
|
+
// return FUtil.Axios.get(`/v2/presentables/detail`, {
|
|
105
|
+
// params,
|
|
106
|
+
// });
|
|
107
|
+
return FUtil.Request({
|
|
108
|
+
method: 'GET',
|
|
109
|
+
url: `/v2/presentables/detail`,
|
|
110
|
+
params: params,
|
|
111
|
+
});
|
|
112
|
+
}
|
|
113
|
+
const {presentableId, ...p} = params as PresentableDetailsParamsType1;
|
|
114
|
+
// return FUtil.Axios.get(`/v2/presentables/${presentableId}`, {
|
|
115
|
+
// params: p,
|
|
116
|
+
// });
|
|
117
|
+
return FUtil.Request({
|
|
118
|
+
method: 'GET',
|
|
119
|
+
url: `/v2/presentables/${presentableId}`,
|
|
120
|
+
params: p,
|
|
121
|
+
});
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
// 查询展品分页列表
|
|
125
|
+
interface PresentablesParamsType {
|
|
126
|
+
nodeId: number;
|
|
127
|
+
skip?: number;
|
|
128
|
+
limit?: number;
|
|
129
|
+
resourceType?: string;
|
|
130
|
+
omitResourceType?: string;
|
|
131
|
+
onlineStatus?: number;
|
|
132
|
+
tags?: string;
|
|
133
|
+
projection?: string;
|
|
134
|
+
keywords?: string;
|
|
135
|
+
isLoadVersionProperty?: 0 | 1;
|
|
136
|
+
isLoadPolicyInfo?: 0 | 1;
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
export function presentables(params: PresentablesParamsType) {
|
|
140
|
+
return FUtil.Request({
|
|
141
|
+
method: 'GET',
|
|
142
|
+
url: `/v2/presentables`,
|
|
143
|
+
params: params,
|
|
144
|
+
});
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
// 批量查询展品列表
|
|
148
|
+
interface PresentableListParamsType {
|
|
149
|
+
nodeId?: number;
|
|
150
|
+
userId?: number;
|
|
151
|
+
presentableIds?: string;
|
|
152
|
+
resourceIds?: string;
|
|
153
|
+
resourceNames?: string;
|
|
154
|
+
isLoadVersionProperty?: 0 | 1;
|
|
155
|
+
isLoadPolicyInfo?: 0 | 1;
|
|
156
|
+
isTranslate?: 0 | 1;
|
|
157
|
+
projection?: string;
|
|
158
|
+
resolveResourceIds?: string;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
export function presentableList(params: PresentableListParamsType) {
|
|
162
|
+
return FUtil.Request({
|
|
163
|
+
method: 'GET',
|
|
164
|
+
url: `/v2/presentables/list`,
|
|
165
|
+
params: params,
|
|
166
|
+
});
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
// 查看展品依赖树
|
|
170
|
+
interface DependencyTreeParamsType {
|
|
171
|
+
presentableId: string;
|
|
172
|
+
maxDeep?: number;
|
|
173
|
+
nid?: string;
|
|
174
|
+
isContainRootNode?: boolean;
|
|
175
|
+
version?: string;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
export function dependencyTree({presentableId, ...params}: DependencyTreeParamsType) {
|
|
179
|
+
// return FUtil.Axios.get(`/v2/presentables/${presentableId}/dependencyTree`, {params});
|
|
180
|
+
return FUtil.Request({
|
|
181
|
+
method: 'GET',
|
|
182
|
+
url: `/v2/presentables/${presentableId}/dependencyTree`,
|
|
183
|
+
params: params,
|
|
184
|
+
});
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
// 查看展品关系树
|
|
188
|
+
interface RelationTreeParamsType {
|
|
189
|
+
presentableId: string;
|
|
190
|
+
version?: string;
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
export function relationTree({presentableId, ...params}: RelationTreeParamsType) {
|
|
194
|
+
// return FUtil.Axios.get(`/v2/presentables/${presentableId}/relationTree`, {params});
|
|
195
|
+
return FUtil.Request({
|
|
196
|
+
method: 'GET',
|
|
197
|
+
url: `/v2/presentables/${presentableId}/relationTree`,
|
|
198
|
+
params: params,
|
|
199
|
+
});
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
// 查看展品授权树
|
|
203
|
+
interface AuthTreeParamsType {
|
|
204
|
+
presentableId: string;
|
|
205
|
+
maxDeep?: number;
|
|
206
|
+
nid?: string;
|
|
207
|
+
isContainRootNode?: boolean;
|
|
208
|
+
version?: string;
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
export function authTree({presentableId, ...params}: AuthTreeParamsType) {
|
|
212
|
+
// return FUtil.Axios.get(`/v2/presentables/${presentableId}/authTree`, {params});
|
|
213
|
+
return FUtil.Request({
|
|
214
|
+
method: 'GET',
|
|
215
|
+
url: `/v2/presentables/${presentableId}/authTree`,
|
|
216
|
+
params: params,
|
|
217
|
+
});
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
// 切换展品版本
|
|
221
|
+
interface PresentablesVersionParamsType {
|
|
222
|
+
presentableId: string;
|
|
223
|
+
version: string;
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
export function presentablesVersion({presentableId, ...params}: PresentablesVersionParamsType) {
|
|
227
|
+
// return FUtil.Axios.put(`/v2/presentables/${presentableId}/version`, params);
|
|
228
|
+
return FUtil.Request({
|
|
229
|
+
method: 'PUT',
|
|
230
|
+
url: `/v2/presentables/${presentableId}/version`,
|
|
231
|
+
data: params,
|
|
232
|
+
});
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
// 设置展品自定义属性
|
|
236
|
+
interface UpdateRewritePropertyParamsType {
|
|
237
|
+
presentableId: string;
|
|
238
|
+
rewriteProperty: {
|
|
239
|
+
key: string;
|
|
240
|
+
value: string;
|
|
241
|
+
remark: string;
|
|
242
|
+
}[];
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
export function updateRewriteProperty({presentableId, ...params}: UpdateRewritePropertyParamsType) {
|
|
246
|
+
// return FUtil.Axios.put(`/v2/presentables/${presentableId}/rewriteProperty`, params);
|
|
247
|
+
return FUtil.Request({
|
|
248
|
+
method: 'PUT',
|
|
249
|
+
url: `/v2/presentables/${presentableId}/rewriteProperty`,
|
|
250
|
+
data: params,
|
|
251
|
+
});
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
// 批量获取展品授权结果
|
|
255
|
+
interface BatchAuthParamsType {
|
|
256
|
+
nodeId: number;
|
|
257
|
+
authType: 1 | 2 | 3; // 1:节点侧授权 2:资源侧授权 3:节点+资源侧授权
|
|
258
|
+
presentableIds: string;
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
export function batchAuth({nodeId, ...params}: BatchAuthParamsType) {
|
|
262
|
+
// return FUtil.Axios.get(`/v2/auths/presentables/nodes/${nodeId}/batchAuth/result`, {
|
|
263
|
+
// params,
|
|
264
|
+
// });
|
|
265
|
+
return FUtil.Request({
|
|
266
|
+
method: 'GET',
|
|
267
|
+
url: `/v2/auths/presentables/nodes/${nodeId}/batchAuth/result`,
|
|
268
|
+
params: params,
|
|
269
|
+
});
|
|
270
|
+
}
|
|
271
|
+
|
|
272
|
+
// 查看合约应用的展品列表
|
|
273
|
+
interface ContractAppliedPresentableParamsType {
|
|
274
|
+
nodeId: number;
|
|
275
|
+
contractIds: string;
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
export function contractAppliedPresentable({nodeId, ...params}: ContractAppliedPresentableParamsType) {
|
|
279
|
+
// return FUtil.Axios.get(`/v2/presentables/${nodeId}/contractAppliedPresentable`, {
|
|
280
|
+
// params,
|
|
281
|
+
// });
|
|
282
|
+
return FUtil.Request({
|
|
283
|
+
method: 'GET',
|
|
284
|
+
url: `/v2/presentables/${nodeId}/contractAppliedPresentable`,
|
|
285
|
+
params: params,
|
|
286
|
+
});
|
|
287
|
+
}
|
package/src/utils/linkTo.ts
CHANGED
|
@@ -143,7 +143,7 @@ export function nodeCreator({}: NodeCreatorParamsType = {}): TReturnType {
|
|
|
143
143
|
// 节点管理
|
|
144
144
|
interface NodeManagementParamsType {
|
|
145
145
|
nodeID: number;
|
|
146
|
-
showPage?: 'exhibit' | 'theme';
|
|
146
|
+
showPage?: 'exhibit' | 'theme' | 'mappingRule';
|
|
147
147
|
}
|
|
148
148
|
|
|
149
149
|
export function nodeManagement({nodeID, showPage = 'exhibit', ...params}: NodeManagementParamsType): TReturnType {
|