diff --git a/src/views/wallet/mch-manage/form.vue b/src/views/wallet/mch-manage/form.vue index dcdb532..79e6e26 100644 --- a/src/views/wallet/mch-manage/form.vue +++ b/src/views/wallet/mch-manage/form.vue @@ -59,7 +59,7 @@ range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" - value-format="HH-mm" + value-format="HH:mm" format="HH:mm" /> @@ -71,7 +71,7 @@ range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" - value-format="HH-mm" + value-format="HH:mm" format="HH:mm" /> @@ -83,7 +83,7 @@ range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" - value-format="HH-mm" + value-format="HH:mm" format="HH:mm" /> @@ -176,7 +176,7 @@ const onSubmit = async () => { const _pa = { ...form, types: form.merchantType, - jobTime: jobTime.morning.join(",") + ";" + jobTime.noon.join(",") + ";" + jobTime.evening.join(","), + jobTime: (jobTime.morning?.join("-") || "") + "," + (jobTime.noon?.join("-") || "") + "," + (jobTime.evening?.join("-") || ""), } try { loading.value = true @@ -197,14 +197,13 @@ const getmerchantInfoData = async (id: string) => { try { const res = await getObj(id) if (res.code === 0) { - const data = res.data - const resJobTime = data.jobTime?.split(";") - Object.assign(form, data, { - merchantType: data.types, + const resJobTime = res.data.jobTime ? res.data.jobTime.split(",") : [] + Object.assign(form, res.data, { + merchantType: res.data.types, }) - jobTime.morning = resJobTime ? resJobTime[0]?.split(",") : [] - jobTime.noon = resJobTime ? resJobTime[1]?.split(",") : [] - jobTime.evening = resJobTime ? resJobTime[2]?.split(",") : [] + jobTime.morning = resJobTime[0]?.split("-") + jobTime.noon = resJobTime[1]?.split("-") + jobTime.evening = resJobTime[2]?.split("-") } } catch (error: any) { useMessage().error(error.msg) diff --git a/src/views/wallet/mch-manage/index.vue b/src/views/wallet/mch-manage/index.vue index 1377a5b..0602bf2 100644 --- a/src/views/wallet/mch-manage/index.vue +++ b/src/views/wallet/mch-manage/index.vue @@ -36,8 +36,8 @@ @sort-change="sortChangeHandle" > - - + + - + - + - +