Trim frontend build for lightweight AI agent admin
This commit is contained in:
+45
-19
@@ -176,14 +176,18 @@ dmypy.json
|
|||||||
node_modules
|
node_modules
|
||||||
|
|
||||||
# ai-agent-admin: exclude legacy generated bundles and removed heavy modules
|
# ai-agent-admin: exclude legacy generated bundles and removed heavy modules
|
||||||
|
.ops-backups/
|
||||||
docker/web/
|
docker/web/
|
||||||
docker/uniapp/
|
docker/uniapp/
|
||||||
|
uniapp-zq/
|
||||||
web/apps/web-ele/src/components/screen-design/
|
web/apps/web-ele/src/components/screen-design/
|
||||||
web/apps/web-ele/src/components/form-design/
|
web/apps/web-ele/src/components/form-design/
|
||||||
web/apps/web-ele/src/components/zq-editor/
|
web/apps/web-ele/src/components/zq-editor/
|
||||||
web/apps/web-ele/src/components/whiteboard/
|
web/apps/web-ele/src/components/whiteboard/
|
||||||
web/apps/web-ele/src/views/online-dev/
|
web/apps/web-ele/src/views/online-dev/
|
||||||
web/apps/web-ele/src/views/dashboard/
|
web/apps/web-ele/src/views/dashboard/
|
||||||
|
web/apps/web-ele/src/views/demos/
|
||||||
|
web/apps/web-ele/src/views/zq-smart-table/
|
||||||
web/apps/web-ele/src/api/online-dev/
|
web/apps/web-ele/src/api/online-dev/
|
||||||
web/apps/web-ele/src/components/dashboard-design/
|
web/apps/web-ele/src/components/dashboard-design/
|
||||||
web/apps/web-ele/src/components/document-designer/
|
web/apps/web-ele/src/components/document-designer/
|
||||||
@@ -194,28 +198,50 @@ web/packages/zq-univer/
|
|||||||
web/apps/web-ele/src/locales/langs/*/dashboard-design.json*
|
web/apps/web-ele/src/locales/langs/*/dashboard-design.json*
|
||||||
web/apps/web-ele/src/locales/langs/*/form-design.json
|
web/apps/web-ele/src/locales/langs/*/form-design.json
|
||||||
web/apps/web-ele/src/locales/langs/*/screen-design.json
|
web/apps/web-ele/src/locales/langs/*/screen-design.json
|
||||||
backend-fastapi/ai_platform/nodes/builtin/app_create_node.py
|
web/apps/web-ele/src/router/routes/modules/form-layout.ts
|
||||||
backend-fastapi/ai_platform/nodes/builtin/app_design_node.py
|
web/apps/web-ele/src/router/routes/modules/online-dev.ts
|
||||||
backend-fastapi/ai_platform/nodes/builtin/app_settings_node.py
|
web/apps/web-ele/src/router/routes/modules/zq-smart-table.ts
|
||||||
backend-fastapi/ai_platform/nodes/builtin/app_update_node.py
|
web/apps/web-ele/src/components/report-design/
|
||||||
backend-fastapi/ai_platform/nodes/builtin/dashboard_basic_info_node.py
|
backend-fastapi/online_dev/
|
||||||
backend-fastapi/ai_platform/nodes/builtin/dashboard_create_node.py
|
backend-fastapi/zq_demo/
|
||||||
backend-fastapi/ai_platform/nodes/builtin/dashboard_design_node.py
|
backend-fastapi/zq_smart_table/
|
||||||
backend-fastapi/ai_platform/nodes/builtin/dashboard_publish_node.py
|
backend-fastapi/ai_platform/nodes/builtin/app_*_node.py
|
||||||
backend-fastapi/ai_platform/nodes/builtin/form_basic_info_node.py
|
backend-fastapi/ai_platform/nodes/builtin/dashboard_*_node.py
|
||||||
backend-fastapi/ai_platform/nodes/builtin/form_create_node.py
|
backend-fastapi/ai_platform/nodes/builtin/form_*_node.py
|
||||||
backend-fastapi/ai_platform/nodes/builtin/form_data_node.py
|
|
||||||
backend-fastapi/ai_platform/nodes/builtin/form_database_create_node.py
|
|
||||||
backend-fastapi/ai_platform/nodes/builtin/form_database_design_node.py
|
|
||||||
backend-fastapi/ai_platform/nodes/builtin/form_list_design_node.py
|
|
||||||
backend-fastapi/ai_platform/nodes/builtin/form_publish_node.py
|
|
||||||
backend-fastapi/ai_platform/nodes/builtin/form_ui_design_node.py
|
|
||||||
backend-fastapi/ai_platform/nodes/builtin/system_summary_node.py
|
backend-fastapi/ai_platform/nodes/builtin/system_summary_node.py
|
||||||
web/apps/web-ele/src/components/form-editor/SystemSummaryConfirmPanel.vue
|
web/apps/web-ele/src/api/core/database-monitor.ts
|
||||||
|
web/apps/web-ele/src/api/core/demo.ts
|
||||||
|
web/apps/web-ele/src/api/core/dingtalk-sync.ts
|
||||||
|
web/apps/web-ele/src/api/core/feishu-sync.ts
|
||||||
|
web/apps/web-ele/src/api/core/link-preview.ts
|
||||||
|
web/apps/web-ele/src/api/core/redis-manager.ts
|
||||||
|
web/apps/web-ele/src/api/core/redis-monitor.ts
|
||||||
|
web/apps/web-ele/src/api/core/region.ts
|
||||||
|
web/apps/web-ele/src/api/core/scheduler.ts
|
||||||
|
web/apps/web-ele/src/api/core/server-monitor.ts
|
||||||
|
web/apps/web-ele/src/api/core/wecom-sync.ts
|
||||||
|
web/apps/web-ele/src/router/routes/modules/wiki.ts
|
||||||
|
web/apps/web-ele/src/views/_core/application/
|
||||||
|
web/apps/web-ele/src/views/_core/approval-center/
|
||||||
|
web/apps/web-ele/src/views/_core/data-source/
|
||||||
|
web/apps/web-ele/src/views/_core/database-connection/
|
||||||
|
web/apps/web-ele/src/views/_core/database-manager/
|
||||||
|
web/apps/web-ele/src/views/_core/database-monitor/
|
||||||
|
web/apps/web-ele/src/views/_core/demo/
|
||||||
|
web/apps/web-ele/src/views/_core/mobile-signature/
|
||||||
|
web/apps/web-ele/src/views/_core/post/
|
||||||
|
web/apps/web-ele/src/views/_core/redis-manager/
|
||||||
|
web/apps/web-ele/src/views/_core/redis-monitor/
|
||||||
|
web/apps/web-ele/src/views/_core/region-manager/
|
||||||
|
web/apps/web-ele/src/views/_core/scheduler/
|
||||||
|
web/apps/web-ele/src/views/_core/server-monitor/
|
||||||
|
web/apps/web-ele/src/views/_core/system-config/modules/dingtalk-sync-form.vue
|
||||||
|
web/apps/web-ele/src/views/_core/system-config/modules/feishu-sync-form.vue
|
||||||
|
web/apps/web-ele/src/views/_core/system-config/modules/wecom-sync-form.vue
|
||||||
web/apps/web-ele/src/views/ai-platform/workflow/editor/nodes/SystemSummaryNode.vue
|
web/apps/web-ele/src/views/ai-platform/workflow/editor/nodes/SystemSummaryNode.vue
|
||||||
web/apps/web-ele/src/views/ai-platform/workflow/editor/panels/SystemSummaryPanel.vue
|
web/apps/web-ele/src/views/ai-platform/workflow/editor/panels/SystemSummaryPanel.vue
|
||||||
!web/apps/web-ele/src/components/form-editor/index.ts
|
web/apps/web-ele/src/views/wiki/
|
||||||
web/apps/web-ele/src/components/report-design/
|
web/apps/web-ele/src/components/zq-form/table-selector/types.ts
|
||||||
|
|
||||||
# keep only lightweight form-editor barrel
|
# keep only lightweight form-editor barrel
|
||||||
web/apps/web-ele/src/components/form-editor/*
|
web/apps/web-ele/src/components/form-editor/*
|
||||||
|
|||||||
@@ -89,11 +89,6 @@ const ZqIconPicker = defineAsyncComponent(() =>
|
|||||||
(res) => res.default,
|
(res) => res.default,
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
const CronSelector = defineAsyncComponent(() =>
|
|
||||||
import('#/components/zq-form/cron-selector/cron-selector.vue').then(
|
|
||||||
(res) => res.default,
|
|
||||||
),
|
|
||||||
);
|
|
||||||
const CodeEditor = defineAsyncComponent(() =>
|
const CodeEditor = defineAsyncComponent(() =>
|
||||||
import('#/components/zq-form/code-editor/code-editor.vue').then(
|
import('#/components/zq-form/code-editor/code-editor.vue').then(
|
||||||
(res) => res.default,
|
(res) => res.default,
|
||||||
@@ -214,7 +209,6 @@ export type ComponentType =
|
|||||||
| 'Checkbox'
|
| 'Checkbox'
|
||||||
| 'CheckboxGroup'
|
| 'CheckboxGroup'
|
||||||
| 'CodeEditor'
|
| 'CodeEditor'
|
||||||
| 'CronSelector'
|
|
||||||
| 'DatePicker'
|
| 'DatePicker'
|
||||||
| 'DeptSelector'
|
| 'DeptSelector'
|
||||||
| 'Divider'
|
| 'Divider'
|
||||||
@@ -309,7 +303,6 @@ async function initComponentAdapter() {
|
|||||||
Textarea: withDefaultPlaceholder(ElInput, 'input', { type: 'textarea' }),
|
Textarea: withDefaultPlaceholder(ElInput, 'input', { type: 'textarea' }),
|
||||||
JsonEditor,
|
JsonEditor,
|
||||||
CodeEditor,
|
CodeEditor,
|
||||||
CronSelector,
|
|
||||||
InputNumber: withDefaultPlaceholder(ElInputNumber, 'input'),
|
InputNumber: withDefaultPlaceholder(ElInputNumber, 'input'),
|
||||||
RadioGroup: (props, { attrs, slots }) => {
|
RadioGroup: (props, { attrs, slots }) => {
|
||||||
let defaultSlot;
|
let defaultSlot;
|
||||||
|
|||||||
@@ -0,0 +1,81 @@
|
|||||||
|
<script setup lang="ts">
|
||||||
|
import type { DesignPreviewData } from './types';
|
||||||
|
|
||||||
|
import { computed, ref, watch } from 'vue';
|
||||||
|
|
||||||
|
import { ElButton, ElDialog, ElInput, ElMessage } from 'element-plus';
|
||||||
|
|
||||||
|
const props = defineProps<{
|
||||||
|
preview?: DesignPreviewData;
|
||||||
|
title?: string;
|
||||||
|
visible: boolean;
|
||||||
|
}>();
|
||||||
|
|
||||||
|
const emit = defineEmits<{
|
||||||
|
(e: 'close'): void;
|
||||||
|
(e: 'confirm', data: Record<string, any>): void;
|
||||||
|
(e: 'update:visible', visible: boolean): void;
|
||||||
|
}>();
|
||||||
|
|
||||||
|
const draftText = ref('{}');
|
||||||
|
|
||||||
|
const dialogTitle = computed(
|
||||||
|
() => props.preview?.title || props.title || '确认内容',
|
||||||
|
);
|
||||||
|
|
||||||
|
watch(
|
||||||
|
() => [props.visible, props.preview] as const,
|
||||||
|
() => {
|
||||||
|
if (props.visible) {
|
||||||
|
draftText.value = JSON.stringify(props.preview?.data || {}, null, 2);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{ immediate: true },
|
||||||
|
);
|
||||||
|
|
||||||
|
function handleClose() {
|
||||||
|
emit('update:visible', false);
|
||||||
|
emit('close');
|
||||||
|
}
|
||||||
|
|
||||||
|
function handleConfirm() {
|
||||||
|
try {
|
||||||
|
const data = JSON.parse(draftText.value || '{}');
|
||||||
|
emit('confirm', data && typeof data === 'object' ? data : { value: data });
|
||||||
|
emit('update:visible', false);
|
||||||
|
} catch {
|
||||||
|
ElMessage.error('JSON 格式不正确');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function handleVisibleChange(visible: boolean) {
|
||||||
|
if (!visible) handleClose();
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<ElDialog
|
||||||
|
:model-value="visible"
|
||||||
|
:title="dialogTitle"
|
||||||
|
width="720px"
|
||||||
|
append-to-body
|
||||||
|
destroy-on-close
|
||||||
|
@update:model-value="handleVisibleChange"
|
||||||
|
>
|
||||||
|
<div class="space-y-3">
|
||||||
|
<div class="text-muted-foreground text-sm">
|
||||||
|
{{ preview?.type || 'design_preview' }}
|
||||||
|
</div>
|
||||||
|
<ElInput
|
||||||
|
v-model="draftText"
|
||||||
|
type="textarea"
|
||||||
|
:rows="18"
|
||||||
|
resize="vertical"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
<template #footer>
|
||||||
|
<ElButton @click="handleClose">取消</ElButton>
|
||||||
|
<ElButton type="primary" @click="handleConfirm">确认</ElButton>
|
||||||
|
</template>
|
||||||
|
</ElDialog>
|
||||||
|
</template>
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
import DesignPreviewDialog from './DesignPreviewDialog.vue';
|
||||||
|
|
||||||
|
type PreviewData = {
|
||||||
|
data?: Record<string, any>;
|
||||||
|
[key: string]: any;
|
||||||
|
};
|
||||||
|
|
||||||
|
export type AppDesignData = PreviewData;
|
||||||
|
export type AppSettingsData = PreviewData;
|
||||||
|
export type DashboardBasicInfoData = PreviewData;
|
||||||
|
export type DashboardDesignData = PreviewData;
|
||||||
|
export type DashboardPublishData = PreviewData;
|
||||||
|
export type DesignData = PreviewData;
|
||||||
|
export type DesignType = string;
|
||||||
|
export type SystemSummaryData = PreviewData;
|
||||||
|
|
||||||
|
export const AppDesignPanel = DesignPreviewDialog;
|
||||||
|
export const AppSettingsPanel = DesignPreviewDialog;
|
||||||
|
export const DashboardBasicInfoConfirmPanel = DesignPreviewDialog;
|
||||||
|
export const DashboardDesignConfirmPanel = DesignPreviewDialog;
|
||||||
|
export const DashboardPublishConfirmPanel = DesignPreviewDialog;
|
||||||
|
export const DesignEditorPanel = DesignPreviewDialog;
|
||||||
|
export const SystemSummaryConfirmPanel = DesignPreviewDialog;
|
||||||
@@ -1,45 +1,34 @@
|
|||||||
import type { Component } from 'vue';
|
import DesignPreviewDialog from '#/components/ai-chat-panel/DesignPreviewDialog.vue';
|
||||||
|
|
||||||
import { defineComponent, h } from 'vue';
|
type PreviewData = {
|
||||||
|
data?: Record<string, any>;
|
||||||
|
[key: string]: any;
|
||||||
|
};
|
||||||
|
|
||||||
export type DesignEditorData = Record<string, any>;
|
export type AppDesignData = PreviewData;
|
||||||
export type AppDesignData = Record<string, any>;
|
export type AppSettingsData = PreviewData;
|
||||||
export type DashboardBasicInfoData = Record<string, any>;
|
export type BasicFormData = PreviewData;
|
||||||
export type DashboardDesignData = Record<string, any>;
|
export type DashboardBasicInfoData = PreviewData;
|
||||||
export type DashboardPublishData = Record<string, any>;
|
export type DashboardDesignData = PreviewData;
|
||||||
export type SystemSummaryData = Record<string, any>;
|
export type DashboardPublishData = PreviewData;
|
||||||
|
export type DesignData = PreviewData;
|
||||||
|
export type DesignType = string;
|
||||||
|
export type FormBasicData = PreviewData;
|
||||||
|
export type FormEditorData = PreviewData;
|
||||||
|
export type PageBasicInfo = PreviewData;
|
||||||
|
export type PageEditorData = PreviewData;
|
||||||
|
export type PagePublishInfo = PreviewData;
|
||||||
|
export type SystemSummaryData = PreviewData;
|
||||||
|
|
||||||
export interface FormEditorProps {
|
export const AppDesignPanel = DesignPreviewDialog;
|
||||||
readonly?: boolean;
|
export const AppSettingsPanel = DesignPreviewDialog;
|
||||||
schema?: Record<string, any>;
|
export const BasicInfoEditor = DesignPreviewDialog;
|
||||||
}
|
export const DashboardBasicInfoConfirmPanel = DesignPreviewDialog;
|
||||||
|
export const DashboardDesignConfirmPanel = DesignPreviewDialog;
|
||||||
export interface PageEditorProps {
|
export const DashboardPublishConfirmPanel = DesignPreviewDialog;
|
||||||
readonly?: boolean;
|
export const DesignEditorPanel = DesignPreviewDialog;
|
||||||
schema?: Record<string, any>;
|
export const FormEditorContent = DesignPreviewDialog;
|
||||||
}
|
export const PageBasicInfoEditor = DesignPreviewDialog;
|
||||||
|
export const PageEditorContent = DesignPreviewDialog;
|
||||||
export const FORM_EDITOR_LIGHTWEIGHT = true;
|
export const PagePublishInfoEditor = DesignPreviewDialog;
|
||||||
|
export const SystemSummaryConfirmPanel = DesignPreviewDialog;
|
||||||
function createLitePanel(name: string): Component {
|
|
||||||
return defineComponent({
|
|
||||||
name,
|
|
||||||
setup(_, { slots }) {
|
|
||||||
return () => h('div', { class: 'form-editor-lite-placeholder' }, slots.default?.());
|
|
||||||
},
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
export const BasicInfoEditor = createLitePanel('BasicInfoEditor');
|
|
||||||
export const PublishInfoEditor = createLitePanel('PublishInfoEditor');
|
|
||||||
export const PageBasicInfoEditor = createLitePanel('PageBasicInfoEditor');
|
|
||||||
export const PagePublishInfoEditor = createLitePanel('PagePublishInfoEditor');
|
|
||||||
export const FormEditorContent = createLitePanel('FormEditorContent');
|
|
||||||
export const PageEditorContent = createLitePanel('PageEditorContent');
|
|
||||||
export const DesignEditorPanel = createLitePanel('DesignEditorPanel');
|
|
||||||
export const AppDesignPanel = createLitePanel('AppDesignPanel');
|
|
||||||
export const AppSettingsPanel = createLitePanel('AppSettingsPanel');
|
|
||||||
export const DashboardBasicInfoConfirmPanel = createLitePanel('DashboardBasicInfoConfirmPanel');
|
|
||||||
export const DashboardDesignConfirmPanel = createLitePanel('DashboardDesignConfirmPanel');
|
|
||||||
export const DashboardPublishConfirmPanel = createLitePanel('DashboardPublishConfirmPanel');
|
|
||||||
export const SystemSummaryConfirmPanel = createLitePanel('SystemSummaryConfirmPanel');
|
|
||||||
|
|||||||
@@ -53,9 +53,7 @@ import {
|
|||||||
import draggable from 'vuedraggable';
|
import draggable from 'vuedraggable';
|
||||||
|
|
||||||
import { DeptSelector } from '../zq-form/dept-selector';
|
import { DeptSelector } from '../zq-form/dept-selector';
|
||||||
import { FormSelector } from '../zq-form/form-selector';
|
|
||||||
import { PostSelector } from '../zq-form/post-selector';
|
import { PostSelector } from '../zq-form/post-selector';
|
||||||
import { TableSelector } from '../zq-form/table-selector';
|
|
||||||
import { UserSelector } from '../zq-form/user-selector';
|
import { UserSelector } from '../zq-form/user-selector';
|
||||||
import { useTableForm } from './init';
|
import { useTableForm } from './init';
|
||||||
|
|
||||||
@@ -619,11 +617,9 @@ function isDialogFilterComponent(componentType: string): boolean {
|
|||||||
'department-selector',
|
'department-selector',
|
||||||
'dept-select',
|
'dept-select',
|
||||||
'dept-selector',
|
'dept-selector',
|
||||||
'form-selector',
|
|
||||||
'position-selector',
|
'position-selector',
|
||||||
'post-select',
|
'post-select',
|
||||||
'post-selector',
|
'post-selector',
|
||||||
'table-selector',
|
|
||||||
'user-select',
|
'user-select',
|
||||||
'user-selector',
|
'user-selector',
|
||||||
].includes(componentType);
|
].includes(componentType);
|
||||||
@@ -1291,35 +1287,6 @@ function getSummaryMethod(param: { columns: any[]; data: any[] }) {
|
|||||||
:placeholder="$t('common.select')"
|
:placeholder="$t('common.select')"
|
||||||
@change="handleSelectorFilterChange"
|
@change="handleSelectorFilterChange"
|
||||||
/>
|
/>
|
||||||
<FormSelector
|
|
||||||
v-else-if="
|
|
||||||
activeFilterComponentType === 'form-selector'
|
|
||||||
"
|
|
||||||
:model-value="tempFilterValues"
|
|
||||||
:form-code="col.formCode"
|
|
||||||
:value-field="col.formSelectorValueField || 'id'"
|
|
||||||
:label-field="col.formSelectorLabelField || 'name'"
|
|
||||||
multiple
|
|
||||||
:placeholder="$t('common.select')"
|
|
||||||
@change="handleSelectorFilterChange"
|
|
||||||
/>
|
|
||||||
<TableSelector
|
|
||||||
v-else-if="
|
|
||||||
activeFilterComponentType === 'table-selector'
|
|
||||||
"
|
|
||||||
:model-value="tempFilterValues"
|
|
||||||
:data-source-type="col.tableSelectorDataSourceType"
|
|
||||||
:form-code="col.formCode"
|
|
||||||
:dict-code="col.tableSelectorDictCode"
|
|
||||||
:data-source-code="col.tableSelectorDataSourceCode"
|
|
||||||
:value-field="col.formSelectorValueField || 'id'"
|
|
||||||
:label-field="col.formSelectorLabelField || 'name'"
|
|
||||||
:columns="col.tableSelectorColumns"
|
|
||||||
:search-fields="col.tableSelectorSearchFields"
|
|
||||||
multiple
|
|
||||||
:placeholder="$t('common.select')"
|
|
||||||
@change="handleSelectorFilterChange"
|
|
||||||
/>
|
|
||||||
</div>
|
</div>
|
||||||
<!-- 操作按钮 -->
|
<!-- 操作按钮 -->
|
||||||
<div class="mt-2 flex justify-end gap-2">
|
<div class="mt-2 flex justify-end gap-2">
|
||||||
|
|||||||
@@ -30,66 +30,24 @@ const modules = import.meta.glob([
|
|||||||
'./langs/*/authentication.json',
|
'./langs/*/authentication.json',
|
||||||
'./langs/*/chat.json',
|
'./langs/*/chat.json',
|
||||||
'./langs/*/common.json',
|
'./langs/*/common.json',
|
||||||
'./langs/*/database-connection.json',
|
|
||||||
'./langs/*/data-source.json',
|
|
||||||
'./langs/*/dept.json',
|
|
||||||
'./langs/*/dict.json',
|
|
||||||
'./langs/*/file-manager.json',
|
|
||||||
'./langs/*/loginLog.json',
|
'./langs/*/loginLog.json',
|
||||||
'./langs/*/menu.json',
|
'./langs/*/menu.json',
|
||||||
'./langs/*/menu-title.json',
|
'./langs/*/menu-title.json',
|
||||||
'./langs/*/message.json',
|
'./langs/*/message.json',
|
||||||
'./langs/*/org-chart.json',
|
'./langs/*/page.json',
|
||||||
'./langs/*/permission.json',
|
'./langs/*/permission.json',
|
||||||
'./langs/*/post.json',
|
|
||||||
'./langs/*/role.json',
|
'./langs/*/role.json',
|
||||||
'./langs/*/server-monitor.json',
|
|
||||||
'./langs/*/system-config.json',
|
'./langs/*/system-config.json',
|
||||||
'./langs/*/system.json',
|
'./langs/*/system.json',
|
||||||
'./langs/*/ui-config.json',
|
|
||||||
'./langs/*/ui.json',
|
'./langs/*/ui.json',
|
||||||
'./langs/*/user-avatar.json',
|
'./langs/*/user-avatar.json',
|
||||||
'./langs/*/user.json',
|
'./langs/*/user.json',
|
||||||
'./langs/*/wiki.json',
|
|
||||||
'./langs/*/workflow.json',
|
|
||||||
'./langs/*/zq-smart-table.json',
|
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const localesMap = loadLocalesMapFromDir(
|
const localesMap = loadLocalesMapFromDir(
|
||||||
/\.\/langs\/([^/]+)\/(.*)\.json$/,
|
/\.\/langs\/([^/]+)\/(.*)\.json$/,
|
||||||
modules,
|
modules,
|
||||||
);
|
);
|
||||||
/** zq-table 需要提升到根级的命名空间,以便 t('table.xxx') 等能正确解析 */
|
|
||||||
const ZQ_TABLE_ROOT_KEYS = [
|
|
||||||
'common',
|
|
||||||
'table',
|
|
||||||
'toolbar',
|
|
||||||
'filter',
|
|
||||||
'field',
|
|
||||||
'view',
|
|
||||||
'kanban',
|
|
||||||
'gantt',
|
|
||||||
'calendar',
|
|
||||||
'gallery',
|
|
||||||
'form',
|
|
||||||
'dashboard',
|
|
||||||
'sidebar',
|
|
||||||
'app',
|
|
||||||
'theme',
|
|
||||||
'language',
|
|
||||||
'link',
|
|
||||||
'cellRenderer',
|
|
||||||
'permission',
|
|
||||||
'summary',
|
|
||||||
'formula',
|
|
||||||
'validation',
|
|
||||||
'comment',
|
|
||||||
'mention',
|
|
||||||
'document',
|
|
||||||
'trash',
|
|
||||||
'version',
|
|
||||||
'template',
|
|
||||||
] as const;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 加载应用特有的语言包
|
* 加载应用特有的语言包
|
||||||
@@ -101,30 +59,7 @@ async function loadMessages(lang: SupportedLanguagesType) {
|
|||||||
localesMap[lang]?.(),
|
localesMap[lang]?.(),
|
||||||
loadThirdPartyMessage(lang),
|
loadThirdPartyMessage(lang),
|
||||||
]);
|
]);
|
||||||
const messages = appLocaleMessages?.default || {};
|
return appLocaleMessages?.default || {};
|
||||||
// 将 zq-table / zq-smart-table 的 table/toolbar/filter 等命名空间提升到根级
|
|
||||||
// 使用浅合并:zq-table 的子键补充到已有命名空间,app 级别的同名 key 优先保留
|
|
||||||
const merged = { ...messages };
|
|
||||||
for (const ns of ['zq-table', 'zq-smart-table'] as const) {
|
|
||||||
const src = messages[ns];
|
|
||||||
if (src && typeof src === 'object') {
|
|
||||||
for (const key of ZQ_TABLE_ROOT_KEYS) {
|
|
||||||
if (key in src && src[key] != null) {
|
|
||||||
const existing = merged[key];
|
|
||||||
if (
|
|
||||||
existing &&
|
|
||||||
typeof existing === 'object' &&
|
|
||||||
typeof src[key] === 'object'
|
|
||||||
) {
|
|
||||||
merged[key] = { ...src[key], ...existing };
|
|
||||||
} else {
|
|
||||||
merged[key] = src[key];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return merged;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -17,13 +17,29 @@ const forbiddenComponent = () => import('#/views/_core/fallback/forbidden.vue');
|
|||||||
|
|
||||||
async function generateAccess(options: GenerateMenuAndRoutesOptions) {
|
async function generateAccess(options: GenerateMenuAndRoutesOptions) {
|
||||||
const pageMap: ComponentRecordType = import.meta.glob([
|
const pageMap: ComponentRecordType = import.meta.glob([
|
||||||
'../views/**/*.vue',
|
'../views/_core/account-settings/**/*.vue',
|
||||||
'!../views/**/components/**',
|
'../views/_core/agent-chat/**/*.vue',
|
||||||
'!../views/**/modules/**',
|
'../views/_core/announcement/index.vue',
|
||||||
'!../views/ai-platform/workflow/editor/components/**/*.vue',
|
'../views/_core/announcement/list.vue',
|
||||||
'!../views/ai-platform/workflow/editor/edges/**/*.vue',
|
'../views/_core/authentication/**/*.vue',
|
||||||
'!../views/ai-platform/workflow/editor/nodes/**/*.vue',
|
'../views/_core/chat/**/*.vue',
|
||||||
'!../views/ai-platform/workflow/editor/panels/**/*.vue',
|
'../views/_core/fallback/**/*.vue',
|
||||||
|
'../views/_core/file-preview/index.vue',
|
||||||
|
'../views/_core/login-log/index.vue',
|
||||||
|
'../views/_core/menu/index.vue',
|
||||||
|
'../views/_core/message/index.vue',
|
||||||
|
'../views/_core/mobile-signature/index.vue',
|
||||||
|
'../views/_core/permission/index.vue',
|
||||||
|
'../views/_core/role/index.vue',
|
||||||
|
'../views/_core/system-config/index.vue',
|
||||||
|
'../views/_core/user/index.vue',
|
||||||
|
'../views/ai-platform/agent/editor/index.vue',
|
||||||
|
'../views/ai-platform/agent/index.vue',
|
||||||
|
'../views/ai-platform/knowledge/detail/index.vue',
|
||||||
|
'../views/ai-platform/knowledge/index.vue',
|
||||||
|
'../views/ai-platform/workflow/editor/index.vue',
|
||||||
|
'../views/ai-platform/workflow/index.vue',
|
||||||
|
'../views/ai-platform/workflow-runs/index.vue',
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const layoutMap: ComponentRecordType = {
|
const layoutMap: ComponentRecordType = {
|
||||||
|
|||||||
@@ -97,6 +97,17 @@ const coreRoutes: RouteRecordRaw[] = [
|
|||||||
title: 'OAuth Callback',
|
title: 'OAuth Callback',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: 'MobileSignature',
|
||||||
|
path: '/mobile-signature/:token',
|
||||||
|
component: () => import('#/views/_core/mobile-signature/index.vue'),
|
||||||
|
meta: {
|
||||||
|
hideInBreadcrumb: true,
|
||||||
|
hideInMenu: true,
|
||||||
|
hideInTab: true,
|
||||||
|
title: 'Mobile Signature',
|
||||||
|
},
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: 'FilePreview',
|
name: 'FilePreview',
|
||||||
path: '/file-preview/:id',
|
path: '/file-preview/:id',
|
||||||
|
|||||||
@@ -3,17 +3,16 @@ import type { RouteRecordRaw } from 'vue-router';
|
|||||||
import { mergeRouteModules, traverseTreeValues } from '@vben/utils';
|
import { mergeRouteModules, traverseTreeValues } from '@vben/utils';
|
||||||
|
|
||||||
import { coreRoutes, fallbackNotFoundRoute } from './core';
|
import { coreRoutes, fallbackNotFoundRoute } from './core';
|
||||||
|
import aiPlatformRoutes from './modules/ai-platform';
|
||||||
const dynamicRouteFiles = import.meta.glob('./modules/**/*.ts', {
|
|
||||||
eager: true,
|
|
||||||
});
|
|
||||||
|
|
||||||
// 有需要可以自行打开注释,并创建文件夹
|
// 有需要可以自行打开注释,并创建文件夹
|
||||||
// const externalRouteFiles = import.meta.glob('./external/**/*.ts', { eager: true });
|
// const externalRouteFiles = import.meta.glob('./external/**/*.ts', { eager: true });
|
||||||
// const staticRouteFiles = import.meta.glob('./static/**/*.ts', { eager: true });
|
// const staticRouteFiles = import.meta.glob('./static/**/*.ts', { eager: true });
|
||||||
|
|
||||||
/** 动态路由 */
|
/** 动态路由 */
|
||||||
const dynamicRoutes: RouteRecordRaw[] = mergeRouteModules(dynamicRouteFiles);
|
const dynamicRoutes: RouteRecordRaw[] = mergeRouteModules({
|
||||||
|
'./modules/ai-platform.ts': { default: aiPlatformRoutes },
|
||||||
|
});
|
||||||
|
|
||||||
/** 外部路由列表,访问这些页面可以不需要Layout,可能用于内嵌在别的系统(不会显示在菜单中) */
|
/** 外部路由列表,访问这些页面可以不需要Layout,可能用于内嵌在别的系统(不会显示在菜单中) */
|
||||||
// const externalRoutes: RouteRecordRaw[] = mergeRouteModules(externalRouteFiles);
|
// const externalRoutes: RouteRecordRaw[] = mergeRouteModules(externalRouteFiles);
|
||||||
@@ -37,13 +36,29 @@ const accessRoutes = [...dynamicRoutes, ...staticRoutes];
|
|||||||
|
|
||||||
const componentKeys: string[] = Object.keys(
|
const componentKeys: string[] = Object.keys(
|
||||||
import.meta.glob([
|
import.meta.glob([
|
||||||
'../../views/**/*.vue',
|
'../../views/_core/account-settings/**/*.vue',
|
||||||
'!../../views/**/components/**',
|
'../../views/_core/agent-chat/**/*.vue',
|
||||||
'!../../views/**/modules/**',
|
'../../views/_core/announcement/index.vue',
|
||||||
'!../../views/ai-platform/workflow/editor/components/**/*.vue',
|
'../../views/_core/announcement/list.vue',
|
||||||
'!../../views/ai-platform/workflow/editor/edges/**/*.vue',
|
'../../views/_core/authentication/**/*.vue',
|
||||||
'!../../views/ai-platform/workflow/editor/nodes/**/*.vue',
|
'../../views/_core/chat/**/*.vue',
|
||||||
'!../../views/ai-platform/workflow/editor/panels/**/*.vue',
|
'../../views/_core/fallback/**/*.vue',
|
||||||
|
'../../views/_core/file-preview/index.vue',
|
||||||
|
'../../views/_core/login-log/index.vue',
|
||||||
|
'../../views/_core/menu/index.vue',
|
||||||
|
'../../views/_core/message/index.vue',
|
||||||
|
'../../views/_core/mobile-signature/index.vue',
|
||||||
|
'../../views/_core/permission/index.vue',
|
||||||
|
'../../views/_core/role/index.vue',
|
||||||
|
'../../views/_core/system-config/index.vue',
|
||||||
|
'../../views/_core/user/index.vue',
|
||||||
|
'../../views/ai-platform/agent/editor/index.vue',
|
||||||
|
'../../views/ai-platform/agent/index.vue',
|
||||||
|
'../../views/ai-platform/knowledge/detail/index.vue',
|
||||||
|
'../../views/ai-platform/knowledge/index.vue',
|
||||||
|
'../../views/ai-platform/workflow/editor/index.vue',
|
||||||
|
'../../views/ai-platform/workflow/index.vue',
|
||||||
|
'../../views/ai-platform/workflow-runs/index.vue',
|
||||||
]),
|
]),
|
||||||
)
|
)
|
||||||
.filter((item) => !item.includes('/modules/'))
|
.filter((item) => !item.includes('/modules/'))
|
||||||
|
|||||||
@@ -815,7 +815,8 @@ onBeforeUnmount(() => {
|
|||||||
class="w-full"
|
class="w-full"
|
||||||
type="textarea"
|
type="textarea"
|
||||||
:placeholder="$t('announcement.formContentPlaceholder')"
|
:placeholder="$t('announcement.formContentPlaceholder')"
|
||||||
:rows="12"
|
:autosize="{ minRows: 8, maxRows: 16 }"
|
||||||
|
resize="vertical"
|
||||||
/>
|
/>
|
||||||
</ElFormItem>
|
</ElFormItem>
|
||||||
</ElForm>
|
</ElForm>
|
||||||
|
|||||||
@@ -1,16 +1,29 @@
|
|||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import type { WorkflowRunListItem } from '#/api/ai-platform/ai-platform';
|
import type { WorkflowRunListItem } from '#/api/ai-platform/ai-platform';
|
||||||
|
|
||||||
import { ref } from 'vue';
|
import { computed, onMounted, ref } from 'vue';
|
||||||
|
|
||||||
import { Page } from '@vben/common-ui';
|
import { Page } from '@vben/common-ui';
|
||||||
import { Eye } from '@vben/icons';
|
import { Eye, RefreshCw, Search } from '@vben/icons';
|
||||||
import { $t } from '@vben/locales';
|
import { $t } from '@vben/locales';
|
||||||
|
|
||||||
import { ElButton, ElTag } from 'element-plus';
|
import {
|
||||||
|
ElButton,
|
||||||
|
ElCard,
|
||||||
|
ElForm,
|
||||||
|
ElFormItem,
|
||||||
|
ElOption,
|
||||||
|
ElPagination,
|
||||||
|
ElSelect,
|
||||||
|
ElTable,
|
||||||
|
ElTableColumn,
|
||||||
|
ElTag,
|
||||||
|
} from 'element-plus';
|
||||||
|
|
||||||
import { getAllWorkflowRunsApi } from '#/api/ai-platform/ai-platform';
|
import {
|
||||||
import { useZqTable } from '#/components/zq-table';
|
getAllWorkflowRunsApi,
|
||||||
|
getWorkflowListApi,
|
||||||
|
} from '#/api/ai-platform/ai-platform';
|
||||||
|
|
||||||
import RunStatusTag from './components/RunStatusTag.vue';
|
import RunStatusTag from './components/RunStatusTag.vue';
|
||||||
import {
|
import {
|
||||||
@@ -18,97 +31,245 @@ import {
|
|||||||
formatTime,
|
formatTime,
|
||||||
getTagLabel,
|
getTagLabel,
|
||||||
getTagType,
|
getTagType,
|
||||||
|
getStatusOptions,
|
||||||
getTriggerOptions,
|
getTriggerOptions,
|
||||||
useSearchFormSchema,
|
|
||||||
useZqTableColumns,
|
|
||||||
} from './data';
|
} from './data';
|
||||||
import DetailDialog from './modules/detail-dialog.vue';
|
import DetailDialog from './modules/detail-dialog.vue';
|
||||||
|
|
||||||
defineOptions({ name: 'WorkflowRunHistory' });
|
defineOptions({ name: 'WorkflowRunHistory' });
|
||||||
|
|
||||||
const detailRef = ref<InstanceType<typeof DetailDialog>>();
|
const detailRef = ref<InstanceType<typeof DetailDialog>>();
|
||||||
const triggerOptions = getTriggerOptions();
|
const loading = ref(false);
|
||||||
|
const rows = ref<WorkflowRunListItem[]>([]);
|
||||||
const fetchRunList = async (params: any) => {
|
const total = ref(0);
|
||||||
const res = await getAllWorkflowRunsApi({
|
const currentPage = ref(1);
|
||||||
page: params.page.currentPage,
|
const pageSize = ref(20);
|
||||||
pageSize: params.page.pageSize,
|
const workflowOptions = ref<Array<{ label: string; value: string }>>([]);
|
||||||
workflowId: params.form?.workflowId || undefined,
|
const filters = ref({
|
||||||
status: params.form?.status || undefined,
|
workflowId: '',
|
||||||
triggerType: params.form?.triggerType || undefined,
|
status: '',
|
||||||
});
|
triggerType: '',
|
||||||
return {
|
|
||||||
items: res.items,
|
|
||||||
total: res.total,
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
const [Grid] = useZqTable({
|
|
||||||
gridOptions: {
|
|
||||||
columns: useZqTableColumns(),
|
|
||||||
border: true,
|
|
||||||
stripe: true,
|
|
||||||
showIndex: true,
|
|
||||||
proxyConfig: {
|
|
||||||
autoLoad: true,
|
|
||||||
ajax: {
|
|
||||||
query: fetchRunList,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
pagerConfig: {
|
|
||||||
enabled: true,
|
|
||||||
pageSize: 20,
|
|
||||||
},
|
|
||||||
toolbarConfig: {
|
|
||||||
search: true,
|
|
||||||
refresh: true,
|
|
||||||
zoom: true,
|
|
||||||
custom: true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
formOptions: {
|
|
||||||
schema: useSearchFormSchema(),
|
|
||||||
showCollapseButton: true,
|
|
||||||
submitOnChange: true,
|
|
||||||
},
|
|
||||||
});
|
});
|
||||||
|
const statusOptions = getStatusOptions();
|
||||||
|
const triggerOptions = getTriggerOptions();
|
||||||
|
const rowIndex = computed(() => (currentPage.value - 1) * pageSize.value);
|
||||||
|
|
||||||
|
async function loadWorkflowOptions() {
|
||||||
|
const res = await getWorkflowListApi({ page: 1, pageSize: 200 });
|
||||||
|
workflowOptions.value = (res.items || []).map((item) => ({
|
||||||
|
label: item.name,
|
||||||
|
value: item.id,
|
||||||
|
}));
|
||||||
|
}
|
||||||
|
|
||||||
|
async function loadRuns() {
|
||||||
|
loading.value = true;
|
||||||
|
try {
|
||||||
|
const res = await getAllWorkflowRunsApi({
|
||||||
|
page: currentPage.value,
|
||||||
|
pageSize: pageSize.value,
|
||||||
|
workflowId: filters.value.workflowId || undefined,
|
||||||
|
status: filters.value.status || undefined,
|
||||||
|
triggerType: filters.value.triggerType || undefined,
|
||||||
|
});
|
||||||
|
rows.value = res.items || [];
|
||||||
|
total.value = res.total || 0;
|
||||||
|
} finally {
|
||||||
|
loading.value = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
function handleSearch() {
|
||||||
|
currentPage.value = 1;
|
||||||
|
loadRuns();
|
||||||
|
}
|
||||||
|
|
||||||
|
function handleSizeChange(size: number) {
|
||||||
|
pageSize.value = size;
|
||||||
|
currentPage.value = 1;
|
||||||
|
loadRuns();
|
||||||
|
}
|
||||||
|
|
||||||
|
function handlePageChange(page: number) {
|
||||||
|
currentPage.value = page;
|
||||||
|
loadRuns();
|
||||||
|
}
|
||||||
|
|
||||||
function openDetail(row: WorkflowRunListItem) {
|
function openDetail(row: WorkflowRunListItem) {
|
||||||
detailRef.value?.open(row.id);
|
detailRef.value?.open(row.id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
onMounted(() => {
|
||||||
|
loadWorkflowOptions();
|
||||||
|
loadRuns();
|
||||||
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<Page auto-content-height>
|
<Page auto-content-height>
|
||||||
<DetailDialog ref="detailRef" />
|
<DetailDialog ref="detailRef" />
|
||||||
|
|
||||||
<Grid>
|
<ElCard shadow="never" class="h-full">
|
||||||
<template #cell-status="{ row }">
|
<ElForm :model="filters" inline class="mb-3">
|
||||||
<RunStatusTag :status="row.status" />
|
<ElFormItem :label="$t('ai-platform.workflowRuns.filters.workflow')">
|
||||||
</template>
|
<ElSelect
|
||||||
|
v-model="filters.workflowId"
|
||||||
|
clearable
|
||||||
|
filterable
|
||||||
|
style="width: 220px"
|
||||||
|
:placeholder="$t('ai-platform.workflowRuns.filters.allWorkflows')"
|
||||||
|
>
|
||||||
|
<ElOption
|
||||||
|
v-for="item in workflowOptions"
|
||||||
|
:key="item.value"
|
||||||
|
:label="item.label"
|
||||||
|
:value="item.value"
|
||||||
|
/>
|
||||||
|
</ElSelect>
|
||||||
|
</ElFormItem>
|
||||||
|
<ElFormItem :label="$t('ai-platform.workflowRuns.filters.status')">
|
||||||
|
<ElSelect
|
||||||
|
v-model="filters.status"
|
||||||
|
clearable
|
||||||
|
style="width: 150px"
|
||||||
|
:placeholder="$t('ai-platform.workflowRuns.filters.allStatus')"
|
||||||
|
>
|
||||||
|
<ElOption
|
||||||
|
v-for="item in statusOptions"
|
||||||
|
:key="item.value"
|
||||||
|
:label="item.label"
|
||||||
|
:value="item.value"
|
||||||
|
/>
|
||||||
|
</ElSelect>
|
||||||
|
</ElFormItem>
|
||||||
|
<ElFormItem :label="$t('ai-platform.workflowRuns.filters.trigger')">
|
||||||
|
<ElSelect
|
||||||
|
v-model="filters.triggerType"
|
||||||
|
clearable
|
||||||
|
style="width: 160px"
|
||||||
|
:placeholder="$t('ai-platform.workflowRuns.filters.allTriggers')"
|
||||||
|
>
|
||||||
|
<ElOption
|
||||||
|
v-for="item in triggerOptions"
|
||||||
|
:key="item.value"
|
||||||
|
:label="item.label"
|
||||||
|
:value="item.value"
|
||||||
|
/>
|
||||||
|
</ElSelect>
|
||||||
|
</ElFormItem>
|
||||||
|
<ElFormItem>
|
||||||
|
<ElButton type="primary" :icon="Search" @click="handleSearch">
|
||||||
|
{{ $t('common.search') }}
|
||||||
|
</ElButton>
|
||||||
|
<ElButton :icon="RefreshCw" @click="loadRuns">
|
||||||
|
{{ $t('common.refresh') }}
|
||||||
|
</ElButton>
|
||||||
|
</ElFormItem>
|
||||||
|
</ElForm>
|
||||||
|
|
||||||
<template #cell-trigger_type="{ row }">
|
<ElTable
|
||||||
<ElTag
|
v-loading="loading"
|
||||||
:type="getTagType(row.trigger_type, triggerOptions)"
|
:data="rows"
|
||||||
size="small"
|
border
|
||||||
|
stripe
|
||||||
|
height="calc(100vh - 285px)"
|
||||||
|
>
|
||||||
|
<ElTableColumn type="index" width="60" :index="rowIndex + 1" />
|
||||||
|
<ElTableColumn
|
||||||
|
prop="workflow_name"
|
||||||
|
:label="$t('ai-platform.workflowRuns.columns.workflow')"
|
||||||
|
min-width="160"
|
||||||
|
show-overflow-tooltip
|
||||||
|
/>
|
||||||
|
<ElTableColumn
|
||||||
|
:label="$t('ai-platform.workflowRuns.columns.status')"
|
||||||
|
width="110"
|
||||||
|
align="center"
|
||||||
>
|
>
|
||||||
{{ getTagLabel(row.trigger_type, triggerOptions) }}
|
<template #default="{ row }">
|
||||||
</ElTag>
|
<RunStatusTag :status="row.status" />
|
||||||
</template>
|
</template>
|
||||||
|
</ElTableColumn>
|
||||||
|
<ElTableColumn
|
||||||
|
:label="$t('ai-platform.workflowRuns.columns.trigger')"
|
||||||
|
width="140"
|
||||||
|
align="center"
|
||||||
|
>
|
||||||
|
<template #default="{ row }">
|
||||||
|
<ElTag
|
||||||
|
:type="getTagType(row.trigger_type, triggerOptions)"
|
||||||
|
size="small"
|
||||||
|
>
|
||||||
|
{{ getTagLabel(row.trigger_type, triggerOptions) }}
|
||||||
|
</ElTag>
|
||||||
|
</template>
|
||||||
|
</ElTableColumn>
|
||||||
|
<ElTableColumn
|
||||||
|
prop="total_steps"
|
||||||
|
:label="$t('ai-platform.workflowRuns.columns.steps')"
|
||||||
|
width="80"
|
||||||
|
align="center"
|
||||||
|
/>
|
||||||
|
<ElTableColumn
|
||||||
|
prop="total_tokens"
|
||||||
|
:label="$t('ai-platform.workflowRuns.columns.tokens')"
|
||||||
|
width="90"
|
||||||
|
align="center"
|
||||||
|
/>
|
||||||
|
<ElTableColumn
|
||||||
|
:label="$t('ai-platform.workflowRuns.columns.duration')"
|
||||||
|
width="100"
|
||||||
|
align="center"
|
||||||
|
>
|
||||||
|
<template #default="{ row }">
|
||||||
|
{{ formatDuration(row.elapsed_time) }}
|
||||||
|
</template>
|
||||||
|
</ElTableColumn>
|
||||||
|
<ElTableColumn
|
||||||
|
:label="$t('ai-platform.workflowRuns.columns.startedAt')"
|
||||||
|
width="180"
|
||||||
|
>
|
||||||
|
<template #default="{ row }">
|
||||||
|
{{ formatTime(row.started_at) }}
|
||||||
|
</template>
|
||||||
|
</ElTableColumn>
|
||||||
|
<ElTableColumn
|
||||||
|
prop="error_message"
|
||||||
|
:label="$t('ai-platform.workflowRuns.columns.error')"
|
||||||
|
min-width="180"
|
||||||
|
show-overflow-tooltip
|
||||||
|
/>
|
||||||
|
<ElTableColumn
|
||||||
|
:label="$t('ai-platform.workflowRuns.columns.actions')"
|
||||||
|
width="120"
|
||||||
|
fixed="right"
|
||||||
|
align="center"
|
||||||
|
>
|
||||||
|
<template #default="{ row }">
|
||||||
|
<ElButton
|
||||||
|
link
|
||||||
|
type="primary"
|
||||||
|
:icon="Eye"
|
||||||
|
@click.stop="openDetail(row)"
|
||||||
|
>
|
||||||
|
{{ $t('common.view') }}
|
||||||
|
</ElButton>
|
||||||
|
</template>
|
||||||
|
</ElTableColumn>
|
||||||
|
</ElTable>
|
||||||
|
|
||||||
<template #cell-elapsed_time="{ row }">
|
<div class="mt-4 flex justify-end">
|
||||||
{{ formatDuration(row.elapsed_time) }}
|
<ElPagination
|
||||||
</template>
|
v-model:current-page="currentPage"
|
||||||
|
v-model:page-size="pageSize"
|
||||||
<template #cell-started_at="{ row }">
|
background
|
||||||
{{ formatTime(row.started_at) }}
|
layout="total, sizes, prev, pager, next, jumper"
|
||||||
</template>
|
:page-sizes="[10, 20, 50, 100]"
|
||||||
|
:total="total"
|
||||||
<template #cell-actions="{ row }">
|
@current-change="handlePageChange"
|
||||||
<ElButton link type="primary" :icon="Eye" @click.stop="openDetail(row)">
|
@size-change="handleSizeChange"
|
||||||
{{ $t('common.view') }}
|
/>
|
||||||
</ElButton>
|
</div>
|
||||||
</template>
|
</ElCard>
|
||||||
</Grid>
|
|
||||||
</Page>
|
</Page>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -1,6 +1,16 @@
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import type { WorkflowStreamEvent } from '#/api/ai-platform/ai-platform';
|
import type { WorkflowStreamEvent } from '#/api/ai-platform/ai-platform';
|
||||||
import type { ChatMessage, ReasoningStep } from '#/components/ChatBox/index';
|
import type { ChatMessage, ReasoningStep } from '#/components/ChatBox/index';
|
||||||
|
import type {
|
||||||
|
AppDesignData,
|
||||||
|
AppSettingsData,
|
||||||
|
DashboardBasicInfoData,
|
||||||
|
DashboardDesignData,
|
||||||
|
DashboardPublishData,
|
||||||
|
DesignData,
|
||||||
|
SystemSummaryData,
|
||||||
|
} from '#/components/form-editor';
|
||||||
|
|
||||||
import { computed, onUnmounted, ref, watch } from 'vue';
|
import { computed, onUnmounted, ref, watch } from 'vue';
|
||||||
|
|
||||||
import { Settings2, X } from '@vben/icons';
|
import { Settings2, X } from '@vben/icons';
|
||||||
@@ -20,6 +30,15 @@ import {
|
|||||||
runWorkflowStreamApi,
|
runWorkflowStreamApi,
|
||||||
} from '#/api/ai-platform/ai-platform';
|
} from '#/api/ai-platform/ai-platform';
|
||||||
import { ChatBox } from '#/components/ChatBox/index';
|
import { ChatBox } from '#/components/ChatBox/index';
|
||||||
|
import {
|
||||||
|
AppDesignPanel,
|
||||||
|
AppSettingsPanel,
|
||||||
|
DashboardBasicInfoConfirmPanel,
|
||||||
|
DashboardDesignConfirmPanel,
|
||||||
|
DashboardPublishConfirmPanel,
|
||||||
|
DesignEditorPanel,
|
||||||
|
SystemSummaryConfirmPanel,
|
||||||
|
} from '#/components/form-editor';
|
||||||
|
|
||||||
const props = defineProps<{
|
const props = defineProps<{
|
||||||
nodes: any[];
|
nodes: any[];
|
||||||
@@ -52,12 +71,37 @@ const waitingConfig = ref<any>(null);
|
|||||||
const currentRunId = ref('');
|
const currentRunId = ref('');
|
||||||
|
|
||||||
// 设计预览编辑面板状态
|
// 设计预览编辑面板状态
|
||||||
|
const showDesignPanel = ref(false);
|
||||||
|
const currentDesign = ref<DesignData | undefined>(undefined);
|
||||||
|
|
||||||
// 应用设计面板状态
|
// 应用设计面板状态
|
||||||
|
const showAppDesignPanel = ref(false);
|
||||||
|
const currentAppDesign = ref<AppDesignData | undefined>(undefined);
|
||||||
|
|
||||||
// 应用设置面板状态
|
// 应用设置面板状态
|
||||||
|
const showAppSettingsPanel = ref(false);
|
||||||
|
const currentAppSettings = ref<AppSettingsData | undefined>(undefined);
|
||||||
|
|
||||||
// 仪表盘基础信息面板状态
|
// 仪表盘基础信息面板状态
|
||||||
|
const showDashboardBasicInfoPanel = ref(false);
|
||||||
|
const currentDashboardBasicInfo = ref<DashboardBasicInfoData | undefined>(
|
||||||
|
undefined,
|
||||||
|
);
|
||||||
|
|
||||||
// 仪表盘设计面板状态
|
// 仪表盘设计面板状态
|
||||||
|
const showDashboardDesignPanel = ref(false);
|
||||||
|
const currentDashboardDesign = ref<DashboardDesignData | undefined>(undefined);
|
||||||
|
|
||||||
// 仪表盘发布面板状态
|
// 仪表盘发布面板状态
|
||||||
|
const showDashboardPublishPanel = ref(false);
|
||||||
|
const currentDashboardPublish = ref<DashboardPublishData | undefined>(
|
||||||
|
undefined,
|
||||||
|
);
|
||||||
|
|
||||||
// 系统总结面板状态
|
// 系统总结面板状态
|
||||||
|
const showSystemSummaryPanel = ref(false);
|
||||||
|
const currentSystemSummary = ref<SystemSummaryData | undefined>(undefined);
|
||||||
|
|
||||||
// 查找 Start 节点并提取变量
|
// 查找 Start 节点并提取变量
|
||||||
const startNode = computed(() => props.nodes.find((n) => n.type === 'start'));
|
const startNode = computed(() => props.nodes.find((n) => n.type === 'start'));
|
||||||
const variables = computed(() => startNode.value?.data?.variables || []);
|
const variables = computed(() => startNode.value?.data?.variables || []);
|
||||||
@@ -546,13 +590,126 @@ const handleStreamEvent = (event: WorkflowStreamEvent, msgId: string) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
case 'waiting_input': {
|
case 'waiting_input': {
|
||||||
|
// 等待用户输入(对话流节点或设计预览)
|
||||||
waitingForInput.value = true;
|
waitingForInput.value = true;
|
||||||
waitingConfig.value = event.waiting_config || event.config;
|
waitingConfig.value = event.waiting_config || event.config;
|
||||||
|
|
||||||
const configData = event.waiting_config || (event as any).config;
|
const configData = event.waiting_config || (event as any).config;
|
||||||
|
|
||||||
|
// 检查是否是设计预览类型
|
||||||
if (configData?.type === 'design_preview') {
|
if (configData?.type === 'design_preview') {
|
||||||
const waitingContent = `**${configData.title}**\n\n${configData.message || $t('ai-platform.workflow.editor.chatPanel.designPreviewHint')}\n\n????????/??/??????????`;
|
// 检查是否是应用设计类型
|
||||||
|
switch (configData.preview_type) {
|
||||||
|
case 'app_design': {
|
||||||
|
// 应用设计:打开专用的应用设计面板
|
||||||
|
currentAppDesign.value = {
|
||||||
|
type: 'app_design',
|
||||||
|
title:
|
||||||
|
configData.title ||
|
||||||
|
$t('ai-platform.workflow.editor.chatPanel.appDesignTitle'),
|
||||||
|
data: configData.data || {},
|
||||||
|
nodeId: event.node_id || '',
|
||||||
|
};
|
||||||
|
showAppDesignPanel.value = true;
|
||||||
|
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'app_settings': {
|
||||||
|
// 应用设置:打开专用的应用设置面板
|
||||||
|
currentAppSettings.value = {
|
||||||
|
type: 'app_settings',
|
||||||
|
title:
|
||||||
|
configData.title ||
|
||||||
|
$t('ai-platform.workflow.editor.chatPanel.appSettingsTitle'),
|
||||||
|
data: configData.data || {},
|
||||||
|
nodeId: event.node_id || '',
|
||||||
|
layoutOptions: configData.layoutOptions || [],
|
||||||
|
themeOptions: configData.themeOptions || [],
|
||||||
|
};
|
||||||
|
showAppSettingsPanel.value = true;
|
||||||
|
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'dashboard_basic_info': {
|
||||||
|
// 仪表盘基础信息:打开专用面板(在聊天框右侧)
|
||||||
|
currentDashboardBasicInfo.value = {
|
||||||
|
type: 'dashboard_basic_info',
|
||||||
|
title:
|
||||||
|
configData.title ||
|
||||||
|
$t(
|
||||||
|
'ai-platform.workflow.editor.chatPanel.dashboardBasicInfoTitle',
|
||||||
|
),
|
||||||
|
data: configData.data || {},
|
||||||
|
nodeId: event.node_id || '',
|
||||||
|
};
|
||||||
|
showDashboardBasicInfoPanel.value = true;
|
||||||
|
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'dashboard_design': {
|
||||||
|
// 仪表盘设计:打开设计器面板(在聊天框右侧)
|
||||||
|
currentDashboardDesign.value = {
|
||||||
|
type: 'dashboard_design',
|
||||||
|
title:
|
||||||
|
configData.title ||
|
||||||
|
$t(
|
||||||
|
'ai-platform.workflow.editor.chatPanel.dashboardDesignTitle',
|
||||||
|
),
|
||||||
|
data: configData.data || {},
|
||||||
|
nodeId: event.node_id || '',
|
||||||
|
};
|
||||||
|
showDashboardDesignPanel.value = true;
|
||||||
|
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'dashboard_publish': {
|
||||||
|
// 仪表盘发布:打开发布确认面板(在聊天框右侧)
|
||||||
|
currentDashboardPublish.value = {
|
||||||
|
type: 'dashboard_publish',
|
||||||
|
title:
|
||||||
|
configData.title ||
|
||||||
|
$t(
|
||||||
|
'ai-platform.workflow.editor.chatPanel.dashboardPublishTitle',
|
||||||
|
),
|
||||||
|
data: configData.data || {},
|
||||||
|
nodeId: event.node_id || '',
|
||||||
|
};
|
||||||
|
showDashboardPublishPanel.value = true;
|
||||||
|
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'system_summary': {
|
||||||
|
// 系统总结:打开总结展示面板
|
||||||
|
currentSystemSummary.value = {
|
||||||
|
type: 'system_summary',
|
||||||
|
title:
|
||||||
|
configData.title ||
|
||||||
|
$t('ai-platform.workflow.editor.chatPanel.systemSummaryTitle'),
|
||||||
|
data: configData.data || {},
|
||||||
|
nodeId: event.node_id || '',
|
||||||
|
};
|
||||||
|
showSystemSummaryPanel.value = true;
|
||||||
|
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
default: {
|
||||||
|
// 其他设计预览:打开通用设计编辑面板
|
||||||
|
currentDesign.value = {
|
||||||
|
type: configData.preview_type,
|
||||||
|
title:
|
||||||
|
configData.title ||
|
||||||
|
$t('ai-platform.workflow.editor.chatPanel.designPreviewTitle'),
|
||||||
|
data: configData.data || {},
|
||||||
|
nodeId: event.node_id || '',
|
||||||
|
form_fields: configData.form_fields || [], // 传递表单字段列表(用于列表设计)
|
||||||
|
table_configs: configData.table_configs || [], // 传递数据表配置(用于表单设计)
|
||||||
|
};
|
||||||
|
showDesignPanel.value = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 显示提示消息
|
||||||
|
const waitingContent = `**${configData.title}**\n\n${configData.message || $t('ai-platform.workflow.editor.chatPanel.designPreviewHint')}`;
|
||||||
const initialMsg = messages.value.find((m) => m.id === msgId);
|
const initialMsg = messages.value.find((m) => m.id === msgId);
|
||||||
if (initialMsg && !initialMsg.content?.trim()) {
|
if (initialMsg && !initialMsg.content?.trim()) {
|
||||||
updateAssistantMessage(msgId, {
|
updateAssistantMessage(msgId, {
|
||||||
@@ -570,15 +727,20 @@ const handleStreamEvent = (event: WorkflowStreamEvent, msgId: string) => {
|
|||||||
messages.value.push(newMsg);
|
messages.value.push(newMsg);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
// 普通对话流交互
|
||||||
const waitingContent = getWaitingPrompt(configData);
|
const waitingContent = getWaitingPrompt(configData);
|
||||||
|
|
||||||
|
// 检查初始消息是否还是 typing indicator(没有内容)
|
||||||
const initialMsg = messages.value.find((m) => m.id === msgId);
|
const initialMsg = messages.value.find((m) => m.id === msgId);
|
||||||
if (initialMsg && !initialMsg.content?.trim()) {
|
if (initialMsg && !initialMsg.content?.trim()) {
|
||||||
|
// 更新初始消息为等待输入的内容
|
||||||
updateAssistantMessage(msgId, {
|
updateAssistantMessage(msgId, {
|
||||||
status: 'completed',
|
status: 'completed',
|
||||||
content: waitingContent,
|
content: waitingContent,
|
||||||
interaction: configData as any,
|
interaction: configData as any,
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
|
// 已有内容,创建新的助手消息
|
||||||
const newMsg: ChatMessage = {
|
const newMsg: ChatMessage = {
|
||||||
id: generateId(),
|
id: generateId(),
|
||||||
role: 'assistant',
|
role: 'assistant',
|
||||||
@@ -590,7 +752,7 @@ const handleStreamEvent = (event: WorkflowStreamEvent, msgId: string) => {
|
|||||||
messages.value.push(newMsg);
|
messages.value.push(newMsg);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
running.value = false;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -789,6 +951,209 @@ const handleUpdateMessage = (
|
|||||||
};
|
};
|
||||||
|
|
||||||
// 处理设计预览确认
|
// 处理设计预览确认
|
||||||
|
const handleDesignConfirm = (data: Record<string, any>) => {
|
||||||
|
showDesignPanel.value = false;
|
||||||
|
currentDesign.value = undefined;
|
||||||
|
|
||||||
|
// 添加用户确认消息
|
||||||
|
const userMsg: ChatMessage = {
|
||||||
|
id: generateId(),
|
||||||
|
role: 'user',
|
||||||
|
content: $t('ai-platform.workflow.editor.chatPanel.confirmDesign'),
|
||||||
|
timestamp: new Date(),
|
||||||
|
};
|
||||||
|
messages.value.push(userMsg);
|
||||||
|
|
||||||
|
// 重置等待状态
|
||||||
|
waitingForInput.value = false;
|
||||||
|
waitingConfig.value = null;
|
||||||
|
|
||||||
|
// 恢复工作流,传递编辑后的数据
|
||||||
|
resumeWorkflow(JSON.stringify(data));
|
||||||
|
};
|
||||||
|
|
||||||
|
// 处理设计预览关闭
|
||||||
|
const handleDesignClose = () => {
|
||||||
|
showDesignPanel.value = false;
|
||||||
|
currentDesign.value = undefined;
|
||||||
|
};
|
||||||
|
|
||||||
|
// 处理应用设计确认
|
||||||
|
const handleAppDesignConfirm = (data: Record<string, any>) => {
|
||||||
|
showAppDesignPanel.value = false;
|
||||||
|
currentAppDesign.value = undefined;
|
||||||
|
|
||||||
|
// 添加用户确认消息
|
||||||
|
const userMsg: ChatMessage = {
|
||||||
|
id: generateId(),
|
||||||
|
role: 'user',
|
||||||
|
content: $t('ai-platform.workflow.editor.chatPanel.confirmAppDesign'),
|
||||||
|
timestamp: new Date(),
|
||||||
|
};
|
||||||
|
messages.value.push(userMsg);
|
||||||
|
|
||||||
|
// 重置等待状态
|
||||||
|
waitingForInput.value = false;
|
||||||
|
waitingConfig.value = null;
|
||||||
|
|
||||||
|
// 恢复工作流,传递编辑后的数据
|
||||||
|
resumeWorkflow(JSON.stringify(data));
|
||||||
|
};
|
||||||
|
|
||||||
|
// 处理应用设计面板关闭
|
||||||
|
const handleAppDesignClose = () => {
|
||||||
|
showAppDesignPanel.value = false;
|
||||||
|
currentAppDesign.value = undefined;
|
||||||
|
};
|
||||||
|
|
||||||
|
// 处理应用设置确认
|
||||||
|
const handleAppSettingsConfirm = (data: Record<string, any>) => {
|
||||||
|
showAppSettingsPanel.value = false;
|
||||||
|
currentAppSettings.value = undefined;
|
||||||
|
|
||||||
|
// 添加用户确认消息
|
||||||
|
const userMsg: ChatMessage = {
|
||||||
|
id: generateId(),
|
||||||
|
role: 'user',
|
||||||
|
content: $t('ai-platform.workflow.editor.chatPanel.confirmAppSettings'),
|
||||||
|
timestamp: new Date(),
|
||||||
|
};
|
||||||
|
messages.value.push(userMsg);
|
||||||
|
|
||||||
|
// 重置等待状态
|
||||||
|
waitingForInput.value = false;
|
||||||
|
waitingConfig.value = null;
|
||||||
|
|
||||||
|
// 恢复工作流,传递编辑后的数据
|
||||||
|
resumeWorkflow(JSON.stringify(data));
|
||||||
|
};
|
||||||
|
|
||||||
|
// 处理应用设置面板关闭
|
||||||
|
const handleAppSettingsClose = () => {
|
||||||
|
showAppSettingsPanel.value = false;
|
||||||
|
currentAppSettings.value = undefined;
|
||||||
|
};
|
||||||
|
|
||||||
|
// 处理仪表盘基础信息确认
|
||||||
|
const handleDashboardBasicInfoConfirm = (data: Record<string, any>) => {
|
||||||
|
showDashboardBasicInfoPanel.value = false;
|
||||||
|
currentDashboardBasicInfo.value = undefined;
|
||||||
|
|
||||||
|
// 添加用户确认消息
|
||||||
|
const userMsg: ChatMessage = {
|
||||||
|
id: generateId(),
|
||||||
|
role: 'user',
|
||||||
|
content: $t(
|
||||||
|
'ai-platform.workflow.editor.chatPanel.confirmDashboardBasicInfo',
|
||||||
|
),
|
||||||
|
timestamp: new Date(),
|
||||||
|
};
|
||||||
|
messages.value.push(userMsg);
|
||||||
|
|
||||||
|
// 重置等待状态
|
||||||
|
waitingForInput.value = false;
|
||||||
|
waitingConfig.value = null;
|
||||||
|
|
||||||
|
// 恢复工作流,传递编辑后的数据
|
||||||
|
resumeWorkflow(JSON.stringify(data));
|
||||||
|
};
|
||||||
|
|
||||||
|
// 处理仪表盘基础信息面板关闭
|
||||||
|
const handleDashboardBasicInfoClose = () => {
|
||||||
|
showDashboardBasicInfoPanel.value = false;
|
||||||
|
currentDashboardBasicInfo.value = undefined;
|
||||||
|
};
|
||||||
|
|
||||||
|
// 处理仪表盘设计确认
|
||||||
|
const handleDashboardDesignConfirm = (data: Record<string, any>) => {
|
||||||
|
showDashboardDesignPanel.value = false;
|
||||||
|
currentDashboardDesign.value = undefined;
|
||||||
|
|
||||||
|
// 添加用户确认消息
|
||||||
|
const userMsg: ChatMessage = {
|
||||||
|
id: generateId(),
|
||||||
|
role: 'user',
|
||||||
|
content: $t('ai-platform.workflow.editor.chatPanel.confirmDashboardDesign'),
|
||||||
|
timestamp: new Date(),
|
||||||
|
};
|
||||||
|
messages.value.push(userMsg);
|
||||||
|
|
||||||
|
// 重置等待状态
|
||||||
|
waitingForInput.value = false;
|
||||||
|
waitingConfig.value = null;
|
||||||
|
|
||||||
|
// 恢复工作流,传递编辑后的数据
|
||||||
|
resumeWorkflow(JSON.stringify(data));
|
||||||
|
};
|
||||||
|
|
||||||
|
// 处理仪表盘设计面板关闭
|
||||||
|
const handleDashboardDesignClose = () => {
|
||||||
|
showDashboardDesignPanel.value = false;
|
||||||
|
currentDashboardDesign.value = undefined;
|
||||||
|
};
|
||||||
|
|
||||||
|
// 处理仪表盘发布确认
|
||||||
|
const handleDashboardPublishConfirm = (data: Record<string, any>) => {
|
||||||
|
console.log('[ChatPanel] 接收到发布确认数据:', data);
|
||||||
|
showDashboardPublishPanel.value = false;
|
||||||
|
currentDashboardPublish.value = undefined;
|
||||||
|
|
||||||
|
// 添加用户确认消息
|
||||||
|
const userMsg: ChatMessage = {
|
||||||
|
id: generateId(),
|
||||||
|
role: 'user',
|
||||||
|
content: $t('ai-platform.workflow.editor.chatPanel.publishToMenu', {
|
||||||
|
name: data.menu_name,
|
||||||
|
}),
|
||||||
|
timestamp: new Date(),
|
||||||
|
};
|
||||||
|
messages.value.push(userMsg);
|
||||||
|
|
||||||
|
// 重置等待状态
|
||||||
|
waitingForInput.value = false;
|
||||||
|
waitingConfig.value = null;
|
||||||
|
|
||||||
|
// 恢复工作流,传递发布数据
|
||||||
|
const userInputStr = JSON.stringify(data);
|
||||||
|
console.log('[ChatPanel] 传递给 resumeWorkflow 的数据:', userInputStr);
|
||||||
|
resumeWorkflow(userInputStr);
|
||||||
|
};
|
||||||
|
|
||||||
|
// 处理仪表盘发布面板关闭
|
||||||
|
const handleDashboardPublishClose = () => {
|
||||||
|
showDashboardPublishPanel.value = false;
|
||||||
|
currentDashboardPublish.value = undefined;
|
||||||
|
};
|
||||||
|
|
||||||
|
// 处理系统总结确认
|
||||||
|
const handleSystemSummaryConfirm = (data: Record<string, any>) => {
|
||||||
|
showSystemSummaryPanel.value = false;
|
||||||
|
currentSystemSummary.value = undefined;
|
||||||
|
|
||||||
|
// 添加用户确认消息
|
||||||
|
const userMsg: ChatMessage = {
|
||||||
|
id: generateId(),
|
||||||
|
role: 'user',
|
||||||
|
content: $t('ai-platform.workflow.editor.chatPanel.complete'),
|
||||||
|
timestamp: new Date(),
|
||||||
|
};
|
||||||
|
messages.value.push(userMsg);
|
||||||
|
|
||||||
|
// 重置等待状态
|
||||||
|
waitingForInput.value = false;
|
||||||
|
waitingConfig.value = null;
|
||||||
|
|
||||||
|
// 恢复工作流,传递确认数据
|
||||||
|
resumeWorkflow(JSON.stringify(data));
|
||||||
|
};
|
||||||
|
|
||||||
|
// 处理系统总结面板关闭
|
||||||
|
const handleSystemSummaryClose = () => {
|
||||||
|
showSystemSummaryPanel.value = false;
|
||||||
|
currentSystemSummary.value = undefined;
|
||||||
|
};
|
||||||
|
|
||||||
|
// 组件卸载时取消流
|
||||||
onUnmounted(() => {
|
onUnmounted(() => {
|
||||||
cancelStream?.();
|
cancelStream?.();
|
||||||
});
|
});
|
||||||
@@ -884,17 +1249,66 @@ onUnmounted(() => {
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- 设计编辑面板 -->
|
<!-- 设计编辑面板 -->
|
||||||
|
<DesignEditorPanel
|
||||||
|
:visible="showDesignPanel"
|
||||||
|
:design="currentDesign"
|
||||||
|
@update:visible="showDesignPanel = $event"
|
||||||
|
@confirm="handleDesignConfirm"
|
||||||
|
@close="handleDesignClose"
|
||||||
|
/>
|
||||||
|
|
||||||
<!-- 应用设计面板 -->
|
<!-- 应用设计面板 -->
|
||||||
|
<AppDesignPanel
|
||||||
|
:visible="showAppDesignPanel"
|
||||||
|
:design="currentAppDesign"
|
||||||
|
@update:visible="showAppDesignPanel = $event"
|
||||||
|
@confirm="handleAppDesignConfirm"
|
||||||
|
@close="handleAppDesignClose"
|
||||||
|
/>
|
||||||
|
|
||||||
<!-- 应用设置面板 -->
|
<!-- 应用设置面板 -->
|
||||||
|
<AppSettingsPanel
|
||||||
|
:visible="showAppSettingsPanel"
|
||||||
|
:settings="currentAppSettings"
|
||||||
|
@update:visible="showAppSettingsPanel = $event"
|
||||||
|
@confirm="handleAppSettingsConfirm"
|
||||||
|
@close="handleAppSettingsClose"
|
||||||
|
/>
|
||||||
|
|
||||||
<!-- 仪表盘基础信息面板 -->
|
<!-- 仪表盘基础信息面板 -->
|
||||||
|
<DashboardBasicInfoConfirmPanel
|
||||||
|
:visible="showDashboardBasicInfoPanel"
|
||||||
|
:basic-info="currentDashboardBasicInfo"
|
||||||
|
@update:visible="showDashboardBasicInfoPanel = $event"
|
||||||
|
@confirm="handleDashboardBasicInfoConfirm"
|
||||||
|
@close="handleDashboardBasicInfoClose"
|
||||||
|
/>
|
||||||
|
|
||||||
<!-- 仪表盘设计面板 -->
|
<!-- 仪表盘设计面板 -->
|
||||||
|
<DashboardDesignConfirmPanel
|
||||||
|
:visible="showDashboardDesignPanel"
|
||||||
|
:design="currentDashboardDesign"
|
||||||
|
@update:visible="showDashboardDesignPanel = $event"
|
||||||
|
@confirm="handleDashboardDesignConfirm"
|
||||||
|
@close="handleDashboardDesignClose"
|
||||||
|
/>
|
||||||
|
|
||||||
<!-- 仪表盘发布面板 -->
|
<!-- 仪表盘发布面板 -->
|
||||||
|
<DashboardPublishConfirmPanel
|
||||||
|
:visible="showDashboardPublishPanel"
|
||||||
|
:publish-data="currentDashboardPublish"
|
||||||
|
@update:visible="showDashboardPublishPanel = $event"
|
||||||
|
@confirm="handleDashboardPublishConfirm"
|
||||||
|
@close="handleDashboardPublishClose"
|
||||||
|
/>
|
||||||
|
|
||||||
<!-- 系统总结面板 -->
|
<!-- 系统总结面板 -->
|
||||||
|
<SystemSummaryConfirmPanel
|
||||||
|
:visible="showSystemSummaryPanel"
|
||||||
|
:data="currentSystemSummary"
|
||||||
|
@update:visible="showSystemSummaryPanel = $event"
|
||||||
|
@confirm="handleSystemSummaryConfirm"
|
||||||
|
@close="handleSystemSummaryClose"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
+418
@@ -2,16 +2,20 @@
|
|||||||
import { computed, ref } from 'vue';
|
import { computed, ref } from 'vue';
|
||||||
|
|
||||||
import {
|
import {
|
||||||
|
AppWindow,
|
||||||
BookOpen,
|
BookOpen,
|
||||||
Bot,
|
Bot,
|
||||||
ChevronDown,
|
ChevronDown,
|
||||||
ChevronRight,
|
ChevronRight,
|
||||||
CircleHelp,
|
CircleHelp,
|
||||||
|
ClipboardCheck,
|
||||||
Code,
|
Code,
|
||||||
Combine,
|
Combine,
|
||||||
Database,
|
Database,
|
||||||
|
FileText,
|
||||||
Globe,
|
Globe,
|
||||||
HelpCircle,
|
HelpCircle,
|
||||||
|
LayoutDashboard,
|
||||||
LayoutTemplate,
|
LayoutTemplate,
|
||||||
ListChecks,
|
ListChecks,
|
||||||
MessageSquareText,
|
MessageSquareText,
|
||||||
@@ -61,9 +65,21 @@ const icons: any = {
|
|||||||
// 合并节点
|
// 合并节点
|
||||||
merge: Combine,
|
merge: Combine,
|
||||||
// 表单节点
|
// 表单节点
|
||||||
|
form_basic_info: FileText,
|
||||||
|
form_database_design: Database,
|
||||||
|
form_database_create: Database,
|
||||||
// 应用节点
|
// 应用节点
|
||||||
|
app_create: AppWindow,
|
||||||
|
app_design: LayoutDashboard,
|
||||||
|
app_settings: LayoutDashboard,
|
||||||
|
app_update: LayoutDashboard,
|
||||||
// 仪表盘节点
|
// 仪表盘节点
|
||||||
|
dashboard_basic_info: LayoutDashboard,
|
||||||
|
dashboard_design: LayoutDashboard,
|
||||||
|
dashboard_create: LayoutDashboard,
|
||||||
|
dashboard_publish: LayoutDashboard,
|
||||||
// 系统总结节点
|
// 系统总结节点
|
||||||
|
system_summary: ClipboardCheck,
|
||||||
// 子流程节点
|
// 子流程节点
|
||||||
subflow: Play,
|
subflow: Play,
|
||||||
// 知识库检索节点
|
// 知识库检索节点
|
||||||
@@ -123,6 +139,92 @@ const availableNodes = computed(() => {
|
|||||||
|
|
||||||
// 根据节点类型获取输出变量 schema
|
// 根据节点类型获取输出变量 schema
|
||||||
switch (node.type) {
|
switch (node.type) {
|
||||||
|
case 'app_create': {
|
||||||
|
variables = [
|
||||||
|
{
|
||||||
|
key: 'app_id',
|
||||||
|
label: $t('ai-platform.workflow.editor.variableSelector.appId'),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'app_code',
|
||||||
|
label: $t('ai-platform.workflow.editor.variableSelector.appCode'),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'app_name',
|
||||||
|
label: $t('ai-platform.workflow.editor.variableSelector.appName'),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'success',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.createSuccess',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'app_design': {
|
||||||
|
variables = [
|
||||||
|
{
|
||||||
|
key: 'design_content',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.designContent',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'design_title',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.designTitle',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'confirmed',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.isConfirmed',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'app_settings': {
|
||||||
|
variables = [
|
||||||
|
{
|
||||||
|
key: 'settings',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.appSettings',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'confirmed',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.isConfirmed',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'app_update': {
|
||||||
|
variables = [
|
||||||
|
{
|
||||||
|
key: 'update_success',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.updateSuccess',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'config_id',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.configId',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'update_message',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.updateMessage',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
break;
|
||||||
|
}
|
||||||
case 'choice': {
|
case 'choice': {
|
||||||
const choiceVar = node.data.variable_name || 'user_choice';
|
const choiceVar = node.data.variable_name || 'user_choice';
|
||||||
variables = [
|
variables = [
|
||||||
@@ -178,6 +280,96 @@ const availableNodes = computed(() => {
|
|||||||
];
|
];
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
case 'dashboard_basic_info': {
|
||||||
|
variables = [
|
||||||
|
{
|
||||||
|
key: 'dashboard_basic_info',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.dashboardBasicInfo',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'dashboard_name',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.dashboardName',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'dashboard_code',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.dashboardCode',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'dashboard_create': {
|
||||||
|
variables = [
|
||||||
|
{
|
||||||
|
key: 'dashboard_id',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.dashboardId',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'dashboard_code',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.dashboardCode',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'page_meta',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.pageMeta',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'dashboard_design': {
|
||||||
|
variables = [
|
||||||
|
{
|
||||||
|
key: 'page_config',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.pageConfig',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'design_title',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.designTitle',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'confirmed',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.isConfirmed',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'dashboard_publish': {
|
||||||
|
variables = [
|
||||||
|
{
|
||||||
|
key: 'menu_id',
|
||||||
|
label: $t('ai-platform.workflow.editor.variableSelector.menuId'),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'route_path',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.routePath',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'publish_result',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.publishResult',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
break;
|
||||||
|
}
|
||||||
case 'db_delete': {
|
case 'db_delete': {
|
||||||
const deleteOutputVar = node.data.output_variable || 'delete_result';
|
const deleteOutputVar = node.data.output_variable || 'delete_result';
|
||||||
variables = [
|
variables = [
|
||||||
@@ -268,6 +460,205 @@ const availableNodes = computed(() => {
|
|||||||
];
|
];
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
case 'form_basic_info': {
|
||||||
|
variables = [
|
||||||
|
{
|
||||||
|
key: 'form_basic_info',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.formBasicInfoObj',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'form_name',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.formName',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'form_code',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.formCode',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'form_type',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.formType',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'form_description',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.formDescription',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'form_sort',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.formSort',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'form_create': {
|
||||||
|
variables = [
|
||||||
|
{
|
||||||
|
key: 'form_id',
|
||||||
|
label: $t('ai-platform.workflow.editor.variableSelector.formId'),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'form_code',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.formCode',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'form_meta',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.formMeta',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'form_database_create': {
|
||||||
|
variables = [
|
||||||
|
{
|
||||||
|
key: 'creation_result',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.creationResult',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'all_tables_ready',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.allTablesReady',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'created_count',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.createdCount',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'error_count',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.errorCount',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'schema_name',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.schemaName',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'table_name',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.tableName',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'form_database_design': {
|
||||||
|
variables = [
|
||||||
|
{
|
||||||
|
key: 'database_design',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.dbDesignObj',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'table_name',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.tableName',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'field_count',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.fieldCount',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'form_list_design': {
|
||||||
|
variables = [
|
||||||
|
{
|
||||||
|
key: 'list_config',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.listConfig',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'query_field_count',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.queryFieldCount',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'column_count',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.columnCount',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'form_publish': {
|
||||||
|
variables = [
|
||||||
|
{
|
||||||
|
key: 'menu_id',
|
||||||
|
label: $t('ai-platform.workflow.editor.variableSelector.menuId'),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'route_path',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.routePath',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'publish_result',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.publishResult',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case 'form_ui_design': {
|
||||||
|
variables = [
|
||||||
|
{
|
||||||
|
key: 'form_ui_design',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.formUiDesign',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'form_code',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.formCode',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'field_count',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.fieldCount',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'group_count',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.groupCount',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
break;
|
||||||
|
}
|
||||||
case 'http': {
|
case 'http': {
|
||||||
variables = [
|
variables = [
|
||||||
{
|
{
|
||||||
@@ -574,6 +965,33 @@ const availableNodes = computed(() => {
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
case 'system_summary': {
|
||||||
|
variables = [
|
||||||
|
{
|
||||||
|
key: 'summary',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.summaryData',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'total_forms',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.totalForms',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'has_app',
|
||||||
|
label: $t('ai-platform.workflow.editor.variableSelector.hasApp'),
|
||||||
|
},
|
||||||
|
{
|
||||||
|
key: 'has_dashboard',
|
||||||
|
label: $t(
|
||||||
|
'ai-platform.workflow.editor.variableSelector.hasDashboard',
|
||||||
|
),
|
||||||
|
},
|
||||||
|
];
|
||||||
|
break;
|
||||||
|
}
|
||||||
case 'template': {
|
case 'template': {
|
||||||
const templateOutputVar =
|
const templateOutputVar =
|
||||||
node.data.output_variable || 'template_result';
|
node.data.output_variable || 'template_result';
|
||||||
|
|||||||
@@ -1,15 +1,31 @@
|
|||||||
import { defineConfig } from '@vben/vite-config';
|
import { defineConfig } from '@vben/vite-config';
|
||||||
|
|
||||||
import ElementPlus from 'unplugin-element-plus/vite';
|
import ElementPlus from 'unplugin-element-plus/vite';
|
||||||
import { createLogger } from 'vite';
|
|
||||||
|
|
||||||
const viteLogger = createLogger();
|
|
||||||
|
|
||||||
export default defineConfig(async () => {
|
export default defineConfig(async () => {
|
||||||
return {
|
return {
|
||||||
application: {},
|
application: {},
|
||||||
vite: {
|
vite: {
|
||||||
customLogger: viteLogger,
|
resolve: {
|
||||||
|
alias: {
|
||||||
|
'#/components/form-editor':
|
||||||
|
'/opt/apps/ai-agent-admin-vben/web/apps/web-ele/src/components/ai-chat-panel/form-editor-lite.ts',
|
||||||
|
'@vben-core/shared/cache':
|
||||||
|
'/opt/apps/ai-agent-admin-vben/web/packages/@core/base/shared/src/cache/index.ts',
|
||||||
|
'@vben-core/shared/color':
|
||||||
|
'/opt/apps/ai-agent-admin-vben/web/packages/@core/base/shared/src/color/index.ts',
|
||||||
|
'@vben-core/shared/constants':
|
||||||
|
'/opt/apps/ai-agent-admin-vben/web/packages/@core/base/shared/src/constants/index.ts',
|
||||||
|
'@vben-core/shared/global-state':
|
||||||
|
'/opt/apps/ai-agent-admin-vben/web/packages/@core/base/shared/src/global-state.ts',
|
||||||
|
'@vben-core/shared/store':
|
||||||
|
'/opt/apps/ai-agent-admin-vben/web/packages/@core/base/shared/src/store.ts',
|
||||||
|
'@vben-core/shared/utils':
|
||||||
|
'/opt/apps/ai-agent-admin-vben/web/packages/@core/base/shared/src/utils/index.ts',
|
||||||
|
'pinia-plugin-persistedstate':
|
||||||
|
'/opt/apps/ai-agent-admin-vben/web/node_modules/.pnpm/pinia-plugin-persistedstate@4.7.1_@nuxt+kit@3.20.1_magicast@0.5.1__pinia@3.0.4_typescri_81307ef2ad6357254c03f94e9f8090c4/node_modules/pinia-plugin-persistedstate/dist/index.js',
|
||||||
|
},
|
||||||
|
},
|
||||||
plugins: [
|
plugins: [
|
||||||
ElementPlus({
|
ElementPlus({
|
||||||
format: 'esm',
|
format: 'esm',
|
||||||
|
|||||||
Reference in New Issue
Block a user