Merge remote-tracking branch 'origin/master'

ywj_dev
郑明梁 2 years ago
commit c63ed6c90a

@ -206,7 +206,8 @@
<div style="margin-left: 25px"> <div style="margin-left: 25px">
<el-collapse> <el-collapse>
<el-collapse-item title="供应商送货设置" v-if="inputQuery.corpType==2 && inputQuery.mainAction!= 'WareHouseOut'"> <el-collapse-item title="供应商送货设置"
v-if="inputQuery.corpType==2 && inputQuery.mainAction!= 'WareHouseOut'">
<div style="width: 100%;margin-top: 15px"> <div style="width: 100%;margin-top: 15px">
<el-row> <el-row>
@ -1183,6 +1184,11 @@ export default {
// if (this.inputQuery.mainAction != 'WareHouseIn') { // if (this.inputQuery.mainAction != 'WareHouseIn') {
// this.inputQuery.actionType = null // this.inputQuery.actionType = null
// } // }
//
if (this.inputQuery.corpType != 1 || this.inputQuery.mainAction != "WarehouseOut") {
this.inputQuery.genUnit = false;
}
}, },
// //

@ -362,6 +362,7 @@ export default {
this.formName = "update"; this.formName = "update";
this.spellUpdate = true; this.spellUpdate = true;
this.editQuery = row; this.editQuery = row;
this.resetForm();
} else { } else {
this.editQuery = { this.editQuery = {

@ -79,6 +79,7 @@
<el-form-item class="query-form-item" label="货位名称:"> <el-form-item class="query-form-item" label="货位名称:">
<el-select v-model="productQuery.invSpaceCode" placeholder="请选择货位" <el-select v-model="productQuery.invSpaceCode" placeholder="请选择货位"
@change="invSpaceChange" @change="invSpaceChange"
clearable
style="width: 90%" style="width: 90%"
> >
<el-option <el-option
@ -177,12 +178,11 @@ export default {
invList: [], invList: [],
spaceList: [], spaceList: [],
productList: [], productList: [],
combineProductList: [],
formLoading: false, formLoading: false,
productVisible: false, productVisible: false,
loading: false, loading: false,
productQuery: { productQuery: {
invCode: null, invCode: this.$store.getters.locInvCode,
invSpaceCode: null, invSpaceCode: null,
cpmctymc: null, cpmctymc: null,
nameCode: null, nameCode: null,
@ -199,12 +199,12 @@ export default {
this.showSearch = !this.showSearch; this.showSearch = !this.showSearch;
}, },
invChange() { invChange() {
this.combineProductList = []; this.multipleSelection = [];
this.spaceList = []; this.spaceList = [];
this.formData.invSpaceCode = null; this.formData.invSpaceCode = null;
this.formData.relId = null; this.formData.relId = null;
this.formData.ggxh = null; this.formData.ggxh = null;
this.getProductList(); this.getInvProductList();
this.getSpaceList(); this.getSpaceList();
}, },
getInvList() { getInvList() {
@ -224,7 +224,7 @@ export default {
}) })
}, },
invSpaceChange() { invSpaceChange() {
this.combineProductList = []; this.multipleSelection = [];
}, },
formSubmit() { formSubmit() {
let message = this.verifyFormData(); let message = this.verifyFormData();
@ -233,15 +233,24 @@ export default {
return; return;
} }
let relIdList = []; let relIdList = [];
if (this.combineProductList.length > 0) { if (this.multipleSelection.length > 0) {
this.combineProductList.forEach((item) => { this.multipleSelection.forEach((item) => {
relIdList.push(item.relIdFk); relIdList.push(item.relIdFk);
}); });
} else {
this.$message.error("请选择需要预警的产品");
return;
} }
// //
let params = { let params = {
lowStock: this.formData.lowStock,
lackStock: this.formData.lackStock,
overStock: this.formData.overStock,
expireDate: this.formData.expireDate,
recentDate: this.formData.recentDate,
deptCode: this.formData.deptCode, deptCode: this.formData.deptCode,
invCode: this.formData.invCode, invCode: this.formData.invCode,
invSpaceCode: this.formData.invSpaceCode, invSpaceCode: this.formData.invSpaceCode,
@ -280,8 +289,6 @@ export default {
this.productTotal = 0; this.productTotal = 0;
}, },
getInvProductList() { getInvProductList() {
debugger
console.log(this.productQuery.invCode+"---------");
getInvProduct(this.productQuery).then((res) => { getInvProduct(this.productQuery).then((res) => {
if (res.code === 20000) { if (res.code === 20000) {
this.productList = res.data.list || []; this.productList = res.data.list || [];
@ -296,9 +303,6 @@ export default {
this.productTotal = 0; this.productTotal = 0;
}) })
}, },
removeProduct(index) {
this.combineProductList.splice(index, 1);
},
onReset() { onReset() {
this.productQuery = { this.productQuery = {
invCode: this.formData.invCode, invCode: this.formData.invCode,
@ -318,16 +322,6 @@ export default {
handleSelectionChange(val) { handleSelectionChange(val) {
this.multipleSelection = val; this.multipleSelection = val;
}, },
combine() {
if (this.multipleSelection.length === 0) {
this.$message.warning("请选择需要添加预警的产品!");
return;
}
this.productVisible = false;
this.multipleSelection.forEach((item) => {
this.combineProductList.push(item);
});
},
}, },
created() { created() {
this.getInvList(); this.getInvList();

Loading…
Cancel
Save