对接订单打印小票
This commit is contained in:
@@ -44,7 +44,7 @@
|
||||
<span>{{ scope.row.productName }}</span>
|
||||
</div>
|
||||
<div class="sku" v-if="scope.row.skuName">{{ scope.row.skuName }}</div>
|
||||
<div class="sku">¥{{ formatDecimal(+scope.row.price) }}</div>
|
||||
<div class="sku">¥{{ formatDecimal(+scope.row.payAmount) }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
@@ -76,7 +76,7 @@
|
||||
<template #footer>
|
||||
<div class="drawer_footer">
|
||||
<div class="btn">
|
||||
<el-button style="width: 100%;" @click="refundHandle(true)">手动退款</el-button>
|
||||
<el-button style="width: 100%;" @click="handleRefund">手动退款</el-button>
|
||||
</div>
|
||||
<div class="btn">
|
||||
<el-button type="primary" style="width: 100%;" @click="refundHandle()">原路退回</el-button>
|
||||
@@ -91,7 +91,7 @@ import { ref, onMounted } from 'vue'
|
||||
import { useGlobal } from '@/store/global.js'
|
||||
import { formatDecimal, inputFilterFloat } from "@/utils/index.js";
|
||||
import { refundOrder } from '@/api/order.js'
|
||||
import { ElNotification } from 'element-plus'
|
||||
import { ElNotification, ElMessageBox } from 'element-plus'
|
||||
|
||||
const emits = defineEmits(['success'])
|
||||
|
||||
@@ -112,6 +112,15 @@ const remarkTagList = ref([
|
||||
'服务态度不满意'
|
||||
])
|
||||
|
||||
// 显示手动退款
|
||||
function handleRefund() {
|
||||
ElMessageBox.confirm('请线下手动转账给客户或现金,一旦操作完成无法修改订单状态,请慎重操作!', '注意', {
|
||||
confirmButtonText: '已在线下完成退款'
|
||||
}).then(() => {
|
||||
refundHandle(true)
|
||||
}).catch(() => { })
|
||||
}
|
||||
|
||||
// 开始退款
|
||||
async function refundHandle(cash = false) {
|
||||
try {
|
||||
@@ -200,7 +209,7 @@ function numberChange() {
|
||||
function tabSelectChange(val) {
|
||||
amount.value = 0
|
||||
val.map(item => {
|
||||
amount.value += item.refundNum * item.price
|
||||
amount.value += item.refundNum * item.payAmount
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user