From 0dbf34348c42f8800259472c8a30c132894ed0d1 Mon Sep 17 00:00:00 2001 From: pushuo <229102104@qq.com> Date: Mon, 15 Aug 2022 12:42:51 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E4=B8=AA=E4=BA=BA=E4=B8=AD?= =?UTF-8?q?=E5=BF=83=20=E8=AE=A2=E5=8D=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/build/beike/shop/default/js/app.js | 3 +- resources/beike/shop/default/js/common.js | 3 +- themes/default/account/account.blade.php | 101 ++++++++++++++-------- themes/default/layout/master.blade.php | 4 + 4 files changed, 72 insertions(+), 39 deletions(-) diff --git a/public/build/beike/shop/default/js/app.js b/public/build/beike/shop/default/js/app.js index 6a097c50..599dbf23 100644 --- a/public/build/beike/shop/default/js/app.js +++ b/public/build/beike/shop/default/js/app.js @@ -2165,8 +2165,9 @@ __webpack_require__.r(__webpack_exports__); }).then(function (res) { layer.msg(res.message); $btn.attr('data-in-wishlist', res.data.id); - })["finally"](function (e) { $btn.html(btnHtml).prop('disabled', false).find('i.bi').prop('class', 'bi bi-heart-fill'); + })["catch"](function (e) { + $btn.html(btnHtml).prop('disabled', false); }); } }, diff --git a/resources/beike/shop/default/js/common.js b/resources/beike/shop/default/js/common.js index d85d019f..6203a95c 100644 --- a/resources/beike/shop/default/js/common.js +++ b/resources/beike/shop/default/js/common.js @@ -78,8 +78,9 @@ export default { $http.post('account/wishlist', {product_id: id}, {hload: true}).then((res) => { layer.msg(res.message) $btn.attr('data-in-wishlist', res.data.id); - }).finally((e) => { $btn.html(btnHtml).prop('disabled', false).find('i.bi').prop('class', 'bi bi-heart-fill') + }).catch((e) => { + $btn.html(btnHtml).prop('disabled', false) }) } }, diff --git a/themes/default/account/account.blade.php b/themes/default/account/account.blade.php index 00f07d2c..fb065c3e 100644 --- a/themes/default/account/account.blade.php +++ b/themes/default/account/account.blade.php @@ -13,12 +13,14 @@
近期订单
--}} +|
+
+ @foreach ($order->orderProducts as $product)
+
+ |
+
+ 订单号:{{ $order->number }} 共 {{ count($order->orderProducts) }} 件商品
+ 下单时间:{{ $order->created_at }}
+ |
+ + 状态:{{ $order->status }} + | ++ 金额:{{ $order->total }} + | - @foreach ($latest_orders as $order) -|
| - {{ $order->created_at }} - 订单号:{{ $order->number }} - | -||||
|
-
-
-
- {{ $product->name }}
-
- {{ $product->quantity }}
- |
- @if ($loop->first)
- {{ $order->total }} | -{{ $order->status }} | -- 查看 - | - @endif ++ 查看详情 + |