diff --git a/src/views/mch/mch-manage/form.vue b/src/views/mch/mch-manage/form.vue index 13b50cb..769ead5 100644 --- a/src/views/mch/mch-manage/form.vue +++ b/src/views/mch/mch-manage/form.vue @@ -158,7 +158,7 @@ const form = reactive({ businessTime: "", addressDes: "", sort: 0, - supType: "10", + supType: "", cooperationStatus: "1", parentId: "", discountsPrice: "", @@ -222,7 +222,7 @@ watch( () => form.types, (newVal) => { if (newVal != "2") { - form.supType = "10" + form.supType = "" form.cooperationStatus = "1" form.parentId = "" form.discountsPrice = "" @@ -241,6 +241,11 @@ const onSubmit = async () => { cooperationStatus: form.types == "2" && form.supType == "10" ? null : form.cooperationStatus, parentId: form.types == "2" && form.supType == "10" ? -1 : form.parentId, } + + if (_pa.parentId == "") { + _pa.parentId = -1 + } + try { loading.value = true form.id ? await putObj(_pa) : await addObj(_pa) diff --git a/src/views/supermarketerp/supermarketBrand/form.vue b/src/views/supermarketerp/supermarketBrand/form.vue index 21a6ab4..2f078d8 100644 --- a/src/views/supermarketerp/supermarketBrand/form.vue +++ b/src/views/supermarketerp/supermarketBrand/form.vue @@ -4,7 +4,7 @@ - + @@ -35,9 +35,7 @@ - {{ item.label }} - + {{ item.label }} @@ -55,7 +53,7 @@