From 2ea28a13e7b14dd8a8eb883cdde9ca218185b2a0 Mon Sep 17 00:00:00 2001 From: zhangds Date: Tue, 1 Nov 2022 10:57:26 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BC=98=E5=8C=96=E4=BC=98=E6=83=A0?= =?UTF-8?q?=E5=88=B8=E9=98=B2=E6=8A=96=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/UseCouponAddEdit/index.jsx | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/src/components/UseCouponAddEdit/index.jsx b/src/components/UseCouponAddEdit/index.jsx index 23ab3dee..5a66afd6 100644 --- a/src/components/UseCouponAddEdit/index.jsx +++ b/src/components/UseCouponAddEdit/index.jsx @@ -662,16 +662,16 @@ const UseCouponAddEdit = forwardRef((props, ref) => { console.log("编辑 大提交 =>", param); editCoupon(editData.id, param).then((res) => { - setState({ - isLoadingBtn: false, - }); handelResponse( res, (req, msg) => { Notify.success(res.message); setTimeout(() => { + setState({ + isLoadingBtn: false, + }); window.history.back(); - }, 2000); + }, 500); }, (err) => { Notify.error(err); @@ -721,16 +721,17 @@ const UseCouponAddEdit = forwardRef((props, ref) => { }); } addCoupon(param).then((res) => { - setState({ - isLoadingBtn: false, - }); handelResponse( res, (req, msg) => { Notify.success(res.message); + setTimeout(() => { + setState({ + isLoadingBtn: false, + }); window.history.back(); - }, 2000); + }, 500); }, (err) => { Notify.error(err);