diff --git a/Web/src/components/Bill/BillForm.vue b/Web/src/components/Bill/BillForm.vue index c45e83a..4c8c4da 100644 --- a/Web/src/components/Bill/BillForm.vue +++ b/Web/src/components/Bill/BillForm.vue @@ -116,7 +116,7 @@ - - diff --git a/Web/src/components/ReasonGroupList.vue b/Web/src/components/ReasonGroupList.vue index 4d8860e..854e0c8 100644 --- a/Web/src/components/ReasonGroupList.vue +++ b/Web/src/components/ReasonGroupList.vue @@ -56,7 +56,7 @@ v-model="showTransactionList" :title="selectedGroup?.reason || '交易记录'" :subtitle="groupTransactionsTotal ? `共 ${groupTransactionsTotal} 笔交易` : ''" - height="80%" + height="85%" > - @@ -112,17 +112,16 @@ input-align="left" /> - - + + + + + 支出 + 收入 + 不计 + + + @@ -166,16 +165,6 @@ - - - - - { batchForm.value.classify = classify } -// 确认选择交易类型 -const handleConfirmType = ({ selectedOptions }) => { - batchForm.value.type = selectedOptions[0].value - batchForm.value.typeName = selectedOptions[0].text - showTypePicker.value = false -} - // 新增分类 const addNewClassify = async () => { if (!newClassify.value.trim()) { @@ -571,7 +545,7 @@ onBeforeUnmount(() => { }) // 当有交易新增/修改/批量更新时的刷新监听 -const onGlobalTransactionsChanged = (e) => { +const onGlobalTransactionsChanged = () => { if (showTransactionList.value && selectedGroup.value) { groupTransactions.value = [] transactionPageIndex.value = 1 diff --git a/Web/src/components/TransactionDetail.vue b/Web/src/components/TransactionDetail.vue index d529213..0edbd15 100644 --- a/Web/src/components/TransactionDetail.vue +++ b/Web/src/components/TransactionDetail.vue @@ -45,16 +45,17 @@ type="number" :rules="[{ required: true, message: '请输入交易后余额' }]" /> - + + + + + 支出 + 收入 + 不计 + + + + 请选择交易分类 @@ -103,16 +104,6 @@ - - - - - props.transaction, (newVal) => { editForm.amount = String(newVal.amount) editForm.balance = String(newVal.balance) editForm.type = newVal.type - editForm.typeText = getTypeName(newVal.type) editForm.classify = newVal.classify || '' // 根据交易类型加载分类 @@ -277,13 +258,6 @@ const selectClassify = (classify) => { editForm.classify = classify } -// 交易类型选择确认 -const onTypeConfirm = ({ selectedValues, selectedOptions }) => { - editForm.type = selectedValues[0] - editForm.typeText = selectedOptions[0].text - showTypePicker.value = false -} - // 新增分类 const addNewClassify = async () => { if (!newClassify.value.trim()) { diff --git a/Web/src/components/TransactionDetailDialog.vue b/Web/src/components/TransactionDetailDialog.vue deleted file mode 100644 index 404100f..0000000 --- a/Web/src/components/TransactionDetailDialog.vue +++ /dev/null @@ -1,410 +0,0 @@ - - - - - 账单详情 - - - - - - - - - - - - - - - - - - - - - - - - - - - 请选择分类 - {{ formData.classify }} - - - - - - - + 新增 - - - {{ item.name }} - - - 清空 - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Web/src/views/PeriodicRecord.vue b/Web/src/views/PeriodicRecord.vue index 4edba57..1d0aa1e 100644 --- a/Web/src/views/PeriodicRecord.vue +++ b/Web/src/views/PeriodicRecord.vue @@ -91,7 +91,7 @@ height="85%" > - + - + - + + > + + + 支出 + 收入 + 不计 + + + 请选择交易分类 @@ -219,25 +222,16 @@ 清空 - + - + {{ isEdit ? '更新' : '确认添加' }} - - + + - - - - - { form.reason = item.reason form.amount = item.amount.toString() form.type = item.type - form.typeText = typeColumns.find(t => t.value === item.type)?.text || '' form.classify = item.classify form.periodicType = item.periodicType form.periodicTypeText = periodicTypeColumns.find(t => t.value === item.periodicType)?.text || '' @@ -593,7 +577,6 @@ const resetForm = () => { form.reason = '' form.amount = '' form.type = 0 - form.typeText = '' form.classify = '' form.periodicType = 0 form.periodicTypeText = '' @@ -606,17 +589,6 @@ const resetForm = () => { form.yearDay = '' } -// 选择器确认事件 -const onTypeConfirm = ({ selectedValues, selectedOptions }) => { - form.type = selectedValues[0] - form.typeText = selectedOptions[0].text - showTypePicker.value = false - // 清空已选的分类 - form.classify = '' - // 重新加载对应类型的分类列表 - loadClassifyList(form.type) -} - const onPeriodicTypeConfirm = ({ selectedValues, selectedOptions }) => { form.periodicType = selectedValues[0] form.periodicTypeText = selectedOptions[0].text