From d7afe916e24fde153719d97ae61858bcdf60268a Mon Sep 17 00:00:00 2001 From: Feynman Date: Sat, 15 Mar 2025 19:50:52 +0800 Subject: [PATCH 01/46] feat: add incremental validation --- packages/api/src/TaskInspect.ts | 62 ++++ packages/api/src/index.js | 6 +- packages/assets/icons/svg/data-scan.svg | 10 + packages/dag/src/Editor.vue | 1 + .../src/components/DataValidationDialog.vue | 298 +++++++++++++++ packages/dag/src/components/TopHeader.vue | 34 +- .../src/components/monitor/BottomPanel.vue | 7 +- .../components/InspectDetailDialog.vue | 338 ++++++++++++++++++ .../monitor/components/TaskInspect.vue | 237 ++++++++++++ packages/dag/src/locale/lang/en.js | 53 ++- packages/dag/src/locale/lang/zh-CN.js | 54 ++- packages/dag/src/locale/lang/zh-TW.js | 26 +- packages/i18n/src/locale/lang/en.js | 4 +- packages/i18n/src/locale/lang/zh-CN.js | 4 +- packages/i18n/src/locale/lang/zh-TW.js | 4 +- 15 files changed, 1123 insertions(+), 15 deletions(-) create mode 100644 packages/api/src/TaskInspect.ts create mode 100644 packages/assets/icons/svg/data-scan.svg create mode 100644 packages/dag/src/components/DataValidationDialog.vue create mode 100644 packages/dag/src/components/monitor/components/InspectDetailDialog.vue create mode 100644 packages/dag/src/components/monitor/components/TaskInspect.vue diff --git a/packages/api/src/TaskInspect.ts b/packages/api/src/TaskInspect.ts new file mode 100644 index 0000000000..4c59df828a --- /dev/null +++ b/packages/api/src/TaskInspect.ts @@ -0,0 +1,62 @@ +import Http from './Http' + +interface TaskInspectConfig { + custom: { + cdc: { + enable: boolean + sample: { + interval: number + limit: number + } + type: 'CLOSE' | 'SAMPLE' + } + full?: { + enable: boolean + cron: string + diffEnable: boolean + diffLimit: number + diffRetryTimes: number + sampleLimit: number + samplePercent: number + trigger: string + type: string + } + } + intelligent?: { + cdcSampleInterval: number + cdcSampleLimit: number + enableRecover: boolean + fullDiffLimit: number + fullSampleLimit: number + } + mode: 'CLOSE' | 'INTELLIGENT' | 'CUSTOM' +} + +export default class TaskInspect extends Http { + constructor() { + super('/api/task-inspect') + } + + getConfig(taskId: string, params: any): Promise { + return this.axios.get(this.url + `/${taskId}`, { params }).catch(err => { + console.error(err) + return Promise.resolve({ + mode: 'CUSTOM', + custom: { + cdc: { + enable: true, + sample: { interval: 60, limit: 20 } + } + } + }) + }) + } + + putConfig(taskId: string, params: TaskInspectConfig) { + return this.axios.put(this.url + `/${taskId}`, params) + } + + getHistories(taskId: string, params: any) { + return this.axios.get(this.url + `/${taskId}/histories`, { params }) + } +} diff --git a/packages/api/src/index.js b/packages/api/src/index.js index 4121739356..9d1105cd31 100644 --- a/packages/api/src/index.js +++ b/packages/api/src/index.js @@ -189,6 +189,9 @@ const agentGroupApi = new AgentGroup() import Webhook from './Webhook' const webhookApi = new Webhook() +import TaskInspect from './TaskInspect' +const taskInspectApi = new TaskInspect() + export { connectionsApi, databaseTypesApi, @@ -252,7 +255,8 @@ export { connectorRecordApi, alarmMailApi, agentGroupApi, - webhookApi + webhookApi, + taskInspectApi } export * from './ApiClient' diff --git a/packages/assets/icons/svg/data-scan.svg b/packages/assets/icons/svg/data-scan.svg new file mode 100644 index 0000000000..a1359d996c --- /dev/null +++ b/packages/assets/icons/svg/data-scan.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/packages/dag/src/Editor.vue b/packages/dag/src/Editor.vue index a9dbe32f8e..600786501f 100644 --- a/packages/dag/src/Editor.vue +++ b/packages/dag/src/Editor.vue @@ -25,6 +25,7 @@ @debug-start="handleStart(true)" @stop="handleStop" @forceStop="handleForceStop" + j @reset="handleReset" @edit="handleEdit" @detail="handleDetail" diff --git a/packages/dag/src/components/DataValidationDialog.vue b/packages/dag/src/components/DataValidationDialog.vue new file mode 100644 index 0000000000..978329546b --- /dev/null +++ b/packages/dag/src/components/DataValidationDialog.vue @@ -0,0 +1,298 @@ + + + + + diff --git a/packages/dag/src/components/TopHeader.vue b/packages/dag/src/components/TopHeader.vue index 7c270a9ab5..87b0bb9c38 100644 --- a/packages/dag/src/components/TopHeader.vue +++ b/packages/dag/src/components/TopHeader.vue @@ -162,6 +162,12 @@ bug-outlined + + + +
@@ -254,6 +260,14 @@ @update:visible="openDebug = $event" @start="$emit('debug-start')" > + + @@ -265,6 +279,7 @@ import { TaskStatus } from '@tap/business' import focusSelect from '@tap/component/src/directives/focusSelect' import { taskApi } from '@tap/api' import DataCaptureDebug from './DataCaptureDebug.vue' +import DataValidationDialog from './DataValidationDialog.vue' export default { name: 'TopHeader', @@ -287,6 +302,7 @@ export default { components: { DataCaptureDebug, + DataValidationDialog, TextEditable, TaskStatus, VDivider, @@ -312,7 +328,16 @@ export default { showSearchNodePopover: false, nodeSearchInput: '', refreshing: false, - openDebug: false + openDebug: false, + openValidation: false, + validationSettings: { + enabled: false, + type: 'incremental', + frequency: { + time: 1, + records: 10 + } + } } }, @@ -391,6 +416,13 @@ export default { this.$emit('locate-node', node) }, + handleSaveValidation(settings) { + // Save validation settings to the server + this.validationSettings = settings + // You might want to make an API call here to save the settings + console.log('Validation settings saved:', settings) + }, + refreshSchema() { if (this.refreshing) return diff --git a/packages/dag/src/components/monitor/BottomPanel.vue b/packages/dag/src/components/monitor/BottomPanel.vue index 9528785151..d99c2f9ada 100644 --- a/packages/dag/src/components/monitor/BottomPanel.vue +++ b/packages/dag/src/components/monitor/BottomPanel.vue @@ -49,6 +49,10 @@ @load-data="$emit('load-data')" > + + + + close @@ -68,12 +72,13 @@ import MilestoneList from '@tap/business/src/components/milestone/List' import Record from './components/Record' import Alert from './components/Alert' +import TaskInspect from './components/TaskInspect' import { taskApi } from '@tap/api' export default { name: 'ConfigPanel', - components: { Record, Alert, RelationList, NodeLog, MilestoneList }, + components: { Record, Alert, RelationList, NodeLog, MilestoneList, TaskInspect }, directives: { resize, diff --git a/packages/dag/src/components/monitor/components/InspectDetailDialog.vue b/packages/dag/src/components/monitor/components/InspectDetailDialog.vue new file mode 100644 index 0000000000..6be6ba9eb9 --- /dev/null +++ b/packages/dag/src/components/monitor/components/InspectDetailDialog.vue @@ -0,0 +1,338 @@ + + + + + diff --git a/packages/dag/src/components/monitor/components/TaskInspect.vue b/packages/dag/src/components/monitor/components/TaskInspect.vue new file mode 100644 index 0000000000..3f13fd2bf0 --- /dev/null +++ b/packages/dag/src/components/monitor/components/TaskInspect.vue @@ -0,0 +1,237 @@ + + + + + diff --git a/packages/dag/src/locale/lang/en.js b/packages/dag/src/locale/lang/en.js index fb84b042ad..68ccc30b8d 100644 --- a/packages/dag/src/locale/lang/en.js +++ b/packages/dag/src/locale/lang/en.js @@ -795,7 +795,7 @@ export default { 'When enabled, the child tables are filtered out; when disabled, the main table is filtered out.', packages_dag_enableConcurrentRead: 'Enable Concurrent Table Reading', packages_dag_enableConcurrentRead_tips: - 'Enabling this will allow the system to read and sync multiple tables simultaneously, ideal for scenarios with many small tables to improve performance. \nNote: In full-sync mode, newly added tables won’t sync once enabled. Adjust the target node concurrent thread count based on available resources to maintain stability.', + "Enabling this will allow the system to read and sync multiple tables simultaneously, ideal for scenarios with many small tables to improve performance. \nNote: In full-sync mode, newly added tables won't sync once enabled. Adjust the target node concurrent thread count based on available resources to maintain stability.", packages_dag_concurrentReadThreadNumber: 'Number of Tables to Read', packages_dag_missing_primary_key_or_index: 'Missing Primary Key or Unique Index', packages_dag_merge_table_missing_key_or_index: @@ -804,8 +804,8 @@ export default { packages_dag_add_own_target_datasource: 'Add My Own Target Data Source', packages_dag_add_new_connection: 'Create New Connection', packages_dag_add_own_datasource_desc: 'Configure a new data source from the list of connectors in TapData', - packages_dag_no_datasource: 'I Don’t Have a Data Source', - packages_dag_no_target_datasource: 'I Don’t Have a Target Data Source', + packages_dag_no_datasource: "I Don't Have a Data Source", + packages_dag_no_target_datasource: "I Don't Have a Target Data Source", packages_dag_no_datasource_desc: 'TapData provides a demo library with 2 sources and 2 targets.', packages_dag_have_connection: 'Select Existing Connection', packages_dag_have_connection_desc: 'Connections or data sources you have previously created.', @@ -832,5 +832,50 @@ export default { packages_dag_field_path: 'Field Path', packages_dag_email_receivers: 'Email Receivers', packages_dag_merge_table_js_node_error: 'Merge table node cannot have JS node after it', - packages_dag_merge_table_table_not_allow_target: 'Merge table does not support writing to {val}' + packages_dag_merge_table_table_not_allow_target: 'Merge table does not support writing to {val}', + packages_dag_incremental_validation: 'Incremental Validation', + packages_dag_validation_frequency: 'Validation Frequency', + packages_dag_every: 'Every', + packages_dag_seconds: 'Seconds', + packages_dag_records: 'Records', + packages_dag_enable_validation: 'Enable Validation', + packages_dag_inspect_type: 'Type', + packages_dag_inspect_start_time: 'Start Time', + packages_dag_inspect_end_time: 'End Time', + packages_dag_inspect_status: 'Status', + packages_dag_inspect_result: 'Result', + packages_dag_inspect_type_count: 'Incremental Validation', + packages_dag_inspect_type_hash: 'Auto Repair', + packages_dag_inspect_type_field: 'Field Validation', + packages_dag_inspect_type_jointField: 'Joint Field Validation', + packages_dag_inspect_type_full: 'Full Validation', + packages_dag_inspect_type_increment: 'Incremental Validation', + packages_dag_inspect_status_scheduling: 'Scheduling', + packages_dag_inspect_status_running: 'Running', + packages_dag_inspect_status_done: 'Completed', + packages_dag_inspect_status_error: 'Error', + packages_dag_inspect_result_passed: 'Passed', + packages_dag_inspect_result_failed: 'Failed', + packages_dag_inspect_result_error: 'Error', + packages_dag_inspect_detail_title: 'Verification Details', + packages_dag_inspect_last_verify_time: 'Last Verification Time', + packages_dag_inspect_source_table: 'Source Table', + packages_dag_inspect_target_table: 'Target Table', + packages_dag_inspect_count: 'Verification Count', + packages_dag_inspect_diff_count: 'Data Differences: {count}', + packages_dag_inspect_detail_tab: 'Verification Details', + packages_dag_inspect_summary_tab: 'Verification Summary', + packages_dag_inspect_source_field: 'Source Field', + packages_dag_inspect_target_field: 'Target Field', + packages_dag_inspect_value: 'Value', + packages_dag_inspect_no_data: 'No data available', + packages_dag_inspect_loading: 'Loading...', + packages_dag_inspect_fetch_error: 'Failed to fetch verification details', + packages_dag_inspect_summary_title: 'Data Differences Found', + packages_dag_inspect_summary_desc: 'There are {count} records with differences between source and target', + packages_dag_inspect_verification_summary: 'Verification Summary', + packages_dag_inspect_total_records: 'Total Records', + packages_dag_inspect_diff_records: 'Different Records', + packages_dag_inspect_source_records: 'Source Records', + packages_dag_inspect_target_records: 'Target Records' } diff --git a/packages/dag/src/locale/lang/zh-CN.js b/packages/dag/src/locale/lang/zh-CN.js index 5366613f02..e3cc165d28 100644 --- a/packages/dag/src/locale/lang/zh-CN.js +++ b/packages/dag/src/locale/lang/zh-CN.js @@ -393,9 +393,9 @@ export default { packages_dag_nodes_targetdatabase_jiedianmiaoshu: '节点描述', packages_dag_src_store_weizhaodaojiedian: '未找到节点', packages_dag_src_store_qingkongjiedianshu: '清空节点输入输出的监听', - packages_dag_node_none_input: '“ {val1} ”至少需要{val2}个源节点', - packages_dag_node_none_output: '“ {val1} ”至少需要{val2}个目标节点', - packages_dag_node_none_connection: '“ {val1} ”没有任何连线', + packages_dag_node_none_input: '" {val1} "至少需要{val2}个源节点', + packages_dag_node_none_output: '" {val1} "至少需要{val2}个目标节点', + packages_dag_node_none_connection: '" {val1} "没有任何连线', packages_dag_node_only_as_source: '该节点「{val1}」仅支持作为源', packages_dag_node_only_as_target: '该节点「{val1}」仅支持作为目标', packages_dag_components_alert_dangqianrenwuyi: '当前任务已报错停止,请关注!', @@ -776,5 +776,51 @@ export default { packages_dag_field_path: '字段路径', packages_dag_email_receivers: '邮件接收人', packages_dag_merge_table_js_node_error: '主从合并节点后不允许存在 JS 节点', - packages_dag_merge_table_table_not_allow_target: '主从合并后不支持将 {val} 作为写入目标' + packages_dag_merge_table_table_not_allow_target: '主从合并后不支持将 {val} 作为写入目标', + packages_dag_incremental_validation: '增量校验', + packages_dag_validation_frequency: '校验频率', + packages_dag_every: '每', + packages_dag_seconds: '秒', + packages_dag_records: '条记录', + packages_dag_enable_validation: '启用校验', + packages_dag_inspect_type: '类型', + packages_dag_inspect_start_time: '运行开始时间', + packages_dag_inspect_end_time: '运行结束时间', + packages_dag_inspect_status: '状态', + packages_dag_inspect_result: '结果', + packages_dag_inspect_type_count: '增量校验', + packages_dag_inspect_type_hash: '自动修复', + packages_dag_inspect_type_field: '字段校验', + packages_dag_inspect_type_jointField: '联合字段校验', + packages_dag_inspect_type_full: '全量校验', + packages_dag_inspect_type_increment: '增量校验', + packages_dag_inspect_status_scheduling: '调度中', + packages_dag_inspect_status_running: '运行中', + packages_dag_inspect_status_done: '已完成', + packages_dag_inspect_status_error: '错误', + packages_dag_inspect_result_passed: '一致', + packages_dag_inspect_result_failed: '错误', + packages_dag_inspect_result_error: '错误', + // Inspect detail dialog translations + packages_dag_inspect_detail_title: '检验详情', + packages_dag_inspect_last_verify_time: '最后验证时间', + packages_dag_inspect_source_table: '源表', + packages_dag_inspect_target_table: '目标表', + packages_dag_inspect_count: '校验次数', + packages_dag_inspect_diff_count: '表数据差异:{count}', + packages_dag_inspect_detail_tab: '校验详情', + packages_dag_inspect_summary_tab: '校验摘要', + packages_dag_inspect_source_field: '源表字段名', + packages_dag_inspect_target_field: '目标字段名', + packages_dag_inspect_value: '值', + packages_dag_inspect_no_data: '暂无数据', + packages_dag_inspect_loading: '加载中...', + packages_dag_inspect_fetch_error: '获取检验详情失败', + packages_dag_inspect_summary_title: '存在数据差异', + packages_dag_inspect_summary_desc: '源表和目标表数据存在差异,共 {count} 条记录不一致', + packages_dag_inspect_verification_summary: '验证摘要', + packages_dag_inspect_total_records: '总记录数', + packages_dag_inspect_diff_records: '差异记录数', + packages_dag_inspect_source_records: '源表记录数', + packages_dag_inspect_target_records: '目标表记录数' } diff --git a/packages/dag/src/locale/lang/zh-TW.js b/packages/dag/src/locale/lang/zh-TW.js index a1da5769d9..c0fda4048f 100644 --- a/packages/dag/src/locale/lang/zh-TW.js +++ b/packages/dag/src/locale/lang/zh-TW.js @@ -771,5 +771,29 @@ export default { packages_dag_field_path: '字段路徑', packages_dag_email_receivers: '郵件接收人', packages_dag_merge_table_js_node_error: '主從合併節點後不允許存在 JS 節點', - packages_dag_merge_table_table_not_allow_target: '主從合併後不支持將 {val} 作為寫入目標' + packages_dag_merge_table_table_not_allow_target: '主從合併後不支持將 {val} 作為寫入目標', + packages_dag_incremental_validation: '增量校验', + packages_dag_validation_frequency: '校验频率', + packages_dag_every: '每', + packages_dag_seconds: '秒', + packages_dag_records: '條記錄', + packages_dag_enable_validation: '啟用校驗', + packages_dag_inspect_type: '類型', + packages_dag_inspect_start_time: '運行開始時間', + packages_dag_inspect_end_time: '運行結束時間', + packages_dag_inspect_status: '狀態', + packages_dag_inspect_result: '結果', + packages_dag_inspect_type_count: '增量校驗', + packages_dag_inspect_type_hash: '自動修復', + packages_dag_inspect_type_field: '字段校驗', + packages_dag_inspect_type_jointField: '聯合字段校驗', + packages_dag_inspect_type_full: '全量校驗', + packages_dag_inspect_type_increment: '增量校驗', + packages_dag_inspect_status_scheduling: '調度中', + packages_dag_inspect_status_running: '運行中', + packages_dag_inspect_status_done: '已完成', + packages_dag_inspect_status_error: '錯誤', + packages_dag_inspect_result_passed: '一致', + packages_dag_inspect_result_failed: '錯誤', + packages_dag_inspect_result_error: '錯誤' } diff --git a/packages/i18n/src/locale/lang/en.js b/packages/i18n/src/locale/lang/en.js index 6e559dafdb..b0d971f0f9 100644 --- a/packages/i18n/src/locale/lang/en.js +++ b/packages/i18n/src/locale/lang/en.js @@ -380,5 +380,7 @@ export default { public_load_end: 'End', public_store_type: 'Store Type', public_from_db_type: 'From DB Type', - public_sample_size: 'Sample Size' + public_sample_size: 'Sample Size', + public_data_validation: 'Data Validation', + public_validation_record: 'Validation Record' } diff --git a/packages/i18n/src/locale/lang/zh-CN.js b/packages/i18n/src/locale/lang/zh-CN.js index c2c2b8d37e..c3f8b98f9b 100644 --- a/packages/i18n/src/locale/lang/zh-CN.js +++ b/packages/i18n/src/locale/lang/zh-CN.js @@ -376,5 +376,7 @@ export default { public_array: '数组', public_load_more: '加载更多', public_loading: '拼命加载中', - public_load_end: '到底了' + public_load_end: '到底了', + public_data_validation: '数据校验', + public_validation_record: '校验记录' } diff --git a/packages/i18n/src/locale/lang/zh-TW.js b/packages/i18n/src/locale/lang/zh-TW.js index 368af82c5d..37579207e3 100644 --- a/packages/i18n/src/locale/lang/zh-TW.js +++ b/packages/i18n/src/locale/lang/zh-TW.js @@ -375,5 +375,7 @@ export default { public_array: '数组', public_load_more: '加载更多', public_loading: '拼命加载中', - public_load_end: '到底了' + public_load_end: '到底了', + public_data_validation: '数据校验', + public_validation_record: '校验记录' } From ea468c7dee30f1ae37efbb519f079f68a996d0f8 Mon Sep 17 00:00:00 2001 From: Feynman Date: Tue, 25 Mar 2025 14:34:45 +0800 Subject: [PATCH 02/46] feat: enhance TaskInspect and DataValidationDialog components with improved configuration handling and UI updates --- packages/api/src/TaskInspect.ts | 27 ++++-- .../src/components/DataValidationDialog.vue | 12 +-- .../dag/src/components/monitor/TopHeader.vue | 20 ++++- .../monitor/components/TaskInspect.vue | 86 +++++++------------ 4 files changed, 76 insertions(+), 69 deletions(-) diff --git a/packages/api/src/TaskInspect.ts b/packages/api/src/TaskInspect.ts index 4c59df828a..bc5a0470e4 100644 --- a/packages/api/src/TaskInspect.ts +++ b/packages/api/src/TaskInspect.ts @@ -32,24 +32,35 @@ interface TaskInspectConfig { mode: 'CLOSE' | 'INTELLIGENT' | 'CUSTOM' } +interface TaskInspectHistory { + id: string + taskId: string + createdAt: string + status: string + type: string + [key: string]: any +} + export default class TaskInspect extends Http { constructor() { super('/api/task-inspect') } - getConfig(taskId: string, params: any): Promise { - return this.axios.get(this.url + `/${taskId}`, { params }).catch(err => { - console.error(err) - return Promise.resolve({ - mode: 'CUSTOM', + async getConfig(taskId: string, params: any): Promise { + const response = (await this.axios.get(this.url + `/${taskId}`, { params })) as unknown as TaskInspectConfig + + return ( + response || { + mode: 'CLOSE', custom: { cdc: { enable: true, - sample: { interval: 60, limit: 20 } + sample: { interval: 10, limit: 1 }, + type: 'SAMPLE' } } - }) - }) + } + ) } putConfig(taskId: string, params: TaskInspectConfig) { diff --git a/packages/dag/src/components/DataValidationDialog.vue b/packages/dag/src/components/DataValidationDialog.vue index 978329546b..79a725b0c8 100644 --- a/packages/dag/src/components/DataValidationDialog.vue +++ b/packages/dag/src/components/DataValidationDialog.vue @@ -120,11 +120,13 @@ export default { async handleSave() { const settings = { - enabled: this.validationEnabled, - type: this.validationType, - frequency: { - time: this.frequencyTime, - records: this.frequencyRecords + mode: this.validationEnabled ? 'CUSTOM' : 'CLOSE', + custom: { + cdc: { + enable: true, + sample: { interval: this.frequencyTime, limit: this.frequencyRecords }, // 采样间隔和数量 + type: 'SAMPLE' // 采样类型 + } } } diff --git a/packages/dag/src/components/monitor/TopHeader.vue b/packages/dag/src/components/monitor/TopHeader.vue index b784d6dd9c..8c39b7c973 100644 --- a/packages/dag/src/components/monitor/TopHeader.vue +++ b/packages/dag/src/components/monitor/TopHeader.vue @@ -96,6 +96,12 @@ > bug-outlined + + + +
@@ -167,6 +173,14 @@ @update:visible="openDebug = $event" @start="$emit('debug-start')" > + + @@ -182,6 +196,7 @@ import { TextEditable, VIcon, VDivider, OverflowTooltip } from '@tap/component' import { TaskStatus } from '@tap/business' import syncTaskAgent from '@tap/business/src/mixins/syncTaskAgent' import DataCaptureDebug from '../DataCaptureDebug.vue' +import DataValidationDialog from '../DataValidationDialog.vue' export default { name: 'TopHeader', @@ -210,7 +225,7 @@ export default { mixins: [syncTaskAgent], - components: { DataCaptureDebug, VIcon, TaskStatus, VDivider, OverflowTooltip, TextEditable }, + components: { DataCaptureDebug, VIcon, TaskStatus, VDivider, OverflowTooltip, TextEditable, DataValidationDialog }, data() { const isMacOs = /(ipad|iphone|ipod|mac)/i.test(navigator.platform) @@ -232,7 +247,8 @@ export default { cdc: i18n.t('public_task_type_cdc'), 'initial_sync+cdc': i18n.t('public_task_type_initial_sync_and_cdc') }, - openDebug: false + openDebug: false, + openValidation: false } }, diff --git a/packages/dag/src/components/monitor/components/TaskInspect.vue b/packages/dag/src/components/monitor/components/TaskInspect.vue index 3f13fd2bf0..3d39537b12 100644 --- a/packages/dag/src/components/monitor/components/TaskInspect.vue +++ b/packages/dag/src/components/monitor/components/TaskInspect.vue @@ -10,25 +10,14 @@ height="100%" hide-on-single-page > - diff --git a/packages/dag/src/components/monitor/TopHeader.vue b/packages/dag/src/components/monitor/TopHeader.vue index 8c39b7c973..9d97f445ee 100644 --- a/packages/dag/src/components/monitor/TopHeader.vue +++ b/packages/dag/src/components/monitor/TopHeader.vue @@ -177,9 +177,7 @@ diff --git a/packages/dag/src/components/monitor/components/InspectDetailDialog.vue b/packages/dag/src/components/monitor/components/InspectDetailDialog.vue index e091401817..76f20610d3 100644 --- a/packages/dag/src/components/monitor/components/InspectDetailDialog.vue +++ b/packages/dag/src/components/monitor/components/InspectDetailDialog.vue @@ -1,6 +1,7 @@ + + diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index e00c7174e6..1ac3d407d7 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -369,14 +369,14 @@ importers: specifier: ^1.86.2 version: 1.86.3 unplugin-auto-import: - specifier: ^0.17.6 - version: 0.17.8(@vueuse/core@10.11.1(vue@3.5.13(typescript@5.8.3)))(rollup@4.40.0) + specifier: ^19.2.0 + version: 19.2.0(@vueuse/core@10.11.1(vue@3.5.13(typescript@5.8.3))) unplugin-icons: specifier: ^0.19.0 version: 0.19.3(@vue/compiler-sfc@3.5.13) unplugin-vue-components: - specifier: ^0.27.0 - version: 0.27.5(@babel/parser@7.27.0)(rollup@4.40.0)(vue@3.5.13(typescript@5.8.3)) + specifier: ^28.5.0 + version: 28.5.0(@babel/parser@7.27.0)(vue@3.5.13(typescript@5.8.3)) vite: specifier: ^6.2.4 version: 6.3.1(@types/node@20.17.30)(sass@1.86.3)(terser@5.39.0)(yaml@2.7.1) @@ -4950,6 +4950,9 @@ packages: strip-literal@2.1.1: resolution: {integrity: sha512-631UJ6O00eNGfMiWG78ck80dfBab8X6IVFB51jZK5Icd7XAs60Z5y7QdSd/wGIklnWvRbUNloVzhOKKmutxQ6Q==} + strip-literal@3.0.0: + resolution: {integrity: sha512-TcccoMhJOM3OebGhSBEmp3UZ2SfDMZUEBdRA/9ynfLi8yYajyWX3JiXArcJt4Umh4vISpspkQIY8ZZoCqjbviA==} + supports-color@2.0.0: resolution: {integrity: sha512-KKNVtd6pCYgPIKU4cp2733HWYCpplQhddZLBUryaAHou723x+FRzQ5Df824Fj+IyyuiQTRoub4SnIFfIcrp70g==} engines: {node: '>=0.8.0'} @@ -5172,6 +5175,10 @@ packages: unimport@3.14.6: resolution: {integrity: sha512-CYvbDaTT04Rh8bmD8jz3WPmHYZRG/NnvYVzwD6V1YAlvvKROlAeNDUBhkBGzNav2RKaeuXvlWYaa1V4Lfi/O0g==} + unimport@4.2.0: + resolution: {integrity: sha512-mYVtA0nmzrysnYnyb3ALMbByJ+Maosee2+WyE0puXl+Xm2bUwPorPaaeZt0ETfuroPOtG8jj1g/qeFZ6buFnag==} + engines: {node: '>=18.12.0'} + union-value@1.0.1: resolution: {integrity: sha512-tJfXmxMeWYnczCVs7XAEvIV7ieppALdyepWMkHkwciRpZraG/xwT+s2JN8+pr1+8jCRf80FFzvr+MpQeeoF4Xg==} engines: {node: '>=0.10.0'} @@ -5212,8 +5219,8 @@ packages: '@vueuse/core': optional: true - unplugin-auto-import@0.17.8: - resolution: {integrity: sha512-CHryj6HzJ+n4ASjzwHruD8arhbdl+UXvhuAIlHDs15Y/IMecG3wrf7FVg4pVH/DIysbq/n0phIjNHAjl7TG7Iw==} + unplugin-auto-import@19.2.0: + resolution: {integrity: sha512-DGRHg86nUDKEYpny1p2kFZjeLg7kHQmknsPQ8krAshvpeypps7dFxNBsAqhBaxYINjetbgQilF8wbjuZxpdomg==} engines: {node: '>=14'} peerDependencies: '@nuxt/kit': ^3.2.2 @@ -5264,6 +5271,10 @@ packages: vue-template-es2015-compiler: optional: true + unplugin-utils@0.2.4: + resolution: {integrity: sha512-8U/MtpkPkkk3Atewj1+RcKIjb5WBimZ/WSLhhR3w6SsIj8XJuKTacSP8g+2JhfSGw0Cb125Y+2zA/IzJZDVbhA==} + engines: {node: '>=18.12.0'} + unplugin-vue-components@0.25.2: resolution: {integrity: sha512-OVmLFqILH6w+eM8fyt/d/eoJT9A6WO51NZLf1vC5c1FZ4rmq2bbGxTy8WP2Jm7xwFdukaIdv819+UI7RClPyCA==} engines: {node: '>=14'} @@ -5277,8 +5288,8 @@ packages: '@nuxt/kit': optional: true - unplugin-vue-components@0.27.5: - resolution: {integrity: sha512-m9j4goBeNwXyNN8oZHHxvIIYiG8FQ9UfmKWeNllpDvhU7btKNNELGPt+o3mckQKuPwrE7e0PvCsx+IWuDSD9Vg==} + unplugin-vue-components@28.5.0: + resolution: {integrity: sha512-o7fMKU/uI8NiP+E0W62zoduuguWqB0obTfHFtbr1AP2uo2lhUPnPttWUE92yesdiYfo9/0hxIrj38FMc1eaySg==} engines: {node: '>=14'} peerDependencies: '@babel/parser': ^7.15.8 @@ -5294,6 +5305,10 @@ packages: resolution: {integrity: sha512-4/u/j4FrCKdi17jaxuJA0jClGxB1AvU2hw/IuayPc4ay1XGaJs/rbb4v5WKwAjNifjmXK9PIFyuPiaK8azyR9w==} engines: {node: '>=14.0.0'} + unplugin@2.3.4: + resolution: {integrity: sha512-m4PjxTurwpWfpMomp8AptjD5yj8qEZN5uQjjGM3TAs9MWWD2tXSSNNj6jGR2FoVGod4293ytyV6SwBbertfyJg==} + engines: {node: '>=18.12.0'} + unrs-resolver@1.5.0: resolution: {integrity: sha512-6aia3Oy7SEe0MuUGQm2nsyob0L2+g57w178K5SE/3pvSGAIp28BB2O921fKx424Ahc/gQ6v0DXFbhcpyhGZdOA==} @@ -10410,6 +10425,10 @@ snapshots: dependencies: js-tokens: 9.0.1 + strip-literal@3.0.0: + dependencies: + js-tokens: 9.0.1 + supports-color@2.0.0: {} supports-color@3.2.3: @@ -10676,6 +10695,23 @@ snapshots: transitivePeerDependencies: - rollup + unimport@4.2.0: + dependencies: + acorn: 8.14.1 + escape-string-regexp: 5.0.0 + estree-walker: 3.0.3 + local-pkg: 1.1.1 + magic-string: 0.30.17 + mlly: 1.7.4 + pathe: 2.0.3 + picomatch: 4.0.2 + pkg-types: 2.1.0 + scule: 1.3.0 + strip-literal: 3.0.0 + tinyglobby: 0.2.12 + unplugin: 2.3.4 + unplugin-utils: 0.2.4 + union-value@1.0.1: dependencies: arr-union: 3.1.0 @@ -10723,20 +10759,16 @@ snapshots: transitivePeerDependencies: - rollup - unplugin-auto-import@0.17.8(@vueuse/core@10.11.1(vue@3.5.13(typescript@5.8.3)))(rollup@4.40.0): + unplugin-auto-import@19.2.0(@vueuse/core@10.11.1(vue@3.5.13(typescript@5.8.3))): dependencies: - '@antfu/utils': 0.7.10 - '@rollup/pluginutils': 5.1.4(rollup@4.40.0) - fast-glob: 3.3.3 - local-pkg: 0.5.1 + local-pkg: 1.1.1 magic-string: 0.30.17 - minimatch: 9.0.5 - unimport: 3.14.6(rollup@4.40.0) - unplugin: 1.16.1 + picomatch: 4.0.2 + unimport: 4.2.0 + unplugin: 2.3.4 + unplugin-utils: 0.2.4 optionalDependencies: '@vueuse/core': 10.11.1(vue@3.5.13(typescript@5.8.3)) - transitivePeerDependencies: - - rollup unplugin-icons@0.17.4(@vue/compiler-sfc@3.5.13): dependencies: @@ -10766,6 +10798,11 @@ snapshots: transitivePeerDependencies: - supports-color + unplugin-utils@0.2.4: + dependencies: + pathe: 2.0.3 + picomatch: 4.0.2 + unplugin-vue-components@0.25.2(@babel/parser@7.27.0)(rollup@4.40.0)(vue@3.5.13(typescript@5.8.3)): dependencies: '@antfu/utils': 0.7.10 @@ -10785,23 +10822,20 @@ snapshots: - rollup - supports-color - unplugin-vue-components@0.27.5(@babel/parser@7.27.0)(rollup@4.40.0)(vue@3.5.13(typescript@5.8.3)): + unplugin-vue-components@28.5.0(@babel/parser@7.27.0)(vue@3.5.13(typescript@5.8.3)): dependencies: - '@antfu/utils': 0.7.10 - '@rollup/pluginutils': 5.1.4(rollup@4.40.0) chokidar: 3.6.0 debug: 4.4.0 - fast-glob: 3.3.3 - local-pkg: 0.5.1 + local-pkg: 1.1.1 magic-string: 0.30.17 - minimatch: 9.0.5 mlly: 1.7.4 - unplugin: 1.16.1 + tinyglobby: 0.2.12 + unplugin: 2.3.4 + unplugin-utils: 0.2.4 vue: 3.5.13(typescript@5.8.3) optionalDependencies: '@babel/parser': 7.27.0 transitivePeerDependencies: - - rollup - supports-color unplugin@1.16.1: @@ -10809,6 +10843,12 @@ snapshots: acorn: 8.14.1 webpack-virtual-modules: 0.6.2 + unplugin@2.3.4: + dependencies: + acorn: 8.14.1 + picomatch: 4.0.2 + webpack-virtual-modules: 0.6.2 + unrs-resolver@1.5.0: optionalDependencies: '@unrs/resolver-binding-darwin-arm64': 1.5.0 From ad4233ed6cb2d38e2eec4e674a70c659c29a2ea8 Mon Sep 17 00:00:00 2001 From: Feynman Date: Mon, 19 May 2025 20:09:48 +0800 Subject: [PATCH 37/46] style: adjust button spacing in TablePage for improved layout - Added a custom CSS variable to control button spacing in the selection area, enhancing the visual alignment of elements. --- apps/daas/src/components.d.ts | 1 + packages/business/src/components/TablePage.vue | 1 + 2 files changed, 2 insertions(+) diff --git a/apps/daas/src/components.d.ts b/apps/daas/src/components.d.ts index d237710e02..da25ccc926 100644 --- a/apps/daas/src/components.d.ts +++ b/apps/daas/src/components.d.ts @@ -2,6 +2,7 @@ // @ts-nocheck // Generated by unplugin-vue-components // Read more: https://github.com/vuejs/core/pull/3399 +// biome-ignore lint: disable export {} /* prettier-ignore */ diff --git a/packages/business/src/components/TablePage.vue b/packages/business/src/components/TablePage.vue index d40866eace..b3d570aecf 100644 --- a/packages/business/src/components/TablePage.vue +++ b/packages/business/src/components/TablePage.vue @@ -346,6 +346,7 @@ export default {
Date: Tue, 20 May 2025 11:25:01 +0800 Subject: [PATCH 38/46] refactor: enhance user interface and functionality in various components - Updated Header.vue to improve layout and styling of the header element. - Refactored List.vue to optimize tag selection logic and enhance user interaction with bulk operations. - Improved TablePage.vue by adjusting button spacing and adding a new icon for dropdown actions. - Updated Classification.vue to introduce a search feature, enhancing usability. - Modified element.scss to refine button hover styles for better visual feedback. - Replaced the expand-list icon with a new SVG for improved clarity and consistency across components. --- apps/daas/src/auto-imports.d.ts | 1 + apps/daas/src/layouts/Header.vue | 11 +- apps/daas/src/views/user/List.vue | 155 +++++++++--------- packages/assets/icons/svg/expand-list.svg | 6 +- packages/assets/styles/element.scss | 6 + .../business/src/components/TablePage.vue | 28 ++-- .../business/src/views/connections/List.vue | 17 +- packages/business/src/views/task/List.vue | 14 +- packages/component/src/Classification.vue | 46 ++++-- packages/component/src/index.js | 2 + 10 files changed, 157 insertions(+), 129 deletions(-) diff --git a/apps/daas/src/auto-imports.d.ts b/apps/daas/src/auto-imports.d.ts index 459454d427..541046c404 100644 --- a/apps/daas/src/auto-imports.d.ts +++ b/apps/daas/src/auto-imports.d.ts @@ -3,6 +3,7 @@ // @ts-nocheck // noinspection JSUnusedGlobalSymbols // Generated by unplugin-auto-import +// biome-ignore lint: disable export {} declare global { const ElIcon: typeof import('element-plus/es')['ElIcon'] diff --git a/apps/daas/src/layouts/Header.vue b/apps/daas/src/layouts/Header.vue index 185f51c5d5..07b393939e 100644 --- a/apps/daas/src/layouts/Header.vue +++ b/apps/daas/src/layouts/Header.vue @@ -244,7 +244,11 @@ defineExpose({ diff --git a/packages/business/src/views/task/List.vue b/packages/business/src/views/task/List.vue index 99857e8639..1a48bfb91a 100644 --- a/packages/business/src/views/task/List.vue +++ b/packages/business/src/views/task/List.vue @@ -6,8 +6,7 @@ import { taskApi, workerApi, } from '@tap/api' -import { FilterBar, SelectList } from '@tap/component' -import InfiniteSelect from '@tap/form/src/components/infinite-select/InfiniteSelect.vue' +import { DownBoldOutlined, FilterBar, SelectList } from '@tap/component' import i18n from '@tap/i18n' import { generateId } from '@tap/shared' import dayjs from 'dayjs' @@ -32,7 +31,7 @@ export default { name: 'List', components: { - InfiniteSelect, + DownBoldOutlined, DatabaseIcon, FilterBar, SelectList, @@ -1008,10 +1007,7 @@ export default {