This commit is contained in:
faiz 2024-06-18 16:22:59 +08:00
parent 0b7ff0e50b
commit f374238e56
2 changed files with 22 additions and 0 deletions

View File

@ -62,6 +62,12 @@ export function cardListApi(data) {
export function orderUpdateApi(id) { export function orderUpdateApi(id) {
return request.get(`store/order/update/${id}/form`) return request.get(`store/order/update/${id}/form`)
} }
/**
* @description 订单 -- 手动退款
*/
export function onOrdermanualApi(id) {
return request.get(`order/refund/manual/${id}`)
}
/** /**
* @description 订单 -- 发货 * @description 订单 -- 发货

View File

@ -189,6 +189,7 @@
@click="onOrderDetail(scope.row.order.order_sn)" @click="onOrderDetail(scope.row.order.order_sn)"
>订单详情</el-button> >订单详情</el-button>
<el-button v-if="scope.row.status === 0" type="text" size="small" @click="onOrderStatus(scope.row.refund_order_id)">退款</el-button> <el-button v-if="scope.row.status === 0" type="text" size="small" @click="onOrderStatus(scope.row.refund_order_id)">退款</el-button>
<el-button v-if="scope.row.status === 0" type="text" size="small" @click="onOrdermanual(scope.row.refund_order_id)">手动退款</el-button>
<el-button type="text" size="small" @click="onRefundOrderDetail(scope.row.refund_order_id)">退款单详情</el-button> <el-button type="text" size="small" @click="onRefundOrderDetail(scope.row.refund_order_id)">退款单详情</el-button>
</template> </template>
</el-table-column> </el-table-column>
@ -234,6 +235,7 @@ import {
refundorderStatusApi, refundorderStatusApi,
refundorderDetailApi, refundorderDetailApi,
refundorderExpressApi, refundorderExpressApi,
onOrdermanualApi,
orderDeliveryApi, exportRefundOrderApi orderDeliveryApi, exportRefundOrderApi
} from "@/api/order"; } from "@/api/order";
import createWorkBook from '@/utils/newToExcel.js'; import createWorkBook from '@/utils/newToExcel.js';
@ -316,6 +318,20 @@ export default {
// 退 // 退
onOrderStatus(id) { onOrderStatus(id) {
this.$modalForm(refundorderStatusApi(id)).then(() => this.getList('')) this.$modalForm(refundorderStatusApi(id)).then(() => this.getList(''))
},
onOrdermanual(id){
this.$confirm('请确认该订单已线下退款,请谨慎操作', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
onOrdermanualApi(id).then((res)=>{
this.$message.success(res.message)
this.getList('');
}).catch(({ message }) => {
this.$message.error(message)
});
})
}, },
// //
onRefundOrderDetail(id) { onRefundOrderDetail(id) {