Browse Source

M100查询增加查询参数,日常打印M100信息向子组件传参优化

master
安虹睿 2 years ago
parent
commit
7a81033bcc
  1. 7
      vue/src/views/pg-fis/basedate/m100Online/budaMB.vue
  2. 7
      vue/src/views/pg-fis/basedate/m100Online/budaZHB.vue
  3. 37
      vue/src/views/pg-fis/basedate/m100Online/normalPritIndex.vue
  4. 68
      vue/src/views/pg-fis/basedate/select/index.vue

7
vue/src/views/pg-fis/basedate/m100Online/budaMB.vue

@ -292,13 +292,12 @@ export default {
//this.tableHeight = offsetHei -260
});
},
created() {
this.getList();
},
// created() {
// this.getList();
// },
watch: {
customerInfosMB: {
handler(newVal) {
console.log("门板-接收的父组件的值:" + JSON.stringify(newVal));
if (newVal == "" || newVal == "undefined") {
//TODO

7
vue/src/views/pg-fis/basedate/m100Online/budaZHB.vue

@ -304,7 +304,7 @@ export default {
newVal.forEach((element) => {
this.customerInfo.printType = 2; //2
this.customerInfo.productLine = element.ProductLine;
this.customerInfo.productGroup = element.productGroup
this.customerInfo.Groupname = element.Groupname
});
if (this.customerInfo.productLine != "") {
this.getList();
@ -472,7 +472,8 @@ export default {
if (this.customerInfo.productLine != "") {
inputParam.productLine = this.customerInfo.productLine;
}
inputParam.Groupname = this.customerInfo.productGroup;
inputParam.Groupname = this.customerInfo.Groupname;
console.log(476,inputParam)
console.log('取柱护板补打列表replenish-print-zhb-list方法输入参数:' + JSON.stringify(this.listQuery));
this.$axios
.gets(
@ -507,7 +508,7 @@ export default {
var params = {
printType: 2,
productLine: this.customerInfo.productLine,
Groupname: this.customerInfo.productGroup,
Groupname: this.customerInfo.Groupname,
beginVin: beginVin1,
endVin: endVin1,
m100IdList: []

37
vue/src/views/pg-fis/basedate/m100Online/normalPritIndex.vue

@ -46,16 +46,16 @@
</el-form-item>
<!-- 柱护板时候显示 -->
<el-form-item
prop="productGroup"
prop="Groupname"
v-show="this.listQuery.productType == 2"
>
<el-select
v-model="listQuery.productGroup"
v-model="listQuery.Groupname"
clearable
placeholder="请选择"
size="medium"
style="margin-right: 10px"
@change="GroupselectChange"
@change="valueselectChange"
>
<el-option
v-for="(item,key) in PLChildGroupList"
@ -571,7 +571,7 @@ export default {
MaxResultCount: 15,
productType: 1, //1:2:
ProductLine: undefined,
productGroup:undefined,//
Groupname:undefined,//
Version: undefined,
printBillNum: undefined,
serialNumBegin: undefined,
@ -1153,7 +1153,7 @@ export default {
this.listQueryList.BillStatus = 2; //
this.listQueryList.ProductLine = this.listQuery.productLine; //线
this.listQueryList.CanNotPrint = false; //
this.listQueryList.GroupNmae = this.listQuery.productGroup
this.listQueryList.GroupNmae = this.listQuery.Groupname
console.log("日常打印M100查询条件:" + JSON.stringify(this.listQueryList));
//this.click();
this.$axios
@ -1196,7 +1196,7 @@ export default {
this.listLoading = false;
});
},
//
valueselectChange(val) {
this.$forceUpdate();
this.customerInfosMB = [];
@ -1206,7 +1206,7 @@ export default {
this.customerInfosMB = [
{
PrintType: 1,
ProductLine: val,
ProductLine: this.listQuery.productLine,
},
];
}
@ -1215,14 +1215,12 @@ export default {
this.customerInfosZHB = [
{
PrintType: 1,
ProductLine: val,
ProductLine: this.listQuery.productLine,
Groupname:this.listQuery.Groupname
},
];
}
},
GroupselectChange(val){
this.customerInfosZHB[0].productGroup = val
},
handleImportSAP() {},
handleFilter() {
@ -1278,7 +1276,7 @@ export default {
}
//
else if(type == 2){
_name = this.productTypeList[1].name + ': ' + _productLineName + ' (' + this.listQuery.productGroup + ')'
_name = this.productTypeList[1].name + ': ' + _productLineName + ' (' + this.listQuery.Groupname + ')'
}
return _name
},
@ -1303,7 +1301,7 @@ export default {
});
return;
}
if(this.listQuery.productType == '2' && (this.listQuery.productGroup === "" || this.listQuery.productGroup === undefined)){
if(this.listQuery.productType == '2' && (this.listQuery.Groupname === "" || this.listQuery.Groupname === undefined)){
this.$message({
message: "请选择生产线",
type: "warning",
@ -1314,8 +1312,8 @@ export default {
(this.printNumZHB = "24"),
(this.hostSNQuery.productLine = this.listQuery.productLine);
this.hostPrintQuery.productLine = this.listQuery.productLine;
this.hostPrintQuery.Groupname = this.listQuery.productGroup;
this.hostSNQuery.Groupname = this.listQuery.productGroup
this.hostPrintQuery.Groupname = this.listQuery.Groupname;
this.hostSNQuery.Groupname = this.listQuery.Groupname
//
if (this.listQuery.productType === 1) {
@ -1433,7 +1431,7 @@ export default {
});
return;
}
if(this.listQuery.productType == '2' && (this.listQuery.productGroup === "" || this.listQuery.productGroup === undefined)){
if(this.listQuery.productType == '2' && (this.listQuery.Groupname === "" || this.listQuery.Groupname === undefined)){
this.$message({
message: "请选择生产线",
type: "warning",
@ -1473,7 +1471,7 @@ export default {
});
return;
}
if(this.listQuery.productType == '2' && (this.listQuery.productGroup === "" || this.listQuery.productGroup === undefined)){
if(this.listQuery.productType == '2' && (this.listQuery.Groupname === "" || this.listQuery.Groupname === undefined)){
this.$message({
message: "请选择生产线",
type: "warning",
@ -1832,14 +1830,15 @@ export default {
//线
ptypeselectChange() {
this.$forceUpdate();
this.listQuery.productLine = "";
this.listQuery.productGroup = undefined
this.PLChildList = this.PLList.filter(
(u) => u.productType === parseInt(this.listQuery.productType)
).sort((a, b) => {
return a.productLineCode - b.productLineCode;
});
this.listQuery.productLine = this.PLChildList[0].productLineCode;
this.listQuery.Groupname = this.listQuery.productType == '1' ? undefined : this.PLChildGroupList[0]
this.changeMainTableHeight()
this.valueselectChange()
//
if (this.listQuery.productType === 1) {
this.$refs.btn1.$el.innerText = "打印门板发货排序单";

68
vue/src/views/pg-fis/basedate/select/index.vue

@ -32,7 +32,7 @@
clearable
placeholder="请选择"
size="medium"
style="margin-right: 15px"
style="margin-right: 10px"
@change="valueselectChange"
>
<el-option
@ -43,6 +43,27 @@
/>
</el-select>
</el-form-item>
<!-- 柱护板时候显示 -->
<el-form-item
prop="Groupname"
v-show="listQuery.productType == 2"
>
<el-select
v-model="listQuery.Groupname"
clearable
placeholder="请选择"
size="medium"
style="margin-right: 10px"
>
<el-option
v-for="(item,key) in PLChildGroupList"
:key="key"
:label="item"
:value="item"
/>
</el-select>
</el-form-item>
<el-form-item label="版本:" prop="Version">
<el-input
v-model="listQuery.Version"
@ -361,7 +382,7 @@
<pagination
v-show="totalCount > 0"
:total="totalCount"
style="margin-bottom: -5px; float: right"
style="float: right"
:page.sync="page"
:limit.sync="listQuery.MaxResultCount"
@pagination="getList"
@ -486,6 +507,7 @@ export default {
MaxResultCount: 15,
productType: 1, //1:2:
ProductLine: undefined,
Groupname:undefined,//
Version: undefined,
printBillNum: undefined,
serialNumBegin: undefined,
@ -562,6 +584,7 @@ export default {
details: [], //
PLList: [], //线
PLChildList: [], //线
PLChildGroupList: [], //线
productTypeList: [
{ id: 1, name: "门板" },
{ id: 2, name: "柱护板" },
@ -572,13 +595,11 @@ export default {
};
},
mounted() {
this.$nextTick(() => {
var offsetHei = document.documentElement.clientHeight;
//console.log(offsetHei);
let boxH = this.$refs.box.offsetHeight;
this.tableHeight = offsetHei - boxH - 57 - 79; //57footer79
//this.tableHeight = offsetHei -260
});
let _this = this
window.addEventListener('resize',function(){
_this.changeMainTableHeight()
})
this.getPLChildGroupList()
},
created() {
this.billState.forEach((element, index) => {
@ -663,6 +684,28 @@ export default {
...mapGetters(["userInfo"]), //
},
methods: {
//
changeMainTableHeight(){
this.$nextTick(()=>{
var offsetHei = document.documentElement.clientHeight;
//console.log(offsetHei);
let boxH = this.$refs.box.offsetHeight;
this.tableHeight = offsetHei - boxH - 37 - 79; //57footer79
//this.tableHeight = offsetHei -260
})
},
// PLChildGroupList
getPLChildGroupList(){
this.$axios
.gets(
"/api/newjit/print-template-configuration/list",
)
.then((response) => {
if (response.item !== null) {
this.PLChildGroupList= response.item;
}
});
},
//
handleDrawerOpen(param) {
this.drawer = true;
@ -861,6 +904,8 @@ export default {
.catch(() => {
this.listLoading = false;
});
this.changeMainTableHeight()
},
getDetialList(partCode) {
@ -1506,21 +1551,24 @@ export default {
ptypeselectChange() {
this.$forceUpdate();
//console.log(this.listQuery.productType);
this.listQuery.productLine = "";
this.PLChildList = this.PLList.filter(
(u) => u.productType === parseInt(this.listQuery.productType)
).sort((a, b) => {
return a.productLineCode - b.productLineCode;
});
this.listQuery.productLine = this.PLChildList[0].productLineCode;
this.changeMainTableHeight()
//console.log(this.PLList)
//
if (this.listQuery.productType === 1) {
this.listQuery.Groupname = undefined
this.$refs.btn1.$el.innerText = "打印门板发货排序单";
this.$refs.btn2.$el.innerText = "重新打印门板发货排序单";
this.$refs.btn3.$el.innerText = "补打门板发货排序单";
this.listQuery.state.push(this.billState[0].id);
this.isShowState = true;
} else if (this.listQuery.productType === 2) {
this.listQuery.Groupname = this.PLChildGroupList[0]
this.$refs.btn1.$el.innerText = "打印柱护板发货排序单";
this.$refs.btn2.$el.innerText = "重新打印柱护板发货排序单";
this.$refs.btn3.$el.innerText = "补打柱护板发货排序单";

Loading…
Cancel
Save