BUG 29744
This commit is contained in:
@@ -195,14 +195,13 @@
|
|||||||
fixed="right">
|
fixed="right">
|
||||||
<template v-slot="{ row }">
|
<template v-slot="{ row }">
|
||||||
<div class="table-options">
|
<div class="table-options">
|
||||||
<el-button
|
<el-button v-if="row.orderCode" type="text" @click="goDetail(row)" title="详情"
|
||||||
v-if="row.orderCode"
|
:disabled="!$permissions('app_appvillagerintegralshoporder_detail')">详情
|
||||||
type="text"
|
|
||||||
@click="goDetail(row)"
|
|
||||||
title="详情"
|
|
||||||
:disabled="!$permissions('app_appvillagerintegralshoporder_detail')">
|
|
||||||
详情
|
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<template v-if="row.orderStatus==0">
|
||||||
|
<el-button type="text" @click="handlePendingOrder(row.id,1)">确认兑换</el-button>
|
||||||
|
<el-button type="text" @click="handlePendingOrder(row.id,0)">取消订单</el-button>
|
||||||
|
</template>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
@@ -325,14 +324,26 @@ export default {
|
|||||||
}
|
}
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
if (res.code == 0) {
|
if (res.code == 0) {
|
||||||
this.$message.success(`批量${val == 1 ? '完成' : '取消'}成功`)
|
this.$message.success(`批量${val == 1 ? '兑换' : '取消'}成功`)
|
||||||
this.getList()
|
this.getList()
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
handlePendingOrder(ids, status) {
|
||||||
|
let text = status == 1 ? "确认兑换" : "取消订单"
|
||||||
|
this.$confirm(`是否${text}?`).then(() => {
|
||||||
|
this.instance.post(`/app/appvillagerintegralshoporder/changeOrderStatus`, null, {
|
||||||
|
params: {ids, status}
|
||||||
|
}).then(res => {
|
||||||
|
if (res.code == 0) {
|
||||||
|
this.$message.success(`${text}成功`)
|
||||||
|
this.getList()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}).catch(() => 0)
|
||||||
|
},
|
||||||
getList() {
|
getList() {
|
||||||
this.instance
|
this.instance.post(`/app/appvillagerintegralshoporder/list`, null, {
|
||||||
.post(`/app/appvillagerintegralshoporder/list`, null, {
|
|
||||||
params: {
|
params: {
|
||||||
...this.searchObj,
|
...this.searchObj,
|
||||||
...this.page,
|
...this.page,
|
||||||
|
|||||||
Reference in New Issue
Block a user