给销售订单单据增加强制结单-以销定购的按钮
This commit is contained in:
@@ -231,37 +231,6 @@ export const JeecgListMixin = {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
batchForceClose: function () {
|
|
||||||
if(!this.url.forceCloseBatch){
|
|
||||||
this.$message.error("请设置url.forceCloseBatch属性!")
|
|
||||||
return
|
|
||||||
}
|
|
||||||
if (this.selectedRowKeys.length <= 0) {
|
|
||||||
this.$message.warning('请选择一条记录!')
|
|
||||||
} else {
|
|
||||||
let ids = "";
|
|
||||||
for (let a = 0; a < this.selectedRowKeys.length; a++) {
|
|
||||||
ids += this.selectedRowKeys[a] + ","
|
|
||||||
}
|
|
||||||
let that = this
|
|
||||||
this.$confirm({
|
|
||||||
title: "确认强制结单",
|
|
||||||
content: "是否强制结单选中数据?",
|
|
||||||
onOk: function () {
|
|
||||||
that.loading = true
|
|
||||||
postAction(that.url.forceCloseBatch, {ids: ids}).then((res) => {
|
|
||||||
if(res.code === 200){
|
|
||||||
that.loadData()
|
|
||||||
} else {
|
|
||||||
that.$message.warning(res.data.message)
|
|
||||||
}
|
|
||||||
}).finally(() => {
|
|
||||||
that.loading = false
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
},
|
|
||||||
handleDelete: function (id) {
|
handleDelete: function (id) {
|
||||||
if(!this.url.delete){
|
if(!this.url.delete){
|
||||||
this.$message.error("请设置url.delete属性!")
|
this.$message.error("请设置url.delete属性!")
|
||||||
|
|||||||
@@ -86,6 +86,7 @@
|
|||||||
<a-button v-if="btnEnableList.indexOf(1)>-1" @click="myHandleAdd" type="primary" icon="plus">新增</a-button>
|
<a-button v-if="btnEnableList.indexOf(1)>-1" @click="myHandleAdd" type="primary" icon="plus">新增</a-button>
|
||||||
<a-button v-if="btnEnableList.indexOf(1)>-1" icon="delete" @click="batchDel">删除</a-button>
|
<a-button v-if="btnEnableList.indexOf(1)>-1" icon="delete" @click="batchDel">删除</a-button>
|
||||||
<a-button v-if="btnEnableList.indexOf(1)>-1" icon="issues-close" @click="batchForceClose">强制结单</a-button>
|
<a-button v-if="btnEnableList.indexOf(1)>-1" icon="issues-close" @click="batchForceClose">强制结单</a-button>
|
||||||
|
<a-button v-if="purchaseBySaleFlag && btnEnableList.indexOf(1)>-1" icon="issues-close" @click="batchForceClosePurchase">强制结单-以销定购</a-button>
|
||||||
<a-button v-if="checkFlag && btnEnableList.indexOf(2)>-1" icon="check" @click="batchSetStatus(1)">审核</a-button>
|
<a-button v-if="checkFlag && btnEnableList.indexOf(2)>-1" icon="check" @click="batchSetStatus(1)">审核</a-button>
|
||||||
<a-button v-if="checkFlag && btnEnableList.indexOf(7)>-1" icon="stop" @click="batchSetStatus(0)">反审核</a-button>
|
<a-button v-if="checkFlag && btnEnableList.indexOf(7)>-1" icon="stop" @click="batchSetStatus(0)">反审核</a-button>
|
||||||
<a-button v-if="isShowExcel && btnEnableList.indexOf(3)>-1" icon="download" @click="handleExport">导出</a-button>
|
<a-button v-if="isShowExcel && btnEnableList.indexOf(3)>-1" icon="download" @click="handleExport">导出</a-button>
|
||||||
@@ -201,6 +202,8 @@
|
|||||||
remark: ""
|
remark: ""
|
||||||
},
|
},
|
||||||
prefixNo: 'XSDD',
|
prefixNo: 'XSDD',
|
||||||
|
//以销定购开关
|
||||||
|
purchaseBySaleFlag: false,
|
||||||
labelCol: {
|
labelCol: {
|
||||||
span: 5
|
span: 5
|
||||||
},
|
},
|
||||||
@@ -258,6 +261,7 @@
|
|||||||
delete: "/depotHead/delete",
|
delete: "/depotHead/delete",
|
||||||
deleteBatch: "/depotHead/deleteBatch",
|
deleteBatch: "/depotHead/deleteBatch",
|
||||||
forceCloseBatch: "/depotHead/forceCloseBatch",
|
forceCloseBatch: "/depotHead/forceCloseBatch",
|
||||||
|
forceClosePurchaseBatch: "/depotHead/forceClosePurchaseBatch",
|
||||||
batchSetStatusUrl: "/depotHead/batchSetStatus"
|
batchSetStatusUrl: "/depotHead/batchSetStatus"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
import Vue from 'vue'
|
import Vue from 'vue'
|
||||||
import {getAction } from '@/api/manage'
|
import { getAction, postAction } from '@/api/manage'
|
||||||
import { FormTypes } from '@/utils/JEditableTableUtil'
|
import { FormTypes } from '@/utils/JEditableTableUtil'
|
||||||
import {findBillDetailByNumber, findBySelectSup, findBySelectCus, findBySelectRetail, getUserList, getAccount, waitBillCount,
|
import {findBillDetailByNumber, findBySelectSup, findBySelectCus, findBySelectRetail, getUserList, getAccount, waitBillCount,
|
||||||
getCurrentSystemConfig, getPlatformConfigByKey} from '@/api/api'
|
getCurrentSystemConfig, getPlatformConfigByKey} from '@/api/api'
|
||||||
@@ -107,6 +107,68 @@ export const BillListMixin = {
|
|||||||
}
|
}
|
||||||
this.handleDetail(record, type, prefixNo);
|
this.handleDetail(record, type, prefixNo);
|
||||||
},
|
},
|
||||||
|
batchForceClose: function () {
|
||||||
|
if(!this.url.forceCloseBatch){
|
||||||
|
this.$message.error("请设置url.forceCloseBatch属性!")
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (this.selectedRowKeys.length <= 0) {
|
||||||
|
this.$message.warning('请选择一条记录!')
|
||||||
|
} else {
|
||||||
|
let ids = "";
|
||||||
|
for (let a = 0; a < this.selectedRowKeys.length; a++) {
|
||||||
|
ids += this.selectedRowKeys[a] + ","
|
||||||
|
}
|
||||||
|
let that = this
|
||||||
|
this.$confirm({
|
||||||
|
title: "确认强制结单",
|
||||||
|
content: "是否强制结单选中数据?",
|
||||||
|
onOk: function () {
|
||||||
|
that.loading = true
|
||||||
|
postAction(that.url.forceCloseBatch, {ids: ids}).then((res) => {
|
||||||
|
if(res.code === 200){
|
||||||
|
that.loadData()
|
||||||
|
} else {
|
||||||
|
that.$message.warning(res.data.message)
|
||||||
|
}
|
||||||
|
}).finally(() => {
|
||||||
|
that.loading = false
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
|
batchForceClosePurchase: function () {
|
||||||
|
if(!this.url.forceClosePurchaseBatch){
|
||||||
|
this.$message.error("请设置url.forceClosePurchaseBatch属性!")
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (this.selectedRowKeys.length <= 0) {
|
||||||
|
this.$message.warning('请选择一条记录!')
|
||||||
|
} else {
|
||||||
|
let ids = "";
|
||||||
|
for (let a = 0; a < this.selectedRowKeys.length; a++) {
|
||||||
|
ids += this.selectedRowKeys[a] + ","
|
||||||
|
}
|
||||||
|
let that = this
|
||||||
|
this.$confirm({
|
||||||
|
title: "确认强制结单(以销定购)",
|
||||||
|
content: "是否强制结单选中数据?",
|
||||||
|
onOk: function () {
|
||||||
|
that.loading = true
|
||||||
|
postAction(that.url.forceClosePurchaseBatch, {ids: ids}).then((res) => {
|
||||||
|
if(res.code === 200){
|
||||||
|
that.loadData()
|
||||||
|
} else {
|
||||||
|
that.$message.warning(res.data.message)
|
||||||
|
}
|
||||||
|
}).finally(() => {
|
||||||
|
that.loading = false
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
handleApprove(record) {
|
handleApprove(record) {
|
||||||
this.$refs.modalForm.action = "approve";
|
this.$refs.modalForm.action = "approve";
|
||||||
this.$refs.modalForm.edit(record);
|
this.$refs.modalForm.edit(record);
|
||||||
|
|||||||
Reference in New Issue
Block a user