From 6e0212394c012122d8ea7bfa8a2d65738a7a379c Mon Sep 17 00:00:00 2001 From: Haiyi <1021441632@qq.com> Date: Thu, 17 Nov 2022 16:50:43 +0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9E=20fix(ID1000746):=E7=94=B3?= =?UTF-8?q?=E8=AF=B7=E9=80=80=E8=B4=A7=EF=BC=8C=E5=8F=AA=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E9=80=80=E8=B4=A7=E7=90=86=E7=94=B1=E6=97=B6=E7=82=B9=E5=87=BB?= =?UTF-8?q?=E7=A1=AE=E8=AE=A4=EF=BC=8C=E9=A1=B5=E9=9D=A2=E5=8D=A1=E4=BD=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- project.private.config.json | 14 ++++++++++++++ src/pages/applyGoods/index.tsx | 18 ++++++++++++------ 2 files changed, 26 insertions(+), 6 deletions(-) diff --git a/project.private.config.json b/project.private.config.json index 1da5fee..8bee24a 100644 --- a/project.private.config.json +++ b/project.private.config.json @@ -211,6 +211,20 @@ "query": "", "launchMode": "default", "scene": null + }, + { + "name": "", + "pathName": "pages/orderDetails/index", + "query": "id=31743", + "launchMode": "default", + "scene": null + }, + { + "name": "", + "pathName": "pages/applyGoods/index", + "query": "orderId=31743", + "launchMode": "default", + "scene": null } ] } diff --git a/src/pages/applyGoods/index.tsx b/src/pages/applyGoods/index.tsx index b2562e8..d83ddc6 100644 --- a/src/pages/applyGoods/index.tsx +++ b/src/pages/applyGoods/index.tsx @@ -204,7 +204,6 @@ export default () => { //判断是否允许提交 const isDisabled = useMemo(() => { - console.log(Query, 8888) if (Query.GoodStatus !== '' && Query.return_explain !== '' && totalNums > 0 && @@ -248,7 +247,7 @@ export default () => { }) setQuery((val) => ({ ...val, return_reason: item.id, return_explain: '' })) queryRef.current.return_reason = item.id - // queryRef.current.reasonName = item.name + queryRef.current.reasonName = item.name setReasonList([...ReasonList]) getReasonTwo() } @@ -305,16 +304,23 @@ export default () => { //确认选择退货原因 const handSlect = () => { + if (queryRef.current?.reasonName == '请选择') { + Taro.showToast({ + title: '请选择完整', + icon: 'error' + }) + return false + } const resOne = ReasonList.filter(item => { return item.default }) - queryRef.current.return_reason = resOne[0].id - queryRef.current.reasonName = resOne[0].name + queryRef.current.return_reason = resOne[0]?.id + queryRef.current.reasonName = resOne[0]?.name const resTwo = ReasonListTwo.filter(item => { return item.default }) - queryRef.current.return_explain = resTwo[0].id - queryRef.current.reasonNameTwo = resTwo[0].name + queryRef.current.return_explain = resTwo[0]?.id + queryRef.current.reasonNameTwo = resTwo[0]?.name setQuery((val) => ({ ...val, reasonName: queryRef.current.reasonName,