Merge branch 'main' of https://git.opencomputing.cn/yumoqing/kboss
This commit is contained in:
commit
2bb52fc378
@ -119,3 +119,13 @@ export const reqSearchProductList = (data) => {
|
|||||||
data
|
data
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 累计消费 共优惠
|
||||||
|
export const reqDiscount = (data) => {
|
||||||
|
return request({
|
||||||
|
url: '/bz_order/cumulative_order.dspy',
|
||||||
|
method: 'get',
|
||||||
|
headers: {'Content-Type': 'application/json'},
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|||||||
@ -124,14 +124,14 @@
|
|||||||
<span class="stat-label">累计支付总金额:</span>
|
<span class="stat-label">累计支付总金额:</span>
|
||||||
<div class="stat-value">
|
<div class="stat-value">
|
||||||
<el-skeleton animated v-if="all_price_show" :rows="1" style="width: 80px" />
|
<el-skeleton animated v-if="all_price_show" :rows="1" style="width: 80px" />
|
||||||
<span v-else class="price-text">¥ {{ all_price || '0.00' }}</span>
|
<span v-else class="price-text">¥ {{ price || '0.00' }}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="stat-item">
|
<div class="stat-item">
|
||||||
<span class="stat-label">累计优惠总金额:</span>
|
<span class="stat-label">累计优惠总金额:</span>
|
||||||
<div class="stat-value">
|
<div class="stat-value">
|
||||||
<el-skeleton animated v-if="all_price_show" :rows="1" style="width: 80px" />
|
<el-skeleton animated v-if="all_price_show" :rows="1" style="width: 80px" />
|
||||||
<span v-else class="price-text">¥ {{ all_discount || '0.00' }}</span>
|
<span v-else class="price-text">¥ {{ discount || '0.00' }}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -247,12 +247,14 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { getOrderAPI } from "@/api/product/product";
|
import { getOrderAPI ,reqDiscount} from "@/api/product/product";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'OrderManagement',
|
name: 'OrderManagement',
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
price:0,//累计消费
|
||||||
|
discount:0,//累计优惠
|
||||||
pagination: {
|
pagination: {
|
||||||
page: 1,
|
page: 1,
|
||||||
size: 10,
|
size: 10,
|
||||||
@ -344,6 +346,7 @@ export default {
|
|||||||
created() {
|
created() {
|
||||||
this.isMobile = /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(this.userAgent);
|
this.isMobile = /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(this.userAgent);
|
||||||
this.initFromRouteQuery();
|
this.initFromRouteQuery();
|
||||||
|
this.getAllPrice()
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
// 监听路由变化,当从首页跳转过来时重新处理参数
|
// 监听路由变化,当从首页跳转过来时重新处理参数
|
||||||
@ -352,6 +355,14 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
// 累计消费 优惠
|
||||||
|
async getAllPrice() {
|
||||||
|
console.log(54321,res);
|
||||||
|
if(res.status === true){
|
||||||
|
this.price = res.data.total_paid_amount
|
||||||
|
this.discount = res.data.total_discount_amount
|
||||||
|
}
|
||||||
|
},
|
||||||
// 从路由参数初始化筛选条件
|
// 从路由参数初始化筛选条件
|
||||||
initFromRouteQuery() {
|
initFromRouteQuery() {
|
||||||
const query = this.$route.query;
|
const query = this.$route.query;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user