优化结账页面 提交订单 按钮状态判断
This commit is contained in:
parent
02dd913ec1
commit
0bcdc4e222
|
|
@ -54,7 +54,7 @@
|
|||
class="text-muted">{{ __('shop/account.after_sales') }}</span></a>
|
||||
</div>
|
||||
<div class="order-wrap">
|
||||
@if (!$latest_orders)
|
||||
@if (!count($latest_orders))
|
||||
<div class="no-order d-flex flex-column align-items-center">
|
||||
<div class="icon mb-2"><i class="iconfont"></i></div>
|
||||
<div class="text mb-3 text-muted">{{ __('shop/account.no_order') }}<a href="">{{ __('shop/account.to_buy') }}</a></div>
|
||||
|
|
|
|||
|
|
@ -107,7 +107,7 @@
|
|||
@endforeach
|
||||
</ul>
|
||||
<div class="d-grid gap-2 mt-3">
|
||||
<button class="btn btn-primary" type="button" @click="checkedBtnCheckoutConfirm">提交订单</button>
|
||||
<button class="btn btn-primary" type="button" :disabled="!isSubmit" @click="checkedBtnCheckoutConfirm">提交订单</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -168,6 +168,10 @@
|
|||
|
||||
// 计算属性
|
||||
computed: {
|
||||
isSubmit() {
|
||||
// source.addresses.length > 0 && source.payment_methods.length > 0 && source.shipping_methods.length > 0
|
||||
return this.source.addresses.length > 0 && this.source.payment_methods.length > 0 && this.source.shipping_methods.length > 0;
|
||||
},
|
||||
// isAddress: {
|
||||
// this.form.shipping_address_id ==
|
||||
// }
|
||||
|
|
|
|||
Loading…
Reference in New Issue