@blueking/ai-ui-sdk 0.4.3-beta.13 → 0.4.3-beta.14
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/README.md +2258 -2258
- package/dist/assets/svg/lock.svg +43 -43
- package/dist/common/util.ts.js +103 -103
- package/dist/components/render-agent/agent-download.vue.css +2 -2
- package/dist/components/render-agent/agent-type.vue.css +9 -9
- package/dist/components/render-agent/agent-type.vue.js +1 -1
- package/dist/components/render-auth/auth-dialog.script.vue.js.js +3 -6
- package/dist/components/render-auth/auth-dialog.vue.css +2 -2
- package/dist/components/render-auto-height-textarea/index.vue.css +26 -26
- package/dist/components/render-auto-height-textarea/index.vue.js +1 -1
- package/dist/components/render-auto-refresh/index.vue.css +30 -30
- package/dist/components/render-auto-refresh/index.vue.js +1 -1
- package/dist/components/render-card/agent/index.vue.d.ts +1 -1
- package/dist/components/render-card/agent/prefix-info-tool.vue.css +18 -18
- package/dist/components/render-card/agent/prefix-info-tool.vue.js +1 -1
- package/dist/components/render-card/base.vue.css +30 -30
- package/dist/components/render-card/base.vue.js +1 -1
- package/dist/components/render-card/knowledge/index.vue.d.ts +1 -1
- package/dist/components/render-card/knowledgebase/index.vue.d.ts +1 -1
- package/dist/components/render-card/llm/corner-badge.vue.css +12 -12
- package/dist/components/render-card/llm/corner-badge.vue.js +1 -1
- package/dist/components/render-card/llm/icons.vue.css +3 -3
- package/dist/components/render-card/llm/icons.vue.js +1 -1
- package/dist/components/render-card/llm/index.vue.d.ts +1 -1
- package/dist/components/render-card/llm/info.vue.css +8 -8
- package/dist/components/render-card/llm/info.vue.js +1 -1
- package/dist/components/render-card/llm/tag-prefix.vue.css +5 -5
- package/dist/components/render-card/llm/tag-prefix.vue.js +1 -1
- package/dist/components/render-card/mcp/index.vue.d.ts +1 -1
- package/dist/components/render-card/mcp/name-suffix.vue.css +7 -7
- package/dist/components/render-card/mcp/name-suffix.vue.js +1 -1
- package/dist/components/render-card/mcp/selected-tools-info.vue.d.ts +1 -1
- package/dist/components/render-card/prompt/icons.vue.css +2 -2
- package/dist/components/render-card/prompt/icons.vue.js +1 -1
- package/dist/components/render-card/prompt/index.script.vue.js.js +6 -1
- package/dist/components/render-card/prompt/index.vue.d.ts +2 -1
- package/dist/components/render-card/role/index.script.vue.js.js +6 -1
- package/dist/components/render-card/role/index.vue.d.ts +2 -1
- package/dist/components/render-card/skill/scanner.vue.css +7 -7
- package/dist/components/render-card/skill/scanner.vue.js +1 -1
- package/dist/components/render-card/tool/index.script.vue.js.js +6 -1
- package/dist/components/render-card/tool/index.vue.d.ts +2 -1
- package/dist/components/render-checkbox/index.vue.css +41 -41
- package/dist/components/render-checkbox/index.vue.js +1 -1
- package/dist/components/render-choose-tag/index.vue.css +29 -29
- package/dist/components/render-choose-tag/index.vue.js +1 -1
- package/dist/components/render-collapse/index.vue.css +6 -6
- package/dist/components/render-collapse/index.vue.js +1 -1
- package/dist/components/render-collection/content/index.vue.css +15 -15
- package/dist/components/render-collection/content/index.vue.js +1 -1
- package/dist/components/render-dataset/components/batch-delete-dataset-data/index.vue.css +10 -10
- package/dist/components/render-dataset/components/batch-delete-dataset-data/index.vue.js +1 -1
- package/dist/components/render-dataset/components/dataset-data-tool-icons/index.script.vue.js +1 -1
- package/dist/components/render-dataset/components/edit-dataset-data/index.vue.css +9 -9
- package/dist/components/render-dataset/components/edit-dataset-data/index.vue.js +1 -1
- package/dist/components/render-dataset/components/operation-record/index.vue.css +10 -10
- package/dist/components/render-dataset/components/operation-record/index.vue.js +1 -1
- package/dist/components/render-dataset/components/operation-record/table/index.vue.css +8 -8
- package/dist/components/render-dataset/components/operation-record/table/index.vue.js +1 -1
- package/dist/components/render-dataset/components/operation-record/view-op-result/index.vue.css +8 -8
- package/dist/components/render-dataset/components/operation-record/view-op-result/index.vue.js +1 -1
- package/dist/components/render-dataset/components/plus-dataset/index.vue.css +2 -2
- package/dist/components/render-dataset/components/plus-dataset/index.vue.js +1 -1
- package/dist/components/render-dataset/components/plus-dataset-data/form/api.vue.css +6 -6
- package/dist/components/render-dataset/components/plus-dataset-data/form/api.vue.js +1 -1
- package/dist/components/render-dataset/components/plus-dataset-data/form/footer.vue.css +3 -3
- package/dist/components/render-dataset/components/plus-dataset-data/form/footer.vue.js +1 -1
- package/dist/components/render-dataset/components/plus-dataset-data/form/index.vue.css +2 -2
- package/dist/components/render-dataset/components/plus-dataset-data/form/index.vue.js +1 -1
- package/dist/components/render-dataset/components/plus-dataset-data/form/manual.vue.css +4 -4
- package/dist/components/render-dataset/components/review-dataset-data/index.vue.css +21 -21
- package/dist/components/render-dataset/components/review-dataset-data/index.vue.js +1 -1
- package/dist/components/render-dataset-detail-origin-data/index.vue.css +9 -9
- package/dist/components/render-dataset-detail-origin-data/index.vue.js +1 -1
- package/dist/components/render-dataset-list/components/main.vue.css +9 -9
- package/dist/components/render-dataset-list/components/main.vue.js +1 -1
- package/dist/components/render-dataset-list/index.vue.css +4 -4
- package/dist/components/render-dataset-list/index.vue.js +1 -1
- package/dist/components/render-dialog/choose-resource.vue.css +4 -4
- package/dist/components/render-dialog/choose-resource.vue.js +1 -1
- package/dist/components/render-dialog/choose-result.vue.css +31 -31
- package/dist/components/render-dialog/choose-result.vue.js +1 -1
- package/dist/components/render-dialog/choose-space.vue.css +18 -18
- package/dist/components/render-dialog/choose-space.vue.js +1 -1
- package/dist/components/render-dialog/index.vue.css +12 -12
- package/dist/components/render-dialog/index.vue.js +1 -1
- package/dist/components/render-dropdown/index.vue.css +15 -15
- package/dist/components/render-file-card/index.vue.css +28 -28
- package/dist/components/render-file-card/index.vue.d.ts +1 -1
- package/dist/components/render-file-card/index.vue.js +1 -1
- package/dist/components/render-file-type-icon/index.vue.css +7 -7
- package/dist/components/render-file-type-icon/index.vue.js +1 -1
- package/dist/components/render-generate-tag/index.vue.css +12 -12
- package/dist/components/render-generate-tag/index.vue.js +1 -1
- package/dist/components/render-knowledge/icon/index.vue.css +2 -2
- package/dist/components/render-knowledge/icon/index.vue.js +1 -1
- package/dist/components/render-markdown/edit.postcss.css +92 -92
- package/dist/components/render-markdown/katex.ts.js +8 -8
- package/dist/components/render-markdown/prism-atom-one-dark.postcss.css +192 -192
- package/dist/components/render-markdown/view.postcss.css +99 -99
- package/dist/components/render-permission-tag/index.vue.css +2 -2
- package/dist/components/render-prompt/content/index.vue.css +5 -5
- package/dist/components/render-prompt/content/index.vue.js +1 -1
- package/dist/components/render-reference/index.vue.css +4 -4
- package/dist/components/render-reference/index.vue.js +1 -1
- package/dist/components/render-resource-version/index.vue.css +7 -7
- package/dist/components/render-resource-version/index.vue.js +1 -1
- package/dist/components/render-router-tab/index.vue.css +15 -15
- package/dist/components/render-router-tab/index.vue.js +1 -1
- package/dist/components/render-search-empty/index.script.vue.js.js +2 -3
- package/dist/components/render-search-empty/index.vue.d.ts +1 -1
- package/dist/components/render-search-select/index.vue.d.ts +1 -1
- package/dist/components/render-select-plus-extension/index.vue.css +11 -11
- package/dist/components/render-select-plus-extension/index.vue.js +1 -1
- package/dist/components/render-t-table/index.script.vue.js +5 -8
- package/dist/components/render-t-table/index.vue.css +117 -117
- package/dist/components/render-t-table/index.vue.d.ts +1 -1
- package/dist/components/render-t-table/index.vue.js +1 -1
- package/dist/components/render-tag-tree/index.vue.css +17 -17
- package/dist/components/render-tag-tree/index.vue.js +1 -1
- package/dist/components/render-tags/index.vue.css +12 -12
- package/dist/components/render-tags/index.vue.js +1 -1
- package/dist/components/render-tree/index.vue.css +12 -12
- package/dist/components/render-tree/index.vue.d.ts +1 -1
- package/dist/css/fonts/iconcool.svg +268 -268
- package/dist/css/g-utilities.css +16 -10
- package/dist/css/style.css +259 -259
- package/dist/hooks/use-ellipsis-tooltip.ts.js +28 -28
- package/dist/hooks/use-loading-version.ts.js +4 -4
- package/dist/http/helper/agent.ts.js +44 -44
- package/dist/http/helper/collection.ts.js +13 -12
- package/dist/http/helper/common.ts.js +44 -44
- package/dist/http/helper/dataset.ts.js +76 -76
- package/dist/http/helper/knowledge.ts.js +45 -45
- package/dist/http/helper/mcp.ts.js +36 -36
- package/dist/http/helper/permission.ts.js +12 -12
- package/dist/http/helper/prompt.ts.js +13 -12
- package/dist/http/helper/skill.ts.js +24 -24
- package/dist/http/helper/space.ts.js +24 -24
- package/dist/http/helper/tool.ts.js +22 -20
- package/dist/types/collection.d.ts +2 -0
- package/dist/types/prompt.d.ts +2 -0
- package/dist/types/tool.d.ts +2 -0
- package/package.json +112 -112
|
@@ -53,10 +53,10 @@ function _object_spread_props(target, source) {
|
|
|
53
53
|
import { transferBaseCountParam2BaseCountParamApi, transferIPaginationParam2IPaginationParamApi, transferISortParam2ISortParamApi, transferResourceCommonSearchParams2ResourceCommonSearchParamsApi } from './common.ts.js';
|
|
54
54
|
import { mergeStringWithoutLastSlash, mergeStringWithoutLeadingSlash } from '../../common/util.ts.js';
|
|
55
55
|
import { transferResourcePermissionApi2ResourcePermission } from './permission.ts.js';
|
|
56
|
-
/**
|
|
57
|
-
* 从路径中获取文件信息
|
|
58
|
-
* @param path 路径
|
|
59
|
-
* @returns 文件路径和文件名
|
|
56
|
+
/**
|
|
57
|
+
* 从路径中获取文件信息
|
|
58
|
+
* @param path 路径
|
|
59
|
+
* @returns 文件路径和文件名
|
|
60
60
|
*/ export const getFileInfoFromPath = (path)=>{
|
|
61
61
|
const match = /\/([^/]*)$/.exec(path);
|
|
62
62
|
const result = {
|
|
@@ -69,10 +69,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
69
69
|
}
|
|
70
70
|
return result;
|
|
71
71
|
};
|
|
72
|
-
/**
|
|
73
|
-
* ui 转换为接口使用
|
|
74
|
-
* @param data IKnowledge
|
|
75
|
-
* @returns IKnowledgeApi
|
|
72
|
+
/**
|
|
73
|
+
* ui 转换为接口使用
|
|
74
|
+
* @param data IKnowledge
|
|
75
|
+
* @returns IKnowledgeApi
|
|
76
76
|
*/ export const transferKnowledge = (data)=>({
|
|
77
77
|
id: data.id,
|
|
78
78
|
url: data.url,
|
|
@@ -151,10 +151,10 @@ export const transferPipelineVersionDiffApi2PipelineVersionDiff = (data)=>{
|
|
|
151
151
|
target: (_transferPipelineVersionHandleTypeApi2PipelineVersionHandleType1 = transferPipelineVersionHandleTypeApi2PipelineVersionHandleType(data.target)) !== null && _transferPipelineVersionHandleTypeApi2PipelineVersionHandleType1 !== void 0 ? _transferPipelineVersionHandleTypeApi2PipelineVersionHandleType1 : null
|
|
152
152
|
};
|
|
153
153
|
};
|
|
154
|
-
/**
|
|
155
|
-
* 接口转换为ui使用
|
|
156
|
-
* @param data IKnowledgeApi
|
|
157
|
-
* @returns IKnowledge
|
|
154
|
+
/**
|
|
155
|
+
* 接口转换为ui使用
|
|
156
|
+
* @param data IKnowledgeApi
|
|
157
|
+
* @returns IKnowledge
|
|
158
158
|
*/ export const transferKnowledgeApi = (data)=>{
|
|
159
159
|
var _data_config, _data_config1, _data_config2, _data_config3, _data_ingestion_stage_snapshots;
|
|
160
160
|
const { fileName = data.file_path, filePath = '' } = getFileInfoFromPath(data.file_path);
|
|
@@ -194,8 +194,8 @@ export const transferPipelineVersionDiffApi2PipelineVersionDiff = (data)=>{
|
|
|
194
194
|
pipelineVersionDiff: transferPipelineVersionDiffApi2PipelineVersionDiff(data.pipeline_version_diff)
|
|
195
195
|
};
|
|
196
196
|
};
|
|
197
|
-
/**
|
|
198
|
-
* 接口文件夹转换为knowledgbase
|
|
197
|
+
/**
|
|
198
|
+
* 接口文件夹转换为knowledgbase
|
|
199
199
|
*/ export const transferKnowledgeApi2Knowledgebase = (knowledge, knowledgebase)=>{
|
|
200
200
|
var _knowledge_config, _knowledge_children;
|
|
201
201
|
const { fileName = knowledge.file_path, filePath = '' } = getFileInfoFromPath(knowledge.file_path);
|
|
@@ -224,10 +224,10 @@ export const transferPipelineVersionDiffApi2PipelineVersionDiff = (data)=>{
|
|
|
224
224
|
children: (_knowledge_children = knowledge.children) === null || _knowledge_children === void 0 ? void 0 : _knowledge_children.map((child)=>transferKnowledgeApi2Knowledgebase(child, knowledgebase))
|
|
225
225
|
});
|
|
226
226
|
};
|
|
227
|
-
/**
|
|
228
|
-
* ui 转换为接口使用
|
|
229
|
-
* @param data IKnowledgebase
|
|
230
|
-
* @returns IKnowledgebaseApi
|
|
227
|
+
/**
|
|
228
|
+
* ui 转换为接口使用
|
|
229
|
+
* @param data IKnowledgebase
|
|
230
|
+
* @returns IKnowledgebaseApi
|
|
231
231
|
*/ export const transferKnowledgebase = (data)=>({
|
|
232
232
|
pipeline_codes: data.pipelineCodes,
|
|
233
233
|
id: data.id,
|
|
@@ -243,9 +243,9 @@ export const transferPipelineVersionDiffApi2PipelineVersionDiff = (data)=>{
|
|
|
243
243
|
status: data.status,
|
|
244
244
|
space_id: data.spaceId
|
|
245
245
|
});
|
|
246
|
-
/**
|
|
247
|
-
* 转换 ui 文件夹为 IKnowledgeApi,接口使用
|
|
248
|
-
* @param knowledgebase IKnowledgebase
|
|
246
|
+
/**
|
|
247
|
+
* 转换 ui 文件夹为 IKnowledgeApi,接口使用
|
|
248
|
+
* @param knowledgebase IKnowledgebase
|
|
249
249
|
*/ export const transferKnowledgebase2KnowledgeApi = (data)=>({
|
|
250
250
|
id: data.id,
|
|
251
251
|
config: {
|
|
@@ -259,10 +259,10 @@ export const transferPipelineVersionDiffApi2PipelineVersionDiff = (data)=>{
|
|
|
259
259
|
path_type: data.pathType,
|
|
260
260
|
anchor_path: mergeStringWithoutLastSlash(data.parentAnchorPath, data.name)
|
|
261
261
|
});
|
|
262
|
-
/**
|
|
263
|
-
* 接口转换为ui使用
|
|
264
|
-
* @param data IKnowledgebaseApi
|
|
265
|
-
* @returns IKnowledgebase
|
|
262
|
+
/**
|
|
263
|
+
* 接口转换为ui使用
|
|
264
|
+
* @param data IKnowledgebaseApi
|
|
265
|
+
* @returns IKnowledgebase
|
|
266
266
|
*/ export const transferKnowledgebaseApi = (data)=>{
|
|
267
267
|
var _data_children;
|
|
268
268
|
const knowledgebase = {
|
|
@@ -291,10 +291,10 @@ export const transferPipelineVersionDiffApi2PipelineVersionDiff = (data)=>{
|
|
|
291
291
|
children: (_data_children = data.children) === null || _data_children === void 0 ? void 0 : _data_children.map((child)=>transferKnowledgeApi2Knowledgebase(child, knowledgebase))
|
|
292
292
|
});
|
|
293
293
|
};
|
|
294
|
-
/**
|
|
295
|
-
* 接口转换为ui使用
|
|
296
|
-
* @param data IKnowledgePipelineApi
|
|
297
|
-
* @returns IKnowledgePipeline
|
|
294
|
+
/**
|
|
295
|
+
* 接口转换为ui使用
|
|
296
|
+
* @param data IKnowledgePipelineApi
|
|
297
|
+
* @returns IKnowledgePipeline
|
|
298
298
|
*/ export const transferKnowledgePipelineApi2KnowledgePipeline = (data)=>{
|
|
299
299
|
var _data_pipelines;
|
|
300
300
|
return {
|
|
@@ -306,10 +306,10 @@ export const transferPipelineVersionDiffApi2PipelineVersionDiff = (data)=>{
|
|
|
306
306
|
pipelines: (_data_pipelines = data.pipelines) === null || _data_pipelines === void 0 ? void 0 : _data_pipelines.map(transferKnowledgePipelineApi2KnowledgePipeline)
|
|
307
307
|
};
|
|
308
308
|
};
|
|
309
|
-
/**
|
|
310
|
-
* 接口转换为ui
|
|
311
|
-
* @param data IKnowledgeQuerySetting
|
|
312
|
-
* @returns IKnowledgeQuerySettingApi
|
|
309
|
+
/**
|
|
310
|
+
* 接口转换为ui
|
|
311
|
+
* @param data IKnowledgeQuerySetting
|
|
312
|
+
* @returns IKnowledgeQuerySettingApi
|
|
313
313
|
*/ export const transferKnowledgeQuerySetting = (data)=>({
|
|
314
314
|
recall_channels: data.recallChannels,
|
|
315
315
|
document_fragment_count: data.documentFragmentCount,
|
|
@@ -324,10 +324,10 @@ export const transferPipelineVersionDiffApi2PipelineVersionDiff = (data)=>{
|
|
|
324
324
|
is_response_when_no_knowledgebase_match: data.isResponseWhenNoKnowledgebaseMatch,
|
|
325
325
|
rejection_message: data.rejectionMessage
|
|
326
326
|
});
|
|
327
|
-
/**
|
|
328
|
-
* 接口转换为ui
|
|
329
|
-
* @param data IKnowledgeQuerySettingApi
|
|
330
|
-
* @returns IKnowledgeQuerySetting
|
|
327
|
+
/**
|
|
328
|
+
* 接口转换为ui
|
|
329
|
+
* @param data IKnowledgeQuerySettingApi
|
|
330
|
+
* @returns IKnowledgeQuerySetting
|
|
331
331
|
*/ export const transferKnowledgeQuerySettingApi = (data)=>({
|
|
332
332
|
recallChannels: data.recall_channels,
|
|
333
333
|
documentFragmentCount: data.document_fragment_count,
|
|
@@ -342,10 +342,10 @@ export const transferPipelineVersionDiffApi2PipelineVersionDiff = (data)=>{
|
|
|
342
342
|
isResponseWhenNoKnowledgebaseMatch: data.is_response_when_no_knowledgebase_match,
|
|
343
343
|
rejectionMessage: data.rejection_message
|
|
344
344
|
});
|
|
345
|
-
/**
|
|
346
|
-
* ui转换为接口使用
|
|
347
|
-
* @param data IKnowledgeListParam
|
|
348
|
-
* @returns IKnowledgeListParamApi
|
|
345
|
+
/**
|
|
346
|
+
* ui转换为接口使用
|
|
347
|
+
* @param data IKnowledgeListParam
|
|
348
|
+
* @returns IKnowledgeListParamApi
|
|
349
349
|
*/ export const transferKnowledgeListParam2KnowledgeListParamApi = (data)=>_object_spread({
|
|
350
350
|
searchbox: {
|
|
351
351
|
knowledge_name: data.searchbox.knowledgeName,
|
|
@@ -364,10 +364,10 @@ export const transferPipelineVersionDiffApi2PipelineVersionDiff = (data)=>{
|
|
|
364
364
|
with_private: data.withPrivate,
|
|
365
365
|
created_by: data.createdBy
|
|
366
366
|
}, transferIPaginationParam2IPaginationParamApi(data), transferISortParam2ISortParamApi(data), transferResourceCommonSearchParams2ResourceCommonSearchParamsApi(data));
|
|
367
|
-
/**
|
|
368
|
-
* ui转换为接口使用
|
|
369
|
-
* @param data IKnowledgebaseListParam
|
|
370
|
-
* @returns IKnowledgebaseListParamApi
|
|
367
|
+
/**
|
|
368
|
+
* ui转换为接口使用
|
|
369
|
+
* @param data IKnowledgebaseListParam
|
|
370
|
+
* @returns IKnowledgebaseListParamApi
|
|
371
371
|
*/ export const transferKnowledgebaseListParam2KnowledgebaseListParamApi = (data)=>_object_spread_props(_object_spread({}, transferResourceCommonSearchParams2ResourceCommonSearchParamsApi(data), transferISortParam2ISortParamApi(data), transferIPaginationParam2IPaginationParamApi(data)), {
|
|
372
372
|
fuzzy: data.fuzzy,
|
|
373
373
|
anchor_paths: data.anchorPaths,
|
|
@@ -51,10 +51,10 @@ function _object_spread_props(target, source) {
|
|
|
51
51
|
return target;
|
|
52
52
|
}
|
|
53
53
|
import { transferBaseCountParam2BaseCountParamApi, transferIApprovalSettingValue2IApprovalSettingValueApi, transferIApprovalSettingValueApi2IApprovalSettingValue, transferIPaginationParam2IPaginationParamApi, transferISortParam2ISortParamApi, transferResourceCommon2ResourceCommonApi, transferResourceCommonApi2ResourceCommon, transferResourceCommonSearchParams2ResourceCommonSearchParamsApi, transferResourceFormCommon2ResourceFormCommonApi, transferResourceFormCommonApi2ResourceFormCommon } from './common.ts.js';
|
|
54
|
-
/**
|
|
55
|
-
* ui转换为接口使用
|
|
56
|
-
* @param data IMcpListParam
|
|
57
|
-
* @returns IMcpListParamApi
|
|
54
|
+
/**
|
|
55
|
+
* ui转换为接口使用
|
|
56
|
+
* @param data IMcpListParam
|
|
57
|
+
* @returns IMcpListParamApi
|
|
58
58
|
*/ export const transferMcpParam2McpParamApi = (data)=>_object_spread_props(_object_spread({}, transferResourceCommonSearchParams2ResourceCommonSearchParamsApi(data), transferISortParam2ISortParamApi(data), transferIPaginationParam2IPaginationParamApi(data)), {
|
|
59
59
|
created_by: data.createdBy,
|
|
60
60
|
updated_by: data.updatedBy,
|
|
@@ -71,8 +71,8 @@ import { transferBaseCountParam2BaseCountParamApi, transferIApprovalSettingValue
|
|
|
71
71
|
with_apigw_mcp: data.withApigwMcp,
|
|
72
72
|
description: data.description
|
|
73
73
|
});
|
|
74
|
-
/**
|
|
75
|
-
* 接口转换为ui使用(MCP工具输入参数)
|
|
74
|
+
/**
|
|
75
|
+
* 接口转换为ui使用(MCP工具输入参数)
|
|
76
76
|
*/ export const transferMcpToolInputParamApi2McpToolInputParam = (data)=>{
|
|
77
77
|
var _data_children;
|
|
78
78
|
return {
|
|
@@ -83,8 +83,8 @@ import { transferBaseCountParam2BaseCountParamApi, transferIApprovalSettingValue
|
|
|
83
83
|
children: (_data_children = data.children) === null || _data_children === void 0 ? void 0 : _data_children.map(transferMcpToolInputParamApi2McpToolInputParam)
|
|
84
84
|
};
|
|
85
85
|
};
|
|
86
|
-
/**
|
|
87
|
-
* 接口转换为ui使用(MCP工具输出参数)
|
|
86
|
+
/**
|
|
87
|
+
* 接口转换为ui使用(MCP工具输出参数)
|
|
88
88
|
*/ export const transferMcpToolOutputParamApi2McpToolOutputParam = (data)=>{
|
|
89
89
|
var _data_children;
|
|
90
90
|
return {
|
|
@@ -94,8 +94,8 @@ import { transferBaseCountParam2BaseCountParamApi, transferIApprovalSettingValue
|
|
|
94
94
|
children: (_data_children = data.children) === null || _data_children === void 0 ? void 0 : _data_children.map(transferMcpToolOutputParamApi2McpToolOutputParam)
|
|
95
95
|
};
|
|
96
96
|
};
|
|
97
|
-
/**
|
|
98
|
-
* API to UI (MCP Tool)
|
|
97
|
+
/**
|
|
98
|
+
* API to UI (MCP Tool)
|
|
99
99
|
*/ export const transferMcpToolApi2McpTool = (mcpTool)=>{
|
|
100
100
|
var _mcpTool_input_params, _mcpTool_output_params;
|
|
101
101
|
return _object_spread({
|
|
@@ -107,8 +107,8 @@ import { transferBaseCountParam2BaseCountParamApi, transferIApprovalSettingValue
|
|
|
107
107
|
arguments: mcpTool.arguments
|
|
108
108
|
}, transferIApprovalSettingValueApi2IApprovalSettingValue(mcpTool));
|
|
109
109
|
};
|
|
110
|
-
/**
|
|
111
|
-
* ui转换为接口使用(MCP工具输入参数)
|
|
110
|
+
/**
|
|
111
|
+
* ui转换为接口使用(MCP工具输入参数)
|
|
112
112
|
*/ export const transferMcpToolInputParam2McpToolInputParamApi = (data)=>{
|
|
113
113
|
var _data_children;
|
|
114
114
|
return {
|
|
@@ -119,8 +119,8 @@ import { transferBaseCountParam2BaseCountParamApi, transferIApprovalSettingValue
|
|
|
119
119
|
children: (_data_children = data.children) === null || _data_children === void 0 ? void 0 : _data_children.map(transferMcpToolInputParam2McpToolInputParamApi)
|
|
120
120
|
};
|
|
121
121
|
};
|
|
122
|
-
/**
|
|
123
|
-
* ui转换为接口使用(MCP工具输出参数)
|
|
122
|
+
/**
|
|
123
|
+
* ui转换为接口使用(MCP工具输出参数)
|
|
124
124
|
*/ export const transferMcpToolOutputParam2McpToolOutputParamApi = (data)=>{
|
|
125
125
|
var _data_children;
|
|
126
126
|
return {
|
|
@@ -130,8 +130,8 @@ import { transferBaseCountParam2BaseCountParamApi, transferIApprovalSettingValue
|
|
|
130
130
|
children: (_data_children = data.children) === null || _data_children === void 0 ? void 0 : _data_children.map(transferMcpToolOutputParam2McpToolOutputParamApi)
|
|
131
131
|
};
|
|
132
132
|
};
|
|
133
|
-
/**
|
|
134
|
-
* UI to API (MCP Tool)
|
|
133
|
+
/**
|
|
134
|
+
* UI to API (MCP Tool)
|
|
135
135
|
*/ export const transferMcpTool2McpToolApi = (mcpTool)=>{
|
|
136
136
|
var _mcpTool_inputParams, _mcpTool_outputParams;
|
|
137
137
|
return _object_spread({
|
|
@@ -143,10 +143,10 @@ import { transferBaseCountParam2BaseCountParamApi, transferIApprovalSettingValue
|
|
|
143
143
|
arguments: mcpTool.arguments
|
|
144
144
|
}, transferIApprovalSettingValue2IApprovalSettingValueApi(mcpTool));
|
|
145
145
|
};
|
|
146
|
-
/**
|
|
147
|
-
* 接口转换为ui使用(表单字段)
|
|
148
|
-
* @param data IMcpFormApi
|
|
149
|
-
* @returns IMcpForm
|
|
146
|
+
/**
|
|
147
|
+
* 接口转换为ui使用(表单字段)
|
|
148
|
+
* @param data IMcpFormApi
|
|
149
|
+
* @returns IMcpForm
|
|
150
150
|
*/ export const transferMcpFormApi2McpForm = (data)=>_object_spread_props(_object_spread({}, transferResourceFormCommonApi2ResourceFormCommon(data)), {
|
|
151
151
|
mcpName: data.mcp_name,
|
|
152
152
|
mcpCode: data.mcp_code,
|
|
@@ -157,10 +157,10 @@ import { transferBaseCountParam2BaseCountParamApi, transferIApprovalSettingValue
|
|
|
157
157
|
icon: data.icon,
|
|
158
158
|
userGuide: data.user_guide
|
|
159
159
|
});
|
|
160
|
-
/**
|
|
161
|
-
* 接口转换为ui使用(完整资源)
|
|
162
|
-
* @param data IMcpApi
|
|
163
|
-
* @returns IMcp
|
|
160
|
+
/**
|
|
161
|
+
* 接口转换为ui使用(完整资源)
|
|
162
|
+
* @param data IMcpApi
|
|
163
|
+
* @returns IMcp
|
|
164
164
|
*/ export const transferMcpApi2Mcp = (data)=>{
|
|
165
165
|
var _data_mcp_tools, _data_selected_tools;
|
|
166
166
|
return _object_spread_props(_object_spread({}, transferMcpFormApi2McpForm(data), transferResourceCommonApi2ResourceCommon(data)), {
|
|
@@ -178,10 +178,10 @@ import { transferBaseCountParam2BaseCountParamApi, transferIApprovalSettingValue
|
|
|
178
178
|
favoriteCount: data.favorite_count
|
|
179
179
|
});
|
|
180
180
|
};
|
|
181
|
-
/**
|
|
182
|
-
* ui转换为接口使用(表单字段)
|
|
183
|
-
* @param data IMcpForm
|
|
184
|
-
* @returns IMcpFormApi
|
|
181
|
+
/**
|
|
182
|
+
* ui转换为接口使用(表单字段)
|
|
183
|
+
* @param data IMcpForm
|
|
184
|
+
* @returns IMcpFormApi
|
|
185
185
|
*/ export const transferMcpForm2McpFormApi = (data)=>_object_spread_props(_object_spread({}, transferResourceFormCommon2ResourceFormCommonApi(data)), {
|
|
186
186
|
mcp_name: data.mcpName,
|
|
187
187
|
mcp_code: data.mcpCode,
|
|
@@ -192,10 +192,10 @@ import { transferBaseCountParam2BaseCountParamApi, transferIApprovalSettingValue
|
|
|
192
192
|
icon: data.icon,
|
|
193
193
|
user_guide: data.userGuide
|
|
194
194
|
});
|
|
195
|
-
/**
|
|
196
|
-
* ui转换为接口使用(完整资源)
|
|
197
|
-
* @param data IMcp
|
|
198
|
-
* @returns IMcpApi
|
|
195
|
+
/**
|
|
196
|
+
* ui转换为接口使用(完整资源)
|
|
197
|
+
* @param data IMcp
|
|
198
|
+
* @returns IMcpApi
|
|
199
199
|
*/ export const transferMcp2McpApi = (data)=>{
|
|
200
200
|
var _data_mcpTools, _data_selectedTools;
|
|
201
201
|
return _object_spread_props(_object_spread({}, transferMcpForm2McpFormApi(data), transferResourceCommon2ResourceCommonApi(data)), {
|
|
@@ -212,10 +212,10 @@ import { transferBaseCountParam2BaseCountParamApi, transferIApprovalSettingValue
|
|
|
212
212
|
favorite_count: data.favoriteCount
|
|
213
213
|
});
|
|
214
214
|
};
|
|
215
|
-
/**
|
|
216
|
-
* ui转换为接口使用(注册MCP配置)
|
|
217
|
-
* @param data IRegisterMcpParam
|
|
218
|
-
* @returns IRegisterMcpParamApi
|
|
215
|
+
/**
|
|
216
|
+
* ui转换为接口使用(注册MCP配置)
|
|
217
|
+
* @param data IRegisterMcpParam
|
|
218
|
+
* @returns IRegisterMcpParamApi
|
|
219
219
|
*/ export const transferRegisterMcpParam2RegisterMcpParamApi = (data)=>({
|
|
220
220
|
mcps: data.mcps.map((item)=>({
|
|
221
221
|
mcp_type: item.mcpType,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* 接口转换为ui
|
|
3
|
-
* @param data IResourcePermissionApi
|
|
4
|
-
* @returns IResourcePermission
|
|
1
|
+
/**
|
|
2
|
+
* 接口转换为ui
|
|
3
|
+
* @param data IResourcePermissionApi
|
|
4
|
+
* @returns IResourcePermission
|
|
5
5
|
*/ export const transferResourcePermissionApi2ResourcePermission = (data)=>data ? {
|
|
6
6
|
accessModel: data.access_model,
|
|
7
7
|
accessModelStrategy: data.access_model_strategy,
|
|
@@ -41,10 +41,10 @@
|
|
|
41
41
|
useMcp: data.use_mcp,
|
|
42
42
|
manageProject: data.manage_project
|
|
43
43
|
} : undefined;
|
|
44
|
-
/**
|
|
45
|
-
* ui转换为接口使用
|
|
46
|
-
* @param data IResourcePermission
|
|
47
|
-
* @returns IResourcePermissionApi
|
|
44
|
+
/**
|
|
45
|
+
* ui转换为接口使用
|
|
46
|
+
* @param data IResourcePermission
|
|
47
|
+
* @returns IResourcePermissionApi
|
|
48
48
|
*/ export const transferResourcePermission2ResourcePermissionApi = (data)=>data ? {
|
|
49
49
|
access_model: data.accessModel,
|
|
50
50
|
access_model_strategy: data.accessModelStrategy,
|
|
@@ -84,10 +84,10 @@
|
|
|
84
84
|
use_mcp: data.useMcp,
|
|
85
85
|
manage_project: data.manageProject
|
|
86
86
|
} : undefined;
|
|
87
|
-
/**
|
|
88
|
-
* 接口转换为ui
|
|
89
|
-
* @param data ICheckPermissionApi
|
|
90
|
-
* @returns ICheckPermission
|
|
87
|
+
/**
|
|
88
|
+
* 接口转换为ui
|
|
89
|
+
* @param data ICheckPermissionApi
|
|
90
|
+
* @returns ICheckPermission
|
|
91
91
|
*/ export const transferCheckPermissionApi2CheckPermission = (data)=>data.map((item)=>({
|
|
92
92
|
actionId: item.action_id,
|
|
93
93
|
isAllowed: item.is_allowed
|
|
@@ -51,20 +51,21 @@ function _object_spread_props(target, source) {
|
|
|
51
51
|
return target;
|
|
52
52
|
}
|
|
53
53
|
import { transferBaseCountParam2BaseCountParamApi, transferIPaginationParam2IPaginationParamApi, transferResourceCommonApi2ResourceCommon, transferResourceCommonSearchParams2ResourceCommonSearchParamsApi, transferResourceFormCommonApi2ResourceFormCommon, transferVariableApi2Variable } from './common.ts.js';
|
|
54
|
-
/**
|
|
55
|
-
* 接口转换为ui使用(表单字段)
|
|
56
|
-
* @param data IPromptFormApi
|
|
57
|
-
* @returns IPromptForm
|
|
54
|
+
/**
|
|
55
|
+
* 接口转换为ui使用(表单字段)
|
|
56
|
+
* @param data IPromptFormApi
|
|
57
|
+
* @returns IPromptForm
|
|
58
58
|
*/ export const transferPromptFormApi2PromptForm = (data)=>_object_spread_props(_object_spread({}, transferResourceFormCommonApi2ResourceFormCommon(data)), {
|
|
59
59
|
name: data.prompt_name,
|
|
60
60
|
code: data.prompt_code,
|
|
61
|
+
icon: data.icon,
|
|
61
62
|
content: data.content,
|
|
62
63
|
variables: data.variables.map(transferVariableApi2Variable)
|
|
63
64
|
});
|
|
64
|
-
/**
|
|
65
|
-
* 接口转换为ui使用(完整资源)
|
|
66
|
-
* @param data IPromptApi
|
|
67
|
-
* @returns IPrompt
|
|
65
|
+
/**
|
|
66
|
+
* 接口转换为ui使用(完整资源)
|
|
67
|
+
* @param data IPromptApi
|
|
68
|
+
* @returns IPrompt
|
|
68
69
|
*/ export const transferPromptApi2Prompt = (data)=>{
|
|
69
70
|
var _data_prompt_id, _data_likes;
|
|
70
71
|
return _object_spread_props(_object_spread({}, transferPromptFormApi2PromptForm(data), transferResourceCommonApi2ResourceCommon(data)), {
|
|
@@ -74,10 +75,10 @@ import { transferBaseCountParam2BaseCountParamApi, transferIPaginationParam2IPag
|
|
|
74
75
|
usedCount: data.used_count
|
|
75
76
|
});
|
|
76
77
|
};
|
|
77
|
-
/**
|
|
78
|
-
* ui转换为接口使用
|
|
79
|
-
* @param data IPromptsParams
|
|
80
|
-
* @returns IPromptsApiParams
|
|
78
|
+
/**
|
|
79
|
+
* ui转换为接口使用
|
|
80
|
+
* @param data IPromptsParams
|
|
81
|
+
* @returns IPromptsApiParams
|
|
81
82
|
*/ export const transferPromptParam2PromptParamApi = (data)=>{
|
|
82
83
|
return _object_spread_props(_object_spread({}, transferResourceCommonSearchParams2ResourceCommonSearchParamsApi(data), transferIPaginationParam2IPaginationParamApi(data)), {
|
|
83
84
|
fuzzy: data.fuzzy,
|
|
@@ -51,10 +51,10 @@ function _object_spread_props(target, source) {
|
|
|
51
51
|
return target;
|
|
52
52
|
}
|
|
53
53
|
import { transferIPaginationParam2IPaginationParamApi, transferISortParam2ISortParamApi, transferResourceCommon2ResourceCommonApi, transferResourceCommonApi2ResourceCommon, transferResourceCommonSearchParams2ResourceCommonSearchParamsApi, transferResourceFormCommon2ResourceFormCommonApi, transferResourceFormCommonApi2ResourceFormCommon } from './common.ts.js';
|
|
54
|
-
/**
|
|
55
|
-
* ui转换为接口使用(表单字段)
|
|
56
|
-
* @param data ISkillForm
|
|
57
|
-
* @returns ISkillFormApi
|
|
54
|
+
/**
|
|
55
|
+
* ui转换为接口使用(表单字段)
|
|
56
|
+
* @param data ISkillForm
|
|
57
|
+
* @returns ISkillFormApi
|
|
58
58
|
*/ export const transferSkillForm2SkillFormApi = (data)=>_object_spread_props(_object_spread({}, transferResourceFormCommon2ResourceFormCommonApi(data)), {
|
|
59
59
|
skill_name: data.skillName,
|
|
60
60
|
skill_code: data.skillCode,
|
|
@@ -65,10 +65,10 @@ import { transferIPaginationParam2IPaginationParamApi, transferISortParam2ISortP
|
|
|
65
65
|
file_type: data.fileType,
|
|
66
66
|
version: data.version
|
|
67
67
|
});
|
|
68
|
-
/**
|
|
69
|
-
* 接口转换为ui使用(表单字段)
|
|
70
|
-
* @param data ISkillFormApi
|
|
71
|
-
* @returns ISkillForm
|
|
68
|
+
/**
|
|
69
|
+
* 接口转换为ui使用(表单字段)
|
|
70
|
+
* @param data ISkillFormApi
|
|
71
|
+
* @returns ISkillForm
|
|
72
72
|
*/ export const transferSkillFormApi2SkillForm = (data)=>_object_spread_props(_object_spread({}, transferResourceFormCommonApi2ResourceFormCommon(data)), {
|
|
73
73
|
skillName: data.skill_name,
|
|
74
74
|
skillCode: data.skill_code,
|
|
@@ -79,10 +79,10 @@ import { transferIPaginationParam2IPaginationParamApi, transferISortParam2ISortP
|
|
|
79
79
|
fileType: data.file_type,
|
|
80
80
|
version: data.version
|
|
81
81
|
});
|
|
82
|
-
/**
|
|
83
|
-
* 接口转换为ui使用(完整资源)
|
|
84
|
-
* @param data ISkillApi
|
|
85
|
-
* @returns ISkill
|
|
82
|
+
/**
|
|
83
|
+
* 接口转换为ui使用(完整资源)
|
|
84
|
+
* @param data ISkillApi
|
|
85
|
+
* @returns ISkill
|
|
86
86
|
*/ export const transferSkillApi2Skill = (data)=>{
|
|
87
87
|
var _data_bkai_dependencies;
|
|
88
88
|
return _object_spread_props(_object_spread({}, transferSkillFormApi2SkillForm(data), transferResourceCommonApi2ResourceCommon(data)), {
|
|
@@ -106,10 +106,10 @@ import { transferIPaginationParam2IPaginationParamApi, transferISortParam2ISortP
|
|
|
106
106
|
envs: data.envs
|
|
107
107
|
});
|
|
108
108
|
};
|
|
109
|
-
/**
|
|
110
|
-
* ui转换为接口使用(完整资源)
|
|
111
|
-
* @param data ISkill
|
|
112
|
-
* @returns ISkillApi
|
|
109
|
+
/**
|
|
110
|
+
* ui转换为接口使用(完整资源)
|
|
111
|
+
* @param data ISkill
|
|
112
|
+
* @returns ISkillApi
|
|
113
113
|
*/ export const transferSkill2SkillApi = (data)=>{
|
|
114
114
|
var _data_bkaiDependencies;
|
|
115
115
|
return _object_spread_props(_object_spread({}, transferSkillForm2SkillFormApi(data), transferResourceCommon2ResourceCommonApi(data)), {
|
|
@@ -140,10 +140,10 @@ export const transferSkillCount2SkillCountApi = (data)=>{
|
|
|
140
140
|
created_by: data.createdBy
|
|
141
141
|
};
|
|
142
142
|
};
|
|
143
|
-
/**
|
|
144
|
-
* 接口转换为ui使用(构建日志)
|
|
145
|
-
* @param data ISkillBuildLogApi
|
|
146
|
-
* @returns ISkillBuildLog
|
|
143
|
+
/**
|
|
144
|
+
* 接口转换为ui使用(构建日志)
|
|
145
|
+
* @param data ISkillBuildLogApi
|
|
146
|
+
* @returns ISkillBuildLog
|
|
147
147
|
*/ export const transferSkillBuildLogApi2SkillBuildLog = (data)=>({
|
|
148
148
|
status: data.status,
|
|
149
149
|
buildLogs: data.build_logs,
|
|
@@ -151,10 +151,10 @@ export const transferSkillCount2SkillCountApi = (data)=>{
|
|
|
151
151
|
startedAt: data.started_at,
|
|
152
152
|
completedAt: data.completed_at
|
|
153
153
|
});
|
|
154
|
-
/**
|
|
155
|
-
* ui转换为接口使用
|
|
156
|
-
* @param data ISkillListParam
|
|
157
|
-
* @returns ISkillListParamApi
|
|
154
|
+
/**
|
|
155
|
+
* ui转换为接口使用
|
|
156
|
+
* @param data ISkillListParam
|
|
157
|
+
* @returns ISkillListParamApi
|
|
158
158
|
*/ export const transferSkillParam2SkillParamApi = (data)=>_object_spread_props(_object_spread({}, transferResourceCommonSearchParams2ResourceCommonSearchParamsApi(data), transferISortParam2ISortParamApi(data), transferIPaginationParam2IPaginationParamApi(data)), {
|
|
159
159
|
generate_type: data.generateType,
|
|
160
160
|
fuzzy: data.fuzzy,
|
|
@@ -1,42 +1,42 @@
|
|
|
1
1
|
import { transferResourcePermissionApi2ResourcePermission } from './permission.ts.js';
|
|
2
|
-
/**
|
|
3
|
-
* ui转换为接口
|
|
4
|
-
* @param data IResourcesRemoveApplication
|
|
5
|
-
* @returns IResourcesRemoveApplicationApi
|
|
2
|
+
/**
|
|
3
|
+
* ui转换为接口
|
|
4
|
+
* @param data IResourcesRemoveApplication
|
|
5
|
+
* @returns IResourcesRemoveApplicationApi
|
|
6
6
|
*/ export const transferResourcesRemoveApplication2ResourcesRemoveApplicationApi = (n)=>({
|
|
7
7
|
resource_type: n.resourceType,
|
|
8
8
|
resource_id: n.resourceId
|
|
9
9
|
});
|
|
10
|
-
/**
|
|
11
|
-
* ui转换为接口
|
|
12
|
-
* @param data IResourcesRevokeApplication
|
|
13
|
-
* @returns IResourcesRevokeApplicationApi
|
|
10
|
+
/**
|
|
11
|
+
* ui转换为接口
|
|
12
|
+
* @param data IResourcesRevokeApplication
|
|
13
|
+
* @returns IResourcesRevokeApplicationApi
|
|
14
14
|
*/ export const transferResourcesRevokeApplication2ResourcesRevokeApplicationApi = (n)=>({
|
|
15
15
|
resource_type: n.resourceType,
|
|
16
16
|
resource_id: n.resourceId
|
|
17
17
|
});
|
|
18
|
-
/**
|
|
19
|
-
* ui转换为接口
|
|
20
|
-
* @param data IUsableSpaceParam
|
|
21
|
-
* @returns IUsableSpaceParamApi
|
|
18
|
+
/**
|
|
19
|
+
* ui转换为接口
|
|
20
|
+
* @param data IUsableSpaceParam
|
|
21
|
+
* @returns IUsableSpaceParamApi
|
|
22
22
|
*/ export const transferUsableSpaceParam2UsableSpaceParamApi = (data)=>({
|
|
23
23
|
resource_type: data.resourceType,
|
|
24
24
|
can_apply: data.canApply,
|
|
25
25
|
space_name: data.spaceName
|
|
26
26
|
});
|
|
27
|
-
/**
|
|
28
|
-
* 接口转换为ui
|
|
29
|
-
* @param data IUsableSpaceApi
|
|
30
|
-
* @returns IUsableSpace
|
|
27
|
+
/**
|
|
28
|
+
* 接口转换为ui
|
|
29
|
+
* @param data IUsableSpaceApi
|
|
30
|
+
* @returns IUsableSpace
|
|
31
31
|
*/ export const transferUsableSpaceApi2UsableSpace = (data)=>({
|
|
32
32
|
spaceId: data.space_id,
|
|
33
33
|
spaceCode: data.space_code,
|
|
34
34
|
spaceName: data.space_name
|
|
35
35
|
});
|
|
36
|
-
/**
|
|
37
|
-
* 接口转换为ui
|
|
38
|
-
* @param data ISpaceApi
|
|
39
|
-
* @returns ISpace
|
|
36
|
+
/**
|
|
37
|
+
* 接口转换为ui
|
|
38
|
+
* @param data ISpaceApi
|
|
39
|
+
* @returns ISpace
|
|
40
40
|
*/ export const transferSpaceApi2Space = (data)=>({
|
|
41
41
|
spaceId: data.space_id,
|
|
42
42
|
spaceName: data.space_name,
|
|
@@ -47,10 +47,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
47
47
|
iamGradeManagerMembers: data.iam_grade_manager_members,
|
|
48
48
|
permission: transferResourcePermissionApi2ResourcePermission(data.permission)
|
|
49
49
|
});
|
|
50
|
-
/**
|
|
51
|
-
* ui转换为接口
|
|
52
|
-
* @param data IResourceAuthorizedSpacesParam
|
|
53
|
-
* @returns IResourceAuthorizedSpacesParamApi
|
|
50
|
+
/**
|
|
51
|
+
* ui转换为接口
|
|
52
|
+
* @param data IResourceAuthorizedSpacesParam
|
|
53
|
+
* @returns IResourceAuthorizedSpacesParamApi
|
|
54
54
|
*/ export const transferResourceAuthorizedSpacesParam2ResourceAuthorizedSpacesParamApi = (data)=>({
|
|
55
55
|
resource_type: data.resourceType,
|
|
56
56
|
resource_id: data.resourceId,
|
|
@@ -51,13 +51,14 @@ function _object_spread_props(target, source) {
|
|
|
51
51
|
return target;
|
|
52
52
|
}
|
|
53
53
|
import { transferBaseCountParam2BaseCountParamApi, transferIApprovalSettingValue2IApprovalSettingValueApi, transferIApprovalSettingValueApi2IApprovalSettingValue, transferIPaginationParam2IPaginationParamApi, transferISortParam2ISortParamApi, transferResourceCommon2ResourceCommonApi, transferResourceCommonApi2ResourceCommon, transferResourceCommonSearchParams2ResourceCommonSearchParamsApi, transferResourceFormCommon2ResourceFormCommonApi, transferResourceFormCommonApi2ResourceFormCommon } from './common.ts.js';
|
|
54
|
-
/**
|
|
55
|
-
* ui转换为接口使用(表单字段)
|
|
56
|
-
* @param data IToolForm
|
|
57
|
-
* @returns IToolFormApi
|
|
54
|
+
/**
|
|
55
|
+
* ui转换为接口使用(表单字段)
|
|
56
|
+
* @param data IToolForm
|
|
57
|
+
* @returns IToolFormApi
|
|
58
58
|
*/ export const transferToolForm2ToolFormApi = (data)=>_object_spread_props(_object_spread({}, transferResourceFormCommon2ResourceFormCommonApi(data)), {
|
|
59
59
|
tool_name: data.toolName,
|
|
60
60
|
tool_code: data.toolCode,
|
|
61
|
+
icon: data.icon,
|
|
61
62
|
method: data.method,
|
|
62
63
|
url: data.url,
|
|
63
64
|
property: {
|
|
@@ -70,13 +71,14 @@ import { transferBaseCountParam2BaseCountParamApi, transferIApprovalSettingValue
|
|
|
70
71
|
credential_id: data.credentialId,
|
|
71
72
|
credential_type: data.credentialType
|
|
72
73
|
});
|
|
73
|
-
/**
|
|
74
|
-
* 接口转换为ui使用(表单字段)
|
|
75
|
-
* @param data IToolFormApi
|
|
76
|
-
* @returns IToolForm
|
|
74
|
+
/**
|
|
75
|
+
* 接口转换为ui使用(表单字段)
|
|
76
|
+
* @param data IToolFormApi
|
|
77
|
+
* @returns IToolForm
|
|
77
78
|
*/ export const transferToolFormApi2ToolForm = (data)=>_object_spread_props(_object_spread({}, transferResourceFormCommonApi2ResourceFormCommon(data)), {
|
|
78
79
|
toolName: data.tool_name,
|
|
79
80
|
toolCode: data.tool_code,
|
|
81
|
+
icon: data.icon,
|
|
80
82
|
method: data.method,
|
|
81
83
|
url: data.url,
|
|
82
84
|
header: data.property.header,
|
|
@@ -87,10 +89,10 @@ import { transferBaseCountParam2BaseCountParamApi, transferIApprovalSettingValue
|
|
|
87
89
|
credentialId: data.credential_id,
|
|
88
90
|
credentialType: data.credential_type
|
|
89
91
|
});
|
|
90
|
-
/**
|
|
91
|
-
* 接口转换为ui使用(完整资源)
|
|
92
|
-
* @param data IToolApi
|
|
93
|
-
* @returns ITool
|
|
92
|
+
/**
|
|
93
|
+
* 接口转换为ui使用(完整资源)
|
|
94
|
+
* @param data IToolApi
|
|
95
|
+
* @returns ITool
|
|
94
96
|
*/ export const transferToolApi2Tool = (data)=>_object_spread_props(_object_spread({}, transferToolFormApi2ToolForm(data), transferResourceCommonApi2ResourceCommon(_object_spread_props(_object_spread({}, data), {
|
|
95
97
|
id: data.tool_id
|
|
96
98
|
})), transferIApprovalSettingValueApi2IApprovalSettingValue(data)), {
|
|
@@ -99,19 +101,19 @@ import { transferBaseCountParam2BaseCountParamApi, transferIApprovalSettingValue
|
|
|
99
101
|
favorite: data.favorite,
|
|
100
102
|
favoriteCount: data.favorite_count
|
|
101
103
|
});
|
|
102
|
-
/**
|
|
103
|
-
* ui转换为接口使用(完整资源)
|
|
104
|
-
* @param data ITool
|
|
105
|
-
* @returns IToolApi
|
|
104
|
+
/**
|
|
105
|
+
* ui转换为接口使用(完整资源)
|
|
106
|
+
* @param data ITool
|
|
107
|
+
* @returns IToolApi
|
|
106
108
|
*/ export const transferTool2ToolApi = (data)=>_object_spread_props(_object_spread({}, transferToolForm2ToolFormApi(data), transferResourceCommon2ResourceCommonApi(data), transferIApprovalSettingValue2IApprovalSettingValueApi(data)), {
|
|
107
109
|
tool_id: data.id,
|
|
108
110
|
favorite: data.favorite,
|
|
109
111
|
favorite_count: data.favoriteCount
|
|
110
112
|
});
|
|
111
|
-
/**
|
|
112
|
-
* ui转换为接口使用
|
|
113
|
-
* @param data IToolsParam
|
|
114
|
-
* @returns IToolsApiParam
|
|
113
|
+
/**
|
|
114
|
+
* ui转换为接口使用
|
|
115
|
+
* @param data IToolsParam
|
|
116
|
+
* @returns IToolsApiParam
|
|
115
117
|
*/ export const transferToolsParam2ToolsParamApi = (data)=>{
|
|
116
118
|
return _object_spread_props(_object_spread({}, transferResourceCommonSearchParams2ResourceCommonSearchParamsApi(data), transferISortParam2ISortParamApi(data), transferIPaginationParam2IPaginationParamApi(data)), {
|
|
117
119
|
fuzzy: data.fuzzy,
|