From 572a7aba84d56ab24f3d7b79f20c83e0c018654f Mon Sep 17 00:00:00 2001 From: lzq <2495532633@qq.com> Date: Tue, 3 Mar 2026 11:05:47 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B4=B9=E7=94=A8=E7=AE=A1=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/cst/station/station-api.ts | 5 +++- .../fin/expense-item/ExpenseItemForm.vue | 28 +++++++++++++++++-- src/pages/fin/expense-item/expense-item.d.ts | 4 +++ 3 files changed, 34 insertions(+), 3 deletions(-) diff --git a/src/pages/cst/station/station-api.ts b/src/pages/cst/station/station-api.ts index 371df21..80c832b 100644 --- a/src/pages/cst/station/station-api.ts +++ b/src/pages/cst/station/station-api.ts @@ -1,6 +1,6 @@ import { get, - post + post, } from '@/common/utils/http-util.ts' export default { @@ -19,4 +19,7 @@ export default { del(ids: string[]) { return post('/station/del', ids) }, + listAll() { + return get('/station/list_all') + }, } diff --git a/src/pages/fin/expense-item/ExpenseItemForm.vue b/src/pages/fin/expense-item/ExpenseItemForm.vue index a5c9bbb..df75764 100644 --- a/src/pages/fin/expense-item/ExpenseItemForm.vue +++ b/src/pages/fin/expense-item/ExpenseItemForm.vue @@ -20,6 +20,17 @@ + + + + + + + {{ it.txt }} @@ -86,6 +97,8 @@ import { } from '@/pages/gds/goods/constants.ts' import { expenseItemCategory } from '@/pages/fin/expense-item/constants.ts' import GoodsDropTable from '@/pages/gds/goods/GoodsDropTable.vue' +import { useAppUserStore } from '@/common/app/app-user-store.ts' +import StationApi from '@/pages/cst/station/station-api.ts' const props = withDefaults(defineProps<{ research?: () => void @@ -93,6 +106,7 @@ const props = withDefaults(defineProps<{ research: () => { }, }) +const appUserStore = useAppUserStore() const formPanelIns = useTemplateRef('formPanel') const status = ref<'add' | 'modify'>('add') const formPanelProps = buildFormPanelProps({ @@ -115,11 +129,11 @@ const formPanelProps = buildFormPanelProps { formPanelProps.title = status.value === 'add' ? '新建收费项目' : '修改收费项目信息' }) +const stations = ref([]) defineExpose({ open(data?: ExpenseItemTypes.SearchExpenseItemResult) { + if (appUserStore.isXiaoNa) { + StationApi.listAll() + .then(res => { + stations.value = res.data + }) + } else { + stations.value = [] + } + formPanelIns.value?.open(data?.id) }, }) diff --git a/src/pages/fin/expense-item/expense-item.d.ts b/src/pages/fin/expense-item/expense-item.d.ts index 7c803fd..3ca2cff 100644 --- a/src/pages/fin/expense-item/expense-item.d.ts +++ b/src/pages/fin/expense-item/expense-item.d.ts @@ -5,6 +5,7 @@ declare global { interface SearchExpenseItemParam extends G.PageParam { // Id id?: string + stationId?: string // 归属用户 Id userId?: string // 归属客户 Id @@ -52,6 +53,7 @@ declare global { id?: string // 归属用户 Id userId?: string + stationId?: string // 归属客户 Id customerId?: string // 归属组织 Id @@ -97,6 +99,7 @@ declare global { id?: string // 归属用户 Id userId?: string + stationId?: string // 归属客户 Id customerId?: string // 归属组织 Id @@ -140,6 +143,7 @@ declare global { interface ModifyExpenseItemParam { // Id id?: string + stationId?: string // 归属用户 Id userId?: string // 归属客户 Id