增加订单审核操作:增加到审核、审核失败状态
This commit is contained in:
parent
1a571e3519
commit
6bc3939a1b
|
@ -122,6 +122,18 @@ export function orderRefuseApi(params) {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 订单 审核失败
|
||||||
|
* @param prams
|
||||||
|
*/
|
||||||
|
export function orderAuditApi(audit,params) {
|
||||||
|
return request({
|
||||||
|
url: `/admin/store/order/audit/${audit}`,
|
||||||
|
method: 'get',
|
||||||
|
params,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 订单 立即退款
|
* 订单 立即退款
|
||||||
* @param prams
|
* @param prams
|
||||||
|
|
|
@ -19,6 +19,9 @@
|
||||||
<el-radio-button label="unPaid"
|
<el-radio-button label="unPaid"
|
||||||
>未支付 {{ '(' + orderChartType.unPaid ? orderChartType.unPaid : 0 + ')' }}</el-radio-button
|
>未支付 {{ '(' + orderChartType.unPaid ? orderChartType.unPaid : 0 + ')' }}</el-radio-button
|
||||||
>
|
>
|
||||||
|
<el-radio-button label="audit"
|
||||||
|
>待审核 {{ '(' + orderChartType.audit ? orderChartType.audit : 0 + ')' }}</el-radio-button
|
||||||
|
>
|
||||||
<el-radio-button label="notShipped"
|
<el-radio-button label="notShipped"
|
||||||
>未发货 {{ '(' + orderChartType.notShipped ? orderChartType.notShipped : 0 + ')' }}</el-radio-button
|
>未发货 {{ '(' + orderChartType.notShipped ? orderChartType.notShipped : 0 + ')' }}</el-radio-button
|
||||||
>
|
>
|
||||||
|
@ -41,6 +44,9 @@
|
||||||
<el-radio-button label="refunded"
|
<el-radio-button label="refunded"
|
||||||
>已退款 {{ '(' + orderChartType.refunded ? orderChartType.refunded : 0 + ')' }}</el-radio-button
|
>已退款 {{ '(' + orderChartType.refunded ? orderChartType.refunded : 0 + ')' }}</el-radio-button
|
||||||
>
|
>
|
||||||
|
<el-radio-button label="auditReject"
|
||||||
|
>已驳回 {{ '(' + orderChartType.auditReject ? orderChartType.auditReject : 0 + ')' }}</el-radio-button
|
||||||
|
>
|
||||||
<el-radio-button label="deleted"
|
<el-radio-button label="deleted"
|
||||||
>已删除 {{ '(' + orderChartType.deleted ? orderChartType.deleted : 0 + ')' }}</el-radio-button
|
>已删除 {{ '(' + orderChartType.deleted ? orderChartType.deleted : 0 + ')' }}</el-radio-button
|
||||||
>
|
>
|
||||||
|
@ -203,6 +209,14 @@
|
||||||
class="mr10"
|
class="mr10"
|
||||||
>编辑</el-button
|
>编辑</el-button
|
||||||
>
|
>
|
||||||
|
<el-button
|
||||||
|
v-if="scope.row.orderType == '[分期订单]' && scope.row.statusStr.key === 'audit' && checkPermi(['admin:order:audit'])"
|
||||||
|
type="text"
|
||||||
|
size="small"
|
||||||
|
@click="onAudit(scope.row)"
|
||||||
|
class="mr10"
|
||||||
|
>审核</el-button
|
||||||
|
>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="
|
v-if="
|
||||||
scope.row.statusStr.key === 'notShipped' &&
|
scope.row.statusStr.key === 'notShipped' &&
|
||||||
|
@ -253,15 +267,9 @@
|
||||||
<el-dropdown-item
|
<el-dropdown-item
|
||||||
@click.native="onInstallmentBills(scope.row.id)"
|
@click.native="onInstallmentBills(scope.row.id)"
|
||||||
v-if="checkPermi(['admin:order:info'])"
|
v-if="checkPermi(['admin:order:info'])"
|
||||||
v-show="scope.row.orderType == '[分期订单]'"
|
v-show="scope.row.orderType == '[分期订单]' && scope.row.statusStr.key != 'audit' && scope.row.statusStr.key != 'auditReject'"
|
||||||
>查看账单</el-dropdown-item
|
>查看账单</el-dropdown-item
|
||||||
>
|
>
|
||||||
<el-dropdown-item
|
|
||||||
@click.native="onAudit(scope.row.id)"
|
|
||||||
v-if="checkPermi(['admin:order:info'])"
|
|
||||||
v-show="scope.row.orderType == '[分期订单]'"
|
|
||||||
>审核</el-dropdown-item
|
|
||||||
>
|
|
||||||
<el-dropdown-item
|
<el-dropdown-item
|
||||||
@click.native="onOrderLog(scope.row.orderId)"
|
@click.native="onOrderLog(scope.row.orderId)"
|
||||||
v-if="checkPermi(['admin:order:status:list'])"
|
v-if="checkPermi(['admin:order:status:list'])"
|
||||||
|
@ -379,6 +387,25 @@
|
||||||
<!--详情-->
|
<!--详情-->
|
||||||
<details-from ref="orderDetail" :orderId="orderId" />
|
<details-from ref="orderDetail" :orderId="orderId" />
|
||||||
|
|
||||||
|
|
||||||
|
<!--审核-->
|
||||||
|
<el-dialog
|
||||||
|
title="审核"
|
||||||
|
v-if="AuditVisible"
|
||||||
|
:visible.sync="AuditVisible"
|
||||||
|
width="500px"
|
||||||
|
:before-close="AudithandleClose"
|
||||||
|
>
|
||||||
|
<zb-parser
|
||||||
|
:form-id="145"
|
||||||
|
:is-create="1"
|
||||||
|
:edit-data="AuditData"
|
||||||
|
@submit="AudithandlerSubmit"
|
||||||
|
@resetForm="resetFormAudithand"
|
||||||
|
/>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
|
|
||||||
<!-- 发送货 -->
|
<!-- 发送货 -->
|
||||||
<order-send
|
<order-send
|
||||||
ref="send"
|
ref="send"
|
||||||
|
@ -424,20 +451,20 @@
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import {
|
import {
|
||||||
orderListDataApi,
|
orderListDataApi,
|
||||||
orderStatusNumApi,
|
orderStatusNumApi,
|
||||||
writeUpdateApi,
|
writeUpdateApi,
|
||||||
orderListApi,
|
orderListApi,
|
||||||
updatePriceApi,
|
updatePriceApi,
|
||||||
orderLogApi,
|
orderLogApi,
|
||||||
orderMarkApi,
|
orderMarkApi,
|
||||||
orderDeleteApi,
|
orderDeleteApi,
|
||||||
orderRefuseApi,
|
orderRefuseApi,
|
||||||
orderRefundApi,
|
orderRefundApi,
|
||||||
orderPrint,
|
orderPrint,
|
||||||
orderDetailApi,
|
orderDetailApi, orderAuditApi
|
||||||
} from '@/api/order';
|
} from '@/api/order'
|
||||||
import zbParser from '@/components/FormGenerator/components/parser/ZBParser';
|
import zbParser from '@/components/FormGenerator/components/parser/ZBParser';
|
||||||
import detailsFrom from './orderDetail';
|
import detailsFrom from './orderDetail';
|
||||||
import orderSend from './orderSend';
|
import orderSend from './orderSend';
|
||||||
|
@ -479,6 +506,8 @@ export default {
|
||||||
],
|
],
|
||||||
RefuseVisible: false,
|
RefuseVisible: false,
|
||||||
RefuseData: {},
|
RefuseData: {},
|
||||||
|
AuditVisible: false,//审核弹窗
|
||||||
|
AuditData: {},
|
||||||
orderId: '',
|
orderId: '',
|
||||||
refundVisible: false,
|
refundVisible: false,
|
||||||
refundData: {},
|
refundData: {},
|
||||||
|
@ -576,6 +605,9 @@ export default {
|
||||||
resetFormRefusehand() {
|
resetFormRefusehand() {
|
||||||
this.RefuseVisible = false;
|
this.RefuseVisible = false;
|
||||||
},
|
},
|
||||||
|
resetFormAudithand() {
|
||||||
|
this.AuditVisible = false;
|
||||||
|
},
|
||||||
resetForm(formValue) {
|
resetForm(formValue) {
|
||||||
this.dialogVisible = false;
|
this.dialogVisible = false;
|
||||||
},
|
},
|
||||||
|
@ -598,6 +630,10 @@ export default {
|
||||||
RefusehandleClose() {
|
RefusehandleClose() {
|
||||||
this.RefuseVisible = false;
|
this.RefuseVisible = false;
|
||||||
},
|
},
|
||||||
|
//关闭 审核
|
||||||
|
AudithandleClose() {
|
||||||
|
this.AuditVisible = false;
|
||||||
|
},
|
||||||
onOrderRefuse(row) {
|
onOrderRefuse(row) {
|
||||||
this.orderids = row.orderId;
|
this.orderids = row.orderId;
|
||||||
this.RefuseData = {
|
this.RefuseData = {
|
||||||
|
@ -613,6 +649,25 @@ export default {
|
||||||
this.getList();
|
this.getList();
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
//审核提交
|
||||||
|
AudithandlerSubmit(formValue) {
|
||||||
|
let data;
|
||||||
|
if(formValue.audit == "reject" && (formValue.reason == undefined || formValue.reason == "")){
|
||||||
|
this.$message.error("驳回原因不能为空");
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if(formValue.audit == "pass"){
|
||||||
|
data = { orderNo: this.orderids, reason: "" ,audit:formValue.audit};
|
||||||
|
}else{
|
||||||
|
data = { orderNo: this.orderids, reason: formValue.reason ,audit:formValue.audit};
|
||||||
|
}
|
||||||
|
console.log("formValue-------"+JSON.stringify(data));
|
||||||
|
orderAuditApi(formValue.audit,data).then((res) => {
|
||||||
|
this.$message.success('操作成功');
|
||||||
|
this.AuditVisible = false;
|
||||||
|
this.getList();
|
||||||
|
});
|
||||||
|
},
|
||||||
// 立即退款
|
// 立即退款
|
||||||
refundhandleClose() {
|
refundhandleClose() {
|
||||||
this.refundVisible = false;
|
this.refundVisible = false;
|
||||||
|
@ -707,11 +762,14 @@ export default {
|
||||||
this.getInstallmentList(id);
|
this.getInstallmentList(id);
|
||||||
},
|
},
|
||||||
// 审核
|
// 审核
|
||||||
onAudit(id) {
|
onAudit(row) {
|
||||||
this.tableFromLog.limit = 10;
|
this.orderids = row.orderId;
|
||||||
this.orderId = id;
|
this.AuditData = {
|
||||||
this.dialogVisibleInstallment = true;
|
orderId: row.orderId,
|
||||||
// this.getInstallmentList(id);
|
audit: "pass",
|
||||||
|
reason: ""
|
||||||
|
};
|
||||||
|
this.AuditVisible = true;
|
||||||
},
|
},
|
||||||
// 订单记录
|
// 订单记录
|
||||||
onOrderLog(id) {
|
onOrderLog(id) {
|
||||||
|
@ -1015,4 +1073,7 @@ export default {
|
||||||
::v-deep .el-checkbox__input.is-checked + .el-checkbox__label {
|
::v-deep .el-checkbox__input.is-checked + .el-checkbox__label {
|
||||||
color: #606266;
|
color: #606266;
|
||||||
}
|
}
|
||||||
|
.el-form-item__content{
|
||||||
|
float: right;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
Loading…
Reference in New Issue
Block a user