feat: 为弹窗添加统一底部操作按钮
为myCar、myFavorites和myOrders页面的弹窗添加底部操作按钮,包括取消和确认按钮 统一按钮样式和行为,提升用户体验
Showing
3 changed files
with
74 additions
and
7 deletions
| 1 | <!-- | 1 | <!-- |
| 2 | * @Date: 2022-09-19 14:11:06 | 2 | * @Date: 2022-09-19 14:11:06 |
| 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com | 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com |
| 4 | - * @LastEditTime: 2025-07-18 15:48:40 | 4 | + * @LastEditTime: 2025-07-29 16:57:13 |
| 5 | * @FilePath: /jgdl/src/pages/myCar/index.vue | 5 | * @FilePath: /jgdl/src/pages/myCar/index.vue |
| 6 | * @Description: 文件描述 | 6 | * @Description: 文件描述 |
| 7 | --> | 7 | --> |
| ... | @@ -143,6 +143,16 @@ | ... | @@ -143,6 +143,16 @@ |
| 143 | <text style="font-size: 1rem;">{{ offlineDialogContent }}</text> | 143 | <text style="font-size: 1rem;">{{ offlineDialogContent }}</text> |
| 144 | </view> | 144 | </view> |
| 145 | </template> | 145 | </template> |
| 146 | + <template #footer> | ||
| 147 | + <view class="flex gap-4 p-4"> | ||
| 148 | + <nut-button plain class="flex-1" size="small" @click="cancelOffline"> | ||
| 149 | + 取消 | ||
| 150 | + </nut-button> | ||
| 151 | + <nut-button type="warning" class="flex-1" size="small" color="orange" @click="confirmOffline"> | ||
| 152 | + 确认 | ||
| 153 | + </nut-button> | ||
| 154 | + </view> | ||
| 155 | + </template> | ||
| 146 | </nut-dialog> | 156 | </nut-dialog> |
| 147 | </view> | 157 | </view> |
| 148 | </template> | 158 | </template> | ... | ... |
| 1 | <!-- | 1 | <!-- |
| 2 | * @Date: 2022-09-19 14:11:06 | 2 | * @Date: 2022-09-19 14:11:06 |
| 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com | 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com |
| 4 | - * @LastEditTime: 2025-07-24 11:09:05 | 4 | + * @LastEditTime: 2025-07-29 16:52:58 |
| 5 | * @FilePath: /jgdl/src/pages/myFavorites/index.vue | 5 | * @FilePath: /jgdl/src/pages/myFavorites/index.vue |
| 6 | * @Description: 我的关注页面 | 6 | * @Description: 我的关注页面 |
| 7 | --> | 7 | --> |
| ... | @@ -96,6 +96,16 @@ | ... | @@ -96,6 +96,16 @@ |
| 96 | <text style="font-size: 1rem;">确定要取消关注此车辆吗?</text> | 96 | <text style="font-size: 1rem;">确定要取消关注此车辆吗?</text> |
| 97 | </view> | 97 | </view> |
| 98 | </template> | 98 | </template> |
| 99 | + <template #footer> | ||
| 100 | + <view class="flex gap-4 p-4"> | ||
| 101 | + <nut-button plain class="flex-1" size="small" @click="showConfirmModal = false"> | ||
| 102 | + 取消 | ||
| 103 | + </nut-button> | ||
| 104 | + <nut-button type="warning" class="flex-1" size="small" color="orange" @click="confirmUnfollow"> | ||
| 105 | + 确认 | ||
| 106 | + </nut-button> | ||
| 107 | + </view> | ||
| 108 | + </template> | ||
| 99 | </nut-dialog> | 109 | </nut-dialog> |
| 100 | 110 | ||
| 101 | <!-- 成功提示 --> | 111 | <!-- 成功提示 --> | ... | ... |
| 1 | <!-- | 1 | <!-- |
| 2 | * @Date: 2022-09-19 14:11:06 | 2 | * @Date: 2022-09-19 14:11:06 |
| 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com | 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com |
| 4 | - * @LastEditTime: 2025-07-29 16:38:27 | 4 | + * @LastEditTime: 2025-07-29 17:02:07 |
| 5 | * @FilePath: /jgdl/src/pages/myOrders/index.vue | 5 | * @FilePath: /jgdl/src/pages/myOrders/index.vue |
| 6 | * @Description: 订单管理页面 | 6 | * @Description: 订单管理页面 |
| 7 | --> | 7 | --> |
| ... | @@ -111,7 +111,7 @@ | ... | @@ -111,7 +111,7 @@ |
| 111 | <!-- 买车模式:待收货状态 --> | 111 | <!-- 买车模式:待收货状态 --> |
| 112 | <template v-if="viewMode === 'buy' && order.status === 9"> | 112 | <template v-if="viewMode === 'buy' && order.status === 9"> |
| 113 | <nut-button type="default" size="small" @click="viewOrderDetail(order.id)"> | 113 | <nut-button type="default" size="small" @click="viewOrderDetail(order.id)"> |
| 114 | - 查看详情 | 114 | + 订单详情 |
| 115 | </nut-button> | 115 | </nut-button> |
| 116 | <nut-button type="primary" size="small" @click="handleConfirmReceive(order)" color="orange" class="ml-2" | 116 | <nut-button type="primary" size="small" @click="handleConfirmReceive(order)" color="orange" class="ml-2" |
| 117 | :loading="receivingOrderId === order.id" :disabled="receivingOrderId === order.id"> | 117 | :loading="receivingOrderId === order.id" :disabled="receivingOrderId === order.id"> |
| ... | @@ -122,7 +122,7 @@ | ... | @@ -122,7 +122,7 @@ |
| 122 | <!-- 卖车模式:待发货状态 --> | 122 | <!-- 卖车模式:待发货状态 --> |
| 123 | <template v-if="viewMode === 'sell' && order.status === 5"> | 123 | <template v-if="viewMode === 'sell' && order.status === 5"> |
| 124 | <nut-button type="default" size="small" @click="viewOrderDetail(order.id)"> | 124 | <nut-button type="default" size="small" @click="viewOrderDetail(order.id)"> |
| 125 | - 查看详情 | 125 | + 订单详情 |
| 126 | </nut-button> | 126 | </nut-button> |
| 127 | <nut-button type="primary" size="small" @click="handleConfirmShip(order)" color="orange" class="ml-2" | 127 | <nut-button type="primary" size="small" @click="handleConfirmShip(order)" color="orange" class="ml-2" |
| 128 | :loading="shippingOrderId === order.id" :disabled="shippingOrderId === order.id"> | 128 | :loading="shippingOrderId === order.id" :disabled="shippingOrderId === order.id"> |
| ... | @@ -133,14 +133,21 @@ | ... | @@ -133,14 +133,21 @@ |
| 133 | <!-- 买车模式:待发货状态 --> | 133 | <!-- 买车模式:待发货状态 --> |
| 134 | <template v-if="viewMode === 'buy' && order.status === 5"> | 134 | <template v-if="viewMode === 'buy' && order.status === 5"> |
| 135 | <nut-button type="default" size="small" @click="viewOrderDetail(order.id)"> | 135 | <nut-button type="default" size="small" @click="viewOrderDetail(order.id)"> |
| 136 | - 查看详情 | 136 | + 订单详情 |
| 137 | + </nut-button> | ||
| 138 | + </template> | ||
| 139 | + | ||
| 140 | + <!-- 卖车模式:已发货状态 --> | ||
| 141 | + <template v-if="viewMode === 'sell' && order.status === 9"> | ||
| 142 | + <nut-button type="default" size="small" @click="viewOrderDetail(order.id)"> | ||
| 143 | + 订单详情 | ||
| 137 | </nut-button> | 144 | </nut-button> |
| 138 | </template> | 145 | </template> |
| 139 | 146 | ||
| 140 | <!-- 已完成状态 --> | 147 | <!-- 已完成状态 --> |
| 141 | <template v-if="order.status === 11"> | 148 | <template v-if="order.status === 11"> |
| 142 | <nut-button type="default" size="small" @click="viewOrderDetail(order.id)"> | 149 | <nut-button type="default" size="small" @click="viewOrderDetail(order.id)"> |
| 143 | - 查看详情 | 150 | + 订单详情 |
| 144 | </nut-button> | 151 | </nut-button> |
| 145 | <!-- 只有买车订单才显示评价按钮,卖车订单不显示 --> | 152 | <!-- 只有买车订单才显示评价按钮,卖车订单不显示 --> |
| 146 | <nut-button v-if="viewMode === 'buy'" type="primary" size="small" @click="rateOrder(order.id)" class="ml-2" color="orange" plain> | 153 | <nut-button v-if="viewMode === 'buy'" type="primary" size="small" @click="rateOrder(order.id)" class="ml-2" color="orange" plain> |
| ... | @@ -339,6 +346,16 @@ | ... | @@ -339,6 +346,16 @@ |
| 339 | <text style="font-size: 1rem;">是否确认删除订单?</text> | 346 | <text style="font-size: 1rem;">是否确认删除订单?</text> |
| 340 | </view> | 347 | </view> |
| 341 | </template> | 348 | </template> |
| 349 | + <template #footer> | ||
| 350 | + <view class="flex gap-4 p-4"> | ||
| 351 | + <nut-button plain class="flex-1" size="small" @click="showConfirmModal = false"> | ||
| 352 | + 取消 | ||
| 353 | + </nut-button> | ||
| 354 | + <nut-button type="warning" class="flex-1" size="small" color="orange" @click="performDeleteOrder(pendingDeleteOrderId)"> | ||
| 355 | + 确认 | ||
| 356 | + </nut-button> | ||
| 357 | + </view> | ||
| 358 | + </template> | ||
| 342 | </nut-dialog> | 359 | </nut-dialog> |
| 343 | 360 | ||
| 344 | <!-- Cancel Order Confirmation Modal --> | 361 | <!-- Cancel Order Confirmation Modal --> |
| ... | @@ -349,6 +366,16 @@ | ... | @@ -349,6 +366,16 @@ |
| 349 | <text style="font-size: 1rem;">是否确认取消订单?</text> | 366 | <text style="font-size: 1rem;">是否确认取消订单?</text> |
| 350 | </view> | 367 | </view> |
| 351 | </template> | 368 | </template> |
| 369 | + <template #footer> | ||
| 370 | + <view class="flex gap-4 p-4"> | ||
| 371 | + <nut-button plain class="flex-1" size="small" @click="showCancelConfirmModal = false"> | ||
| 372 | + 我再想想 | ||
| 373 | + </nut-button> | ||
| 374 | + <nut-button type="warning" class="flex-1" size="small" color="orange" @click="performCancelOrder(pendingCancelOrderId)"> | ||
| 375 | + 确定取消 | ||
| 376 | + </nut-button> | ||
| 377 | + </view> | ||
| 378 | + </template> | ||
| 352 | </nut-dialog> | 379 | </nut-dialog> |
| 353 | 380 | ||
| 354 | <!-- 确认发货弹窗 --> | 381 | <!-- 确认发货弹窗 --> |
| ... | @@ -359,6 +386,16 @@ | ... | @@ -359,6 +386,16 @@ |
| 359 | <text style="font-size: 1rem;">确认已将车辆发货给买家?</text> | 386 | <text style="font-size: 1rem;">确认已将车辆发货给买家?</text> |
| 360 | </view> | 387 | </view> |
| 361 | </template> | 388 | </template> |
| 389 | + <template #footer> | ||
| 390 | + <view class="flex gap-4 p-4"> | ||
| 391 | + <nut-button plain class="flex-1" size="small" @click="showShipConfirmModal = false"> | ||
| 392 | + 取消 | ||
| 393 | + </nut-button> | ||
| 394 | + <nut-button type="warning" class="flex-1" size="small" color="orange" @click="performConfirmShip(pendingShipOrderId)"> | ||
| 395 | + 确认发货 | ||
| 396 | + </nut-button> | ||
| 397 | + </view> | ||
| 398 | + </template> | ||
| 362 | </nut-dialog> | 399 | </nut-dialog> |
| 363 | 400 | ||
| 364 | <!-- 确认收货弹窗 --> | 401 | <!-- 确认收货弹窗 --> |
| ... | @@ -369,6 +406,16 @@ | ... | @@ -369,6 +406,16 @@ |
| 369 | <text style="font-size: 1rem;">确认已收到车辆?</text> | 406 | <text style="font-size: 1rem;">确认已收到车辆?</text> |
| 370 | </view> | 407 | </view> |
| 371 | </template> | 408 | </template> |
| 409 | + <template #footer> | ||
| 410 | + <view class="flex gap-4 p-4"> | ||
| 411 | + <nut-button plain class="flex-1" size="small" @click="showReceiveConfirmModal = false"> | ||
| 412 | + 取消 | ||
| 413 | + </nut-button> | ||
| 414 | + <nut-button type="warning" class="flex-1" size="small" color="orange" @click="performConfirmReceive(pendingReceiveOrderId)"> | ||
| 415 | + 确认收货 | ||
| 416 | + </nut-button> | ||
| 417 | + </view> | ||
| 418 | + </template> | ||
| 372 | </nut-dialog> | 419 | </nut-dialog> |
| 373 | </view> | 420 | </view> |
| 374 | </template> | 421 | </template> | ... | ... |
-
Please register or login to post a comment