@blueking/ai-ui-sdk 0.4.3-beta.10 → 0.4.3-beta.13
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-card/agent/actions.script.vue.js.js → render-agent/action/index.script.vue.js.js} +33 -9
- package/dist/components/{render-card/agent/actions.vue.d.ts → render-agent/action/index.vue.d.ts} +1 -0
- package/dist/components/render-agent/action/index.vue.js +3 -0
- package/dist/components/render-agent/agent-download.vue.css +2 -2
- package/dist/components/render-agent/agent-share.script.vue.js.js +8 -5
- package/dist/components/render-agent/agent-share.vue.d.ts +1 -0
- package/dist/components/render-agent/agent-type.script.vue.js.js +3 -9
- package/dist/components/render-agent/agent-type.vue.css +9 -13
- package/dist/components/render-agent/agent-type.vue.d.ts +1 -1
- package/dist/components/render-agent/agent-type.vue.js +1 -1
- package/dist/components/render-auth/auth-dialog.script.vue.js.js +6 -3
- 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.script.vue.js.js +55 -22
- package/dist/components/render-card/agent/index.vue.d.ts +4 -2
- 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/application-base-actions.script.vue.js.js +1 -1
- package/dist/components/render-card/base/collection-icon.script.vue.js.js +149 -0
- package/dist/components/render-card/base/collection-icon.vue.d.ts +20 -0
- package/dist/components/render-card/base/collection-icon.vue.js +3 -0
- 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/actions.script.vue.js.js +15 -3
- package/dist/components/render-card/llm/actions.vue.d.ts +1 -0
- 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.script.vue.js.js +9 -8
- 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.script.vue.js.js +18 -14
- package/dist/components/render-card/llm/tag-prefix.vue.css +5 -8
- package/dist/components/render-card/llm/tag-prefix.vue.d.ts +4 -1
- package/dist/components/render-card/llm/tag-prefix.vue.js +1 -1
- package/dist/components/render-card/mcp/actions.script.vue.js.js +35 -7
- package/dist/components/render-card/mcp/actions.vue.d.ts +1 -0
- package/dist/components/render-card/mcp/index.script.vue.js.js +35 -9
- package/dist/components/render-card/mcp/index.vue.d.ts +5 -4
- 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.script.vue.js.js +3 -7
- package/dist/components/render-card/mcp/selected-tools-info.vue.d.ts +1 -2
- 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 +48 -14
- package/dist/components/render-card/prompt/index.vue.d.ts +4 -2
- package/dist/components/render-card/role/index.script.vue.js.js +53 -20
- package/dist/components/render-card/role/index.vue.d.ts +4 -2
- package/dist/components/render-card/skill/index.script.vue.js.js +58 -24
- package/dist/components/render-card/skill/index.vue.d.ts +8 -4
- package/dist/components/render-card/skill/scanner.script.vue.js.js +66 -0
- package/dist/components/render-card/skill/{tag-prefix.vue.css → scanner.vue.css} +7 -7
- package/dist/components/render-card/skill/scanner.vue.d.ts +11 -0
- package/dist/components/render-card/skill/scanner.vue.js +5 -0
- package/dist/components/render-card/skill/tag-prefix.script.vue.js.js +11 -50
- package/dist/components/render-card/skill/tag-prefix.vue.js +0 -2
- package/dist/components/render-card/tool/actions.script.vue.js.js +26 -4
- package/dist/components/render-card/tool/actions.vue.d.ts +1 -0
- package/dist/components/render-card/tool/index.script.vue.js.js +53 -20
- package/dist/components/render-card/tool/index.vue.d.ts +4 -2
- 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/actions/index.script.vue.js.js +22 -4
- package/dist/components/render-collection/actions/index.vue.d.ts +1 -0
- 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 -18
- package/dist/components/render-dropdown/index.vue.d.ts +5 -5
- 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.d.ts +1 -1
- 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.d.ts +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.d.ts +1 -1
- 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/actions/index.script.vue.js.js +22 -4
- package/dist/components/render-prompt/actions/index.vue.d.ts +1 -0
- 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-relate-agent/index.script.vue.js +8 -6
- package/dist/components/render-relate-agent/index.vue.d.ts +2 -2
- package/dist/components/render-resource-version/index.script.vue.js.js +6 -3
- package/dist/components/render-resource-version/index.vue.css +7 -7
- package/dist/components/render-resource-version/index.vue.d.ts +1 -1
- 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 +3 -2
- 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-skill/actions/index.script.vue.js.js +38 -7
- package/dist/components/render-skill/actions/index.vue.d.ts +3 -2
- package/dist/components/render-t-table/index.script.vue.js +32 -12
- 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.script.vue.js +6 -6
- package/dist/components/render-tags/index.vue.css +12 -12
- package/dist/components/render-tags/index.vue.d.ts +1 -1
- 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/components.d.ts +15 -1
- package/dist/components.ts.js +15 -1
- package/dist/css/fonts/iconcool.svg +268 -268
- package/dist/css/g-utilities.css +39 -16
- package/dist/css/g-utilities.manifest.json +7 -0
- package/dist/css/style.css +259 -259
- package/dist/hooks/use-agent-http.d.ts +2 -0
- package/dist/hooks/use-agent-http.ts.js +15 -1
- package/dist/hooks/use-collection-http.d.ts +2 -0
- package/dist/hooks/use-collection-http.ts.js +15 -1
- package/dist/hooks/use-ellipsis-tooltip.ts.js +28 -28
- package/dist/hooks/use-loading-version.ts.js +4 -4
- package/dist/hooks/use-market-http.d.ts +10 -0
- package/dist/hooks/use-market-http.ts.js +71 -1
- package/dist/hooks/use-mcp-http.d.ts +2 -0
- package/dist/hooks/use-mcp-http.ts.js +15 -1
- package/dist/hooks/use-prompt-http.d.ts +2 -0
- package/dist/hooks/use-prompt-http.ts.js +15 -1
- package/dist/hooks/use-skill-http.d.ts +2 -0
- package/dist/hooks/use-skill-http.ts.js +15 -1
- package/dist/hooks/use-t-table.d.ts +11 -5
- package/dist/hooks/use-t-table.ts.js +25 -3
- package/dist/hooks/use-tool-http.d.ts +2 -0
- package/dist/hooks/use-tool-http.ts.js +15 -1
- package/dist/http/helper/agent.ts.js +46 -47
- package/dist/http/helper/collection.ts.js +14 -13
- package/dist/http/helper/common.d.ts +1 -1
- package/dist/http/helper/common.ts.js +48 -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 +42 -38
- package/dist/http/helper/permission.ts.js +12 -12
- package/dist/http/helper/prompt.ts.js +14 -13
- package/dist/http/helper/skill.ts.js +28 -24
- package/dist/http/helper/space.ts.js +24 -24
- package/dist/http/helper/tool.ts.js +26 -22
- package/dist/types/agent.d.ts +3 -3
- package/dist/types/collection.d.ts +3 -1
- package/dist/types/common.d.ts +4 -0
- package/dist/types/enum.d.ts +5 -7
- package/dist/types/enum.ts.js +3 -6
- package/dist/types/mcp.d.ts +4 -0
- package/dist/types/prompt.d.ts +3 -1
- package/dist/types/skill.d.ts +4 -0
- package/dist/types/tool.d.ts +4 -0
- package/package.json +112 -112
- package/dist/components/render-card/agent/actions.vue.js +0 -3
|
@@ -55,10 +55,10 @@ import { transferKnowledge, transferKnowledgeApi, transferKnowledgebase, transfe
|
|
|
55
55
|
import { transferMcp2McpApi, transferMcpApi2Mcp } from './mcp.ts.js';
|
|
56
56
|
import { transferSkill2SkillApi, transferSkillApi2Skill } from './skill.ts.js';
|
|
57
57
|
import { transferTool2ToolApi, transferToolApi2Tool } from './tool.ts.js';
|
|
58
|
-
/**
|
|
59
|
-
* 接口转换为ui使用
|
|
60
|
-
* @param data IAgentCommandApi
|
|
61
|
-
* @returns IAgentCommand
|
|
58
|
+
/**
|
|
59
|
+
* 接口转换为ui使用
|
|
60
|
+
* @param data IAgentCommandApi
|
|
61
|
+
* @returns IAgentCommand
|
|
62
62
|
*/ export const transferAgentCommandApi2AgentCommand = (data)=>{
|
|
63
63
|
return {
|
|
64
64
|
id: data.id,
|
|
@@ -93,10 +93,10 @@ import { transferTool2ToolApi, transferToolApi2Tool } from './tool.ts.js';
|
|
|
93
93
|
}))
|
|
94
94
|
};
|
|
95
95
|
};
|
|
96
|
-
/**
|
|
97
|
-
* ui转换为接口使用
|
|
98
|
-
* @param data IAgentCommand
|
|
99
|
-
* @returns IAgentCommandApi
|
|
96
|
+
/**
|
|
97
|
+
* ui转换为接口使用
|
|
98
|
+
* @param data IAgentCommand
|
|
99
|
+
* @returns IAgentCommandApi
|
|
100
100
|
*/ export const transferAgentCommand2AgentCommandApi = (data)=>{
|
|
101
101
|
const result = {
|
|
102
102
|
id: data.id,
|
|
@@ -132,10 +132,10 @@ import { transferTool2ToolApi, transferToolApi2Tool } from './tool.ts.js';
|
|
|
132
132
|
};
|
|
133
133
|
return result;
|
|
134
134
|
};
|
|
135
|
-
/**
|
|
136
|
-
* ui转换为接口使用(表单字段)
|
|
137
|
-
* @param data IAgentForm
|
|
138
|
-
* @returns IAgentFormApi
|
|
135
|
+
/**
|
|
136
|
+
* ui转换为接口使用(表单字段)
|
|
137
|
+
* @param data IAgentForm
|
|
138
|
+
* @returns IAgentFormApi
|
|
139
139
|
*/ export const transferAgentForm2AgentFormApi = (data)=>{
|
|
140
140
|
var _data_conversationSettings, _data_conversationSettings1, _data_conversationSettings_commands, _data_conversationSettings2, _data_conversationSettings3, _data_conversationSettings4, _data_promptSetting_collectionVariables, _data_relatedTools_tools, _data_relatedTools_mcps, _data_approvalSettings;
|
|
141
141
|
var _data_conversationSettings_openingRemark, _data_conversationSettings_predefinedQuestions;
|
|
@@ -144,7 +144,6 @@ import { transferTool2ToolApi, transferToolApi2Tool } from './tool.ts.js';
|
|
|
144
144
|
agent_name: data.agentName,
|
|
145
145
|
icon: data.icon,
|
|
146
146
|
agent_type: data.agentType,
|
|
147
|
-
craw_type: data.crawType,
|
|
148
147
|
user_guide: data.userGuide,
|
|
149
148
|
is_bind_bk_saas: data.isBindBkSaas,
|
|
150
149
|
deploy_mode: data.deployMode,
|
|
@@ -199,10 +198,10 @@ import { transferTool2ToolApi, transferToolApi2Tool } from './tool.ts.js';
|
|
|
199
198
|
business_ids: data.businessIds
|
|
200
199
|
});
|
|
201
200
|
};
|
|
202
|
-
/**
|
|
203
|
-
* 接口转换为ui使用(表单字段)
|
|
204
|
-
* @param data IAgentFormApi
|
|
205
|
-
* @returns IAgentForm
|
|
201
|
+
/**
|
|
202
|
+
* 接口转换为ui使用(表单字段)
|
|
203
|
+
* @param data IAgentFormApi
|
|
204
|
+
* @returns IAgentForm
|
|
206
205
|
*/ export const transferAgentFormApi2AgentForm = (data)=>{
|
|
207
206
|
var _data_conversation_settings, _data_conversation_settings1, _data_conversation_settings_commands, _data_conversation_settings2, _data_conversation_settings3, _data_conversation_settings4, _data_prompt_setting_collection_variables, _data_related_tools_tools, _data_related_tools_mcps, _data_related_skills_skills, _data_approval_settings;
|
|
208
207
|
var _data_conversation_settings_opening_remark, _data_conversation_settings_predefined_questions;
|
|
@@ -211,7 +210,6 @@ import { transferTool2ToolApi, transferToolApi2Tool } from './tool.ts.js';
|
|
|
211
210
|
agentName: data.agent_name,
|
|
212
211
|
icon: data.icon,
|
|
213
212
|
agentType: data.agent_type,
|
|
214
|
-
crawType: data.craw_type,
|
|
215
213
|
userGuide: data.user_guide,
|
|
216
214
|
isBindBkSaas: data.is_bind_bk_saas,
|
|
217
215
|
deployMode: data.deploy_mode,
|
|
@@ -266,10 +264,10 @@ import { transferTool2ToolApi, transferToolApi2Tool } from './tool.ts.js';
|
|
|
266
264
|
businessIds: data.business_ids
|
|
267
265
|
});
|
|
268
266
|
};
|
|
269
|
-
/**
|
|
270
|
-
* 接口转换为ui使用(完整资源)
|
|
271
|
-
* @param data IAgentApi
|
|
272
|
-
* @returns IAgent
|
|
267
|
+
/**
|
|
268
|
+
* 接口转换为ui使用(完整资源)
|
|
269
|
+
* @param data IAgentApi
|
|
270
|
+
* @returns IAgent
|
|
273
271
|
*/ export const transferAgentApi2Agent = (data)=>_object_spread_props(_object_spread({}, transferAgentFormApi2AgentForm(data), transferResourceCommonApi2ResourceCommon(data)), {
|
|
274
272
|
version: data.version,
|
|
275
273
|
latestVersion: data.latest_version,
|
|
@@ -291,10 +289,10 @@ import { transferTool2ToolApi, transferToolApi2Tool } from './tool.ts.js';
|
|
|
291
289
|
observability: data.paasv3_pages.observability
|
|
292
290
|
} : undefined
|
|
293
291
|
});
|
|
294
|
-
/**
|
|
295
|
-
* ui转换为接口使用(完整资源)
|
|
296
|
-
* @param data IAgent
|
|
297
|
-
* @returns IAgentApi
|
|
292
|
+
/**
|
|
293
|
+
* ui转换为接口使用(完整资源)
|
|
294
|
+
* @param data IAgent
|
|
295
|
+
* @returns IAgentApi
|
|
298
296
|
*/ export const transferAgent2AgentApi = (data)=>_object_spread_props(_object_spread({}, transferAgentForm2AgentFormApi(data), transferResourceCommon2ResourceCommonApi(data)), {
|
|
299
297
|
version: data.version,
|
|
300
298
|
latest_version: data.latestVersion,
|
|
@@ -315,10 +313,10 @@ import { transferTool2ToolApi, transferToolApi2Tool } from './tool.ts.js';
|
|
|
315
313
|
observability: data.paasv3Pages.observability
|
|
316
314
|
} : undefined
|
|
317
315
|
});
|
|
318
|
-
/**
|
|
319
|
-
* ui 转换为接口使用
|
|
320
|
-
* @param data IAgentListParam
|
|
321
|
-
* @returns IAgentListParamApi
|
|
316
|
+
/**
|
|
317
|
+
* ui 转换为接口使用
|
|
318
|
+
* @param data IAgentListParam
|
|
319
|
+
* @returns IAgentListParamApi
|
|
322
320
|
*/ export const transferAgentListParam2AgentListParamApi = (data)=>_object_spread_props(_object_spread({}, transferResourceCommonSearchParams2ResourceCommonSearchParamsApi(data), transferISortParam2ISortParamApi(data), transferIPaginationParam2IPaginationParamApi(data)), {
|
|
323
321
|
agent_type: data.agentType,
|
|
324
322
|
fuzzy: data.fuzzy,
|
|
@@ -333,12 +331,13 @@ import { transferTool2ToolApi, transferToolApi2Tool } from './tool.ts.js';
|
|
|
333
331
|
description: data.description,
|
|
334
332
|
updated_by: data.updatedBy,
|
|
335
333
|
created_by: data.createdBy,
|
|
336
|
-
agent_version: data.agentVersion
|
|
334
|
+
agent_version: data.agentVersion,
|
|
335
|
+
group_type: data.groupType
|
|
337
336
|
});
|
|
338
|
-
/**
|
|
339
|
-
* ui转换为接口使用
|
|
340
|
-
* @param data IResourceApply[]
|
|
341
|
-
* @returns IResourceApplyApi[]
|
|
337
|
+
/**
|
|
338
|
+
* ui转换为接口使用
|
|
339
|
+
* @param data IResourceApply[]
|
|
340
|
+
* @returns IResourceApplyApi[]
|
|
342
341
|
*/ export const transferResourceApply2ResourceApplyApi = (data)=>data.map((item)=>({
|
|
343
342
|
resource_type: item.resourceType,
|
|
344
343
|
resource_code: item.resourceCode
|
|
@@ -355,10 +354,10 @@ export const transferAgentCount2AgentCountApi = (data)=>{
|
|
|
355
354
|
is_published: data.isPublished
|
|
356
355
|
});
|
|
357
356
|
};
|
|
358
|
-
/**
|
|
359
|
-
* 接口转换为ui使用
|
|
360
|
-
* @param data IAgentApigwMcpPermissionApi
|
|
361
|
-
* @returns IAgentApigwMcpPermission
|
|
357
|
+
/**
|
|
358
|
+
* 接口转换为ui使用
|
|
359
|
+
* @param data IAgentApigwMcpPermissionApi
|
|
360
|
+
* @returns IAgentApigwMcpPermission
|
|
362
361
|
*/ export const transferAgentApigwMcpPermissionApi2AgentApigwMcpPermission = (data)=>({
|
|
363
362
|
status: data.status,
|
|
364
363
|
hasPermission: data.has_permission,
|
|
@@ -367,20 +366,20 @@ export const transferAgentCount2AgentCountApi = (data)=>{
|
|
|
367
366
|
url: data.url,
|
|
368
367
|
protocolType: data.protocol_type
|
|
369
368
|
});
|
|
370
|
-
/**
|
|
371
|
-
* ui转换为接口使用(配置审批)
|
|
372
|
-
* @param data IApprovalSetting,
|
|
373
|
-
* @returns IApprovalSettingApi
|
|
369
|
+
/**
|
|
370
|
+
* ui转换为接口使用(配置审批)
|
|
371
|
+
* @param data IApprovalSetting,
|
|
372
|
+
* @returns IApprovalSettingApi
|
|
374
373
|
*/ export const transferIApprovalSetting2IApprovalSettingApi = (data)=>({
|
|
375
374
|
strategy_id: data.strategyId,
|
|
376
375
|
approval_name: data.approvalName,
|
|
377
376
|
approvers: data.approvers,
|
|
378
377
|
is_default: data.isDefault
|
|
379
378
|
});
|
|
380
|
-
/**
|
|
381
|
-
* 接口转换为ui使用(配置审批)
|
|
382
|
-
* @param data IApprovalSettingApi
|
|
383
|
-
* @returns IApprovalSetting
|
|
379
|
+
/**
|
|
380
|
+
* 接口转换为ui使用(配置审批)
|
|
381
|
+
* @param data IApprovalSettingApi
|
|
382
|
+
* @returns IApprovalSetting
|
|
384
383
|
*/ export const transferIApprovalSettingApi2IApprovalSetting = (data)=>({
|
|
385
384
|
strategyId: data.strategy_id,
|
|
386
385
|
approvalName: data.approval_name,
|
|
@@ -51,10 +51,10 @@ function _object_spread_props(target, source) {
|
|
|
51
51
|
return target;
|
|
52
52
|
}
|
|
53
53
|
import { transferBaseCountParam2BaseCountParamApi, transferIPaginationParam2IPaginationParamApi, transferISortParam2ISortParamApi, transferResourceCommonApi2ResourceCommon, transferResourceCommonSearchParams2ResourceCommonSearchParamsApi, transferVariableApi2Variable } from './common.ts.js';
|
|
54
|
-
/**
|
|
55
|
-
* ui转换为接口使用
|
|
56
|
-
* @param data ICollectionListParam
|
|
57
|
-
* @returns ICollectionListParamApi
|
|
54
|
+
/**
|
|
55
|
+
* ui转换为接口使用
|
|
56
|
+
* @param data ICollectionListParam
|
|
57
|
+
* @returns ICollectionListParamApi
|
|
58
58
|
*/ export const transferCollectionListParam2CollectionListParamApi = (data)=>{
|
|
59
59
|
return _object_spread_props(_object_spread({}, transferResourceCommonSearchParams2ResourceCommonSearchParamsApi(data), transferIPaginationParam2IPaginationParamApi(data), transferISortParam2ISortParamApi(data)), {
|
|
60
60
|
fuzzy: data.fuzzy,
|
|
@@ -72,13 +72,14 @@ import { transferBaseCountParam2BaseCountParamApi, transferIPaginationParam2IPag
|
|
|
72
72
|
content: data.content,
|
|
73
73
|
created_by: data.createdBy,
|
|
74
74
|
created_at: data.createdAt,
|
|
75
|
-
updated_by: data.updatedBy
|
|
75
|
+
updated_by: data.updatedBy,
|
|
76
|
+
group_type: data.groupType
|
|
76
77
|
});
|
|
77
78
|
};
|
|
78
|
-
/**
|
|
79
|
-
* 接口转换为ui使用(表单字段,Collection 的 Omit<IResourceFormCommon, 'description'> 需手动映射公共字段)
|
|
80
|
-
* @param data ICollectionFormApi
|
|
81
|
-
* @returns ICollectionForm
|
|
79
|
+
/**
|
|
80
|
+
* 接口转换为ui使用(表单字段,Collection 的 Omit<IResourceFormCommon, 'description'> 需手动映射公共字段)
|
|
81
|
+
* @param data ICollectionFormApi
|
|
82
|
+
* @returns ICollectionForm
|
|
82
83
|
*/ export const transferCollectionFormApi2CollectionForm = (data)=>({
|
|
83
84
|
tagNames: data.tag_names,
|
|
84
85
|
generateType: data.generate_type,
|
|
@@ -89,10 +90,10 @@ import { transferBaseCountParam2BaseCountParamApi, transferIPaginationParam2IPag
|
|
|
89
90
|
variables: data.variables.map(transferVariableApi2Variable),
|
|
90
91
|
content: data.content
|
|
91
92
|
});
|
|
92
|
-
/**
|
|
93
|
-
* 接口转换为ui使用(完整资源)
|
|
94
|
-
* @param data ICollectionApi
|
|
95
|
-
* @returns ICollection
|
|
93
|
+
/**
|
|
94
|
+
* 接口转换为ui使用(完整资源)
|
|
95
|
+
* @param data ICollectionApi
|
|
96
|
+
* @returns ICollection
|
|
96
97
|
*/ export const transferCollectionApi2Collection = (data)=>{
|
|
97
98
|
var _data_collection_id, _ref, _data_ref_count;
|
|
98
99
|
return _object_spread_props(_object_spread({}, transferCollectionFormApi2CollectionForm(data), transferResourceCommonApi2ResourceCommon(data)), {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ResourceStatus } from '@/enums';
|
|
2
|
-
import type { IBaseCountParam, IBaseCountParamApi, IPaginationParam, IPaginationParamApi, IPaginationResponse, IPaginationResponseApi, IReferringAgent, IReferringAgentApi, IResourceCommon, IResourceCommonApi, IResourceCommonSearchParams, IResourceCommonSearchParamsApi, IResourceCount, IResourceCountApi, IResourceFormCommon, IResourceFormCommonApi, IResourceReference, IResourceReferenceApi, ISortParam, ISortParamApi, ITagTree, ITagTreeApi, ITagTreeNode, ITagTreeNodeApi, IVariable, IVariableApi
|
|
2
|
+
import type { IApprovalSettingValue, IApprovalSettingValueApi, IBaseCountParam, IBaseCountParamApi, IPaginationParam, IPaginationParamApi, IPaginationResponse, IPaginationResponseApi, IReferringAgent, IReferringAgentApi, IResourceCommon, IResourceCommonApi, IResourceCommonSearchParams, IResourceCommonSearchParamsApi, IResourceCount, IResourceCountApi, IResourceFormCommon, IResourceFormCommonApi, IResourceReference, IResourceReferenceApi, ISortParam, ISortParamApi, ITagTree, ITagTreeApi, ITagTreeNode, ITagTreeNodeApi, IVariable, IVariableApi } from '@/types/common';
|
|
3
3
|
/**
|
|
4
4
|
* 接口转换为ui使用
|
|
5
5
|
* @param data ITagsTreeApi
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import { transferResourcePermission2ResourcePermissionApi, transferResourcePermissionApi2ResourcePermission } from './permission.ts.js';
|
|
2
|
-
/**
|
|
3
|
-
* 接口转换为ui使用
|
|
4
|
-
* @param data ITagsTreeApi
|
|
5
|
-
* @returns ITagsTree
|
|
2
|
+
/**
|
|
3
|
+
* 接口转换为ui使用
|
|
4
|
+
* @param data ITagsTreeApi
|
|
5
|
+
* @returns ITagsTree
|
|
6
6
|
*/ export const transferTagTreeApi2TagTree = (data)=>{
|
|
7
7
|
return {
|
|
8
8
|
all: data.all,
|
|
9
9
|
tree: data.tree.map(transferTagTreeNodeApi2TagTreeNode)
|
|
10
10
|
};
|
|
11
11
|
};
|
|
12
|
-
/**
|
|
13
|
-
* 接口转换为ui使用
|
|
14
|
-
* @param data ITagsTreeNodeApi
|
|
15
|
-
* @returns ITagsTreeNode
|
|
12
|
+
/**
|
|
13
|
+
* 接口转换为ui使用
|
|
14
|
+
* @param data ITagsTreeNodeApi
|
|
15
|
+
* @returns ITagsTreeNode
|
|
16
16
|
*/ export const transferTagTreeNodeApi2TagTreeNode = (data)=>{
|
|
17
17
|
var _data_children;
|
|
18
18
|
return {
|
|
@@ -24,50 +24,50 @@ import { transferResourcePermission2ResourcePermissionApi, transferResourcePermi
|
|
|
24
24
|
children: (_data_children = data.children) === null || _data_children === void 0 ? void 0 : _data_children.map(transferTagTreeNodeApi2TagTreeNode)
|
|
25
25
|
};
|
|
26
26
|
};
|
|
27
|
-
/**
|
|
28
|
-
* ui转换为接口使用
|
|
29
|
-
* @param data IPaginationParam
|
|
30
|
-
* @returns IPaginationParamApi
|
|
27
|
+
/**
|
|
28
|
+
* ui转换为接口使用
|
|
29
|
+
* @param data IPaginationParam
|
|
30
|
+
* @returns IPaginationParamApi
|
|
31
31
|
*/ export const transferIPaginationParam2IPaginationParamApi = (data)=>{
|
|
32
32
|
return {
|
|
33
33
|
page: data === null || data === void 0 ? void 0 : data.page,
|
|
34
34
|
page_size: data === null || data === void 0 ? void 0 : data.pageSize
|
|
35
35
|
};
|
|
36
36
|
};
|
|
37
|
-
/**
|
|
38
|
-
* ui转换为接口使用
|
|
39
|
-
* @param data ISortParam
|
|
40
|
-
* @returns ISortParamApi
|
|
37
|
+
/**
|
|
38
|
+
* ui转换为接口使用
|
|
39
|
+
* @param data ISortParam
|
|
40
|
+
* @returns ISortParamApi
|
|
41
41
|
*/ export const transferISortParam2ISortParamApi = (data)=>{
|
|
42
42
|
return {
|
|
43
43
|
order_by: data === null || data === void 0 ? void 0 : data.orderBy,
|
|
44
44
|
order_method: data === null || data === void 0 ? void 0 : data.orderMethod
|
|
45
45
|
};
|
|
46
46
|
};
|
|
47
|
-
/**
|
|
48
|
-
* 接口转换为ui使用(表单公共字段)
|
|
49
|
-
* @param data IResourceFormCommonApi
|
|
50
|
-
* @returns IResourceFormCommon
|
|
47
|
+
/**
|
|
48
|
+
* 接口转换为ui使用(表单公共字段)
|
|
49
|
+
* @param data IResourceFormCommonApi
|
|
50
|
+
* @returns IResourceFormCommon
|
|
51
51
|
*/ export const transferResourceFormCommonApi2ResourceFormCommon = (data)=>({
|
|
52
52
|
tagNames: data.tag_names,
|
|
53
53
|
generateType: data.generate_type,
|
|
54
54
|
isPublic: data.is_public,
|
|
55
55
|
description: data.description
|
|
56
56
|
});
|
|
57
|
-
/**
|
|
58
|
-
* ui转换为接口使用(表单公共字段)
|
|
59
|
-
* @param data IResourceFormCommon
|
|
60
|
-
* @returns IResourceFormCommonApi
|
|
57
|
+
/**
|
|
58
|
+
* ui转换为接口使用(表单公共字段)
|
|
59
|
+
* @param data IResourceFormCommon
|
|
60
|
+
* @returns IResourceFormCommonApi
|
|
61
61
|
*/ export const transferResourceFormCommon2ResourceFormCommonApi = (data)=>({
|
|
62
62
|
tag_names: data.tagNames,
|
|
63
63
|
generate_type: data.generateType,
|
|
64
64
|
is_public: data.isPublic,
|
|
65
65
|
description: data.description
|
|
66
66
|
});
|
|
67
|
-
/**
|
|
68
|
-
* 接口转换为ui使用(列表/详情公共字段,只转换 IResourceCommon 自己的字段)
|
|
69
|
-
* @param data IResourceCommonApi
|
|
70
|
-
* @returns IResourceCommon
|
|
67
|
+
/**
|
|
68
|
+
* 接口转换为ui使用(列表/详情公共字段,只转换 IResourceCommon 自己的字段)
|
|
69
|
+
* @param data IResourceCommonApi
|
|
70
|
+
* @returns IResourceCommon
|
|
71
71
|
*/ export const transferResourceCommonApi2ResourceCommon = (data)=>({
|
|
72
72
|
id: data.id,
|
|
73
73
|
createdBy: data.created_by,
|
|
@@ -78,12 +78,14 @@ import { transferResourcePermission2ResourcePermissionApi, transferResourcePermi
|
|
|
78
78
|
spaceId: data.space_id,
|
|
79
79
|
approvers: data.approvers,
|
|
80
80
|
ticketUrl: data.ticket_url,
|
|
81
|
+
favorite: data.favorite,
|
|
82
|
+
favoriteCount: data.favorite_count,
|
|
81
83
|
permission: transferResourcePermissionApi2ResourcePermission(data.permission)
|
|
82
84
|
});
|
|
83
|
-
/**
|
|
84
|
-
* ui转换为接口使用(完整资源)
|
|
85
|
-
* @param data IResourceCommon
|
|
86
|
-
* @returns IResourceCommonApi
|
|
85
|
+
/**
|
|
86
|
+
* ui转换为接口使用(完整资源)
|
|
87
|
+
* @param data IResourceCommon
|
|
88
|
+
* @returns IResourceCommonApi
|
|
87
89
|
*/ export const transferResourceCommon2ResourceCommonApi = (data)=>({
|
|
88
90
|
id: data.id,
|
|
89
91
|
created_by: data.createdBy,
|
|
@@ -94,12 +96,14 @@ import { transferResourcePermission2ResourcePermissionApi, transferResourcePermi
|
|
|
94
96
|
space_id: data.spaceId,
|
|
95
97
|
approvers: data.approvers,
|
|
96
98
|
ticket_url: data.ticketUrl,
|
|
99
|
+
favorite: data.favorite,
|
|
100
|
+
favorite_count: data.favoriteCount,
|
|
97
101
|
permission: transferResourcePermission2ResourcePermissionApi(data.permission)
|
|
98
102
|
});
|
|
99
|
-
/**
|
|
100
|
-
* 分页接口响应转换为ui使用,通过传入的转换函数逐项转换列表数据
|
|
101
|
-
* @param transferItem 单项转换函数,将接口类型 A 转换为ui类型 U
|
|
102
|
-
* @returns 将 IPaginationResponseApi<A> 转换为 IPaginationResponse<U> 的函数
|
|
103
|
+
/**
|
|
104
|
+
* 分页接口响应转换为ui使用,通过传入的转换函数逐项转换列表数据
|
|
105
|
+
* @param transferItem 单项转换函数,将接口类型 A 转换为ui类型 U
|
|
106
|
+
* @returns 将 IPaginationResponseApi<A> 转换为 IPaginationResponse<U> 的函数
|
|
103
107
|
*/ export const transferPaginationResponseApi2PaginationResponse = (transferItem)=>(data)=>({
|
|
104
108
|
count: data.count,
|
|
105
109
|
results: data.results.map(transferItem)
|
|
@@ -168,18 +172,18 @@ export const transferIResourceReferenceApi2IResourceReference = (data)=>{
|
|
|
168
172
|
spaceId: data.space_id
|
|
169
173
|
};
|
|
170
174
|
};
|
|
171
|
-
/**
|
|
172
|
-
* ui转换为接口使用(配置审批策略)
|
|
173
|
-
* @param data IApprovalSettingValue,
|
|
174
|
-
* @returns IApprovalSettingValueApi
|
|
175
|
+
/**
|
|
176
|
+
* ui转换为接口使用(配置审批策略)
|
|
177
|
+
* @param data IApprovalSettingValue,
|
|
178
|
+
* @returns IApprovalSettingValueApi
|
|
175
179
|
*/ export const transferIApprovalSettingValue2IApprovalSettingValueApi = (data)=>({
|
|
176
180
|
approval_enabled: data.approvalEnabled,
|
|
177
181
|
approval_strategy_id: data.approvalStrategyId
|
|
178
182
|
});
|
|
179
|
-
/**
|
|
180
|
-
* 接口转换为ui使用(配置审批策略)
|
|
181
|
-
* @param data IApprovalSettingValueApi
|
|
182
|
-
* @returns IApprovalSettingValue
|
|
183
|
+
/**
|
|
184
|
+
* 接口转换为ui使用(配置审批策略)
|
|
185
|
+
* @param data IApprovalSettingValueApi
|
|
186
|
+
* @returns IApprovalSettingValue
|
|
183
187
|
*/ export const transferIApprovalSettingValueApi2IApprovalSettingValue = (data)=>({
|
|
184
188
|
approvalEnabled: data.approval_enabled,
|
|
185
189
|
approvalStrategyId: data.approval_strategy_id
|
|
@@ -79,30 +79,30 @@ function _object_without_properties_loose(source, excluded) {
|
|
|
79
79
|
}
|
|
80
80
|
import { transferIPaginationParam2IPaginationParamApi, transferISortParam2ISortParamApi } from './common.ts.js';
|
|
81
81
|
import { transferResourcePermissionApi2ResourcePermission } from './permission.ts.js';
|
|
82
|
-
/**
|
|
83
|
-
* 接口转换为ui使用
|
|
84
|
-
* @param data ICreataDatasetDataResultApi
|
|
85
|
-
* @returns ICreataDatasetDataResult
|
|
82
|
+
/**
|
|
83
|
+
* 接口转换为ui使用
|
|
84
|
+
* @param data ICreataDatasetDataResultApi
|
|
85
|
+
* @returns ICreataDatasetDataResult
|
|
86
86
|
*/ export const transferCreateDatasetDataResultApi2CreateDatasetDataResult = (data)=>{
|
|
87
87
|
return {
|
|
88
88
|
createCount: data.create_count,
|
|
89
89
|
duplicateCount: data.duplicate_count
|
|
90
90
|
};
|
|
91
91
|
};
|
|
92
|
-
/**
|
|
93
|
-
* 接口转换为ui使用
|
|
94
|
-
* @param data ICompanyApi
|
|
95
|
-
* @returns ICompany
|
|
92
|
+
/**
|
|
93
|
+
* 接口转换为ui使用
|
|
94
|
+
* @param data ICompanyApi
|
|
95
|
+
* @returns ICompany
|
|
96
96
|
*/ export const transferCompanyApi2Company = (data)=>{
|
|
97
97
|
return {
|
|
98
98
|
id: data.id,
|
|
99
99
|
companyName: data.company_name
|
|
100
100
|
};
|
|
101
101
|
};
|
|
102
|
-
/**
|
|
103
|
-
* 接口转换为ui使用
|
|
104
|
-
* @param data IDatasetDataFileApi
|
|
105
|
-
* @returns IDatasetDataFile
|
|
102
|
+
/**
|
|
103
|
+
* 接口转换为ui使用
|
|
104
|
+
* @param data IDatasetDataFileApi
|
|
105
|
+
* @returns IDatasetDataFile
|
|
106
106
|
*/ export const transferDatasetDataFileApi2DatasetDataFile = (data)=>{
|
|
107
107
|
return {
|
|
108
108
|
fileName: data.file_name,
|
|
@@ -111,10 +111,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
111
111
|
id: data.id
|
|
112
112
|
};
|
|
113
113
|
};
|
|
114
|
-
/**
|
|
115
|
-
* ui转换为使用接口
|
|
116
|
-
* @param data IDatasetDataFileApi
|
|
117
|
-
* @returns IDatasetDataFile
|
|
114
|
+
/**
|
|
115
|
+
* ui转换为使用接口
|
|
116
|
+
* @param data IDatasetDataFileApi
|
|
117
|
+
* @returns IDatasetDataFile
|
|
118
118
|
*/ export const transferDatasetDataFile2DatasetDataFileApi = (data)=>{
|
|
119
119
|
return {
|
|
120
120
|
file_name: data.fileName,
|
|
@@ -123,10 +123,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
123
123
|
id: data.id
|
|
124
124
|
};
|
|
125
125
|
};
|
|
126
|
-
/**
|
|
127
|
-
* 接口转换为ui使用
|
|
128
|
-
* @param data IDatasetApi
|
|
129
|
-
* @returns IDataset
|
|
126
|
+
/**
|
|
127
|
+
* 接口转换为ui使用
|
|
128
|
+
* @param data IDatasetApi
|
|
129
|
+
* @returns IDataset
|
|
130
130
|
*/ export const transferDatasetApi2Dataset = (data)=>{
|
|
131
131
|
return {
|
|
132
132
|
componentIds: data.component_ids,
|
|
@@ -149,10 +149,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
149
149
|
permission: transferResourcePermissionApi2ResourcePermission(data.permission)
|
|
150
150
|
};
|
|
151
151
|
};
|
|
152
|
-
/**
|
|
153
|
-
* 接口转换为ui使用
|
|
154
|
-
* @param data IDatasetApiGuideApi
|
|
155
|
-
* @returns IDatasetApiGuide
|
|
152
|
+
/**
|
|
153
|
+
* 接口转换为ui使用
|
|
154
|
+
* @param data IDatasetApiGuideApi
|
|
155
|
+
* @returns IDatasetApiGuide
|
|
156
156
|
*/ export const transferDatasetApiGuideApi2DatasetApiGuide = (data)=>{
|
|
157
157
|
return {
|
|
158
158
|
apiEndpoint: data.api_endpoint,
|
|
@@ -164,10 +164,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
164
164
|
}))
|
|
165
165
|
};
|
|
166
166
|
};
|
|
167
|
-
/**
|
|
168
|
-
* ui转换为接口使用
|
|
169
|
-
* @param data IDatasetListParam
|
|
170
|
-
* @returns IDatasetListParamApi
|
|
167
|
+
/**
|
|
168
|
+
* ui转换为接口使用
|
|
169
|
+
* @param data IDatasetListParam
|
|
170
|
+
* @returns IDatasetListParamApi
|
|
171
171
|
*/ export const transferDatasetListParam2DatasetListParamApi = (data)=>{
|
|
172
172
|
return _object_spread_props(_object_spread({}, transferIPaginationParam2IPaginationParamApi(data), transferISortParam2ISortParamApi(data)), {
|
|
173
173
|
company_name: data === null || data === void 0 ? void 0 : data.companyName,
|
|
@@ -185,10 +185,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
185
185
|
updated_by: data === null || data === void 0 ? void 0 : data.updatedBy
|
|
186
186
|
});
|
|
187
187
|
};
|
|
188
|
-
/**
|
|
189
|
-
* ui转换为接口使用
|
|
190
|
-
* @param data IDatasetForm
|
|
191
|
-
* @returns IDatasetFormApi
|
|
188
|
+
/**
|
|
189
|
+
* ui转换为接口使用
|
|
190
|
+
* @param data IDatasetForm
|
|
191
|
+
* @returns IDatasetFormApi
|
|
192
192
|
*/ export const transferDatasetForm2DatasetFormApi = (data)=>{
|
|
193
193
|
return {
|
|
194
194
|
component_ids: data.componentIds,
|
|
@@ -200,10 +200,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
200
200
|
description: data.description
|
|
201
201
|
};
|
|
202
202
|
};
|
|
203
|
-
/**
|
|
204
|
-
* ui转换为接口使用
|
|
205
|
-
* @param data IDatasetDataParam
|
|
206
|
-
* @returns IDatasetDataParamApi
|
|
203
|
+
/**
|
|
204
|
+
* ui转换为接口使用
|
|
205
|
+
* @param data IDatasetDataParam
|
|
206
|
+
* @returns IDatasetDataParamApi
|
|
207
207
|
*/ export const transferDatasetDataParam2DatasetDataParamApi = (data)=>{
|
|
208
208
|
const { datasetId, createdBy, pageSize, ordering, page, sourceTypes, modelType, levels, isValid, statuses, reviewStatuses } = data, rest = _object_without_properties(data, [
|
|
209
209
|
"datasetId",
|
|
@@ -232,10 +232,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
232
232
|
page
|
|
233
233
|
});
|
|
234
234
|
};
|
|
235
|
-
/**
|
|
236
|
-
* ui转换为接口使用
|
|
237
|
-
* @param data IDatasetDataForm
|
|
238
|
-
* @returns IDatasetDataFormApi
|
|
235
|
+
/**
|
|
236
|
+
* ui转换为接口使用
|
|
237
|
+
* @param data IDatasetDataForm
|
|
238
|
+
* @returns IDatasetDataFormApi
|
|
239
239
|
*/ export const transferDatasetDataForm2DatasetDataFormApi = (data)=>{
|
|
240
240
|
return {
|
|
241
241
|
data: data.data,
|
|
@@ -244,10 +244,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
244
244
|
source_type: data.sourceType
|
|
245
245
|
};
|
|
246
246
|
};
|
|
247
|
-
/**
|
|
248
|
-
* 接口转换为ui使用
|
|
249
|
-
* @param data IDatasetApi
|
|
250
|
-
* @returns IDataset
|
|
247
|
+
/**
|
|
248
|
+
* 接口转换为ui使用
|
|
249
|
+
* @param data IDatasetApi
|
|
250
|
+
* @returns IDataset
|
|
251
251
|
*/ export const transferDatasetDataApi2DatasetData = (data)=>{
|
|
252
252
|
return {
|
|
253
253
|
data: data.data,
|
|
@@ -269,10 +269,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
269
269
|
isValid: data.is_valid
|
|
270
270
|
};
|
|
271
271
|
};
|
|
272
|
-
/**
|
|
273
|
-
* ui转换为接口使用
|
|
274
|
-
* @param data IUserInfo
|
|
275
|
-
* @returns IUserInfoApi
|
|
272
|
+
/**
|
|
273
|
+
* ui转换为接口使用
|
|
274
|
+
* @param data IUserInfo
|
|
275
|
+
* @returns IUserInfoApi
|
|
276
276
|
*/ export const transferUserInfoForm2UserInfoFormApi = (data)=>{
|
|
277
277
|
return {
|
|
278
278
|
name: data.name,
|
|
@@ -281,10 +281,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
281
281
|
email: data.email
|
|
282
282
|
};
|
|
283
283
|
};
|
|
284
|
-
/**
|
|
285
|
-
* 接口转换为ui使用
|
|
286
|
-
* @param data IUserInfoApi
|
|
287
|
-
* @returns IUserInfo
|
|
284
|
+
/**
|
|
285
|
+
* 接口转换为ui使用
|
|
286
|
+
* @param data IUserInfoApi
|
|
287
|
+
* @returns IUserInfo
|
|
288
288
|
*/ export const transferUserInfoApi2UserInfo = (data)=>{
|
|
289
289
|
var _data_extra_weixin, _data_extra, _data_extra_weixin1, _data_extra1, _data_extra_weixin2, _data_extra2, _data_extra_weixin3, _data_extra3, _data_extra4;
|
|
290
290
|
return {
|
|
@@ -306,10 +306,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
306
306
|
}
|
|
307
307
|
};
|
|
308
308
|
};
|
|
309
|
-
/**
|
|
310
|
-
* 接口转换为ui使用
|
|
311
|
-
* @param data IOperatRecordParam
|
|
312
|
-
* @returns IOperatRecordParamApi
|
|
309
|
+
/**
|
|
310
|
+
* 接口转换为ui使用
|
|
311
|
+
* @param data IOperatRecordParam
|
|
312
|
+
* @returns IOperatRecordParamApi
|
|
313
313
|
*/ export const transferOperatRecordParam2OperatRecordParamApi = (data)=>{
|
|
314
314
|
return _object_spread_props(_object_spread({}, transferIPaginationParam2IPaginationParamApi(data)), {
|
|
315
315
|
fuzzy: data.fuzzy,
|
|
@@ -324,10 +324,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
324
324
|
instance_data: data.instanceData
|
|
325
325
|
});
|
|
326
326
|
};
|
|
327
|
-
/**
|
|
328
|
-
* 接口转换为ui使用
|
|
329
|
-
* @param data I
|
|
330
|
-
* @returns IUserInfo
|
|
327
|
+
/**
|
|
328
|
+
* 接口转换为ui使用
|
|
329
|
+
* @param data I
|
|
330
|
+
* @returns IUserInfo
|
|
331
331
|
*/ export const transferOperatRecordApi2OperatRecord = (data)=>{
|
|
332
332
|
return {
|
|
333
333
|
id: data.id,
|
|
@@ -340,10 +340,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
340
340
|
endTime: data.end_time
|
|
341
341
|
};
|
|
342
342
|
};
|
|
343
|
-
/**
|
|
344
|
-
* 接口转换为ui使用
|
|
345
|
-
* @param data ICompanyParticipantApi[]
|
|
346
|
-
* @returns ICompanyParticipant[]
|
|
343
|
+
/**
|
|
344
|
+
* 接口转换为ui使用
|
|
345
|
+
* @param data ICompanyParticipantApi[]
|
|
346
|
+
* @returns ICompanyParticipant[]
|
|
347
347
|
*/ export const transferCompanyParticipantApi2CompanyParticipantList = (data)=>{
|
|
348
348
|
const countMap = {};
|
|
349
349
|
data.forEach((item)=>{
|
|
@@ -359,10 +359,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
359
359
|
rowspan: countMap[item.category]
|
|
360
360
|
}));
|
|
361
361
|
};
|
|
362
|
-
/**
|
|
363
|
-
* ui 转接口
|
|
364
|
-
* @param data IBatchReviewDatasetData
|
|
365
|
-
* @returns IBatchReviewDatasetDataApi
|
|
362
|
+
/**
|
|
363
|
+
* ui 转接口
|
|
364
|
+
* @param data IBatchReviewDatasetData
|
|
365
|
+
* @returns IBatchReviewDatasetDataApi
|
|
366
366
|
*/ export const transferBatchReviewDatasetData2BatchReviewDatasetDataApi = (data)=>{
|
|
367
367
|
return {
|
|
368
368
|
accept_ai: data.acceptAi,
|
|
@@ -374,10 +374,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
374
374
|
exclude_failed: data.excludeFailed
|
|
375
375
|
};
|
|
376
376
|
};
|
|
377
|
-
/**
|
|
378
|
-
* ui 转接卡
|
|
379
|
-
* @param d IBatchRetryReviewDatasetData
|
|
380
|
-
* @returns IBatchRetryReviewDatasetDataApi
|
|
377
|
+
/**
|
|
378
|
+
* ui 转接卡
|
|
379
|
+
* @param d IBatchRetryReviewDatasetData
|
|
380
|
+
* @returns IBatchRetryReviewDatasetDataApi
|
|
381
381
|
*/ export const transferBatchRetryReviewDatasetData2BatchRetryReviewDatasetDataApi = (d)=>{
|
|
382
382
|
return {
|
|
383
383
|
dataset_id: d.datasetId,
|
|
@@ -385,10 +385,10 @@ import { transferResourcePermissionApi2ResourcePermission } from './permission.t
|
|
|
385
385
|
is_retry_all: d.isRetryAll
|
|
386
386
|
};
|
|
387
387
|
};
|
|
388
|
-
/**
|
|
389
|
-
* ui 转接口
|
|
390
|
-
* @param data IBatchUpdateDatasetDataValidity
|
|
391
|
-
* @returns IBatchUpdateDatasetDataValidityApi
|
|
388
|
+
/**
|
|
389
|
+
* ui 转接口
|
|
390
|
+
* @param data IBatchUpdateDatasetDataValidity
|
|
391
|
+
* @returns IBatchUpdateDatasetDataValidityApi
|
|
392
392
|
*/ export const transferBatchUpdateDatasetDataValidity2BatchUpdateDatasetDataValidityApi = (data)=>{
|
|
393
393
|
return {
|
|
394
394
|
dataset_id: data.datasetId,
|