Showing
5 changed files
with
45 additions
and
4 deletions
| ... | @@ -147,6 +147,7 @@ export default { | ... | @@ -147,6 +147,7 @@ export default { |
| 147 | }, | 147 | }, |
| 148 | closeSelectedTag(view) { | 148 | closeSelectedTag(view) { |
| 149 | this.$store.dispatch('tagsView/delView', view).then(({ visitedViews }) => { | 149 | this.$store.dispatch('tagsView/delView', view).then(({ visitedViews }) => { |
| 150 | + console.log(view) | ||
| 150 | if (this.isActive(view)) { | 151 | if (this.isActive(view)) { |
| 151 | this.toLastView(visitedViews, view) | 152 | this.toLastView(visitedViews, view) |
| 152 | } | 153 | } | ... | ... |
| ... | @@ -498,11 +498,10 @@ export default { | ... | @@ -498,11 +498,10 @@ export default { |
| 498 | */ | 498 | */ |
| 499 | if (item.status == "3" || (item.status == "1" && item.ruleDate)) { | 499 | if (item.status == "3" || (item.status == "1" && item.ruleDate)) { |
| 500 | return true; | 500 | return true; |
| 501 | - } else if (item.status == "1" && item.remark) { | 501 | + } else if (item.status == "1" && this.$route.query.querySpecifyData) { |
| 502 | // 航班配舱设置非日期级别情况下 | 502 | // 航班配舱设置非日期级别情况下 |
| 503 | return true; | 503 | return true; |
| 504 | } else if (item.status == "2") { | 504 | } else if (item.status == "2") { |
| 505 | - // 航班配舱设置非日期级别情况下 | ||
| 506 | return true; | 505 | return true; |
| 507 | } else { | 506 | } else { |
| 508 | return false; | 507 | return false; | ... | ... |
This diff is collapsed. Click to expand it.
| ... | @@ -506,7 +506,7 @@ export default { | ... | @@ -506,7 +506,7 @@ export default { |
| 506 | const { code, msg } = res; | 506 | const { code, msg } = res; |
| 507 | if (code == 200) { | 507 | if (code == 200) { |
| 508 | this.msgSuccess(msg || "创建成功!"); | 508 | this.msgSuccess(msg || "创建成功!"); |
| 509 | - this.$router.push("/et86RuleConfig"); | 509 | + this.closeTagMenu(this.$route) |
| 510 | } else { | 510 | } else { |
| 511 | this.msgError(msg || "创建失败!"); | 511 | this.msgError(msg || "创建失败!"); |
| 512 | } | 512 | } |
| ... | @@ -556,6 +556,16 @@ export default { | ... | @@ -556,6 +556,16 @@ export default { |
| 556 | } else { | 556 | } else { |
| 557 | this.checkboxClassType = []; | 557 | this.checkboxClassType = []; |
| 558 | } | 558 | } |
| 559 | + // 人民币 | ||
| 560 | + if (data.list.fltRuleDto.currencyCd == "CNY") { | ||
| 561 | + this.minCNYCustomVal = data.list.fltRuleDto.minCustomVal; | ||
| 562 | + this.maxCNYCustomVal = data.list.fltRuleDto.maxCustomVal; | ||
| 563 | + } | ||
| 564 | + // 美元 | ||
| 565 | + if (data.list.fltRuleDto.currencyCd == "USD") { | ||
| 566 | + this.minSUDCustomVal = data.list.fltRuleDto.minCustomVal; | ||
| 567 | + this.maxSUDCustomVal = data.list.fltRuleDto.maxCustomVal; | ||
| 568 | + } | ||
| 559 | this.queryForm = data.list.fltRuleDto; // ET86配舱航班顺位维度 | 569 | this.queryForm = data.list.fltRuleDto; // ET86配舱航班顺位维度 |
| 560 | } else { | 570 | } else { |
| 561 | this.msgError(msg || "获取查看失败"); | 571 | this.msgError(msg || "获取查看失败"); |
| ... | @@ -570,7 +580,7 @@ export default { | ... | @@ -570,7 +580,7 @@ export default { |
| 570 | const { code, msg } = res; | 580 | const { code, msg } = res; |
| 571 | if (code == 200) { | 581 | if (code == 200) { |
| 572 | this.msgSuccess(msg || "修改成功!"); | 582 | this.msgSuccess(msg || "修改成功!"); |
| 573 | - this.$router.push("/et86RuleConfig"); | 583 | + this.closeTagMenu(this.$route) |
| 574 | } else { | 584 | } else { |
| 575 | this.msgError(msg || "修改失败!"); | 585 | this.msgError(msg || "修改失败!"); |
| 576 | } | 586 | } |
| ... | @@ -785,6 +795,34 @@ export default { | ... | @@ -785,6 +795,34 @@ export default { |
| 785 | }); | 795 | }); |
| 786 | this.$emit("handleSearch"); | 796 | this.$emit("handleSearch"); |
| 787 | }, | 797 | }, |
| 798 | + isActive(route) { | ||
| 799 | + return route.path === this.$route.path; | ||
| 800 | + }, | ||
| 801 | + toLastView(visitedViews, view) { | ||
| 802 | + const latestView = visitedViews.slice(-1)[0]; | ||
| 803 | + if (latestView) { | ||
| 804 | + this.$router.push(latestView.fullPath); | ||
| 805 | + } else { | ||
| 806 | + // now the default is to redirect to the home page if there is no tags-view, | ||
| 807 | + // you can adjust it according to your needs. | ||
| 808 | + if (view.name === "Dashboard") { | ||
| 809 | + // to reload home page | ||
| 810 | + this.$router.replace({ path: "/redirect" + view.fullPath }); | ||
| 811 | + } else { | ||
| 812 | + this.$router.push("/"); | ||
| 813 | + } | ||
| 814 | + } | ||
| 815 | + }, | ||
| 816 | + // 关闭当前标签菜单 | ||
| 817 | + closeTagMenu(view) { | ||
| 818 | + this.$store | ||
| 819 | + .dispatch("tagsView/delView", view) | ||
| 820 | + .then(({ visitedViews }) => { | ||
| 821 | + if (this.isActive(view)) { | ||
| 822 | + this.toLastView(visitedViews, view); | ||
| 823 | + } | ||
| 824 | + }); | ||
| 825 | + }, | ||
| 788 | }, | 826 | }, |
| 789 | }; | 827 | }; |
| 790 | </script> | 828 | </script> | ... | ... |
-
Please register or login to post a comment