Showing
1 changed file
with
36 additions
and
40 deletions
| ... | @@ -71,7 +71,8 @@ | ... | @@ -71,7 +71,8 @@ |
| 71 | <el-button type="primary" v-if="val.status === '3'" size="mini" | 71 | <el-button type="primary" v-if="val.status === '3'" size="mini" |
| 72 | icon="el-icon-video-pause" @click="changeStatus(idx)"> | 72 | icon="el-icon-video-pause" @click="changeStatus(idx)"> |
| 73 | 启 用</el-button> | 73 | 启 用</el-button> |
| 74 | - <el-button v-if="val.id" type="danger" size="mini" icon="el-icon-delete" @click="del(idx)"> | 74 | + <el-button v-if="val.id" type="danger" size="mini" icon="el-icon-delete" |
| 75 | + @click="del(idx)"> | ||
| 75 | 删 除</el-button> | 76 | 删 除</el-button> |
| 76 | <div v-if="(routeSatus.indexOf('flightInformationMaintenance') >= 0)" | 77 | <div v-if="(routeSatus.indexOf('flightInformationMaintenance') >= 0)" |
| 77 | style="display: inline-block;"> | 78 | style="display: inline-block;"> |
| ... | @@ -148,9 +149,7 @@ | ... | @@ -148,9 +149,7 @@ |
| 148 | <el-col :span="10"> | 149 | <el-col :span="10"> |
| 149 | <el-input class="numberInput" v-model.trim="val.minNumOfPieces" | 150 | <el-input class="numberInput" v-model.trim="val.minNumOfPieces" |
| 150 | oninput="value=value.replace(/[^\d\.\-]/g,'')" @change="change" | 151 | oninput="value=value.replace(/[^\d\.\-]/g,'')" @change="change" |
| 151 | - @input="change($event)" | 152 | + @input="change($event)" @blur="inputBlurMinPieces($event)"> |
| 152 | - @blur="inputBlurMinPieces($event)" | ||
| 153 | - > | ||
| 154 | </el-input> | 153 | </el-input> |
| 155 | <span ref="minNumOfPieces" class="el-form-item__error"></span> | 154 | <span ref="minNumOfPieces" class="el-form-item__error"></span> |
| 156 | </el-col> | 155 | </el-col> |
| ... | @@ -158,9 +157,7 @@ | ... | @@ -158,9 +157,7 @@ |
| 158 | <el-col :span="10"> | 157 | <el-col :span="10"> |
| 159 | <el-input class="numberInput" v-model.trim="val.maxNumOfPieces" | 158 | <el-input class="numberInput" v-model.trim="val.maxNumOfPieces" |
| 160 | oninput="value=value.replace(/[^\d\.\-]/g,'')" @change="change" | 159 | oninput="value=value.replace(/[^\d\.\-]/g,'')" @change="change" |
| 161 | - @input="change($event)" | 160 | + @input="change($event)" @blur="inputBlurMaxPieces($event)"> |
| 162 | - @blur="inputBlurMaxPieces($event)" | ||
| 163 | - > | ||
| 164 | </el-input> | 161 | </el-input> |
| 165 | </el-col> | 162 | </el-col> |
| 166 | </el-form-item> | 163 | </el-form-item> |
| ... | @@ -170,9 +167,7 @@ | ... | @@ -170,9 +167,7 @@ |
| 170 | <el-col :span="10"> | 167 | <el-col :span="10"> |
| 171 | <el-input class="numberInput" v-model.trim="val.minWeight" | 168 | <el-input class="numberInput" v-model.trim="val.minWeight" |
| 172 | oninput="value=value.replace(/[^\d\.\-]/g,'')" @change="change" | 169 | oninput="value=value.replace(/[^\d\.\-]/g,'')" @change="change" |
| 173 | - @input="change($event)" | 170 | + @input="change($event)" @blur="inputBlurMinWeight($event)"> |
| 174 | - @blur="inputBlurMinWeight($event)" | ||
| 175 | - > | ||
| 176 | </el-input> | 171 | </el-input> |
| 177 | <span ref="minWeight" class="el-form-item__error"></span> | 172 | <span ref="minWeight" class="el-form-item__error"></span> |
| 178 | </el-col> | 173 | </el-col> |
| ... | @@ -180,9 +175,7 @@ | ... | @@ -180,9 +175,7 @@ |
| 180 | <el-col :span="10"> | 175 | <el-col :span="10"> |
| 181 | <el-input class="numberInput" v-model.trim="val.maxWeight" | 176 | <el-input class="numberInput" v-model.trim="val.maxWeight" |
| 182 | oninput="value=value.replace(/[^\d\.\-]/g,'')" @change="change" | 177 | oninput="value=value.replace(/[^\d\.\-]/g,'')" @change="change" |
| 183 | - @input="change($event)" | 178 | + @input="change($event)" @blur="inputBlurMaxWeight($event)"> |
| 184 | - @blur="inputBlurMaxWeight($event)" | ||
| 185 | - > | ||
| 186 | </el-input> | 179 | </el-input> |
| 187 | </el-col> | 180 | </el-col> |
| 188 | </el-form-item> | 181 | </el-form-item> |
| ... | @@ -324,13 +317,15 @@ | ... | @@ -324,13 +317,15 @@ |
| 324 | <el-button type="primary" v-if="val.status === '3'" size="mini" icon="el-icon-video-pause" | 317 | <el-button type="primary" v-if="val.status === '3'" size="mini" icon="el-icon-video-pause" |
| 325 | @click="changeStatus(idx)"> | 318 | @click="changeStatus(idx)"> |
| 326 | 启 用</el-button> | 319 | 启 用</el-button> |
| 327 | - <el-button v-if="val.id" type="danger" size="mini" icon="el-icon-delete" style="margin-right:10px" @click="del(idx)"> | 320 | + <el-button v-if="val.id" type="danger" size="mini" icon="el-icon-delete" style="margin-right:10px" |
| 321 | + @click="del(idx)"> | ||
| 328 | 删 除</el-button> | 322 | 删 除</el-button> |
| 329 | <div v-if="routeSatus.indexOf('flightInformationMaintenance') >= 0" style="display: inline-block;"> | 323 | <div v-if="routeSatus.indexOf('flightInformationMaintenance') >= 0" style="display: inline-block;"> |
| 330 | <span v-if="val.id">日期级别规则</span><span v-else>普通规则</span> | 324 | <span v-if="val.id">日期级别规则</span><span v-else>普通规则</span> |
| 331 | </div> | 325 | </div> |
| 332 | <div v-else-if="(routeSatus.indexOf('FlightAllocConfig') >= 0)" style="display: inline-block;"> | 326 | <div v-else-if="(routeSatus.indexOf('FlightAllocConfig') >= 0)" style="display: inline-block;"> |
| 333 | - <span v-if="infoForm.fltDate != null && infoForm.fltDate != '' && infoForm.fltDate != ' '">日期级别规则</span><span | 327 | + <span |
| 328 | + v-if="infoForm.fltDate != null && infoForm.fltDate != '' && infoForm.fltDate != ' '">日期级别规则</span><span | ||
| 334 | v-else>普通规则</span> | 329 | v-else>普通规则</span> |
| 335 | </div> | 330 | </div> |
| 336 | <el-divider></el-divider> | 331 | <el-divider></el-divider> |
| ... | @@ -396,9 +391,7 @@ | ... | @@ -396,9 +391,7 @@ |
| 396 | <el-col :span="10"> | 391 | <el-col :span="10"> |
| 397 | <el-input class="numberInput" v-model.trim="val.minNumOfPieces" | 392 | <el-input class="numberInput" v-model.trim="val.minNumOfPieces" |
| 398 | oninput="value=value.replace(/[^\d\.\-]/g,'')" @change="change" | 393 | oninput="value=value.replace(/[^\d\.\-]/g,'')" @change="change" |
| 399 | - @input="change($event)" | 394 | + @input="change($event)" @blur="inputBlurMinPieces($event)"> |
| 400 | - @blur="inputBlurMinPieces($event)" | ||
| 401 | - > | ||
| 402 | </el-input> | 395 | </el-input> |
| 403 | <span ref="minNumOfPieces" class="el-form-item__error"></span> | 396 | <span ref="minNumOfPieces" class="el-form-item__error"></span> |
| 404 | </el-col> | 397 | </el-col> |
| ... | @@ -406,9 +399,7 @@ | ... | @@ -406,9 +399,7 @@ |
| 406 | <el-col :span="10"> | 399 | <el-col :span="10"> |
| 407 | <el-input class="numberInput" v-model.trim="val.maxNumOfPieces" | 400 | <el-input class="numberInput" v-model.trim="val.maxNumOfPieces" |
| 408 | oninput="value=value.replace(/[^\d\.\-]/g,'')" @change="change" | 401 | oninput="value=value.replace(/[^\d\.\-]/g,'')" @change="change" |
| 409 | - @input="change($event)" | 402 | + @input="change($event)" @blur="inputBlurMaxPieces($event)"> |
| 410 | - @blur="inputBlurMaxPieces($event)" | ||
| 411 | - > | ||
| 412 | </el-input> | 403 | </el-input> |
| 413 | </el-col> | 404 | </el-col> |
| 414 | </el-form-item> | 405 | </el-form-item> |
| ... | @@ -418,9 +409,7 @@ | ... | @@ -418,9 +409,7 @@ |
| 418 | <el-col :span="10"> | 409 | <el-col :span="10"> |
| 419 | <el-input class="numberInput" v-model.trim="val.minWeight" | 410 | <el-input class="numberInput" v-model.trim="val.minWeight" |
| 420 | oninput="value=value.replace(/[^\d\.\-]/g,'')" @change="change" | 411 | oninput="value=value.replace(/[^\d\.\-]/g,'')" @change="change" |
| 421 | - @input="change($event)" | 412 | + @input="change($event)" @blur="inputBlurMinWeight($event)"> |
| 422 | - @blur="inputBlurMinWeight($event)" | ||
| 423 | - > | ||
| 424 | </el-input> | 413 | </el-input> |
| 425 | <span ref="minWeight" class="el-form-item__error"></span> | 414 | <span ref="minWeight" class="el-form-item__error"></span> |
| 426 | </el-col> | 415 | </el-col> |
| ... | @@ -428,9 +417,7 @@ | ... | @@ -428,9 +417,7 @@ |
| 428 | <el-col :span="10"> | 417 | <el-col :span="10"> |
| 429 | <el-input class="numberInput" v-model.trim="val.maxWeight" | 418 | <el-input class="numberInput" v-model.trim="val.maxWeight" |
| 430 | oninput="value=value.replace(/[^\d\.\-]/g,'')" @change="change" | 419 | oninput="value=value.replace(/[^\d\.\-]/g,'')" @change="change" |
| 431 | - @input="change($event)" | 420 | + @input="change($event)" @blur="inputBlurMaxWeight($event)"> |
| 432 | - @blur="inputBlurMaxWeight($event)" | ||
| 433 | - > | ||
| 434 | </el-input> | 421 | </el-input> |
| 435 | </el-col> | 422 | </el-col> |
| 436 | </el-form-item> | 423 | </el-form-item> |
| ... | @@ -739,7 +726,7 @@ export default { | ... | @@ -739,7 +726,7 @@ export default { |
| 739 | flightRouteListStr: val.flightRouteListStr, | 726 | flightRouteListStr: val.flightRouteListStr, |
| 740 | status: val.status ? val.status : '' | 727 | status: val.status ? val.status : '' |
| 741 | } | 728 | } |
| 742 | - if(this.$route.params.handle == "updated"){ | 729 | + if (this.$route.params.handle == "updated") { |
| 743 | delete obj.flightRoute | 730 | delete obj.flightRoute |
| 744 | } | 731 | } |
| 745 | // 修改时 & 详情时 | 732 | // 修改时 & 详情时 |
| ... | @@ -784,6 +771,11 @@ export default { | ... | @@ -784,6 +771,11 @@ export default { |
| 784 | } else { | 771 | } else { |
| 785 | // | 772 | // |
| 786 | if (this.routeSatus == 'FlightAllocConfig') { | 773 | if (this.routeSatus == 'FlightAllocConfig') { |
| 774 | + res.data.list.forEach(dateItem => { | ||
| 775 | + this.infoForm.list.push( | ||
| 776 | + this.dataHandle(dateItem) | ||
| 777 | + ) | ||
| 778 | + }) | ||
| 787 | findDestinationFltRuleByFlightNo({ | 779 | findDestinationFltRuleByFlightNo({ |
| 788 | purposeOfFlightNo: this.infoForm.fltNo, | 780 | purposeOfFlightNo: this.infoForm.fltNo, |
| 789 | fltDate: '', | 781 | fltDate: '', |
| ... | @@ -795,23 +787,27 @@ export default { | ... | @@ -795,23 +787,27 @@ export default { |
| 795 | this.routeList.forEach((route) => { | 787 | this.routeList.forEach((route) => { |
| 796 | let routeStatus = 1 | 788 | let routeStatus = 1 |
| 797 | resData.data.list.forEach(item => { | 789 | resData.data.list.forEach(item => { |
| 790 | + if (res.data.list[0].flightRoute != item.flightRoute) { | ||
| 798 | if (item.flightRoute == route.route) { | 791 | if (item.flightRoute == route.route) { |
| 792 | + item.id = undefined | ||
| 793 | + item.status = undefined | ||
| 799 | routeStatus = 2 | 794 | routeStatus = 2 |
| 800 | this.infoForm.list.push( | 795 | this.infoForm.list.push( |
| 801 | this.dataHandle(item) | 796 | this.dataHandle(item) |
| 802 | ) | 797 | ) |
| 803 | console.log(route.route) | 798 | console.log(route.route) |
| 799 | + } else { | ||
| 800 | + // this.infoForm.list.push({ | ||
| 801 | + // purposeOfFlightNo: this.infoForm.fltNo, | ||
| 802 | + // ruleDate: this.infoForm.fltDate, | ||
| 803 | + // flightRoute: route.route, | ||
| 804 | + // routePriority: route.routePriority, | ||
| 805 | + // }) | ||
| 804 | } | 806 | } |
| 805 | - }) | ||
| 806 | - if (routeStatus == 1) { | ||
| 807 | - this.infoForm.list.push({ | ||
| 808 | - purposeOfFlightNo: this.infoForm.fltNo, | ||
| 809 | - ruleDate: this.infoForm.fltDate, | ||
| 810 | - flightRoute: route.route, | ||
| 811 | - routePriority: route.routePriority, | ||
| 812 | - }) | ||
| 813 | } | 807 | } |
| 814 | }) | 808 | }) |
| 809 | + | ||
| 810 | + }) | ||
| 815 | } | 811 | } |
| 816 | else { | 812 | else { |
| 817 | this.routeList.forEach((route) => { | 813 | this.routeList.forEach((route) => { |
| ... | @@ -827,7 +823,7 @@ export default { | ... | @@ -827,7 +823,7 @@ export default { |
| 827 | this.isEmpty = true | 823 | this.isEmpty = true |
| 828 | console.log(err) | 824 | console.log(err) |
| 829 | }) | 825 | }) |
| 830 | - }else{ | 826 | + } else { |
| 831 | // 航线为空,对应航班或航班+日期下的全部维度(需补全未创建维度) | 827 | // 航线为空,对应航班或航班+日期下的全部维度(需补全未创建维度) |
| 832 | this.routeList.forEach((route, sub) => { | 828 | this.routeList.forEach((route, sub) => { |
| 833 | let routeStatus = 1 | 829 | let routeStatus = 1 |
| ... | @@ -863,7 +859,7 @@ export default { | ... | @@ -863,7 +859,7 @@ export default { |
| 863 | flightRouteListStr: this.$route.params.route, | 859 | flightRouteListStr: this.$route.params.route, |
| 864 | status: this.$route.params.status | 860 | status: this.$route.params.status |
| 865 | } | 861 | } |
| 866 | - if(this.$route.params.handle == "updated"){ | 862 | + if (this.$route.params.handle == "updated") { |
| 867 | delete params.flightRoute | 863 | delete params.flightRoute |
| 868 | } | 864 | } |
| 869 | //航线不为空,获取该航线下无日期通用维度设置 | 865 | //航线不为空,获取该航线下无日期通用维度设置 |
| ... | @@ -999,10 +995,10 @@ export default { | ... | @@ -999,10 +995,10 @@ export default { |
| 999 | //航班类型Purple Tail展示全部航线维度 | 995 | //航班类型Purple Tail展示全部航线维度 |
| 1000 | findDestinationFltRuleByFlightNo(query).then(result => { | 996 | findDestinationFltRuleByFlightNo(query).then(result => { |
| 1001 | const { code, data } = result; | 997 | const { code, data } = result; |
| 1002 | - if(code == 200){ | 998 | + if (code == 200) { |
| 1003 | this.routeList = data.routeList; | 999 | this.routeList = data.routeList; |
| 1004 | let routesStatus = 1 | 1000 | let routesStatus = 1 |
| 1005 | - if(data.routeList.length){ | 1001 | + if (data.routeList.length) { |
| 1006 | this.routeList.forEach(route => { | 1002 | this.routeList.forEach(route => { |
| 1007 | data.list.forEach(item => { | 1003 | data.list.forEach(item => { |
| 1008 | if (route.route === item.flightRoute) { | 1004 | if (route.route === item.flightRoute) { | ... | ... |
-
Please register or login to post a comment