取消订单设置
This commit is contained in:
parent
f67b394ea1
commit
ff6fba29a6
|
|
@ -383,17 +383,17 @@ const downloadContract = () => {
|
|||
// }
|
||||
}
|
||||
|
||||
const confirmFail = async (index: number) => {
|
||||
const confirmFail = async (item: any) => {
|
||||
ElMessageBox.confirm('是否确定取消订单?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
})
|
||||
.then(() => {
|
||||
return failApi({ orderId: cardList.value[index].orderId, orderStatus: 99 })
|
||||
return failApi({ orderId: item.orderId, orderStatus: 99 })
|
||||
// return removeDeviceApi([row.maId])
|
||||
})
|
||||
.then((res) => {
|
||||
.then((res: any) => {
|
||||
if (res.code === 200) {
|
||||
ElMessage({
|
||||
type: 'success',
|
||||
|
|
@ -865,10 +865,10 @@ const costSubmit = () => {
|
|||
</el-button>
|
||||
<!-- <el-button type="primary" size="small"> 发起减免 </el-button> -->
|
||||
<el-button
|
||||
v-if="item.orderStatus == '2'"
|
||||
v-if="item.orderStatus == '1' || item.orderStatus == '2'"
|
||||
type="primary"
|
||||
size="small"
|
||||
@click="confirmFail(index)"
|
||||
@click="confirmFail(item)"
|
||||
>
|
||||
取消订单
|
||||
</el-button>
|
||||
|
|
|
|||
|
|
@ -200,17 +200,18 @@ const confirmPass = async (index: number) => {
|
|||
}
|
||||
|
||||
// 驳回按钮
|
||||
const confirmFail = async (index: number) => {
|
||||
const confirmFail = async (item: any) => {
|
||||
// console.log(item.orderId, '-->>>')
|
||||
ElMessageBox.confirm('是否确定取消?', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning',
|
||||
})
|
||||
.then(() => {
|
||||
return failApi({ orderId: cardList.value[index].orderId, orderStatus: 99 })
|
||||
return failApi({ orderId: item.orderId, orderStatus: 99 })
|
||||
// return removeDeviceApi([row.maId])
|
||||
})
|
||||
.then((res) => {
|
||||
.then((res: any) => {
|
||||
if (res.code === 200) {
|
||||
ElMessage({
|
||||
type: 'success',
|
||||
|
|
@ -703,6 +704,11 @@ const downloadContract = () => {
|
|||
}
|
||||
|
||||
const wordUrl = ref('')
|
||||
|
||||
// 取消订单
|
||||
const handleCancel = () => {
|
||||
|
||||
}
|
||||
</script>
|
||||
|
||||
<template>
|
||||
|
|
@ -1130,8 +1136,8 @@ const wordUrl = ref('')
|
|||
<el-button
|
||||
size="small"
|
||||
type="primary"
|
||||
v-if="item.orderStatus == '2'"
|
||||
@click="confirmFail(index)"
|
||||
v-if="item.orderStatus == '1'"
|
||||
@click="confirmFail(item)"
|
||||
>
|
||||
取消订单
|
||||
</el-button>
|
||||
|
|
|
|||
Loading…
Reference in New Issue