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,