feat: 重构 Skill 管理与编辑工作台

- 统一列表、分类、新建与详情页的产品交互

- 提供 Markdown 实时编辑、源码与脚本资源工作台

- 实现能力自动保存、导入导出及完整状态反馈
This commit is contained in:
2026-07-27 18:54:57 +08:00
parent 2a9e882ac6
commit 0dc5c3ca55
78 changed files with 16413 additions and 799 deletions

View File

@@ -25,6 +25,8 @@ import BotApprovalSnapshotPreview from '#/views/system/approval/components/BotAp
import KnowledgeApprovalSnapshotPreview from '#/views/system/approval/components/KnowledgeApprovalSnapshotPreview.vue';
import WorkflowApprovalSnapshotPreview from '#/views/system/approval/components/WorkflowApprovalSnapshotPreview.vue';
import { formatApprovalAccount } from './approval-format';
const route = useRoute();
const loading = ref(false);
const detail = ref<any>(null);
@@ -171,23 +173,6 @@ function formatPayload(payload: Record<string, any>) {
return JSON.stringify(payload || {}, null, 2);
}
function formatAccountDisplay(
name?: string,
account?: null | string,
fallbackId?: null | number | string,
) {
if (name && account) {
return `${name}${account}`;
}
if (name) {
return name;
}
if (account) {
return account;
}
return fallbackId || '-';
}
function formatOperatorId(
account?: null | string,
fallbackId?: null | number | string,
@@ -334,7 +319,7 @@ function formatEventInfo(row: Record<string, any>) {
</ElDescriptionsItem>
<ElDescriptionsItem :label="$t('approval.fields.applicant')">
{{
formatAccountDisplay(
formatApprovalAccount(
detail.applicantName,
detail.applicantAccount,
detail.applicantId,
@@ -390,7 +375,7 @@ function formatEventInfo(row: Record<string, any>) {
</ElTableColumn>
<ElTableColumn :label="$t('approval.fields.actedBy')" width="180">
<template #default="{ row }">
{{ formatAccountDisplay(row.actedByName, row.actedBy) }}
{{ formatApprovalAccount(row.actedByName, row.actedBy) }}
</template>
</ElTableColumn>
<ElTableColumn