|
@@ -453,8 +453,9 @@ export default {
|
|
|
referOrderDataModVis: false,
|
|
|
error:'', // 选中数据不符合的字段名
|
|
|
errorIdentical:[],//选中多行数据客户、分销点不同字段
|
|
|
- errorFather: '', //选中数据与已有数据不同集合
|
|
|
-
|
|
|
+ // errorFather: '', //选中数据与已有数据不同集合
|
|
|
+ garmentArr:[],//选中数据的成衣工厂集合
|
|
|
+ customerArr:[],//选中数据的客户简称集合
|
|
|
// 查询条件
|
|
|
queryParam: {
|
|
|
// itemNumber: '', // 订单号
|
|
@@ -527,13 +528,17 @@ export default {
|
|
|
} else if(this.selectedRows !== 1 && this.error !==''){
|
|
|
this.$message.error(this.error+'至少一项不相同!');
|
|
|
this.error = ''
|
|
|
+ }else if(this.queryParam.account == '901' && this.garmentArr.includes("")){
|
|
|
+ this.$message.error('含有成衣工厂为空的数据,请重新选择!');
|
|
|
+ }else if(this.queryParam.account == '903' && !(this.customerArr.length==1 && this.customerArr[0] == '香港森语')){
|
|
|
+ this.$message.error('含有客户简称不为香港森语的数据,请重新选择!');
|
|
|
}else{
|
|
|
var garment = ''
|
|
|
if(this.queryParam.flourOrGarment == 1){
|
|
|
garment = '成衣'
|
|
|
}else {
|
|
|
garment = '面料'
|
|
|
- }
|
|
|
+ }
|
|
|
this.loading = true
|
|
|
addShipmentList({itemId:this.confimList,readyFabric:garment}).then(res => {
|
|
|
if (res.success) {
|
|
@@ -553,6 +558,8 @@ export default {
|
|
|
//参照数据选择多条时
|
|
|
dataSet(){
|
|
|
this.confimList = []
|
|
|
+ this.ggarmentArr = []
|
|
|
+ this.customerArr = []
|
|
|
var orderTest = [],
|
|
|
poTest = [],
|
|
|
preDeliveryTest = [],
|
|
@@ -577,7 +584,10 @@ export default {
|
|
|
sizeTest.push(item.size)
|
|
|
custorTest.push(item.customerName)
|
|
|
distributionPointTest.push(item.distributionPoint)
|
|
|
+ this.garmentArr.push(item.garmentFactory)
|
|
|
+ this.customerArr.push(item.customerAbbreviation)
|
|
|
})
|
|
|
+ this.customerArr = [...new Set(this.customerArr)]
|
|
|
if([...new Set(orderTest)].length == 1 && [...new Set(poTest)].length == 1 &&[...new Set(preDeliveryTest)].length == 1&&
|
|
|
[...new Set(preCompletionTest)].length == 1 && [...new Set(itemNumberTest)].length == 1 &&[...new Set(inventoryCodeTest)].length !== 1&&
|
|
|
[...new Set(inventoryNameTest)].length == 1 && [...new Set(colourTest)].length == 1 &&[...new Set(sizeTest)].length == 1){
|
|
@@ -587,6 +597,7 @@ export default {
|
|
|
if([...new Set(distributionPointTest)].length !== 1){this.errorIdentical.push('分销点')}
|
|
|
},
|
|
|
|
|
|
+
|
|
|
//已有参考列表
|
|
|
// fatherDataSet(fathers,sons){
|
|
|
// var father = fathers[0]
|
|
@@ -611,7 +622,7 @@ export default {
|
|
|
this.getOrderList();
|
|
|
},
|
|
|
|
|
|
- searchQuery() {
|
|
|
+ searchQuery() {
|
|
|
this.toggleSearchStatus = false
|
|
|
if(this.queryParam.flourOrGarment === '' || !this.queryParam.hasOwnProperty('flourOrGarment')){
|
|
|
this.$message.error('请选择查询类型!');
|
|
@@ -638,7 +649,9 @@ export default {
|
|
|
this.queryParam.pageNo = ''
|
|
|
this.getOrderList();
|
|
|
}
|
|
|
-
|
|
|
+ this.selectedRowKeys = []
|
|
|
+ this.selectedRows = []
|
|
|
+ this.selectedNumber = 0
|
|
|
}
|
|
|
},
|
|
|
|
|
@@ -651,6 +664,7 @@ export default {
|
|
|
this.orderListData = []
|
|
|
this.selectedRowKeys = [];
|
|
|
this.selectedRows = [];
|
|
|
+ this.selectedNumber = 0
|
|
|
// this.$emit('default-reset')
|
|
|
},
|
|
|
// 选中行
|