From 910a680c8b116ea6867bbdf0787b7c2f19d67f77 Mon Sep 17 00:00:00 2001 From: zchengo <1933757688@qq.com> Date: Fri, 2 Dec 2022 21:56:37 +0800 Subject: [PATCH] fix: customer region default value --- web/src/views/Customer.vue | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/web/src/views/Customer.vue b/web/src/views/Customer.vue index 55289d9..c748713 100644 --- a/web/src/views/Customer.vue +++ b/web/src/views/Customer.vue @@ -94,7 +94,7 @@ - @@ -243,8 +243,6 @@ export default { const modalFormRef = ref(); const keyWord = ref('') - const region = ref([]) - // 点击新建客户 const onCreate = () => { title.value = '新建客户' @@ -270,7 +268,7 @@ export default { customer.level = p.level customer.remarks = p.remarks customer.region = p.region - region.value = customer.region.split(',') + customer.region = p.region.split(',') customer.address = p.address customer.status = p.status } @@ -281,8 +279,8 @@ export default { const onSave = () => { console.log("zzz123") modalFormRef.value.validateFields().then(() => { + customer.region = customer.region.toString() if (operation.value == 1) { - customer.region.toString() createCustomer(customer).then((res) => { if (res.data.code == 0) { message.success('保存成功') @@ -361,7 +359,7 @@ export default { const options = regionData const selectedOptions = (value) => { - customer.region = value.toString() + customer.region = value } return { @@ -386,7 +384,6 @@ export default { getCustomerList, keyWord, options, - region, onPagination, pagination, selectedOptions,