From 943cc7eeca1fb8fb11e61e302a8bec0f9ad48130 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=99=88=E6=98=B1=E8=BE=BE?= Date: Tue, 4 Mar 2025 20:38:14 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=96=B0=E5=A2=9E=E9=80=89=E9=A1=B9?= =?UTF-8?q?=E6=93=8D=E4=BD=9C=E5=8A=9F=E8=83=BD=E5=B9=B6=E4=BC=98=E5=8C=96?= =?UTF-8?q?=E9=97=AE=E5=8D=B7=E8=AE=BE=E8=AE=A1=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 新增 OptionAction 组件用于选项操作 - 更新 BaseSelect 组件,集成 OptionAction 功能 - 优化 Paging 组件样式 - 调整 Design 页面布局和样式 --- components.d.ts | 3 + src/components/YLSelect.vue | 97 +++++++++++++++++++ src/stores/modules/common.ts | 44 +++++++++ src/views/Design/Index.vue | 10 +- .../ActionCompoents/QuestionAction.vue | 66 ++++++++++++- 5 files changed, 216 insertions(+), 4 deletions(-) create mode 100644 src/components/YLSelect.vue diff --git a/components.d.ts b/components.d.ts index 2f649c1..917ada8 100644 --- a/components.d.ts +++ b/components.d.ts @@ -14,12 +14,15 @@ declare module 'vue' { VanCellGroup: typeof import('vant/es')['CellGroup'] VanCheckbox: typeof import('vant/es')['Checkbox'] VanCheckboxGroup: typeof import('vant/es')['CheckboxGroup'] + VanDialog: typeof import('vant/es')['Dialog'] VanDivider: typeof import('vant/es')['Divider'] VanField: typeof import('vant/es')['Field'] VanIcon: typeof import('vant/es')['Icon'] + VanPopup: typeof import('vant/es')['Popup'] VanSearch: typeof import('vant/es')['Search'] VanSwitch: typeof import('vant/es')['Switch'] VanTabbar: typeof import('vant/es')['Tabbar'] VanTabbarItem: typeof import('vant/es')['TabbarItem'] + YLSelect: typeof import('./src/components/YLSelect.vue')['default'] } } diff --git a/src/components/YLSelect.vue b/src/components/YLSelect.vue new file mode 100644 index 0000000..55d8424 --- /dev/null +++ b/src/components/YLSelect.vue @@ -0,0 +1,97 @@ + + + + + diff --git a/src/stores/modules/common.ts b/src/stores/modules/common.ts index 5857e63..0d7ecfb 100644 --- a/src/stores/modules/common.ts +++ b/src/stores/modules/common.ts @@ -181,6 +181,50 @@ export const useCommonStore = defineStore('common', { cell_indexs: [] }, hide_option_index: [] + }, + { + id: 472152, + question_index: 24, + sample_number: 0, + skip_question_index: 0, + skip_type: 1, + question_id: '17852294', + logic: [ + { + value: '', + location: 0, + date: '', + time: '', + type: 0, + row_type: 0, + cell_type: 0, + logic: 'if', + operator: '=', + is_answer: 1, + is_select: 0, + row_index: 0, + cell_index: 0, + question_type: 1, + question_index: 0, + relation_question_index: 0, + relation_question_row_index: 0, + relation_question_cell_index: 0, + is_option_group: 0, + option_index: 0, + skip_type: null, + question_id: null + } + ], + autofill: { + value: '', + date: '', + time: '', + question_type: 1, + option_indexs: [], + row_indexs: [], + cell_indexs: [] + }, + hide_option_index: [] } ], questions: [ diff --git a/src/views/Design/Index.vue b/src/views/Design/Index.vue index 0bcefc6..4564ec4 100644 --- a/src/views/Design/Index.vue +++ b/src/views/Design/Index.vue @@ -1,5 +1,5 @@ - + - + @@ -50,6 +50,30 @@ + + + +