This commit is contained in:
pushuo 2022-07-01 17:49:40 +08:00
parent 467699dc15
commit 329bdb0a9c
11 changed files with 42 additions and 8 deletions

View File

@ -46,7 +46,7 @@ body {
}
.main-content > #content {
flex: 1;
padding: 1rem;
padding: 1rem 1rem 4rem;
overflow-y: auto;
}
@media screen and (max-width: 991px) {
@ -224,6 +224,12 @@ body.page-seller-product .share-link-pop .share-links-code img {
}
.header-wrap .header-left {
width: 190px;
display: flex;
align-items: center;
justify-content: center;
}
.header-wrap .header-left .logo {
max-width: 76%;
}
.header-wrap .header-right {
display: flex;

View File

@ -104,6 +104,7 @@
height: 17px;
text-align: center;
cursor: pointer;
background-color: #fff;
}
.quantity-wrap > .right i:last-of-type {
border-top: 1px solid #ced4da;
@ -429,6 +430,9 @@ body.page-cart .cart-products-wrap .table tbody td {
vertical-align: middle;
border-color: #f0f2f4;
}
body.page-cart .cart-products-wrap .table tbody tr.active {
background-color: #fff6f1;
}
body.page-cart .cart-products-wrap .table thead {
background-color: #F8F9FA;
}

View File

@ -18,6 +18,7 @@ $(document).ready(function ($) {
}
});
$('.quantity-wrap .right i').on('click', function (event) {
event.stopPropagation();
var input = $(this).parent().siblings('input');
if ($(this).hasClass('bi-chevron-up')) {

View File

@ -44,7 +44,7 @@ body {
> #content {
flex: 1;
padding: 1rem;
padding: 1rem 1rem 4rem;
overflow-y: auto;
@media screen and (max-width: 991px) {

View File

@ -17,6 +17,14 @@
.header-left {
width: 190px;
display: flex;
align-items: center; // flex-start | center
justify-content: center; // flex-end | center | space-between
// flex-wrap: wrap;
.logo {
max-width: 76%;
}
}
.header-right {

View File

@ -1,8 +1,8 @@
<div class="header-wrap">
<div class="header-left">
<div class="logo">
{{-- <img src="http://dummyimage.com/200x50" class="img-fluid"> --}}
<div class="text-center"><h5 class="mb-0">beike admin</h5></div>
<img src="{{ asset('image/logo.png') }}" class="img-fluid">
{{-- <div class="text-center"><h5 class="mb-0">beike admin</h5></div> --}}
</div>
</div>
<div class="header-right">

View File

@ -9,6 +9,12 @@ body.page-cart {
vertical-align: middle;
border-color: #f0f2f4;
}
tr {
&.active {
background-color: #fff6f1;
}
}
}
thead {

View File

@ -101,6 +101,7 @@
height: 17px;
text-align: center;
cursor: pointer;
background-color: #fff;
&:last-of-type {
border-top: 1px solid #ced4da;
}

View File

@ -6,6 +6,7 @@ $(document).ready(function ($) {
});
$('.quantity-wrap .right i').on('click', function(event) {
event.stopPropagation();
let input = $(this).parent().siblings('input')
if ($(this).hasClass('bi-chevron-up')) {

View File

@ -40,10 +40,11 @@
</tr>
</thead>
<tbody>
<tr v-for="product, index in products" :key="index">
<tr v-for="product, index in products" :key="index" @click="checkedCartTr(index)"
:class="product.selected ? 'active' : ''">
<td>
<div class="d-flex align-items-center p-image">
<input class="form-check-input" @change="selectedBtnSelected" type="checkbox" v-model="product.selected">
<input class="form-check-input" type="checkbox" v-model="product.selected">
<img :src="product.image" class="img-fluid">
</div>
</td>
@ -75,7 +76,8 @@
<div class="card-header"><h5 class="mb-0">商品总计</h5></div>
<div class="card-body">
<ul class="list-group list-group-flush">
<li class="list-group-item"><span>总数</span><span>@{{ total_quantity }}</span></li>
<li class="list-group-item"><span>全部</span><span>@{{ products.length }}</span></li>
<li class="list-group-item"><span>已选</span><span>@{{ total_quantity }}</span></li>
<li class="list-group-item border-bottom-0"><span>总价</span><span class="total-price">@{{ amount_format }}</span></li>
<li class="list-group-item d-grid gap-2 mt-3 border-bottom-0">
{{-- <a href="{{ shop_route('checkout.index', 'checkout') }}" class="btn btn-primary">去结账</a> --}}
@ -151,6 +153,11 @@
})
},
checkedCartTr(index) {
this.products[index].selected = !this.products[index].selected;
this.selectedBtnSelected();
},
selectedBtnSelected() {
const self = this;
const cart_ids = this.products.filter(e => e.selected).map(x => x.cart_id)

View File

@ -213,6 +213,7 @@
},
beforeMount () {
this.countryChange(this.dialogAddress.form.country_id);
},
methods: {
@ -225,7 +226,6 @@
})
}
this.countryChange(this.dialogAddress.form.country_id);
this.dialogAddress.show = true
},