|
@@ -422,6 +422,7 @@ export default {
|
|
|
orderListData: [], //订单数据
|
|
|
confirmLoading: false,
|
|
|
referOrderDataModVis: false,
|
|
|
+ error:[], // 选中数据不符合的字段名
|
|
|
|
|
|
// 查询条件
|
|
|
queryParam: {
|
|
@@ -477,14 +478,13 @@ export default {
|
|
|
|
|
|
// 弹框确定
|
|
|
onSubmit() {
|
|
|
- this.confimList = [];
|
|
|
+ this.dataSet( this.selectedRows)
|
|
|
if (this.selectedRowKeys.length == 0) {
|
|
|
this.$message.error('请勾选订单数据')
|
|
|
- } else {
|
|
|
- this.selectedRows.forEach(item => {
|
|
|
- this.confimList.push(item.syOrderDataItemId);
|
|
|
- })
|
|
|
-
|
|
|
+ } else if(this.error.length !== 0){
|
|
|
+ var cc =this.error.toString()
|
|
|
+ this.$message.error(cc+'必须相同!');
|
|
|
+ }else {
|
|
|
confimOrderData(this.confimList).then(res => {
|
|
|
if (res.success) {
|
|
|
this.propList = res.result;
|
|
@@ -498,6 +498,40 @@ export default {
|
|
|
this.searchReset();
|
|
|
}
|
|
|
},
|
|
|
+ dataSet(){
|
|
|
+ this.confimList = [];
|
|
|
+ var orderTest = [],
|
|
|
+ poTest = [],
|
|
|
+ preDeliveryTest = [],
|
|
|
+ preCompletionTest = [],
|
|
|
+ itemNumberTest = [],
|
|
|
+ inventoryCodeTest = [],
|
|
|
+ inventoryNameTest = [],
|
|
|
+ colourTest = [],
|
|
|
+ sizeTest = []
|
|
|
+ this.selectedRows.map(item=>{
|
|
|
+ this.confimList.push(item.syOrderDataItemId);
|
|
|
+ orderTest.push(item.orderNumber)
|
|
|
+ poTest.push(item.smallPo)
|
|
|
+ preDeliveryTest.push(item.preDeliveryDate)
|
|
|
+ preCompletionTest.push(item.preCompletionDate)
|
|
|
+ itemNumberTest.push(item.itemNumber)
|
|
|
+ inventoryCodeTest.push(item.inventoryCode)
|
|
|
+ inventoryNameTest.push(item.inventoryName)
|
|
|
+ colourTest.push(item.colour)
|
|
|
+ sizeTest.push(item.size)
|
|
|
+ })
|
|
|
+ if([...new Set(orderTest)].length !== 1){this.error.push('订单号')}
|
|
|
+ if([...new Set(poTest)].length !== 1){this.error.push('小po')}
|
|
|
+ if([...new Set(preDeliveryTest)].length !== 1){this.error.push('预发货日期')}
|
|
|
+ if([...new Set(preCompletionTest)].length !== 1){this.error.push('预完工日期')}
|
|
|
+ if([...new Set(itemNumberTest)].length !== 1){this.error.push('款号')}
|
|
|
+ if([...new Set(inventoryCodeTest)].length !== 1){this.error.push('存货编码')}
|
|
|
+ if([...new Set(inventoryNameTest)].length !== 1){this.error.push('存货名称')}
|
|
|
+ if([...new Set(colourTest)].length !== 1){this.error.push('颜色')}
|
|
|
+ if([...new Set(sizeTest)].length !== 1){this.error.push('尺码')}
|
|
|
+ },
|
|
|
+
|
|
|
handleTableChange(pagination, filters, sorter) {
|
|
|
this.queryParam.pageNo = pagination.current;
|
|
|
this.getOrderList();
|