Showing
2 changed files
with
481 additions
and
1 deletions
| ... | @@ -187,6 +187,9 @@ | ... | @@ -187,6 +187,9 @@ |
| 187 | 'id': 1, | 187 | 'id': 1, |
| 188 | 'name': '有效' | 188 | 'name': '有效' |
| 189 | },{ | 189 | },{ |
| 190 | + 'id': 2, | ||
| 191 | + 'name': '执行中' | ||
| 192 | + },{ | ||
| 190 | 'id': 3, | 193 | 'id': 3, |
| 191 | 'name': '停用' | 194 | 'name': '停用' |
| 192 | }], | 195 | }], |
| ... | @@ -379,7 +382,7 @@ | ... | @@ -379,7 +382,7 @@ |
| 379 | if (row.status === '1') { | 382 | if (row.status === '1') { |
| 380 | return '有效' | 383 | return '有效' |
| 381 | } else if (row.status === '2') { | 384 | } else if (row.status === '2') { |
| 382 | - return '配置中' | 385 | + return '执行中' |
| 383 | } else if (row.status === '3') { | 386 | } else if (row.status === '3') { |
| 384 | return '停用' | 387 | return '停用' |
| 385 | } | 388 | } | ... | ... |
src/views/systemConfig/userConfig/index.vue
0 → 100644
| 1 | +<template> | ||
| 2 | + <div class="app-container"> | ||
| 3 | + <el-form :model="queryParams" ref="queryForm" :inline="true" label-width="90px"> | ||
| 4 | + <el-row> | ||
| 5 | + <el-col :span="8"> | ||
| 6 | + | ||
| 7 | + <el-form-item label="航班日期从" prop="flightDate"> | ||
| 8 | + <el-date-picker value-format="yyyy-MM-dd" v-model="queryParams.flightDate" type="date" placeholder="选择日期"> | ||
| 9 | + </el-date-picker> | ||
| 10 | + </el-form-item> | ||
| 11 | + </el-col> | ||
| 12 | + | ||
| 13 | + <el-col :span="8"> | ||
| 14 | + <el-form-item label="到" prop="flightDate"> | ||
| 15 | + <el-date-picker value-format="yyyy-MM-dd" v-model="queryParams.flightDate" type="date" placeholder="选择日期"> | ||
| 16 | + </el-date-picker> | ||
| 17 | + </el-form-item> | ||
| 18 | + </el-col> | ||
| 19 | + | ||
| 20 | + <el-col :span="8"> | ||
| 21 | + <el-form-item label="航班号" prop="sourceFlightNo"> | ||
| 22 | + <el-input v-model="queryParams.sourceFlightNo" placeholder="请输入航班号" clearable size="small" /> | ||
| 23 | + </el-form-item> | ||
| 24 | + </el-col> | ||
| 25 | + | ||
| 26 | + </el-row> | ||
| 27 | + <el-row> | ||
| 28 | + <el-col :span="8"> | ||
| 29 | + <el-form-item label="航班类型" prop="status"> | ||
| 30 | + <el-select v-model="queryParams.status" placeholder="请选择" clearable size="small"> | ||
| 31 | + <el-option v-for="dict in statusList" :key="dict.id" :label="dict.name" :value="dict.id" /> | ||
| 32 | + </el-select> | ||
| 33 | + </el-form-item> | ||
| 34 | + </el-col> | ||
| 35 | + | ||
| 36 | + <el-col :span="8"> | ||
| 37 | + <el-form-item label="航班状态" prop="status"> | ||
| 38 | + <el-select v-model="queryParams.status" placeholder="请选择" clearable size="small"> | ||
| 39 | + <el-option v-for="dict in statusList" :key="dict.id" :label="dict.name" :value="dict.id" /> | ||
| 40 | + </el-select> | ||
| 41 | + </el-form-item> | ||
| 42 | + </el-col> | ||
| 43 | + | ||
| 44 | + <el-col :span="8"> | ||
| 45 | + <el-form-item label="航班种类" prop="status"> | ||
| 46 | + <el-select v-model="queryParams.status" placeholder="请选择" clearable size="small"> | ||
| 47 | + <el-option v-for="dict in statusList" :key="dict.id" :label="dict.name" :value="dict.id" /> | ||
| 48 | + </el-select> | ||
| 49 | + </el-form-item> | ||
| 50 | + </el-col> | ||
| 51 | + | ||
| 52 | + </el-row> | ||
| 53 | + | ||
| 54 | + <br /> | ||
| 55 | + <el-form-item> | ||
| 56 | + <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button> | ||
| 57 | + <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button> | ||
| 58 | + </el-form-item> | ||
| 59 | + </el-form> | ||
| 60 | + <el-row :gutter="10" class="mb8"> | ||
| 61 | + <el-col :span="1.5"> | ||
| 62 | + <el-button type="primary" icon="el-icon-plus" size="mini" @click="handleAdd">新增</el-button> | ||
| 63 | + </el-col> | ||
| 64 | + <el-col :span="1.5"> | ||
| 65 | + <el-button type="success" icon="el-icon-edit" size="mini" :disabled="single" @click="handleUpdate">修改 | ||
| 66 | + </el-button> | ||
| 67 | + </el-col> | ||
| 68 | + <el-col :span="1.5"> | ||
| 69 | + <el-button type="danger" icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete">删除 | ||
| 70 | + </el-button> | ||
| 71 | + </el-col> | ||
| 72 | + </el-row> | ||
| 73 | + <el-table max-height="500" highlight-current-row border stripe v-loading="loading" :data="sourceFlightRulesList" | ||
| 74 | + @selection-change="handleSelectionChange"> | ||
| 75 | + <el-table-column type="selection" width="55" align="center" /> | ||
| 76 | + <el-table-column label="航班日期" align="center" prop="sourceFlightNo" /> | ||
| 77 | + <el-table-column label="航班起飞时间" align="center" prop="flightRank" width="280" /> | ||
| 78 | + <el-table-column label="航班号" align="center" prop="dayOfWeek" width="180" /> | ||
| 79 | + <el-table-column label="航班路线" align="center" prop="status" :formatter="statusFormat" /> | ||
| 80 | + <el-table-column label="航班类型" align="center" prop="startDate" width="100" /> | ||
| 81 | + <el-table-column label="航班种类" align="center" prop="endDate" width="100" /> | ||
| 82 | + <el-table-column label="航班状态" align="center" prop="updateUserName" /> | ||
| 83 | + <el-table-column label="总重量(KG)" align="center" prop="updateTime" width="130" /> | ||
| 84 | + <el-table-column label="原始重量(KG)" align="center" prop="updateTime" width="130" /> | ||
| 85 | + <el-table-column label="总体积(cm³)" align="center" prop="updateTime" width="130" /> | ||
| 86 | + <el-table-column label="是否限制一票一件" align="center" prop="updateTime" width="150" /> | ||
| 87 | + <el-table-column label="是否需要预审" align="center" prop="updateTime" width="150" /> | ||
| 88 | + <el-table-column label="额外增重百分比" align="center" prop="updateTime" width="150" /> | ||
| 89 | + <el-table-column label="高价百分比" align="center" prop="updateTime" width="150" /> | ||
| 90 | + <el-table-column label="低价百分比" align="center" prop="updateTime" width="150" /> | ||
| 91 | + <el-table-column label="是否开启高地价" align="center" prop="updateTime" width="150" /> | ||
| 92 | + <el-table-column label="已配重量(KG)" align="center" prop="updateTime" width="150" /> | ||
| 93 | + <el-table-column label="已配体积(cm³)" align="center" prop="updateTime" width="150" /> | ||
| 94 | + <el-table-column label="航班优先级" align="center" prop="updateTime" width="150" /> | ||
| 95 | + <el-table-column label="配舱优先级" align="center" prop="updateTime" width="150" /> | ||
| 96 | + <el-table-column label="创建人" align="center" prop="updateTime" width="100" /> | ||
| 97 | + <el-table-column label="创建时间" align="center" prop="updateTime" width="100" /> | ||
| 98 | + <el-table-column label="最后修改人" align="center" prop="updateTime" width="100" /> | ||
| 99 | + <el-table-column label="最后修改时间" align="center" prop="updateTime" width="100" /> | ||
| 100 | + <el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="130" fixed="right"> | ||
| 101 | + <template slot-scope="scope"> | ||
| 102 | + <el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)">修改</el-button> | ||
| 103 | + <el-button size="mini" type="text" icon="el-icon-delete" @click="handleDeleteorPlayorpause(scope.row,0,'删除')"> | ||
| 104 | + 删除</el-button> | ||
| 105 | + </template> | ||
| 106 | + </el-table-column> | ||
| 107 | + </el-table> | ||
| 108 | + | ||
| 109 | + <pagination v-show="total>0" :total="total" layout=" prev, pager, next, jumper, sizes,total" | ||
| 110 | + :page.sync="queryParams.pageNum" :limit.sync="queryParams.limit" @pagination="findSourceFlightRules" /> | ||
| 111 | + | ||
| 112 | + | ||
| 113 | + <!-- 查看目的航班对话框 --> | ||
| 114 | + <el-dialog title="实际配载航班" :visible.sync="openFlightDate" width="70%"> | ||
| 115 | + <el-table v-loading="loadingFlightDate" :data="sourceFlightAndFlightDate"> | ||
| 116 | + | ||
| 117 | + <el-table-column label="原航班" align="center" prop="sourceFlightNo" /> | ||
| 118 | + <el-table-column label="实际配载航班" align="center" prop="actualFlight" width="280" /> | ||
| 119 | + <el-table-column label="航班日期" align="center" prop="flightDate" /> | ||
| 120 | + <el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="200"> | ||
| 121 | + <template slot-scope="scope"> | ||
| 122 | + <el-button size="mini" type="text" icon="el-icon-edit" | ||
| 123 | + @click="handleClick(scope.row.sourceFlightNo, 'detail')">查看配置维度</el-button> | ||
| 124 | + </template> | ||
| 125 | + </el-table-column> | ||
| 126 | + </el-table> | ||
| 127 | + <div slot="footer" class="dialog-footer"> | ||
| 128 | + <el-button @click="cancelFlightDate">返 回</el-button> | ||
| 129 | + </div> | ||
| 130 | + </el-dialog> | ||
| 131 | + | ||
| 132 | + | ||
| 133 | + <!-- 添加或修改对话框 --> | ||
| 134 | + <el-dialog :title="title" :visible.sync="open" width="60%"> | ||
| 135 | + <el-form ref="form" :model="form" :rules="rules" label-width="100px"> | ||
| 136 | + <el-row> | ||
| 137 | + <el-col :span="10"> | ||
| 138 | + <el-form-item label="原航班" prop="sourceFlightNo"> | ||
| 139 | + <el-input v-model="form.sourceFlightNo" placeholder="请输入原航班号" /> | ||
| 140 | + </el-form-item> | ||
| 141 | + </el-col> | ||
| 142 | + </el-row> | ||
| 143 | + <el-row> | ||
| 144 | + <el-col :span="12"> | ||
| 145 | + <el-form-item label="有效开始时间" prop="startDate"> | ||
| 146 | + <el-date-picker clearable size="small" :picker-options="pickerOptionsStart" v-model="form.startDate" | ||
| 147 | + type="date" value-format="yyyy-MM-dd" placeholder="选择开始时间"> | ||
| 148 | + </el-date-picker> | ||
| 149 | + </el-form-item> | ||
| 150 | + </el-col> | ||
| 151 | + <el-col :span="12"> | ||
| 152 | + <el-form-item label="有效结束时间" prop="endDate"> | ||
| 153 | + <el-date-picker clearable size="small" :picker-options="pickerOptionsEnd" v-model="form.endDate" | ||
| 154 | + type="date" value-format="yyyy-MM-dd" placeholder="选择结束时间"> | ||
| 155 | + </el-date-picker> | ||
| 156 | + </el-form-item> | ||
| 157 | + </el-col> | ||
| 158 | + | ||
| 159 | + <el-col :span="24" style="margin-bottom: 5%;"> | ||
| 160 | + <span style="color: red;margin-left: 10%;">提示:配载航班之同请用分号分隔【符号不区分中英文】,例:CA1053:C7433</span><br /> | ||
| 161 | + <span style="color: red;margin-left: 10%;">提示:如果需要设置配载航班延迟或提前可以直接在目的航斑后加减【+-】天数。如:CA1053+1:CZ433-1</span> | ||
| 162 | + </el-col> | ||
| 163 | + <el-col :span="24"> | ||
| 164 | + <el-form-item label="配载航班" prop="flightRank"> | ||
| 165 | + <el-input type="textarea" v-model="form.flightRank" :rows="4"></el-input> | ||
| 166 | + </el-form-item> | ||
| 167 | + </el-col> | ||
| 168 | + <el-col :span="24"> | ||
| 169 | + <el-form-item label="周期段"> | ||
| 170 | + <el-checkbox-group v-model="dayOfWeek"> | ||
| 171 | + <el-checkbox v-for="item in dayOfWeekList" :key="item" :label="item" :name="item"></el-checkbox> | ||
| 172 | + </el-checkbox-group> | ||
| 173 | + </el-form-item> | ||
| 174 | + </el-col> | ||
| 175 | + | ||
| 176 | + </el-row> | ||
| 177 | + </el-form> | ||
| 178 | + <div slot="footer" class="dialog-footer"> | ||
| 179 | + <el-button type="primary" @click="submitForm">确 定</el-button> | ||
| 180 | + <el-button @click="cancel">取 消</el-button> | ||
| 181 | + </div> | ||
| 182 | + </el-dialog> | ||
| 183 | + </div> | ||
| 184 | +</template> | ||
| 185 | +<script> | ||
| 186 | + import { | ||
| 187 | + findSourceFlightRulesApi, | ||
| 188 | + sourceFlightRulesSaveApi, | ||
| 189 | + delOrEnableORDisableApi, | ||
| 190 | + findSourceFlightAndFlightDateApi | ||
| 191 | + } from "@/api/sourceFlightRules"; | ||
| 192 | + export default { | ||
| 193 | + name: "SourceFlightRules", | ||
| 194 | + data() { | ||
| 195 | + return { | ||
| 196 | + // 选中数组 | ||
| 197 | + ids: [], | ||
| 198 | + // 非单个禁用 | ||
| 199 | + single: true, | ||
| 200 | + // 非多个禁用 | ||
| 201 | + multiple: true, | ||
| 202 | + // data 中设定 | ||
| 203 | + pickerOptionsStart: { | ||
| 204 | + disabledDate: time => { | ||
| 205 | + let endDateVal = this.form.endDate; | ||
| 206 | + if (endDateVal) { | ||
| 207 | + return time.getTime() > new Date(endDateVal).getTime() || time.getTime() < new Date().getTime() - 24 * | ||
| 208 | + 60 * 60 * 1000; | ||
| 209 | + } else { | ||
| 210 | + return time.getTime() < new Date().getTime() - 24 * 60 * 60 * 1000; | ||
| 211 | + } | ||
| 212 | + } | ||
| 213 | + }, | ||
| 214 | + pickerOptionsEnd: { | ||
| 215 | + disabledDate: time => { | ||
| 216 | + let beginDateVal = this.form.startDate; | ||
| 217 | + if (beginDateVal) { | ||
| 218 | + return time.getTime() < new Date(beginDateVal).getTime(); | ||
| 219 | + } else { | ||
| 220 | + return time.getTime() < new Date().getTime() - 24 * 60 * 60 * 1000; | ||
| 221 | + } | ||
| 222 | + } | ||
| 223 | + }, | ||
| 224 | + | ||
| 225 | + //周期段 | ||
| 226 | + dayOfWeekList: ['D1', 'D2', 'D3', 'D4', 'D5', 'D6', 'D7'], | ||
| 227 | + // 遮罩层 | ||
| 228 | + loading: false, | ||
| 229 | + // 遮罩层 | ||
| 230 | + loadingFlightDate: false, | ||
| 231 | + // 弹出层标题 | ||
| 232 | + title: "", | ||
| 233 | + // 总条数 | ||
| 234 | + total: 0, | ||
| 235 | + // 原航班规则数据 | ||
| 236 | + sourceFlightRulesList: [], | ||
| 237 | + //目的航班数据 | ||
| 238 | + sourceFlightAndFlightDate: [], | ||
| 239 | + statusList: [{ | ||
| 240 | + 'id': 1, | ||
| 241 | + 'name': '有效' | ||
| 242 | + }, { | ||
| 243 | + 'id': 3, | ||
| 244 | + 'name': '停用' | ||
| 245 | + }], | ||
| 246 | + // 新增修改查看规则弹出层 | ||
| 247 | + open: false, | ||
| 248 | + // 是否显示查看目的航班弹出层 | ||
| 249 | + openFlightDate: false, | ||
| 250 | + // 查询参数 | ||
| 251 | + queryParams: { | ||
| 252 | + start: 0, //当前条数【代表第几条数据 +1开始】 | ||
| 253 | + pageNum: 1, | ||
| 254 | + limit: 20, //一页显示多少条数据 | ||
| 255 | + sourceFlightNo: undefined, //原航班号 | ||
| 256 | + status: undefined, //状态 | ||
| 257 | + flightDate: undefined //日期 | ||
| 258 | + }, | ||
| 259 | + dayOfWeek: [], | ||
| 260 | + // 表单参数 | ||
| 261 | + form: { | ||
| 262 | + dayOfWeek: [] | ||
| 263 | + }, | ||
| 264 | + currentRow: null, | ||
| 265 | + // 表单校验 | ||
| 266 | + rules: { | ||
| 267 | + sourceFlightNo: [{ | ||
| 268 | + required: true, | ||
| 269 | + message: "原航班号不能为空", | ||
| 270 | + trigger: "blur" | ||
| 271 | + }], | ||
| 272 | + flightRank: [{ | ||
| 273 | + required: true, | ||
| 274 | + message: "配载航班不能为空", | ||
| 275 | + trigger: "blur" | ||
| 276 | + }], | ||
| 277 | + } | ||
| 278 | + }; | ||
| 279 | + }, | ||
| 280 | + created() { | ||
| 281 | + this.findSourceFlightRules(); | ||
| 282 | + }, | ||
| 283 | + methods: { | ||
| 284 | + | ||
| 285 | + // 多选框选中数据 | ||
| 286 | + handleSelectionChange(selection) { | ||
| 287 | + this.ids = selection.map(item => item.postId) | ||
| 288 | + this.single = selection.length != 1 | ||
| 289 | + this.multiple = !selection.length | ||
| 290 | + }, | ||
| 291 | + //跳转到查看,修改页面 | ||
| 292 | + handleClick(flightiId, handle) { | ||
| 293 | + this.$router.push({ | ||
| 294 | + name: "Info", | ||
| 295 | + params: { | ||
| 296 | + handle: handle, | ||
| 297 | + id: flightiId | ||
| 298 | + }, | ||
| 299 | + }); | ||
| 300 | + }, | ||
| 301 | + /** 查询原航班顺位规则*/ | ||
| 302 | + findSourceFlightRules() { | ||
| 303 | + //this.loading = true; | ||
| 304 | + if (this.queryParams.pageNum > 1) { | ||
| 305 | + this.queryParams.start = (this.queryParams.pageNum - 1) * this.queryParams.limit | ||
| 306 | + } else { | ||
| 307 | + this.queryParams.start = 0; | ||
| 308 | + } | ||
| 309 | + findSourceFlightRulesApi(this.queryParams).then(response => { | ||
| 310 | + if (response.code == 200) { | ||
| 311 | + this.sourceFlightRulesList = response.data.list; | ||
| 312 | + this.total = response.data.totalCount; | ||
| 313 | + this.loading = false; | ||
| 314 | + } else { | ||
| 315 | + this.msgError(response.msg); | ||
| 316 | + } | ||
| 317 | + | ||
| 318 | + }); | ||
| 319 | + | ||
| 320 | + }, | ||
| 321 | + /** 新增按钮操作 */ | ||
| 322 | + handleAdd() { | ||
| 323 | + this.form = {}; | ||
| 324 | + this.open = true; | ||
| 325 | + this.title = "添加原航班顺位规则"; | ||
| 326 | + this.form.id = -1; | ||
| 327 | + this.dayOfWeek = []; | ||
| 328 | + | ||
| 329 | + }, | ||
| 330 | + /** 修改按钮操作 */ | ||
| 331 | + handleUpdate(row) { | ||
| 332 | + | ||
| 333 | + this.form = {}; | ||
| 334 | + this.dayOfWeek = []; | ||
| 335 | + this.open = true; | ||
| 336 | + this.title = "修改原航班顺位规则"; | ||
| 337 | + this.form = row; | ||
| 338 | + this.dayOfWeek = this.form.dayOfWeek ? this.form.dayOfWeek.split(";") : []; | ||
| 339 | + //this.form.dayOfWeek = this.form.dayOfWeek ? this.form.dayOfWeek.split(";") : []; | ||
| 340 | + | ||
| 341 | + }, | ||
| 342 | + /** 删除 启用 停用按钮操作 */ | ||
| 343 | + handleDeleteorPlayorpause(row, status, statusText) { | ||
| 344 | + debugger | ||
| 345 | + //删除前需要停用 | ||
| 346 | + if (status === 0 && row.status != '3') { | ||
| 347 | + this.$message({ | ||
| 348 | + message: '请停用后删除', | ||
| 349 | + type: 'warning' | ||
| 350 | + }); | ||
| 351 | + return; | ||
| 352 | + } | ||
| 353 | + | ||
| 354 | + this.$confirm('是否确认' + statusText + '此数据项?', "警告", { | ||
| 355 | + confirmButtonText: "确定", | ||
| 356 | + cancelButtonText: "取消", | ||
| 357 | + type: "warning" | ||
| 358 | + }).then(function() { | ||
| 359 | + | ||
| 360 | + let disable = { | ||
| 361 | + id: row.id, | ||
| 362 | + status: status | ||
| 363 | + }; | ||
| 364 | + | ||
| 365 | + return delOrEnableORDisableApi(disable); | ||
| 366 | + }).then(response => { | ||
| 367 | + if (response.code == 200) { | ||
| 368 | + this.findSourceFlightRules(); | ||
| 369 | + this.msgSuccess(statusText + "成功"); | ||
| 370 | + } else { | ||
| 371 | + this.msgError(response.msg); | ||
| 372 | + } | ||
| 373 | + | ||
| 374 | + }).catch(function() {}); | ||
| 375 | + }, | ||
| 376 | + /** 提交按钮 */ | ||
| 377 | + submitForm: function() { | ||
| 378 | + this.$refs["form"].validate(valid => { | ||
| 379 | + if (valid) { | ||
| 380 | + this.form.dayOfWeek = this.dayOfWeek.sort(); | ||
| 381 | + //处理数据 | ||
| 382 | + sourceFlightRulesSaveApi(this.form).then(response => { | ||
| 383 | + if (response.code === 200) { | ||
| 384 | + this.msgSuccess("保存成功"); | ||
| 385 | + this.open = false; | ||
| 386 | + this.findSourceFlightRules(); | ||
| 387 | + } else { | ||
| 388 | + this.msgError(response.msg); | ||
| 389 | + } | ||
| 390 | + }); | ||
| 391 | + | ||
| 392 | + } | ||
| 393 | + }); | ||
| 394 | + }, | ||
| 395 | + // 表单重置 | ||
| 396 | + reset() { | ||
| 397 | + this.form = { | ||
| 398 | + | ||
| 399 | + dayOfWeek: [] | ||
| 400 | + | ||
| 401 | + }; | ||
| 402 | + this.resetForm("form"); | ||
| 403 | + }, | ||
| 404 | + /** 查询目的航班*/ | ||
| 405 | + findSourceFlightAndFlightDate() { | ||
| 406 | + //校验原航班号非空 | ||
| 407 | + if (this.queryParams.sourceFlightNo === null || this.queryParams.sourceFlightNo === undefined || this | ||
| 408 | + .queryParams.sourceFlightNo.trim() === '') { | ||
| 409 | + this.$message.warning("原航班号为空"); | ||
| 410 | + return | ||
| 411 | + } | ||
| 412 | + //校验原日期非空 | ||
| 413 | + if (this.queryParams.flightDate === null || this.queryParams.flightDate === undefined) { | ||
| 414 | + this.$message.warning("日期为空"); | ||
| 415 | + return | ||
| 416 | + } | ||
| 417 | + this.openFlightDate = true; | ||
| 418 | + this.loadingFlightDate = true; | ||
| 419 | + this.sourceFlightAndFlightDate = []; | ||
| 420 | + findSourceFlightAndFlightDateApi(this.queryParams).then(response => { | ||
| 421 | + if (response.code === 200) { | ||
| 422 | + this.sourceFlightAndFlightDate = response.data; | ||
| 423 | + this.loadingFlightDate = false; | ||
| 424 | + } else { | ||
| 425 | + this.msgError(response.msg); | ||
| 426 | + } | ||
| 427 | + | ||
| 428 | + }); | ||
| 429 | + | ||
| 430 | + | ||
| 431 | + }, | ||
| 432 | + // 目的航班弹出框返回 | ||
| 433 | + cancelFlightDate() { | ||
| 434 | + this.openFlightDate = false; | ||
| 435 | + }, | ||
| 436 | + // 取消按钮 | ||
| 437 | + cancel() { | ||
| 438 | + this.open = false; | ||
| 439 | + // this.reset(); | ||
| 440 | + }, | ||
| 441 | + // 状态字典翻译 | ||
| 442 | + statusFormat(row) { | ||
| 443 | + if (row.status === '1') { | ||
| 444 | + return '有效' | ||
| 445 | + } else if (row.status === '2') { | ||
| 446 | + return '配置中' | ||
| 447 | + } else if (row.status === '3') { | ||
| 448 | + return '停用' | ||
| 449 | + } | ||
| 450 | + return row.status; | ||
| 451 | + }, | ||
| 452 | + /** 重置按钮操作 */ | ||
| 453 | + resetQuery() { | ||
| 454 | + this.resetForm("queryForm"); | ||
| 455 | + this.handleQuery(); | ||
| 456 | + }, | ||
| 457 | + /** 搜索按钮操作 */ | ||
| 458 | + handleQuery() { | ||
| 459 | + this.queryParams.pageNum = 1; | ||
| 460 | + this.queryParams.start = 0; | ||
| 461 | + this.findSourceFlightRules(); | ||
| 462 | + } | ||
| 463 | + | ||
| 464 | + } | ||
| 465 | + }; | ||
| 466 | +</script> | ||
| 467 | +<style> | ||
| 468 | + .el-table--striped .el-table__body tr.el-table__row--striped.current-row td, | ||
| 469 | + .el-table__body tr.current-row>td { | ||
| 470 | + background-color: #a0cfff; | ||
| 471 | + } | ||
| 472 | + | ||
| 473 | + .el-table--striped .el-table__body tr.hover-row.el-table__row--striped>td, | ||
| 474 | + .el-table__body tr.hover-row>td { | ||
| 475 | + background-color: #d9ecff !important; | ||
| 476 | + } | ||
| 477 | +</style> |
-
Please register or login to post a comment