fix(销售页面): 将发布成功提示改为模态框并添加审核等待信息
修改发布成功后的用户提示方式,从简单的toast提示改为模态框,并添加需要等待审核的说明。用户确认后直接跳转首页,提升用户体验和操作明确性。
Showing
1 changed file
with
11 additions
and
7 deletions
| ... | @@ -877,14 +877,18 @@ const createCar = async (data) => { | ... | @@ -877,14 +877,18 @@ const createCar = async (data) => { |
| 877 | const { code } = await addVehicleAPI({ ...data, op: 'review' }) | 877 | const { code } = await addVehicleAPI({ ...data, op: 'review' }) |
| 878 | if (code) { | 878 | if (code) { |
| 879 | Taro.hideLoading() | 879 | Taro.hideLoading() |
| 880 | - Taro.showToast({ | 880 | + // 发布成功,提示用户等待审核 |
| 881 | - title: '发布成功', | 881 | + Taro.showModal({ |
| 882 | - icon: 'success', | 882 | + title: '提示', |
| 883 | - duration: 2000 | 883 | + content: '发布成功,请等待审核', |
| 884 | + showCancel: false, | ||
| 885 | + confirmText: '知道了', | ||
| 886 | + success: (res) => { | ||
| 887 | + if (res.confirm) { | ||
| 888 | + Taro.reLaunch({ url: '/pages/index/index' }) | ||
| 889 | + } | ||
| 890 | + } | ||
| 884 | }) | 891 | }) |
| 885 | - setTimeout(() => { | ||
| 886 | - Taro.reLaunch({ url: '/pages/index/index' }) | ||
| 887 | - }, 1000); | ||
| 888 | } | 892 | } |
| 889 | } | 893 | } |
| 890 | 894 | ... | ... |
-
Please register or login to post a comment