Merge remote-tracking branch 'origin/nmms'
# Conflicts: # src/views/Home.vue
正在显示
11 个修改的文件
包含
909 行增加
和
221 行删除
| @@ -7,3 +7,7 @@ export const getCountry = params => { return http.get(`${baseUrl}/getCountryCode | @@ -7,3 +7,7 @@ export const getCountry = params => { return http.get(`${baseUrl}/getCountryCode | ||
| 7 | export const getByCountryCodeForName = params => { return http.post(`${baseUrl}/getByCountryCodeForName`,params)}; | 7 | export const getByCountryCodeForName = params => { return http.post(`${baseUrl}/getByCountryCodeForName`,params)}; |
| 8 | 8 | ||
| 9 | export const getByCountryCode = params => { return http.post(`${baseUrl}/getByCountryCode`,params)}; | 9 | export const getByCountryCode = params => { return http.post(`${baseUrl}/getByCountryCode`,params)}; |
| 10 | + | ||
| 11 | +export const getAirportCode = params =>{return http.post(`/nmms-server-import/nmms/mt1201/selectList`,params)} | ||
| 12 | + | ||
| 13 | +export const getCustomCode = params =>{return http.post(`/nmms-server-import/nmms/mt1201/selectCustomcode`,params)} |
| @@ -12,3 +12,7 @@ export const updateStatus = params => { return http.put(`${baseUrl}/updateStatus | @@ -12,3 +12,7 @@ export const updateStatus = params => { return http.put(`${baseUrl}/updateStatus | ||
| 12 | export const updateMT3201 = params => { return http.put(`${baseUrl}/updateMt3201`,params)}; | 12 | export const updateMT3201 = params => { return http.put(`${baseUrl}/updateMt3201`,params)}; |
| 13 | 13 | ||
| 14 | export const addMt3201 = params => { return http.post(`${baseUrl}/addMt3201`,params)}; | 14 | export const addMt3201 = params => { return http.post(`${baseUrl}/addMt3201`,params)}; |
| 15 | + | ||
| 16 | +export const sendCreateMt3201 = params => { return http.post(`${baseUrl}/sendCreateMt3201`,params)}; | ||
| 17 | + | ||
| 18 | +export const sendRemoveMt3201 = params => { return http.post(`${baseUrl}/sendRemoveMt3201`,params)}; |
| @@ -12,3 +12,8 @@ export const updateStatus = params => { return http.put(`${baseUrl}/updateStatus | @@ -12,3 +12,8 @@ export const updateStatus = params => { return http.put(`${baseUrl}/updateStatus | ||
| 12 | export const updateMT4201 = params => { return http.put(`${baseUrl}/updateMt4201`,params)}; | 12 | export const updateMT4201 = params => { return http.put(`${baseUrl}/updateMt4201`,params)}; |
| 13 | 13 | ||
| 14 | export const addMt4201 = params => { return http.post(`${baseUrl}/addMt4201`,params)}; | 14 | export const addMt4201 = params => { return http.post(`${baseUrl}/addMt4201`,params)}; |
| 15 | + | ||
| 16 | + | ||
| 17 | +export const sendCreateMt4201 = params => { return http.post(`${baseUrl}/sendCreateMt4201`,params)}; | ||
| 18 | + | ||
| 19 | +export const sendDeleteMt4201 = params => { return http.post(`${baseUrl}/sendDeleteMt4201`,params)}; |
| @@ -17,3 +17,9 @@ export const getLostLoadChange = params => { return http.get(`${baseUrl}/getLost | @@ -17,3 +17,9 @@ export const getLostLoadChange = params => { return http.get(`${baseUrl}/getLost | ||
| 17 | export const saveLostChange = params => { return http.get(`${baseUrl}/saveLostChange`, params)}; | 17 | export const saveLostChange = params => { return http.get(`${baseUrl}/saveLostChange`, params)}; |
| 18 | 18 | ||
| 19 | export const saveLostLoad = params => { return http.put(`${baseUrl}/saveLostLoad`,params)}; | 19 | export const saveLostLoad = params => { return http.put(`${baseUrl}/saveLostLoad`,params)}; |
| 20 | + | ||
| 21 | +export const sendDeleteMt2201 = params =>{return http.post(`${baseUrl}/sendDeleteMt2201`,params)} | ||
| 22 | + | ||
| 23 | +export const sendUpdateMt2201 = params =>{return http.post(`${baseUrl}/sendUpdateMt2201`,params)} | ||
| 24 | + | ||
| 25 | +export const sendCreateMt2201 = params =>{return http.post(`${baseUrl}/sendCreateMt2201`,params)} |
| @@ -12,3 +12,7 @@ export const updateStatus = params => { return http.put(`${baseUrl}/updateStatus | @@ -12,3 +12,7 @@ export const updateStatus = params => { return http.put(`${baseUrl}/updateStatus | ||
| 12 | export const updateMt520X = params => { return http.put(`${baseUrl}/updateMt520x`,params)}; | 12 | export const updateMt520X = params => { return http.put(`${baseUrl}/updateMt520x`,params)}; |
| 13 | 13 | ||
| 14 | export const addMt520X = params => { return http.post(`${baseUrl}/addMt520x`,params)}; | 14 | export const addMt520X = params => { return http.post(`${baseUrl}/addMt520x`,params)}; |
| 15 | + | ||
| 16 | +export const sendCreateMt5202 = params => { return http.post(`${baseUrl}/sendCreateMt5202`,params)}; | ||
| 17 | + | ||
| 18 | +export const sendRemoveMt5202 = params => { return http.post(`${baseUrl}/sendRemoveMt5202`,params)}; |
| @@ -93,6 +93,7 @@ | @@ -93,6 +93,7 @@ | ||
| 93 | <template slot-scope="scope"> | 93 | <template slot-scope="scope"> |
| 94 | <span v-if="scope.row.status ==='01'">未发送</span> | 94 | <span v-if="scope.row.status ==='01'">未发送</span> |
| 95 | <span v-if="scope.row.status ==='02'">已发舱单报</span> | 95 | <span v-if="scope.row.status ==='02'">已发舱单报</span> |
| 96 | + <span v-if="scope.row.status ==='04'">已发送</span> | ||
| 96 | <span v-if="scope.row.status ==='05'">舱单报退单</span> | 97 | <span v-if="scope.row.status ==='05'">舱单报退单</span> |
| 97 | <span v-if="scope.row.status ==='06'">舱单转人工</span> | 98 | <span v-if="scope.row.status ==='06'">舱单转人工</span> |
| 98 | <span v-if="scope.row.status ==='07'">舱单报申报成功</span> | 99 | <span v-if="scope.row.status ==='07'">舱单报申报成功</span> |
| @@ -115,15 +116,13 @@ | @@ -115,15 +116,13 @@ | ||
| 115 | <el-table-column prop="operation" label="操作" align="center"> | 116 | <el-table-column prop="operation" label="操作" align="center"> |
| 116 | <template slot-scope="scope"> | 117 | <template slot-scope="scope"> |
| 117 | <el-button size="mini" @click="handleSend(scope.row)">收发明细</el-button> | 118 | <el-button size="mini" @click="handleSend(scope.row)">收发明细</el-button> |
| 118 | - <el-button size="mini" type="success" @click="handleEdit(scope.row)">编辑运单</el-button> | ||
| 119 | - <el-button size="mini" type="primary" @click="handleAwbSend(scope.row)" | ||
| 120 | - :disabled="scope.row.status !=='00'">发送舱单报 | ||
| 121 | - </el-button> | 119 | + <el-button size="mini" type="success" @click="handleEdit(scope.row)" :disabled="scope.row.status !=='01'">编辑</el-button> |
| 120 | + <el-button size="mini" type="primary" @click="handleSendAwb(scope.row)" | ||
| 121 | + :disabled="scope.row.status !=='01'">发送舱单报</el-button> | ||
| 122 | <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单</el-button> | 122 | <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单</el-button> |
| 123 | - | ||
| 124 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" | 123 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" |
| 125 | - :disabled="scope.row.status ==='00'">修改状态 | ||
| 126 | - </el-button> | 124 | + :disabled="scope.row.status ==='01'">修改状态</el-button> |
| 125 | + <el-button size="mini" type="danger" @click="handleSendDelete(scope.row)">发删除报</el-button> | ||
| 127 | </template> | 126 | </template> |
| 128 | </el-table-column> | 127 | </el-table-column> |
| 129 | </el-table> | 128 | </el-table> |
| @@ -132,7 +131,7 @@ | @@ -132,7 +131,7 @@ | ||
| 132 | <el-button type="primary" size="mini" v-if="arriveQuery.flightno !==undefined || arriveData.length>0" | 131 | <el-button type="primary" size="mini" v-if="arriveQuery.flightno !==undefined || arriveData.length>0" |
| 133 | @click="handelAddArriveInfo">新增出港运抵 | 132 | @click="handelAddArriveInfo">新增出港运抵 |
| 134 | </el-button> | 133 | </el-button> |
| 135 | - <el-button type="primary" size="mini" v-if="arriveModel.flightno !== undefined || arriveData.length>0" | 134 | + <el-button type="primary" size="mini" v-if="arriveQuery.flightno !== undefined || arriveData.length>0" |
| 136 | @click="handelBackStep">返回 | 135 | @click="handelBackStep">返回 |
| 137 | </el-button> | 136 | </el-button> |
| 138 | </el-row> | 137 | </el-row> |
| @@ -185,14 +184,26 @@ | @@ -185,14 +184,26 @@ | ||
| 185 | <el-row> | 184 | <el-row> |
| 186 | <el-col :span="7.5"> | 185 | <el-col :span="7.5"> |
| 187 | <el-form-item label="起始站" prop="originstation"> | 186 | <el-form-item label="起始站" prop="originstation"> |
| 188 | - <el-input v-model="originstation" | ||
| 189 | - :disabled="dialogFormVisible === 'update'"></el-input> | 187 | + <el-select filterable clearable placeholder="请选择起始站" allow-create v-model="arriveModel.originstation"> |
| 188 | + <el-option v-for="item in airportCode" | ||
| 189 | + :key="item.airportid" :label="item.airportid" | ||
| 190 | + :value="item.airportid" :disabled="dialogFormVisible === 'update'"> | ||
| 191 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 192 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 193 | + </el-option> | ||
| 194 | + </el-select> | ||
| 190 | </el-form-item> | 195 | </el-form-item> |
| 191 | </el-col> | 196 | </el-col> |
| 192 | <el-col :span="7.5"> | 197 | <el-col :span="7.5"> |
| 193 | <el-form-item label="目的站" prop="destinationstation"> | 198 | <el-form-item label="目的站" prop="destinationstation"> |
| 194 | - <el-input v-model="destinationstation" | ||
| 195 | - :disabled="dialogFormVisible === 'update'"></el-input> | 199 | + <el-select filterable clearable placeholder="请选择起始站" allow-create v-model="arriveModel.destinationstation"> |
| 200 | + <el-option v-for="item in airportCode" | ||
| 201 | + :key="item.airportid" :label="item.airportid" | ||
| 202 | + :value="item.airportid" :disabled="dialogFormVisible === 'update'"> | ||
| 203 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 204 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 205 | + </el-option> | ||
| 206 | + </el-select> | ||
| 196 | </el-form-item> | 207 | </el-form-item> |
| 197 | </el-col> | 208 | </el-col> |
| 198 | </el-row> | 209 | </el-row> |
| @@ -226,9 +237,13 @@ | @@ -226,9 +237,13 @@ | ||
| 226 | </el-col> | 237 | </el-col> |
| 227 | <el-col :span="7.5"> | 238 | <el-col :span="7.5"> |
| 228 | <el-form-item label="海关关区" prop="customcode"> | 239 | <el-form-item label="海关关区" prop="customcode"> |
| 229 | - <el-select v-model="arriveModel.customcode"> | ||
| 230 | - <el-option v-for="item in customcodeList " :key="item" :label="item" | ||
| 231 | - :value="item"></el-option> | 240 | + <el-select v-model="arriveModel.customcode" placeholder="请选择关区代码" filterable clearable |
| 241 | + :disabled="dialogStatus === 'addAwbh'"> | ||
| 242 | + <el-option v-for="item in customCodeList" :key="item.customcode" :label="item.customcode" | ||
| 243 | + :value="item.customcode"> | ||
| 244 | + <span style="float: left">{{ item.customcode }}</span> | ||
| 245 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.customname }}</span> | ||
| 246 | + </el-option> | ||
| 232 | </el-select> | 247 | </el-select> |
| 233 | </el-form-item> | 248 | </el-form-item> |
| 234 | </el-col> | 249 | </el-col> |
| @@ -237,7 +252,6 @@ | @@ -237,7 +252,6 @@ | ||
| 237 | <div slot="footer" class="dialog-footer"> | 252 | <div slot="footer" class="dialog-footer"> |
| 238 | <el-button @click="dialogFormVisible = false">取消</el-button> | 253 | <el-button @click="dialogFormVisible = false">取消</el-button> |
| 239 | <el-button type="primary" @click="dialogStatus==='create'?createData():updateData()">保存</el-button> | 254 | <el-button type="primary" @click="dialogStatus==='create'?createData():updateData()">保存</el-button> |
| 240 | - <el-button type="success" @click="SaveAndSend">保存并发送</el-button> | ||
| 241 | </div> | 255 | </div> |
| 242 | </el-dialog> | 256 | </el-dialog> |
| 243 | <el-dialog title="收发明细" :visible.sync="dialogTableVisible"> | 257 | <el-dialog title="收发明细" :visible.sync="dialogTableVisible"> |
| @@ -279,16 +293,51 @@ | @@ -279,16 +293,51 @@ | ||
| 279 | </el-table-column> | 293 | </el-table-column> |
| 280 | </el-table> | 294 | </el-table> |
| 281 | </el-dialog> | 295 | </el-dialog> |
| 296 | + <el-dialog title="删除原因" :visible.sync="dialogDeleteVisible" width="30%"> | ||
| 297 | + <el-form ref="arriveDeleteForm" :model="respModel" :rules="arriveDeleteRules" | ||
| 298 | + label-width="120px" style="margin-right: 50px"> | ||
| 299 | + <el-form-item label="删除原因" prop="reason"> | ||
| 300 | + <el-input v-model="respModel.reason" placeholder="删除原因"></el-input> | ||
| 301 | + </el-form-item> | ||
| 302 | + <el-form-item label="删除操作人" prop="contactName"> | ||
| 303 | + <el-input v-model="respModel.contactName" placeholder="操作人姓名"></el-input> | ||
| 304 | + </el-form-item> | ||
| 305 | + <el-form-item label="操作人Tel" prop="contactTel"> | ||
| 306 | + <el-input v-model="respModel.contactTel" placeholder="删除操作人联系方式"></el-input> | ||
| 307 | + </el-form-item> | ||
| 308 | + <el-form-item label="备注"> | ||
| 309 | + <el-input v-model="respModel.content" type="textarea"></el-input> | ||
| 310 | + </el-form-item> | ||
| 311 | + </el-form> | ||
| 312 | + <div slot="footer" class="dialog-footer"> | ||
| 313 | + <el-button @click="dialogDeleteVisible = false">取消</el-button> | ||
| 314 | + <el-button type="primary" @click="sendArriveDelete()">发送</el-button> | ||
| 315 | + </div> | ||
| 316 | + </el-dialog> | ||
| 282 | </div> | 317 | </div> |
| 283 | </template> | 318 | </template> |
| 284 | <script> | 319 | <script> |
| 285 | import treeTable from '@/components/TreeTable' | 320 | import treeTable from '@/components/TreeTable' |
| 286 | import treeToArray from '@/utils/customEval' | 321 | import treeToArray from '@/utils/customEval' |
| 287 | import Pagination from '@/components/Pagination' | 322 | import Pagination from '@/components/Pagination' |
| 288 | - | ||
| 289 | - import {getMt3201ListForParam, deleteByIsDelete, updateStatus, updateMT3201, addMt3201} from '@/api/exitArrive' | 323 | + import {getCustomCode,getAirportCode} from "@/api/country"; |
| 324 | + import { | ||
| 325 | + getMt3201ListForParam, | ||
| 326 | + deleteByIsDelete, | ||
| 327 | + updateStatus, | ||
| 328 | + updateMT3201, | ||
| 329 | + addMt3201, | ||
| 330 | + sendCreateMt3201, | ||
| 331 | + sendRemoveMt3201 | ||
| 332 | + } from '@/api/exitArrive' | ||
| 290 | import {Message} from "element-ui"; | 333 | import {Message} from "element-ui"; |
| 291 | - import {validAwb, validAlphabets, validAlphabetsAndNum,validAlphabetsAndSpanceKey,validatorNum} from "@/utils/validate"; | 334 | + import { |
| 335 | + validAwb, | ||
| 336 | + validAlphabets, | ||
| 337 | + validAlphabetsAndNum, | ||
| 338 | + validAlphabetsAndSpanceKey, | ||
| 339 | + validatorNum | ||
| 340 | + } from "@/utils/validate"; | ||
| 292 | import {getResponseForParam} from '@/api/responseDetail' | 341 | import {getResponseForParam} from '@/api/responseDetail' |
| 293 | 342 | ||
| 294 | export default { | 343 | export default { |
| @@ -314,8 +363,8 @@ | @@ -314,8 +363,8 @@ | ||
| 314 | } | 363 | } |
| 315 | callback() | 364 | callback() |
| 316 | } | 365 | } |
| 317 | - const validAlphabetsSpanceKey = (rule,value,callback) =>{ | ||
| 318 | - if(!validAlphabetsAndSpanceKey(value)){ | 366 | + const validAlphabetsSpanceKey = (rule, value, callback) => { |
| 367 | + if (!validAlphabetsAndSpanceKey(value)) { | ||
| 319 | callback("只能输入字母、数字、空格") | 368 | callback("只能输入字母、数字、空格") |
| 320 | } | 369 | } |
| 321 | callback() | 370 | callback() |
| @@ -339,7 +388,8 @@ | @@ -339,7 +388,8 @@ | ||
| 339 | flightdate: undefined, | 388 | flightdate: undefined, |
| 340 | originstation: undefined, | 389 | originstation: undefined, |
| 341 | destinationstation: undefined, | 390 | destinationstation: undefined, |
| 342 | - customcode: undefined | 391 | + customcode: undefined, |
| 392 | + messageType: undefined, | ||
| 343 | }, | 393 | }, |
| 344 | dialogMap: { | 394 | dialogMap: { |
| 345 | update: '编辑出港运抵', | 395 | update: '编辑出港运抵', |
| @@ -347,10 +397,12 @@ | @@ -347,10 +397,12 @@ | ||
| 347 | }, | 397 | }, |
| 348 | dialogTableVisible: false, | 398 | dialogTableVisible: false, |
| 349 | multipleSelection: [], | 399 | multipleSelection: [], |
| 350 | - customcodeList: [4604, 4620], | 400 | + customCodeList: [], |
| 401 | + airportCode:[], | ||
| 351 | dialogStatus: undefined, | 402 | dialogStatus: undefined, |
| 352 | awbhStatus: false, | 403 | awbhStatus: false, |
| 353 | dialogFormVisible: false, | 404 | dialogFormVisible: false, |
| 405 | + dialogDeleteVisible: false, | ||
| 354 | listLoading: false, | 406 | listLoading: false, |
| 355 | arriveRoles: { | 407 | arriveRoles: { |
| 356 | awba: [{required: true, trigger: 'blur', validator: validatorAwb}], | 408 | awba: [{required: true, trigger: 'blur', validator: validatorAwb}], |
| @@ -379,7 +431,24 @@ | @@ -379,7 +431,24 @@ | ||
| 379 | customcode: undefined, | 431 | customcode: undefined, |
| 380 | arrivetime: undefined, | 432 | arrivetime: undefined, |
| 381 | messageType: 'MT3201' | 433 | messageType: 'MT3201' |
| 382 | - } | 434 | + }, |
| 435 | + respModel: { | ||
| 436 | + uuid: undefined, | ||
| 437 | + reason: undefined, | ||
| 438 | + contactName: undefined, | ||
| 439 | + contactTel: undefined, | ||
| 440 | + content: '', | ||
| 441 | + flightNo: undefined, | ||
| 442 | + awba: undefined, | ||
| 443 | + customCode: undefined, | ||
| 444 | + flightDate: undefined, | ||
| 445 | + awbh: '' | ||
| 446 | + }, | ||
| 447 | + arriveDeleteRules: { | ||
| 448 | + reason: [{required: true, message: '删除原因不能为空', trigger: 'blur'}], | ||
| 449 | + contactName: [{required: true, message: '删除操作人不能为空', trigger: 'blur'}], | ||
| 450 | + contactTel: [{required: true, message: '操作人联系方式不能为空', trigger: 'blur'}] | ||
| 451 | + }, | ||
| 383 | } | 452 | } |
| 384 | }, | 453 | }, |
| 385 | created() { | 454 | created() { |
| @@ -388,7 +457,6 @@ | @@ -388,7 +457,6 @@ | ||
| 388 | if (this.$route.params.flightData.awba !== undefined && this.$route.params.flightData.awba !== '') { | 457 | if (this.$route.params.flightData.awba !== undefined && this.$route.params.flightData.awba !== '') { |
| 389 | this.arriveQuery.awba = this.$route.params.flightData.awba.substring(0, 3) + "-" + this.$route.params.flightData.awba.substring(3) | 458 | this.arriveQuery.awba = this.$route.params.flightData.awba.substring(0, 3) + "-" + this.$route.params.flightData.awba.substring(3) |
| 390 | } | 459 | } |
| 391 | - | ||
| 392 | this.arriveQuery.carrier = this.$route.params.flightData.flightno.substring(0, 2) | 460 | this.arriveQuery.carrier = this.$route.params.flightData.flightno.substring(0, 2) |
| 393 | this.arriveQuery.flightno = this.$route.params.flightData.flightno.substring(2) | 461 | this.arriveQuery.flightno = this.$route.params.flightData.flightno.substring(2) |
| 394 | this.arriveQuery.flightdate = this.$route.params.flightData.flightdate | 462 | this.arriveQuery.flightdate = this.$route.params.flightData.flightdate |
| @@ -396,8 +464,10 @@ | @@ -396,8 +464,10 @@ | ||
| 396 | this.arriveQuery.destinationstation = this.$route.params.flightData.destinationstation | 464 | this.arriveQuery.destinationstation = this.$route.params.flightData.destinationstation |
| 397 | this.getList() | 465 | this.getList() |
| 398 | } | 466 | } |
| 467 | + this.getAirportCode() | ||
| 468 | + this.getCustomCode() | ||
| 399 | let username = JSON.parse(sessionStorage.getItem('user')).username | 469 | let username = JSON.parse(sessionStorage.getItem('user')).username |
| 400 | - if(username === 'admin'){ | 470 | + if (username === 'admin') { |
| 401 | this.isAdmin = true | 471 | this.isAdmin = true |
| 402 | } | 472 | } |
| 403 | }, | 473 | }, |
| @@ -575,9 +645,73 @@ | @@ -575,9 +645,73 @@ | ||
| 575 | 645 | ||
| 576 | }) | 646 | }) |
| 577 | }, | 647 | }, |
| 578 | - //保存并发送 | ||
| 579 | - SaveAndSend() { | 648 | + // 发送舱单报 |
| 649 | + handleSendAwb(row) { | ||
| 650 | + this.$confirm("是否发送", "确认消息", { | ||
| 651 | + distinguishCancelAndClose: true, | ||
| 652 | + confirmButtonText: '发送', | ||
| 653 | + cancelButtonText: '取消' | ||
| 654 | + }).then(() => { | ||
| 655 | + if(row.awbh ===null){ | ||
| 656 | + row.awbh = '' | ||
| 657 | + } | ||
| 658 | + sendCreateMt3201(row).then(res => { | ||
| 659 | + if (res.data.count > 0) { | ||
| 660 | + Message.success(res.data.respMessage) | ||
| 661 | + this.getList() | ||
| 662 | + } else { | ||
| 663 | + Message.success(res.data.respMessage) | ||
| 664 | + } | ||
| 665 | + }) | ||
| 666 | + }).catch(error => { | ||
| 667 | + Message.error(error.message) | ||
| 668 | + }) | ||
| 669 | + }, | ||
| 670 | + | ||
| 671 | + // 发送删除报 | ||
| 672 | + handleSendDelete(row) { | ||
| 673 | + this.respModel = { | ||
| 674 | + uuid: undefined, | ||
| 675 | + reason: undefined, | ||
| 676 | + contactName: undefined, | ||
| 677 | + contactTel: undefined, | ||
| 678 | + content: '', | ||
| 679 | + flightNo: undefined, | ||
| 680 | + awba: undefined, | ||
| 681 | + customCode: undefined, | ||
| 682 | + flightDate: undefined, | ||
| 683 | + awbh: undefined | ||
| 684 | + } | ||
| 685 | + this.dialogDeleteVisible = true | ||
| 686 | + this.respModel.flightNo = row.carrier + row.flightno | ||
| 687 | + this.respModel.awba = row.awba | ||
| 688 | + this.respModel.uuid = row.uuid | ||
| 689 | + if(row.awbh ===null){ | ||
| 690 | + this.respModel.awbh = '' | ||
| 691 | + }else { | ||
| 692 | + this.respModel.awbh = row.awbh | ||
| 693 | + } | ||
| 694 | + this.respModel.customCode = row.customcode | ||
| 695 | + this.respModel.flightDate = row.flightdate | ||
| 696 | + this.$nextTick(() => { | ||
| 697 | + this.$refs.arriveDeleteForm.clearValidate() | ||
| 698 | + }) | ||
| 699 | + }, | ||
| 580 | 700 | ||
| 701 | + sendArriveDelete() { | ||
| 702 | + this.$refs.arriveDeleteForm.validate(valid => { | ||
| 703 | + if (valid) { | ||
| 704 | + sendRemoveMt3201(this.respModel).then(res => { | ||
| 705 | + if (res.data.count > 0) { | ||
| 706 | + Message.success(res.data.respMessage) | ||
| 707 | + this.dialogDeleteVisible = false | ||
| 708 | + this.getList() | ||
| 709 | + } else { | ||
| 710 | + Message.success(res.data.respMessage) | ||
| 711 | + } | ||
| 712 | + }) | ||
| 713 | + } | ||
| 714 | + }) | ||
| 581 | }, | 715 | }, |
| 582 | // 收发明细 | 716 | // 收发明细 |
| 583 | handleSend(row) { | 717 | handleSend(row) { |
| @@ -594,14 +728,6 @@ | @@ -594,14 +728,6 @@ | ||
| 594 | this.detailData = res.data | 728 | this.detailData = res.data |
| 595 | }) | 729 | }) |
| 596 | }, | 730 | }, |
| 597 | - // 发送舱单报 | ||
| 598 | - handleAwbSend() { | ||
| 599 | - | ||
| 600 | - }, | ||
| 601 | - // 发送修改报 | ||
| 602 | - handleAwbEdit() { | ||
| 603 | - | ||
| 604 | - }, | ||
| 605 | //发送删除报 | 731 | //发送删除报 |
| 606 | handleAwbDelete(row) { | 732 | handleAwbDelete(row) { |
| 607 | this.$confirm("是否删除", "确认消息", { | 733 | this.$confirm("是否删除", "确认消息", { |
| @@ -663,6 +789,16 @@ | @@ -663,6 +789,16 @@ | ||
| 663 | }) | 789 | }) |
| 664 | }) | 790 | }) |
| 665 | }, | 791 | }, |
| 792 | + getAirportCode(){ | ||
| 793 | + getAirportCode().then(res=>{ | ||
| 794 | + this.airportCode = res.data.data | ||
| 795 | + }) | ||
| 796 | + }, | ||
| 797 | + getCustomCode(){ | ||
| 798 | + getCustomCode().then(res =>{ | ||
| 799 | + this.customCodeList = res.data.data | ||
| 800 | + }) | ||
| 801 | + }, | ||
| 666 | // 携数据跳转 新增运抵 | 802 | // 携数据跳转 新增运抵 |
| 667 | handleAddArrive() { | 803 | handleAddArrive() { |
| 668 | const row = { | 804 | const row = { |
| @@ -671,7 +807,8 @@ | @@ -671,7 +807,8 @@ | ||
| 671 | this.$router.push({name: "出港航班信息", params: {scopeRow: row}}) | 807 | this.$router.push({name: "出港航班信息", params: {scopeRow: row}}) |
| 672 | }, | 808 | }, |
| 673 | handelBackStep() { | 809 | handelBackStep() { |
| 674 | - this.$router.push({name: '出港航班信息', params: {scopeRow: this.arriveModel}}) | 810 | + this.arriveQuery.messageType = 'MT3201' |
| 811 | + this.$router.push({name: '出港航班信息', params: {scopeRow: this.arriveQuery}}) | ||
| 675 | } | 812 | } |
| 676 | 813 | ||
| 677 | } | 814 | } |
| @@ -26,14 +26,42 @@ | @@ -26,14 +26,42 @@ | ||
| 26 | </el-date-picker> | 26 | </el-date-picker> |
| 27 | </el-col> | 27 | </el-col> |
| 28 | <el-col :span="4"> | 28 | <el-col :span="4"> |
| 29 | - <el-input placeholder="必填" v-model="originstation"> | ||
| 30 | - <template slot="prepend">始发站</template> | ||
| 31 | - </el-input> | 29 | + <el-select |
| 30 | + :remote-method="remoteMethod" | ||
| 31 | + :loading="listLoading" | ||
| 32 | + v-model="flight.originstation" | ||
| 33 | + allow-create | ||
| 34 | + filterable | ||
| 35 | + remote | ||
| 36 | + placeholder="请选择起始站" clearable> | ||
| 37 | + <el-option | ||
| 38 | + v-for="item in airportCode" | ||
| 39 | + :key="item.value" | ||
| 40 | + :label="item.value" | ||
| 41 | + :value="item.value"> | ||
| 42 | + <span style="float: left">{{ item.label }}</span> | ||
| 43 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.value }}</span> | ||
| 44 | + </el-option> | ||
| 45 | + </el-select> | ||
| 32 | </el-col> | 46 | </el-col> |
| 33 | <el-col :span="4" style="margin-left: 20px"> | 47 | <el-col :span="4" style="margin-left: 20px"> |
| 34 | - <el-input placeholder="必填" v-model="destinationstation"> | ||
| 35 | - <template slot="prepend">目的站</template> | ||
| 36 | - </el-input> | 48 | + <el-select |
| 49 | + :remote-method="remoteMethod" | ||
| 50 | + :loading="listLoading" | ||
| 51 | + v-model="flight.destinationstation" | ||
| 52 | + allow-create | ||
| 53 | + filterable | ||
| 54 | + remote | ||
| 55 | + placeholder="请选择目的站" clearable> | ||
| 56 | + <el-option | ||
| 57 | + v-for="item in airportCode" | ||
| 58 | + :key="item.value" | ||
| 59 | + :label="item.value" | ||
| 60 | + :value="item.value"> | ||
| 61 | + <span style="float: left">{{ item.label }}</span> | ||
| 62 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.value }}</span> | ||
| 63 | + </el-option> | ||
| 64 | + </el-select> | ||
| 37 | </el-col> | 65 | </el-col> |
| 38 | <el-col :span="4" style="margin-left: 20px"> | 66 | <el-col :span="4" style="margin-left: 20px"> |
| 39 | <el-input placeholder="可为空" v-model="awba"> | 67 | <el-input placeholder="可为空" v-model="awba"> |
| @@ -55,7 +83,7 @@ | @@ -55,7 +83,7 @@ | ||
| 55 | 83 | ||
| 56 | <script> | 84 | <script> |
| 57 | import {Message} from "element-ui"; | 85 | import {Message} from "element-ui"; |
| 58 | - | 86 | + import {getCountry,getAirportCode} from "@/api/country"; |
| 59 | export default { | 87 | export default { |
| 60 | name: 'ExitFlightDesc', | 88 | name: 'ExitFlightDesc', |
| 61 | data() { | 89 | data() { |
| @@ -68,7 +96,11 @@ | @@ -68,7 +96,11 @@ | ||
| 68 | awba: undefined, | 96 | awba: undefined, |
| 69 | messageType:undefined | 97 | messageType:undefined |
| 70 | }, | 98 | }, |
| 71 | - btnStatus: true | 99 | + btnStatus: true, |
| 100 | + listLoading: false, | ||
| 101 | + airportList:[], | ||
| 102 | + airportResultCode: [], | ||
| 103 | + airportCode: [], | ||
| 72 | }; | 104 | }; |
| 73 | }, | 105 | }, |
| 74 | created() { | 106 | created() { |
| @@ -85,8 +117,17 @@ | @@ -85,8 +117,17 @@ | ||
| 85 | if(this.$route.params.scopeRow.awba !== undefined){ | 117 | if(this.$route.params.scopeRow.awba !== undefined){ |
| 86 | this.flight.awba = this.$route.params.scopeRow.awba.replace('-','') | 118 | this.flight.awba = this.$route.params.scopeRow.awba.replace('-','') |
| 87 | } | 119 | } |
| 88 | - | ||
| 89 | } | 120 | } |
| 121 | + this.getCountryList() | ||
| 122 | + this.getAirport() | ||
| 123 | + }, | ||
| 124 | + mounted() { | ||
| 125 | + // 延迟加载,否则会出错 | ||
| 126 | + setTimeout(() => { | ||
| 127 | + this.airportResultCode = this.airportCode.map(item =>{ | ||
| 128 | + return {label: item.airportdescchn,value: item.airportid} | ||
| 129 | + }) | ||
| 130 | + }, 6000) | ||
| 90 | }, | 131 | }, |
| 91 | computed:{ | 132 | computed:{ |
| 92 | flightno : { | 133 | flightno : { |
| @@ -144,7 +185,7 @@ | @@ -144,7 +185,7 @@ | ||
| 144 | this.flight.awba = undefined | 185 | this.flight.awba = undefined |
| 145 | } | 186 | } |
| 146 | 187 | ||
| 147 | - if(this.flight.messageType ==="MT5201"){ | 188 | + if(this.flight.messageType ==="MT5202"){ |
| 148 | this.$router.push({name: '出港理货', params: {flightData: this.flight}}); | 189 | this.$router.push({name: '出港理货', params: {flightData: this.flight}}); |
| 149 | } | 190 | } |
| 150 | if(this.flight.messageType ==="MT4201"){ | 191 | if(this.flight.messageType ==="MT4201"){ |
| @@ -160,7 +201,31 @@ | @@ -160,7 +201,31 @@ | ||
| 160 | Message.warning("请将航班信息填写完整") | 201 | Message.warning("请将航班信息填写完整") |
| 161 | } | 202 | } |
| 162 | 203 | ||
| 163 | - } | 204 | + }, |
| 205 | + | ||
| 206 | + getAirport(){ | ||
| 207 | + getAirportCode().then(res =>{ | ||
| 208 | + this.airportCode = res.data.data | ||
| 209 | + }) | ||
| 210 | + }, | ||
| 211 | + getCountryList() { | ||
| 212 | + getCountry().then(res => { | ||
| 213 | + this.countryList = res.data.dataList | ||
| 214 | + }) | ||
| 215 | + }, | ||
| 216 | + remoteMethod(query) { | ||
| 217 | + if (query !== '') { | ||
| 218 | + this.listLoading = true | ||
| 219 | + setTimeout(() => { | ||
| 220 | + this.listLoading = false | ||
| 221 | + this.airportCode = this.airportResultCode.filter(item => { | ||
| 222 | + return item.value.trim().indexOf(query.toUpperCase()) > -1 | ||
| 223 | + }) | ||
| 224 | + }, 200) | ||
| 225 | + } else { | ||
| 226 | + this.airportCode = [] | ||
| 227 | + } | ||
| 228 | + }, | ||
| 164 | } | 229 | } |
| 165 | }; | 230 | }; |
| 166 | </script> | 231 | </script> |
| @@ -37,7 +37,7 @@ | @@ -37,7 +37,7 @@ | ||
| 37 | </el-col> | 37 | </el-col> |
| 38 | <div class="el-btn"> | 38 | <div class="el-btn"> |
| 39 | <el-button type="primary" size="mini" @click="handleSearch">查询</el-button> | 39 | <el-button type="primary" size="mini" @click="handleSearch">查询</el-button> |
| 40 | - <el-button v-if="loadingModel.flightno === undefined && loadingData.length <1" | 40 | + <el-button v-if="loadingQuery.flightno === undefined && loadingData.length <1" |
| 41 | type="primary" size="mini" @click="handleAddLoading">新增装载 | 41 | type="primary" size="mini" @click="handleAddLoading">新增装载 |
| 42 | </el-button> | 42 | </el-button> |
| 43 | </div> | 43 | </div> |
| @@ -51,11 +51,16 @@ | @@ -51,11 +51,16 @@ | ||
| 51 | </el-row> | 51 | </el-row> |
| 52 | <tree-table v-loading="listLoading" :data="loadingData" :eval-func="func" :expand-all="true" stripe | 52 | <tree-table v-loading="listLoading" :data="loadingData" :eval-func="func" :expand-all="true" stripe |
| 53 | style="font-size: 12px" border @selection-change="handleSelectionChange"> | 53 | style="font-size: 12px" border @selection-change="handleSelectionChange"> |
| 54 | - <el-table-column label="运单号" width="160" align="center"> | 54 | + <el-table-column label="主单号" width="160" align="center"> |
| 55 | <template slot-scope="scope"> | 55 | <template slot-scope="scope"> |
| 56 | <span>{{scope.row.awba}}</span> | 56 | <span>{{scope.row.awba}}</span> |
| 57 | </template> | 57 | </template> |
| 58 | </el-table-column> | 58 | </el-table-column> |
| 59 | + <!--<el-table-column label="分单号" width="160" align="center">--> | ||
| 60 | + <!--<template slot-scope="scope">--> | ||
| 61 | + <!--<span>{{scope.row.awbh}}</span>--> | ||
| 62 | + <!--</template>--> | ||
| 63 | + <!--</el-table-column>--> | ||
| 59 | <el-table-column label="运载件数" width="70" align="center"> | 64 | <el-table-column label="运载件数" width="70" align="center"> |
| 60 | <template slot-scope="scope"> | 65 | <template slot-scope="scope"> |
| 61 | <span>{{scope.row.lodingpiece}}</span> | 66 | <span>{{scope.row.lodingpiece}}</span> |
| @@ -102,26 +107,30 @@ | @@ -102,26 +107,30 @@ | ||
| 102 | <el-table-column prop="operation" label="操作" align="center"> | 107 | <el-table-column prop="operation" label="操作" align="center"> |
| 103 | <template slot-scope="scope"> | 108 | <template slot-scope="scope"> |
| 104 | <el-button size="mini" @click="handleSend(scope.row)">收发明细</el-button> | 109 | <el-button size="mini" @click="handleSend(scope.row)">收发明细</el-button> |
| 105 | - <el-button size="mini" type="success" @click="handleEdit(scope.row)">编辑主单 | 110 | + <el-button size="mini" type="success" @click="handleEdit(scope.row)" :disabled="scope.row.status !=='01'">编辑 |
| 106 | </el-button> | 111 | </el-button> |
| 107 | <el-button size="mini" type="primary" @click="handleSendAwb(scope.row)" | 112 | <el-button size="mini" type="primary" @click="handleSendAwb(scope.row)" |
| 108 | :disabled="scope.row.status !=='00'">发送舱单报 | 113 | :disabled="scope.row.status !=='00'">发送舱单报 |
| 109 | </el-button> | 114 | </el-button> |
| 110 | - <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单</el-button> | 115 | + <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单 |
| 116 | + </el-button> | ||
| 111 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" | 117 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" |
| 112 | :disabled="scope.row.status ==='00'">更改状态 | 118 | :disabled="scope.row.status ==='00'">更改状态 |
| 113 | </el-button> | 119 | </el-button> |
| 120 | + <el-button size="mini" type="danger" @click="handleSendDelete(scope.row)">发删除报</el-button> | ||
| 114 | </template> | 121 | </template> |
| 115 | </el-table-column> | 122 | </el-table-column> |
| 116 | </tree-table> | 123 | </tree-table> |
| 117 | <div class="btnFoot"> | 124 | <div class="btnFoot"> |
| 118 | <el-row> | 125 | <el-row> |
| 119 | <el-button type="primary" size="mini" | 126 | <el-button type="primary" size="mini" |
| 120 | - v-if="loadingModel.flightno !== undefined || loadingData.length >0" | 127 | + v-if="loadingQuery.flightno !== undefined || loadingData.length >0" |
| 121 | @click="handelAddLoadingInfo">新增出港装载 | 128 | @click="handelAddLoadingInfo">新增出港装载 |
| 122 | </el-button> | 129 | </el-button> |
| 123 | - <el-button type="primary" size="mini" v-if="loadingModel.flightno !== undefined || loadingData.length>0" | ||
| 124 | - @click="handelBackStep">返回</el-button> | 130 | + <el-button type="primary" size="mini" |
| 131 | + v-if="loadingQuery.flightno !== undefined || loadingData.length>0" | ||
| 132 | + @click="handelBackStep">返回 | ||
| 133 | + </el-button> | ||
| 125 | </el-row> | 134 | </el-row> |
| 126 | </div> | 135 | </div> |
| 127 | <pagination v-show="total>0" :total="total" :page.sync="loadingQuery.page" :limit.sync="loadingQuery.limit" | 136 | <pagination v-show="total>0" :total="total" :page.sync="loadingQuery.page" :limit.sync="loadingQuery.limit" |
| @@ -155,13 +164,26 @@ | @@ -155,13 +164,26 @@ | ||
| 155 | 164 | ||
| 156 | <el-col :span="7.5"> | 165 | <el-col :span="7.5"> |
| 157 | <el-form-item label="起始站" prop="originstation"> | 166 | <el-form-item label="起始站" prop="originstation"> |
| 158 | - <el-input v-model="originstation" | ||
| 159 | - :disabled="dialogStatus ==='update'"></el-input> | 167 | + <el-select filterable clearable placeholder="请选择起始站" allow-create v-model="loadingModel.originstation"> |
| 168 | + <el-option v-for="item in airportCode" | ||
| 169 | + :key="item.airportid" :label="item.airportid" | ||
| 170 | + :value="item.airportid" :disabled="dialogStatus === 'update'"> | ||
| 171 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 172 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 173 | + </el-option> | ||
| 174 | + </el-select> | ||
| 160 | </el-form-item> | 175 | </el-form-item> |
| 161 | </el-col> | 176 | </el-col> |
| 162 | <el-col :span="7.5"> | 177 | <el-col :span="7.5"> |
| 163 | - <el-form-item label="目的站" prop="flightno"> | ||
| 164 | - <el-input v-model="destinationstation" :disabled="dialogStatus ==='update'"></el-input> | 178 | + <el-form-item label="目的站" prop="originstation"> |
| 179 | + <el-select filterable clearable placeholder="请选择起始站" allow-create v-model="loadingModel.destinationstation"> | ||
| 180 | + <el-option v-for="item in airportCode" | ||
| 181 | + :key="item.airportid" :label="item.airportid" | ||
| 182 | + :value="item.airportid" :disabled="dialogStatus === 'update'"> | ||
| 183 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 184 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 185 | + </el-option> | ||
| 186 | + </el-select> | ||
| 165 | </el-form-item> | 187 | </el-form-item> |
| 166 | </el-col> | 188 | </el-col> |
| 167 | <el-col :span="7.5"> | 189 | <el-col :span="7.5"> |
| @@ -206,9 +228,13 @@ | @@ -206,9 +228,13 @@ | ||
| 206 | </el-col> | 228 | </el-col> |
| 207 | <el-col :span="7.5"> | 229 | <el-col :span="7.5"> |
| 208 | <el-form-item label="海关关区" prop="customcode"> | 230 | <el-form-item label="海关关区" prop="customcode"> |
| 209 | - <el-select v-model="loadingModel.customcode"> | ||
| 210 | - <el-option v-for="item in customcodeList " :key="item" :label="item" | ||
| 211 | - :value="item"></el-option> | 231 | + <el-select v-model="loadingModel.customcode" placeholder="请选择关区代码" filterable clearable |
| 232 | + :disabled="dialogStatus === 'addAwbh'"> | ||
| 233 | + <el-option v-for="item in customCodeList" :key="item.customcode" :label="item.customcode" | ||
| 234 | + :value="item.customcode"> | ||
| 235 | + <span style="float: left">{{ item.customcode }}</span> | ||
| 236 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.customname }}</span> | ||
| 237 | + </el-option> | ||
| 212 | </el-select> | 238 | </el-select> |
| 213 | </el-form-item> | 239 | </el-form-item> |
| 214 | </el-col> | 240 | </el-col> |
| @@ -229,7 +255,6 @@ | @@ -229,7 +255,6 @@ | ||
| 229 | <div slot="footer" class="dialog-footer"> | 255 | <div slot="footer" class="dialog-footer"> |
| 230 | <el-button @click="dialogFormVisible = false">取消</el-button> | 256 | <el-button @click="dialogFormVisible = false">取消</el-button> |
| 231 | <el-button type="primary" @click="dialogStatus==='create'?createData():updateData()">保存</el-button> | 257 | <el-button type="primary" @click="dialogStatus==='create'?createData():updateData()">保存</el-button> |
| 232 | - <el-button type="success" @click="handleSaveAndSend">保存并发送</el-button> | ||
| 233 | </div> | 258 | </div> |
| 234 | </el-dialog> | 259 | </el-dialog> |
| 235 | <el-dialog title="收发明细" :visible.sync="dialogTableVisible"> | 260 | <el-dialog title="收发明细" :visible.sync="dialogTableVisible"> |
| @@ -271,6 +296,27 @@ | @@ -271,6 +296,27 @@ | ||
| 271 | </el-table-column> | 296 | </el-table-column> |
| 272 | </el-table> | 297 | </el-table> |
| 273 | </el-dialog> | 298 | </el-dialog> |
| 299 | + <el-dialog title="删除原因" :visible.sync="dialogDeleteVisible" width="30%"> | ||
| 300 | + <el-form ref="loadingDeleteForm" :model="respModel" :rules="loadingDeleteRules" | ||
| 301 | + label-width="120px" style="margin-right: 50px"> | ||
| 302 | + <el-form-item label="删除原因" prop="reason"> | ||
| 303 | + <el-input v-model="respModel.reason" placeholder="删除原因"></el-input> | ||
| 304 | + </el-form-item> | ||
| 305 | + <el-form-item label="删除操作人" prop="contactName"> | ||
| 306 | + <el-input v-model="respModel.contactName" placeholder="操作人姓名"></el-input> | ||
| 307 | + </el-form-item> | ||
| 308 | + <el-form-item label="操作人Tel" prop="contactTel"> | ||
| 309 | + <el-input v-model="respModel.contactTel" placeholder="删除操作人联系方式"></el-input> | ||
| 310 | + </el-form-item> | ||
| 311 | + <el-form-item label="备注"> | ||
| 312 | + <el-input v-model="respModel.content" type="textarea"></el-input> | ||
| 313 | + </el-form-item> | ||
| 314 | + </el-form> | ||
| 315 | + <div slot="footer" class="dialog-footer"> | ||
| 316 | + <el-button @click="dialogDeleteVisible = false">取消</el-button> | ||
| 317 | + <el-button type="primary" @click="sendLoadingDelete()">发送</el-button> | ||
| 318 | + </div> | ||
| 319 | + </el-dialog> | ||
| 274 | </div> | 320 | </div> |
| 275 | </div> | 321 | </div> |
| 276 | </template> | 322 | </template> |
| @@ -278,9 +324,20 @@ | @@ -278,9 +324,20 @@ | ||
| 278 | import treeTable from '@/components/TreeTable' | 324 | import treeTable from '@/components/TreeTable' |
| 279 | import treeToArray from '@/utils/customEval' | 325 | import treeToArray from '@/utils/customEval' |
| 280 | import Pagination from '@/components/Pagination' | 326 | import Pagination from '@/components/Pagination' |
| 281 | - import {getMt4201ListForParam, deleteByIsDelete, updateStatus, updateMT4201, addMt4201} from '@/api/exitLoading' | 327 | + import {getCustomCode,getAirportCode} from "@/api/country"; |
| 328 | + import { | ||
| 329 | + getMt4201ListForParam, deleteByIsDelete, updateStatus, | ||
| 330 | + updateMT4201, addMt4201, sendCreateMt4201, sendDeleteMt4201 | ||
| 331 | + } from '@/api/exitLoading' | ||
| 282 | import {Message} from "element-ui"; | 332 | import {Message} from "element-ui"; |
| 283 | - import {validAwb, validAlphabets, validAlphabetsAndNum, validAlphabetsAndSpanceKey,validatorNum} from "@/utils/validate" | 333 | + import { |
| 334 | + validAwb, | ||
| 335 | + validAlphabets, | ||
| 336 | + validAlphabetsAndNum, | ||
| 337 | + validAlphabetsAndSpanceKey, | ||
| 338 | + validatorNum | ||
| 339 | + } from "@/utils/validate" | ||
| 340 | + | ||
| 284 | export default { | 341 | export default { |
| 285 | name: "ExitLoading", | 342 | name: "ExitLoading", |
| 286 | components: {treeTable, Pagination}, | 343 | components: {treeTable, Pagination}, |
| @@ -304,8 +361,8 @@ | @@ -304,8 +361,8 @@ | ||
| 304 | } | 361 | } |
| 305 | callback() | 362 | callback() |
| 306 | } | 363 | } |
| 307 | - const validAlphabetsSpanceKey = (rule,value,callback) =>{ | ||
| 308 | - if(!validAlphabetsAndSpanceKey(value)){ | 364 | + const validAlphabetsSpanceKey = (rule, value, callback) => { |
| 365 | + if (!validAlphabetsAndSpanceKey(value)) { | ||
| 309 | callback("只能输入字母、数字、空格") | 366 | callback("只能输入字母、数字、空格") |
| 310 | } | 367 | } |
| 311 | callback() | 368 | callback() |
| @@ -319,15 +376,17 @@ | @@ -319,15 +376,17 @@ | ||
| 319 | return { | 376 | return { |
| 320 | func: treeToArray, | 377 | func: treeToArray, |
| 321 | total: 1, | 378 | total: 1, |
| 322 | - isAdmin:false, | 379 | + isAdmin: false, |
| 323 | dialogMap: { | 380 | dialogMap: { |
| 324 | update: '编辑出港装载', | 381 | update: '编辑出港装载', |
| 325 | create: '添加出港装载', | 382 | create: '添加出港装载', |
| 326 | }, | 383 | }, |
| 327 | - customcodeList: [4604, 4620], | 384 | + customCodeList: [], |
| 385 | + airportCode:[], | ||
| 328 | dialogStatus: undefined, | 386 | dialogStatus: undefined, |
| 329 | dialogTableVisible: false, | 387 | dialogTableVisible: false, |
| 330 | dialogFormVisible: false, | 388 | dialogFormVisible: false, |
| 389 | + dialogDeleteVisible: false, | ||
| 331 | listLoading: false, | 390 | listLoading: false, |
| 332 | loadingQuery: { | 391 | loadingQuery: { |
| 333 | pageSize: 1, | 392 | pageSize: 1, |
| @@ -338,7 +397,8 @@ | @@ -338,7 +397,8 @@ | ||
| 338 | flightdate: undefined, | 397 | flightdate: undefined, |
| 339 | originstation: undefined, | 398 | originstation: undefined, |
| 340 | destinationstation: undefined, | 399 | destinationstation: undefined, |
| 341 | - customcode: undefined | 400 | + customcode: undefined, |
| 401 | + messageType: undefined | ||
| 342 | }, | 402 | }, |
| 343 | loadingRoles: { | 403 | loadingRoles: { |
| 344 | awba: [{required: true, trigger: 'blur', validator: validatorAwb}], | 404 | awba: [{required: true, trigger: 'blur', validator: validatorAwb}], |
| @@ -350,12 +410,12 @@ | @@ -350,12 +410,12 @@ | ||
| 350 | destinationstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], | 410 | destinationstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], |
| 351 | piece: [{type: 'number', required: true, trigger: 'change', message: '只能输入数字'}], | 411 | piece: [{type: 'number', required: true, trigger: 'change', message: '只能输入数字'}], |
| 352 | weight: [{type: 'number', required: true, trigger: 'change', message: '只能输入数字'}], | 412 | weight: [{type: 'number', required: true, trigger: 'change', message: '只能输入数字'}], |
| 353 | - customcode:[{required: true, trigger: 'change',message:'不能为空'}] | 413 | + customcode: [{required: true, trigger: 'change', message: '不能为空'}] |
| 354 | }, | 414 | }, |
| 355 | loadingData: [], | 415 | loadingData: [], |
| 356 | detailData: [], | 416 | detailData: [], |
| 357 | loadingModel: { | 417 | loadingModel: { |
| 358 | - carrier:undefined, | 418 | + carrier: undefined, |
| 359 | flightno: undefined, | 419 | flightno: undefined, |
| 360 | flightdate: undefined, | 420 | flightdate: undefined, |
| 361 | originstation: undefined, | 421 | originstation: undefined, |
| @@ -369,8 +429,29 @@ | @@ -369,8 +429,29 @@ | ||
| 369 | loadingtime: undefined, | 429 | loadingtime: undefined, |
| 370 | messageType: 'MT4201', | 430 | messageType: 'MT4201', |
| 371 | awbprice: undefined, | 431 | awbprice: undefined, |
| 372 | - awbweight: undefined | ||
| 373 | - } | 432 | + awbweight: undefined, |
| 433 | + reason: undefined, | ||
| 434 | + contactName: undefined, | ||
| 435 | + contactTel: undefined, | ||
| 436 | + content: undefined, | ||
| 437 | + }, | ||
| 438 | + respModel: { | ||
| 439 | + uuid: undefined, | ||
| 440 | + reason: undefined, | ||
| 441 | + contactName: undefined, | ||
| 442 | + contactTel: undefined, | ||
| 443 | + content: '', | ||
| 444 | + flightNo: undefined, | ||
| 445 | + awba: undefined, | ||
| 446 | + customCode: undefined, | ||
| 447 | + flightDate: undefined, | ||
| 448 | + awbh: '' | ||
| 449 | + }, | ||
| 450 | + loadingDeleteRules: { | ||
| 451 | + reason: [{required: true, message: '删除原因不能为空', trigger: 'blur'}], | ||
| 452 | + contactName: [{required: true, message: '删除操作人不能为空', trigger: 'blur'}], | ||
| 453 | + contactTel: [{required: true, message: '操作人联系方式不能为空', trigger: 'blur'}] | ||
| 454 | + }, | ||
| 374 | } | 455 | } |
| 375 | }, | 456 | }, |
| 376 | created() { | 457 | created() { |
| @@ -386,8 +467,10 @@ | @@ -386,8 +467,10 @@ | ||
| 386 | this.loadingQuery.destinationstation = this.$route.params.flightData.destinationstation | 467 | this.loadingQuery.destinationstation = this.$route.params.flightData.destinationstation |
| 387 | this.getList() | 468 | this.getList() |
| 388 | } | 469 | } |
| 470 | + this.getAirportCode() | ||
| 471 | + this.getCustomCode() | ||
| 389 | let username = JSON.parse(sessionStorage.getItem('user')).username | 472 | let username = JSON.parse(sessionStorage.getItem('user')).username |
| 390 | - if(username === 'admin'){ | 473 | + if (username === 'admin') { |
| 391 | this.isAdmin = true | 474 | this.isAdmin = true |
| 392 | } | 475 | } |
| 393 | }, | 476 | }, |
| @@ -494,7 +577,6 @@ | @@ -494,7 +577,6 @@ | ||
| 494 | // 编辑 弹框 | 577 | // 编辑 弹框 |
| 495 | handleEdit(row) { | 578 | handleEdit(row) { |
| 496 | this.loadingModel = Object.assign({}, row) | 579 | this.loadingModel = Object.assign({}, row) |
| 497 | - console.log(this.loadingModel) | ||
| 498 | this.dialogStatus = 'update' | 580 | this.dialogStatus = 'update' |
| 499 | this.dialogFormVisible = true | 581 | this.dialogFormVisible = true |
| 500 | this.$nextTick(() => { | 582 | this.$nextTick(() => { |
| @@ -519,10 +601,75 @@ | @@ -519,10 +601,75 @@ | ||
| 519 | }, | 601 | }, |
| 520 | 602 | ||
| 521 | // 发送舱单报 | 603 | // 发送舱单报 |
| 522 | - handleSendAwb() { | 604 | + handleSendAwb(row) { |
| 523 | 605 | ||
| 606 | + this.$confirm("是否发送", "确认消息", { | ||
| 607 | + distinguishCancelAndClose: true, | ||
| 608 | + confirmButtonText: '发送', | ||
| 609 | + cancelButtonText: '取消' | ||
| 610 | + }).then(() => { | ||
| 611 | + if(row.awbh === null || row.awbh === undefined){ | ||
| 612 | + row.awbh = '' | ||
| 613 | + } | ||
| 614 | + sendCreateMt4201(row).then(res => { | ||
| 615 | + if (res.data.count > 0) { | ||
| 616 | + Message.success(res.data.respMessage) | ||
| 617 | + this.getList() | ||
| 618 | + }else { | ||
| 619 | + Message.success(res.data.respMessage) | ||
| 620 | + } | ||
| 621 | + }) | ||
| 622 | + }).catch(error =>{ | ||
| 623 | + Message.error(error.message) | ||
| 624 | + }) | ||
| 524 | }, | 625 | }, |
| 525 | - // 删除 发送删除报 | 626 | + |
| 627 | + // 发送删除报 | ||
| 628 | + handleSendDelete(row) { | ||
| 629 | + this.respModel = { | ||
| 630 | + uuid: undefined, | ||
| 631 | + reason: undefined, | ||
| 632 | + contactName: undefined, | ||
| 633 | + contactTel: undefined, | ||
| 634 | + content: '', | ||
| 635 | + flightNo: undefined, | ||
| 636 | + awba: undefined, | ||
| 637 | + customCode: undefined, | ||
| 638 | + flightDate: undefined, | ||
| 639 | + awbh: '' | ||
| 640 | + } | ||
| 641 | + this.dialogDeleteVisible = true | ||
| 642 | + this.respModel.uuid = row.uuid | ||
| 643 | + this.respModel.flightNo = row.carrier + row.flightno | ||
| 644 | + this.respModel.awba = row.awba | ||
| 645 | + this.respModel.customCode = row.customcode | ||
| 646 | + this.respModel.flightDate = row.flightdate | ||
| 647 | + if(row.awbh ===null){ | ||
| 648 | + this.respModel.awbh = '' | ||
| 649 | + }else { | ||
| 650 | + this.respModel.awbh = row.awbh | ||
| 651 | + } | ||
| 652 | + this.$nextTick(() => { | ||
| 653 | + this.$refs.loadingDeleteForm.clearValidate() | ||
| 654 | + }) | ||
| 655 | + }, | ||
| 656 | + | ||
| 657 | + sendLoadingDelete() { | ||
| 658 | + this.$refs.loadingDeleteForm.validate(valid => { | ||
| 659 | + if (valid) { | ||
| 660 | + sendDeleteMt4201(this.respModel).then(res => { | ||
| 661 | + if (res.data.count > 0) { | ||
| 662 | + Message.success(res.data.respMessage) | ||
| 663 | + this.dialogDeleteVisible = false | ||
| 664 | + this.getList() | ||
| 665 | + } else { | ||
| 666 | + Message.success(res.data.respMessage) | ||
| 667 | + } | ||
| 668 | + }) | ||
| 669 | + } | ||
| 670 | + }) | ||
| 671 | + }, | ||
| 672 | + // 删除 | ||
| 526 | handleAwbDelete(row) { | 673 | handleAwbDelete(row) { |
| 527 | this.$confirm("是否删除", "确认消息", { | 674 | this.$confirm("是否删除", "确认消息", { |
| 528 | distinguishCancelAndClose: true, | 675 | distinguishCancelAndClose: true, |
| @@ -583,14 +730,10 @@ | @@ -583,14 +730,10 @@ | ||
| 583 | }) | 730 | }) |
| 584 | }) | 731 | }) |
| 585 | }, | 732 | }, |
| 586 | - // 保存并发送 | ||
| 587 | - handleSaveAndSend() { | ||
| 588 | - | ||
| 589 | - }, | ||
| 590 | // 重置实体 | 733 | // 重置实体 |
| 591 | restModel() { | 734 | restModel() { |
| 592 | this.loadingModel = { | 735 | this.loadingModel = { |
| 593 | - carrier:undefined, | 736 | + carrier: undefined, |
| 594 | flightno: undefined, | 737 | flightno: undefined, |
| 595 | flightdate: undefined, | 738 | flightdate: undefined, |
| 596 | originstation: undefined, | 739 | originstation: undefined, |
| @@ -639,6 +782,16 @@ | @@ -639,6 +782,16 @@ | ||
| 639 | } | 782 | } |
| 640 | }) | 783 | }) |
| 641 | }, | 784 | }, |
| 785 | + getAirportCode(){ | ||
| 786 | + getAirportCode().then(res=>{ | ||
| 787 | + this.airportCode = res.data.data | ||
| 788 | + }) | ||
| 789 | + }, | ||
| 790 | + getCustomCode(){ | ||
| 791 | + getCustomCode().then(res =>{ | ||
| 792 | + this.customCodeList = res.data.data | ||
| 793 | + }) | ||
| 794 | + }, | ||
| 642 | handleAddLoading() { | 795 | handleAddLoading() { |
| 643 | const row = { | 796 | const row = { |
| 644 | 'messageType': 'MT4201' | 797 | 'messageType': 'MT4201' |
| @@ -646,7 +799,8 @@ | @@ -646,7 +799,8 @@ | ||
| 646 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) | 799 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) |
| 647 | }, | 800 | }, |
| 648 | handelBackStep() { | 801 | handelBackStep() { |
| 649 | - this.$router.push({name: '出港航班信息', params: {scopeRow: this.loadingModel}}) | 802 | + this.loadingQuery.messageType = 'MT4201' |
| 803 | + this.$router.push({name: '出港航班信息', params: {scopeRow: this.loadingQuery}}) | ||
| 650 | } | 804 | } |
| 651 | } | 805 | } |
| 652 | } | 806 | } |
| @@ -212,6 +212,7 @@ | @@ -212,6 +212,7 @@ | ||
| 212 | 212 | ||
| 213 | }, | 213 | }, |
| 214 | handleUpdate(row){ | 214 | handleUpdate(row){ |
| 215 | + console.log(row.messageType ) | ||
| 215 | if(row.messageType === 'MT2201'){ | 216 | if(row.messageType === 'MT2201'){ |
| 216 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) | 217 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) |
| 217 | } | 218 | } |
| @@ -221,7 +222,7 @@ | @@ -221,7 +222,7 @@ | ||
| 221 | if(row.messageType === 'MT4201'){ | 222 | if(row.messageType === 'MT4201'){ |
| 222 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) | 223 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) |
| 223 | } | 224 | } |
| 224 | - if(row.messageType === 'MT5201'){ | 225 | + if(row.messageType === 'MT5202'){ |
| 225 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) | 226 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) |
| 226 | } | 227 | } |
| 227 | }, | 228 | }, |
| @@ -13,9 +13,9 @@ | @@ -13,9 +13,9 @@ | ||
| 13 | </el-col> | 13 | </el-col> |
| 14 | <el-col :span="20"> | 14 | <el-col :span="20"> |
| 15 | <div class="grid-content"> | 15 | <div class="grid-content"> |
| 16 | - <span class="titleSpan">航班号:{{this.listQuery.carrier}}{{this.listQuery.flightNo}}</span> | ||
| 17 | - <span class="titleSpan">航班日期:{{this.listQuery.flightDate}}</span> | ||
| 18 | - <span class="titleSpan">航段:{{this.listQuery.originStation}}-{{this.listQuery.destinationStation}}</span> | 16 | + <span class="titleSpan">航班号:{{this.preQuery.carrier}}{{this.preQuery.flightno}}</span> |
| 17 | + <span class="titleSpan">航班日期:{{this.preQuery.flightdate}}</span> | ||
| 18 | + <span class="titleSpan">航段:{{this.preQuery.originstation}}-{{this.preQuery.destinationstation}}</span> | ||
| 19 | </div> | 19 | </div> |
| 20 | </el-col> | 20 | </el-col> |
| 21 | </div> | 21 | </div> |
| @@ -32,12 +32,12 @@ | @@ -32,12 +32,12 @@ | ||
| 32 | <div class="grid-content"> | 32 | <div class="grid-content"> |
| 33 | <el-col :span="4"> | 33 | <el-col :span="4"> |
| 34 | <div class="grid-content"> | 34 | <div class="grid-content"> |
| 35 | - <el-input v-model="listQuery.awba" placeholder="请输入主单号" clearable></el-input> | 35 | + <el-input v-model="preQuery.awba" placeholder="请输入主单号" clearable></el-input> |
| 36 | </div> | 36 | </div> |
| 37 | </el-col> | 37 | </el-col> |
| 38 | <div class="grid-content el-btn"> | 38 | <div class="grid-content el-btn"> |
| 39 | <el-button type="primary" size="mini" @click="handleSerach">查询</el-button> | 39 | <el-button type="primary" size="mini" @click="handleSerach">查询</el-button> |
| 40 | - <el-button v-if="preModel.flightno === undefined && preData.length<1" type="primary" | 40 | + <el-button v-if="preQuery.flightno === undefined && preData.length<1" type="primary" |
| 41 | size="mini" | 41 | size="mini" |
| 42 | @click="handleAddpre">新增预配舱单 | 42 | @click="handleAddpre">新增预配舱单 |
| 43 | </el-button> | 43 | </el-button> |
| @@ -87,15 +87,16 @@ | @@ -87,15 +87,16 @@ | ||
| 87 | {{scope.row.actime}} | 87 | {{scope.row.actime}} |
| 88 | </template> | 88 | </template> |
| 89 | </el-table-column> | 89 | </el-table-column> |
| 90 | - <el-table-column label="代理人代码" width="120" align="center"> | ||
| 91 | - <template slot-scope="scope"> | ||
| 92 | - {{scope.row.status}} | ||
| 93 | - </template> | ||
| 94 | - </el-table-column> | 90 | + <!--<el-table-column label="代理人代码" width="120" align="center">--> |
| 91 | + <!--<template slot-scope="scope">--> | ||
| 92 | + <!--{{scope.row.status}}--> | ||
| 93 | + <!--</template>--> | ||
| 94 | + <!--</el-table-column>--> | ||
| 95 | <el-table-column label="状态" width="100" align="center"> | 95 | <el-table-column label="状态" width="100" align="center"> |
| 96 | <template slot-scope="scope"> | 96 | <template slot-scope="scope"> |
| 97 | <span v-if="scope.row.status ==='01'">未发送</span> | 97 | <span v-if="scope.row.status ==='01'">未发送</span> |
| 98 | <span v-if="scope.row.status ==='02'">已发舱单报</span> | 98 | <span v-if="scope.row.status ==='02'">已发舱单报</span> |
| 99 | + <span v-if="scope.row.status ==='04'">已发送</span> | ||
| 99 | <span v-if="scope.row.status ==='05'">舱单报退单</span> | 100 | <span v-if="scope.row.status ==='05'">舱单报退单</span> |
| 100 | <span v-if="scope.row.status ==='06'">舱单转人工</span> | 101 | <span v-if="scope.row.status ==='06'">舱单转人工</span> |
| 101 | <span v-if="scope.row.status ==='07'">舱单报申报成功</span> | 102 | <span v-if="scope.row.status ==='07'">舱单报申报成功</span> |
| @@ -116,9 +117,9 @@ | @@ -116,9 +117,9 @@ | ||
| 116 | <el-button size="mini" @click="handleSend(scope.row)">收发明细</el-button> | 117 | <el-button size="mini" @click="handleSend(scope.row)">收发明细</el-button> |
| 117 | </template> | 118 | </template> |
| 118 | </el-table-column> | 119 | </el-table-column> |
| 119 | - <el-table-column label="操作" width="300"> | 120 | + <el-table-column label="操作" width="450"> |
| 120 | <template slot-scope="scope"> | 121 | <template slot-scope="scope"> |
| 121 | - <el-button size="mini" type="success" @click="handleEdit(scope.row)">编辑运单</el-button> | 122 | + <el-button size="mini" type="success" @click="handleEdit(scope.row)" :disabled="scope.row.status !=='01'">编辑</el-button> |
| 122 | <el-button size="mini" type="success" v-if="scope.row.awbh ===null" | 123 | <el-button size="mini" type="success" v-if="scope.row.awbh ===null" |
| 123 | @click="handleAddAwbh(scope.row)">新增分单 | 124 | @click="handleAddAwbh(scope.row)">新增分单 |
| 124 | </el-button> | 125 | </el-button> |
| @@ -127,25 +128,26 @@ | @@ -127,25 +128,26 @@ | ||
| 127 | </el-button> | 128 | </el-button> |
| 128 | <p></p> | 129 | <p></p> |
| 129 | <el-button size="mini" type="primary" @click="handleAwbEdit(scope.row)">发修改报</el-button> | 130 | <el-button size="mini" type="primary" @click="handleAwbEdit(scope.row)">发修改报</el-button> |
| 130 | - | ||
| 131 | - <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单</el-button> | 131 | + <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单 |
| 132 | + </el-button> | ||
| 132 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" | 133 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" |
| 133 | :disabled="scope.row.status === '01'">更改状态 | 134 | :disabled="scope.row.status === '01'">更改状态 |
| 134 | </el-button> | 135 | </el-button> |
| 136 | + <el-button size="mini" type="danger" @click="handleSendDelete(scope.row)">发删除报</el-button> | ||
| 135 | </template> | 137 | </template> |
| 136 | </el-table-column> | 138 | </el-table-column> |
| 137 | </tree-table> | 139 | </tree-table> |
| 138 | <div class="btnFoot"> | 140 | <div class="btnFoot"> |
| 139 | <el-row> | 141 | <el-row> |
| 140 | - <el-button type="primary" size="mini" v-if="preData.flightno !== undefined || preData.length> 0" | 142 | + <el-button type="primary" size="mini" v-if="preQuery.flightno !== undefined | preData.length > 0" |
| 141 | @click="handleAddpreInfo">新增预配舱单 | 143 | @click="handleAddpreInfo">新增预配舱单 |
| 142 | </el-button> | 144 | </el-button> |
| 143 | <el-button type="primary" size="mini" @click="handelBackStep" | 145 | <el-button type="primary" size="mini" @click="handelBackStep" |
| 144 | - v-if="preModel.flightno !== undefined || preData.length >0">返回 | 146 | + v-if="preQuery.flightno !== undefined || preData.length >0">返回 |
| 145 | </el-button> | 147 | </el-button> |
| 146 | </el-row> | 148 | </el-row> |
| 147 | </div> | 149 | </div> |
| 148 | - <pagination v-show="total>0" :total="total" :page.sync="listQuery.pageSize" :limit.sync="listQuery.limitSize" | 150 | + <pagination v-show="total>0" :total="total" :page.sync="preQuery.pageSize" :limit.sync="preQuery.limitSize" |
| 149 | @pagination="getList"/> | 151 | @pagination="getList"/> |
| 150 | <el-dialog :title="dialogMap[dialogStatus]" :visible.sync="dialogFormVisible" width="60%"> | 152 | <el-dialog :title="dialogMap[dialogStatus]" :visible.sync="dialogFormVisible" width="60%"> |
| 151 | <el-form ref="preFormData" :model="preModel" :rules="preRoles" label-position="right" | 153 | <el-form ref="preFormData" :model="preModel" :rules="preRoles" label-position="right" |
| @@ -192,12 +194,27 @@ | @@ -192,12 +194,27 @@ | ||
| 192 | <el-row> | 194 | <el-row> |
| 193 | <el-col :span="7.5"> | 195 | <el-col :span="7.5"> |
| 194 | <el-form-item label="起始站" prop="originstation"> | 196 | <el-form-item label="起始站" prop="originstation"> |
| 195 | - <el-input v-model="originstation" :disabled="dialogStatus === 'addAwbh'" clearable/> | 197 | + <el-select filterable clearable placeholder="请选择起始站" allow-create v-model="preModel.originstation"> |
| 198 | + <el-option v-for="item in airportCode" | ||
| 199 | + :key="item.airportid" :label="item.airportid" | ||
| 200 | + :value="item.airportid" :disabled="dialogStatus === 'addAwbh'"> | ||
| 201 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 202 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 203 | + </el-option> | ||
| 204 | + </el-select> | ||
| 205 | + <!--<el-input v-model="preModel.originstation" :disabled="dialogStatus === 'addAwbh'" clearable/>--> | ||
| 196 | </el-form-item> | 206 | </el-form-item> |
| 197 | </el-col> | 207 | </el-col> |
| 198 | <el-col :span="7.5"> | 208 | <el-col :span="7.5"> |
| 199 | <el-form-item label="目的站" prop="destinationstation"> | 209 | <el-form-item label="目的站" prop="destinationstation"> |
| 200 | - <el-input v-model="destinationstation" :disabled="dialogStatus === 'addAwbh'" clearable/> | 210 | + <el-select filterable clearable placeholder="请选择目的站" allow-create v-model="preModel.destinationstation"> |
| 211 | + <el-option v-for="item in airportCode" | ||
| 212 | + :key="item.airportid" :label="item.airportid" | ||
| 213 | + :value="item.airportid" :disabled="dialogStatus === 'addAwbh'" > | ||
| 214 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 215 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 216 | + </el-option> | ||
| 217 | + </el-select> | ||
| 201 | </el-form-item> | 218 | </el-form-item> |
| 202 | </el-col> | 219 | </el-col> |
| 203 | </el-row> | 220 | </el-row> |
| @@ -306,16 +323,19 @@ | @@ -306,16 +323,19 @@ | ||
| 306 | <el-row> | 323 | <el-row> |
| 307 | <el-col :span="7.5"> | 324 | <el-col :span="7.5"> |
| 308 | <el-form-item label="关区代码" prop="customcode"> | 325 | <el-form-item label="关区代码" prop="customcode"> |
| 309 | - <el-select v-model="preModel.customcode" class="filter-item" placeholder="请选择关区代码" | 326 | + <el-select v-model="preModel.customcode" placeholder="请选择关区代码" filterable clearable |
| 310 | :disabled="dialogStatus === 'addAwbh'"> | 327 | :disabled="dialogStatus === 'addAwbh'"> |
| 311 | - <el-option v-for="item in customcodeList" :key="item.value" :label="item.label" | ||
| 312 | - :value="item.value"></el-option> | 328 | + <el-option v-for="item in customCodeList" :key="item.customcode" :label="item.customcode" |
| 329 | + :value="item.customcode"> | ||
| 330 | + <span style="float: left">{{ item.customcode }}</span> | ||
| 331 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.customname }}</span> | ||
| 332 | + </el-option> | ||
| 313 | </el-select> | 333 | </el-select> |
| 314 | </el-form-item> | 334 | </el-form-item> |
| 315 | </el-col> | 335 | </el-col> |
| 316 | <el-col :span="7.5"> | 336 | <el-col :span="7.5"> |
| 317 | <el-form-item label="海关状态"> | 337 | <el-form-item label="海关状态"> |
| 318 | - <el-select v-model="preModel.awbtype" class="filter-item" placeholder="请录入货物类型"> | 338 | + <el-select v-model="preModel.awbinfo.awbtype" class="filter-item" placeholder="请录入货物类型"> |
| 319 | <el-option v-for="item in customTypes" :key="item.value" :label="item.label" | 339 | <el-option v-for="item in customTypes" :key="item.value" :label="item.label" |
| 320 | :value="item.value"/> | 340 | :value="item.value"/> |
| 321 | </el-select> | 341 | </el-select> |
| @@ -520,11 +540,35 @@ | @@ -520,11 +540,35 @@ | ||
| 520 | <!--</el-form-item>--> | 540 | <!--</el-form-item>--> |
| 521 | <!--</el-col>--> | 541 | <!--</el-col>--> |
| 522 | </el-row> | 542 | </el-row> |
| 543 | + <div v-show="dialogStatus === 'sendUpdate'"> | ||
| 544 | + <div class="grid-content content"> | ||
| 545 | + 运单信息 | ||
| 546 | + </div> | ||
| 547 | + <el-row> | ||
| 548 | + <el-col :span="7.5"> | ||
| 549 | + <el-form-item label="修改原因" prop="reason"> | ||
| 550 | + <el-input v-model="preModel.reason" clearable/> | ||
| 551 | + </el-form-item> | ||
| 552 | + </el-col> | ||
| 553 | + <el-col :span="7.5"> | ||
| 554 | + <el-form-item label="修改人" prop="contactName"> | ||
| 555 | + <el-input v-model="preModel.contactName" clearable/> | ||
| 556 | + </el-form-item> | ||
| 557 | + </el-col> | ||
| 558 | + <el-col :span="7.5"> | ||
| 559 | + <el-form-item label="修改人Tel" prop="contactTel"> | ||
| 560 | + <el-input v-model="preModel.contactTel" clearable maxlength="5"/> | ||
| 561 | + </el-form-item> | ||
| 562 | + </el-col> | ||
| 563 | + </el-row> | ||
| 564 | + </div> | ||
| 565 | + | ||
| 523 | </el-form> | 566 | </el-form> |
| 524 | <div slot="footer" class="dialog-footer"> | 567 | <div slot="footer" class="dialog-footer"> |
| 525 | <el-button @click="dialogFormVisible = false">取消</el-button> | 568 | <el-button @click="dialogFormVisible = false">取消</el-button> |
| 526 | - <el-button type="primary" @click="dialogStatus !=='create'? createData():updateData()">保存</el-button> | ||
| 527 | - <el-button type="success" @click="handleSaveAndSend">保存并发送</el-button> | 569 | + <el-button type="primary" v-show="dialogStatus!=='sendUpdate'" |
| 570 | + @click="dialogStatus ==='create'? createData():updateData()">保存</el-button> | ||
| 571 | + <el-button type="primary" v-show="dialogStatus==='sendUpdate'" @click="sendUpdate()">发送</el-button> | ||
| 528 | </div> | 572 | </div> |
| 529 | </el-dialog> | 573 | </el-dialog> |
| 530 | <el-dialog title="收发明细" :visible.sync="dialogTableVisible"> | 574 | <el-dialog title="收发明细" :visible.sync="dialogTableVisible"> |
| @@ -566,6 +610,27 @@ | @@ -566,6 +610,27 @@ | ||
| 566 | </el-table-column> | 610 | </el-table-column> |
| 567 | </el-table> | 611 | </el-table> |
| 568 | </el-dialog> | 612 | </el-dialog> |
| 613 | + <el-dialog title="删除原因" :visible.sync="dialogDeleteVisble" width="30%"> | ||
| 614 | + <el-form ref="sendDeleteForm" :model="respModel" :rules="sendDeleteRules" label-width="120px" | ||
| 615 | + style="margin-right:50px;"> | ||
| 616 | + <el-form-item label="删除原因" prop="reason"> | ||
| 617 | + <el-input v-model="respModel.reason" placeholder="删除原因"></el-input> | ||
| 618 | + </el-form-item> | ||
| 619 | + <el-form-item label="删除操作人" prop="contactName"> | ||
| 620 | + <el-input v-model="respModel.contactName" placeholder="操作人姓名"></el-input> | ||
| 621 | + </el-form-item> | ||
| 622 | + <el-form-item label="操作人Tel" prop="contactTel"> | ||
| 623 | + <el-input v-model="respModel.contactTel" placeholder="删除操作人联系方式"></el-input> | ||
| 624 | + </el-form-item> | ||
| 625 | + <el-form-item label="备注"> | ||
| 626 | + <el-input v-model="respModel.content" type="textarea"></el-input> | ||
| 627 | + </el-form-item> | ||
| 628 | + </el-form> | ||
| 629 | + <div slot="footer" class="dialog-footer"> | ||
| 630 | + <el-button @click="dialogDeleteVisble = false">取消</el-button> | ||
| 631 | + <el-button type="primary" @click="sendDelete()">发送</el-button> | ||
| 632 | + </div> | ||
| 633 | + </el-dialog> | ||
| 569 | </div> | 634 | </div> |
| 570 | </template> | 635 | </template> |
| 571 | <script> | 636 | <script> |
| @@ -573,8 +638,17 @@ | @@ -573,8 +638,17 @@ | ||
| 573 | import treeToArray from '@/utils/customEval' | 638 | import treeToArray from '@/utils/customEval' |
| 574 | import Pagination from '@/components/Pagination' | 639 | import Pagination from '@/components/Pagination' |
| 575 | 640 | ||
| 576 | - import {getCountry, getByCountryCode, getByCountryCodeForName} from "@/api/country"; | ||
| 577 | - import {getMt2201ListForParam, deleteByIsDelete, updateStatus, updateMT2201, addMt2201} from '@/api/exitPre' | 641 | + import {getCountry, getByCountryCode, getByCountryCodeForName,getCustomCode,getAirportCode} from "@/api/country"; |
| 642 | + import { | ||
| 643 | + getMt2201ListForParam, | ||
| 644 | + deleteByIsDelete, | ||
| 645 | + updateStatus, | ||
| 646 | + updateMT2201, | ||
| 647 | + addMt2201, | ||
| 648 | + sendCreateMt2201, | ||
| 649 | + sendDeleteMt2201, | ||
| 650 | + sendUpdateMt2201 | ||
| 651 | + } from '@/api/exitPre' | ||
| 578 | import {Message} from "element-ui"; | 652 | import {Message} from "element-ui"; |
| 579 | import {getResponseForParam} from '@/api/responseDetail' | 653 | import {getResponseForParam} from '@/api/responseDetail' |
| 580 | import { | 654 | import { |
| @@ -623,16 +697,17 @@ | @@ -623,16 +697,17 @@ | ||
| 623 | return { | 697 | return { |
| 624 | func: treeToArray, | 698 | func: treeToArray, |
| 625 | total: 1, | 699 | total: 1, |
| 626 | - isAdmin:false, | ||
| 627 | - listQuery: { | 700 | + isAdmin: false, |
| 701 | + preQuery: { | ||
| 628 | pageSize: 1, | 702 | pageSize: 1, |
| 629 | limitSize: 100, | 703 | limitSize: 100, |
| 630 | awba: undefined, | 704 | awba: undefined, |
| 631 | carrier: undefined, | 705 | carrier: undefined, |
| 632 | - flightNo: undefined, | ||
| 633 | - flightDate: undefined, | ||
| 634 | - originStation: undefined, | ||
| 635 | - destinationStation: undefined | 706 | + flightno: undefined, |
| 707 | + flightdate: undefined, | ||
| 708 | + originstation: undefined, | ||
| 709 | + destinationstation: undefined, | ||
| 710 | + messageType: undefined | ||
| 636 | }, | 711 | }, |
| 637 | dialogMap: { | 712 | dialogMap: { |
| 638 | update: '编辑预配舱单', | 713 | update: '编辑预配舱单', |
| @@ -647,9 +722,11 @@ | @@ -647,9 +722,11 @@ | ||
| 647 | {label: '快件', value: '005'}], | 722 | {label: '快件', value: '005'}], |
| 648 | payTypes: [{label: '预付', value: '0'}, {label: '到付', value: '1'}], | 723 | payTypes: [{label: '预付', value: '0'}, {label: '到付', value: '1'}], |
| 649 | splitcodes: [{label: '是', value: 'T'}, {label: '否', value: 'P'}], | 724 | splitcodes: [{label: '是', value: 'T'}, {label: '否', value: 'P'}], |
| 650 | - customcodeList: [{label: '4604', value: '4604'}, {label: '4620', value: '4620'}], | 725 | + customCodeList: [], |
| 726 | + airportCode:[], | ||
| 651 | dialogStatus: undefined, | 727 | dialogStatus: undefined, |
| 652 | dialogTableVisible: false, | 728 | dialogTableVisible: false, |
| 729 | + dialogDeleteVisble: false, | ||
| 653 | listLoading: false, | 730 | listLoading: false, |
| 654 | disabledStatus: false, | 731 | disabledStatus: false, |
| 655 | dialogFormVisible: false, | 732 | dialogFormVisible: false, |
| @@ -673,6 +750,9 @@ | @@ -673,6 +750,9 @@ | ||
| 673 | 'awbinfo.collected': [{required: true, message: '付款方式必选', trigger: 'change'}], | 750 | 'awbinfo.collected': [{required: true, message: '付款方式必选', trigger: 'change'}], |
| 674 | goodsname: [{required: true, trigger: 'change', validator: validAlphabetsSpanceKey}], | 751 | goodsname: [{required: true, trigger: 'change', validator: validAlphabetsSpanceKey}], |
| 675 | ex5: [{required: true, message: '货物描述不能为空', trigger: 'blur'}], | 752 | ex5: [{required: true, message: '货物描述不能为空', trigger: 'blur'}], |
| 753 | + reason:[{required: true, message: '修改原因不能为空', trigger: 'blur'}], | ||
| 754 | + contactName:[{required: true, message: '修改操作人不能为空', trigger: 'blur'}], | ||
| 755 | + contactTel:[{required: true, message: '修改操作人联系方式不能为空', trigger: 'blur'}], | ||
| 676 | 'awbinfo.sairportid': [{required: true, message: '起始航站不能为空', trigger: 'change'}], | 756 | 'awbinfo.sairportid': [{required: true, message: '起始航站不能为空', trigger: 'change'}], |
| 677 | 'awbinfo.shprname': [{required: true, message: '发货人不能为空', trigger: 'change'}], | 757 | 'awbinfo.shprname': [{required: true, message: '发货人不能为空', trigger: 'change'}], |
| 678 | 'awbinfo.shprtel': [{required: true, message: '发货电话不能为空', trigger: 'change'}], | 758 | 'awbinfo.shprtel': [{required: true, message: '发货电话不能为空', trigger: 'change'}], |
| @@ -703,6 +783,9 @@ | @@ -703,6 +783,9 @@ | ||
| 703 | uldNo: undefined, | 783 | uldNo: undefined, |
| 704 | status: undefined, | 784 | status: undefined, |
| 705 | ex5: undefined, | 785 | ex5: undefined, |
| 786 | + reason: undefined, | ||
| 787 | + contactName: undefined, | ||
| 788 | + contactTel: undefined, | ||
| 706 | awbinfo: { | 789 | awbinfo: { |
| 707 | pcs: undefined, | 790 | pcs: undefined, |
| 708 | weight: undefined, | 791 | weight: undefined, |
| @@ -743,6 +826,23 @@ | @@ -743,6 +826,23 @@ | ||
| 743 | awbtype: undefined | 826 | awbtype: undefined |
| 744 | } | 827 | } |
| 745 | }, | 828 | }, |
| 829 | + respModel: { | ||
| 830 | + uuid: undefined, | ||
| 831 | + reason: undefined, | ||
| 832 | + contactName: undefined, | ||
| 833 | + contactTel: undefined, | ||
| 834 | + content: '', | ||
| 835 | + flightNo: undefined, | ||
| 836 | + awba: undefined, | ||
| 837 | + customCode: undefined, | ||
| 838 | + flightDate: undefined, | ||
| 839 | + awbh: '' | ||
| 840 | + }, | ||
| 841 | + sendDeleteRules:{ | ||
| 842 | + reason:[{required:true,message:'删除原因不能为空',trigger:'blur'}], | ||
| 843 | + contactName:[{required:true,message:'删除操作人不能为空',trigger:'blur'}], | ||
| 844 | + contactTel:[{required:true,message:'操作人联系方式不能为空',trigger:'blur'}] | ||
| 845 | + }, | ||
| 746 | preData: [], | 846 | preData: [], |
| 747 | detailData: [] | 847 | detailData: [] |
| 748 | } | 848 | } |
| @@ -757,17 +857,21 @@ | @@ -757,17 +857,21 @@ | ||
| 757 | }, | 857 | }, |
| 758 | created() { | 858 | created() { |
| 759 | if (this.$route.params.flightData !== undefined) { | 859 | if (this.$route.params.flightData !== undefined) { |
| 760 | - this.listQuery.carrier = this.$route.params.flightData.flightno.substring(0, 2) | ||
| 761 | - this.listQuery.flightNo = this.$route.params.flightData.flightno.substring(2) | ||
| 762 | - this.listQuery.flightDate = this.$route.params.flightData.flightdate | ||
| 763 | - this.listQuery.originStation = this.$route.params.flightData.originstation | ||
| 764 | - this.listQuery.destinationStation = this.$route.params.flightData.destinationstation | ||
| 765 | - this.listQuery.awba = this.$route.params.flightData.awba | 860 | + this.preQuery.carrier = this.$route.params.flightData.flightno.substring(0, 2) |
| 861 | + this.preQuery.flightno = this.$route.params.flightData.flightno.substring(2) | ||
| 862 | + this.preQuery.flightdate = this.$route.params.flightData.flightdate | ||
| 863 | + this.preQuery.originstation = this.$route.params.flightData.originstation | ||
| 864 | + this.preQuery.destinationstation = this.$route.params.flightData.destinationstation | ||
| 865 | + if (this.$route.params.flightData.awba !== undefined && this.$route.params.flightData.awba !== '') { | ||
| 866 | + this.preQuery.awba = this.$route.params.flightData.awba.substring(0, 3) + "-" + this.$route.params.flightData.awba.substring(3) | ||
| 867 | + } | ||
| 766 | this.getList() | 868 | this.getList() |
| 767 | } | 869 | } |
| 768 | this.getCountryList() | 870 | this.getCountryList() |
| 871 | + this.getAirportCode() | ||
| 872 | + this.getCustomCode() | ||
| 769 | let username = JSON.parse(sessionStorage.getItem('user')).username | 873 | let username = JSON.parse(sessionStorage.getItem('user')).username |
| 770 | - if(username === 'admin'){ | 874 | + if (username === 'admin') { |
| 771 | this.isAdmin = true | 875 | this.isAdmin = true |
| 772 | } | 876 | } |
| 773 | }, | 877 | }, |
| @@ -981,24 +1085,24 @@ | @@ -981,24 +1085,24 @@ | ||
| 981 | // >>>>>>>>>>>>>>>>获取list集合<<<<<<<<<<<<<<<<<< | 1085 | // >>>>>>>>>>>>>>>>获取list集合<<<<<<<<<<<<<<<<<< |
| 982 | getList() { | 1086 | getList() { |
| 983 | this.listLoading = true | 1087 | this.listLoading = true |
| 984 | - if (this.listQuery.awba !== undefined && this.listQuery.awba !== '') { | ||
| 985 | - getMt2201ListForParam(this.listQuery).then(res => { | 1088 | + if (this.preQuery.awba !== undefined && this.preQuery.awba !== '') { |
| 1089 | + getMt2201ListForParam(this.preQuery).then(res => { | ||
| 986 | this.preData = res.data.dataList | 1090 | this.preData = res.data.dataList |
| 987 | this.total = res.data.count | 1091 | this.total = res.data.count |
| 988 | if (res.data.count > 0) { | 1092 | if (res.data.count > 0) { |
| 989 | - this.listQuery.carrier = this.preData[0].carrier | ||
| 990 | - this.listQuery.flightNo = this.preData[0].flightno | ||
| 991 | - this.listQuery.flightDate = this.preData[0].flightdate | ||
| 992 | - this.listQuery.originStation = this.preData[0].originstation | ||
| 993 | - this.listQuery.destinationStation = this.preData[0].destinationstation | ||
| 994 | - this.listQuery.customcode = this.preData[0].customcode | 1093 | + this.preQuery.carrier = this.preData[0].carrier |
| 1094 | + this.preQuery.flightno = this.preData[0].flightno | ||
| 1095 | + this.preQuery.flightdate = this.preData[0].flightdate | ||
| 1096 | + this.preQuery.originstation = this.preData[0].originstation | ||
| 1097 | + this.preQuery.destinationstation = this.preData[0].destinationstation | ||
| 1098 | + this.preQuery.customcode = this.preData[0].customcode | ||
| 995 | } | 1099 | } |
| 996 | setTimeout(() => { | 1100 | setTimeout(() => { |
| 997 | this.listLoading = false | 1101 | this.listLoading = false |
| 998 | }, 1500) | 1102 | }, 1500) |
| 999 | }) | 1103 | }) |
| 1000 | } else { | 1104 | } else { |
| 1001 | - getMt2201ListForParam(this.listQuery).then(res => { | 1105 | + getMt2201ListForParam(this.preQuery).then(res => { |
| 1002 | this.preData = res.data.dataList | 1106 | this.preData = res.data.dataList |
| 1003 | this.total = res.data.count | 1107 | this.total = res.data.count |
| 1004 | setTimeout(() => { | 1108 | setTimeout(() => { |
| @@ -1072,12 +1176,12 @@ | @@ -1072,12 +1176,12 @@ | ||
| 1072 | // >>>>>>>>>>>>>>>>新增主单<<<<<<<<<<<<<<<<<< | 1176 | // >>>>>>>>>>>>>>>>新增主单<<<<<<<<<<<<<<<<<< |
| 1073 | handleAddpreInfo() { | 1177 | handleAddpreInfo() { |
| 1074 | this.restModel() | 1178 | this.restModel() |
| 1075 | - this.preModel.carrier = this.listQuery.carrier | ||
| 1076 | - this.preModel.flightno = this.listQuery.flightno | ||
| 1077 | - this.preModel.flightdate = this.listQuery.flightdate | ||
| 1078 | - this.preModel.originstation = this.listQuery.originstation | ||
| 1079 | - this.preModel.destinationstation = this.listQuery.carrier | ||
| 1080 | - this.preModel.customcode = this.listQuery.customcode | 1179 | + this.preModel.carrier = this.preQuery.carrier |
| 1180 | + this.preModel.flightno = this.preQuery.flightno | ||
| 1181 | + this.preModel.flightdate = this.preQuery.flightdate | ||
| 1182 | + this.preModel.originstation = this.preQuery.originstation | ||
| 1183 | + this.preModel.destinationstation = this.preQuery.carrier | ||
| 1184 | + this.preModel.customcode = this.preQuery.customcode | ||
| 1081 | this.dialogStatus = 'create' | 1185 | this.dialogStatus = 'create' |
| 1082 | this.dialogFormVisible = true | 1186 | this.dialogFormVisible = true |
| 1083 | this.$nextTick(() => { | 1187 | this.$nextTick(() => { |
| @@ -1105,19 +1209,19 @@ | @@ -1105,19 +1209,19 @@ | ||
| 1105 | }, | 1209 | }, |
| 1106 | // >>>>>>>>>>>>>>>>搜索<<<<<<<<<<<<<<<<<< | 1210 | // >>>>>>>>>>>>>>>>搜索<<<<<<<<<<<<<<<<<< |
| 1107 | handleSerach() { | 1211 | handleSerach() { |
| 1108 | - this.listQuery.carrier = undefined | ||
| 1109 | - this.listQuery.flightno = undefined | ||
| 1110 | - this.listQuery.originstation = undefined | ||
| 1111 | - this.listQuery.flightdate = undefined | ||
| 1112 | - this.listQuery.destinationstation = undefined | 1212 | + this.preQuery.flightno = undefined |
| 1213 | + this.preQuery.carrier = undefined | ||
| 1214 | + this.preQuery.originstation = undefined | ||
| 1215 | + this.preQuery.flightdate = undefined | ||
| 1216 | + this.preQuery.destinationstation = undefined | ||
| 1113 | this.getList() | 1217 | this.getList() |
| 1114 | }, | 1218 | }, |
| 1115 | // >>>>>>>>>>>>>>>>收发明细<<<<<<<<<<<<<<<<<< | 1219 | // >>>>>>>>>>>>>>>>收发明细<<<<<<<<<<<<<<<<<< |
| 1116 | handleSend(row) { | 1220 | handleSend(row) { |
| 1117 | const resQuery = { | 1221 | const resQuery = { |
| 1118 | carrier: row.carrier, | 1222 | carrier: row.carrier, |
| 1119 | - flightNo: row.flightno, | ||
| 1120 | - flightDate: row.flightdate, | 1223 | + flightno: row.flightno, |
| 1224 | + flightdate: row.flightdate, | ||
| 1121 | awba: row.awba, | 1225 | awba: row.awba, |
| 1122 | awbh: row.awbh, | 1226 | awbh: row.awbh, |
| 1123 | messageType: 'MT2201' | 1227 | messageType: 'MT2201' |
| @@ -1128,8 +1232,24 @@ | @@ -1128,8 +1232,24 @@ | ||
| 1128 | }) | 1232 | }) |
| 1129 | }, | 1233 | }, |
| 1130 | // >>>>>>>>>>>>>>>>发送舱单报<<<<<<<<<<<<<<<<<< | 1234 | // >>>>>>>>>>>>>>>>发送舱单报<<<<<<<<<<<<<<<<<< |
| 1131 | - handleAwbSend() { | ||
| 1132 | - | 1235 | + handleAwbSend(row) { |
| 1236 | + delete row.parent | ||
| 1237 | + delete row.children | ||
| 1238 | + this.$confirm("是否发送", "确认消息", { | ||
| 1239 | + distinguishCancelAndClose: true, | ||
| 1240 | + confirmButtonText: '发送', | ||
| 1241 | + cancelButtonText: '取消' | ||
| 1242 | + }).then(() => { | ||
| 1243 | + sendCreateMt2201(row).then(res => { | ||
| 1244 | + console.log(res) | ||
| 1245 | + if (res.data.count > 0) { | ||
| 1246 | + Message.success(res.data.respMessage) | ||
| 1247 | + this.getList() | ||
| 1248 | + } else { | ||
| 1249 | + Message.error(res.data.respMessage) | ||
| 1250 | + } | ||
| 1251 | + }) | ||
| 1252 | + }) | ||
| 1133 | }, | 1253 | }, |
| 1134 | // >>>>>>>>>>>>>>>>更新运单数据<<<<<<<<<<<<<<<<<< | 1254 | // >>>>>>>>>>>>>>>>更新运单数据<<<<<<<<<<<<<<<<<< |
| 1135 | handleEdit(row) { | 1255 | handleEdit(row) { |
| @@ -1158,14 +1278,82 @@ | @@ -1158,14 +1278,82 @@ | ||
| 1158 | }) | 1278 | }) |
| 1159 | }, | 1279 | }, |
| 1160 | // >>>>>>>>>>>>>>>>发送修改报<<<<<<<<<<<<<<<<<< | 1280 | // >>>>>>>>>>>>>>>>发送修改报<<<<<<<<<<<<<<<<<< |
| 1161 | - handleAwbEdit() { | ||
| 1162 | - | 1281 | + handleAwbEdit(row) { |
| 1282 | + delete row.parent | ||
| 1283 | + delete row.children | ||
| 1284 | + this.preModel = Object.assign({}, row) | ||
| 1285 | + this.dialogStatus = 'sendUpdate' | ||
| 1286 | + this.dialogFormVisible = true | ||
| 1287 | + this.$nextTick(() => { | ||
| 1288 | + this.$refs.preFormData.clearValidate() | ||
| 1289 | + }) | ||
| 1163 | }, | 1290 | }, |
| 1164 | - // >>>>>>>>>>>>>>>>保存并发送<<<<<<<<<<<<<<<<<< | ||
| 1165 | - handleSaveAndSend() { | ||
| 1166 | - | 1291 | + sendUpdate(){ |
| 1292 | + this.respModel.reason = this.preModel.reason | ||
| 1293 | + this.respModel.contactName = this.preModel.contactName | ||
| 1294 | + this.respModel.contactTel = this.preModel.contactTel | ||
| 1295 | + const map = { | ||
| 1296 | + 'mt2201': this.preModel, | ||
| 1297 | + 'reason' : this.preModel.reason, | ||
| 1298 | + 'contactName':this.preModel.contactName, | ||
| 1299 | + 'contactTel': this.preModel.contactTel, | ||
| 1300 | + } | ||
| 1301 | + this.$refs.preFormData.validate(valid =>{ | ||
| 1302 | + if(valid){ | ||
| 1303 | + sendUpdateMt2201(map).then(res =>{ | ||
| 1304 | + if(res.data.count >0){ | ||
| 1305 | + Message.success(res.data.respMessage) | ||
| 1306 | + this.getList() | ||
| 1307 | + this.dialogFormVisible = false | ||
| 1308 | + }else { | ||
| 1309 | + Message.error(res.data.respMessage) | ||
| 1310 | + } | ||
| 1311 | + }) | ||
| 1312 | + } | ||
| 1313 | + }) | ||
| 1167 | }, | 1314 | }, |
| 1315 | + | ||
| 1168 | // >>>>>>>>>>>>>>>>发送删除报<<<<<<<<<<<<<<<<<< | 1316 | // >>>>>>>>>>>>>>>>发送删除报<<<<<<<<<<<<<<<<<< |
| 1317 | + handleSendDelete(row) { | ||
| 1318 | + this.respModel = { | ||
| 1319 | + uuid: undefined, | ||
| 1320 | + reason: undefined, | ||
| 1321 | + contactName: undefined, | ||
| 1322 | + contactTel: undefined, | ||
| 1323 | + content: '', | ||
| 1324 | + flightNo: undefined, | ||
| 1325 | + awba: undefined, | ||
| 1326 | + customCode: undefined, | ||
| 1327 | + flightDate: undefined, | ||
| 1328 | + awbh: '' | ||
| 1329 | + } | ||
| 1330 | + this.dialogDeleteVisble = true | ||
| 1331 | + this.respModel.awba = row.awba | ||
| 1332 | + this.respModel.flightNo = row.carrier + row.flightno | ||
| 1333 | + this.respModel.customCode = row.customcode | ||
| 1334 | + this.respModel.awbh = row.awbh | ||
| 1335 | + this.respModel.flightDate = row.flightdate | ||
| 1336 | + this.respModel.uuid = row.uuid | ||
| 1337 | + this.$nextTick(()=>{ | ||
| 1338 | + this.$refs.sendDeleteForm.clearValidate() | ||
| 1339 | + }) | ||
| 1340 | + }, | ||
| 1341 | + sendDelete() { | ||
| 1342 | + this.$refs.sendDeleteForm.validate(valid =>{ | ||
| 1343 | + if(valid){ | ||
| 1344 | + sendDeleteMt2201(this.respModel).then(res => { | ||
| 1345 | + if(res.data.count>0){ | ||
| 1346 | + Message.success(res.data.respMessage) | ||
| 1347 | + this.dialogDeleteVisble = false | ||
| 1348 | + this.getList() | ||
| 1349 | + }else { | ||
| 1350 | + Message.error(res.data.respMessage) | ||
| 1351 | + } | ||
| 1352 | + }) | ||
| 1353 | + } | ||
| 1354 | + }) | ||
| 1355 | + }, | ||
| 1356 | + //>>>>>>>>>>>>>>>>删除运单<<<<<<<<<<<<<<<<<< | ||
| 1169 | handleAwbDelete(row) { | 1357 | handleAwbDelete(row) { |
| 1170 | delete row.parent | 1358 | delete row.parent |
| 1171 | delete row.children | 1359 | delete row.children |
| @@ -1246,14 +1434,14 @@ | @@ -1246,14 +1434,14 @@ | ||
| 1246 | this.preModel.awbinfo.sairportid = template.awbinfo.sairportid | 1434 | this.preModel.awbinfo.sairportid = template.awbinfo.sairportid |
| 1247 | this.preModel.awbinfo.eairportid = template.awbinfo.eairportid | 1435 | this.preModel.awbinfo.eairportid = template.awbinfo.eairportid |
| 1248 | this.preModel.awbinfo.ex5 = template.awbinfo.ex5 | 1436 | this.preModel.awbinfo.ex5 = template.awbinfo.ex5 |
| 1249 | - this.listQuery.awba = template.awba | ||
| 1250 | - this.listQuery.flightDate = template.flightdate | ||
| 1251 | - this.listQuery.flightNo = template.flightno | ||
| 1252 | - this.listQuery.originStation = template.originstation | ||
| 1253 | - this.listQuery.destinationStation = template.destinationstation | ||
| 1254 | - this.listQuery.customcode = template.customcode | ||
| 1255 | - this.listQuery.carrier = template.carrier | ||
| 1256 | - getMt2201ListForParam(this.listQuery).then(res => { | 1437 | + this.preQuery.awba = template.awba |
| 1438 | + this.preQuery.flightdate = template.flightdate | ||
| 1439 | + this.preQuery.flightno = template.flightno | ||
| 1440 | + this.preQuery.originstation = template.originstation | ||
| 1441 | + this.preQuery.destinationstation = template.destinationstation | ||
| 1442 | + this.preQuery.customcode = template.customcode | ||
| 1443 | + this.preQuery.carrier = template.carrier | ||
| 1444 | + getMt2201ListForParam(this.preQuery).then(res => { | ||
| 1257 | this.awbPiece = 0 | 1445 | this.awbPiece = 0 |
| 1258 | this.awbWeight = 0 | 1446 | this.awbWeight = 0 |
| 1259 | let residuePiece = 0 | 1447 | let residuePiece = 0 |
| @@ -1294,21 +1482,20 @@ | @@ -1294,21 +1482,20 @@ | ||
| 1294 | .indexOf(query.toUpperCase()) > -1 | 1482 | .indexOf(query.toUpperCase()) > -1 |
| 1295 | }) | 1483 | }) |
| 1296 | }, 200) | 1484 | }, 200) |
| 1297 | - // if (query.length > 1) { | ||
| 1298 | - // this.selectCountry.countryCode = query | ||
| 1299 | - // getByCountryCode(this.selectCountry).then(res => { | ||
| 1300 | - // this.shpCompnyList = res.data.dataList | ||
| 1301 | - // this.shpCompnyTypeOption = this.shpCompnyList.map(item => { | ||
| 1302 | - // console.log(item) | ||
| 1303 | - // return {value: item.enterpriseCode, label: item.enterpriseCode} | ||
| 1304 | - // }) | ||
| 1305 | - // }) | ||
| 1306 | - // } | ||
| 1307 | } else { | 1485 | } else { |
| 1308 | this.countryOption = [] | 1486 | this.countryOption = [] |
| 1309 | } | 1487 | } |
| 1488 | + }, | ||
| 1310 | 1489 | ||
| 1311 | - | 1490 | + getAirportCode(){ |
| 1491 | + getAirportCode().then(res=>{ | ||
| 1492 | + this.airportCode = res.data.data | ||
| 1493 | + }) | ||
| 1494 | + }, | ||
| 1495 | + getCustomCode(){ | ||
| 1496 | + getCustomCode().then(res =>{ | ||
| 1497 | + this.customCodeList = res.data.data | ||
| 1498 | + }) | ||
| 1312 | }, | 1499 | }, |
| 1313 | handleAddpre() { | 1500 | handleAddpre() { |
| 1314 | const row = { | 1501 | const row = { |
| @@ -1318,7 +1505,8 @@ | @@ -1318,7 +1505,8 @@ | ||
| 1318 | }, | 1505 | }, |
| 1319 | 1506 | ||
| 1320 | handelBackStep() { | 1507 | handelBackStep() { |
| 1321 | - this.$router.push({name: '出港航班信息', params: {scopeRow: this.preModel}}) | 1508 | + this.preQuery.messageType = 'MT2201' |
| 1509 | + this.$router.push({name: '出港航班信息', params: {scopeRow: this.preQuery}}) | ||
| 1322 | } | 1510 | } |
| 1323 | } | 1511 | } |
| 1324 | } | 1512 | } |
| @@ -96,7 +96,7 @@ | @@ -96,7 +96,7 @@ | ||
| 96 | <span v-if="scope.row.status ==='16'">海关已存在</span> | 96 | <span v-if="scope.row.status ==='16'">海关已存在</span> |
| 97 | </template> | 97 | </template> |
| 98 | </el-table-column> | 98 | </el-table-column> |
| 99 | - <el-table-column prop="receipt" label="回执信息" width="180" align="center"> | 99 | + <el-table-column prop="receipt" label="回执信息" width="300" align="center"> |
| 100 | <template slot-scope="scope"> | 100 | <template slot-scope="scope"> |
| 101 | <span>{{scope.row.ext5}}</span> | 101 | <span>{{scope.row.ext5}}</span> |
| 102 | </template> | 102 | </template> |
| @@ -105,27 +105,25 @@ | @@ -105,27 +105,25 @@ | ||
| 105 | <template slot-scope="scope"> | 105 | <template slot-scope="scope"> |
| 106 | 106 | ||
| 107 | <el-button size="mini" @click="handleSend(scope.row)">收发明细</el-button> | 107 | <el-button size="mini" @click="handleSend(scope.row)">收发明细</el-button> |
| 108 | - <el-button size="mini" type="success" @click="handleEdit(scope.row)">编辑</el-button> | 108 | + <el-button size="mini" type="success" @click="handleEdit(scope.row)" :disabled="scope.row.status !=='01'">编辑</el-button> |
| 109 | <el-button size="mini" type="primary" @click="handleAwbSend(scope.row)" | 109 | <el-button size="mini" type="primary" @click="handleAwbSend(scope.row)" |
| 110 | - :disabled="scope.row.status !=='00'">发舱单报 | ||
| 111 | - </el-button> | 110 | + :disabled="scope.row.status !=='01'">发舱单报</el-button> |
| 112 | <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单</el-button> | 111 | <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单</el-button> |
| 113 | - | 112 | + <p></p> |
| 114 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" | 113 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" |
| 115 | - :disabled="scope.row.status ==='00'">更改状态 | ||
| 116 | - </el-button> | 114 | + :disabled="scope.row.status ==='01'">更改状态</el-button> |
| 117 | <el-button size="mini" type="primary" v-if="scope.row.awbh ===null" | 115 | <el-button size="mini" type="primary" v-if="scope.row.awbh ===null" |
| 118 | - @click="handleAddAwbh(scope.row)">新增分单 | ||
| 119 | - </el-button> | 116 | + @click="handleAddAwbh(scope.row)">新增分单</el-button> |
| 117 | + <el-button size="mini" type="danger" @click="handleSendDelete(scope.row)">发删除报</el-button> | ||
| 120 | </template> | 118 | </template> |
| 121 | </el-table-column> | 119 | </el-table-column> |
| 122 | </tree-table> | 120 | </tree-table> |
| 123 | <div class="btnFoot"> | 121 | <div class="btnFoot"> |
| 124 | <el-row> | 122 | <el-row> |
| 125 | - <el-button type="primary" size="mini" v-if="tidyModel.flightno !== undefined || tidyData.length> 0" | 123 | + <el-button type="primary" size="mini" v-if="tidyQuery.flightno !== undefined || tidyData.length> 0" |
| 126 | @click="handelAddTidyInfo">新增出港理货 | 124 | @click="handelAddTidyInfo">新增出港理货 |
| 127 | </el-button> | 125 | </el-button> |
| 128 | - <el-button type="primary" size="mini" v-if="tidyModel.flightno !== undefined || tidyData.length> 0" | 126 | + <el-button type="primary" size="mini" v-if="tidyQuery.flightno !== undefined || tidyData.length> 0" |
| 129 | @click="handelBackStep">返回 | 127 | @click="handelBackStep">返回 |
| 130 | </el-button> | 128 | </el-button> |
| 131 | </el-row> | 129 | </el-row> |
| @@ -174,14 +172,27 @@ | @@ -174,14 +172,27 @@ | ||
| 174 | <el-row> | 172 | <el-row> |
| 175 | <el-col :span="7.5"> | 173 | <el-col :span="7.5"> |
| 176 | <el-form-item label="起始站" prop="originstation"> | 174 | <el-form-item label="起始站" prop="originstation"> |
| 177 | - <el-input v-model="originstation" | ||
| 178 | - :disabled="dialogStatus === 'update'"></el-input> | 175 | + |
| 176 | + <el-select filterable clearable placeholder="请选择起始站" allow-create v-model="tidyModel.originstation"> | ||
| 177 | + <el-option v-for="item in airportCode" | ||
| 178 | + :key="item.airportid" :label="item.airportid" | ||
| 179 | + :value="item.airportid" :disabled="dialogStatus === 'update'"> | ||
| 180 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 181 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 182 | + </el-option> | ||
| 183 | + </el-select> | ||
| 179 | </el-form-item> | 184 | </el-form-item> |
| 180 | </el-col> | 185 | </el-col> |
| 181 | <el-col :span="7.5"> | 186 | <el-col :span="7.5"> |
| 182 | <el-form-item label="目的站" prop="destinationstation"> | 187 | <el-form-item label="目的站" prop="destinationstation"> |
| 183 | - <el-input v-model="destinationstation" | ||
| 184 | - :disabled="dialogStatus === 'update'"></el-input> | 188 | + <el-select filterable clearable placeholder="请选择起始站" allow-create v-model="tidyModel.destinationstation"> |
| 189 | + <el-option v-for="item in airportCode" | ||
| 190 | + :key="item.airportid" :label="item.airportid" | ||
| 191 | + :value="item.airportid" :disabled="dialogStatus === 'update'"> | ||
| 192 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 193 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 194 | + </el-option> | ||
| 195 | + </el-select> | ||
| 185 | </el-form-item> | 196 | </el-form-item> |
| 186 | </el-col> | 197 | </el-col> |
| 187 | 198 | ||
| @@ -238,9 +249,13 @@ | @@ -238,9 +249,13 @@ | ||
| 238 | </el-col> | 249 | </el-col> |
| 239 | <el-col :span="7.5"> | 250 | <el-col :span="7.5"> |
| 240 | <el-form-item label="海关关区" prop="customcode"> | 251 | <el-form-item label="海关关区" prop="customcode"> |
| 241 | - <el-select v-model="tidyModel.customcode"> | ||
| 242 | - <el-option v-for="item in customcodeList " :key="item" :label="item" | ||
| 243 | - :value="item"></el-option> | 252 | + <el-select v-model="tidyModel.customcode" placeholder="请选择关区代码" filterable clearable |
| 253 | + :disabled="dialogStatus === 'addAwbh'"> | ||
| 254 | + <el-option v-for="item in customCodeList" :key="item.customcode" :label="item.customcode" | ||
| 255 | + :value="item.customcode"> | ||
| 256 | + <span style="float: left">{{ item.customcode }}</span> | ||
| 257 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.customname }}</span> | ||
| 258 | + </el-option> | ||
| 244 | </el-select> | 259 | </el-select> |
| 245 | </el-form-item> | 260 | </el-form-item> |
| 246 | </el-col> | 261 | </el-col> |
| @@ -249,7 +264,6 @@ | @@ -249,7 +264,6 @@ | ||
| 249 | <div slot="footer" class="dialog-footer"> | 264 | <div slot="footer" class="dialog-footer"> |
| 250 | <el-button @click="dialogFormVisible = false">取消</el-button> | 265 | <el-button @click="dialogFormVisible = false">取消</el-button> |
| 251 | <el-button type="primary" @click="dialogStatus==='create'?createData():updateData()">保存</el-button> | 266 | <el-button type="primary" @click="dialogStatus==='create'?createData():updateData()">保存</el-button> |
| 252 | - <el-button type="success" @click="handleSaveAndSend">保存并发送</el-button> | ||
| 253 | </div> | 267 | </div> |
| 254 | </el-dialog> | 268 | </el-dialog> |
| 255 | <el-dialog title="收发明细" :visible.sync="dialogTableVisible"> | 269 | <el-dialog title="收发明细" :visible.sync="dialogTableVisible"> |
| @@ -291,7 +305,27 @@ | @@ -291,7 +305,27 @@ | ||
| 291 | </el-table-column> | 305 | </el-table-column> |
| 292 | </el-table> | 306 | </el-table> |
| 293 | </el-dialog> | 307 | </el-dialog> |
| 294 | - | 308 | + <el-dialog title="删除原因" :visible.sync="dialogDeleteVisible" width="30%"> |
| 309 | + <el-form ref="tidyDeleteForm" :model="respModel" :rules="tidyDeleteRules" | ||
| 310 | + label-width="120px" style="margin-right: 50px"> | ||
| 311 | + <el-form-item label="删除原因" prop="reason"> | ||
| 312 | + <el-input v-model="respModel.reason" placeholder="删除原因"></el-input> | ||
| 313 | + </el-form-item> | ||
| 314 | + <el-form-item label="删除操作人" prop="contactName"> | ||
| 315 | + <el-input v-model="respModel.contactName" placeholder="操作人姓名"></el-input> | ||
| 316 | + </el-form-item> | ||
| 317 | + <el-form-item label="操作人Tel" prop="contactTel"> | ||
| 318 | + <el-input v-model="respModel.contactTel" placeholder="删除操作人联系方式"></el-input> | ||
| 319 | + </el-form-item> | ||
| 320 | + <el-form-item label="备注"> | ||
| 321 | + <el-input v-model="respModel.content" type="textarea"></el-input> | ||
| 322 | + </el-form-item> | ||
| 323 | + </el-form> | ||
| 324 | + <div slot="footer" class="dialog-footer"> | ||
| 325 | + <el-button @click="dialogDeleteVisible = false">取消</el-button> | ||
| 326 | + <el-button type="primary" @click="sendTidyDelete()">发送</el-button> | ||
| 327 | + </div> | ||
| 328 | + </el-dialog> | ||
| 295 | </div> | 329 | </div> |
| 296 | </template> | 330 | </template> |
| 297 | <script> | 331 | <script> |
| @@ -299,10 +333,14 @@ | @@ -299,10 +333,14 @@ | ||
| 299 | import treeToArray from '@/utils/customEval' | 333 | import treeToArray from '@/utils/customEval' |
| 300 | import Pagination from '@/components/Pagination' | 334 | import Pagination from '@/components/Pagination' |
| 301 | 335 | ||
| 302 | - import {getMt520XListForParam, deleteByIsDelete, updateStatus, updateMt520X, addMt520X} from '@/api/exitTidy' | 336 | + import { |
| 337 | + getMt520XListForParam, deleteByIsDelete, | ||
| 338 | + updateStatus, updateMt520X, addMt520X, | ||
| 339 | + sendCreateMt5202,sendRemoveMt5202 } from '@/api/exitTidy' | ||
| 303 | import {Message} from "element-ui"; | 340 | import {Message} from "element-ui"; |
| 304 | import {getResponseForParam} from '@/api/responseDetail' | 341 | import {getResponseForParam} from '@/api/responseDetail' |
| 305 | import {validAwb, validAlphabets, validAlphabetsAndNum, validAlphabetsAndSpanceKey,validatorNum} from "@/utils/validate" | 342 | import {validAwb, validAlphabets, validAlphabetsAndNum, validAlphabetsAndSpanceKey,validatorNum} from "@/utils/validate" |
| 343 | + import {getCustomCode,getAirportCode} from "@/api/country"; | ||
| 306 | 344 | ||
| 307 | export default { | 345 | export default { |
| 308 | name: "ExitTidy", | 346 | name: "ExitTidy", |
| @@ -348,7 +386,8 @@ | @@ -348,7 +386,8 @@ | ||
| 348 | create: '添加出港理货', | 386 | create: '添加出港理货', |
| 349 | addAwbh: '添加分单理货' | 387 | addAwbh: '添加分单理货' |
| 350 | }, | 388 | }, |
| 351 | - customcodeList: [4604, 4620], | 389 | + customCodeList: [], |
| 390 | + airportCode:[], | ||
| 352 | tidyQuery: { | 391 | tidyQuery: { |
| 353 | pageSize: 1, | 392 | pageSize: 1, |
| 354 | limitSize: 100, | 393 | limitSize: 100, |
| @@ -358,7 +397,8 @@ | @@ -358,7 +397,8 @@ | ||
| 358 | flightdate: undefined, | 397 | flightdate: undefined, |
| 359 | originstation: undefined, | 398 | originstation: undefined, |
| 360 | destinationstation: undefined, | 399 | destinationstation: undefined, |
| 361 | - customcode: undefined | 400 | + customcode: undefined, |
| 401 | + messageType: undefined | ||
| 362 | }, | 402 | }, |
| 363 | tidyRoles: { | 403 | tidyRoles: { |
| 364 | awba: [{required: true, trigger: 'blur', validator: validatorAwb}], | 404 | awba: [{required: true, trigger: 'blur', validator: validatorAwb}], |
| @@ -374,6 +414,7 @@ | @@ -374,6 +414,7 @@ | ||
| 374 | tidyData: [], | 414 | tidyData: [], |
| 375 | detailData: [], | 415 | detailData: [], |
| 376 | dialogTableVisible: false, | 416 | dialogTableVisible: false, |
| 417 | + dialogDeleteVisible: false, | ||
| 377 | dialogStatus: undefined, | 418 | dialogStatus: undefined, |
| 378 | disabledStatus: false, | 419 | disabledStatus: false, |
| 379 | listLoading: false, | 420 | listLoading: false, |
| @@ -396,7 +437,25 @@ | @@ -396,7 +437,25 @@ | ||
| 396 | awbpiece: undefined, | 437 | awbpiece: undefined, |
| 397 | awbweight: undefined, | 438 | awbweight: undefined, |
| 398 | rcfdep: 'MT5202', | 439 | rcfdep: 'MT5202', |
| 399 | - } | 440 | + }, |
| 441 | + respModel : { | ||
| 442 | + uuid: undefined, | ||
| 443 | + reason: undefined, | ||
| 444 | + contactName: undefined, | ||
| 445 | + contactTel: undefined, | ||
| 446 | + content: '', | ||
| 447 | + flightNo: undefined, | ||
| 448 | + awba: undefined, | ||
| 449 | + customCode: undefined, | ||
| 450 | + flightDate: undefined, | ||
| 451 | + awbh: undefined, | ||
| 452 | + rcfdep: 'MT5202', | ||
| 453 | + }, | ||
| 454 | + tidyDeleteRules: { | ||
| 455 | + reason: [{required: true, message: '删除原因不能为空', trigger: 'blur'}], | ||
| 456 | + contactName: [{required: true, message: '删除操作人不能为空', trigger: 'blur'}], | ||
| 457 | + contactTel: [{required: true, message: '操作人联系方式不能为空', trigger: 'blur'}] | ||
| 458 | + }, | ||
| 400 | } | 459 | } |
| 401 | }, | 460 | }, |
| 402 | created() { | 461 | created() { |
| @@ -411,6 +470,8 @@ | @@ -411,6 +470,8 @@ | ||
| 411 | } | 470 | } |
| 412 | this.getList() | 471 | this.getList() |
| 413 | } | 472 | } |
| 473 | + this.getAirportCode() | ||
| 474 | + this.getCustomCode() | ||
| 414 | let username = JSON.parse(sessionStorage.getItem('user')).username | 475 | let username = JSON.parse(sessionStorage.getItem('user')).username |
| 415 | if(username === 'admin'){ | 476 | if(username === 'admin'){ |
| 416 | this.isAdmin = true | 477 | this.isAdmin = true |
| @@ -547,7 +608,25 @@ | @@ -547,7 +608,25 @@ | ||
| 547 | 608 | ||
| 548 | //发送舱单报 | 609 | //发送舱单报 |
| 549 | handleAwbSend(row) { | 610 | handleAwbSend(row) { |
| 550 | - | 611 | + delete row.children |
| 612 | + delete row.parent | ||
| 613 | + this.$confirm("是否发送", "确认消息", { | ||
| 614 | + distinguishCancelAndClose: true, | ||
| 615 | + confirmButtonText: '发送', | ||
| 616 | + cancelButtonText: '取消' | ||
| 617 | + }).then(() => { | ||
| 618 | + console.log(row) | ||
| 619 | + sendCreateMt5202(row).then(res => { | ||
| 620 | + if (res.data.count > 0) { | ||
| 621 | + Message.success(res.data.respMessage) | ||
| 622 | + this.getList() | ||
| 623 | + }else { | ||
| 624 | + Message.error(res.data.respMessage) | ||
| 625 | + } | ||
| 626 | + }) | ||
| 627 | + }).catch(error =>{ | ||
| 628 | + Message.error(error.message) | ||
| 629 | + }) | ||
| 551 | }, | 630 | }, |
| 552 | //新增分单理货 | 631 | //新增分单理货 |
| 553 | handleAddAwbh(row) { | 632 | handleAddAwbh(row) { |
| @@ -564,6 +643,52 @@ | @@ -564,6 +643,52 @@ | ||
| 564 | this.$refs.tidyFormData.clearValidate() | 643 | this.$refs.tidyFormData.clearValidate() |
| 565 | }) | 644 | }) |
| 566 | }, | 645 | }, |
| 646 | + // 发删除报 | ||
| 647 | + handleSendDelete(row){ | ||
| 648 | + this.respModel = { | ||
| 649 | + uuid: undefined, | ||
| 650 | + reason: undefined, | ||
| 651 | + contactName: undefined, | ||
| 652 | + contactTel: undefined, | ||
| 653 | + content: '', | ||
| 654 | + flightNo: undefined, | ||
| 655 | + awba: undefined, | ||
| 656 | + customCode: undefined, | ||
| 657 | + flightDate: undefined, | ||
| 658 | + awbh: undefined, | ||
| 659 | + rcfdep: 'MT5202', | ||
| 660 | + } | ||
| 661 | + this.dialogDeleteVisible = true | ||
| 662 | + this.respModel.uuid = row.uuid | ||
| 663 | + this.respModel.flightNo = row.carrier + row.flightno | ||
| 664 | + this.respModel.awba = row.awba | ||
| 665 | + this.respModel.customCode = row.customcode | ||
| 666 | + this.respModel.flightDate = row.flightdate | ||
| 667 | + if(row.awbh === null){ | ||
| 668 | + this.respModel.awbh = '' | ||
| 669 | + }else { | ||
| 670 | + this.respModel.awbh = row.awbh | ||
| 671 | + } | ||
| 672 | + this.$nextTick(() => { | ||
| 673 | + this.$refs.tidyDeleteForm.clearValidate() | ||
| 674 | + }) | ||
| 675 | + }, | ||
| 676 | + sendTidyDelete(){ | ||
| 677 | + this.$refs.tidyDeleteForm.validate(valid =>{ | ||
| 678 | + if(valid){ | ||
| 679 | + sendRemoveMt5202(this.respModel).then(res =>{ | ||
| 680 | + if(res.data.count >0){ | ||
| 681 | + Message.success(res.data.respMessage) | ||
| 682 | + this.dialogDeleteVisible = false | ||
| 683 | + this.getList() | ||
| 684 | + }else { | ||
| 685 | + Message.error(res.data.respMessage) | ||
| 686 | + } | ||
| 687 | + }) | ||
| 688 | + } | ||
| 689 | + }) | ||
| 690 | + }, | ||
| 691 | + | ||
| 567 | // 删除当前运单 | 692 | // 删除当前运单 |
| 568 | handleAwbDelete(row) { | 693 | handleAwbDelete(row) { |
| 569 | delete row.parent | 694 | delete row.parent |
| @@ -575,16 +700,10 @@ | @@ -575,16 +700,10 @@ | ||
| 575 | }).then(() => { | 700 | }).then(() => { |
| 576 | deleteByIsDelete(row).then(res => { | 701 | deleteByIsDelete(row).then(res => { |
| 577 | if (res.data.count > 0) { | 702 | if (res.data.count > 0) { |
| 578 | - this.$message({ | ||
| 579 | - type: 'success', | ||
| 580 | - message: '删除成功' | ||
| 581 | - }) | 703 | + Message.success("删除成功") |
| 582 | this.getList() | 704 | this.getList() |
| 583 | } else { | 705 | } else { |
| 584 | - this.$message({ | ||
| 585 | - type: 'error', | ||
| 586 | - message: '删除异常,请稍后重试' | ||
| 587 | - }) | 706 | + Message.success("删除异常,请稍后重试") |
| 588 | } | 707 | } |
| 589 | }) | 708 | }) |
| 590 | }).catch(action => { | 709 | }).catch(action => { |
| @@ -608,16 +727,10 @@ | @@ -608,16 +727,10 @@ | ||
| 608 | }).then(() => { | 727 | }).then(() => { |
| 609 | updateStatus(row).then(res => { | 728 | updateStatus(row).then(res => { |
| 610 | if (res.data.count > 0) { | 729 | if (res.data.count > 0) { |
| 611 | - this.$message({ | ||
| 612 | - type: 'success', | ||
| 613 | - message: '当前运单状态已更改' | ||
| 614 | - }) | 730 | + Message.success(res.data.respMessage) |
| 615 | this.getList() | 731 | this.getList() |
| 616 | } else { | 732 | } else { |
| 617 | - this.$message({ | ||
| 618 | - type: 'error', | ||
| 619 | - message: '更新失败,请稍后重试' | ||
| 620 | - }) | 733 | + Message.error(res.data.respMessage) |
| 621 | } | 734 | } |
| 622 | }) | 735 | }) |
| 623 | }).catch(action => { | 736 | }).catch(action => { |
| @@ -712,20 +825,27 @@ | @@ -712,20 +825,27 @@ | ||
| 712 | } | 825 | } |
| 713 | }) | 826 | }) |
| 714 | }, | 827 | }, |
| 715 | - // 保存并发送 | ||
| 716 | - handleSaveAndSend() { | ||
| 717 | - | 828 | + getAirportCode(){ |
| 829 | + getAirportCode().then(res=>{ | ||
| 830 | + this.airportCode = res.data.data | ||
| 831 | + }) | ||
| 832 | + }, | ||
| 833 | + getCustomCode(){ | ||
| 834 | + getCustomCode().then(res =>{ | ||
| 835 | + this.customCodeList = res.data.data | ||
| 836 | + }) | ||
| 718 | }, | 837 | }, |
| 719 | // 新增理货弹框 | 838 | // 新增理货弹框 |
| 720 | handleAddTidy() { | 839 | handleAddTidy() { |
| 721 | const row = { | 840 | const row = { |
| 722 | - 'messageType': 'MT5201' | 841 | + 'messageType': 'MT5202' |
| 723 | } | 842 | } |
| 724 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) | 843 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) |
| 725 | }, | 844 | }, |
| 726 | // 返回 | 845 | // 返回 |
| 727 | handelBackStep() { | 846 | handelBackStep() { |
| 728 | - this.$router.push({name: '出港航班信息', params: {scopeRow: this.tidyModel}}) | 847 | + this.tidyQuery.messageType = 'MT5202' |
| 848 | + this.$router.push({name: '出港航班信息', params: {scopeRow: this.tidyQuery}}) | ||
| 729 | } | 849 | } |
| 730 | } | 850 | } |
| 731 | } | 851 | } |
-
请 注册 或 登录 后发表评论