Showing
2 changed files
with
71 additions
and
7 deletions
| ... | @@ -8,3 +8,13 @@ export function findSourceFlightRulesApi(data) { | ... | @@ -8,3 +8,13 @@ export function findSourceFlightRulesApi(data) { |
| 8 | data: data | 8 | data: data |
| 9 | }) | 9 | }) |
| 10 | } | 10 | } |
| 11 | +// 目标航班查询 | ||
| 12 | +export function findSourceFlightAndFlightDateApi(data) { | ||
| 13 | + return request({ | ||
| 14 | + url: '/sourceFlight/findSourceFlightAndFlightDate', | ||
| 15 | + method: 'post', | ||
| 16 | + data: data | ||
| 17 | + }) | ||
| 18 | +} | ||
| 19 | + | ||
| 20 | + | ... | ... |
| ... | @@ -22,7 +22,7 @@ | ... | @@ -22,7 +22,7 @@ |
| 22 | </el-form-item> | 22 | </el-form-item> |
| 23 | 23 | ||
| 24 | <el-form-item> | 24 | <el-form-item> |
| 25 | - <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">查询实际目的航班</el-button>  | 25 | + <el-button type="primary" icon="el-icon-search" size="mini" @click="findSourceFlightAndFlightDate">查询实际目的航班</el-button>  |
| 26 | <span style="color: red;">注:原航班+日期查询该日期的航班实际情况</span> | 26 | <span style="color: red;">注:原航班+日期查询该日期的航班实际情况</span> |
| 27 | </el-form-item> | 27 | </el-form-item> |
| 28 | <br /> | 28 | <br /> |
| ... | @@ -35,18 +35,18 @@ | ... | @@ -35,18 +35,18 @@ |
| 35 | </el-form> | 35 | </el-form> |
| 36 | 36 | ||
| 37 | 37 | ||
| 38 | - <el-table v-loading="loading" :data="sourceFlightRulesList"> | 38 | + <el-table v-loading="loading" :data="sourceFlightRulesList" > |
| 39 | 39 | ||
| 40 | <el-table-column label="原航班" align="center" prop="sourceFlightNo"/> | 40 | <el-table-column label="原航班" align="center" prop="sourceFlightNo"/> |
| 41 | <el-table-column label="目的航班排序" align="center" prop="flightRank" width="280"/> | 41 | <el-table-column label="目的航班排序" align="center" prop="flightRank" width="280"/> |
| 42 | - <el-table-column label="优先级" align="center" prop="priority" /> | 42 | + <!-- <el-table-column label="优先级" align="center" prop="priority" /> --> |
| 43 | <el-table-column label="周期" align="center" prop="dayOfWeek" width="180"/> | 43 | <el-table-column label="周期" align="center" prop="dayOfWeek" width="180"/> |
| 44 | <el-table-column label="状态" align="center" prop="status" :formatter="statusFormat" /> | 44 | <el-table-column label="状态" align="center" prop="status" :formatter="statusFormat" /> |
| 45 | <el-table-column label="开始时间" align="center" prop="startDate" width="100"/> | 45 | <el-table-column label="开始时间" align="center" prop="startDate" width="100"/> |
| 46 | <el-table-column label="结束时间" align="center" prop="endDate" width="100"/> | 46 | <el-table-column label="结束时间" align="center" prop="endDate" width="100"/> |
| 47 | <el-table-column label="最后修改人" align="center" prop="updateUserName" width="100"/> | 47 | <el-table-column label="最后修改人" align="center" prop="updateUserName" width="100"/> |
| 48 | <el-table-column label="最后修改时间" align="center" prop="updateTime" width="100"/> | 48 | <el-table-column label="最后修改时间" align="center" prop="updateTime" width="100"/> |
| 49 | - <el-table-column label="操作" align="center" class-name="small-padding fixed-width"width="200"> | 49 | + <el-table-column label="操作" align="center" class-name="small-padding fixed-width"width="280" fixed="right"> |
| 50 | <template slot-scope="scope"> | 50 | <template slot-scope="scope"> |
| 51 | <el-button size="mini" type="text" icon="el-icon-edit" >修改</el-button> | 51 | <el-button size="mini" type="text" icon="el-icon-edit" >修改</el-button> |
| 52 | <el-button size="mini" type="text" icon="el-icon-delete" >删除</el-button> | 52 | <el-button size="mini" type="text" icon="el-icon-delete" >删除</el-button> |
| ... | @@ -55,14 +55,33 @@ | ... | @@ -55,14 +55,33 @@ |
| 55 | </template> | 55 | </template> |
| 56 | </el-table-column> | 56 | </el-table-column> |
| 57 | </el-table> | 57 | </el-table> |
| 58 | + | ||
| 58 | <pagination v-show="total>0" :total="total" layout=" prev, pager, next, jumper, sizes,total" | 59 | <pagination v-show="total>0" :total="total" layout=" prev, pager, next, jumper, sizes,total" |
| 59 | :page.sync="queryParams.pageNum" :limit.sync="queryParams.limit" @pagination="findSourceFlightRules" /> | 60 | :page.sync="queryParams.pageNum" :limit.sync="queryParams.limit" @pagination="findSourceFlightRules" /> |
| 60 | 61 | ||
| 62 | + | ||
| 63 | + <!-- 查看目的航班对话框 --> | ||
| 64 | + <el-dialog title="实际目的航班" :visible.sync="openFlightDate" width="70%"> | ||
| 65 | + <el-table v-loading="loadingFlightDate" :data="sourceFlightAndFlightDate"> | ||
| 66 | + | ||
| 67 | + <el-table-column label="原航班" align="center" prop="sourceFlightNo"/> | ||
| 68 | + <el-table-column label="实际目的航班" align="center" prop="actualFlight" width="280"/> | ||
| 69 | + <el-table-column label="航班日期" align="center" prop="flightDate" /> | ||
| 70 | + <el-table-column label="操作" align="center" class-name="small-padding fixed-width"width="200"> | ||
| 71 | + <template slot-scope="scope"> | ||
| 72 | + <el-button size="mini" type="text" icon="el-icon-edit" >查看配置维度</el-button> | ||
| 73 | + </template> | ||
| 74 | + </el-table-column> | ||
| 75 | + </el-table> | ||
| 76 | + <div slot="footer" class="dialog-footer"> | ||
| 77 | + <el-button @click="cancelFlightDate">返 回</el-button> | ||
| 78 | + </div> | ||
| 79 | + </el-dialog> | ||
| 61 | </div> | 80 | </div> |
| 62 | </template> | 81 | </template> |
| 63 | <script> | 82 | <script> |
| 64 | import { | 83 | import { |
| 65 | - findSourceFlightRulesApi | 84 | + findSourceFlightRulesApi,findSourceFlightAndFlightDateApi |
| 66 | } from "@/api/sourceFlightRules"; | 85 | } from "@/api/sourceFlightRules"; |
| 67 | export default { | 86 | export default { |
| 68 | name: "SourceFlightRules", | 87 | name: "SourceFlightRules", |
| ... | @@ -70,13 +89,19 @@ | ... | @@ -70,13 +89,19 @@ |
| 70 | return { | 89 | return { |
| 71 | // 遮罩层 | 90 | // 遮罩层 |
| 72 | loading: false, | 91 | loading: false, |
| 92 | + // 遮罩层 | ||
| 93 | + loadingFlightDate: false, | ||
| 73 | // 总条数 | 94 | // 总条数 |
| 74 | total: 0, | 95 | total: 0, |
| 75 | // 原航班规则数据 | 96 | // 原航班规则数据 |
| 76 | sourceFlightRulesList: [], | 97 | sourceFlightRulesList: [], |
| 98 | + //目的航班数据 | ||
| 99 | + sourceFlightAndFlightDate:[], | ||
| 77 | statusList: [{'id':1,'name':'有效'}, {'id':2,'name':'配置中'},{'id':3,'name':'停用'}], | 100 | statusList: [{'id':1,'name':'有效'}, {'id':2,'name':'配置中'},{'id':3,'name':'停用'}], |
| 78 | - // 是否显示弹出层 | 101 | + // 新增修改查看规则弹出层 |
| 79 | open: false, | 102 | open: false, |
| 103 | + // 是否显示查看目的航班弹出层 | ||
| 104 | + openFlightDate: false, | ||
| 80 | // 查询参数 | 105 | // 查询参数 |
| 81 | queryParams: { | 106 | queryParams: { |
| 82 | start: 0, //当前条数【代表第几条数据 +1开始】 | 107 | start: 0, //当前条数【代表第几条数据 +1开始】 |
| ... | @@ -105,13 +130,38 @@ | ... | @@ -105,13 +130,38 @@ |
| 105 | this.queryParams.start=0; | 130 | this.queryParams.start=0; |
| 106 | } | 131 | } |
| 107 | findSourceFlightRulesApi(this.queryParams).then(response => { | 132 | findSourceFlightRulesApi(this.queryParams).then(response => { |
| 108 | - | ||
| 109 | this.sourceFlightRulesList = response.data.list; | 133 | this.sourceFlightRulesList = response.data.list; |
| 110 | this.total = response.data.totalCount; | 134 | this.total = response.data.totalCount; |
| 111 | this.loading = false; | 135 | this.loading = false; |
| 112 | }); | 136 | }); |
| 113 | 137 | ||
| 114 | }, | 138 | }, |
| 139 | + /** 查询目的航班*/ | ||
| 140 | + findSourceFlightAndFlightDate(){ | ||
| 141 | + //校验原航班号非空 | ||
| 142 | + if(this.queryParams.sourceFlightNo===null||this.queryParams.sourceFlightNo===undefined||this.queryParams.sourceFlightNo.trim()===''){ | ||
| 143 | + this.$message.warning("原航班号为空"); | ||
| 144 | + return | ||
| 145 | + } | ||
| 146 | + //校验原日期非空 | ||
| 147 | + if(this.queryParams.flightDate===null||this.queryParams.flightDate===undefined){ | ||
| 148 | + this.$message.warning("日期为空"); | ||
| 149 | + return | ||
| 150 | + } | ||
| 151 | + this.openFlightDate = true; | ||
| 152 | + this.loadingFlightDate=true; | ||
| 153 | + this.sourceFlightAndFlightDate=[]; | ||
| 154 | + findSourceFlightAndFlightDateApi(this.queryParams).then(response => { | ||
| 155 | + this.sourceFlightAndFlightDate = response.data; | ||
| 156 | + this.loadingFlightDate=false; | ||
| 157 | + }); | ||
| 158 | + | ||
| 159 | + | ||
| 160 | + }, | ||
| 161 | + // 目的航班弹出框返回 | ||
| 162 | + cancelFlightDate() { | ||
| 163 | + this.openFlightDate = false; | ||
| 164 | + }, | ||
| 115 | // 状态字典翻译 | 165 | // 状态字典翻译 |
| 116 | statusFormat(row) { | 166 | statusFormat(row) { |
| 117 | if(row.status==='1'){ | 167 | if(row.status==='1'){ |
| ... | @@ -138,3 +188,7 @@ | ... | @@ -138,3 +188,7 @@ |
| 138 | } | 188 | } |
| 139 | }; | 189 | }; |
| 140 | </script> | 190 | </script> |
| 191 | +<style> | ||
| 192 | + | ||
| 193 | + | ||
| 194 | +</style> | ... | ... |
-
Please register or login to post a comment