优化代码
This commit is contained in:
@@ -63,12 +63,12 @@
|
||||
<el-table-column label="日期" prop="tradeDay"></el-table-column>
|
||||
<el-table-column label="营业额" prop="total">
|
||||
<template v-slot="scope">
|
||||
¥{{ scope.row.total }}
|
||||
¥{{ scope.row.total }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="销售额" prop="total">
|
||||
<template v-slot="scope">
|
||||
¥{{ scope.row.total + scope.row.refund }}
|
||||
¥{{ scope.row.total | totalfilter(scope.row.refund) }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="微信小程序支付" prop="wxLite">
|
||||
@@ -106,6 +106,7 @@
|
||||
<el-table-column label="商品名称" prop="productName"></el-table-column>
|
||||
<el-table-column label="商品分类" prop="cateName"></el-table-column>
|
||||
<el-table-column label="商品描述" prop="productSkuName"></el-table-column>
|
||||
<el-table-column label="单价" prop="price"></el-table-column>
|
||||
<el-table-column label="销量" prop="salesNum"></el-table-column>
|
||||
<el-table-column label="退单量" prop="refNum"></el-table-column>
|
||||
<el-table-column label="销售金额" prop="salesAmount">
|
||||
@@ -161,6 +162,10 @@ export default {
|
||||
filters: {
|
||||
timeFilter(time) {
|
||||
return dayjs(time).format("YYYY-MM-DD HH:mm:ss");
|
||||
},
|
||||
totalfilter(item,d) {
|
||||
let num = item + d
|
||||
return num.toFixed(2)
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
|
||||
@@ -142,7 +142,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="foot">退款:¥-{{ item.refundAmount }}</div>
|
||||
<div class="foot">退款:¥-{{ item.orderAmount }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</el-tab-pane>
|
||||
|
||||
@@ -123,10 +123,8 @@
|
||||
{{ item.productName }}
|
||||
<span
|
||||
class="refund"
|
||||
v-if="
|
||||
item.status == 'refunding' || item.status == 'refund'
|
||||
"
|
||||
>(退 - {{ item.num }})</span
|
||||
v-if="item.refundNumber"
|
||||
>(退 - {{ item.refundNumber }})</span
|
||||
>
|
||||
</div>
|
||||
<div class="sku">{{ item.productSkuName }}</div>
|
||||
@@ -140,13 +138,13 @@
|
||||
<div>{{ scope.row.orderType | orderTypeFilter }}</div>
|
||||
<div
|
||||
class="refund"
|
||||
v-if="
|
||||
scope.row.status == 'refunding' || scope.row.status == 'refund'
|
||||
v-if="
|
||||
scope.row.orderType == 'return'
|
||||
"
|
||||
>
|
||||
退款:-¥{{ scope.row.refundAmount }}
|
||||
退款:-¥{{ scope.row.orderAmount }}
|
||||
</div>
|
||||
<div>¥{{ scope.row.orderAmount }}</div>
|
||||
<div v-else>¥{{ scope.row.orderAmount }}</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="状态">
|
||||
|
||||
Reference in New Issue
Block a user