Merge remote-tracking branch 'origin/master'
# Conflicts: # config/index.js # src/api/user.js # src/views/Home.vue
正在显示
47 个修改的文件
包含
3584 行增加
和
920 行删除
| @@ -31,7 +31,7 @@ module.exports = { | @@ -31,7 +31,7 @@ module.exports = { | ||
| 31 | proxyTable: { | 31 | proxyTable: { |
| 32 | '/api':{ | 32 | '/api':{ |
| 33 | target: 'http://192.168.1.53:12343',//设置你调用的接口域名和端口号 别忘了加http | 33 | target: 'http://192.168.1.53:12343',//设置你调用的接口域名和端口号 别忘了加http |
| 34 | - //target: 'http://localhost:12343',//设置你调用的接口域名和端口号 别忘了加http | 34 | + // target: 'http://localhost:12343',//设置你调用的接口域名和端口号 别忘了加http |
| 35 | changeOrigin: true, | 35 | changeOrigin: true, |
| 36 | pathRewrite: { | 36 | pathRewrite: { |
| 37 | '^/api/': '/'//这里理解成用‘/api’代替target里面的地址,后面组件中我们掉接口时直接用api代替 比如我要调用'http://40.00.100.100:3002/user/add',直接写‘/api/user/add’即可 | 37 | '^/api/': '/'//这里理解成用‘/api’代替target里面的地址,后面组件中我们掉接口时直接用api代替 比如我要调用'http://40.00.100.100:3002/user/add',直接写‘/api/user/add’即可 |
| @@ -1610,6 +1610,11 @@ | @@ -1610,6 +1610,11 @@ | ||
| 1610 | } | 1610 | } |
| 1611 | } | 1611 | } |
| 1612 | }, | 1612 | }, |
| 1613 | + "base64-arraybuffer": { | ||
| 1614 | + "version": "0.2.0", | ||
| 1615 | + "resolved": "https://registry.npmjs.org/base64-arraybuffer/-/base64-arraybuffer-0.2.0.tgz", | ||
| 1616 | + "integrity": "sha512-7emyCsu1/xiBXgQZrscw/8KPRT44I4Yq9Pe6EGs3aPRTsWuggML1/1DTuZUuIaJPIm1FTDUVXl4x/yW8s0kQDQ==" | ||
| 1617 | + }, | ||
| 1613 | "base64-js": { | 1618 | "base64-js": { |
| 1614 | "version": "1.3.1", | 1619 | "version": "1.3.1", |
| 1615 | "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.3.1.tgz", | 1620 | "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.3.1.tgz", |
| @@ -1972,9 +1977,9 @@ | @@ -1972,9 +1977,9 @@ | ||
| 1972 | } | 1977 | } |
| 1973 | }, | 1978 | }, |
| 1974 | "cfb": { | 1979 | "cfb": { |
| 1975 | - "version": "1.1.3", | ||
| 1976 | - "resolved": "https://registry.npmjs.org/cfb/-/cfb-1.1.3.tgz", | ||
| 1977 | - "integrity": "sha512-joXBW0nMuwV9no7UTMiyVJnQL6XIU3ThXVjFUDHgl9MpILPOomyfaGqC290VELZ48bbQKZXnQ81UT5HouTxHsw==", | 1980 | + "version": "1.1.4", |
| 1981 | + "resolved": "https://registry.npmjs.org/cfb/-/cfb-1.1.4.tgz", | ||
| 1982 | + "integrity": "sha512-rwFkl3aFO3f+ljR27YINwC0x8vPjyiEVbYbrTCKzspEf7Q++3THdfHVgJYNUbxNcupJECrLX+L40Mjm9hm/Bgw==", | ||
| 1978 | "requires": { | 1983 | "requires": { |
| 1979 | "adler-32": "~1.2.0", | 1984 | "adler-32": "~1.2.0", |
| 1980 | "commander": "^2.16.0", | 1985 | "commander": "^2.16.0", |
| @@ -2754,6 +2759,14 @@ | @@ -2754,6 +2759,14 @@ | ||
| 2754 | "integrity": "sha1-gIrcLnnPhHOAabZGyyDsJ762KeA=", | 2759 | "integrity": "sha1-gIrcLnnPhHOAabZGyyDsJ762KeA=", |
| 2755 | "dev": true | 2760 | "dev": true |
| 2756 | }, | 2761 | }, |
| 2762 | + "css-line-break": { | ||
| 2763 | + "version": "1.1.1", | ||
| 2764 | + "resolved": "https://registry.npmjs.org/css-line-break/-/css-line-break-1.1.1.tgz", | ||
| 2765 | + "integrity": "sha512-1feNVaM4Fyzdj4mKPIQNL2n70MmuYzAXZ1aytlROFX1JsOo070OsugwGjj7nl6jnDJWHDM8zRZswkmeYVWZJQA==", | ||
| 2766 | + "requires": { | ||
| 2767 | + "base64-arraybuffer": "^0.2.0" | ||
| 2768 | + } | ||
| 2769 | + }, | ||
| 2757 | "css-loader": { | 2770 | "css-loader": { |
| 2758 | "version": "0.26.4", | 2771 | "version": "0.26.4", |
| 2759 | "resolved": "https://registry.npmjs.org/css-loader/-/css-loader-0.26.4.tgz", | 2772 | "resolved": "https://registry.npmjs.org/css-loader/-/css-loader-0.26.4.tgz", |
| @@ -5017,6 +5030,14 @@ | @@ -5017,6 +5030,14 @@ | ||
| 5017 | "toposort": "^1.0.0" | 5030 | "toposort": "^1.0.0" |
| 5018 | } | 5031 | } |
| 5019 | }, | 5032 | }, |
| 5033 | + "html2canvas": { | ||
| 5034 | + "version": "1.0.0-rc.5", | ||
| 5035 | + "resolved": "https://registry.npmjs.org/html2canvas/-/html2canvas-1.0.0-rc.5.tgz", | ||
| 5036 | + "integrity": "sha512-DtNqPxJNXPoTajs+lVQzGS1SULRI4GQaROeU5R41xH8acffHukxRh/NBVcTBsfCkJSkLq91rih5TpbEwUP9yWA==", | ||
| 5037 | + "requires": { | ||
| 5038 | + "css-line-break": "1.1.1" | ||
| 5039 | + } | ||
| 5040 | + }, | ||
| 5020 | "htmlparser2": { | 5041 | "htmlparser2": { |
| 5021 | "version": "3.10.1", | 5042 | "version": "3.10.1", |
| 5022 | "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-3.10.1.tgz", | 5043 | "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-3.10.1.tgz", |
| @@ -6313,7 +6334,7 @@ | @@ -6313,7 +6334,7 @@ | ||
| 6313 | }, | 6334 | }, |
| 6314 | "normalize-wheel": { | 6335 | "normalize-wheel": { |
| 6315 | "version": "1.0.1", | 6336 | "version": "1.0.1", |
| 6316 | - "resolved": "https://registry.npmjs.org/normalize-wheel/-/normalize-wheel-1.0.1.tgz", | 6337 | + "resolved": "https://registry.npm.taobao.org/normalize-wheel/download/normalize-wheel-1.0.1.tgz", |
| 6317 | "integrity": "sha1-rsiGr/2wRQcNhWRH32Ls+GFG7EU=" | 6338 | "integrity": "sha1-rsiGr/2wRQcNhWRH32Ls+GFG7EU=" |
| 6318 | }, | 6339 | }, |
| 6319 | "npm": { | 6340 | "npm": { |
| @@ -11769,9 +11790,9 @@ | @@ -11769,9 +11790,9 @@ | ||
| 11769 | "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=" | 11790 | "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=" |
| 11770 | }, | 11791 | }, |
| 11771 | "ssf": { | 11792 | "ssf": { |
| 11772 | - "version": "0.10.2", | ||
| 11773 | - "resolved": "https://registry.npmjs.org/ssf/-/ssf-0.10.2.tgz", | ||
| 11774 | - "integrity": "sha512-rDhAPm9WyIsY8eZEKyE8Qsotb3j/wBdvMWBUsOhJdfhKGLfQidRjiBUV0y/MkyCLiXQ38FG6LWW/VYUtqlIDZQ==", | 11793 | + "version": "0.10.3", |
| 11794 | + "resolved": "https://registry.npmjs.org/ssf/-/ssf-0.10.3.tgz", | ||
| 11795 | + "integrity": "sha512-pRuUdW0WwyB2doSqqjWyzwCD6PkfxpHAHdZp39K3dp/Hq7f+xfMwNAWIi16DyrRg4gg9c/RvLYkJTSawTPTm1w==", | ||
| 11775 | "requires": { | 11796 | "requires": { |
| 11776 | "frac": "~1.1.2" | 11797 | "frac": "~1.1.2" |
| 11777 | } | 11798 | } |
| @@ -13105,6 +13126,11 @@ | @@ -13105,6 +13126,11 @@ | ||
| 13105 | "integrity": "sha1-VDjNLqk7IC76Ohn+iIeu58lPnJ0=", | 13126 | "integrity": "sha1-VDjNLqk7IC76Ohn+iIeu58lPnJ0=", |
| 13106 | "dev": true | 13127 | "dev": true |
| 13107 | }, | 13128 | }, |
| 13129 | + "wmf": { | ||
| 13130 | + "version": "1.0.2", | ||
| 13131 | + "resolved": "https://registry.npmjs.org/wmf/-/wmf-1.0.2.tgz", | ||
| 13132 | + "integrity": "sha512-/p9K7bEh0Dj6WbXg4JG0xvLQmIadrner1bi45VMJTfnbVHsc7yIajZyoSoK60/dtVBs12Fm6WkUI5/3WAVsNMw==" | ||
| 13133 | + }, | ||
| 13108 | "wordwrap": { | 13134 | "wordwrap": { |
| 13109 | "version": "1.0.0", | 13135 | "version": "1.0.0", |
| 13110 | "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-1.0.0.tgz", | 13136 | "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-1.0.0.tgz", |
| @@ -13180,17 +13206,18 @@ | @@ -13180,17 +13206,18 @@ | ||
| 13180 | } | 13206 | } |
| 13181 | }, | 13207 | }, |
| 13182 | "xlsx": { | 13208 | "xlsx": { |
| 13183 | - "version": "0.15.1", | ||
| 13184 | - "resolved": "https://registry.npmjs.org/xlsx/-/xlsx-0.15.1.tgz", | ||
| 13185 | - "integrity": "sha512-z+o4+QPMc32EPboLCzJAz94o0Zyy+8jrmWTsVpfzwknFln9qDO6/HN1KrGGVC4//sGA7dh4R3HA4fhbGIKCDOA==", | 13209 | + "version": "0.15.6", |
| 13210 | + "resolved": "https://registry.npmjs.org/xlsx/-/xlsx-0.15.6.tgz", | ||
| 13211 | + "integrity": "sha512-7vD9eutyLs65iDjNFimVN+gk/oDkfkCgpQUjdE82QgzJCrBHC4bGPH7fzKVyy0UPp3gyFVQTQEFJaWaAvZCShQ==", | ||
| 13186 | "requires": { | 13212 | "requires": { |
| 13187 | "adler-32": "~1.2.0", | 13213 | "adler-32": "~1.2.0", |
| 13188 | - "cfb": "^1.1.3", | 13214 | + "cfb": "^1.1.4", |
| 13189 | "codepage": "~1.14.0", | 13215 | "codepage": "~1.14.0", |
| 13190 | "commander": "~2.17.1", | 13216 | "commander": "~2.17.1", |
| 13191 | "crc-32": "~1.2.0", | 13217 | "crc-32": "~1.2.0", |
| 13192 | "exit-on-epipe": "~1.0.1", | 13218 | "exit-on-epipe": "~1.0.1", |
| 13193 | - "ssf": "~0.10.2" | 13219 | + "ssf": "~0.10.3", |
| 13220 | + "wmf": "~1.0.1" | ||
| 13194 | } | 13221 | } |
| 13195 | }, | 13222 | }, |
| 13196 | "xtend": { | 13223 | "xtend": { |
| @@ -16,8 +16,10 @@ | @@ -16,8 +16,10 @@ | ||
| 16 | "eslint": "^5.14.1", | 16 | "eslint": "^5.14.1", |
| 17 | "file-saver": "^2.0.2", | 17 | "file-saver": "^2.0.2", |
| 18 | "font-awesome": "^4.7.0", | 18 | "font-awesome": "^4.7.0", |
| 19 | + "html2canvas": "^1.0.0-rc.5", | ||
| 19 | "install": "^0.12.2", | 20 | "install": "^0.12.2", |
| 20 | "js-cookie": "^2.2.1", | 21 | "js-cookie": "^2.2.1", |
| 22 | + "jspdf": "^1.5.3", | ||
| 21 | "jszip": "^3.2.2", | 23 | "jszip": "^3.2.2", |
| 22 | "moment": "^2.24.0", | 24 | "moment": "^2.24.0", |
| 23 | "npm": "^6.8.0", | 25 | "npm": "^6.8.0", |
| @@ -27,7 +29,7 @@ | @@ -27,7 +29,7 @@ | ||
| 27 | "vue-i18n": "^8.14.0", | 29 | "vue-i18n": "^8.14.0", |
| 28 | "vue-router": "^2.3.0", | 30 | "vue-router": "^2.3.0", |
| 29 | "vuex": "^2.0.0-rc.6", | 31 | "vuex": "^2.0.0-rc.6", |
| 30 | - "xlsx": "^0.15.1" | 32 | + "xlsx": "^0.15.6" |
| 31 | }, | 33 | }, |
| 32 | "devDependencies": { | 34 | "devDependencies": { |
| 33 | "autoprefixer": "^6.7.2", | 35 | "autoprefixer": "^6.7.2", |
| @@ -6,3 +6,8 @@ export const addAllocatImport=params=>{return http.post(`${baseUrl}/addAllocatIm | @@ -6,3 +6,8 @@ export const addAllocatImport=params=>{return http.post(`${baseUrl}/addAllocatIm | ||
| 6 | export const addAllocatArrive=params=>{return http.post(`${baseUrl}/addAllocatArrive`, params);}; | 6 | export const addAllocatArrive=params=>{return http.post(`${baseUrl}/addAllocatArrive`, params);}; |
| 7 | export const QueryData=params=>{return http.get(`${baseUrl}/QueryData`, params);}; | 7 | export const QueryData=params=>{return http.get(`${baseUrl}/QueryData`, params);}; |
| 8 | export const ediAllocat=params=>{return http.put(`${baseUrl}/ediAllocat`, params);}; | 8 | export const ediAllocat=params=>{return http.put(`${baseUrl}/ediAllocat`, params);}; |
| 9 | + | ||
| 10 | +export const sendCreateMt6202=params=>{return http.post(`${baseUrl}/sendCreateMt6202`, params);}; | ||
| 11 | +export const sendRemoveMt6202=params=>{return http.post(`${baseUrl}/sendRemoveMt6202`, params);}; | ||
| 12 | +export const sendCreateMt3202=params=>{return http.post(`${baseUrl}/sendCreateMt3202`, params);}; | ||
| 13 | +export const sendRemoveMt3202=params=>{return http.post(`${baseUrl}/sendRemoveMt3202`, params);}; |
src/api/InResponse.js
0 → 100644
| 1 | +import http from './http.js' | ||
| 2 | + | ||
| 3 | +let baseUrl = 'nmms-server-import/nmms/rep' | ||
| 4 | +//添加回执明细 | ||
| 5 | +export const addResponse=params=>{return http.post(`${baseUrl}/InsertResponse`, params);}; | ||
| 6 | +//查询回执明细列表 | ||
| 7 | +export const selectResponseList=params=>{return http.post(`${baseUrl}/selectResponseList`, params);}; |
| @@ -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.get(`/nmms-server-import/nmms/mt1201/selectList`,params)} | ||
| 12 | + | ||
| 13 | +export const getCustomCode = params =>{return http.get(`/nmms-server-import/nmms/mt1201/selectCustomcode`,params)} |
src/api/el-ext/eltree.js
0 → 100644
| 1 | + |
| @@ -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,11 @@ export const updateStatus = params => { return http.put(`${baseUrl}/updateStatus | @@ -12,3 +12,11 @@ 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)}; | ||
| 20 | + | ||
| 21 | + | ||
| 22 | + |
| @@ -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)}; |
src/api/htmlToPdf.js
0 → 100644
| 1 | +//不使用JQuery版的 | ||
| 2 | + | ||
| 3 | +import html2canvas from 'html2canvas'; | ||
| 4 | +import JsPDF from 'jspdf'; | ||
| 5 | + | ||
| 6 | +/** | ||
| 7 | + * @param ele 要生成 pdf 的DOM元素(容器) | ||
| 8 | + * @param padfName PDF文件生成后的文件名字 | ||
| 9 | + * */ | ||
| 10 | + | ||
| 11 | +function downloadPDF(ele, pdfName){ | ||
| 12 | + | ||
| 13 | + let eleW = ele.offsetWidth;// 获得该容器的宽 | ||
| 14 | + let eleH = ele.offsetHeight;// 获得该容器的高 | ||
| 15 | + | ||
| 16 | + | ||
| 17 | + let eleOffsetTop = ele.offsetTop; // 获得该容器到文档顶部的距离 | ||
| 18 | + let eleOffsetLeft = ele.offsetLeft; // 获得该容器到文档最左的距离 | ||
| 19 | + | ||
| 20 | + var canvas = document.createElement("canvas"); | ||
| 21 | + var abs = 0; | ||
| 22 | + | ||
| 23 | + let win_in = document.documentElement.clientWidth || document.body.clientWidth; // 获得当前可视窗口的宽度(不包含滚动条) | ||
| 24 | + let win_out = window.innerWidth; // 获得当前窗口的宽度(包含滚动条) | ||
| 25 | + | ||
| 26 | + if(win_out>win_in){ | ||
| 27 | + // abs = (win_o - win_i)/2; // 获得滚动条长度的一半 | ||
| 28 | + abs = (win_out - win_in)/2; // 获得滚动条宽度的一半 | ||
| 29 | + // console.log(a, '新abs'); | ||
| 30 | + } | ||
| 31 | + | ||
| 32 | + canvas.width = eleW * 2; // 将画布宽&&高放大两倍 | ||
| 33 | + canvas.height = eleH * 2; | ||
| 34 | + | ||
| 35 | + | ||
| 36 | + | ||
| 37 | + | ||
| 38 | + var context = canvas.getContext("2d"); | ||
| 39 | + | ||
| 40 | + context.scale(2, 2); | ||
| 41 | + | ||
| 42 | + context.translate(-eleOffsetLeft -abs, -eleOffsetTop); | ||
| 43 | + // 这里默认横向没有滚动条的情况,因为offset.left(),有无滚动条的时候存在差值,因此 | ||
| 44 | + // translate的时候,要把这个差值去掉 | ||
| 45 | + | ||
| 46 | + // html2canvas(element).then( (canvas)=>{ //报错 | ||
| 47 | + // html2canvas(element[0]).then( (canvas)=>{ | ||
| 48 | + html2canvas( ele, { | ||
| 49 | + dpi: 300, | ||
| 50 | + // allowTaint: true, //允许 canvas 污染, allowTaint参数要去掉,否则是无法通过toDataURL导出canvas数据的 | ||
| 51 | + useCORS:true //允许canvas画布内 可以跨域请求外部链接图片, 允许跨域请求。 | ||
| 52 | + } ).then( (canvas)=>{ | ||
| 53 | + | ||
| 54 | + var contentWidth = canvas.width; | ||
| 55 | + var contentHeight = canvas.height; | ||
| 56 | + //一页pdf显示html页面生成的canvas高度; | ||
| 57 | + var pageHeight = contentWidth / 592.28 * 841.89; | ||
| 58 | + //未生成pdf的html页面高度 | ||
| 59 | + var leftHeight = contentHeight; | ||
| 60 | + //页面偏移 | ||
| 61 | + var position = 0; | ||
| 62 | + //a4纸的尺寸[595.28,841.89],html页面生成的canvas在pdf中图片的宽高 | ||
| 63 | + var imgWidth = 595.28; | ||
| 64 | + var imgHeight = 595.28/contentWidth * contentHeight; | ||
| 65 | + | ||
| 66 | + var pageData = canvas.toDataURL('image/jpeg', 1.0); | ||
| 67 | + | ||
| 68 | + | ||
| 69 | + | ||
| 70 | + var pdf = new JsPDF('', 'pt', 'a4'); | ||
| 71 | + | ||
| 72 | + //有两个高度需要区分,一个是html页面的实际高度,和生成pdf的页面高度(841.89) | ||
| 73 | + //当内容未超过pdf一页显示的范围,无需分页 | ||
| 74 | + if (leftHeight < pageHeight) { | ||
| 75 | + //在pdf.addImage(pageData, 'JPEG', 左,上,宽度,高度)设置在pdf中显示; | ||
| 76 | + pdf.addImage(pageData, 'JPEG', 0, 0, imgWidth, imgHeight); | ||
| 77 | + // pdf.addImage(pageData, 'JPEG', 20, 40, imgWidth, imgHeight); | ||
| 78 | + } else { // 分页 | ||
| 79 | + while(leftHeight > 0) { | ||
| 80 | + pdf.addImage(pageData, 'JPEG', 0, position, imgWidth, imgHeight); | ||
| 81 | + leftHeight -= pageHeight; | ||
| 82 | + position -= 841.89; | ||
| 83 | + //避免添加空白页 | ||
| 84 | + if(leftHeight > 0) { | ||
| 85 | + pdf.addPage(); | ||
| 86 | + } | ||
| 87 | + } | ||
| 88 | + } | ||
| 89 | + | ||
| 90 | + //可动态生成 | ||
| 91 | + pdf.save(pdfName); | ||
| 92 | + }) | ||
| 93 | + | ||
| 94 | + | ||
| 95 | +} | ||
| 96 | + | ||
| 97 | + | ||
| 98 | +export default { | ||
| 99 | + downloadPDF | ||
| 100 | +} |
| @@ -6,4 +6,10 @@ export const getMt1201List=params=>{return http.get(`${baseUrl}/getMt1201List`, | @@ -6,4 +6,10 @@ export const getMt1201List=params=>{return http.get(`${baseUrl}/getMt1201List`, | ||
| 6 | export const getFenList=params=>{return http.get(`${baseUrl}/getFenList`, params);}; | 6 | export const getFenList=params=>{return http.get(`${baseUrl}/getFenList`, params);}; |
| 7 | export const addMt1201=params=>{return http.post(`${baseUrl}/addMt1201`, params);}; | 7 | export const addMt1201=params=>{return http.post(`${baseUrl}/addMt1201`, params);}; |
| 8 | export const ediMt1201=params=>{return http.put(`${baseUrl}/ediMt1201`, params);}; | 8 | export const ediMt1201=params=>{return http.put(`${baseUrl}/ediMt1201`, params);}; |
| 9 | +export const selectAirport=params=>{return http.get(`${baseUrl}/selectList`, params);}; | ||
| 10 | +export const getCountryCode=params=>{return http.get(`${baseUrl}/getCountryCode`, params);}; | ||
| 11 | +export const selectCustomcode=params=>{return http.get(`${baseUrl}/selectCustomcode`, params);}; | ||
| 9 | 12 | ||
| 13 | +export const sendCreateMt1201=params=>{return http.post(`${baseUrl}/sendCreateMt1201`, params);}; | ||
| 14 | +export const sendEditeMt1201=params=>{return http.post(`${baseUrl}/sendEditeMt1201`, params);}; | ||
| 15 | +export const sendRemoveMt1201=params=>{return http.post(`${baseUrl}/sendRemoveMt1201`, params);}; |
| 1 | import http from './http.js' | 1 | import http from './http.js' |
| 2 | let baseUrl = 'nmms-server-import/nmms/mt5201' | 2 | let baseUrl = 'nmms-server-import/nmms/mt5201' |
| 3 | +let baseUrl2='nmms-server-import/nmms/mt1201' | ||
| 3 | 4 | ||
| 4 | export const getMt5201List=params=>{return http.get(`${baseUrl}/getMt5201List`, params);}; | 5 | export const getMt5201List=params=>{return http.get(`${baseUrl}/getMt5201List`, params);}; |
| 5 | export const addMt5201=params=>{return http.post(`${baseUrl}/addMt5201`, params);}; | 6 | export const addMt5201=params=>{return http.post(`${baseUrl}/addMt5201`, params);}; |
| 6 | export const ediMt5201=params=>{return http.put(`${baseUrl}/ediMt5201`, params);}; | 7 | export const ediMt5201=params=>{return http.put(`${baseUrl}/ediMt5201`, params);}; |
| 7 | export const delMt5201 = params => { return http.del(`${baseUrl}/delMt5201`,params)}; | 8 | export const delMt5201 = params => { return http.del(`${baseUrl}/delMt5201`,params)}; |
| 8 | 9 | ||
| 10 | +export const sendCreateMt520x=params=>{return http.post(`${baseUrl}/sendCreateMt520x`, params);}; | ||
| 11 | +export const sendRemoveMt520x=params=>{return http.post(`${baseUrl}/sendRemoveMt520x`, params);}; | ||
| 12 | +export const selectCustomcode=params=>{return http.get(`${baseUrl2}/selectCustomcode`, params);}; | ||
| 13 | + | ||
| 14 | + |
| @@ -4,13 +4,14 @@ export const getUserList = params => { return http.get(`${baseUrl}/list`, param | @@ -4,13 +4,14 @@ export const getUserList = params => { return http.get(`${baseUrl}/list`, param | ||
| 4 | 4 | ||
| 5 | export const getUserListPage = params => { return http.get(`/user/list`,params) }; | 5 | export const getUserListPage = params => { return http.get(`/user/list`,params) }; |
| 6 | 6 | ||
| 7 | -export const removeUser = params => { return http.del(`/user/del`,params)}; | 7 | +export const removeUser = params => { return http.del(`${baseUrl}/del`,params)}; |
| 8 | 8 | ||
| 9 | -export const batchRemoveUser = params => { return http.del(`/user/batchremove`, { params: params }); }; | 9 | +export const batchRemoveUser = params => { return http.del(`${baseUrl}/batchremove`, { params: params }); }; |
| 10 | 10 | ||
| 11 | -export const editUser = params => { return http.put(`/user/edit`,params)}; | ||
| 12 | export const editPass = params => { return http.put(`${baseUrl}/password`,params)}; | 11 | export const editPass = params => { return http.put(`${baseUrl}/password`,params)}; |
| 13 | 12 | ||
| 14 | -export const addUser = params => { return http.post(`/user/add`,params)}; | 13 | +export const editUser = params => { return http.put(`${baseUrl}/edit`,params)}; |
| 15 | 14 | ||
| 16 | -export const setUserRole = params => { return http.put(`/user/roleset`,params)}; | 15 | +export const addUser = params => { return http.post(`${baseUrl}/add`,params)}; |
| 16 | + | ||
| 17 | +export const setUserRole = params => { return http.put(`${baseUrl}/roleset`,params)}; |
| 1 | var SIGN_REGEXP = /([yMdhsm])(\1*)/g; | 1 | var SIGN_REGEXP = /([yMdhsm])(\1*)/g; |
| 2 | var DEFAULT_PATTERN = 'yyyy-MM-dd'; | 2 | var DEFAULT_PATTERN = 'yyyy-MM-dd'; |
| 3 | +/** | ||
| 4 | + * 根据数组 元素的“值” 来删除或者获取数据 | ||
| 5 | + * 使用方法arrList.splice(arrList.contains('c'),1) | ||
| 6 | + */ | ||
| 7 | +Array.prototype.contains = function(obj) { | ||
| 8 | + var i = this.length; | ||
| 9 | + while (i--) { | ||
| 10 | + if (this[i] === obj) { | ||
| 11 | + return i; // 返回的这个 i 就是元素的索引下标, | ||
| 12 | + } | ||
| 13 | + } | ||
| 14 | + return false; | ||
| 15 | +} | ||
| 3 | 16 | ||
| 4 | function padding(s, len) { | 17 | function padding(s, len) { |
| 5 | - var len = len - (s + '').length; | 18 | + len = len - (s + '').length; |
| 6 | for (var i = 0; i < len; i++) { s = '0' + s; } | 19 | for (var i = 0; i < len; i++) { s = '0' + s; } |
| 7 | return s; | 20 | return s; |
| 8 | -}; | 21 | +} |
| 9 | 22 | ||
| 10 | export default { | 23 | export default { |
| 11 | getQueryStringByName: function (name) { | 24 | getQueryStringByName: function (name) { |
| @@ -91,12 +91,9 @@ axios.interceptors.response.use( | @@ -91,12 +91,9 @@ axios.interceptors.response.use( | ||
| 91 | 91 | ||
| 92 | // 下面是接口回调的satus ,因为我做了一些错误页面,所以都会指向对应的报错页面 | 92 | // 下面是接口回调的satus ,因为我做了一些错误页面,所以都会指向对应的报错页面 |
| 93 | if (error.response.status === 401) { | 93 | if (error.response.status === 401) { |
| 94 | - router.push({ | ||
| 95 | - path: "/login" | ||
| 96 | - }); | ||
| 97 | message({ | 94 | message({ |
| 98 | // 饿了么的消息弹窗组件 | 95 | // 饿了么的消息弹窗组件 |
| 99 | - message: '授权超时,或未授权,请重新登录', | 96 | + message: '授权超时,或访问未授权,请重新登录', |
| 100 | type: "error" | 97 | type: "error" |
| 101 | }); | 98 | }); |
| 102 | } | 99 | } |
| @@ -108,9 +105,14 @@ axios.interceptors.response.use( | @@ -108,9 +105,14 @@ axios.interceptors.response.use( | ||
| 108 | }); | 105 | }); |
| 109 | } | 106 | } |
| 110 | if (error.response.status === 500) { | 107 | if (error.response.status === 500) { |
| 111 | - router.push({ | ||
| 112 | - path: "/error/500" | 108 | + message({ |
| 109 | + // 饿了么的消息弹窗组件 | ||
| 110 | + message: error.message, | ||
| 111 | + type: "error" | ||
| 113 | }); | 112 | }); |
| 113 | + // router.push({ | ||
| 114 | + // path: "/error/500" | ||
| 115 | + // }); | ||
| 114 | } | 116 | } |
| 115 | if (error.response.status === 502) { | 117 | if (error.response.status === 502) { |
| 116 | router.push({ | 118 | router.push({ |
| @@ -118,13 +120,15 @@ axios.interceptors.response.use( | @@ -118,13 +120,15 @@ axios.interceptors.response.use( | ||
| 118 | }); | 120 | }); |
| 119 | } | 121 | } |
| 120 | if (error.response.status === 404) { | 122 | if (error.response.status === 404) { |
| 121 | - router.push({ | ||
| 122 | - path: "/error/404" | 123 | + message({ |
| 124 | + // 饿了么的消息弹窗组件 | ||
| 125 | + message: error.message, | ||
| 126 | + type: "error" | ||
| 123 | }); | 127 | }); |
| 124 | } | 128 | } |
| 125 | } | 129 | } |
| 126 | // 返回 response 里的错误信息 | 130 | // 返回 response 里的错误信息 |
| 127 | - let errorInfo = error.data.error ? error.data.error.message : error.data; | 131 | + let errorInfo = error.response ? error.response.statusText : (error.data.error ? error.data.error.message : error.message); |
| 128 | return Promise.reject(errorInfo); | 132 | return Promise.reject(errorInfo); |
| 129 | } | 133 | } |
| 130 | ); | 134 | ); |
| @@ -35,7 +35,6 @@ import Waybill from './views/nmms_import/Waybill.vue' | @@ -35,7 +35,6 @@ import Waybill from './views/nmms_import/Waybill.vue' | ||
| 35 | import AllocateSearch from './views/nmms_import/AllocateSearch.vue' | 35 | import AllocateSearch from './views/nmms_import/AllocateSearch.vue' |
| 36 | import Importallocation from './views/nmms_import/Importallocation.vue' | 36 | import Importallocation from './views/nmms_import/Importallocation.vue' |
| 37 | import Allocatearrive from './views/nmms_import/Allocatearrive.vue' | 37 | import Allocatearrive from './views/nmms_import/Allocatearrive.vue' |
| 38 | - | ||
| 39 | import User from './views/nav1/user.vue' | 38 | import User from './views/nav1/user.vue' |
| 40 | import Page4 from './views/nav2/Page4.vue' | 39 | import Page4 from './views/nav2/Page4.vue' |
| 41 | import Page5 from './views/nav2/Page5.vue' | 40 | import Page5 from './views/nav2/Page5.vue' |
| @@ -128,7 +127,7 @@ let routes = [ | @@ -128,7 +127,7 @@ let routes = [ | ||
| 128 | {path:'/entertall',component:EnterTally,name:'进港理货'}, | 127 | {path:'/entertall',component:EnterTally,name:'进港理货'}, |
| 129 | {path:'/tallymaster',component:TallyMster,name:'进港理货舱单'}, | 128 | {path:'/tallymaster',component:TallyMster,name:'进港理货舱单'}, |
| 130 | {path:'/importallocation',component:Importallocation,name:'进港分拨'}, | 129 | {path:'/importallocation',component:Importallocation,name:'进港分拨'}, |
| 131 | - {path:'/allocatearrive',component:Allocatearrive,name:'分拨运抵'} | 130 | + {path:'/allocatearrive',component:Allocatearrive,name:'分拨运抵'}, |
| 132 | ] | 131 | ] |
| 133 | }, | 132 | }, |
| 134 | { | 133 | { |
| @@ -99,3 +99,14 @@ export function validatorNum(value) { | @@ -99,3 +99,14 @@ export function validatorNum(value) { | ||
| 99 | const reg = /^(\d*)+(\.[0-9]{1,2})?$/ | 99 | const reg = /^(\d*)+(\.[0-9]{1,2})?$/ |
| 100 | return reg.test(value) | 100 | return reg.test(value) |
| 101 | } | 101 | } |
| 102 | + | ||
| 103 | + | ||
| 104 | +/** | ||
| 105 | + * 关区校验 4位数字 | ||
| 106 | + * @param value | ||
| 107 | + * @returns {boolean} | ||
| 108 | + */ | ||
| 109 | +export function validatorCustomsNum(value) { | ||
| 110 | + const reg = /^(\d{4})$/ | ||
| 111 | + return reg.test(value) | ||
| 112 | +} |
| 1 | <template> | 1 | <template> |
| 2 | - <el-row class="container"> | 2 | + <el-row class="container darkmenu" style="margin-top: 0px;"> |
| 3 | <el-col :span="24" class="header"> | 3 | <el-col :span="24" class="header"> |
| 4 | <el-col :span="10" class="logo" :class="collapsed?'logo-collapse-width':'logo-width'"> | 4 | <el-col :span="10" class="logo" :class="collapsed?'logo-collapse-width':'logo-width'"> |
| 5 | {{collapsed?'':sysName}} | 5 | {{collapsed?'':sysName}} |
| @@ -80,7 +80,7 @@ | @@ -80,7 +80,7 @@ | ||
| 80 | </el-col> | 80 | </el-col> |
| 81 | <el-col :span="24" class="content-wrapper"> | 81 | <el-col :span="24" class="content-wrapper"> |
| 82 | <transition name="fade" mode="out-in"> | 82 | <transition name="fade" mode="out-in"> |
| 83 | - <router-view></router-view> | 83 | + <router-view :key="$route.path +$route.query.t"></router-view> |
| 84 | </transition> | 84 | </transition> |
| 85 | </el-col> | 85 | </el-col> |
| 86 | </div> | 86 | </div> |
| @@ -94,6 +94,12 @@ | @@ -94,6 +94,12 @@ | ||
| 94 | import { editPass} from '../api/user'; | 94 | import { editPass} from '../api/user'; |
| 95 | import ElFormItem from "element-ui/packages/form/src/form-item"; | 95 | import ElFormItem from "element-ui/packages/form/src/form-item"; |
| 96 | export default { | 96 | export default { |
| 97 | + | ||
| 98 | + provide() { | ||
| 99 | + return { | ||
| 100 | + reload: this.reload | ||
| 101 | + } | ||
| 102 | + }, | ||
| 97 | components: {ElFormItem}, | 103 | components: {ElFormItem}, |
| 98 | data() { | 104 | data() { |
| 99 | var validatePass = (rule, value, callback) => { | 105 | var validatePass = (rule, value, callback) => { |
| @@ -120,6 +126,7 @@ | @@ -120,6 +126,7 @@ | ||
| 120 | sysUserName: '', | 126 | sysUserName: '', |
| 121 | sysUserId:'', | 127 | sysUserId:'', |
| 122 | sysUserAvatar: '', | 128 | sysUserAvatar: '', |
| 129 | + isRouterAlive: true, | ||
| 123 | form: { | 130 | form: { |
| 124 | name: '', | 131 | name: '', |
| 125 | region: '', | 132 | region: '', |
| @@ -150,6 +157,16 @@ | @@ -150,6 +157,16 @@ | ||
| 150 | } | 157 | } |
| 151 | }, | 158 | }, |
| 152 | methods: { | 159 | methods: { |
| 160 | + reload() { | ||
| 161 | + this.$nextTick(function () { | ||
| 162 | + this.$router.push({ | ||
| 163 | + path: this.$router.path, | ||
| 164 | + query:{ | ||
| 165 | + t: new Date().getTime() | ||
| 166 | + } | ||
| 167 | + }) | ||
| 168 | + }) | ||
| 169 | + }, | ||
| 153 | editPass:function(){ | 170 | editPass:function(){ |
| 154 | this.dialogFormVisible=true; | 171 | this.dialogFormVisible=true; |
| 155 | }, | 172 | }, |
| @@ -190,7 +207,7 @@ | @@ -190,7 +207,7 @@ | ||
| 190 | console.log('handleclose'); | 207 | console.log('handleclose'); |
| 191 | }, | 208 | }, |
| 192 | handleselect: function (a, b) { | 209 | handleselect: function (a, b) { |
| 193 | - console.log('handleselect!'); | 210 | + this.reload() |
| 194 | }, | 211 | }, |
| 195 | //退出登录 | 212 | //退出登录 |
| 196 | logout: function () { | 213 | logout: function () { |
| @@ -200,7 +217,6 @@ | @@ -200,7 +217,6 @@ | ||
| 200 | }).then(() => { | 217 | }).then(() => { |
| 201 | sessionStorage.removeItem('user'); | 218 | sessionStorage.removeItem('user'); |
| 202 | sessionStorage.removeItem('menu'); | 219 | sessionStorage.removeItem('menu'); |
| 203 | - | ||
| 204 | //退出后初始化原来的路由 | 220 | //退出后初始化原来的路由 |
| 205 | let sysRoutes = JSON.parse(sessionStorage.getItem('sysMenu')); | 221 | let sysRoutes = JSON.parse(sessionStorage.getItem('sysMenu')); |
| 206 | console.log(sysRoutes); | 222 | console.log(sysRoutes); |
| @@ -227,7 +243,6 @@ | @@ -227,7 +243,6 @@ | ||
| 227 | if (user) { | 243 | if (user) { |
| 228 | user = JSON.parse(user); | 244 | user = JSON.parse(user); |
| 229 | this.sysUserName = user.username || ''; | 245 | this.sysUserName = user.username || ''; |
| 230 | - this.sysUserId=user.userId||''; | ||
| 231 | this.sysUserAvatar = user.userface || '/static/images/faceDefault.jpg'; | 246 | this.sysUserAvatar = user.userface || '/static/images/faceDefault.jpg'; |
| 232 | } | 247 | } |
| 233 | //操作路由,判断本地存储的用户栏目列表是否存在,如果存在则加载路由 | 248 | //操作路由,判断本地存储的用户栏目列表是否存在,如果存在则加载路由 |
| @@ -245,7 +260,6 @@ | @@ -245,7 +260,6 @@ | ||
| 245 | 260 | ||
| 246 | <style scoped lang="scss"> | 261 | <style scoped lang="scss"> |
| 247 | @import '~scss_vars'; | 262 | @import '~scss_vars'; |
| 248 | - | ||
| 249 | .container { | 263 | .container { |
| 250 | position: absolute; | 264 | position: absolute; |
| 251 | top: 0px; | 265 | top: 0px; |
| @@ -254,7 +268,7 @@ | @@ -254,7 +268,7 @@ | ||
| 254 | .header { | 268 | .header { |
| 255 | height: 60px; | 269 | height: 60px; |
| 256 | line-height: 60px; | 270 | line-height: 60px; |
| 257 | - background: $color-primary; | 271 | + background: $color-primary url("/static/images/air-banner.png"); |
| 258 | color:#fff; | 272 | color:#fff; |
| 259 | .userinfo { | 273 | .userinfo { |
| 260 | text-align: right; | 274 | text-align: right; |
| @@ -317,9 +331,6 @@ | @@ -317,9 +331,6 @@ | ||
| 317 | // position: absolute; | 331 | // position: absolute; |
| 318 | // top: 0px; | 332 | // top: 0px; |
| 319 | // bottom: 0px; | 333 | // bottom: 0px; |
| 320 | - .el-menu{ | ||
| 321 | - height: 100%; | ||
| 322 | - } | ||
| 323 | .collapsed{ | 334 | .collapsed{ |
| 324 | width:60px; | 335 | width:60px; |
| 325 | .item{ | 336 | .item{ |
| @@ -356,16 +367,21 @@ | @@ -356,16 +367,21 @@ | ||
| 356 | // bottom: 0px; | 367 | // bottom: 0px; |
| 357 | // left: 230px; | 368 | // left: 230px; |
| 358 | overflow-y: scroll; | 369 | overflow-y: scroll; |
| 359 | - padding: 20px; | 370 | + padding: 10px; |
| 360 | .breadcrumb-container { | 371 | .breadcrumb-container { |
| 361 | //margin-bottom: 15px; | 372 | //margin-bottom: 15px; |
| 362 | .title { | 373 | .title { |
| 363 | width: 200px; | 374 | width: 200px; |
| 364 | float: left; | 375 | float: left; |
| 365 | color: #475669; | 376 | color: #475669; |
| 377 | + margin-left: 10px; | ||
| 366 | } | 378 | } |
| 367 | .breadcrumb-inner { | 379 | .breadcrumb-inner { |
| 368 | float: right; | 380 | float: right; |
| 381 | + margin-right:10px; | ||
| 382 | + } | ||
| 383 | + .el-breadcrumb{ | ||
| 384 | + line-height:36px; | ||
| 369 | } | 385 | } |
| 370 | } | 386 | } |
| 371 | .content-wrapper { | 387 | .content-wrapper { |
| @@ -376,3 +392,41 @@ | @@ -376,3 +392,41 @@ | ||
| 376 | } | 392 | } |
| 377 | } | 393 | } |
| 378 | </style> | 394 | </style> |
| 395 | +<style lang="scss"> | ||
| 396 | + .darkmenu{ | ||
| 397 | + .main { | ||
| 398 | + aside { | ||
| 399 | + .el-menu{ | ||
| 400 | + height: 100%; | ||
| 401 | + background: #606060; | ||
| 402 | + .el-menu-item { | ||
| 403 | + i{ | ||
| 404 | + color: white; | ||
| 405 | + } | ||
| 406 | + color: white; | ||
| 407 | + } | ||
| 408 | + .el-menu-item.is-active{ | ||
| 409 | + color:#e6a23c; | ||
| 410 | + } | ||
| 411 | + .el-menu-item:hover,.el-menu-item:focus{ | ||
| 412 | + background-color: #1a4496; | ||
| 413 | + } | ||
| 414 | + .el-submenu { | ||
| 415 | + ul.el-menu.el-menu--inline{ | ||
| 416 | + background: #303030; | ||
| 417 | + } | ||
| 418 | + .el-submenu__title { | ||
| 419 | + color: white; | ||
| 420 | + i{ | ||
| 421 | + color: white; | ||
| 422 | + } | ||
| 423 | + } | ||
| 424 | + .el-submenu__title:hover { | ||
| 425 | + background-color: #1a4496; | ||
| 426 | + } | ||
| 427 | + } | ||
| 428 | + } | ||
| 429 | + } | ||
| 430 | + } | ||
| 431 | + } | ||
| 432 | +</style> |
| @@ -3,12 +3,12 @@ | @@ -3,12 +3,12 @@ | ||
| 3 | <el-form :model="ruleForm2" :rules="rules2" ref="ruleForm2" label-position="left" label-width="0px" class="demo-ruleForm login-container" id="loginForm"> | 3 | <el-form :model="ruleForm2" :rules="rules2" ref="ruleForm2" label-position="left" label-width="0px" class="demo-ruleForm login-container" id="loginForm"> |
| 4 | <h3 class="title">系统登录</h3> | 4 | <h3 class="title">系统登录</h3> |
| 5 | <el-form-item prop="account"> | 5 | <el-form-item prop="account"> |
| 6 | - <el-input type="text" v-model="ruleForm2.account" auto-complete="off" placeholder="账号"></el-input> | 6 | + <el-input type="text" v-model="ruleForm2.account" autofocus placeholder="账号"></el-input> |
| 7 | </el-form-item> | 7 | </el-form-item> |
| 8 | <el-form-item prop="checkPass"> | 8 | <el-form-item prop="checkPass"> |
| 9 | - <el-input type="password" v-model="ruleForm2.checkPass" auto-complete="off" placeholder="密码"></el-input> | 9 | + <el-input type="password" v-model="ruleForm2.checkPass" placeholder="密码" @keyup.enter.native="handleSubmit2"></el-input> |
| 10 | </el-form-item> | 10 | </el-form-item> |
| 11 | - <el-checkbox v-model="checked" checked class="remember">记住密码</el-checkbox> | 11 | + <el-checkbox v-model="checked" checked class="remeberme">记住密码</el-checkbox> |
| 12 | <el-form-item style="width:100%;"> | 12 | <el-form-item style="width:100%;"> |
| 13 | <el-button type="primary" style="width:100%;" @click.native.prevent="handleSubmit2" :loading="logining" :plain="true">登录</el-button> | 13 | <el-button type="primary" style="width:100%;" @click.native.prevent="handleSubmit2" :loading="logining" :plain="true">登录</el-button> |
| 14 | <!--<el-button @click.native.prevent="handleReset2">重置</el-button>--> | 14 | <!--<el-button @click.native.prevent="handleReset2">重置</el-button>--> |
| @@ -42,8 +42,8 @@ | @@ -42,8 +42,8 @@ | ||
| 42 | fixStyle: '', | 42 | fixStyle: '', |
| 43 | logining: false, | 43 | logining: false, |
| 44 | ruleForm2: { | 44 | ruleForm2: { |
| 45 | - account: 'admin', | ||
| 46 | - checkPass: '123456' | 45 | + account: '', |
| 46 | + checkPass: '' | ||
| 47 | }, | 47 | }, |
| 48 | rules2: { | 48 | rules2: { |
| 49 | account: [ | 49 | account: [ |
| @@ -955,9 +955,6 @@ export default { | @@ -955,9 +955,6 @@ export default { | ||
| 955 | margin-bottom: 0; | 955 | margin-bottom: 0; |
| 956 | } | 956 | } |
| 957 | } | 957 | } |
| 958 | - .el-col { | ||
| 959 | - border-radius: 4px; | ||
| 960 | - } | ||
| 961 | .bg-purple-dark { | 958 | .bg-purple-dark { |
| 962 | background: #99a9bf; | 959 | background: #99a9bf; |
| 963 | } | 960 | } |
| @@ -968,7 +965,6 @@ export default { | @@ -968,7 +965,6 @@ export default { | ||
| 968 | background: #e5e9f2; | 965 | background: #e5e9f2; |
| 969 | } | 966 | } |
| 970 | .grid-content { | 967 | .grid-content { |
| 971 | - border-radius: 4px; | ||
| 972 | min-height: 36px; | 968 | min-height: 36px; |
| 973 | } | 969 | } |
| 974 | .row-bg { | 970 | .row-bg { |
| @@ -32,7 +32,9 @@ | @@ -32,7 +32,9 @@ | ||
| 32 | </el-table-column> | 32 | </el-table-column> |
| 33 | <el-table-column prop="modelnamecn" label="操作模块" width="120" sortable> | 33 | <el-table-column prop="modelnamecn" label="操作模块" width="120" sortable> |
| 34 | </el-table-column> | 34 | </el-table-column> |
| 35 | - <el-table-column prop="classname" label="系统类" show-overflow-tooltip="true" width="100" sortable> | 35 | + <el-table-column prop="classname" label="系统类" show-overflow-tooltip width="100" sortable> |
| 36 | + </el-table-column> | ||
| 37 | + <el-table-column prop="parameters" label="参数" show-overflow-tooltip width="100" sortable> | ||
| 36 | </el-table-column> | 38 | </el-table-column> |
| 37 | <el-table-column prop="result" label="操作结果" min-width="200" sortable> | 39 | <el-table-column prop="result" label="操作结果" min-width="200" sortable> |
| 38 | </el-table-column> | 40 | </el-table-column> |
| @@ -16,22 +16,26 @@ | @@ -16,22 +16,26 @@ | ||
| 16 | </el-col> | 16 | </el-col> |
| 17 | 17 | ||
| 18 | <!--列表--> | 18 | <!--列表--> |
| 19 | - <el-table :data="tableList" highlight-current-row v-loading="listLoading" @selection-change="selsChange" style="width: 100%;"> | 19 | + <el-table :data="tableList" highlight-current-row v-loading="listLoading" @selection-change="selsChange" style="width: 100%;" |
| 20 | + row-key="permissionId" | ||
| 21 | + border | ||
| 22 | + :tree-props="{children: 'children', hasChildren: 'hasChildren'}" | ||
| 23 | + > | ||
| 20 | <el-table-column type="selection" width="55"> | 24 | <el-table-column type="selection" width="55"> |
| 21 | </el-table-column> | 25 | </el-table-column> |
| 22 | - <el-table-column type="index" width="60"> | 26 | + <!--<el-table-column type="index" width="60">--> |
| 27 | + <!--</el-table-column>--> | ||
| 28 | + <el-table-column prop="permissionId" label="ID" width="130" sortable> | ||
| 23 | </el-table-column> | 29 | </el-table-column> |
| 24 | - <el-table-column prop="permissionId" label="ID" width="100" sortable> | 30 | + <el-table-column prop="name" label="权限名称" min-width="150" sortable> |
| 25 | </el-table-column> | 31 | </el-table-column> |
| 26 | - <el-table-column prop="name" label="权限名称" min-width="200" sortable> | 32 | + <el-table-column prop="description" label="描述" min-width="120" sortable> |
| 27 | </el-table-column> | 33 | </el-table-column> |
| 28 | - <el-table-column prop="description" label="描述" min-width="200" sortable> | 34 | + <el-table-column prop="ismenu" label="是否目录" width="100" :formatter="formatState" sortable> |
| 29 | </el-table-column> | 35 | </el-table-column> |
| 30 | - <el-table-column prop="permissionOrder" label="排序" width="100" sortable> | 36 | + <el-table-column prop="url" label="访问路径" width="300" sortable> |
| 31 | </el-table-column> | 37 | </el-table-column> |
| 32 | - <el-table-column prop="url" label="路径" width="100" sortable> | ||
| 33 | - </el-table-column> | ||
| 34 | - <el-table-column label="操作" min-width="150"> | 38 | + <el-table-column label="操作" min-width="100"> |
| 35 | <template slot-scope="scope"> | 39 | <template slot-scope="scope"> |
| 36 | <el-button size="small" @click="handleEdit(scope.$index, scope.row)">编辑</el-button> | 40 | <el-button size="small" @click="handleEdit(scope.$index, scope.row)">编辑</el-button> |
| 37 | <el-button type="danger" size="small" @click="handleDel(scope.$index, scope.row)">删除</el-button> | 41 | <el-button type="danger" size="small" @click="handleDel(scope.$index, scope.row)">删除</el-button> |
| @@ -143,7 +147,7 @@ | @@ -143,7 +147,7 @@ | ||
| 143 | tableList: [], | 147 | tableList: [], |
| 144 | total: 0, | 148 | total: 0, |
| 145 | pageNum: 1, | 149 | pageNum: 1, |
| 146 | - pageSize: 10, | 150 | + pageSize: 100, |
| 147 | listLoading: false, | 151 | listLoading: false, |
| 148 | sels: [],//列表选中列 | 152 | sels: [],//列表选中列 |
| 149 | //编辑界面是否显示 | 153 | //编辑界面是否显示 |
| @@ -208,7 +212,7 @@ | @@ -208,7 +212,7 @@ | ||
| 208 | return row.sex == 1 ? '男' : row.sex == 0 ? '女' : '未知'; | 212 | return row.sex == 1 ? '男' : row.sex == 0 ? '女' : '未知'; |
| 209 | }, | 213 | }, |
| 210 | formatState: function (row, column) { | 214 | formatState: function (row, column) { |
| 211 | - return row.state == true ? '是' : row.state == false ? '否' : '未知'; | 215 | + return row.ismenu == true ? '是' : row.ismenu == false ? '否' : '未知'; |
| 212 | }, | 216 | }, |
| 213 | handleCurrentChange(val) { | 217 | handleCurrentChange(val) { |
| 214 | this.pageNum = val; | 218 | this.pageNum = val; |
| @@ -23,18 +23,27 @@ | @@ -23,18 +23,27 @@ | ||
| 23 | :tree-props="{children: 'children', hasChildren: 'hasChildren'}"> | 23 | :tree-props="{children: 'children', hasChildren: 'hasChildren'}"> |
| 24 | <el-table-column type="selection" width="55"> | 24 | <el-table-column type="selection" width="55"> |
| 25 | </el-table-column> | 25 | </el-table-column> |
| 26 | - <el-table-column type="index" width="60"> | ||
| 27 | - </el-table-column> | ||
| 28 | - <!--<el-table-column prop="roleId" label="ID" width="100" sortable>--> | 26 | + <!--<el-table-column type="index" width="60">--> |
| 29 | <!--</el-table-column>--> | 27 | <!--</el-table-column>--> |
| 28 | + <el-table-column prop="roleId" label="ID" width="120"> | ||
| 29 | + </el-table-column> | ||
| 30 | <el-table-column prop="roleName" label="岗位/角色名称" min-width="200" sortable> | 30 | <el-table-column prop="roleName" label="岗位/角色名称" min-width="200" sortable> |
| 31 | </el-table-column> | 31 | </el-table-column> |
| 32 | <!--<el-table-column prop="departmentName" label="部门名称" min-width="200" sortable>--> | 32 | <!--<el-table-column prop="departmentName" label="部门名称" min-width="200" sortable>--> |
| 33 | <!--</el-table-column>--> | 33 | <!--</el-table-column>--> |
| 34 | - <el-table-column prop="description" label="描述" min-width="200" sortable> | 34 | + <el-table-column prop="description" label="描述" min-width="160" > |
| 35 | + </el-table-column> | ||
| 36 | + <el-table-column prop="type" label="类型" min-width="80" sortable> | ||
| 37 | + </el-table-column> | ||
| 38 | + <el-table-column prop="businessLicense" label="工商代码" min-width="180" > | ||
| 39 | + </el-table-column> | ||
| 40 | + <el-table-column prop="customsRegCode" label="海关备案代码" min-width="150" > | ||
| 41 | + </el-table-column> | ||
| 42 | + <el-table-column prop="mqcode" label="海关通道编号" min-width="150" > | ||
| 35 | </el-table-column> | 43 | </el-table-column> |
| 36 | <el-table-column label="操作" min-width="260"> | 44 | <el-table-column label="操作" min-width="260"> |
| 37 | <template slot-scope="scope"> | 45 | <template slot-scope="scope"> |
| 46 | + <el-button type="primary" size="small" @click="handleAdd(scope.$index, scope.row)">新增下级</el-button> | ||
| 38 | <el-button size="small" @click="setPerm(scope.$index, scope.row)">设置权限</el-button> | 47 | <el-button size="small" @click="setPerm(scope.$index, scope.row)">设置权限</el-button> |
| 39 | <el-button size="small" @click="handleEdit(scope.$index, scope.row)">编辑</el-button> | 48 | <el-button size="small" @click="handleEdit(scope.$index, scope.row)">编辑</el-button> |
| 40 | <el-button type="danger" size="small" @click="handleDel(scope.$index, scope.row)">删除</el-button> | 49 | <el-button type="danger" size="small" @click="handleDel(scope.$index, scope.row)">删除</el-button> |
| @@ -48,67 +57,57 @@ | @@ -48,67 +57,57 @@ | ||
| 48 | </el-pagination> | 57 | </el-pagination> |
| 49 | </el-col> | 58 | </el-col> |
| 50 | 59 | ||
| 51 | - <!--编辑界面--> | ||
| 52 | - <el-dialog title="编辑" :visible.sync="editFormVisible" :close-on-click-modal="false"> | ||
| 53 | - <el-form :model="editForm" label-width="80px" :rules="editFormRules" ref="editForm"> | ||
| 54 | - <el-form-item label="ID"> | ||
| 55 | - <span>{{editForm.roleId}}</span> | 60 | + <!--新增界面--> |
| 61 | + <el-dialog :title="dialogMap[dialogStatus]" :visible.sync="addFormVisible" :close-on-click-modal="false"> | ||
| 62 | + <el-form :model="addForm" label-width="120px" :rules="addFormRules" ref="addForm"> | ||
| 63 | + <el-form-item label="上级组织机构"> | ||
| 64 | + <span>{{addForm.parentName}}</span> | ||
| 56 | </el-form-item> | 65 | </el-form-item> |
| 57 | - <el-form-item label="岗位名称"> | ||
| 58 | - <el-input v-model="editForm.roleName" auto-complete="off" placeholder="请输入岗位/角色名称:例如:ROLE_name"></el-input> | 66 | + <el-form-item label="组织机构名称" prop="roleName"> |
| 67 | + <el-input v-model="addForm.roleName" auto-complete="off" placeholder="请输入组织机构名称:例如:公司名称"></el-input> | ||
| 59 | </el-form-item> | 68 | </el-form-item> |
| 60 | - <el-form-item label="岗位描述"> | ||
| 61 | - <el-input v-model="editForm.description" auto-complete="off" placeholder="请输入岗位/角色描述:例如:用户管理员"></el-input> | 69 | + <el-form-item label="组织机构描述" prop="description"> |
| 70 | + <el-input v-model="addForm.description" auto-complete="off" placeholder="组织机构描述:例如:组织机构简介"></el-input> | ||
| 62 | </el-form-item> | 71 | </el-form-item> |
| 63 | - <el-form-item label="部门名称"> | ||
| 64 | - <el-select v-model="editForm.departmentId" placeholder="请选择"> | 72 | + <el-form-item label="组织机构类型" prop="type"> |
| 73 | + <el-select | ||
| 74 | + v-model="addForm.type" | ||
| 75 | + filterable | ||
| 76 | + allow-create | ||
| 77 | + default-first-option | ||
| 78 | + placeholder="请选择类型"> | ||
| 65 | <el-option | 79 | <el-option |
| 66 | - v-for="item in departmentNameList" | ||
| 67 | - :key="item.departmentId" | ||
| 68 | - :label="item.departmentName" | ||
| 69 | - :value="item.departmentId"> | 80 | + v-for="item in companyOption" |
| 81 | + :key="item.value" | ||
| 82 | + :label="item.label" | ||
| 83 | + :value="item.value"> | ||
| 70 | </el-option> | 84 | </el-option> |
| 71 | </el-select> | 85 | </el-select> |
| 72 | </el-form-item> | 86 | </el-form-item> |
| 73 | - </el-form> | ||
| 74 | - <div slot="footer" class="dialog-footer"> | ||
| 75 | - <el-button @click.native="editFormVisible = false">取消</el-button> | ||
| 76 | - <el-button type="primary" @click.native="editSubmit" :loading="editLoading">提交</el-button> | ||
| 77 | - </div> | ||
| 78 | - </el-dialog> | ||
| 79 | - | ||
| 80 | - <!--新增界面--> | ||
| 81 | - <el-dialog title="新增" :visible.sync="addFormVisible" :close-on-click-modal="false"> | ||
| 82 | - <el-form :model="addForm" label-width="80px" :rules="addFormRules" ref="addForm"> | ||
| 83 | - <el-form-item label="岗位/角色名称" prop="roleName"> | ||
| 84 | - <el-input v-model="addForm.roleName" auto-complete="off" placeholder="请输入岗位/角色名称:例如:ROLE_name"></el-input> | 87 | + <el-form-item label="工商企业代码" prop="businessLicense"> |
| 88 | + <el-input v-model="addForm.businessLicense" auto-complete="off" placeholder="社会信用代码或者组织机构代码"></el-input> | ||
| 85 | </el-form-item> | 89 | </el-form-item> |
| 86 | - <el-form-item label="岗位/角色描述" prop="description"> | ||
| 87 | - <el-input v-model="addForm.description" auto-complete="off" placeholder="请输入岗位/角色描述:例如:用户管理员"></el-input> | 90 | + <el-form-item label="海关备案代码" prop="customsRegCode"> |
| 91 | + <el-input v-model="addForm.customsRegCode" auto-complete="off" placeholder="海关备案后返回的备案代码"></el-input> | ||
| 88 | </el-form-item> | 92 | </el-form-item> |
| 89 | - <el-form-item label="部门名称" prop="roleSign"> | ||
| 90 | - <el-select v-model="addForm.departmentId" placeholder="请选择"> | ||
| 91 | - <el-option | ||
| 92 | - v-for="item in departmentNameList" | ||
| 93 | - :key="item.departmentId" | ||
| 94 | - :label="item.departmentName" | ||
| 95 | - :value="item.departmentId"> | ||
| 96 | - </el-option> | ||
| 97 | - </el-select> | 93 | + <el-form-item label="海关通道编号" prop="mqcode"> |
| 94 | + <el-input v-model="addForm.mqcode" auto-complete="off" placeholder="海关通道编号"></el-input> | ||
| 98 | </el-form-item> | 95 | </el-form-item> |
| 99 | </el-form> | 96 | </el-form> |
| 100 | <div slot="footer" class="dialog-footer"> | 97 | <div slot="footer" class="dialog-footer"> |
| 101 | <el-button @click.native="addFormVisible = false">取消</el-button> | 98 | <el-button @click.native="addFormVisible = false">取消</el-button> |
| 102 | - <el-button type="primary" @click.native="addSubmit" :loading="addLoading">提交</el-button> | 99 | + <el-button type="primary" @click="dialogStatus==='create'?addSubmit():editSubmit()" :loading="addLoading" >提交</el-button> |
| 103 | </div> | 100 | </div> |
| 104 | </el-dialog> | 101 | </el-dialog> |
| 105 | 102 | ||
| 106 | <!--权限设置界面--> | 103 | <!--权限设置界面--> |
| 107 | <el-dialog title="岗位的权限设置" :visible.sync="PermFormVisible" :close-on-click-modal="false"> | 104 | <el-dialog title="岗位的权限设置" :visible.sync="PermFormVisible" :close-on-click-modal="false"> |
| 108 | <el-form :model="permForm" label-width="80px" ref="permForm"> | 105 | <el-form :model="permForm" label-width="80px" ref="permForm"> |
| 109 | - <el-checkbox-group v-model="permIds" size="small"> | ||
| 110 | - <el-checkbox v-for="perm in permissons" :label="perm.permissionId" :key="perm.permissionId">{{perm.name}}</el-checkbox> | ||
| 111 | - </el-checkbox-group> | 106 | + <el-tree :data="permissons" :props="treeDefaultProps" |
| 107 | + @check="clickDeal" | ||
| 108 | + show-checkbox highlight-current default-expand-all check-on-click-node check-strictly | ||
| 109 | + node-key="permissionId" ref="tree"> | ||
| 110 | + </el-tree> | ||
| 112 | </el-form> | 111 | </el-form> |
| 113 | <div slot="footer" class="dialog-footer"> | 112 | <div slot="footer" class="dialog-footer"> |
| 114 | <el-button @click.native="PermFormVisible = false">取消</el-button> | 113 | <el-button @click.native="PermFormVisible = false">取消</el-button> |
| @@ -131,6 +130,20 @@ | @@ -131,6 +130,20 @@ | ||
| 131 | filters: { | 130 | filters: { |
| 132 | roleName: '' | 131 | roleName: '' |
| 133 | }, | 132 | }, |
| 133 | + companyOption: [ | ||
| 134 | + { | ||
| 135 | + label: "集团", | ||
| 136 | + value: "集团" | ||
| 137 | + }, | ||
| 138 | + { | ||
| 139 | + label: "公司", | ||
| 140 | + value: "公司" | ||
| 141 | + } | ||
| 142 | + ], | ||
| 143 | + treeDefaultProps: { | ||
| 144 | + children: 'children', | ||
| 145 | + label: 'name', | ||
| 146 | + }, | ||
| 134 | departmentNameList:[], | 147 | departmentNameList:[], |
| 135 | roles: [], | 148 | roles: [], |
| 136 | permissons: [], | 149 | permissons: [], |
| @@ -140,23 +153,11 @@ | @@ -140,23 +153,11 @@ | ||
| 140 | pageSize: 5, | 153 | pageSize: 5, |
| 141 | listLoading: false, | 154 | listLoading: false, |
| 142 | sels: [],//列表选中列 | 155 | sels: [],//列表选中列 |
| 143 | - //编辑界面是否显示 | ||
| 144 | - editFormVisible: false, | ||
| 145 | - editLoading: false, | ||
| 146 | - editFormRules: { | ||
| 147 | - roleName: [ | ||
| 148 | - { required: true, message: '请输入岗位/角色名称', trigger: 'blur' } | ||
| 149 | - ] | ||
| 150 | - }, | ||
| 151 | - //编辑界面数据 | ||
| 152 | - editForm: { | ||
| 153 | - roleId: 1, | ||
| 154 | - description: '', | ||
| 155 | - roleName: '', | ||
| 156 | - roleSign: 1, | ||
| 157 | - departmentId:'' | 156 | + dialogMap: { |
| 157 | + update: '编辑', | ||
| 158 | + create: '新增', | ||
| 158 | }, | 159 | }, |
| 159 | - | 160 | + dialogStatus: 'create', |
| 160 | //新增界面是否显示 | 161 | //新增界面是否显示 |
| 161 | addFormVisible: false, | 162 | addFormVisible: false, |
| 162 | //设置权限界面是否显示 | 163 | //设置权限界面是否显示 |
| @@ -175,7 +176,13 @@ | @@ -175,7 +176,13 @@ | ||
| 175 | description: '', | 176 | description: '', |
| 176 | roleName: '', | 177 | roleName: '', |
| 177 | roleSign: 1, | 178 | roleSign: 1, |
| 178 | - departmentId:'' | 179 | + departmentId:'', |
| 180 | + type: '', | ||
| 181 | + businessLicense: '', | ||
| 182 | + customsRegCode: '', | ||
| 183 | + parentName: '', | ||
| 184 | + mqcode: '' | ||
| 185 | + | ||
| 179 | }, | 186 | }, |
| 180 | permForm: { | 187 | permForm: { |
| 181 | roleId: 1, | 188 | roleId: 1, |
| @@ -228,7 +235,6 @@ | @@ -228,7 +235,6 @@ | ||
| 228 | 235 | ||
| 229 | }, | 236 | }, |
| 230 | 237 | ||
| 231 | - | ||
| 232 | //获取部门列表 | 238 | //获取部门列表 |
| 233 | getdepartmentNames() { | 239 | getdepartmentNames() { |
| 234 | 240 | ||
| @@ -268,7 +274,11 @@ | @@ -268,7 +274,11 @@ | ||
| 268 | if(null!= error.response && error.response!==undefined){ | 274 | if(null!= error.response && error.response!==undefined){ |
| 269 | let status= error.response.status; | 275 | let status= error.response.status; |
| 270 | let msg = error.response.statusText; | 276 | let msg = error.response.statusText; |
| 271 | - alert(status+msg); | 277 | + message({ |
| 278 | + // 饿了么的消息弹窗组件 | ||
| 279 | + message: status+msg, | ||
| 280 | + type: "error" | ||
| 281 | + }); | ||
| 272 | }else { | 282 | }else { |
| 273 | alert(error); | 283 | alert(error); |
| 274 | } | 284 | } |
| @@ -303,14 +313,16 @@ | @@ -303,14 +313,16 @@ | ||
| 303 | * @param row 为这行的数据对象 | 313 | * @param row 为这行的数据对象 |
| 304 | */ | 314 | */ |
| 305 | handleEdit: function (index, row) { | 315 | handleEdit: function (index, row) { |
| 306 | - this.editFormVisible = true; | ||
| 307 | - this.editForm = Object.assign({}, row); | ||
| 308 | - this.getdepartmentNames(); | 316 | + this.addFormVisible = true; |
| 317 | + this.dialogStatus= 'update', | ||
| 318 | + this.addForm = Object.assign({}, row); | ||
| 319 | + // this.getdepartmentNames(); | ||
| 309 | }, | 320 | }, |
| 310 | setPerm: function (index, row) { | 321 | setPerm: function (index, row) { |
| 322 | + this.PermFormVisible = true; | ||
| 323 | + this.getPermList(); | ||
| 311 | var _this = this; | 324 | var _this = this; |
| 312 | this.permIds = []; | 325 | this.permIds = []; |
| 313 | - this.PermFormVisible = true; | ||
| 314 | this.permForm = Object.assign({}, row); | 326 | this.permForm = Object.assign({}, row); |
| 315 | let rolePerms = this.permForm.permissions; | 327 | let rolePerms = this.permForm.permissions; |
| 316 | if (util.checkNull(rolePerms)){ | 328 | if (util.checkNull(rolePerms)){ |
| @@ -320,31 +332,47 @@ | @@ -320,31 +332,47 @@ | ||
| 320 | } | 332 | } |
| 321 | }); | 333 | }); |
| 322 | } | 334 | } |
| 323 | - this.getPermList(); | 335 | + |
| 336 | + this.$nextTick(() => { | ||
| 337 | + | ||
| 338 | + //反向适配 | ||
| 339 | + this.$refs.tree.setCheckedKeys(this.permIds); | ||
| 340 | + }); | ||
| 324 | }, | 341 | }, |
| 325 | //显示新增界面,每次点开初始化数据 | 342 | //显示新增界面,每次点开初始化数据 |
| 326 | - handleAdd: function () { | 343 | + handleAdd: function (index,row) { |
| 327 | this.addFormVisible = true; | 344 | this.addFormVisible = true; |
| 345 | + this.dialogStatus= 'create'; | ||
| 328 | this.addForm = { | 346 | this.addForm = { |
| 329 | - username: '', | ||
| 330 | - password: '', | ||
| 331 | - sex: 1, | ||
| 332 | - address: '', | ||
| 333 | - realname: '', | ||
| 334 | - email: '', | ||
| 335 | - mobilephone: '', | ||
| 336 | - age: 1 | 347 | + description: '', |
| 348 | + roleName: '', | ||
| 349 | + roleSign: 1, | ||
| 350 | + departmentId:'', | ||
| 351 | + type: '', | ||
| 352 | + businessLicense: '', | ||
| 353 | + customsRegCode: '', | ||
| 354 | + mqcode: '', | ||
| 355 | + parentid: 0 | ||
| 356 | + | ||
| 337 | }; | 357 | }; |
| 338 | - this.getdepartmentNames(); | 358 | + //如果新增下级 |
| 359 | + if(util.checkNull(row)){ | ||
| 360 | + //传递上级ID | ||
| 361 | + let parentRole = Object.assign({}, row); | ||
| 362 | + this.addForm.parentid = parentRole.roleId; | ||
| 363 | + this.addForm.parentName = parentRole.roleName; | ||
| 364 | + } | ||
| 365 | + | ||
| 366 | +// this.getdepartmentNames(); | ||
| 339 | }, | 367 | }, |
| 340 | //编辑 | 368 | //编辑 |
| 341 | editSubmit: function () { | 369 | editSubmit: function () { |
| 342 | - this.$refs.editForm.validate((valid) => { | 370 | + this.$refs.addForm.validate((valid) => { |
| 343 | if (valid) { | 371 | if (valid) { |
| 344 | this.$confirm('确认提交吗?', '提示', {}).then(() => { | 372 | this.$confirm('确认提交吗?', '提示', {}).then(() => { |
| 345 | - this.editLoading = true; | 373 | + this.addLoading = true; |
| 346 | //NProgress.start(); | 374 | //NProgress.start(); |
| 347 | - let para = Object.assign({}, this.editForm); | 375 | + let para = Object.assign({}, this.addForm); |
| 348 | //不需要提交的 去掉,后端不好接收 | 376 | //不需要提交的 去掉,后端不好接收 |
| 349 | para.authorities = null; | 377 | para.authorities = null; |
| 350 | para.permissions = null; | 378 | para.permissions = null; |
| @@ -357,8 +385,8 @@ | @@ -357,8 +385,8 @@ | ||
| 357 | 式; | 385 | 式; |
| 358 | */ | 386 | */ |
| 359 | /*moment 安装 npm install moment --save*/ | 387 | /*moment 安装 npm install moment --save*/ |
| 360 | - para.creattime = moment(para.creattime).format('YYYY-MM-DD HH:mm:ss'); | ||
| 361 | - this.editLoading = false; | 388 | + // para.creattime = moment(para.creattime).format('YYYY-MM-DD HH:mm:ss'); |
| 389 | + this.addLoading = false; | ||
| 362 | edit(para).then((res) => { | 390 | edit(para).then((res) => { |
| 363 | 391 | ||
| 364 | //NProgress.done(); | 392 | //NProgress.done(); |
| @@ -366,8 +394,8 @@ | @@ -366,8 +394,8 @@ | ||
| 366 | message: '提交成功', | 394 | message: '提交成功', |
| 367 | type: 'success' | 395 | type: 'success' |
| 368 | }); | 396 | }); |
| 369 | - this.$refs['editForm'].resetFields(); | ||
| 370 | - this.editFormVisible = false; | 397 | + this.$refs['addForm'].resetFields(); |
| 398 | + this.addFormVisible = false; | ||
| 371 | this.getRoles(); | 399 | this.getRoles(); |
| 372 | }).catch(error => alert(error)); | 400 | }).catch(error => alert(error)); |
| 373 | }); | 401 | }); |
| @@ -406,7 +434,7 @@ | @@ -406,7 +434,7 @@ | ||
| 406 | //NProgress.start(); | 434 | //NProgress.start(); |
| 407 | let role = Object.assign({}, this.permForm); | 435 | let role = Object.assign({}, this.permForm); |
| 408 | let roleId = role.roleId; | 436 | let roleId = role.roleId; |
| 409 | - let permissionIds = this.permIds | 437 | + let permissionIds = this.$refs.tree.getCheckedKeys(); |
| 410 | let para = {roleId,permissionIds}; | 438 | let para = {roleId,permissionIds}; |
| 411 | updateRolePerm(para).then((res) => { | 439 | updateRolePerm(para).then((res) => { |
| 412 | this.addLoading = false; | 440 | this.addLoading = false; |
| @@ -449,6 +477,81 @@ | @@ -449,6 +477,81 @@ | ||
| 449 | }).catch(() => { | 477 | }).catch(() => { |
| 450 | 478 | ||
| 451 | }); | 479 | }); |
| 480 | + }, | ||
| 481 | + treeHandleCheckChange: function (data, checked, indeterminate) { | ||
| 482 | + if(checked) { | ||
| 483 | + this.permIds.push(data.permissionId); | ||
| 484 | + }else { | ||
| 485 | + this.permIds.splice(this.permIds.contains(data.permissionId),1); | ||
| 486 | + } | ||
| 487 | + console.log(data, checked, indeterminate); | ||
| 488 | + | ||
| 489 | + }, | ||
| 490 | + uniteParentSame(id,treeStatus){//当子节点全为未选中时父节点也变为未选中状态 | ||
| 491 | + let node = this.$refs.tree.getNode(permissionId);//获取当前节点的节点树 | ||
| 492 | + if (node.parent !== null && node.parent !== undefined) { | ||
| 493 | + let parentNode = node.parent.data;//获取当前节点的父节点树 | ||
| 494 | + if (parentNode != undefined){//判断父节点是否存在 | ||
| 495 | + for (let i = 0; i < parentNode.children.length; i++) { | ||
| 496 | + let checkedKeys = this.$refs.tree.getCheckedKeys(); | ||
| 497 | + let hafCheckedKeys = this.$refs.tree.getHalfCheckedKeys(); | ||
| 498 | + let selectNodes = checkedKeys.concat(hafCheckedKeys);//获取已选择树节点 | ||
| 499 | + let selected = selectNodes.indexOf(parentNode.children[i].permissionId); // -1当前节点的同级节点是否全部未选中 | ||
| 500 | + if (selected !== -1){ | ||
| 501 | + return; | ||
| 502 | + } | ||
| 503 | + } | ||
| 504 | + }else { | ||
| 505 | + return; | ||
| 506 | + } | ||
| 507 | + this.$refs.tree.setChecked(parentNode.permissionId, false);//修改节点为未选择 | ||
| 508 | + if(node.level>2){//判断是否是最上级节点 | ||
| 509 | + this.uniteParentSame(parentNode.permissionId,treeStatus) | ||
| 510 | + } | ||
| 511 | + }else { | ||
| 512 | + return; | ||
| 513 | + } | ||
| 514 | + }, | ||
| 515 | + | ||
| 516 | + // 统一处理子节点为相同的勾选状态 | ||
| 517 | + uniteChildSame(treeList, isSelected){ | ||
| 518 | + this.$refs.tree.setChecked(treeList.permissionId, isSelected); | ||
| 519 | + if (treeList.children !== undefined){ | ||
| 520 | + for (let i = 0; i < treeList.children.length; i++) { | ||
| 521 | + this.uniteChildSame(treeList.children[i], isSelected) | ||
| 522 | + } | ||
| 523 | + } | ||
| 524 | + }, | ||
| 525 | + // 统一处理父节点为选中 | ||
| 526 | + selectedParent(currentObj){ | ||
| 527 | + let currentNode = this.$refs.tree.getNode(currentObj); | ||
| 528 | + if (currentNode.parent.key !== undefined) { | ||
| 529 | + this.$refs.tree.setChecked(currentNode.parent, true); | ||
| 530 | + this.selectedParent(currentNode.parent) | ||
| 531 | + } | ||
| 532 | + }, | ||
| 533 | + clickDeal: function (currentObj, treeStatus){ | ||
| 534 | + // 用于:父子节点严格互不关联时,父节点勾选变化时通知子节点同步变化,实现单向关联。 | ||
| 535 | + let selected = treeStatus.checkedKeys.indexOf(currentObj.permissionId); // -1未选中 | ||
| 536 | + // 选中 | ||
| 537 | + if (selected !== -1) { | ||
| 538 | + // 子节点只要被选中父节点就被选中 | ||
| 539 | + this.selectedParent(currentObj); | ||
| 540 | + // 统一处理子节点为相同的勾选状态 | ||
| 541 | + this.uniteChildSame(currentObj, true) | ||
| 542 | + } else { | ||
| 543 | + // 未选中 处理子节点全部未选中 | ||
| 544 | + if (currentObj.children !== undefined){ | ||
| 545 | + if (currentObj.children.length !== 0) { | ||
| 546 | + this.uniteChildSame(currentObj, false) | ||
| 547 | + } | ||
| 548 | + //放开时为当子节点全为未选中时父节点也变为未选中状态 注释后就是父节点不和子节点强制绑定 | ||
| 549 | + // this.uniteParentSame(currentObj.id,treeStatus)//当子节点全为未选中时父节点也变为未选中状态 | ||
| 550 | + } | ||
| 551 | + // else { | ||
| 552 | + // this.uniteParentSame(currentObj.id,treeStatus) | ||
| 553 | + // } | ||
| 554 | + } | ||
| 452 | } | 555 | } |
| 453 | }, | 556 | }, |
| 454 | mounted() { | 557 | mounted() { |
| @@ -19,11 +19,11 @@ | @@ -19,11 +19,11 @@ | ||
| 19 | </el-col> | 19 | </el-col> |
| 20 | 20 | ||
| 21 | <!--列表--> | 21 | <!--列表--> |
| 22 | - <el-table :data="users" highlight-current-row v-loading="listLoading" @selection-change="selsChange" style="width: 100%;"> | 22 | + <el-table :data="users" highlight-current-row border v-loading="listLoading" @selection-change="selsChange" style="width: 100%;"> |
| 23 | <el-table-column type="selection" width="55"> | 23 | <el-table-column type="selection" width="55"> |
| 24 | </el-table-column> | 24 | </el-table-column> |
| 25 | - <el-table-column type="index" width="60"> | ||
| 26 | - </el-table-column> | 25 | + <!--<el-table-column type="index" width="60">--> |
| 26 | + <!--</el-table-column>--> | ||
| 27 | <el-table-column prop="userId" label="ID" width="100" sortable> | 27 | <el-table-column prop="userId" label="ID" width="100" sortable> |
| 28 | </el-table-column> | 28 | </el-table-column> |
| 29 | <el-table-column prop="username" label="账号" width="120" sortable> | 29 | <el-table-column prop="username" label="账号" width="120" sortable> |
| @@ -46,7 +46,7 @@ | @@ -46,7 +46,7 @@ | ||
| 46 | </el-table-column> | 46 | </el-table-column> |
| 47 | <el-table-column label="操作" width="250"> | 47 | <el-table-column label="操作" width="250"> |
| 48 | <template slot-scope="scope"> | 48 | <template slot-scope="scope"> |
| 49 | - <el-button size="small" @click="roleEdit(scope.$index, scope.row)">权限配置</el-button> | 49 | + <el-button size="small" @click="roleEdit(scope.$index, scope.row)">角色配置</el-button> |
| 50 | <el-button size="small" @click="handleEdit(scope.$index, scope.row)">编辑</el-button> | 50 | <el-button size="small" @click="handleEdit(scope.$index, scope.row)">编辑</el-button> |
| 51 | <el-button type="danger" size="small" @click="handleDel(scope.$index, scope.row)">删除</el-button> | 51 | <el-button type="danger" size="small" @click="handleDel(scope.$index, scope.row)">删除</el-button> |
| 52 | </template> | 52 | </template> |
| @@ -126,7 +126,7 @@ | @@ -126,7 +126,7 @@ | ||
| 126 | <el-dialog title="新增" :visible.sync="addFormVisible" :close-on-click-modal="false"> | 126 | <el-dialog title="新增" :visible.sync="addFormVisible" :close-on-click-modal="false"> |
| 127 | <el-form :model="addForm" label-width="80px" :rules="addFormRules" ref="addForm"> | 127 | <el-form :model="addForm" label-width="80px" :rules="addFormRules" ref="addForm"> |
| 128 | <el-form-item label="账号" prop="username"> | 128 | <el-form-item label="账号" prop="username"> |
| 129 | - <el-input v-model="addForm.username"></el-input> | 129 | + <el-input v-model="addForm.username" aria-placeholder="用户名长度在5-11位,支持英文和数字"></el-input> |
| 130 | </el-form-item> | 130 | </el-form-item> |
| 131 | <el-form-item label="密码" prop="password"> | 131 | <el-form-item label="密码" prop="password"> |
| 132 | <el-input v-model="addForm.password" type="password"></el-input> | 132 | <el-input v-model="addForm.password" type="password"></el-input> |
| @@ -168,7 +168,7 @@ | @@ -168,7 +168,7 @@ | ||
| 168 | <el-form-item label="账号"> | 168 | <el-form-item label="账号"> |
| 169 | <span>{{roleEditForm.username}}</span> | 169 | <span>{{roleEditForm.username}}</span> |
| 170 | </el-form-item> | 170 | </el-form-item> |
| 171 | - <el-tree :data="roles" :props="treeDefaultProps" show-checkbox node-key="roleId" ref="tree"> | 171 | + <el-tree :data="roles" :props="treeDefaultProps" default-expand-all show-checkbox highlight-current check-strictly node-key="roleId" ref="tree" @check-change="treeHandleCheckChange"> |
| 172 | </el-tree> | 172 | </el-tree> |
| 173 | </el-form> | 173 | </el-form> |
| 174 | 174 | ||
| @@ -230,7 +230,10 @@ | @@ -230,7 +230,10 @@ | ||
| 230 | addLoading: false, | 230 | addLoading: false, |
| 231 | addFormRules: { | 231 | addFormRules: { |
| 232 | username: [ | 232 | username: [ |
| 233 | - { required: true, message: '请输入姓名', trigger: 'blur' } | 233 | + { required: true, message: '请输入姓名,用户名长度在5-11位,支持英文和数字', trigger: 'blur' }, |
| 234 | + ], | ||
| 235 | + password: [ | ||
| 236 | + { required: true, message: '请输入密码,用户名长度在6-18位,支持英文和数字和非空字符', trigger: 'blur'} | ||
| 234 | ] | 237 | ] |
| 235 | }, | 238 | }, |
| 236 | //用户角色配置 | 239 | //用户角色配置 |
| @@ -321,16 +324,24 @@ | @@ -321,16 +324,24 @@ | ||
| 321 | this.editForm = Object.assign({}, row); | 324 | this.editForm = Object.assign({}, row); |
| 322 | }, | 325 | }, |
| 323 | roleEdit: function (index, row) { | 326 | roleEdit: function (index, row) { |
| 327 | + this.roleFormVisible = true; | ||
| 328 | + this.getRoles(); | ||
| 324 | var _this = this; | 329 | var _this = this; |
| 325 | _this.roleIds = []; | 330 | _this.roleIds = []; |
| 326 | this.roleEditForm = Object.assign({}, row); | 331 | this.roleEditForm = Object.assign({}, row); |
| 327 | - let userRoles = this.roleEditForm.roles; | ||
| 328 | - if (util.checkNull(userRoles)){ | ||
| 329 | - userRoles.forEach(function (role,v_index,v_arr) { | 332 | + let roles = this.roleEditForm.roles; |
| 333 | + | ||
| 334 | + if (util.checkNull(roles)){ | ||
| 335 | + roles.forEach(function (role,v_index,v_arr) { | ||
| 336 | + if (util.checkNull(role)) { | ||
| 330 | _this.roleIds[v_index] = role.roleId; | 337 | _this.roleIds[v_index] = role.roleId; |
| 338 | + } | ||
| 331 | }); | 339 | }); |
| 332 | } | 340 | } |
| 333 | - this.getRoles(); | 341 | + this.$nextTick(() => { |
| 342 | + //反向适配 | ||
| 343 | + this.$refs.tree.setCheckedKeys(this.roleIds); | ||
| 344 | + }); | ||
| 334 | }, | 345 | }, |
| 335 | getRoles() { | 346 | getRoles() { |
| 336 | let para = { | 347 | let para = { |
| @@ -340,7 +351,6 @@ | @@ -340,7 +351,6 @@ | ||
| 340 | NProgress.start(); | 351 | NProgress.start(); |
| 341 | getList(para).then((res) => { | 352 | getList(para).then((res) => { |
| 342 | this.roles = res.data.list; | 353 | this.roles = res.data.list; |
| 343 | - this.roleFormVisible = true; | ||
| 344 | NProgress.done(); | 354 | NProgress.done(); |
| 345 | }).catch((error) => { | 355 | }).catch((error) => { |
| 346 | if(null!= error.response && error.response!==undefined){ | 356 | if(null!= error.response && error.response!==undefined){ |
| @@ -352,6 +362,7 @@ | @@ -352,6 +362,7 @@ | ||
| 352 | } | 362 | } |
| 353 | }); | 363 | }); |
| 354 | 364 | ||
| 365 | + | ||
| 355 | }, | 366 | }, |
| 356 | //显示新增界面,每次点开初始化数据 | 367 | //显示新增界面,每次点开初始化数据 |
| 357 | handleAdd: function () { | 368 | handleAdd: function () { |
| @@ -424,7 +435,10 @@ | @@ -424,7 +435,10 @@ | ||
| 424 | this.getUsers(); | 435 | this.getUsers(); |
| 425 | }).catch(error => { | 436 | }).catch(error => { |
| 426 | this.addLoading = false; | 437 | this.addLoading = false; |
| 427 | - alert(error.message); | 438 | + this.$message({ |
| 439 | + message: error.message, | ||
| 440 | + type: 'error' | ||
| 441 | + }); | ||
| 428 | }); | 442 | }); |
| 429 | }); | 443 | }); |
| 430 | } | 444 | } |
| @@ -459,11 +473,14 @@ | @@ -459,11 +473,14 @@ | ||
| 459 | this.$confirm('确认提交吗?', '提示', {}).then(() => { | 473 | this.$confirm('确认提交吗?', '提示', {}).then(() => { |
| 460 | // this.editLoading = true; | 474 | // this.editLoading = true; |
| 461 | let userId = this.roleEditForm.userId; | 475 | let userId = this.roleEditForm.userId; |
| 462 | - let roleIds = this.roleIds; | 476 | + let roleIds = this.$refs.tree.getCheckedKeys(); |
| 463 | let para = {userId,roleIds}; | 477 | let para = {userId,roleIds}; |
| 464 | setUserRole(para).then((res) => { | 478 | setUserRole(para).then((res) => { |
| 465 | if (res.status ===200) { | 479 | if (res.status ===200) { |
| 466 | - alert("ok"); | 480 | + this.$message({ |
| 481 | + message: '岗位设置成功', | ||
| 482 | + type: 'success' | ||
| 483 | + }); | ||
| 467 | } | 484 | } |
| 468 | this.getUsers(); | 485 | this.getUsers(); |
| 469 | this.roleFormVisible = false; | 486 | this.roleFormVisible = false; |
| @@ -478,6 +495,15 @@ | @@ -478,6 +495,15 @@ | ||
| 478 | }, | 495 | }, |
| 479 | beforeAvatarUpload: function () { | 496 | beforeAvatarUpload: function () { |
| 480 | 497 | ||
| 498 | + }, | ||
| 499 | + treeHandleCheckChange: function (data, checked, indeterminate) { | ||
| 500 | + if(checked) { | ||
| 501 | + this.roleIds.push(data.roleId); | ||
| 502 | + }else { | ||
| 503 | + this.roleIds.splice(this.roleIds.contains(data.roleId),1); | ||
| 504 | + } | ||
| 505 | +// console.log(data, checked, indeterminate); | ||
| 506 | + console.log(this.roleIds); | ||
| 481 | } | 507 | } |
| 482 | }, | 508 | }, |
| 483 | mounted() { | 509 | mounted() { |
| @@ -32,7 +32,7 @@ | @@ -32,7 +32,7 @@ | ||
| 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="awba" placeholder="请输入主单号"></el-input> | 35 | + <el-input v-model="awba" clearable placeholder="请输入主单号"></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"> |
| @@ -51,15 +51,20 @@ | @@ -51,15 +51,20 @@ | ||
| 51 | </el-col> | 51 | </el-col> |
| 52 | </el-row> | 52 | </el-row> |
| 53 | </div> | 53 | </div> |
| 54 | - <el-table v-loading="listLoading" :data="arriveData" stripe fit highlight-current-row | ||
| 55 | - style="font-size: 12px" border @selection-change="handleSelectionChange"> | ||
| 56 | - <el-table-column type="selection" width="55" align="center"></el-table-column> | ||
| 57 | - <el-table-column label="航班号" width="70" align="center"> | 54 | + <el-table v-loading="listLoading" :data="arriveData" stripe |
| 55 | + style="font-size: 12px" border @selection-change="handleSelectionChange" | ||
| 56 | + default-expand-all | ||
| 57 | + row-key="uuid" | ||
| 58 | + border | ||
| 59 | + :tree-props="{children: 'children', hasChildren: 'hasChildren'}"> | ||
| 60 | + <el-table-column type="selection" width="55"> | ||
| 61 | + </el-table-column> | ||
| 62 | + <el-table-column label="航班号" width="100" align="center"> | ||
| 58 | <template slot-scope="scope"> | 63 | <template slot-scope="scope"> |
| 59 | <span>{{scope.row.carrier}}{{scope.row.flightno}}</span> | 64 | <span>{{scope.row.carrier}}{{scope.row.flightno}}</span> |
| 60 | </template> | 65 | </template> |
| 61 | </el-table-column> | 66 | </el-table-column> |
| 62 | - <el-table-column label="运单号" width="120" align="center"> | 67 | + <el-table-column label="运单号" width="110" align="center"> |
| 63 | <template slot-scope="scope"> | 68 | <template slot-scope="scope"> |
| 64 | <span>{{scope.row.awba}}</span> | 69 | <span>{{scope.row.awba}}</span> |
| 65 | </template> | 70 | </template> |
| @@ -79,7 +84,7 @@ | @@ -79,7 +84,7 @@ | ||
| 79 | <span>{{scope.row.weight}}</span> | 84 | <span>{{scope.row.weight}}</span> |
| 80 | </template> | 85 | </template> |
| 81 | </el-table-column> | 86 | </el-table-column> |
| 82 | - <el-table-column label="货物描述" width="100" align="center"> | 87 | + <el-table-column label="货物描述" width="120" align="center"> |
| 83 | <template slot-scope="scope"> | 88 | <template slot-scope="scope"> |
| 84 | <span>{{scope.row.goodsname}}</span> | 89 | <span>{{scope.row.goodsname}}</span> |
| 85 | </template> | 90 | </template> |
| @@ -91,38 +96,51 @@ | @@ -91,38 +96,51 @@ | ||
| 91 | </el-table-column> | 96 | </el-table-column> |
| 92 | <el-table-column label="状态" width="100" align="center"> | 97 | <el-table-column label="状态" width="100" align="center"> |
| 93 | <template slot-scope="scope"> | 98 | <template slot-scope="scope"> |
| 94 | - <span v-if="scope.row.status ==='01'">未发送</span> | ||
| 95 | - <span v-if="scope.row.status ==='02'">已发舱单报</span> | 99 | + <span v-if="scope.row.status ==='01'">接受申报</span> |
| 100 | + <span v-if="scope.row.status ==='02'">待人工审核</span> | ||
| 101 | + <span v-if="scope.row.status ==='03'">退单</span> | ||
| 96 | <span v-if="scope.row.status ==='05'">舱单报退单</span> | 102 | <span v-if="scope.row.status ==='05'">舱单报退单</span> |
| 97 | <span v-if="scope.row.status ==='06'">舱单转人工</span> | 103 | <span v-if="scope.row.status ==='06'">舱单转人工</span> |
| 98 | <span v-if="scope.row.status ==='07'">舱单报申报成功</span> | 104 | <span v-if="scope.row.status ==='07'">舱单报申报成功</span> |
| 99 | <span v-if="scope.row.status ==='08'">已发舱单删除报</span> | 105 | <span v-if="scope.row.status ==='08'">已发舱单删除报</span> |
| 100 | <span v-if="scope.row.status ==='09'">舱单删除报退单</span> | 106 | <span v-if="scope.row.status ==='09'">舱单删除报退单</span> |
| 101 | <span v-if="scope.row.status ==='10'">舱单删除报转人工</span> | 107 | <span v-if="scope.row.status ==='10'">舱单删除报转人工</span> |
| 102 | - <span v-if="scope.row.status ==='11'">舱单删除成功</span> | ||
| 103 | - <span v-if="scope.row.status ==='12'">已发舱单修改报</span> | ||
| 104 | - <span v-if="scope.row.status ==='13'">舱单修改报退单</span> | 108 | + <span v-if="scope.row.status ==='11'">放行</span> |
| 109 | + <span v-if="scope.row.status ==='12'">拒装</span> | ||
| 110 | + <span v-if="scope.row.status ==='13'">禁卸</span> | ||
| 105 | <span v-if="scope.row.status ==='14'">舱单修改报转人工</span> | 111 | <span v-if="scope.row.status ==='14'">舱单修改报转人工</span> |
| 106 | <span v-if="scope.row.status ==='15'">舱单修改报成功</span> | 112 | <span v-if="scope.row.status ==='15'">舱单修改报成功</span> |
| 107 | <span v-if="scope.row.status ==='16'">海关已存在</span> | 113 | <span v-if="scope.row.status ==='16'">海关已存在</span> |
| 114 | + <span v-if="scope.row.status ==='21'">可自动发送</span> | ||
| 115 | + <span v-if="scope.row.status ==='22'">未发送</span> | ||
| 116 | + <span v-if="scope.row.status ==='23'">已发送新增报</span> | ||
| 117 | + <span v-if="scope.row.status ==='24'">已发送删除报</span> | ||
| 118 | + <span v-if="scope.row.status ==='25'">已发送修改报</span> | ||
| 108 | </template> | 119 | </template> |
| 109 | </el-table-column> | 120 | </el-table-column> |
| 110 | - <el-table-column prop="receipt" label="回执信息" width="180" align="center"> | 121 | + <el-table-column prop="receipt" label="回执信息" align="center"> |
| 111 | <template slot-scope="scope"> | 122 | <template slot-scope="scope"> |
| 112 | <span>{{scope.row.ext5}}</span> | 123 | <span>{{scope.row.ext5}}</span> |
| 113 | </template> | 124 | </template> |
| 114 | </el-table-column> | 125 | </el-table-column> |
| 115 | - <el-table-column prop="operation" label="操作" align="center"> | 126 | + <el-table-column prop="operation" fixed="right" label="操作" align="center" width="400"> |
| 116 | <template slot-scope="scope"> | 127 | <template slot-scope="scope"> |
| 117 | - <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'">发送舱单报 | 128 | + <el-button size="mini" @click="handleSendDesc(scope.row)">收发明细</el-button> |
| 129 | + <el-button size="mini" type="success" @click="handleEdit(scope.row)">编辑</el-button> | ||
| 130 | + <el-button size="mini" type="primary" @click="handleSendAwb(scope.row)" | ||
| 131 | + :disabled="scope.row.status ==='23'">发送出港运抵报 | ||
| 132 | + </el-button> | ||
| 133 | + <p></p> | ||
| 134 | + <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单 | ||
| 121 | </el-button> | 135 | </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)" | 136 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" |
| 125 | - :disabled="scope.row.status ==='00'">修改状态 | 137 | + :disabled="scope.row.status ==='22'">更改状态 |
| 138 | + </el-button> | ||
| 139 | + <el-button size="mini" type="primary" v-if="scope.row.awbh ===''" | ||
| 140 | + @click="handleAddAwbh(scope.row)">新增分单 | ||
| 141 | + </el-button> | ||
| 142 | + <el-button size="mini" type="danger" @click="handleSendDelete(scope.row)" | ||
| 143 | + :disabled="scope.row.status ==='24'">发删除报 | ||
| 126 | </el-button> | 144 | </el-button> |
| 127 | </template> | 145 | </template> |
| 128 | </el-table-column> | 146 | </el-table-column> |
| @@ -132,7 +150,7 @@ | @@ -132,7 +150,7 @@ | ||
| 132 | <el-button type="primary" size="mini" v-if="arriveQuery.flightno !==undefined || arriveData.length>0" | 150 | <el-button type="primary" size="mini" v-if="arriveQuery.flightno !==undefined || arriveData.length>0" |
| 133 | @click="handelAddArriveInfo">新增出港运抵 | 151 | @click="handelAddArriveInfo">新增出港运抵 |
| 134 | </el-button> | 152 | </el-button> |
| 135 | - <el-button type="primary" size="mini" v-if="arriveModel.flightno !== undefined || arriveData.length>0" | 153 | + <el-button type="primary" size="mini" v-if="arriveQuery.flightno !== undefined || arriveData.length>0" |
| 136 | @click="handelBackStep">返回 | 154 | @click="handelBackStep">返回 |
| 137 | </el-button> | 155 | </el-button> |
| 138 | </el-row> | 156 | </el-row> |
| @@ -152,7 +170,7 @@ | @@ -152,7 +170,7 @@ | ||
| 152 | <el-input v-model="arriveModel.awba"></el-input> | 170 | <el-input v-model="arriveModel.awba"></el-input> |
| 153 | </el-form-item> | 171 | </el-form-item> |
| 154 | </el-col> | 172 | </el-col> |
| 155 | - <el-col :span="7.5"> | 173 | + <el-col :span="7.5" v-if="fenStatus === 'addAwbh'"> |
| 156 | <el-form-item label="分单号" prop="awbh"> | 174 | <el-form-item label="分单号" prop="awbh"> |
| 157 | <el-input v-model="awbh"></el-input> | 175 | <el-input v-model="awbh"></el-input> |
| 158 | </el-form-item> | 176 | </el-form-item> |
| @@ -185,14 +203,28 @@ | @@ -185,14 +203,28 @@ | ||
| 185 | <el-row> | 203 | <el-row> |
| 186 | <el-col :span="7.5"> | 204 | <el-col :span="7.5"> |
| 187 | <el-form-item label="起始站" prop="originstation"> | 205 | <el-form-item label="起始站" prop="originstation"> |
| 188 | - <el-input v-model="originstation" | ||
| 189 | - :disabled="dialogFormVisible === 'update'"></el-input> | 206 | + <el-select filterable clearable placeholder="请选择起始站" :remote-method="remoteMethodAirport" |
| 207 | + allow-create v-model="originstation" remote> | ||
| 208 | + <el-option v-for="item in airportCode" | ||
| 209 | + :key="item.airportid" :label="item.airportid" | ||
| 210 | + :value="item.airportid" :disabled="dialogFormVisible === 'update'"> | ||
| 211 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 212 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 213 | + </el-option> | ||
| 214 | + </el-select> | ||
| 190 | </el-form-item> | 215 | </el-form-item> |
| 191 | </el-col> | 216 | </el-col> |
| 192 | <el-col :span="7.5"> | 217 | <el-col :span="7.5"> |
| 193 | <el-form-item label="目的站" prop="destinationstation"> | 218 | <el-form-item label="目的站" prop="destinationstation"> |
| 194 | - <el-input v-model="destinationstation" | ||
| 195 | - :disabled="dialogFormVisible === 'update'"></el-input> | 219 | + <el-select filterable clearable placeholder="请选择起始站" :remote-method="remoteMethodAirport" |
| 220 | + allow-create v-model="destinationstation" remote> | ||
| 221 | + <el-option v-for="item in airportCode" | ||
| 222 | + :key="item.airportid" :label="item.airportid" | ||
| 223 | + :value="item.airportid" :disabled="dialogFormVisible === 'update'"> | ||
| 224 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 225 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 226 | + </el-option> | ||
| 227 | + </el-select> | ||
| 196 | </el-form-item> | 228 | </el-form-item> |
| 197 | </el-col> | 229 | </el-col> |
| 198 | </el-row> | 230 | </el-row> |
| @@ -226,9 +258,15 @@ | @@ -226,9 +258,15 @@ | ||
| 226 | </el-col> | 258 | </el-col> |
| 227 | <el-col :span="7.5"> | 259 | <el-col :span="7.5"> |
| 228 | <el-form-item label="海关关区" prop="customcode"> | 260 | <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> | 261 | + <el-select v-model="arriveModel.customcode" placeholder="请选择关区代码" :loading="customLoading" |
| 262 | + filterable clearable remote :remote-method="remoteMethodCustomCode" | ||
| 263 | + :disabled="dialogStatus === 'addAwbh'"> | ||
| 264 | + <el-option v-for="item in customCodeList" :key="item.customcode" | ||
| 265 | + :label="item.customcode" | ||
| 266 | + :value="item.customcode"> | ||
| 267 | + <span style="float: left">{{ item.customcode }}</span> | ||
| 268 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.customname }}</span> | ||
| 269 | + </el-option> | ||
| 232 | </el-select> | 270 | </el-select> |
| 233 | </el-form-item> | 271 | </el-form-item> |
| 234 | </el-col> | 272 | </el-col> |
| @@ -237,12 +275,11 @@ | @@ -237,12 +275,11 @@ | ||
| 237 | <div slot="footer" class="dialog-footer"> | 275 | <div slot="footer" class="dialog-footer"> |
| 238 | <el-button @click="dialogFormVisible = false">取消</el-button> | 276 | <el-button @click="dialogFormVisible = false">取消</el-button> |
| 239 | <el-button type="primary" @click="dialogStatus==='create'?createData():updateData()">保存</el-button> | 277 | <el-button type="primary" @click="dialogStatus==='create'?createData():updateData()">保存</el-button> |
| 240 | - <el-button type="success" @click="SaveAndSend">保存并发送</el-button> | ||
| 241 | </div> | 278 | </div> |
| 242 | </el-dialog> | 279 | </el-dialog> |
| 243 | <el-dialog title="收发明细" :visible.sync="dialogTableVisible"> | 280 | <el-dialog title="收发明细" :visible.sync="dialogTableVisible"> |
| 244 | <el-table :data="detailData" border> | 281 | <el-table :data="detailData" border> |
| 245 | - <el-table-column label="操作时间" width="150"> | 282 | + <el-table-column label="操作时间" width="180"> |
| 246 | <template slot-scope="scope"> | 283 | <template slot-scope="scope"> |
| 247 | {{scope.row.busdate}} | 284 | {{scope.row.busdate}} |
| 248 | </template> | 285 | </template> |
| @@ -272,6 +309,11 @@ | @@ -272,6 +309,11 @@ | ||
| 272 | {{scope.row.cusrestext}} | 309 | {{scope.row.cusrestext}} |
| 273 | </template> | 310 | </template> |
| 274 | </el-table-column> | 311 | </el-table-column> |
| 312 | + <el-table-column label="操作类型" width="100"> | ||
| 313 | + <template slot-scope="scope"> | ||
| 314 | + {{scope.row.opertype}} | ||
| 315 | + </template> | ||
| 316 | + </el-table-column> | ||
| 275 | <el-table-column label="操作人" width="100"> | 317 | <el-table-column label="操作人" width="100"> |
| 276 | <template slot-scope="scope"> | 318 | <template slot-scope="scope"> |
| 277 | {{scope.row.operusername}} | 319 | {{scope.row.operusername}} |
| @@ -279,16 +321,51 @@ | @@ -279,16 +321,51 @@ | ||
| 279 | </el-table-column> | 321 | </el-table-column> |
| 280 | </el-table> | 322 | </el-table> |
| 281 | </el-dialog> | 323 | </el-dialog> |
| 324 | + <el-dialog title="删除原因" :visible.sync="dialogDeleteVisible" width="30%"> | ||
| 325 | + <el-form ref="arriveDeleteForm" :model="respModel" :rules="arriveDeleteRules" | ||
| 326 | + label-width="120px" style="margin-right: 50px"> | ||
| 327 | + <el-form-item label="删除原因" prop="reason"> | ||
| 328 | + <el-input v-model="respModel.reason" placeholder="删除原因"></el-input> | ||
| 329 | + </el-form-item> | ||
| 330 | + <el-form-item label="删除操作人" prop="contactName"> | ||
| 331 | + <el-input v-model="respModel.contactName" placeholder="操作人姓名"></el-input> | ||
| 332 | + </el-form-item> | ||
| 333 | + <el-form-item label="操作人Tel" prop="contactTel"> | ||
| 334 | + <el-input v-model="respModel.contactTel" placeholder="删除操作人联系方式"></el-input> | ||
| 335 | + </el-form-item> | ||
| 336 | + <el-form-item label="备注"> | ||
| 337 | + <el-input v-model="respModel.content" type="textarea"></el-input> | ||
| 338 | + </el-form-item> | ||
| 339 | + </el-form> | ||
| 340 | + <div slot="footer" class="dialog-footer"> | ||
| 341 | + <el-button @click="dialogDeleteVisible = false">取消</el-button> | ||
| 342 | + <el-button type="primary" @click="sendArriveDelete()">发送</el-button> | ||
| 343 | + </div> | ||
| 344 | + </el-dialog> | ||
| 282 | </div> | 345 | </div> |
| 283 | </template> | 346 | </template> |
| 284 | <script> | 347 | <script> |
| 285 | import treeTable from '@/components/TreeTable' | 348 | import treeTable from '@/components/TreeTable' |
| 286 | import treeToArray from '@/utils/customEval' | 349 | import treeToArray from '@/utils/customEval' |
| 287 | import Pagination from '@/components/Pagination' | 350 | import Pagination from '@/components/Pagination' |
| 288 | - | ||
| 289 | - import {getMt3201ListForParam, deleteByIsDelete, updateStatus, updateMT3201, addMt3201} from '@/api/exitArrive' | 351 | + import {getCustomCode, getAirportCode} from "@/api/country"; |
| 352 | + import { | ||
| 353 | + getMt3201ListForParam, | ||
| 354 | + deleteByIsDelete, | ||
| 355 | + updateStatus, | ||
| 356 | + updateMT3201, | ||
| 357 | + addMt3201, | ||
| 358 | + sendCreateMt3201, | ||
| 359 | + sendRemoveMt3201 | ||
| 360 | + } from '@/api/exitArrive' | ||
| 290 | import {Message} from "element-ui"; | 361 | import {Message} from "element-ui"; |
| 291 | - import {validAwb, validAlphabets, validAlphabetsAndNum,validAlphabetsAndSpanceKey,validatorNum} from "@/utils/validate"; | 362 | + import { |
| 363 | + validAwb, | ||
| 364 | + validAlphabets, | ||
| 365 | + validAlphabetsAndNum, | ||
| 366 | + validAlphabetsAndSpanceKey, | ||
| 367 | + validatorNum | ||
| 368 | + } from "@/utils/validate"; | ||
| 292 | import {getResponseForParam} from '@/api/responseDetail' | 369 | import {getResponseForParam} from '@/api/responseDetail' |
| 293 | 370 | ||
| 294 | export default { | 371 | export default { |
| @@ -314,8 +391,8 @@ | @@ -314,8 +391,8 @@ | ||
| 314 | } | 391 | } |
| 315 | callback() | 392 | callback() |
| 316 | } | 393 | } |
| 317 | - const validAlphabetsSpanceKey = (rule,value,callback) =>{ | ||
| 318 | - if(!validAlphabetsAndSpanceKey(value)){ | 394 | + const validAlphabetsSpanceKey = (rule, value, callback) => { |
| 395 | + if (!validAlphabetsAndSpanceKey(value)) { | ||
| 319 | callback("只能输入字母、数字、空格") | 396 | callback("只能输入字母、数字、空格") |
| 320 | } | 397 | } |
| 321 | callback() | 398 | callback() |
| @@ -332,14 +409,15 @@ | @@ -332,14 +409,15 @@ | ||
| 332 | isAdmin: false, | 409 | isAdmin: false, |
| 333 | arriveQuery: { | 410 | arriveQuery: { |
| 334 | pageSize: 1, | 411 | pageSize: 1, |
| 335 | - limitSize: 100, | 412 | + limitSize: 30, |
| 336 | awba: undefined, | 413 | awba: undefined, |
| 337 | carrier: undefined, | 414 | carrier: undefined, |
| 338 | flightno: undefined, | 415 | flightno: undefined, |
| 339 | flightdate: undefined, | 416 | flightdate: undefined, |
| 340 | originstation: undefined, | 417 | originstation: undefined, |
| 341 | destinationstation: undefined, | 418 | destinationstation: undefined, |
| 342 | - customcode: undefined | 419 | + customcode: undefined, |
| 420 | + messageType: undefined, | ||
| 343 | }, | 421 | }, |
| 344 | dialogMap: { | 422 | dialogMap: { |
| 345 | update: '编辑出港运抵', | 423 | update: '编辑出港运抵', |
| @@ -347,11 +425,15 @@ | @@ -347,11 +425,15 @@ | ||
| 347 | }, | 425 | }, |
| 348 | dialogTableVisible: false, | 426 | dialogTableVisible: false, |
| 349 | multipleSelection: [], | 427 | multipleSelection: [], |
| 350 | - customcodeList: [4604, 4620], | 428 | + customCodeList: [], |
| 429 | + airportCode: [], | ||
| 351 | dialogStatus: undefined, | 430 | dialogStatus: undefined, |
| 352 | awbhStatus: false, | 431 | awbhStatus: false, |
| 432 | + fenStatus: undefined, | ||
| 353 | dialogFormVisible: false, | 433 | dialogFormVisible: false, |
| 434 | + dialogDeleteVisible: false, | ||
| 354 | listLoading: false, | 435 | listLoading: false, |
| 436 | + customLoading: false, | ||
| 355 | arriveRoles: { | 437 | arriveRoles: { |
| 356 | awba: [{required: true, trigger: 'blur', validator: validatorAwb}], | 438 | awba: [{required: true, trigger: 'blur', validator: validatorAwb}], |
| 357 | awbh: [{required: true, trigger: 'blur', validator: validatorAwbh}], | 439 | awbh: [{required: true, trigger: 'blur', validator: validatorAwbh}], |
| @@ -379,7 +461,24 @@ | @@ -379,7 +461,24 @@ | ||
| 379 | customcode: undefined, | 461 | customcode: undefined, |
| 380 | arrivetime: undefined, | 462 | arrivetime: undefined, |
| 381 | messageType: 'MT3201' | 463 | messageType: 'MT3201' |
| 382 | - } | 464 | + }, |
| 465 | + respModel: { | ||
| 466 | + uuid: undefined, | ||
| 467 | + reason: undefined, | ||
| 468 | + contactName: undefined, | ||
| 469 | + contactTel: undefined, | ||
| 470 | + content: '', | ||
| 471 | + flightNo: undefined, | ||
| 472 | + awba: undefined, | ||
| 473 | + customCode: undefined, | ||
| 474 | + flightDate: undefined, | ||
| 475 | + awbh: '' | ||
| 476 | + }, | ||
| 477 | + arriveDeleteRules: { | ||
| 478 | + reason: [{required: true, message: '删除原因不能为空', trigger: 'blur'}], | ||
| 479 | + contactName: [{required: true, message: '删除操作人不能为空', trigger: 'blur'}], | ||
| 480 | + contactTel: [{required: true, message: '操作人联系方式不能为空', trigger: 'blur'}] | ||
| 481 | + }, | ||
| 383 | } | 482 | } |
| 384 | }, | 483 | }, |
| 385 | created() { | 484 | created() { |
| @@ -388,7 +487,6 @@ | @@ -388,7 +487,6 @@ | ||
| 388 | if (this.$route.params.flightData.awba !== undefined && this.$route.params.flightData.awba !== '') { | 487 | 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) | 488 | this.arriveQuery.awba = this.$route.params.flightData.awba.substring(0, 3) + "-" + this.$route.params.flightData.awba.substring(3) |
| 390 | } | 489 | } |
| 391 | - | ||
| 392 | this.arriveQuery.carrier = this.$route.params.flightData.flightno.substring(0, 2) | 490 | this.arriveQuery.carrier = this.$route.params.flightData.flightno.substring(0, 2) |
| 393 | this.arriveQuery.flightno = this.$route.params.flightData.flightno.substring(2) | 491 | this.arriveQuery.flightno = this.$route.params.flightData.flightno.substring(2) |
| 394 | this.arriveQuery.flightdate = this.$route.params.flightData.flightdate | 492 | this.arriveQuery.flightdate = this.$route.params.flightData.flightdate |
| @@ -397,7 +495,7 @@ | @@ -397,7 +495,7 @@ | ||
| 397 | this.getList() | 495 | this.getList() |
| 398 | } | 496 | } |
| 399 | let username = JSON.parse(sessionStorage.getItem('user')).username | 497 | let username = JSON.parse(sessionStorage.getItem('user')).username |
| 400 | - if(username === 'admin'){ | 498 | + if (username === 'admin') { |
| 401 | this.isAdmin = true | 499 | this.isAdmin = true |
| 402 | } | 500 | } |
| 403 | }, | 501 | }, |
| @@ -466,7 +564,7 @@ | @@ -466,7 +564,7 @@ | ||
| 466 | getMt3201ListForParam(this.arriveQuery).then(res => { | 564 | getMt3201ListForParam(this.arriveQuery).then(res => { |
| 467 | this.arriveData = res.data.dataList | 565 | this.arriveData = res.data.dataList |
| 468 | this.total = res.data.count | 566 | this.total = res.data.count |
| 469 | - if (res.data.count > 0) { | 567 | + if (res.data.dataList.length > 0){ |
| 470 | this.arriveQuery.carrier = this.arriveData[0].carrier | 568 | this.arriveQuery.carrier = this.arriveData[0].carrier |
| 471 | this.arriveQuery.flightno = this.arriveData[0].flightno | 569 | this.arriveQuery.flightno = this.arriveData[0].flightno |
| 472 | this.arriveQuery.flightdate = this.arriveData[0].flightdate | 570 | this.arriveQuery.flightdate = this.arriveData[0].flightdate |
| @@ -490,11 +588,11 @@ | @@ -490,11 +588,11 @@ | ||
| 490 | 588 | ||
| 491 | }, | 589 | }, |
| 492 | handleSerach() { | 590 | handleSerach() { |
| 493 | - this.arriveQuery.carrier = undefined | ||
| 494 | - this.arriveQuery.flightno = undefined | ||
| 495 | - this.arriveQuery.originstation = undefined | ||
| 496 | - this.arriveQuery.flightdate = undefined | ||
| 497 | - this.arriveQuery.destinationstation = undefined | 591 | + // this.arriveQuery.carrier = undefined |
| 592 | + // this.arriveQuery.flightno = undefined | ||
| 593 | + // this.arriveQuery.originstation = undefined | ||
| 594 | + // this.arriveQuery.flightdate = undefined | ||
| 595 | + // this.arriveQuery.destinationstation = undefined | ||
| 498 | this.getList() | 596 | this.getList() |
| 499 | }, | 597 | }, |
| 500 | handleSelectionChange(val) { | 598 | handleSelectionChange(val) { |
| @@ -516,6 +614,24 @@ | @@ -516,6 +614,24 @@ | ||
| 516 | this.$refs.arriveFormData.clearValidate() | 614 | this.$refs.arriveFormData.clearValidate() |
| 517 | }) | 615 | }) |
| 518 | }, | 616 | }, |
| 617 | + // 新增出港运抵分单 | ||
| 618 | + handleAddAwbh(row){ | ||
| 619 | + this.restModel() | ||
| 620 | + // 给model赋值,所使用数据是以单独单号查询数据所得 | ||
| 621 | + this.arriveModel.carrier = row.carrier | ||
| 622 | + this.arriveModel.awba = row.awba | ||
| 623 | + this.arriveModel.flightdate = row.flightdate | ||
| 624 | + this.arriveModel.flightno = row.flightno | ||
| 625 | + this.arriveModel.originstation = row.originstation | ||
| 626 | + this.arriveModel.destinationstation = row.destinationstation | ||
| 627 | + this.arriveModel.customcode = row.customcode | ||
| 628 | + this.dialogStatus = 'create' | ||
| 629 | + this.fenStatus = 'addAwbh' | ||
| 630 | + this.dialogFormVisible = true | ||
| 631 | + this.$nextTick(() => { | ||
| 632 | + this.$refs.arriveFormData.clearValidate() | ||
| 633 | + }) | ||
| 634 | + }, | ||
| 519 | createData() { | 635 | createData() { |
| 520 | this.$refs.arriveFormData.validate(valid => { | 636 | this.$refs.arriveFormData.validate(valid => { |
| 521 | if (valid) { | 637 | if (valid) { |
| @@ -553,6 +669,13 @@ | @@ -553,6 +669,13 @@ | ||
| 553 | // 编辑 | 669 | // 编辑 |
| 554 | handleEdit(row) { | 670 | handleEdit(row) { |
| 555 | this.arriveModel = Object.assign({}, row) // copy obj | 671 | this.arriveModel = Object.assign({}, row) // copy obj |
| 672 | + | ||
| 673 | + if (row.awbh === ''){ | ||
| 674 | + this.fenStatus = undefined | ||
| 675 | + }else { | ||
| 676 | + this.fenStatus = 'addAwbh' | ||
| 677 | + } | ||
| 678 | + | ||
| 556 | this.dialogStatus = 'update' | 679 | this.dialogStatus = 'update' |
| 557 | this.dialogFormVisible = true | 680 | this.dialogFormVisible = true |
| 558 | this.$nextTick(() => { | 681 | this.$nextTick(() => { |
| @@ -575,16 +698,83 @@ | @@ -575,16 +698,83 @@ | ||
| 575 | 698 | ||
| 576 | }) | 699 | }) |
| 577 | }, | 700 | }, |
| 578 | - //保存并发送 | ||
| 579 | - SaveAndSend() { | 701 | + // 发送舱单报 |
| 702 | + handleSendAwb(row) { | ||
| 703 | + this.$confirm("是否发送", "确认消息", { | ||
| 704 | + distinguishCancelAndClose: true, | ||
| 705 | + confirmButtonText: '发送', | ||
| 706 | + cancelButtonText: '取消' | ||
| 707 | + }).then(() => { | ||
| 708 | + if (row.awbh === null) { | ||
| 709 | + row.awbh = '' | ||
| 710 | + } | ||
| 711 | + delete row.parent | ||
| 712 | + delete row.children | ||
| 713 | + sendCreateMt3201(row).then(res => { | ||
| 714 | + if (res.data.count > 0) { | ||
| 715 | + Message.success(res.data.respMessage) | ||
| 716 | + this.getList() | ||
| 717 | + } else { | ||
| 718 | + Message.success(res.data.respMessage) | ||
| 719 | + } | ||
| 720 | + }) | ||
| 721 | + }).catch(error => { | ||
| 722 | + Message.error(error.message) | ||
| 723 | + }) | ||
| 724 | + }, | ||
| 725 | + | ||
| 726 | + // 发送删除报 | ||
| 727 | + handleSendDelete(row) { | ||
| 728 | + this.respModel = { | ||
| 729 | + carrier: undefined, | ||
| 730 | + reason: undefined, | ||
| 731 | + contactName: undefined, | ||
| 732 | + contactTel: undefined, | ||
| 733 | + content: '', | ||
| 734 | + flightNo: undefined, | ||
| 735 | + awba: undefined, | ||
| 736 | + customCode: undefined, | ||
| 737 | + flightDate: undefined, | ||
| 738 | + awbh: undefined | ||
| 739 | + } | ||
| 740 | + this.dialogDeleteVisible = true | ||
| 741 | + this.respModel.flightNo = row.flightno | ||
| 742 | + this.respModel.awba = row.awba | ||
| 743 | + this.respModel.carrier = row.carrier | ||
| 744 | + if (row.awbh === null) { | ||
| 745 | + this.respModel.awbh = '' | ||
| 746 | + } else { | ||
| 747 | + this.respModel.awbh = row.awbh | ||
| 748 | + } | ||
| 749 | + this.respModel.customCode = row.customcode | ||
| 750 | + this.respModel.flightDate = row.flightdate | ||
| 751 | + this.$nextTick(() => { | ||
| 752 | + this.$refs.arriveDeleteForm.clearValidate() | ||
| 753 | + }) | ||
| 754 | + }, | ||
| 580 | 755 | ||
| 756 | + sendArriveDelete() { | ||
| 757 | + this.$refs.arriveDeleteForm.validate(valid => { | ||
| 758 | + if (valid) { | ||
| 759 | + sendRemoveMt3201(this.respModel).then(res => { | ||
| 760 | + if (res.data.count > 0) { | ||
| 761 | + Message.success(res.data.respMessage) | ||
| 762 | + this.dialogDeleteVisible = false | ||
| 763 | + this.getList() | ||
| 764 | + } else { | ||
| 765 | + Message.error(res.data.respMessage) | ||
| 766 | + } | ||
| 767 | + }) | ||
| 768 | + } | ||
| 769 | + }) | ||
| 581 | }, | 770 | }, |
| 582 | // 收发明细 | 771 | // 收发明细 |
| 583 | - handleSend(row) { | 772 | + handleSendDesc(row) { |
| 584 | const resQuery = { | 773 | const resQuery = { |
| 585 | carrier: row.carrier, | 774 | carrier: row.carrier, |
| 586 | flightNo: row.flightno, | 775 | flightNo: row.flightno, |
| 587 | flightDate: row.flightdate, | 776 | flightDate: row.flightdate, |
| 777 | + opertype:row.opertype, | ||
| 588 | awba: row.awba, | 778 | awba: row.awba, |
| 589 | awbh: row.awbh, | 779 | awbh: row.awbh, |
| 590 | messageType: 'MT3201' | 780 | messageType: 'MT3201' |
| @@ -594,15 +784,7 @@ | @@ -594,15 +784,7 @@ | ||
| 594 | this.detailData = res.data | 784 | this.detailData = res.data |
| 595 | }) | 785 | }) |
| 596 | }, | 786 | }, |
| 597 | - // 发送舱单报 | ||
| 598 | - handleAwbSend() { | ||
| 599 | - | ||
| 600 | - }, | ||
| 601 | - // 发送修改报 | ||
| 602 | - handleAwbEdit() { | ||
| 603 | - | ||
| 604 | - }, | ||
| 605 | - //发送删除报 | 787 | + //删除运单 |
| 606 | handleAwbDelete(row) { | 788 | handleAwbDelete(row) { |
| 607 | this.$confirm("是否删除", "确认消息", { | 789 | this.$confirm("是否删除", "确认消息", { |
| 608 | distinguishCancelAndClose: true, | 790 | distinguishCancelAndClose: true, |
| @@ -634,25 +816,29 @@ | @@ -634,25 +816,29 @@ | ||
| 634 | }, | 816 | }, |
| 635 | //更改状态 | 817 | //更改状态 |
| 636 | handleAwbStatus(row) { | 818 | handleAwbStatus(row) { |
| 819 | + | ||
| 637 | this.$confirm("是否发送更改状态", "确认消息", { | 820 | this.$confirm("是否发送更改状态", "确认消息", { |
| 638 | distinguishCancelAndClose: true, | 821 | distinguishCancelAndClose: true, |
| 639 | confirmButtonText: '确认更改', | 822 | confirmButtonText: '确认更改', |
| 640 | cancelButtonText: '取消更改' | 823 | cancelButtonText: '取消更改' |
| 641 | }).then(() => { | 824 | }).then(() => { |
| 642 | - updateStatus(row).then(res => { | ||
| 643 | - if (res.data.count > 0) { | ||
| 644 | - this.$message({ | ||
| 645 | - type: 'success', | ||
| 646 | - message: '当前运单状态已更改' | ||
| 647 | - }) | ||
| 648 | - this.getList() | ||
| 649 | - } else { | ||
| 650 | - this.$message({ | ||
| 651 | - type: 'error', | ||
| 652 | - message: '状态更改失败,请稍后重试' | ||
| 653 | - }) | ||
| 654 | - } | ||
| 655 | - }) | 825 | + if (row.status!==22){ |
| 826 | + row.status =22; | ||
| 827 | + } | ||
| 828 | + // updateStatus(row).then(res => { | ||
| 829 | + // if (res.data.count > 0) { | ||
| 830 | + // this.$message({ | ||
| 831 | + // type: 'success', | ||
| 832 | + // message: '当前运单状态已更改' | ||
| 833 | + // }) | ||
| 834 | + // this.getList() | ||
| 835 | + // } else { | ||
| 836 | + // this.$message({ | ||
| 837 | + // type: 'error', | ||
| 838 | + // message: '状态更改失败,请稍后重试' | ||
| 839 | + // }) | ||
| 840 | + // } | ||
| 841 | + // }) | ||
| 656 | 842 | ||
| 657 | }).catch(action => { | 843 | }).catch(action => { |
| 658 | this.$message({ | 844 | this.$message({ |
| @@ -663,6 +849,41 @@ | @@ -663,6 +849,41 @@ | ||
| 663 | }) | 849 | }) |
| 664 | }) | 850 | }) |
| 665 | }, | 851 | }, |
| 852 | + //获取机场三字码 | ||
| 853 | + remoteMethodAirport(query) { | ||
| 854 | + this.airportCode = [] | ||
| 855 | + if (query !== '') { | ||
| 856 | + this.listLoading = true | ||
| 857 | + getAirportCode({airportid: query}).then(res => { | ||
| 858 | + if (res !== null) { | ||
| 859 | + setTimeout(() => { | ||
| 860 | + this.listLoading = false | ||
| 861 | + this.airportCode = res.data.data | ||
| 862 | + }, 200) | ||
| 863 | + } | ||
| 864 | + }) | ||
| 865 | + } else { | ||
| 866 | + this.airportCode = [] | ||
| 867 | + } | ||
| 868 | + }, | ||
| 869 | + //关区代码 | ||
| 870 | + remoteMethodCustomCode(query) { | ||
| 871 | + this.customCodeList = [] | ||
| 872 | + if (query !== '') { | ||
| 873 | + this.customLoading = true | ||
| 874 | + getCustomCode({customcode: query}).then(res => { | ||
| 875 | + if (res !== null) { | ||
| 876 | + setTimeout(() => { | ||
| 877 | + this.customLoading = false | ||
| 878 | + this.customCodeList = res.data.data | ||
| 879 | + }, 200) | ||
| 880 | + } | ||
| 881 | + }) | ||
| 882 | + } else { | ||
| 883 | + this.airportCode = [] | ||
| 884 | + } | ||
| 885 | + }, | ||
| 886 | + | ||
| 666 | // 携数据跳转 新增运抵 | 887 | // 携数据跳转 新增运抵 |
| 667 | handleAddArrive() { | 888 | handleAddArrive() { |
| 668 | const row = { | 889 | const row = { |
| @@ -671,7 +892,8 @@ | @@ -671,7 +892,8 @@ | ||
| 671 | this.$router.push({name: "出港航班信息", params: {scopeRow: row}}) | 892 | this.$router.push({name: "出港航班信息", params: {scopeRow: row}}) |
| 672 | }, | 893 | }, |
| 673 | handelBackStep() { | 894 | handelBackStep() { |
| 674 | - this.$router.push({name: '出港航班信息', params: {scopeRow: this.arriveModel}}) | 895 | + this.arriveQuery.messageType = 'MT3201' |
| 896 | + this.$router.push({name: '出港航班信息', params: {scopeRow: this.arriveQuery}}) | ||
| 675 | } | 897 | } |
| 676 | 898 | ||
| 677 | } | 899 | } |
| @@ -10,33 +10,33 @@ | @@ -10,33 +10,33 @@ | ||
| 10 | <el-button class="filter-item" type="primary" icon="el-icon-search" @click="handleSearch">查询</el-button> | 10 | <el-button class="filter-item" type="primary" icon="el-icon-search" @click="handleSearch">查询</el-button> |
| 11 | </div> | 11 | </div> |
| 12 | <el-table :data="flightData" stripe style="font-size: 14px" border> | 12 | <el-table :data="flightData" stripe style="font-size: 14px" border> |
| 13 | - <el-table-column label="航班号" width="280px" align="center"> | 13 | + <el-table-column label="航班号" width="180px" align="center"> |
| 14 | <template slot-scope="scope"> | 14 | <template slot-scope="scope"> |
| 15 | <span>{{ scope.row.carrier }}{{ scope.row.flightNo }}</span> | 15 | <span>{{ scope.row.carrier }}{{ scope.row.flightNo }}</span> |
| 16 | </template> | 16 | </template> |
| 17 | </el-table-column> | 17 | </el-table-column> |
| 18 | - <el-table-column label="航班日期" width="280px" align="center"> | 18 | + <el-table-column label="航班日期" width="190px" align="center"> |
| 19 | <template slot-scope="scope"> | 19 | <template slot-scope="scope"> |
| 20 | <i class="el-icon-time"></i> | 20 | <i class="el-icon-time"></i> |
| 21 | <span>{{ scope.row.flightDate }}</span> | 21 | <span>{{ scope.row.flightDate }}</span> |
| 22 | </template> | 22 | </template> |
| 23 | </el-table-column> | 23 | </el-table-column> |
| 24 | - <el-table-column label="始发站" width="280px" align="center"> | 24 | + <el-table-column label="始发站" width="160px" align="center"> |
| 25 | <template slot-scope="scope"> | 25 | <template slot-scope="scope"> |
| 26 | <span>{{ scope.row.originstation }}</span> | 26 | <span>{{ scope.row.originstation }}</span> |
| 27 | </template> | 27 | </template> |
| 28 | </el-table-column> | 28 | </el-table-column> |
| 29 | - <el-table-column label="目的站" width="280px" align="center"> | 29 | + <el-table-column label="目的站" width="160px" align="center"> |
| 30 | <template slot-scope="scope"> | 30 | <template slot-scope="scope"> |
| 31 | <span>{{ scope.row.destinationstation }}</span> | 31 | <span>{{ scope.row.destinationstation }}</span> |
| 32 | </template> | 32 | </template> |
| 33 | </el-table-column> | 33 | </el-table-column> |
| 34 | - <el-table-column label="操作" align="center"> | 34 | + <el-table-column label="操作" width="400px" align="center" fixed="right"> |
| 35 | <template slot-scope="scope"> | 35 | <template slot-scope="scope"> |
| 36 | + <el-button type="primary" size="mini" @click="handlePre(scope.row)">预配舱单</el-button> | ||
| 37 | + <el-button type="primary" size="mini" @click="handleArrive(scope.row)">出港运抵</el-button> | ||
| 36 | <el-button type="primary" size="mini" @click="handleLoading(scope.row)">装载舱单</el-button> | 38 | <el-button type="primary" size="mini" @click="handleLoading(scope.row)">装载舱单</el-button> |
| 37 | <el-button type="primary" size="mini" @click="handleTidy(scope.row)">出港理货</el-button> | 39 | <el-button type="primary" size="mini" @click="handleTidy(scope.row)">出港理货</el-button> |
| 38 | - <el-button type="primary" size="mini" @click="handleArrive(scope.row)">出港运抵</el-button> | ||
| 39 | - <el-button type="primary" size="mini" @click="handlePre(scope.row)">预配舱单</el-button> | ||
| 40 | </template> | 40 | </template> |
| 41 | </el-table-column> | 41 | </el-table-column> |
| 42 | </el-table> | 42 | </el-table> |
| @@ -48,6 +48,7 @@ | @@ -48,6 +48,7 @@ | ||
| 48 | <script> | 48 | <script> |
| 49 | import Pagination from '@/components/Pagination' | 49 | import Pagination from '@/components/Pagination' |
| 50 | import {getFlightListForParam} from '@/api/exitFlight' | 50 | import {getFlightListForParam} from '@/api/exitFlight' |
| 51 | + | ||
| 51 | export default { | 52 | export default { |
| 52 | name: "ExitFlight", | 53 | name: "ExitFlight", |
| 53 | components: {Pagination}, | 54 | components: {Pagination}, |
| @@ -58,18 +59,22 @@ | @@ -58,18 +59,22 @@ | ||
| 58 | listQuery: { | 59 | listQuery: { |
| 59 | pageSize: 1, | 60 | pageSize: 1, |
| 60 | limitSize: 10, | 61 | limitSize: 10, |
| 61 | - flightNo: undefined, | 62 | + flightNo: '', |
| 62 | flightDate: undefined | 63 | flightDate: undefined |
| 63 | }, | 64 | }, |
| 64 | flightData: [], | 65 | flightData: [], |
| 65 | } | 66 | } |
| 66 | }, | 67 | }, |
| 67 | - created(){ | 68 | + created() { |
| 68 | this.getList() | 69 | this.getList() |
| 69 | }, | 70 | }, |
| 70 | methods: { | 71 | methods: { |
| 72 | + /*设置默认航班时间*/ | ||
| 73 | + getdatatime() { | ||
| 74 | + this.listQuery.flightDate = new Date(); | ||
| 75 | + }, | ||
| 71 | getList() { | 76 | getList() { |
| 72 | - getFlightListForParam(this.listQuery).then(res =>{ | 77 | + getFlightListForParam(this.listQuery).then(res => { |
| 73 | this.flightData = res.data.dataList | 78 | this.flightData = res.data.dataList |
| 74 | this.total = res.data.count | 79 | this.total = res.data.count |
| 75 | }) | 80 | }) |
| @@ -79,26 +84,39 @@ | @@ -79,26 +84,39 @@ | ||
| 79 | }, | 84 | }, |
| 80 | handleLoading(row) { | 85 | handleLoading(row) { |
| 81 | row.messageType = 'MT4201' | 86 | row.messageType = 'MT4201' |
| 87 | + row.flightdate = row.flightDate | ||
| 88 | + row.flightno = row.flightNo | ||
| 82 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) | 89 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) |
| 83 | }, | 90 | }, |
| 84 | handleTidy(row) { | 91 | handleTidy(row) { |
| 85 | - row.messageType = 'MT5201' | 92 | + row.messageType = 'MT5202' |
| 93 | + row.flightdate = row.flightDate | ||
| 94 | + row.flightno = row.flightNo | ||
| 86 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) | 95 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) |
| 87 | }, | 96 | }, |
| 88 | handleArrive(row) { | 97 | handleArrive(row) { |
| 89 | row.messageType = 'MT3201' | 98 | row.messageType = 'MT3201' |
| 99 | + row.flightdate = row.flightDate | ||
| 100 | + row.flightno = row.flightNo | ||
| 90 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) | 101 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) |
| 91 | }, | 102 | }, |
| 92 | handlePre(row) { | 103 | handlePre(row) { |
| 93 | row.messageType = 'MT2201' | 104 | row.messageType = 'MT2201' |
| 105 | + row.flightdate = row.flightDate | ||
| 106 | + row.flightno = row.flightNo | ||
| 94 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) | 107 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) |
| 95 | } | 108 | } |
| 109 | + }, | ||
| 110 | + // 页面加载完毕后触发的事件 | ||
| 111 | + mounted() { | ||
| 112 | + var vm = this; | ||
| 113 | + vm.getdatatime(); | ||
| 96 | } | 114 | } |
| 97 | } | 115 | } |
| 98 | 116 | ||
| 99 | </script> | 117 | </script> |
| 100 | <style scoped> | 118 | <style scoped> |
| 101 | - .app-content{ | 119 | + .app-content { |
| 102 | margin-top: 20px; | 120 | margin-top: 20px; |
| 103 | } | 121 | } |
| 104 | </style> | 122 | </style> |
| @@ -12,12 +12,12 @@ | @@ -12,12 +12,12 @@ | ||
| 12 | </el-col> | 12 | </el-col> |
| 13 | </el-row> | 13 | </el-row> |
| 14 | <el-row type="flex" class="row-bg" justify="center"> | 14 | <el-row type="flex" class="row-bg" justify="center"> |
| 15 | - <el-col :span="4"> | 15 | + <el-col :span="4" > |
| 16 | <el-input placeholder="必填" v-model="flightno"> | 16 | <el-input placeholder="必填" v-model="flightno"> |
| 17 | <template slot="prepend">航班号</template> | 17 | <template slot="prepend">航班号</template> |
| 18 | </el-input> | 18 | </el-input> |
| 19 | </el-col> | 19 | </el-col> |
| 20 | - <el-col :span="4"> | 20 | + <el-col :span="4" style="margin-left: 20px"> |
| 21 | <el-date-picker | 21 | <el-date-picker |
| 22 | v-model="flight.flightdate" | 22 | v-model="flight.flightdate" |
| 23 | type="date" | 23 | type="date" |
| @@ -25,21 +25,51 @@ | @@ -25,21 +25,51 @@ | ||
| 25 | placeholder="选择日期"> | 25 | placeholder="选择日期"> |
| 26 | </el-date-picker> | 26 | </el-date-picker> |
| 27 | </el-col> | 27 | </el-col> |
| 28 | - <el-col :span="4"> | ||
| 29 | - <el-input placeholder="必填" v-model="originstation"> | ||
| 30 | - <template slot="prepend">始发站</template> | ||
| 31 | - </el-input> | ||
| 32 | - </el-col> | ||
| 33 | - <el-col :span="4" style="margin-left: 20px"> | ||
| 34 | - <el-input placeholder="必填" v-model="destinationstation"> | ||
| 35 | - <template slot="prepend">目的站</template> | ||
| 36 | - </el-input> | 28 | + <el-col :span="4" style="margin-left: 55px"> |
| 29 | + <el-select | ||
| 30 | + :remote-method="remoteMethodAirport" | ||
| 31 | + :loading="listLoading" | ||
| 32 | + v-model="originstation" | ||
| 33 | + allow-create | ||
| 34 | + default-first-option | ||
| 35 | + filterable | ||
| 36 | + remote | ||
| 37 | + placeholder="请选择起始站" clearable> | ||
| 38 | + <el-option | ||
| 39 | + v-for="item in airportCode" | ||
| 40 | + :key="item.airportid" | ||
| 41 | + :label="item.airportid" | ||
| 42 | + :value="item.airportid"> | ||
| 43 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 44 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 45 | + </el-option> | ||
| 46 | + </el-select> | ||
| 37 | </el-col> | 47 | </el-col> |
| 38 | <el-col :span="4" style="margin-left: 20px"> | 48 | <el-col :span="4" style="margin-left: 20px"> |
| 39 | - <el-input placeholder="可为空" v-model="awba"> | ||
| 40 | - <template slot="prepend">主单号</template> | ||
| 41 | - </el-input> | 49 | + <el-select |
| 50 | + :remote-method="remoteMethodAirport" | ||
| 51 | + :loading="listLoading" | ||
| 52 | + v-model="destinationstation" | ||
| 53 | + allow-create | ||
| 54 | + default-first-option | ||
| 55 | + filterable | ||
| 56 | + remote | ||
| 57 | + placeholder="请选择目的站" clearable> | ||
| 58 | + <el-option | ||
| 59 | + v-for="item in airportCode" | ||
| 60 | + :key="item.airportid" | ||
| 61 | + :label="item.airportid" | ||
| 62 | + :value="item.airportid"> | ||
| 63 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 64 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 65 | + </el-option> | ||
| 66 | + </el-select> | ||
| 42 | </el-col> | 67 | </el-col> |
| 68 | +<!-- <el-col :span="4" style="margin-left: 20px">--> | ||
| 69 | +<!-- <el-input placeholder="可为空" v-model="awba">--> | ||
| 70 | +<!-- <template slot="prepend">主单号</template>--> | ||
| 71 | +<!-- </el-input>--> | ||
| 72 | +<!-- </el-col>--> | ||
| 43 | </el-row> | 73 | </el-row> |
| 44 | <el-row> | 74 | <el-row> |
| 45 | <el-col :span="4" :offset="10"> | 75 | <el-col :span="4" :offset="10"> |
| @@ -55,6 +85,7 @@ | @@ -55,6 +85,7 @@ | ||
| 55 | 85 | ||
| 56 | <script> | 86 | <script> |
| 57 | import {Message} from "element-ui"; | 87 | import {Message} from "element-ui"; |
| 88 | + import {getCountry, getAirportCode} from "@/api/country"; | ||
| 58 | 89 | ||
| 59 | export default { | 90 | export default { |
| 60 | name: 'ExitFlightDesc', | 91 | name: 'ExitFlightDesc', |
| @@ -66,14 +97,18 @@ | @@ -66,14 +97,18 @@ | ||
| 66 | originstation: undefined, | 97 | originstation: undefined, |
| 67 | destinationstation: undefined, | 98 | destinationstation: undefined, |
| 68 | awba: undefined, | 99 | awba: undefined, |
| 69 | - messageType:undefined | 100 | + messageType: undefined |
| 70 | }, | 101 | }, |
| 71 | - btnStatus: true | 102 | + btnStatus: true, |
| 103 | + listLoading: false, | ||
| 104 | + airportList: [], | ||
| 105 | + airportResultCode: [], | ||
| 106 | + airportCode: [], | ||
| 72 | }; | 107 | }; |
| 73 | }, | 108 | }, |
| 74 | created() { | 109 | created() { |
| 75 | if (this.$route.params.scopeRow !== undefined) { | 110 | if (this.$route.params.scopeRow !== undefined) { |
| 76 | - if(this.$route.params.scopeRow.carrier === undefined){ | 111 | + if (this.$route.params.scopeRow.carrier === undefined) { |
| 77 | this.flight.flightno = this.$route.params.scopeRow.flightno | 112 | this.flight.flightno = this.$route.params.scopeRow.flightno |
| 78 | } else { | 113 | } else { |
| 79 | this.flight.flightno = this.$route.params.scopeRow.carrier + this.$route.params.scopeRow.flightno | 114 | this.flight.flightno = this.$route.params.scopeRow.carrier + this.$route.params.scopeRow.flightno |
| @@ -82,61 +117,68 @@ | @@ -82,61 +117,68 @@ | ||
| 82 | this.flight.originstation = this.$route.params.scopeRow.originstation | 117 | this.flight.originstation = this.$route.params.scopeRow.originstation |
| 83 | this.flight.destinationstation = this.$route.params.scopeRow.destinationstation | 118 | this.flight.destinationstation = this.$route.params.scopeRow.destinationstation |
| 84 | this.flight.messageType = this.$route.params.scopeRow.messageType | 119 | this.flight.messageType = this.$route.params.scopeRow.messageType |
| 85 | - if(this.$route.params.scopeRow.awba !== undefined){ | ||
| 86 | - this.flight.awba = this.$route.params.scopeRow.awba.replace('-','') | 120 | + if (this.$route.params.scopeRow.awba !== undefined) { |
| 121 | + this.flight.awba = this.$route.params.scopeRow.awba.replace('-', '') | ||
| 87 | } | 122 | } |
| 88 | - | ||
| 89 | } | 123 | } |
| 90 | }, | 124 | }, |
| 91 | - computed:{ | ||
| 92 | - flightno : { | 125 | + // mounted() { |
| 126 | + // // 延迟加载,否则会出错 | ||
| 127 | + // setTimeout(() => { | ||
| 128 | + // this.airportResultCode = this.airportCode.map(item =>{ | ||
| 129 | + // return {label: item.airportdescchn,value: item.airportid} | ||
| 130 | + // }) | ||
| 131 | + // }, 6000) | ||
| 132 | + // }, | ||
| 133 | + computed: { | ||
| 134 | + flightno: { | ||
| 93 | get: function () { | 135 | get: function () { |
| 94 | return this.flight.flightno | 136 | return this.flight.flightno |
| 95 | }, | 137 | }, |
| 96 | - set: function(val){ | 138 | + set: function (val) { |
| 97 | this.flight.flightno = val.toUpperCase().trim() | 139 | this.flight.flightno = val.toUpperCase().trim() |
| 98 | } | 140 | } |
| 99 | }, | 141 | }, |
| 100 | - originstation :{ | 142 | + originstation: { |
| 101 | get: function () { | 143 | get: function () { |
| 102 | return this.flight.originstation | 144 | return this.flight.originstation |
| 103 | }, | 145 | }, |
| 104 | - set: function(val){ | 146 | + set: function (val) { |
| 105 | this.flight.originstation = val.toUpperCase().trim() | 147 | this.flight.originstation = val.toUpperCase().trim() |
| 106 | } | 148 | } |
| 107 | }, | 149 | }, |
| 108 | - destinationstation :{ | 150 | + destinationstation: { |
| 109 | get: function () { | 151 | get: function () { |
| 110 | return this.flight.destinationstation | 152 | return this.flight.destinationstation |
| 111 | }, | 153 | }, |
| 112 | - set: function(val){ | 154 | + set: function (val) { |
| 113 | this.flight.destinationstation = val.toUpperCase().trim() | 155 | this.flight.destinationstation = val.toUpperCase().trim() |
| 114 | } | 156 | } |
| 115 | }, | 157 | }, |
| 116 | - awba :{ | 158 | + awba: { |
| 117 | get: function () { | 159 | get: function () { |
| 118 | return this.flight.awba | 160 | return this.flight.awba |
| 119 | }, | 161 | }, |
| 120 | - set: function(val){ | 162 | + set: function (val) { |
| 121 | this.flight.awba = val.trim() | 163 | this.flight.awba = val.trim() |
| 122 | } | 164 | } |
| 123 | } | 165 | } |
| 124 | }, | 166 | }, |
| 125 | methods: { | 167 | methods: { |
| 126 | nstep() { | 168 | nstep() { |
| 127 | - if (this.flight.flightno !== undefined && this.flight.flightno !==''&& | ||
| 128 | - this.flight.flightdate !== undefined &&this.flight.flightdate !== '' && | ||
| 129 | - this.flight.destinationstation !== undefined && this.flight.destinationstation !==''&& | ||
| 130 | - this.flight.originstation !== undefined && this.flight.originstation !=='') { | ||
| 131 | - if(this.flight.awba !== '' && this.flight.awba !== undefined){ | 169 | + if (this.flight.flightno !== undefined && this.flight.flightno !== '' && |
| 170 | + this.flight.flightdate !== undefined && this.flight.flightdate !== '' && | ||
| 171 | + this.flight.destinationstation !== undefined && this.flight.destinationstation !== '' && | ||
| 172 | + this.flight.originstation !== undefined && this.flight.originstation !== '') { | ||
| 173 | + if (this.flight.awba !== '' && this.flight.awba !== undefined) { | ||
| 132 | const manifest = this.flight.awba; | 174 | const manifest = this.flight.awba; |
| 133 | const reg = /^[0-9]{11}$/ | 175 | const reg = /^[0-9]{11}$/ |
| 134 | - if(!reg.test(manifest)){ | 176 | + if (!reg.test(manifest)) { |
| 135 | Message.error("主单号只支持数字并且最多11位") | 177 | Message.error("主单号只支持数字并且最多11位") |
| 136 | return | 178 | return |
| 137 | } | 179 | } |
| 138 | - const num = (manifest.substring(3,10)) % 7 | ||
| 139 | - if(num !== eval(manifest.substring(10))){ | 180 | + const num = (manifest.substring(3, 10)) % 7 |
| 181 | + if (num !== eval(manifest.substring(10))) { | ||
| 140 | Message.error("主单号不符合模7校验") | 182 | Message.error("主单号不符合模7校验") |
| 141 | return | 183 | return |
| 142 | } | 184 | } |
| @@ -144,22 +186,38 @@ | @@ -144,22 +186,38 @@ | ||
| 144 | this.flight.awba = undefined | 186 | this.flight.awba = undefined |
| 145 | } | 187 | } |
| 146 | 188 | ||
| 147 | - if(this.flight.messageType ==="MT5201"){ | 189 | + if (this.flight.messageType === "MT5202") { |
| 148 | this.$router.push({name: '出港理货', params: {flightData: this.flight}}); | 190 | this.$router.push({name: '出港理货', params: {flightData: this.flight}}); |
| 149 | } | 191 | } |
| 150 | - if(this.flight.messageType ==="MT4201"){ | 192 | + if (this.flight.messageType === "MT4201") { |
| 151 | this.$router.push({name: '出港装载', params: {flightData: this.flight}}); | 193 | this.$router.push({name: '出港装载', params: {flightData: this.flight}}); |
| 152 | } | 194 | } |
| 153 | - if(this.flight.messageType ==="MT3201"){ | ||
| 154 | - this.$router.push({name:'出港运抵',params:{flightData: this.flight}}) | 195 | + if (this.flight.messageType === "MT3201") { |
| 196 | + this.$router.push({name: '出港运抵', params: {flightData: this.flight}}) | ||
| 155 | } | 197 | } |
| 156 | - if(this.flight.messageType ==="MT2201"){ | ||
| 157 | - this.$router.push({name:'出港预配舱单',params:{flightData: this.flight}}) | 198 | + if (this.flight.messageType === "MT2201") { |
| 199 | + this.$router.push({name: '出港预配舱单', params: {flightData: this.flight}}) | ||
| 158 | } | 200 | } |
| 159 | } else { | 201 | } else { |
| 160 | Message.warning("请将航班信息填写完整") | 202 | Message.warning("请将航班信息填写完整") |
| 161 | } | 203 | } |
| 162 | 204 | ||
| 205 | + }, | ||
| 206 | + remoteMethodAirport(query) { | ||
| 207 | + this.airportCode = [] | ||
| 208 | + if (query !== '') { | ||
| 209 | + this.listLoading = true | ||
| 210 | + getAirportCode({airportid: query}).then(res => { | ||
| 211 | + if(res !== null){ | ||
| 212 | + setTimeout(() => { | ||
| 213 | + this.listLoading = false | ||
| 214 | + this.airportCode = res.data.data | ||
| 215 | + }, 200) | ||
| 216 | + } | ||
| 217 | + }) | ||
| 218 | + } else { | ||
| 219 | + this.airportCode = [] | ||
| 220 | + } | ||
| 163 | } | 221 | } |
| 164 | } | 222 | } |
| 165 | }; | 223 | }; |
| @@ -173,7 +231,7 @@ | @@ -173,7 +231,7 @@ | ||
| 173 | margin: 0 auto; | 231 | margin: 0 auto; |
| 174 | height: 400px; | 232 | height: 400px; |
| 175 | } | 233 | } |
| 176 | - | 234 | + flight |
| 177 | p { | 235 | p { |
| 178 | font-size: 25px; | 236 | font-size: 25px; |
| 179 | font-weight: bold; | 237 | font-weight: bold; |
| @@ -21,7 +21,7 @@ | @@ -21,7 +21,7 @@ | ||
| 21 | </div> | 21 | </div> |
| 22 | </el-col> | 22 | </el-col> |
| 23 | <el-col :span="24"> | 23 | <el-col :span="24"> |
| 24 | - <div class="grid-content content">进港舱单查询</div> | 24 | + <div class="grid-content content">出港装载查询</div> |
| 25 | </el-col> | 25 | </el-col> |
| 26 | <el-col :span="24"> | 26 | <el-col :span="24"> |
| 27 | <div class="grid-content co"> | 27 | <div class="grid-content co"> |
| @@ -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="loadingQuery.awba" placeholder="请输入主单号"></el-input> | 35 | + <el-input clearable v-model="loadingQuery.awba" placeholder="请输入主单号"></el-input> |
| 36 | </div> | 36 | </div> |
| 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> |
| @@ -49,9 +49,10 @@ | @@ -49,9 +49,10 @@ | ||
| 49 | <div class="grid-content content" style="margin-top: 6px">出港装载明细</div> | 49 | <div class="grid-content content" style="margin-top: 6px">出港装载明细</div> |
| 50 | </el-col> | 50 | </el-col> |
| 51 | </el-row> | 51 | </el-row> |
| 52 | - <tree-table v-loading="listLoading" :data="loadingData" :eval-func="func" :expand-all="true" stripe | ||
| 53 | - style="font-size: 12px" border @selection-change="handleSelectionChange"> | ||
| 54 | - <el-table-column label="运单号" width="160" align="center"> | 52 | + <el-table v-loading="listLoading" :data="loadingData" stripe style="font-size: 12px" |
| 53 | + border @selection-change="handleSelectionChange"> | ||
| 54 | + <el-table-column type="selection" width="60"></el-table-column> | ||
| 55 | + <el-table-column label="主单号" width="160" align="center"> | ||
| 55 | <template slot-scope="scope"> | 56 | <template slot-scope="scope"> |
| 56 | <span>{{scope.row.awba}}</span> | 57 | <span>{{scope.row.awba}}</span> |
| 57 | </template> | 58 | </template> |
| @@ -78,50 +79,69 @@ | @@ -78,50 +79,69 @@ | ||
| 78 | </el-table-column> | 79 | </el-table-column> |
| 79 | <el-table-column label="状态" width="100" align="center"> | 80 | <el-table-column label="状态" width="100" align="center"> |
| 80 | <template slot-scope="scope"> | 81 | <template slot-scope="scope"> |
| 81 | - <span v-if="scope.row.status ==='01'">未发送</span> | ||
| 82 | - <span v-if="scope.row.status ==='02'">已发舱单报</span> | 82 | + <span v-if="scope.row.status ==='01'">接受申报</span> |
| 83 | + <span v-if="scope.row.status ==='02'">待人工审核</span> | ||
| 84 | + <span v-if="scope.row.status ==='03'">退单</span> | ||
| 83 | <span v-if="scope.row.status ==='05'">舱单报退单</span> | 85 | <span v-if="scope.row.status ==='05'">舱单报退单</span> |
| 84 | <span v-if="scope.row.status ==='06'">舱单转人工</span> | 86 | <span v-if="scope.row.status ==='06'">舱单转人工</span> |
| 85 | <span v-if="scope.row.status ==='07'">舱单报申报成功</span> | 87 | <span v-if="scope.row.status ==='07'">舱单报申报成功</span> |
| 86 | <span v-if="scope.row.status ==='08'">已发舱单删除报</span> | 88 | <span v-if="scope.row.status ==='08'">已发舱单删除报</span> |
| 87 | <span v-if="scope.row.status ==='09'">舱单删除报退单</span> | 89 | <span v-if="scope.row.status ==='09'">舱单删除报退单</span> |
| 88 | <span v-if="scope.row.status ==='10'">舱单删除报转人工</span> | 90 | <span v-if="scope.row.status ==='10'">舱单删除报转人工</span> |
| 89 | - <span v-if="scope.row.status ==='11'">舱单删除成功</span> | ||
| 90 | - <span v-if="scope.row.status ==='12'">已发舱单修改报</span> | ||
| 91 | - <span v-if="scope.row.status ==='13'">舱单修改报退单</span> | 91 | + <span v-if="scope.row.status ==='11'">放行</span> |
| 92 | + <span v-if="scope.row.status ==='12'">拒装</span> | ||
| 93 | + <span v-if="scope.row.status ==='13'">禁卸</span> | ||
| 92 | <span v-if="scope.row.status ==='14'">舱单修改报转人工</span> | 94 | <span v-if="scope.row.status ==='14'">舱单修改报转人工</span> |
| 93 | <span v-if="scope.row.status ==='15'">舱单修改报成功</span> | 95 | <span v-if="scope.row.status ==='15'">舱单修改报成功</span> |
| 94 | <span v-if="scope.row.status ==='16'">海关已存在</span> | 96 | <span v-if="scope.row.status ==='16'">海关已存在</span> |
| 97 | + <span v-if="scope.row.status ==='21'">可自动发送</span> | ||
| 98 | + <span v-if="scope.row.status ==='22'">未发送</span> | ||
| 99 | + <span v-if="scope.row.status ==='23'">已发送新增报</span> | ||
| 100 | + <span v-if="scope.row.status ==='24'">已发送删除报</span> | ||
| 101 | + <span v-if="scope.row.status ==='25'">已发送修改报</span> | ||
| 95 | </template> | 102 | </template> |
| 96 | </el-table-column> | 103 | </el-table-column> |
| 97 | - <el-table-column prop="receipt" label="回执信息" width="180" align="center"> | 104 | + <el-table-column label="回执信息" width="180" align="center"> |
| 98 | <template slot-scope="scope"> | 105 | <template slot-scope="scope"> |
| 99 | <span>{{scope.row.ext5}}</span> | 106 | <span>{{scope.row.ext5}}</span> |
| 100 | </template> | 107 | </template> |
| 101 | </el-table-column> | 108 | </el-table-column> |
| 102 | - <el-table-column prop="operation" label="操作" align="center"> | 109 | + <el-table-column label="操作" align="center" fixed="right"> |
| 103 | <template slot-scope="scope"> | 110 | <template slot-scope="scope"> |
| 104 | <el-button size="mini" @click="handleSend(scope.row)">收发明细</el-button> | 111 | <el-button size="mini" @click="handleSend(scope.row)">收发明细</el-button> |
| 105 | - <el-button size="mini" type="success" @click="handleEdit(scope.row)">编辑主单 | 112 | + |
| 113 | + <el-button size="mini" type="success" @click="handleEdit(scope.row)" >编辑 | ||
| 106 | </el-button> | 114 | </el-button> |
| 115 | + | ||
| 107 | <el-button size="mini" type="primary" @click="handleSendAwb(scope.row)" | 116 | <el-button size="mini" type="primary" @click="handleSendAwb(scope.row)" |
| 108 | - :disabled="scope.row.status !=='00'">发送舱单报 | 117 | + :disabled="scope.row.status ==='23'">发送出港装载报 |
| 118 | + </el-button> | ||
| 119 | + | ||
| 120 | + <br><br> | ||
| 121 | + <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单 | ||
| 109 | </el-button> | 122 | </el-button> |
| 110 | - <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单</el-button> | 123 | + |
| 111 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" | 124 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" |
| 112 | - :disabled="scope.row.status ==='00'">更改状态 | 125 | + :disabled="scope.row.status ==='22'">更改状态 |
| 113 | </el-button> | 126 | </el-button> |
| 127 | + | ||
| 128 | + <el-button size="mini" type="danger" @click="handleSendDelete(scope.row)" | ||
| 129 | + :disabled="scope.row.status ==='24'">发删除报 | ||
| 130 | + </el-button> | ||
| 131 | + | ||
| 114 | </template> | 132 | </template> |
| 115 | </el-table-column> | 133 | </el-table-column> |
| 116 | - </tree-table> | 134 | + </el-table> |
| 117 | <div class="btnFoot"> | 135 | <div class="btnFoot"> |
| 118 | <el-row> | 136 | <el-row> |
| 119 | <el-button type="primary" size="mini" | 137 | <el-button type="primary" size="mini" |
| 120 | - v-if="loadingModel.flightno !== undefined || loadingData.length >0" | 138 | + v-if="loadingQuery.flightno !== undefined || loadingData.length >0" |
| 121 | @click="handelAddLoadingInfo">新增出港装载 | 139 | @click="handelAddLoadingInfo">新增出港装载 |
| 122 | </el-button> | 140 | </el-button> |
| 123 | - <el-button type="primary" size="mini" v-if="loadingModel.flightno !== undefined || loadingData.length>0" | ||
| 124 | - @click="handelBackStep">返回</el-button> | 141 | + <el-button type="primary" size="mini" |
| 142 | + v-if="loadingQuery.flightno !== undefined || loadingData.length>0" | ||
| 143 | + @click="handelBackStep">返回 | ||
| 144 | + </el-button> | ||
| 125 | </el-row> | 145 | </el-row> |
| 126 | </div> | 146 | </div> |
| 127 | <pagination v-show="total>0" :total="total" :page.sync="loadingQuery.page" :limit.sync="loadingQuery.limit" | 147 | <pagination v-show="total>0" :total="total" :page.sync="loadingQuery.page" :limit.sync="loadingQuery.limit" |
| @@ -136,7 +156,7 @@ | @@ -136,7 +156,7 @@ | ||
| 136 | <el-row> | 156 | <el-row> |
| 137 | <el-col :span="7.5"> | 157 | <el-col :span="7.5"> |
| 138 | <el-form-item label="主单号" prop="awba"> | 158 | <el-form-item label="主单号" prop="awba"> |
| 139 | - <el-input v-model="loadingModel.awba"></el-input> | 159 | + <el-input v-model="loadingModel.awba" :disabled="dialogStatus ==='update'"></el-input> |
| 140 | </el-form-item> | 160 | </el-form-item> |
| 141 | </el-col> | 161 | </el-col> |
| 142 | <el-col :span="7.5"> | 162 | <el-col :span="7.5"> |
| @@ -155,13 +175,28 @@ | @@ -155,13 +175,28 @@ | ||
| 155 | 175 | ||
| 156 | <el-col :span="7.5"> | 176 | <el-col :span="7.5"> |
| 157 | <el-form-item label="起始站" prop="originstation"> | 177 | <el-form-item label="起始站" prop="originstation"> |
| 158 | - <el-input v-model="originstation" | ||
| 159 | - :disabled="dialogStatus ==='update'"></el-input> | 178 | + <el-select filterable clearable placeholder="请选择起始站" :remote-method="remoteMethodAirport" |
| 179 | + allow-create v-model="originstation" remote :disabled="dialogStatus ==='update'"> | ||
| 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> | ||
| 160 | </el-form-item> | 187 | </el-form-item> |
| 161 | </el-col> | 188 | </el-col> |
| 162 | <el-col :span="7.5"> | 189 | <el-col :span="7.5"> |
| 163 | - <el-form-item label="目的站" prop="flightno"> | ||
| 164 | - <el-input v-model="destinationstation" :disabled="dialogStatus ==='update'"></el-input> | 190 | + <el-form-item label="目的站" prop="destinationstation"> |
| 191 | + <el-select filterable clearable placeholder="请选择起始站" :remote-method="remoteMethodAirport" | ||
| 192 | + allow-create v-model="destinationstation" remote :disabled="dialogStatus ==='update'"> | ||
| 193 | + <el-option v-for="item in airportCode" | ||
| 194 | + :key="item.airportid" :label="item.airportid" | ||
| 195 | + :value="item.airportid" :disabled="dialogStatus === 'update'"> | ||
| 196 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 197 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 198 | + </el-option> | ||
| 199 | + </el-select> | ||
| 165 | </el-form-item> | 200 | </el-form-item> |
| 166 | </el-col> | 201 | </el-col> |
| 167 | <el-col :span="7.5"> | 202 | <el-col :span="7.5"> |
| @@ -176,13 +211,13 @@ | @@ -176,13 +211,13 @@ | ||
| 176 | </div> | 211 | </div> |
| 177 | <el-row> | 212 | <el-row> |
| 178 | <el-col :span="7.5"> | 213 | <el-col :span="7.5"> |
| 179 | - <el-form-item label="装载件数" prop="piece"> | 214 | + <el-form-item label="装载件数" prop="lodingpiece"> |
| 180 | <el-input v-model.number="loadingModel.lodingpiece"></el-input> | 215 | <el-input v-model.number="loadingModel.lodingpiece"></el-input> |
| 181 | </el-form-item> | 216 | </el-form-item> |
| 182 | </el-col> | 217 | </el-col> |
| 183 | <el-col :span="7.5"> | 218 | <el-col :span="7.5"> |
| 184 | - <el-form-item label="装载重量" prop="weight"> | ||
| 185 | - <el-input v-model.number="loadingModel.lodingweight"></el-input> | 219 | + <el-form-item label="装载重量" prop="lodingweight"> |
| 220 | + <el-input v-model="loadingModel.lodingweight"></el-input> | ||
| 186 | </el-form-item> | 221 | </el-form-item> |
| 187 | </el-col> | 222 | </el-col> |
| 188 | <el-col :span="7.5"> | 223 | <el-col :span="7.5"> |
| @@ -195,27 +230,34 @@ | @@ -195,27 +230,34 @@ | ||
| 195 | </el-row> | 230 | </el-row> |
| 196 | <el-row> | 231 | <el-row> |
| 197 | <el-col :span="7.5"> | 232 | <el-col :span="7.5"> |
| 198 | - <el-form-item label="运单件数" prop="price"> | ||
| 199 | - <el-input v-model="loadingModel.awbprice"></el-input> | 233 | + <el-form-item label="运单件数" prop="awbprice"> |
| 234 | + <el-input v-model.number="loadingModel.awbprice"></el-input> | ||
| 200 | </el-form-item> | 235 | </el-form-item> |
| 201 | </el-col> | 236 | </el-col> |
| 202 | <el-col :span="7.5"> | 237 | <el-col :span="7.5"> |
| 203 | - <el-form-item label="运单重量" prop="weight"> | 238 | + <el-form-item label="运单重量" prop="awbweight"> |
| 204 | <el-input v-model="loadingModel.awbweight"></el-input> | 239 | <el-input v-model="loadingModel.awbweight"></el-input> |
| 205 | </el-form-item> | 240 | </el-form-item> |
| 206 | </el-col> | 241 | </el-col> |
| 207 | <el-col :span="7.5"> | 242 | <el-col :span="7.5"> |
| 208 | <el-form-item label="海关关区" prop="customcode"> | 243 | <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> | 244 | + <el-select v-model="loadingModel.customcode" placeholder="请选择关区代码" |
| 245 | + filterable clearable remote :remote-method="remoteMethodCustomCode" :loading="customLoading" | ||
| 246 | + allow-create | ||
| 247 | + default-first-option | ||
| 248 | + > | ||
| 249 | + <el-option v-for="item in customCodeList" :key="item.customcode" :label="item.customcode" | ||
| 250 | + :value="item.customcode"> | ||
| 251 | + <span style="float: left">{{ item.customcode }}</span> | ||
| 252 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.customname }}</span> | ||
| 253 | + </el-option> | ||
| 212 | </el-select> | 254 | </el-select> |
| 213 | </el-form-item> | 255 | </el-form-item> |
| 214 | </el-col> | 256 | </el-col> |
| 215 | </el-row> | 257 | </el-row> |
| 216 | <el-row> | 258 | <el-row> |
| 217 | <el-col :span="7.5"> | 259 | <el-col :span="7.5"> |
| 218 | - <el-form-item label="特货代码" prop="awbh"> | 260 | + <el-form-item label="特货代码" prop="specialgoods"> |
| 219 | <el-input v-model="loadingModel.specialgoods"></el-input> | 261 | <el-input v-model="loadingModel.specialgoods"></el-input> |
| 220 | </el-form-item> | 262 | </el-form-item> |
| 221 | </el-col> | 263 | </el-col> |
| @@ -229,12 +271,11 @@ | @@ -229,12 +271,11 @@ | ||
| 229 | <div slot="footer" class="dialog-footer"> | 271 | <div slot="footer" class="dialog-footer"> |
| 230 | <el-button @click="dialogFormVisible = false">取消</el-button> | 272 | <el-button @click="dialogFormVisible = false">取消</el-button> |
| 231 | <el-button type="primary" @click="dialogStatus==='create'?createData():updateData()">保存</el-button> | 273 | <el-button type="primary" @click="dialogStatus==='create'?createData():updateData()">保存</el-button> |
| 232 | - <el-button type="success" @click="handleSaveAndSend">保存并发送</el-button> | ||
| 233 | </div> | 274 | </div> |
| 234 | </el-dialog> | 275 | </el-dialog> |
| 235 | <el-dialog title="收发明细" :visible.sync="dialogTableVisible"> | 276 | <el-dialog title="收发明细" :visible.sync="dialogTableVisible"> |
| 236 | <el-table :data="detailData" border> | 277 | <el-table :data="detailData" border> |
| 237 | - <el-table-column label="操作时间" width="150"> | 278 | + <el-table-column label="操作时间" width="180"> |
| 238 | <template slot-scope="scope"> | 279 | <template slot-scope="scope"> |
| 239 | {{scope.row.busdate}} | 280 | {{scope.row.busdate}} |
| 240 | </template> | 281 | </template> |
| @@ -264,6 +305,11 @@ | @@ -264,6 +305,11 @@ | ||
| 264 | {{scope.row.cusrestext}} | 305 | {{scope.row.cusrestext}} |
| 265 | </template> | 306 | </template> |
| 266 | </el-table-column> | 307 | </el-table-column> |
| 308 | + <el-table-column label="操作类型" width="100"> | ||
| 309 | + <template slot-scope="scope"> | ||
| 310 | + {{scope.row.opertype}} | ||
| 311 | + </template> | ||
| 312 | + </el-table-column> | ||
| 267 | <el-table-column label="操作人" width="100"> | 313 | <el-table-column label="操作人" width="100"> |
| 268 | <template slot-scope="scope"> | 314 | <template slot-scope="scope"> |
| 269 | {{scope.row.operusername}} | 315 | {{scope.row.operusername}} |
| @@ -271,24 +317,55 @@ | @@ -271,24 +317,55 @@ | ||
| 271 | </el-table-column> | 317 | </el-table-column> |
| 272 | </el-table> | 318 | </el-table> |
| 273 | </el-dialog> | 319 | </el-dialog> |
| 320 | + <el-dialog title="删除原因" :visible.sync="dialogDeleteVisible" width="30%"> | ||
| 321 | + <el-form ref="loadingDeleteForm" :model="respModel" :rules="loadingDeleteRules" | ||
| 322 | + label-width="120px" style="margin-right: 50px"> | ||
| 323 | + <el-form-item label="删除原因" prop="reason"> | ||
| 324 | + <el-input v-model="respModel.reason" placeholder="删除原因"></el-input> | ||
| 325 | + </el-form-item> | ||
| 326 | + <el-form-item label="删除操作人" prop="contactName"> | ||
| 327 | + <el-input v-model="respModel.contactName" placeholder="操作人姓名"></el-input> | ||
| 328 | + </el-form-item> | ||
| 329 | + <el-form-item label="操作人Tel" prop="contactTel"> | ||
| 330 | + <el-input v-model="respModel.contactTel" placeholder="删除操作人联系方式"></el-input> | ||
| 331 | + </el-form-item> | ||
| 332 | + <el-form-item label="备注"> | ||
| 333 | + <el-input v-model="respModel.content" type="textarea"></el-input> | ||
| 334 | + </el-form-item> | ||
| 335 | + </el-form> | ||
| 336 | + <div slot="footer" class="dialog-footer"> | ||
| 337 | + <el-button @click="dialogDeleteVisible = false">取消</el-button> | ||
| 338 | + <el-button type="primary" @click="sendLoadingDelete()">发送</el-button> | ||
| 339 | + </div> | ||
| 340 | + </el-dialog> | ||
| 274 | </div> | 341 | </div> |
| 275 | </div> | 342 | </div> |
| 276 | </template> | 343 | </template> |
| 277 | <script> | 344 | <script> |
| 278 | - import treeTable from '@/components/TreeTable' | ||
| 279 | - import treeToArray from '@/utils/customEval' | ||
| 280 | import Pagination from '@/components/Pagination' | 345 | import Pagination from '@/components/Pagination' |
| 281 | - import {getMt4201ListForParam, deleteByIsDelete, updateStatus, updateMT4201, addMt4201} from '@/api/exitLoading' | ||
| 282 | - import {Message} from "element-ui"; | ||
| 283 | - import {validAwb, validAlphabets, validAlphabetsAndNum, validAlphabetsAndSpanceKey,validatorNum} from "@/utils/validate" | 346 | + import {getCustomCode,getAirportCode} from "@/api/country"; |
| 347 | + import { | ||
| 348 | + getMt4201ListForParam, deleteByIsDelete, updateStatus, | ||
| 349 | + updateMT4201, addMt4201, sendCreateMt4201, sendDeleteMt4201, test | ||
| 350 | + } from '@/api/exitLoading' | ||
| 351 | + import {Message} from "element-ui" | ||
| 352 | + import { | ||
| 353 | + validAwb, | ||
| 354 | + validAlphabets, | ||
| 355 | + validAlphabetsAndNum, | ||
| 356 | + validAlphabetsAndSpanceKey, | ||
| 357 | + validatorNum, | ||
| 358 | + validatorCustomsNum | ||
| 359 | + } from "@/utils/validate" | ||
| 360 | + import {getResponseForParam} from '@/api/responseDetail' | ||
| 284 | export default { | 361 | export default { |
| 285 | name: "ExitLoading", | 362 | name: "ExitLoading", |
| 286 | - components: {treeTable, Pagination}, | 363 | + components: { Pagination}, |
| 287 | inject: ['reload'], | 364 | inject: ['reload'], |
| 288 | data() { | 365 | data() { |
| 289 | const validatorAwb = (rule, value, callback) => { | 366 | const validatorAwb = (rule, value, callback) => { |
| 290 | if (!validAwb(value)) { | 367 | if (!validAwb(value)) { |
| 291 | - callback("请正确书写主单号") | 368 | + callback("请正确书写主单号格式为xxx-xxxxxxxx") |
| 292 | } | 369 | } |
| 293 | callback() | 370 | callback() |
| 294 | } | 371 | } |
| @@ -304,8 +381,8 @@ | @@ -304,8 +381,8 @@ | ||
| 304 | } | 381 | } |
| 305 | callback() | 382 | callback() |
| 306 | } | 383 | } |
| 307 | - const validAlphabetsSpanceKey = (rule,value,callback) =>{ | ||
| 308 | - if(!validAlphabetsAndSpanceKey(value)){ | 384 | + const validAlphabetsSpanceKey = (rule, value, callback) => { |
| 385 | + if (!validAlphabetsAndSpanceKey(value)) { | ||
| 309 | callback("只能输入字母、数字、空格") | 386 | callback("只能输入字母、数字、空格") |
| 310 | } | 387 | } |
| 311 | callback() | 388 | callback() |
| @@ -316,18 +393,26 @@ | @@ -316,18 +393,26 @@ | ||
| 316 | } | 393 | } |
| 317 | callback() | 394 | callback() |
| 318 | } | 395 | } |
| 396 | + const validatorCustomsNums = (rule, value, callback) => { | ||
| 397 | + if (!validatorCustomsNum(value)) { | ||
| 398 | + callback(new Error("只能输入4位数字")) | ||
| 399 | + } | ||
| 400 | + callback() | ||
| 401 | + } | ||
| 319 | return { | 402 | return { |
| 320 | - func: treeToArray, | ||
| 321 | total: 1, | 403 | total: 1, |
| 322 | - isAdmin:false, | 404 | + isAdmin: false, |
| 323 | dialogMap: { | 405 | dialogMap: { |
| 324 | update: '编辑出港装载', | 406 | update: '编辑出港装载', |
| 325 | create: '添加出港装载', | 407 | create: '添加出港装载', |
| 326 | }, | 408 | }, |
| 327 | - customcodeList: [4604, 4620], | 409 | + customCodeList: [], |
| 410 | + airportCode:[], | ||
| 328 | dialogStatus: undefined, | 411 | dialogStatus: undefined, |
| 329 | dialogTableVisible: false, | 412 | dialogTableVisible: false, |
| 330 | dialogFormVisible: false, | 413 | dialogFormVisible: false, |
| 414 | + dialogDeleteVisible: false, | ||
| 415 | + customLoading: false, | ||
| 331 | listLoading: false, | 416 | listLoading: false, |
| 332 | loadingQuery: { | 417 | loadingQuery: { |
| 333 | pageSize: 1, | 418 | pageSize: 1, |
| @@ -338,7 +423,8 @@ | @@ -338,7 +423,8 @@ | ||
| 338 | flightdate: undefined, | 423 | flightdate: undefined, |
| 339 | originstation: undefined, | 424 | originstation: undefined, |
| 340 | destinationstation: undefined, | 425 | destinationstation: undefined, |
| 341 | - customcode: undefined | 426 | + customcode: undefined, |
| 427 | + messageType: undefined | ||
| 342 | }, | 428 | }, |
| 343 | loadingRoles: { | 429 | loadingRoles: { |
| 344 | awba: [{required: true, trigger: 'blur', validator: validatorAwb}], | 430 | awba: [{required: true, trigger: 'blur', validator: validatorAwb}], |
| @@ -346,16 +432,21 @@ | @@ -346,16 +432,21 @@ | ||
| 346 | goodsname: [{required: true, trigger: 'blur', validator: validAlphabetsSpanceKey}], | 432 | goodsname: [{required: true, trigger: 'blur', validator: validAlphabetsSpanceKey}], |
| 347 | carrier: [{required: true, trigger: 'blur', validator: validatorAwbh}], | 433 | carrier: [{required: true, trigger: 'blur', validator: validatorAwbh}], |
| 348 | flightno: [{required: true, trigger: 'blur', validator: validatorAwbh}], | 434 | flightno: [{required: true, trigger: 'blur', validator: validatorAwbh}], |
| 435 | + flightdate: [{required: true, trigger: 'blur'}], | ||
| 436 | + loadingtime: [{required: true, trigger: 'blur'}], | ||
| 349 | originstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], | 437 | originstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], |
| 350 | destinationstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], | 438 | destinationstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], |
| 351 | - piece: [{type: 'number', required: true, trigger: 'change', message: '只能输入数字'}], | ||
| 352 | - weight: [{type: 'number', required: true, trigger: 'change', message: '只能输入数字'}], | ||
| 353 | - customcode:[{required: true, trigger: 'change',message:'不能为空'}] | 439 | + lodingpiece: [{type: 'number',required: true, trigger: 'change', message: '只能输入数字'}], |
| 440 | + lodingweight: [{required: true, trigger: 'change', message: '只能输入数字,并且小数位最多两位',validator: validatorNums}], | ||
| 441 | + customcode: [ | ||
| 442 | + {required: true, message: '关区号不能为空'}, | ||
| 443 | + {validator: validatorCustomsNums,trigger: 'change',message: '关区号为4位整数'} | ||
| 444 | + ] | ||
| 354 | }, | 445 | }, |
| 355 | loadingData: [], | 446 | loadingData: [], |
| 356 | detailData: [], | 447 | detailData: [], |
| 357 | loadingModel: { | 448 | loadingModel: { |
| 358 | - carrier:undefined, | 449 | + carrier: undefined, |
| 359 | flightno: undefined, | 450 | flightno: undefined, |
| 360 | flightdate: undefined, | 451 | flightdate: undefined, |
| 361 | originstation: undefined, | 452 | originstation: undefined, |
| @@ -369,8 +460,29 @@ | @@ -369,8 +460,29 @@ | ||
| 369 | loadingtime: undefined, | 460 | loadingtime: undefined, |
| 370 | messageType: 'MT4201', | 461 | messageType: 'MT4201', |
| 371 | awbprice: undefined, | 462 | awbprice: undefined, |
| 372 | - awbweight: undefined | ||
| 373 | - } | 463 | + awbweight: undefined, |
| 464 | + reason: undefined, | ||
| 465 | + contactName: undefined, | ||
| 466 | + contactTel: undefined, | ||
| 467 | + content: undefined, | ||
| 468 | + }, | ||
| 469 | + respModel: { | ||
| 470 | + uuid: undefined, | ||
| 471 | + reason: undefined, | ||
| 472 | + contactName: undefined, | ||
| 473 | + contactTel: undefined, | ||
| 474 | + content: '', | ||
| 475 | + flightNo: undefined, | ||
| 476 | + awba: undefined, | ||
| 477 | + customCode: undefined, | ||
| 478 | + flightDate: undefined, | ||
| 479 | + awbh: '' | ||
| 480 | + }, | ||
| 481 | + loadingDeleteRules: { | ||
| 482 | + reason: [{required: true, message: '删除原因不能为空', trigger: 'blur'}], | ||
| 483 | + contactName: [{required: true, message: '删除操作人不能为空', trigger: 'blur'}], | ||
| 484 | + contactTel: [{required: true, message: '操作人联系方式不能为空', trigger: 'blur'}] | ||
| 485 | + }, | ||
| 374 | } | 486 | } |
| 375 | }, | 487 | }, |
| 376 | created() { | 488 | created() { |
| @@ -387,7 +499,7 @@ | @@ -387,7 +499,7 @@ | ||
| 387 | this.getList() | 499 | this.getList() |
| 388 | } | 500 | } |
| 389 | let username = JSON.parse(sessionStorage.getItem('user')).username | 501 | let username = JSON.parse(sessionStorage.getItem('user')).username |
| 390 | - if(username === 'admin'){ | 502 | + if (username === 'admin') { |
| 391 | this.isAdmin = true | 503 | this.isAdmin = true |
| 392 | } | 504 | } |
| 393 | }, | 505 | }, |
| @@ -469,19 +581,20 @@ | @@ -469,19 +581,20 @@ | ||
| 469 | }, | 581 | }, |
| 470 | // 查询 | 582 | // 查询 |
| 471 | handleSearch() { | 583 | handleSearch() { |
| 472 | - this.loadingQuery.carrier = undefined | ||
| 473 | - this.loadingQuery.flightno = undefined | ||
| 474 | - this.loadingQuery.originstation = undefined | ||
| 475 | - this.loadingQuery.flightdate = undefined | ||
| 476 | - this.loadingQuery.destinationstation = undefined | 584 | + // this.loadingQuery.carrier = undefined |
| 585 | + // this.loadingQuery.flightno = undefined | ||
| 586 | + // this.loadingQuery.originstation = undefined | ||
| 587 | + // this.loadingQuery.flightdate = undefined | ||
| 588 | + // this.loadingQuery.destinationstation = undefined | ||
| 477 | this.getList() | 589 | this.getList() |
| 478 | }, | 590 | }, |
| 479 | // 收发明细 | 591 | // 收发明细 |
| 480 | - handleSend() { | 592 | + handleSend(row) { |
| 481 | const resQuery = { | 593 | const resQuery = { |
| 482 | carrier: row.carrier, | 594 | carrier: row.carrier, |
| 483 | flightNo: row.flightno, | 595 | flightNo: row.flightno, |
| 484 | flightDate: row.flightdate, | 596 | flightDate: row.flightdate, |
| 597 | + opertype: row.opertype, | ||
| 485 | awba: row.awba, | 598 | awba: row.awba, |
| 486 | awbh: row.awbh, | 599 | awbh: row.awbh, |
| 487 | messageType: 'MT4201' | 600 | messageType: 'MT4201' |
| @@ -494,7 +607,6 @@ | @@ -494,7 +607,6 @@ | ||
| 494 | // 编辑 弹框 | 607 | // 编辑 弹框 |
| 495 | handleEdit(row) { | 608 | handleEdit(row) { |
| 496 | this.loadingModel = Object.assign({}, row) | 609 | this.loadingModel = Object.assign({}, row) |
| 497 | - console.log(this.loadingModel) | ||
| 498 | this.dialogStatus = 'update' | 610 | this.dialogStatus = 'update' |
| 499 | this.dialogFormVisible = true | 611 | this.dialogFormVisible = true |
| 500 | this.$nextTick(() => { | 612 | this.$nextTick(() => { |
| @@ -519,10 +631,75 @@ | @@ -519,10 +631,75 @@ | ||
| 519 | }, | 631 | }, |
| 520 | 632 | ||
| 521 | // 发送舱单报 | 633 | // 发送舱单报 |
| 522 | - handleSendAwb() { | 634 | + handleSendAwb(row) { |
| 635 | + | ||
| 636 | + this.$confirm("是否发送", "确认消息", { | ||
| 637 | + distinguishCancelAndClose: true, | ||
| 638 | + confirmButtonText: '发送', | ||
| 639 | + cancelButtonText: '取消' | ||
| 640 | + }).then(() => { | ||
| 641 | + if(row.awbh === null || row.awbh === undefined){ | ||
| 642 | + row.awbh = '' | ||
| 643 | + } | ||
| 644 | + sendCreateMt4201(row).then(res => { | ||
| 645 | + if (res.data.count > 0) { | ||
| 646 | + Message.success(res.data.respMessage) | ||
| 647 | + this.getList() | ||
| 648 | + }else { | ||
| 649 | + Message.success(res.data.respMessage) | ||
| 650 | + } | ||
| 651 | + }) | ||
| 652 | + }).catch(error =>{ | ||
| 653 | + Message.error(error.message) | ||
| 654 | + }) | ||
| 655 | + }, | ||
| 523 | 656 | ||
| 657 | + // 发送删除报 | ||
| 658 | + handleSendDelete(row) { | ||
| 659 | + this.respModel = { | ||
| 660 | + carrier: undefined, | ||
| 661 | + reason: undefined, | ||
| 662 | + contactName: undefined, | ||
| 663 | + contactTel: undefined, | ||
| 664 | + content: '', | ||
| 665 | + flightNo: undefined, | ||
| 666 | + awba: undefined, | ||
| 667 | + customCode: undefined, | ||
| 668 | + flightDate: undefined, | ||
| 669 | + awbh: '' | ||
| 670 | + } | ||
| 671 | + this.dialogDeleteVisible = true | ||
| 672 | + this.respModel.carrier = row.carrier | ||
| 673 | + this.respModel.flightNo = row.flightno | ||
| 674 | + this.respModel.awba = row.awba | ||
| 675 | + this.respModel.customCode = row.customcode | ||
| 676 | + this.respModel.flightDate = row.flightdate | ||
| 677 | + if(row.awbh ===null){ | ||
| 678 | + this.respModel.awbh = '' | ||
| 679 | + }else { | ||
| 680 | + this.respModel.awbh = row.awbh | ||
| 681 | + } | ||
| 682 | + this.$nextTick(() => { | ||
| 683 | + this.$refs.loadingDeleteForm.clearValidate() | ||
| 684 | + }) | ||
| 685 | + }, | ||
| 686 | + | ||
| 687 | + sendLoadingDelete() { | ||
| 688 | + this.$refs.loadingDeleteForm.validate(valid => { | ||
| 689 | + if (valid) { | ||
| 690 | + sendDeleteMt4201(this.respModel).then(res => { | ||
| 691 | + if (res.data.count > 0) { | ||
| 692 | + Message.success(res.data.respMessage) | ||
| 693 | + this.dialogDeleteVisible = false | ||
| 694 | + this.getList() | ||
| 695 | + } else { | ||
| 696 | + Message.success(res.data.respMessage) | ||
| 697 | + } | ||
| 698 | + }) | ||
| 699 | + } | ||
| 700 | + }) | ||
| 524 | }, | 701 | }, |
| 525 | - // 删除 发送删除报 | 702 | + // 删除 |
| 526 | handleAwbDelete(row) { | 703 | handleAwbDelete(row) { |
| 527 | this.$confirm("是否删除", "确认消息", { | 704 | this.$confirm("是否删除", "确认消息", { |
| 528 | distinguishCancelAndClose: true, | 705 | distinguishCancelAndClose: true, |
| @@ -559,20 +736,23 @@ | @@ -559,20 +736,23 @@ | ||
| 559 | confirmButtonText: '确认更改', | 736 | confirmButtonText: '确认更改', |
| 560 | cancelButtonText: '取消更改' | 737 | cancelButtonText: '取消更改' |
| 561 | }).then(() => { | 738 | }).then(() => { |
| 562 | - updateStatus(row).then(res => { | ||
| 563 | - if (res.data.count > 0) { | ||
| 564 | - this.$message({ | ||
| 565 | - type: 'success', | ||
| 566 | - message: '当前运单状态已更改' | ||
| 567 | - }) | ||
| 568 | - this.getList() | ||
| 569 | - } else { | ||
| 570 | - this.$message({ | ||
| 571 | - type: 'error', | ||
| 572 | - message: '状态更改失败,请稍后重试' | ||
| 573 | - }) | ||
| 574 | - } | ||
| 575 | - }) | 739 | + if (row.status!==22){ |
| 740 | + row.status =22; | ||
| 741 | + } | ||
| 742 | + // updateStatus(row).then(res => { | ||
| 743 | + // if (res.data.count > 0) { | ||
| 744 | + // this.$message({ | ||
| 745 | + // type: 'success', | ||
| 746 | + // message: '当前运单状态已更改' | ||
| 747 | + // }) | ||
| 748 | + // this.getList() | ||
| 749 | + // } else { | ||
| 750 | + // this.$message({ | ||
| 751 | + // type: 'error', | ||
| 752 | + // message: '状态更改失败,请稍后重试' | ||
| 753 | + // }) | ||
| 754 | + // } | ||
| 755 | + // }) | ||
| 576 | 756 | ||
| 577 | }).catch(action => { | 757 | }).catch(action => { |
| 578 | this.$message({ | 758 | this.$message({ |
| @@ -583,14 +763,10 @@ | @@ -583,14 +763,10 @@ | ||
| 583 | }) | 763 | }) |
| 584 | }) | 764 | }) |
| 585 | }, | 765 | }, |
| 586 | - // 保存并发送 | ||
| 587 | - handleSaveAndSend() { | ||
| 588 | - | ||
| 589 | - }, | ||
| 590 | // 重置实体 | 766 | // 重置实体 |
| 591 | restModel() { | 767 | restModel() { |
| 592 | this.loadingModel = { | 768 | this.loadingModel = { |
| 593 | - carrier:undefined, | 769 | + carrier: undefined, |
| 594 | flightno: undefined, | 770 | flightno: undefined, |
| 595 | flightdate: undefined, | 771 | flightdate: undefined, |
| 596 | originstation: undefined, | 772 | originstation: undefined, |
| @@ -639,6 +815,40 @@ | @@ -639,6 +815,40 @@ | ||
| 639 | } | 815 | } |
| 640 | }) | 816 | }) |
| 641 | }, | 817 | }, |
| 818 | + //获取机场三字码 | ||
| 819 | + remoteMethodAirport(query){ | ||
| 820 | + this.airportCode = [] | ||
| 821 | + if (query !== '') { | ||
| 822 | + this.listLoading = true | ||
| 823 | + getAirportCode({airportid: query}).then(res => { | ||
| 824 | + if(res !== null){ | ||
| 825 | + setTimeout(() => { | ||
| 826 | + this.listLoading = false | ||
| 827 | + this.airportCode = res.data.data | ||
| 828 | + }, 200) | ||
| 829 | + } | ||
| 830 | + }) | ||
| 831 | + } else { | ||
| 832 | + this.airportCode = [] | ||
| 833 | + } | ||
| 834 | + }, | ||
| 835 | + //关区代码 | ||
| 836 | + remoteMethodCustomCode(query){ | ||
| 837 | + this.customCodeList = [] | ||
| 838 | + if (query !== '') { | ||
| 839 | + this.customLoading = true | ||
| 840 | + getCustomCode({customcode: query}).then(res => { | ||
| 841 | + if(res !== null){ | ||
| 842 | + setTimeout(() => { | ||
| 843 | + this.customLoading = false | ||
| 844 | + this.customCodeList = res.data.data | ||
| 845 | + }, 200) | ||
| 846 | + } | ||
| 847 | + }) | ||
| 848 | + } else { | ||
| 849 | + this.airportCode = [] | ||
| 850 | + } | ||
| 851 | + }, | ||
| 642 | handleAddLoading() { | 852 | handleAddLoading() { |
| 643 | const row = { | 853 | const row = { |
| 644 | 'messageType': 'MT4201' | 854 | 'messageType': 'MT4201' |
| @@ -646,7 +856,8 @@ | @@ -646,7 +856,8 @@ | ||
| 646 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) | 856 | this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) |
| 647 | }, | 857 | }, |
| 648 | handelBackStep() { | 858 | handelBackStep() { |
| 649 | - this.$router.push({name: '出港航班信息', params: {scopeRow: this.loadingModel}}) | 859 | + this.loadingQuery.messageType = 'MT4201' |
| 860 | + this.$router.push({name: '出港航班信息', params: {scopeRow: this.loadingQuery}}) | ||
| 650 | } | 861 | } |
| 651 | } | 862 | } |
| 652 | } | 863 | } |
| @@ -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> |
| @@ -52,29 +52,35 @@ | @@ -52,29 +52,35 @@ | ||
| 52 | </el-row> | 52 | </el-row> |
| 53 | </div> | 53 | </div> |
| 54 | 54 | ||
| 55 | - <tree-table :data="preData" stripe style="font-size: 12px" :eval-func="func" :expand-all="true" border | ||
| 56 | - @selection-change="handleSelectionChange" v-loading="listLoading"> | ||
| 57 | - <el-table-column label="航班信息" width="90" align="center"> | ||
| 58 | - <template slot-scope="scope"> | ||
| 59 | - <p class="tableInline">{{scope.row.carrier}}{{scope.row.flightno}}</p> | ||
| 60 | - <p class="tableInline">{{scope.row.flightdate}}</p> | ||
| 61 | - <p class="tableInline">{{scope.row.originstation}}-{{scope.row.destinationstation}}</p> | ||
| 62 | - </template> | 55 | + <el-table :data="preData" stripe style="font-size: 12px" stripe |
| 56 | + @selection-change="handleSelectionChange" v-loading="listLoading" | ||
| 57 | + default-expand-all | ||
| 58 | + row-key="uuid" | ||
| 59 | + border | ||
| 60 | + :tree-props="{children: 'children', hasChildren: 'hasChildren'}"> | ||
| 61 | + <el-table-column type="selection" width="55"> | ||
| 63 | </el-table-column> | 62 | </el-table-column> |
| 64 | - <el-table-column label="运单号" width="120" align="center"> | 63 | +<!-- <el-table-column label="航班信息" width="90" align="center">--> |
| 64 | +<!-- <template slot-scope="scope">--> | ||
| 65 | +<!-- <p class="tableInline">{{scope.row.carrier}}{{scope.row.flightno}}</p>--> | ||
| 66 | +<!-- <p class="tableInline">{{scope.row.flightdate}}</p>--> | ||
| 67 | +<!-- <p class="tableInline">{{scope.row.originstation}}-{{scope.row.destinationstation}}</p>--> | ||
| 68 | +<!-- </template>--> | ||
| 69 | +<!-- </el-table-column>--> | ||
| 70 | + <el-table-column label="运单号" width="200" align="center"> | ||
| 65 | <template slot-scope="scope"> | 71 | <template slot-scope="scope"> |
| 66 | - <p class="tableInline">{{scope.row.awba}}</p> | ||
| 67 | - <p class="tableInline" v-if="scope.row.awbh !==null">{{scope.row.awbh}}</p> | 72 | + <span class="tableInline" v-if="scope.row.awbh !==''">{{scope.row.awbh}}</span> |
| 73 | + <span class="tableInline" v-else>{{scope.row.awba}}</span> | ||
| 68 | </template> | 74 | </template> |
| 69 | </el-table-column> | 75 | </el-table-column> |
| 70 | <el-table-column label="运单件数/重量" width="100" align="center"> | 76 | <el-table-column label="运单件数/重量" width="100" align="center"> |
| 71 | <template slot-scope="scope"> | 77 | <template slot-scope="scope"> |
| 72 | - {{scope.row.piece}} | 78 | + {{scope.row.awbinfo.pcs}}/{{scope.row.awbinfo.weight}} |
| 73 | </template> | 79 | </template> |
| 74 | </el-table-column> | 80 | </el-table-column> |
| 75 | <el-table-column label="预配件数/重量" width="100" align="center"> | 81 | <el-table-column label="预配件数/重量" width="100" align="center"> |
| 76 | <template slot-scope="scope"> | 82 | <template slot-scope="scope"> |
| 77 | - {{scope.row.weight}} | 83 | + {{scope.row.piece}}/{{scope.row.weight}} |
| 78 | </template> | 84 | </template> |
| 79 | </el-table-column> | 85 | </el-table-column> |
| 80 | <el-table-column label="货物描述" width="120" align="center"> | 86 | <el-table-column label="货物描述" width="120" align="center"> |
| @@ -87,67 +93,75 @@ | @@ -87,67 +93,75 @@ | ||
| 87 | {{scope.row.actime}} | 93 | {{scope.row.actime}} |
| 88 | </template> | 94 | </template> |
| 89 | </el-table-column> | 95 | </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> | 96 | + <!--<el-table-column label="代理人代码" width="120" align="center">--> |
| 97 | + <!--<template slot-scope="scope">--> | ||
| 98 | + <!--{{scope.row.status}}--> | ||
| 99 | + <!--</template>--> | ||
| 100 | + <!--</el-table-column>--> | ||
| 95 | <el-table-column label="状态" width="100" align="center"> | 101 | <el-table-column label="状态" width="100" align="center"> |
| 96 | <template slot-scope="scope"> | 102 | <template slot-scope="scope"> |
| 97 | - <span v-if="scope.row.status ==='01'">未发送</span> | ||
| 98 | - <span v-if="scope.row.status ==='02'">已发舱单报</span> | 103 | + <span v-if="scope.row.status ==='01'">接受申报</span> |
| 104 | + <span v-if="scope.row.status ==='02'">待人工审核</span> | ||
| 105 | + <span v-if="scope.row.status ==='03'">退单</span> | ||
| 99 | <span v-if="scope.row.status ==='05'">舱单报退单</span> | 106 | <span v-if="scope.row.status ==='05'">舱单报退单</span> |
| 100 | <span v-if="scope.row.status ==='06'">舱单转人工</span> | 107 | <span v-if="scope.row.status ==='06'">舱单转人工</span> |
| 101 | <span v-if="scope.row.status ==='07'">舱单报申报成功</span> | 108 | <span v-if="scope.row.status ==='07'">舱单报申报成功</span> |
| 102 | <span v-if="scope.row.status ==='08'">已发舱单删除报</span> | 109 | <span v-if="scope.row.status ==='08'">已发舱单删除报</span> |
| 103 | <span v-if="scope.row.status ==='09'">舱单删除报退单</span> | 110 | <span v-if="scope.row.status ==='09'">舱单删除报退单</span> |
| 104 | <span v-if="scope.row.status ==='10'">舱单删除报转人工</span> | 111 | <span v-if="scope.row.status ==='10'">舱单删除报转人工</span> |
| 105 | - <span v-if="scope.row.status ==='11'">舱单删除成功</span> | ||
| 106 | - <span v-if="scope.row.status ==='12'">已发舱单修改报</span> | ||
| 107 | - <span v-if="scope.row.status ==='13'">舱单修改报退单</span> | 112 | + <span v-if="scope.row.status ==='11'">放行</span> |
| 113 | + <span v-if="scope.row.status ==='12'">拒装</span> | ||
| 114 | + <span v-if="scope.row.status ==='13'">禁卸</span> | ||
| 108 | <span v-if="scope.row.status ==='14'">舱单修改报转人工</span> | 115 | <span v-if="scope.row.status ==='14'">舱单修改报转人工</span> |
| 109 | <span v-if="scope.row.status ==='15'">舱单修改报成功</span> | 116 | <span v-if="scope.row.status ==='15'">舱单修改报成功</span> |
| 110 | <span v-if="scope.row.status ==='16'">海关已存在</span> | 117 | <span v-if="scope.row.status ==='16'">海关已存在</span> |
| 118 | + <span v-if="scope.row.status ==='21'">可自动发送</span> | ||
| 119 | + <span v-if="scope.row.status ==='22'">未发送</span> | ||
| 120 | + <span v-if="scope.row.status ==='23'">已发送新增报</span> | ||
| 121 | + <span v-if="scope.row.status ==='24'">已发送删除报</span> | ||
| 122 | + <span v-if="scope.row.status ==='25'">已发送修改报</span> | ||
| 111 | </template> | 123 | </template> |
| 112 | </el-table-column> | 124 | </el-table-column> |
| 113 | <el-table-column prop="receipt" label="回执信息" align="center"> | 125 | <el-table-column prop="receipt" label="回执信息" align="center"> |
| 114 | <template slot-scope="scope"> | 126 | <template slot-scope="scope"> |
| 115 | {{scope.row.ext5}} | 127 | {{scope.row.ext5}} |
| 116 | - <el-button size="mini" @click="handleSend(scope.row)">收发明细</el-button> | ||
| 117 | </template> | 128 | </template> |
| 118 | </el-table-column> | 129 | </el-table-column> |
| 119 | - <el-table-column label="操作" width="300"> | 130 | + <el-table-column label="操作" width="450" fixed="right"> |
| 120 | <template slot-scope="scope"> | 131 | <template slot-scope="scope"> |
| 121 | - <el-button size="mini" type="success" @click="handleEdit(scope.row)">编辑运单</el-button> | ||
| 122 | - <el-button size="mini" type="success" v-if="scope.row.awbh ===null" | 132 | + <el-button size="mini" @click="handleSend(scope.row)">收发明细</el-button> |
| 133 | + <el-button size="mini" type="success" @click="handleEdit(scope.row)" >编辑</el-button> | ||
| 134 | + <el-button size="mini" type="success" v-if="scope.row.awbh ===''" | ||
| 123 | @click="handleAddAwbh(scope.row)">新增分单 | 135 | @click="handleAddAwbh(scope.row)">新增分单 |
| 124 | </el-button> | 136 | </el-button> |
| 125 | <el-button size="mini" type="primary" @click="handleAwbSend(scope.row)" | 137 | <el-button size="mini" type="primary" @click="handleAwbSend(scope.row)" |
| 126 | - :disabled="scope.row.status !== '01'">发舱单报 | 138 | + :disabled="addStatus(scope.row.status)">发送预配舱单报 |
| 127 | </el-button> | 139 | </el-button> |
| 128 | <p></p> | 140 | <p></p> |
| 129 | - <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> | 141 | + <el-button size="mini" type="primary" @click="handleAwbEdit(scope.row)" |
| 142 | + :disabled="editStatus(scope.row.status)">发送预配修改报</el-button> | ||
| 143 | +<!-- <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单</el-button>--> | ||
| 132 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" | 144 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" |
| 133 | - :disabled="scope.row.status === '01'">更改状态 | 145 | + :disabled="scope.row.status === '22'">更改状态 |
| 134 | </el-button> | 146 | </el-button> |
| 147 | + <el-button size="mini" type="danger" @click="handleSendDelete(scope.row)" | ||
| 148 | + :disabled="deleteStatus(scope.row.status)">发送预配删除报</el-button> | ||
| 135 | </template> | 149 | </template> |
| 136 | </el-table-column> | 150 | </el-table-column> |
| 137 | - </tree-table> | 151 | + </el-table> |
| 138 | <div class="btnFoot"> | 152 | <div class="btnFoot"> |
| 139 | <el-row> | 153 | <el-row> |
| 140 | - <el-button type="primary" size="mini" v-if="preData.flightno !== undefined || preData.length> 0" | 154 | + <el-button type="primary" size="mini" v-if="preQuery.flightno !== undefined | preData.length > 0" |
| 141 | @click="handleAddpreInfo">新增预配舱单 | 155 | @click="handleAddpreInfo">新增预配舱单 |
| 142 | </el-button> | 156 | </el-button> |
| 143 | <el-button type="primary" size="mini" @click="handelBackStep" | 157 | <el-button type="primary" size="mini" @click="handelBackStep" |
| 144 | - v-if="preModel.flightno !== undefined || preData.length >0">返回 | 158 | + v-if="preQuery.flightno !== undefined || preData.length >0">返回 |
| 145 | </el-button> | 159 | </el-button> |
| 146 | </el-row> | 160 | </el-row> |
| 147 | </div> | 161 | </div> |
| 148 | - <pagination v-show="total>0" :total="total" :page.sync="listQuery.pageSize" :limit.sync="listQuery.limitSize" | 162 | + <pagination v-show="total>0" :total="total" :page.sync="preQuery.pageSize" :limit.sync="preQuery.limitSize" |
| 149 | @pagination="getList"/> | 163 | @pagination="getList"/> |
| 150 | - <el-dialog :title="dialogMap[dialogStatus]" :visible.sync="dialogFormVisible" width="60%"> | 164 | + <el-dialog :title="dialogMap[dialogStatus]" :visible.sync="dialogFormVisible" width="85%"> |
| 151 | <el-form ref="preFormData" :model="preModel" :rules="preRoles" label-position="right" | 165 | <el-form ref="preFormData" :model="preModel" :rules="preRoles" label-position="right" |
| 152 | label-width="120px" class="el-dialog-div"> | 166 | label-width="120px" class="el-dialog-div"> |
| 153 | <div class="grid-content content"> | 167 | <div class="grid-content content"> |
| @@ -159,7 +173,7 @@ | @@ -159,7 +173,7 @@ | ||
| 159 | <el-input :disabled="dialogStatus !== 'create'" v-model="awba" clearable/> | 173 | <el-input :disabled="dialogStatus !== 'create'" v-model="awba" clearable/> |
| 160 | </el-form-item> | 174 | </el-form-item> |
| 161 | </el-col> | 175 | </el-col> |
| 162 | - <el-col :span="7.5" v-if="dialogStatus === 'addAwbh'"> | 176 | + <el-col :span="7.5" v-if="fenStatus === 'addAwbh'"> |
| 163 | <el-form-item label="分单号" prop="awbh"> | 177 | <el-form-item label="分单号" prop="awbh"> |
| 164 | <el-input v-model="awbh" clearable/> | 178 | <el-input v-model="awbh" clearable/> |
| 165 | </el-form-item> | 179 | </el-form-item> |
| @@ -171,17 +185,17 @@ | @@ -171,17 +185,17 @@ | ||
| 171 | <el-row> | 185 | <el-row> |
| 172 | <el-col :span="7.5"> | 186 | <el-col :span="7.5"> |
| 173 | <el-form-item label="承运人" prop="carrier"> | 187 | <el-form-item label="承运人" prop="carrier"> |
| 174 | - <el-input v-model="carrier" :disabled="dialogStatus === 'addAwbh'" clearable/> | 188 | + <el-input v-model="carrier" :disabled="fenStatus === 'addAwbh'" clearable/> |
| 175 | </el-form-item> | 189 | </el-form-item> |
| 176 | </el-col> | 190 | </el-col> |
| 177 | <el-col :span="7.5"> | 191 | <el-col :span="7.5"> |
| 178 | <el-form-item label="航班号" prop="flightno"> | 192 | <el-form-item label="航班号" prop="flightno"> |
| 179 | - <el-input v-model="flightno" :disabled="dialogStatus === 'addAwbh'" clearable/> | 193 | + <el-input v-model="flightno" :disabled="fenStatus === 'addAwbh'" clearable/> |
| 180 | </el-form-item> | 194 | </el-form-item> |
| 181 | </el-col> | 195 | </el-col> |
| 182 | <el-col :span="7.5"> | 196 | <el-col :span="7.5"> |
| 183 | <el-form-item label="航班日期" prop="flightdate"> | 197 | <el-form-item label="航班日期" prop="flightdate"> |
| 184 | - <el-date-picker :disabled="dialogStatus === 'addAwbh'" | 198 | + <el-date-picker :disabled="fenStatus === 'addAwbh'" |
| 185 | value-format="yyyy-MM-dd" | 199 | value-format="yyyy-MM-dd" |
| 186 | v-model="preModel.flightdate" align="right" | 200 | v-model="preModel.flightdate" align="right" |
| 187 | type="date" placeholder="请输入航班日期" clearable/> | 201 | type="date" placeholder="请输入航班日期" clearable/> |
| @@ -192,12 +206,34 @@ | @@ -192,12 +206,34 @@ | ||
| 192 | <el-row> | 206 | <el-row> |
| 193 | <el-col :span="7.5"> | 207 | <el-col :span="7.5"> |
| 194 | <el-form-item label="起始站" prop="originstation"> | 208 | <el-form-item label="起始站" prop="originstation"> |
| 195 | - <el-input v-model="originstation" :disabled="dialogStatus === 'addAwbh'" clearable/> | 209 | + <el-select |
| 210 | + filterable | ||
| 211 | + clearable | ||
| 212 | + placeholder="请选择起始站" | ||
| 213 | + :remote-method="remoteMethodAirport" | ||
| 214 | + allow-create remote | ||
| 215 | + v-model="originstation" | ||
| 216 | + :loading="airportLoading"> | ||
| 217 | + <el-option v-for="item in airportCode" | ||
| 218 | + :key="item.airportid" :label="item.airportid" | ||
| 219 | + :value="item.airportid" :disabled="fenStatus === 'addAwbh'"> | ||
| 220 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 221 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 222 | + </el-option> | ||
| 223 | + </el-select> | ||
| 196 | </el-form-item> | 224 | </el-form-item> |
| 197 | </el-col> | 225 | </el-col> |
| 198 | <el-col :span="7.5"> | 226 | <el-col :span="7.5"> |
| 199 | <el-form-item label="目的站" prop="destinationstation"> | 227 | <el-form-item label="目的站" prop="destinationstation"> |
| 200 | - <el-input v-model="destinationstation" :disabled="dialogStatus === 'addAwbh'" clearable/> | 228 | + <el-select filterable clearable placeholder="请选择目的站" allow-create remote |
| 229 | + v-model="destinationstation" :remote-method="remoteMethodAirport"> | ||
| 230 | + <el-option v-for="item in airportCode" | ||
| 231 | + :key="item.airportid" :label="item.airportid" | ||
| 232 | + :value="item.airportid" :disabled="fenStatus === 'addAwbh'" > | ||
| 233 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 234 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 235 | + </el-option> | ||
| 236 | + </el-select> | ||
| 201 | </el-form-item> | 237 | </el-form-item> |
| 202 | </el-col> | 238 | </el-col> |
| 203 | </el-row> | 239 | </el-row> |
| @@ -264,13 +300,13 @@ | @@ -264,13 +300,13 @@ | ||
| 264 | </el-col> | 300 | </el-col> |
| 265 | </el-row> | 301 | </el-row> |
| 266 | <el-row> | 302 | <el-row> |
| 267 | - <el-col :span="7.5" v-if="dialogStatus !=='addAwbh'"> | 303 | + <el-col :span="7.5" v-if="fenStatus !=='addAwbh'"> |
| 268 | <el-form-item label="预配件数" prop="piece"> | 304 | <el-form-item label="预配件数" prop="piece"> |
| 269 | <el-input v-model="preModel.piece" clearable/> | 305 | <el-input v-model="preModel.piece" clearable/> |
| 270 | </el-form-item> | 306 | </el-form-item> |
| 271 | </el-col> | 307 | </el-col> |
| 272 | - <el-col :span="8" v-if="dialogStatus ==='addAwbh'"> | ||
| 273 | - <el-col :span="13"> | 308 | + <el-col :span="8" v-if="fenStatus ==='addAwbh'"> |
| 309 | + <el-col :span="14"> | ||
| 274 | <el-form-item label="预配件数" prop="piece"> | 310 | <el-form-item label="预配件数" prop="piece"> |
| 275 | <el-input v-model="preModel.piece" clearable/> | 311 | <el-input v-model="preModel.piece" clearable/> |
| 276 | </el-form-item> | 312 | </el-form-item> |
| @@ -279,13 +315,14 @@ | @@ -279,13 +315,14 @@ | ||
| 279 | <span>剩余件数:{{awbPiece}}</span> | 315 | <span>剩余件数:{{awbPiece}}</span> |
| 280 | </el-col> | 316 | </el-col> |
| 281 | </el-col> | 317 | </el-col> |
| 282 | - <el-col :span="7.5" v-if="dialogStatus !=='addAwbh'"> | 318 | + |
| 319 | + <el-col :span="7.5" v-if="fenStatus !=='addAwbh'"> | ||
| 283 | <el-form-item label="预配重量" prop="weight"> | 320 | <el-form-item label="预配重量" prop="weight"> |
| 284 | <el-input v-model="preModel.weight" clearable/> | 321 | <el-input v-model="preModel.weight" clearable/> |
| 285 | </el-form-item> | 322 | </el-form-item> |
| 286 | </el-col> | 323 | </el-col> |
| 287 | - <el-col :span="8" v-if="dialogStatus ==='addAwbh'"> | ||
| 288 | - <el-col :span="13"> | 324 | + <el-col :span="8" v-if="fenStatus ==='addAwbh'"> |
| 325 | + <el-col :span="14"> | ||
| 289 | <el-form-item label="预配重量" prop="weight"> | 326 | <el-form-item label="预配重量" prop="weight"> |
| 290 | <el-input v-model="preModel.weight" clearable/> | 327 | <el-input v-model="preModel.weight" clearable/> |
| 291 | </el-form-item> | 328 | </el-form-item> |
| @@ -306,24 +343,28 @@ | @@ -306,24 +343,28 @@ | ||
| 306 | <el-row> | 343 | <el-row> |
| 307 | <el-col :span="7.5"> | 344 | <el-col :span="7.5"> |
| 308 | <el-form-item label="关区代码" prop="customcode"> | 345 | <el-form-item label="关区代码" prop="customcode"> |
| 309 | - <el-select v-model="preModel.customcode" class="filter-item" placeholder="请选择关区代码" | ||
| 310 | - :disabled="dialogStatus === 'addAwbh'"> | ||
| 311 | - <el-option v-for="item in customcodeList" :key="item.value" :label="item.label" | ||
| 312 | - :value="item.value"></el-option> | 346 | + <el-select v-model="preModel.customcode" placeholder="请选择关区代码" |
| 347 | + filterable clearable :remote-method="remoteMethodCustomCode" :loading="customLoading" remote | ||
| 348 | + :disabled="fenStatus === 'addAwbh'"> | ||
| 349 | + <el-option v-for="item in customCodeList" :key="item.customcode" :label="item.customcode" | ||
| 350 | + :value="item.customcode"> | ||
| 351 | + <span style="float: left">{{ item.customcode }}</span> | ||
| 352 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.customname }}</span> | ||
| 353 | + </el-option> | ||
| 313 | </el-select> | 354 | </el-select> |
| 314 | </el-form-item> | 355 | </el-form-item> |
| 315 | </el-col> | 356 | </el-col> |
| 316 | <el-col :span="7.5"> | 357 | <el-col :span="7.5"> |
| 317 | <el-form-item label="海关状态"> | 358 | <el-form-item label="海关状态"> |
| 318 | - <el-select v-model="preModel.awbtype" class="filter-item" placeholder="请录入货物类型"> | 359 | + <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" | 360 | <el-option v-for="item in customTypes" :key="item.value" :label="item.label" |
| 320 | :value="item.value"/> | 361 | :value="item.value"/> |
| 321 | </el-select> | 362 | </el-select> |
| 322 | </el-form-item> | 363 | </el-form-item> |
| 323 | </el-col> | 364 | </el-col> |
| 324 | <el-col :span="7.5"> | 365 | <el-col :span="7.5"> |
| 325 | - <el-form-item label="付费方式" prop="awbinfo.collected"> | ||
| 326 | - <el-select v-model="preModel.awbinfo.collected" class="filter-item" placeholder="付费方式"> | 366 | + <el-form-item label="付费方式" prop="awbinfo.paymodel"> |
| 367 | + <el-select v-model="preModel.awbinfo.paymodel" class="filter-item" placeholder="付费方式"> | ||
| 327 | <el-option | 368 | <el-option |
| 328 | v-for="item in payTypes" | 369 | v-for="item in payTypes" |
| 329 | :key="item.value" | 370 | :key="item.value" |
| @@ -399,8 +440,9 @@ | @@ -399,8 +440,9 @@ | ||
| 399 | :loading="listLoading" | 440 | :loading="listLoading" |
| 400 | v-model="shprcountyr" | 441 | v-model="shprcountyr" |
| 401 | filterable | 442 | filterable |
| 443 | + allow-create | ||
| 402 | remote | 444 | remote |
| 403 | - placeholder="请选择" clearable> | 445 | + placeholder="请选择" clearable>目的站 |
| 404 | <el-option | 446 | <el-option |
| 405 | v-for="item in countryOption" | 447 | v-for="item in countryOption" |
| 406 | :key="item.value" | 448 | :key="item.value" |
| @@ -477,6 +519,7 @@ | @@ -477,6 +519,7 @@ | ||
| 477 | :listLoading="listLoading" | 519 | :listLoading="listLoading" |
| 478 | v-model="cnscountyr" | 520 | v-model="cnscountyr" |
| 479 | filterable | 521 | filterable |
| 522 | + allow-create | ||
| 480 | remote | 523 | remote |
| 481 | placeholder="请选择" clearable> | 524 | placeholder="请选择" clearable> |
| 482 | <el-option | 525 | <el-option |
| @@ -520,16 +563,40 @@ | @@ -520,16 +563,40 @@ | ||
| 520 | <!--</el-form-item>--> | 563 | <!--</el-form-item>--> |
| 521 | <!--</el-col>--> | 564 | <!--</el-col>--> |
| 522 | </el-row> | 565 | </el-row> |
| 566 | + <div v-if="dialogStatus === 'sendUpdate'"> | ||
| 567 | + <div class="grid-content content"> | ||
| 568 | + 运单信息 | ||
| 569 | + </div> | ||
| 570 | + <el-row> | ||
| 571 | + <el-col :span="7.5"> | ||
| 572 | + <el-form-item label="修改原因" prop="reason"> | ||
| 573 | + <el-input v-model="preModel.reason" clearable/> | ||
| 574 | + </el-form-item> | ||
| 575 | + </el-col> | ||
| 576 | + <el-col :span="7.5"> | ||
| 577 | + <el-form-item label="修改人" prop="contactName"> | ||
| 578 | + <el-input v-model="preModel.contactName" clearable/> | ||
| 579 | + </el-form-item> | ||
| 580 | + </el-col> | ||
| 581 | + <el-col :span="7.5"> | ||
| 582 | + <el-form-item label="修改人Tel" prop="contactTel"> | ||
| 583 | + <el-input v-model="preModel.contactTel" clearable maxlength="5"/> | ||
| 584 | + </el-form-item> | ||
| 585 | + </el-col> | ||
| 586 | + </el-row> | ||
| 587 | + </div> | ||
| 588 | + | ||
| 523 | </el-form> | 589 | </el-form> |
| 524 | <div slot="footer" class="dialog-footer"> | 590 | <div slot="footer" class="dialog-footer"> |
| 525 | <el-button @click="dialogFormVisible = false">取消</el-button> | 591 | <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> | 592 | + <el-button type="primary" v-show="dialogStatus!=='sendUpdate'" |
| 593 | + @click="dialogStatus ==='create'? createData():updateData()">保存</el-button> | ||
| 594 | + <el-button type="primary" v-show="dialogStatus==='sendUpdate'" @click="sendUpdate()">发送</el-button> | ||
| 528 | </div> | 595 | </div> |
| 529 | </el-dialog> | 596 | </el-dialog> |
| 530 | <el-dialog title="收发明细" :visible.sync="dialogTableVisible"> | 597 | <el-dialog title="收发明细" :visible.sync="dialogTableVisible"> |
| 531 | <el-table :data="detailData" border> | 598 | <el-table :data="detailData" border> |
| 532 | - <el-table-column label="操作时间" width="150"> | 599 | + <el-table-column label="操作时间" width="180"> |
| 533 | <template slot-scope="scope"> | 600 | <template slot-scope="scope"> |
| 534 | {{scope.row.busdate}} | 601 | {{scope.row.busdate}} |
| 535 | </template> | 602 | </template> |
| @@ -559,6 +626,11 @@ | @@ -559,6 +626,11 @@ | ||
| 559 | {{scope.row.cusrestext}} | 626 | {{scope.row.cusrestext}} |
| 560 | </template> | 627 | </template> |
| 561 | </el-table-column> | 628 | </el-table-column> |
| 629 | + <el-table-column label="操作类型" width="100"> | ||
| 630 | + <template slot-scope="scope"> | ||
| 631 | + {{scope.row.opertype}} | ||
| 632 | + </template> | ||
| 633 | + </el-table-column> | ||
| 562 | <el-table-column label="操作人" width="100"> | 634 | <el-table-column label="操作人" width="100"> |
| 563 | <template slot-scope="scope"> | 635 | <template slot-scope="scope"> |
| 564 | {{scope.row.operusername}} | 636 | {{scope.row.operusername}} |
| @@ -566,15 +638,45 @@ | @@ -566,15 +638,45 @@ | ||
| 566 | </el-table-column> | 638 | </el-table-column> |
| 567 | </el-table> | 639 | </el-table> |
| 568 | </el-dialog> | 640 | </el-dialog> |
| 641 | + <el-dialog title="删除原因" :visible.sync="dialogDeleteVisble" width="30%"> | ||
| 642 | + <el-form ref="sendDeleteForm" :model="respModel" :rules="sendDeleteRules" label-width="120px" | ||
| 643 | + style="margin-right:50px;"> | ||
| 644 | + <el-form-item label="删除原因" prop="reason"> | ||
| 645 | + <el-input v-model="respModel.reason" placeholder="删除原因"></el-input> | ||
| 646 | + </el-form-item> | ||
| 647 | + <el-form-item label="删除操作人" prop="contactName"> | ||
| 648 | + <el-input v-model="respModel.contactName" placeholder="操作人姓名"></el-input> | ||
| 649 | + </el-form-item> | ||
| 650 | + <el-form-item label="操作人Tel" prop="contactTel"> | ||
| 651 | + <el-input v-model="respModel.contactTel" placeholder="删除操作人联系方式"></el-input> | ||
| 652 | + </el-form-item> | ||
| 653 | + <el-form-item label="备注"> | ||
| 654 | + <el-input v-model="respModel.content" type="textarea"></el-input> | ||
| 655 | + </el-form-item> | ||
| 656 | + </el-form> | ||
| 657 | + <div slot="footer" class="dialog-footer"> | ||
| 658 | + <el-button @click="dialogDeleteVisble = false">取消</el-button> | ||
| 659 | + <el-button type="primary" @click="sendDelete()">发送</el-button> | ||
| 660 | + </div> | ||
| 661 | + </el-dialog> | ||
| 569 | </div> | 662 | </div> |
| 570 | </template> | 663 | </template> |
| 571 | <script> | 664 | <script> |
| 572 | import treeTable from '@/components/TreeTable' | 665 | import treeTable from '@/components/TreeTable' |
| 573 | import treeToArray from '@/utils/customEval' | 666 | import treeToArray from '@/utils/customEval' |
| 574 | import Pagination from '@/components/Pagination' | 667 | import Pagination from '@/components/Pagination' |
| 575 | - | ||
| 576 | - import {getCountry, getByCountryCode, getByCountryCodeForName} from "@/api/country"; | ||
| 577 | - import {getMt2201ListForParam, deleteByIsDelete, updateStatus, updateMT2201, addMt2201} from '@/api/exitPre' | 668 | + import util from '@/common/js/util' |
| 669 | + import {getCountry, getByCountryCode, getByCountryCodeForName,getCustomCode,getAirportCode} from "@/api/country"; | ||
| 670 | + import { | ||
| 671 | + getMt2201ListForParam, | ||
| 672 | + deleteByIsDelete, | ||
| 673 | + updateStatus, | ||
| 674 | + updateMT2201, | ||
| 675 | + addMt2201, | ||
| 676 | + sendCreateMt2201, | ||
| 677 | + sendDeleteMt2201, | ||
| 678 | + sendUpdateMt2201 | ||
| 679 | + } from '@/api/exitPre' | ||
| 578 | import {Message} from "element-ui"; | 680 | import {Message} from "element-ui"; |
| 579 | import {getResponseForParam} from '@/api/responseDetail' | 681 | import {getResponseForParam} from '@/api/responseDetail' |
| 580 | import { | 682 | import { |
| @@ -623,16 +725,17 @@ | @@ -623,16 +725,17 @@ | ||
| 623 | return { | 725 | return { |
| 624 | func: treeToArray, | 726 | func: treeToArray, |
| 625 | total: 1, | 727 | total: 1, |
| 626 | - isAdmin:false, | ||
| 627 | - listQuery: { | 728 | + isAdmin: false, |
| 729 | + preQuery: { | ||
| 628 | pageSize: 1, | 730 | pageSize: 1, |
| 629 | limitSize: 100, | 731 | limitSize: 100, |
| 630 | awba: undefined, | 732 | awba: undefined, |
| 631 | carrier: undefined, | 733 | carrier: undefined, |
| 632 | - flightNo: undefined, | ||
| 633 | - flightDate: undefined, | ||
| 634 | - originStation: undefined, | ||
| 635 | - destinationStation: undefined | 734 | + flightno: undefined, |
| 735 | + flightdate: undefined, | ||
| 736 | + originstation: undefined, | ||
| 737 | + destinationstation: undefined, | ||
| 738 | + messageType: undefined | ||
| 636 | }, | 739 | }, |
| 637 | dialogMap: { | 740 | dialogMap: { |
| 638 | update: '编辑预配舱单', | 741 | update: '编辑预配舱单', |
| @@ -647,10 +750,15 @@ | @@ -647,10 +750,15 @@ | ||
| 647 | {label: '快件', value: '005'}], | 750 | {label: '快件', value: '005'}], |
| 648 | payTypes: [{label: '预付', value: '0'}, {label: '到付', value: '1'}], | 751 | payTypes: [{label: '预付', value: '0'}, {label: '到付', value: '1'}], |
| 649 | splitcodes: [{label: '是', value: 'T'}, {label: '否', value: 'P'}], | 752 | splitcodes: [{label: '是', value: 'T'}, {label: '否', value: 'P'}], |
| 650 | - customcodeList: [{label: '4604', value: '4604'}, {label: '4620', value: '4620'}], | 753 | + customCodeList: [], |
| 754 | + airportCode:[], | ||
| 651 | dialogStatus: undefined, | 755 | dialogStatus: undefined, |
| 756 | + fenStatus:undefined, | ||
| 652 | dialogTableVisible: false, | 757 | dialogTableVisible: false, |
| 758 | + dialogDeleteVisble: false, | ||
| 653 | listLoading: false, | 759 | listLoading: false, |
| 760 | + customLoading:false, | ||
| 761 | + airportLoading:false, | ||
| 654 | disabledStatus: false, | 762 | disabledStatus: false, |
| 655 | dialogFormVisible: false, | 763 | dialogFormVisible: false, |
| 656 | countryOption: [], | 764 | countryOption: [], |
| @@ -670,9 +778,12 @@ | @@ -670,9 +778,12 @@ | ||
| 670 | customcode: [{required: true, message: '关区代码必须选择', trigger: 'change'}], | 778 | customcode: [{required: true, message: '关区代码必须选择', trigger: 'change'}], |
| 671 | awba: [{required: true, trigger: 'blur', validator: validatorAwb}], | 779 | awba: [{required: true, trigger: 'blur', validator: validatorAwb}], |
| 672 | awbh: [{required: true, trigger: 'blur', validator: validatorAwbh}], | 780 | awbh: [{required: true, trigger: 'blur', validator: validatorAwbh}], |
| 673 | - 'awbinfo.collected': [{required: true, message: '付款方式必选', trigger: 'change'}], | 781 | + 'awbinfo.paymodel': [{required: true, message: '付款方式必选', trigger: 'change'}], |
| 674 | goodsname: [{required: true, trigger: 'change', validator: validAlphabetsSpanceKey}], | 782 | goodsname: [{required: true, trigger: 'change', validator: validAlphabetsSpanceKey}], |
| 675 | ex5: [{required: true, message: '货物描述不能为空', trigger: 'blur'}], | 783 | ex5: [{required: true, message: '货物描述不能为空', trigger: 'blur'}], |
| 784 | + reason:[{required: true, message: '修改原因不能为空', trigger: 'blur'}], | ||
| 785 | + contactName:[{required: true, message: '修改操作人不能为空', trigger: 'blur'}], | ||
| 786 | + contactTel:[{required: true, message: '修改操作人联系方式不能为空', trigger: 'blur'}], | ||
| 676 | 'awbinfo.sairportid': [{required: true, message: '起始航站不能为空', trigger: 'change'}], | 787 | 'awbinfo.sairportid': [{required: true, message: '起始航站不能为空', trigger: 'change'}], |
| 677 | 'awbinfo.shprname': [{required: true, message: '发货人不能为空', trigger: 'change'}], | 788 | 'awbinfo.shprname': [{required: true, message: '发货人不能为空', trigger: 'change'}], |
| 678 | 'awbinfo.shprtel': [{required: true, message: '发货电话不能为空', trigger: 'change'}], | 789 | 'awbinfo.shprtel': [{required: true, message: '发货电话不能为空', trigger: 'change'}], |
| @@ -686,6 +797,7 @@ | @@ -686,6 +797,7 @@ | ||
| 686 | 'awbinfo.pcs': [{required: true, trigger: 'change', validator: validatorNums}], | 797 | 'awbinfo.pcs': [{required: true, trigger: 'change', validator: validatorNums}], |
| 687 | }, | 798 | }, |
| 688 | preModel: { | 799 | preModel: { |
| 800 | + uuid: undefined, | ||
| 689 | awba: undefined, | 801 | awba: undefined, |
| 690 | awbh: undefined, | 802 | awbh: undefined, |
| 691 | customcode: undefined, | 803 | customcode: undefined, |
| @@ -703,6 +815,9 @@ | @@ -703,6 +815,9 @@ | ||
| 703 | uldNo: undefined, | 815 | uldNo: undefined, |
| 704 | status: undefined, | 816 | status: undefined, |
| 705 | ex5: undefined, | 817 | ex5: undefined, |
| 818 | + reason: undefined, | ||
| 819 | + contactName: undefined, | ||
| 820 | + contactTel: undefined, | ||
| 706 | awbinfo: { | 821 | awbinfo: { |
| 707 | pcs: undefined, | 822 | pcs: undefined, |
| 708 | weight: undefined, | 823 | weight: undefined, |
| @@ -731,7 +846,7 @@ | @@ -731,7 +846,7 @@ | ||
| 731 | cargonm: undefined, | 846 | cargonm: undefined, |
| 732 | sairportid: undefined, | 847 | sairportid: undefined, |
| 733 | dest1city: undefined, | 848 | dest1city: undefined, |
| 734 | - by1: undefined, | 849 | + by1: '', |
| 735 | dest1: undefined, | 850 | dest1: undefined, |
| 736 | by2: undefined, | 851 | by2: undefined, |
| 737 | dest2: undefined, | 852 | dest2: undefined, |
| @@ -739,12 +854,30 @@ | @@ -739,12 +854,30 @@ | ||
| 739 | dest3: undefined, | 854 | dest3: undefined, |
| 740 | eairportid: undefined, | 855 | eairportid: undefined, |
| 741 | csgcustomerid: undefined, | 856 | csgcustomerid: undefined, |
| 742 | - collected: '0', | 857 | + paymodel: '0', |
| 743 | awbtype: undefined | 858 | awbtype: undefined |
| 744 | } | 859 | } |
| 745 | }, | 860 | }, |
| 861 | + respModel: { | ||
| 862 | + uuid: undefined, | ||
| 863 | + reason: undefined, | ||
| 864 | + contactName: undefined, | ||
| 865 | + contactTel: undefined, | ||
| 866 | + content: '', | ||
| 867 | + flightNo: undefined, | ||
| 868 | + awba: undefined, | ||
| 869 | + customCode: undefined, | ||
| 870 | + flightDate: undefined, | ||
| 871 | + awbh: '' | ||
| 872 | + }, | ||
| 873 | + sendDeleteRules:{ | ||
| 874 | + reason:[{required:true,message:'删除原因不能为空',trigger:'blur'}], | ||
| 875 | + contactName:[{required:true,message:'删除操作人不能为空',trigger:'blur'}], | ||
| 876 | + contactTel:[{required:true,message:'操作人联系方式不能为空',trigger:'blur'}] | ||
| 877 | + }, | ||
| 746 | preData: [], | 878 | preData: [], |
| 747 | - detailData: [] | 879 | + detailData: [], |
| 880 | + rows:[] | ||
| 748 | } | 881 | } |
| 749 | }, | 882 | }, |
| 750 | mounted() { | 883 | mounted() { |
| @@ -757,20 +890,24 @@ | @@ -757,20 +890,24 @@ | ||
| 757 | }, | 890 | }, |
| 758 | created() { | 891 | created() { |
| 759 | if (this.$route.params.flightData !== undefined) { | 892 | 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 | 893 | + this.preQuery.carrier = this.$route.params.flightData.flightno.substring(0, 2) |
| 894 | + this.preQuery.flightno = this.$route.params.flightData.flightno.substring(2) | ||
| 895 | + this.preQuery.flightdate = this.$route.params.flightData.flightdate | ||
| 896 | + this.preQuery.originstation = this.$route.params.flightData.originstation | ||
| 897 | + this.preQuery.destinationstation = this.$route.params.flightData.destinationstation | ||
| 898 | + if (this.$route.params.flightData.awba !== undefined && this.$route.params.flightData.awba !== '') { | ||
| 899 | + this.preQuery.awba = this.$route.params.flightData.awba.substring(0, 3) + "-" + this.$route.params.flightData.awba.substring(3) | ||
| 900 | + } | ||
| 766 | this.getList() | 901 | this.getList() |
| 767 | } | 902 | } |
| 768 | this.getCountryList() | 903 | this.getCountryList() |
| 769 | let username = JSON.parse(sessionStorage.getItem('user')).username | 904 | let username = JSON.parse(sessionStorage.getItem('user')).username |
| 770 | - if(username === 'admin'){ | 905 | + if (username === 'admin') { |
| 771 | this.isAdmin = true | 906 | this.isAdmin = true |
| 772 | } | 907 | } |
| 773 | }, | 908 | }, |
| 909 | + | ||
| 910 | + // 验证 | ||
| 774 | computed: { | 911 | computed: { |
| 775 | awba: { | 912 | awba: { |
| 776 | get: function () { | 913 | get: function () { |
| @@ -930,10 +1067,10 @@ | @@ -930,10 +1067,10 @@ | ||
| 930 | }, | 1067 | }, |
| 931 | by1: { | 1068 | by1: { |
| 932 | get: function () { | 1069 | get: function () { |
| 933 | - return this.preModel.awbinfo.by1 | 1070 | + return util.checkNull(this.preModel.awbinfo.by1)?this.preModel.awbinfo.by1:'' |
| 934 | }, | 1071 | }, |
| 935 | set: function (val) { | 1072 | set: function (val) { |
| 936 | - this.preModel.awbinfo.by1 = val.toUpperCase().trim() | 1073 | + this.preModel.awbinfo.by1 = util.checkNull(val)?val.toUpperCase().trim():'' |
| 937 | } | 1074 | } |
| 938 | }, | 1075 | }, |
| 939 | dest1: { | 1076 | dest1: { |
| @@ -981,24 +1118,26 @@ | @@ -981,24 +1118,26 @@ | ||
| 981 | // >>>>>>>>>>>>>>>>获取list集合<<<<<<<<<<<<<<<<<< | 1118 | // >>>>>>>>>>>>>>>>获取list集合<<<<<<<<<<<<<<<<<< |
| 982 | getList() { | 1119 | getList() { |
| 983 | this.listLoading = true | 1120 | this.listLoading = true |
| 984 | - if (this.listQuery.awba !== undefined && this.listQuery.awba !== '') { | ||
| 985 | - getMt2201ListForParam(this.listQuery).then(res => { | 1121 | + if (this.preQuery.awba !== undefined && this.preQuery.awba !== '') { |
| 1122 | + getMt2201ListForParam(this.preQuery).then(res => { | ||
| 986 | this.preData = res.data.dataList | 1123 | this.preData = res.data.dataList |
| 987 | this.total = res.data.count | 1124 | this.total = res.data.count |
| 988 | - 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 | 1125 | + console.log("主单号不为空时打印") |
| 1126 | + console.log(res.data) | ||
| 1127 | + if (res.data.dataList.length > 0) { | ||
| 1128 | + this.preQuery.carrier = this.preData[0].carrier | ||
| 1129 | + this.preQuery.flightno = this.preData[0].flightno | ||
| 1130 | + this.preQuery.flightdate = this.preData[0].flightdate | ||
| 1131 | + this.preQuery.originstation = this.preData[0].originstation | ||
| 1132 | + this.preQuery.destinationstation = this.preData[0].destinationstation | ||
| 1133 | + this.preQuery.customcode = this.preData[0].customcode | ||
| 995 | } | 1134 | } |
| 996 | setTimeout(() => { | 1135 | setTimeout(() => { |
| 997 | this.listLoading = false | 1136 | this.listLoading = false |
| 998 | }, 1500) | 1137 | }, 1500) |
| 999 | }) | 1138 | }) |
| 1000 | } else { | 1139 | } else { |
| 1001 | - getMt2201ListForParam(this.listQuery).then(res => { | 1140 | + getMt2201ListForParam(this.preQuery).then(res => { |
| 1002 | this.preData = res.data.dataList | 1141 | this.preData = res.data.dataList |
| 1003 | this.total = res.data.count | 1142 | this.total = res.data.count |
| 1004 | setTimeout(() => { | 1143 | setTimeout(() => { |
| @@ -1006,7 +1145,6 @@ | @@ -1006,7 +1145,6 @@ | ||
| 1006 | }, 1500) | 1145 | }, 1500) |
| 1007 | }) | 1146 | }) |
| 1008 | } | 1147 | } |
| 1009 | - | ||
| 1010 | }, | 1148 | }, |
| 1011 | // >>>>>>>>>>>>>>>>重置实体<<<<<<<<<<<<<<<<<< | 1149 | // >>>>>>>>>>>>>>>>重置实体<<<<<<<<<<<<<<<<<< |
| 1012 | restModel() { | 1150 | restModel() { |
| @@ -1065,19 +1203,19 @@ | @@ -1065,19 +1203,19 @@ | ||
| 1065 | dest3: undefined, | 1203 | dest3: undefined, |
| 1066 | eairportid: undefined, | 1204 | eairportid: undefined, |
| 1067 | csgcustomerid: undefined, | 1205 | csgcustomerid: undefined, |
| 1068 | - collected: '0', | 1206 | + paymodel: '0', |
| 1069 | } | 1207 | } |
| 1070 | } | 1208 | } |
| 1071 | }, | 1209 | }, |
| 1072 | // >>>>>>>>>>>>>>>>新增主单<<<<<<<<<<<<<<<<<< | 1210 | // >>>>>>>>>>>>>>>>新增主单<<<<<<<<<<<<<<<<<< |
| 1073 | handleAddpreInfo() { | 1211 | handleAddpreInfo() { |
| 1074 | this.restModel() | 1212 | 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 | 1213 | + this.preModel.carrier = this.preQuery.carrier |
| 1214 | + this.preModel.flightno = this.preQuery.flightno | ||
| 1215 | + this.preModel.flightdate = this.preQuery.flightdate | ||
| 1216 | + this.preModel.originstation = this.preQuery.originstation | ||
| 1217 | + this.preModel.destinationstation = this.preQuery.destinationstation | ||
| 1218 | + this.preModel.customcode = this.preQuery.customcode | ||
| 1081 | this.dialogStatus = 'create' | 1219 | this.dialogStatus = 'create' |
| 1082 | this.dialogFormVisible = true | 1220 | this.dialogFormVisible = true |
| 1083 | this.$nextTick(() => { | 1221 | this.$nextTick(() => { |
| @@ -1105,19 +1243,20 @@ | @@ -1105,19 +1243,20 @@ | ||
| 1105 | }, | 1243 | }, |
| 1106 | // >>>>>>>>>>>>>>>>搜索<<<<<<<<<<<<<<<<<< | 1244 | // >>>>>>>>>>>>>>>>搜索<<<<<<<<<<<<<<<<<< |
| 1107 | handleSerach() { | 1245 | 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 | 1246 | + // this.preQuery.flightno = undefined |
| 1247 | + // this.preQuery.carrier = undefined | ||
| 1248 | + // this.preQuery.originstation = undefined | ||
| 1249 | + // this.preQuery.flightdate = undefined | ||
| 1250 | + // this.preQuery.destinationstation = undefined | ||
| 1113 | this.getList() | 1251 | this.getList() |
| 1114 | }, | 1252 | }, |
| 1115 | // >>>>>>>>>>>>>>>>收发明细<<<<<<<<<<<<<<<<<< | 1253 | // >>>>>>>>>>>>>>>>收发明细<<<<<<<<<<<<<<<<<< |
| 1116 | handleSend(row) { | 1254 | handleSend(row) { |
| 1117 | const resQuery = { | 1255 | const resQuery = { |
| 1118 | carrier: row.carrier, | 1256 | carrier: row.carrier, |
| 1119 | - flightNo: row.flightno, | ||
| 1120 | - flightDate: row.flightdate, | 1257 | + flightno: row.flightno, |
| 1258 | + flightdate: row.flightdate, | ||
| 1259 | + orpertype: row.orpertype, | ||
| 1121 | awba: row.awba, | 1260 | awba: row.awba, |
| 1122 | awbh: row.awbh, | 1261 | awbh: row.awbh, |
| 1123 | messageType: 'MT2201' | 1262 | messageType: 'MT2201' |
| @@ -1128,13 +1267,46 @@ | @@ -1128,13 +1267,46 @@ | ||
| 1128 | }) | 1267 | }) |
| 1129 | }, | 1268 | }, |
| 1130 | // >>>>>>>>>>>>>>>>发送舱单报<<<<<<<<<<<<<<<<<< | 1269 | // >>>>>>>>>>>>>>>>发送舱单报<<<<<<<<<<<<<<<<<< |
| 1131 | - handleAwbSend() { | ||
| 1132 | - | 1270 | + handleAwbSend(row) { |
| 1271 | + delete row.parent | ||
| 1272 | + delete row.children | ||
| 1273 | + this.rows = row; | ||
| 1274 | + this.$confirm("是否发送", "确认消息", { | ||
| 1275 | + distinguishCancelAndClose: true, | ||
| 1276 | + confirmButtonText: '发送', | ||
| 1277 | + cancelButtonText: '取消' | ||
| 1278 | + }).then(() => { | ||
| 1279 | + if (row.awbh === null) { | ||
| 1280 | + row.awbh = '' | ||
| 1281 | + } | ||
| 1282 | + sendCreateMt2201(row).then(res => { | ||
| 1283 | + if (res.data.count > 0) { | ||
| 1284 | + Message.success(res.data.respMessage) | ||
| 1285 | + this.rows.status="23"; | ||
| 1286 | + this.rows.ext5="新增报发送成功"; | ||
| 1287 | + } else { | ||
| 1288 | + Message.error(res.data.respMessage) | ||
| 1289 | + } | ||
| 1290 | + }) | ||
| 1291 | + }) | ||
| 1292 | + }, | ||
| 1293 | + // 发送舱单报 按钮自灰 | ||
| 1294 | + addStatus(status){ | ||
| 1295 | + if(status=='23' || status=='24'||status=='25'){ | ||
| 1296 | + return true; | ||
| 1297 | + }else if(status=='22' ) { | ||
| 1298 | + return false; | ||
| 1299 | + } | ||
| 1133 | }, | 1300 | }, |
| 1134 | // >>>>>>>>>>>>>>>>更新运单数据<<<<<<<<<<<<<<<<<< | 1301 | // >>>>>>>>>>>>>>>>更新运单数据<<<<<<<<<<<<<<<<<< |
| 1135 | handleEdit(row) { | 1302 | handleEdit(row) { |
| 1303 | + console.log(row) | ||
| 1136 | this.preModel = Object.assign({}, row) | 1304 | this.preModel = Object.assign({}, row) |
| 1137 | this.dialogStatus = 'update' | 1305 | this.dialogStatus = 'update' |
| 1306 | + if (row.awbh !== undefined && row.awbh !== ""){ | ||
| 1307 | + this.fenStatus = 'addAwbh' | ||
| 1308 | + } | ||
| 1309 | + | ||
| 1138 | this.dialogFormVisible = true | 1310 | this.dialogFormVisible = true |
| 1139 | this.$nextTick(() => { | 1311 | this.$nextTick(() => { |
| 1140 | this.$refs.preFormData.clearValidate() | 1312 | this.$refs.preFormData.clearValidate() |
| @@ -1158,14 +1330,116 @@ | @@ -1158,14 +1330,116 @@ | ||
| 1158 | }) | 1330 | }) |
| 1159 | }, | 1331 | }, |
| 1160 | // >>>>>>>>>>>>>>>>发送修改报<<<<<<<<<<<<<<<<<< | 1332 | // >>>>>>>>>>>>>>>>发送修改报<<<<<<<<<<<<<<<<<< |
| 1161 | - handleAwbEdit() { | ||
| 1162 | - | 1333 | + handleAwbEdit(row) { |
| 1334 | + delete row.parent | ||
| 1335 | + delete row.children | ||
| 1336 | + this.rows = row; | ||
| 1337 | + this.preModel = Object.assign({}, row) | ||
| 1338 | + this.dialogStatus = 'sendUpdate' | ||
| 1339 | + this.dialogFormVisible = true | ||
| 1340 | + this.$nextTick(() => { | ||
| 1341 | + this.$refs.preFormData.clearValidate() | ||
| 1342 | + }) | ||
| 1163 | }, | 1343 | }, |
| 1164 | - // >>>>>>>>>>>>>>>>保存并发送<<<<<<<<<<<<<<<<<< | ||
| 1165 | - handleSaveAndSend() { | 1344 | + // 发送修改报自灰 |
| 1345 | + editStatus(status){ | ||
| 1346 | + if(status=='23' || status=='24'||status=='25'){ | ||
| 1347 | + return true; | ||
| 1348 | + }else if(status=='25' ) { | ||
| 1349 | + return false; | ||
| 1350 | + } | ||
| 1351 | + }, | ||
| 1352 | + sendUpdate(){ | ||
| 1353 | + this.respModel.reason = this.preModel.reason | ||
| 1354 | + this.respModel.contactName = this.preModel.contactName | ||
| 1355 | + this.respModel.contactTel = this.preModel.contactTel | ||
| 1356 | + // | ||
| 1357 | + delete this.preModel._expanded | ||
| 1358 | + delete this.preModel._level | ||
| 1359 | + delete this.preModel._marginLeft | ||
| 1360 | + delete this.preModel._show | ||
| 1361 | + delete this.preModel._width | ||
| 1362 | + | ||
| 1363 | + const reason = this.preModel.reason | ||
| 1364 | + const contactName = this.preModel.contactName | ||
| 1365 | + const contactTel = this.preModel.contactTel | ||
| 1166 | 1366 | ||
| 1367 | + this.$refs.preFormData.validate(valid =>{ | ||
| 1368 | + if(valid){ | ||
| 1369 | + delete this.preModel.reason | ||
| 1370 | + delete this.preModel.contactName | ||
| 1371 | + delete this.preModel.contactTel | ||
| 1372 | + const map = { | ||
| 1373 | + 'mt2201': this.preModel, | ||
| 1374 | + 'reason' : reason, | ||
| 1375 | + 'contactName': contactName, | ||
| 1376 | + 'contactTel': contactTel, | ||
| 1377 | + } | ||
| 1378 | + sendUpdateMt2201(map).then(res =>{ | ||
| 1379 | + if(res.data.count >0){ | ||
| 1380 | + Message.success(res.data.respMessage) | ||
| 1381 | + this.rows.status="25"; | ||
| 1382 | + this.rows.ext5="修改报发送成功"; | ||
| 1383 | + this.dialogFormVisible = false | ||
| 1384 | + }else { | ||
| 1385 | + Message.error(res.data.respMessage) | ||
| 1386 | + } | ||
| 1387 | + }) | ||
| 1388 | + } | ||
| 1389 | + }) | ||
| 1167 | }, | 1390 | }, |
| 1391 | + | ||
| 1168 | // >>>>>>>>>>>>>>>>发送删除报<<<<<<<<<<<<<<<<<< | 1392 | // >>>>>>>>>>>>>>>>发送删除报<<<<<<<<<<<<<<<<<< |
| 1393 | + handleSendDelete(row) { | ||
| 1394 | + this.respModel = { | ||
| 1395 | + carrier: undefined, | ||
| 1396 | + reason: undefined, | ||
| 1397 | + contactName: undefined, | ||
| 1398 | + contactTel: undefined, | ||
| 1399 | + content: '', | ||
| 1400 | + flightNo: undefined, | ||
| 1401 | + awba: undefined, | ||
| 1402 | + customCode: undefined, | ||
| 1403 | + flightDate: undefined, | ||
| 1404 | + awbh: '' | ||
| 1405 | + } | ||
| 1406 | + this.rows = row; | ||
| 1407 | + this.dialogDeleteVisble = true | ||
| 1408 | + this.respModel.awba = row.awba | ||
| 1409 | + this.respModel.flightNo = row.flightno | ||
| 1410 | + this.respModel.customCode = row.customcode | ||
| 1411 | + this.respModel.awbh = row.awbh | ||
| 1412 | + this.respModel.flightDate = row.flightdate | ||
| 1413 | + this.respModel.carrier = row.carrier | ||
| 1414 | + this.$nextTick(()=>{ | ||
| 1415 | + this.$refs.sendDeleteForm.clearValidate() | ||
| 1416 | + }) | ||
| 1417 | + }, | ||
| 1418 | + // 发送删除报按钮自灰 | ||
| 1419 | + deleteStatus(status){ | ||
| 1420 | + if(status=='23' || status=='24'||status=='25'){ | ||
| 1421 | + return true; | ||
| 1422 | + }else if(status=='24' ) { | ||
| 1423 | + return false; | ||
| 1424 | + } | ||
| 1425 | + }, | ||
| 1426 | + sendDelete() { | ||
| 1427 | + this.$refs.sendDeleteForm.validate(valid =>{ | ||
| 1428 | + if(valid){ | ||
| 1429 | + sendDeleteMt2201(this.respModel).then(res => { | ||
| 1430 | + if(res.data.count>0){ | ||
| 1431 | + Message.success(res.data.respMessage) | ||
| 1432 | + this.dialogDeleteVisble = false | ||
| 1433 | + this.rows.status="24"; | ||
| 1434 | + this.rows.ext5="删除报发送成功"; | ||
| 1435 | + }else { | ||
| 1436 | + Message.error(res.data.respMessage) | ||
| 1437 | + } | ||
| 1438 | + }) | ||
| 1439 | + } | ||
| 1440 | + }) | ||
| 1441 | + }, | ||
| 1442 | + //>>>>>>>>>>>>>>>>删除运单<<<<<<<<<<<<<<<<<< | ||
| 1169 | handleAwbDelete(row) { | 1443 | handleAwbDelete(row) { |
| 1170 | delete row.parent | 1444 | delete row.parent |
| 1171 | delete row.children | 1445 | delete row.children |
| @@ -1199,27 +1473,28 @@ | @@ -1199,27 +1473,28 @@ | ||
| 1199 | }, | 1473 | }, |
| 1200 | // >>>>>>>>>>>>>>>>更改运单状态<<<<<<<<<<<<<<<<<< | 1474 | // >>>>>>>>>>>>>>>>更改运单状态<<<<<<<<<<<<<<<<<< |
| 1201 | handleAwbStatus(row) { | 1475 | handleAwbStatus(row) { |
| 1202 | - delete row.parent | ||
| 1203 | - delete row.children | ||
| 1204 | this.$confirm("是否发送更改状态", "确认消息", { | 1476 | this.$confirm("是否发送更改状态", "确认消息", { |
| 1205 | distinguishCancelAndClose: true, | 1477 | distinguishCancelAndClose: true, |
| 1206 | confirmButtonText: '确认更改', | 1478 | confirmButtonText: '确认更改', |
| 1207 | cancelButtonText: '取消更改' | 1479 | cancelButtonText: '取消更改' |
| 1208 | }).then(() => { | 1480 | }).then(() => { |
| 1209 | - updateStatus(row).then(res => { | ||
| 1210 | - if (res.data.count > 0) { | ||
| 1211 | - this.$message({ | ||
| 1212 | - type: 'success', | ||
| 1213 | - message: '当前运单状态已更改' | ||
| 1214 | - }) | ||
| 1215 | - this.getList() | ||
| 1216 | - } else { | ||
| 1217 | - this.$message({ | ||
| 1218 | - type: 'error', | ||
| 1219 | - message: '状态更改失败,请稍后重试' | ||
| 1220 | - }) | ||
| 1221 | - } | ||
| 1222 | - }) | 1481 | + if (row.status!==22){ |
| 1482 | + row.status =22; | ||
| 1483 | + } | ||
| 1484 | + // updateStatus(row).then(res => { | ||
| 1485 | + // if (res.data.count > 0) { | ||
| 1486 | + // this.$message({ | ||
| 1487 | + // type: 'success', | ||
| 1488 | + // message: '当前运单状态已更改' | ||
| 1489 | + // }) | ||
| 1490 | + // this.getList() | ||
| 1491 | + // } else { | ||
| 1492 | + // this.$message({ | ||
| 1493 | + // type: 'error', | ||
| 1494 | + // message: '状态更改失败,请稍后重试' | ||
| 1495 | + // }) | ||
| 1496 | + // } | ||
| 1497 | + // }) | ||
| 1223 | 1498 | ||
| 1224 | }).catch(action => { | 1499 | }).catch(action => { |
| 1225 | this.$message({ | 1500 | this.$message({ |
| @@ -1234,6 +1509,7 @@ | @@ -1234,6 +1509,7 @@ | ||
| 1234 | handleAddAwbh(row) { | 1509 | handleAddAwbh(row) { |
| 1235 | this.restModel() | 1510 | this.restModel() |
| 1236 | const template = Object.assign({}, row) // copy obj | 1511 | const template = Object.assign({}, row) // copy obj |
| 1512 | + this.preModel.uuid = template.uuid | ||
| 1237 | this.preModel.awba = template.awba | 1513 | this.preModel.awba = template.awba |
| 1238 | this.preModel.flightdate = template.flightdate | 1514 | this.preModel.flightdate = template.flightdate |
| 1239 | this.preModel.flightno = template.flightno | 1515 | this.preModel.flightno = template.flightno |
| @@ -1242,18 +1518,18 @@ | @@ -1242,18 +1518,18 @@ | ||
| 1242 | this.preModel.carrier = template.carrier | 1518 | this.preModel.carrier = template.carrier |
| 1243 | this.preModel.awbinfo.shprcountyr = template.awbinfo.shprcountyr | 1519 | this.preModel.awbinfo.shprcountyr = template.awbinfo.shprcountyr |
| 1244 | this.preModel.originstation = template.originstation | 1520 | this.preModel.originstation = template.originstation |
| 1245 | - this.preModel.awbinfo.collected = template.awbinfo.collected | 1521 | + this.preModel.awbinfo.paymodel = template.awbinfo.paymodel |
| 1246 | this.preModel.awbinfo.sairportid = template.awbinfo.sairportid | 1522 | this.preModel.awbinfo.sairportid = template.awbinfo.sairportid |
| 1247 | this.preModel.awbinfo.eairportid = template.awbinfo.eairportid | 1523 | this.preModel.awbinfo.eairportid = template.awbinfo.eairportid |
| 1248 | this.preModel.awbinfo.ex5 = template.awbinfo.ex5 | 1524 | 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 => { | 1525 | + this.preQuery.awba = template.awba |
| 1526 | + this.preQuery.flightdate = template.flightdate | ||
| 1527 | + this.preQuery.flightno = template.flightno | ||
| 1528 | + this.preQuery.originstation = template.originstation | ||
| 1529 | + this.preQuery.destinationstation = template.destinationstation | ||
| 1530 | + this.preQuery.customcode = template.customcode | ||
| 1531 | + this.preQuery.carrier = template.carrier | ||
| 1532 | + getMt2201ListForParam(this.preQuery).then(res => { | ||
| 1257 | this.awbPiece = 0 | 1533 | this.awbPiece = 0 |
| 1258 | this.awbWeight = 0 | 1534 | this.awbWeight = 0 |
| 1259 | let residuePiece = 0 | 1535 | let residuePiece = 0 |
| @@ -1271,14 +1547,14 @@ | @@ -1271,14 +1547,14 @@ | ||
| 1271 | this.awbWeight = res.data.dataList[0].weight - residueWeight | 1547 | this.awbWeight = res.data.dataList[0].weight - residueWeight |
| 1272 | } | 1548 | } |
| 1273 | }) | 1549 | }) |
| 1274 | - this.dialogStatus = 'addAwbh' | 1550 | + this.dialogStatus = 'create' |
| 1551 | + this.fenStatus = 'addAwbh' | ||
| 1275 | this.dialogFormVisible = true | 1552 | this.dialogFormVisible = true |
| 1276 | this.$nextTick(() => { | 1553 | this.$nextTick(() => { |
| 1277 | this.$refs.preFormData.clearValidate() | 1554 | this.$refs.preFormData.clearValidate() |
| 1278 | }) | 1555 | }) |
| 1279 | }, | 1556 | }, |
| 1280 | - | ||
| 1281 | - //获取城市列表 | 1557 | + //获取国家列表 |
| 1282 | getCountryList() { | 1558 | getCountryList() { |
| 1283 | getCountry().then(res => { | 1559 | getCountry().then(res => { |
| 1284 | this.countryList = res.data.dataList | 1560 | this.countryList = res.data.dataList |
| @@ -1294,22 +1570,44 @@ | @@ -1294,22 +1570,44 @@ | ||
| 1294 | .indexOf(query.toUpperCase()) > -1 | 1570 | .indexOf(query.toUpperCase()) > -1 |
| 1295 | }) | 1571 | }) |
| 1296 | }, 200) | 1572 | }, 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 { | 1573 | } else { |
| 1308 | this.countryOption = [] | 1574 | this.countryOption = [] |
| 1309 | } | 1575 | } |
| 1576 | + }, | ||
| 1577 | + remoteMethodAirport(query){ | ||
| 1578 | + this.airportCode = [] | ||
| 1579 | + if (query !== '') { | ||
| 1580 | + this.airportLoading = true | ||
| 1581 | + getAirportCode({airportid: query}).then(res => { | ||
| 1582 | + if(res !== null){ | ||
| 1583 | + setTimeout(() => { | ||
| 1584 | + this.airportLoading = false | ||
| 1585 | + this.airportCode = res.data.data | ||
| 1586 | + }, 200) | ||
| 1587 | + } | ||
| 1588 | + }) | ||
| 1589 | + } else { | ||
| 1590 | + this.airportCode = [] | ||
| 1591 | + } | ||
| 1592 | + }, | ||
| 1310 | 1593 | ||
| 1311 | - | 1594 | + remoteMethodCustomCode(query){ |
| 1595 | + this.customCodeList = [] | ||
| 1596 | + if (query !== '') { | ||
| 1597 | + this.customLoading = true | ||
| 1598 | + getCustomCode({customcode: query}).then(res => { | ||
| 1599 | + if(res !== null){ | ||
| 1600 | + setTimeout(() => { | ||
| 1601 | + this.customLoading = false | ||
| 1602 | + this.customCodeList = res.data.data | ||
| 1603 | + }, 200) | ||
| 1604 | + } | ||
| 1605 | + }) | ||
| 1606 | + } else { | ||
| 1607 | + this.airportCode = [] | ||
| 1608 | + } | ||
| 1312 | }, | 1609 | }, |
| 1610 | + | ||
| 1313 | handleAddpre() { | 1611 | handleAddpre() { |
| 1314 | const row = { | 1612 | const row = { |
| 1315 | 'messageType': 'MT2201' | 1613 | 'messageType': 'MT2201' |
| @@ -1318,7 +1616,8 @@ | @@ -1318,7 +1616,8 @@ | ||
| 1318 | }, | 1616 | }, |
| 1319 | 1617 | ||
| 1320 | handelBackStep() { | 1618 | handelBackStep() { |
| 1321 | - this.$router.push({name: '出港航班信息', params: {scopeRow: this.preModel}}) | 1619 | + this.preQuery.messageType = 'MT2201' |
| 1620 | + this.$router.push({name: '出港航班信息', params: {scopeRow: this.preQuery}}) | ||
| 1322 | } | 1621 | } |
| 1323 | } | 1622 | } |
| 1324 | } | 1623 | } |
| @@ -21,7 +21,7 @@ | @@ -21,7 +21,7 @@ | ||
| 21 | </div> | 21 | </div> |
| 22 | </el-col> | 22 | </el-col> |
| 23 | <el-col :span="24"> | 23 | <el-col :span="24"> |
| 24 | - <div class="grid-content content">进港舱单查询</div> | 24 | + <div class="grid-content content">出港理货查询</div> |
| 25 | </el-col> | 25 | </el-col> |
| 26 | <el-col :span="24"> | 26 | <el-col :span="24"> |
| 27 | <div class="grid-content co"> | 27 | <div class="grid-content co"> |
| @@ -32,7 +32,7 @@ | @@ -32,7 +32,7 @@ | ||
| 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="tidyQuery.awba" placeholder="请输入主单号"></el-input> | 35 | + <el-input v-model="tidyQuery.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"> |
| @@ -51,23 +51,30 @@ | @@ -51,23 +51,30 @@ | ||
| 51 | </el-col> | 51 | </el-col> |
| 52 | </el-row> | 52 | </el-row> |
| 53 | </div> | 53 | </div> |
| 54 | - <tree-table v-loading="listLoading" :data="tidyData" :eval-func="func" :expand-all="true" stripe | ||
| 55 | - style="font-size: 12px" border @selection-change="handleSelectionChange"> | ||
| 56 | - <el-table-column label="运单号" width="110" align="center"> | 54 | + <el-table v-loading="listLoading" :data="tidyData" stripe |
| 55 | + highlight-current-row | ||
| 56 | + default-expand-all | ||
| 57 | + row-key="uuid" | ||
| 58 | + border | ||
| 59 | + :tree-props="{children: 'children', hasChildren: 'hasChildren'}" | ||
| 60 | + style="font-size: 12px" @selection-change="handleSelectionChange"> | ||
| 61 | + <el-table-column type="selection" width="55"> | ||
| 62 | + </el-table-column> | ||
| 63 | + <el-table-column label="运单号" width="150" align="center"> | ||
| 57 | <template slot-scope="scope"> | 64 | <template slot-scope="scope"> |
| 58 | <span>{{scope.row.awba}}</span> | 65 | <span>{{scope.row.awba}}</span> |
| 59 | </template> | 66 | </template> |
| 60 | </el-table-column> | 67 | </el-table-column> |
| 61 | - <el-table-column label="运单号" width="120" align="center"> | 68 | + <el-table-column label="分单号" width="120" align="center"> |
| 62 | <template slot-scope="scope"> | 69 | <template slot-scope="scope"> |
| 63 | <span>{{scope.row.awbh}}</span> | 70 | <span>{{scope.row.awbh}}</span> |
| 64 | </template> | 71 | </template> |
| 65 | </el-table-column> | 72 | </el-table-column> |
| 66 | - <el-table-column label="运单件数/重量" width="100" align="center"> | ||
| 67 | - <template slot-scope="scope"> | ||
| 68 | - <span>{{scope.row.awbpiece}} / {{scope.row.awbweight}}</span> | ||
| 69 | - </template> | ||
| 70 | - </el-table-column> | 73 | +<!-- <el-table-column label="运单件数/重量" width="100" align="center">--> |
| 74 | +<!-- <template slot-scope="scope">--> | ||
| 75 | +<!-- <span>{{scope.row.awbpiece}} / {{scope.row.awbweight}}</span>--> | ||
| 76 | +<!-- </template>--> | ||
| 77 | +<!-- </el-table-column>--> | ||
| 71 | <el-table-column label="理货件数/重量" width="100" align="center"> | 78 | <el-table-column label="理货件数/重量" width="100" align="center"> |
| 72 | <template slot-scope="scope"> | 79 | <template slot-scope="scope"> |
| 73 | <span>{{scope.row.piece}} / {{scope.row.weight}}</span> | 80 | <span>{{scope.row.piece}} / {{scope.row.weight}}</span> |
| @@ -81,51 +88,55 @@ | @@ -81,51 +88,55 @@ | ||
| 81 | <el-table-column label="状态" width="100" align="center"> | 88 | <el-table-column label="状态" width="100" align="center"> |
| 82 | <template slot-scope="scope"> | 89 | <template slot-scope="scope"> |
| 83 | <span v-if="scope.row.status ==='01'">未发送</span> | 90 | <span v-if="scope.row.status ==='01'">未发送</span> |
| 84 | - <span v-if="scope.row.status ==='02'">已发舱单报</span> | 91 | + <span v-if="scope.row.status ==='02'">待人工审核</span> |
| 92 | + <span v-if="scope.row.status ==='03'">退单</span> | ||
| 85 | <span v-if="scope.row.status ==='05'">舱单报退单</span> | 93 | <span v-if="scope.row.status ==='05'">舱单报退单</span> |
| 86 | <span v-if="scope.row.status ==='06'">舱单转人工</span> | 94 | <span v-if="scope.row.status ==='06'">舱单转人工</span> |
| 87 | <span v-if="scope.row.status ==='07'">舱单报申报成功</span> | 95 | <span v-if="scope.row.status ==='07'">舱单报申报成功</span> |
| 88 | - <span v-if="scope.row.status ==='08'">已发舱单删除报</span> | ||
| 89 | <span v-if="scope.row.status ==='09'">舱单删除报退单</span> | 96 | <span v-if="scope.row.status ==='09'">舱单删除报退单</span> |
| 90 | <span v-if="scope.row.status ==='10'">舱单删除报转人工</span> | 97 | <span v-if="scope.row.status ==='10'">舱单删除报转人工</span> |
| 91 | - <span v-if="scope.row.status ==='11'">舱单删除成功</span> | ||
| 92 | - <span v-if="scope.row.status ==='12'">已发舱单修改报</span> | ||
| 93 | - <span v-if="scope.row.status ==='13'">舱单修改报退单</span> | 98 | + <span v-if="scope.row.status ==='11'">放行</span> |
| 99 | + <span v-if="scope.row.status ==='12'">拒装</span> | ||
| 100 | + <span v-if="scope.row.status ==='13'">禁卸</span> | ||
| 94 | <span v-if="scope.row.status ==='14'">舱单修改报转人工</span> | 101 | <span v-if="scope.row.status ==='14'">舱单修改报转人工</span> |
| 95 | <span v-if="scope.row.status ==='15'">舱单修改报成功</span> | 102 | <span v-if="scope.row.status ==='15'">舱单修改报成功</span> |
| 96 | <span v-if="scope.row.status ==='16'">海关已存在</span> | 103 | <span v-if="scope.row.status ==='16'">海关已存在</span> |
| 104 | + <span v-if="scope.row.status ==='21'">可自动发送</span> | ||
| 105 | + <span v-if="scope.row.status ==='22'">未发送</span> | ||
| 106 | + <span v-if="scope.row.status ==='23'">已发送新增报</span> | ||
| 107 | + <span v-if="scope.row.status ==='24'">已发送删除报</span> | ||
| 108 | + <span v-if="scope.row.status ==='25'">已发送修改报</span> | ||
| 97 | </template> | 109 | </template> |
| 98 | </el-table-column> | 110 | </el-table-column> |
| 99 | - <el-table-column prop="receipt" label="回执信息" width="180" align="center"> | 111 | + <el-table-column label="回执信息" show-overflow-tooltip width="230" align="center"> |
| 100 | <template slot-scope="scope"> | 112 | <template slot-scope="scope"> |
| 101 | <span>{{scope.row.ext5}}</span> | 113 | <span>{{scope.row.ext5}}</span> |
| 102 | </template> | 114 | </template> |
| 103 | </el-table-column> | 115 | </el-table-column> |
| 104 | - <el-table-column prop="operation" label="操作" show-overflow-tooltip align="center"> | 116 | + <el-table-column prop="operation" label="操作" width="420px" align="center"> |
| 105 | <template slot-scope="scope"> | 117 | <template slot-scope="scope"> |
| 106 | - | ||
| 107 | <el-button size="mini" @click="handleSend(scope.row)">收发明细</el-button> | 118 | <el-button size="mini" @click="handleSend(scope.row)">收发明细</el-button> |
| 108 | <el-button size="mini" type="success" @click="handleEdit(scope.row)">编辑</el-button> | 119 | <el-button size="mini" type="success" @click="handleEdit(scope.row)">编辑</el-button> |
| 109 | <el-button size="mini" type="primary" @click="handleAwbSend(scope.row)" | 120 | <el-button size="mini" type="primary" @click="handleAwbSend(scope.row)" |
| 110 | - :disabled="scope.row.status !=='00'">发舱单报 | ||
| 111 | - </el-button> | ||
| 112 | - <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单</el-button> | 121 | + :disabled="addStatus(scope.row.status)">发送出港理货报</el-button> |
| 113 | 122 | ||
| 123 | + <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单</el-button> | ||
| 124 | + <p></p> | ||
| 114 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" | 125 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" |
| 115 | - :disabled="scope.row.status ==='00'">更改状态 | ||
| 116 | - </el-button> | ||
| 117 | - <el-button size="mini" type="primary" v-if="scope.row.awbh ===null" | ||
| 118 | - @click="handleAddAwbh(scope.row)">新增分单 | ||
| 119 | - </el-button> | 126 | + :disabled="scope.row.status ==='22'">更改状态</el-button> |
| 127 | + <el-button size="mini" type="primary" v-if="scope.row.awbh ===''" | ||
| 128 | + @click="handleAddAwbh(scope.row)">新增分单</el-button> | ||
| 129 | + <el-button size="mini" type="danger" @click="handleSendDelete(scope.row)" | ||
| 130 | + :disabled="deleteStatus(scope.row.status)">发出港理货删除报</el-button> | ||
| 120 | </template> | 131 | </template> |
| 121 | </el-table-column> | 132 | </el-table-column> |
| 122 | - </tree-table> | 133 | + </el-table> |
| 123 | <div class="btnFoot"> | 134 | <div class="btnFoot"> |
| 124 | <el-row> | 135 | <el-row> |
| 125 | - <el-button type="primary" size="mini" v-if="tidyModel.flightno !== undefined || tidyData.length> 0" | 136 | + <el-button type="primary" size="mini" v-if="tidyQuery.flightno !== undefined || tidyData.length> 0" |
| 126 | @click="handelAddTidyInfo">新增出港理货 | 137 | @click="handelAddTidyInfo">新增出港理货 |
| 127 | </el-button> | 138 | </el-button> |
| 128 | - <el-button type="primary" size="mini" v-if="tidyModel.flightno !== undefined || tidyData.length> 0" | 139 | + <el-button type="primary" size="mini" v-if="tidyQuery.flightno !== undefined || tidyData.length> 0" |
| 129 | @click="handelBackStep">返回 | 140 | @click="handelBackStep">返回 |
| 130 | </el-button> | 141 | </el-button> |
| 131 | </el-row> | 142 | </el-row> |
| @@ -148,8 +159,8 @@ | @@ -148,8 +159,8 @@ | ||
| 148 | </el-form-item> | 159 | </el-form-item> |
| 149 | </el-col> | 160 | </el-col> |
| 150 | <el-col :span="7.5"> | 161 | <el-col :span="7.5"> |
| 151 | - <el-form-item label="分单号" prop="awbh"> | ||
| 152 | - <el-input v-model="awbh" :disabled="dialogStatus === 'addAwbh'"></el-input> | 162 | + <el-form-item label="分单号" prop="awbh" v-if="fenStatus === 'addAwbh'"> |
| 163 | + <el-input v-model="awbh" clearable></el-input> | ||
| 153 | </el-form-item> | 164 | </el-form-item> |
| 154 | </el-col> | 165 | </el-col> |
| 155 | </el-row> | 166 | </el-row> |
| @@ -174,14 +185,29 @@ | @@ -174,14 +185,29 @@ | ||
| 174 | <el-row> | 185 | <el-row> |
| 175 | <el-col :span="7.5"> | 186 | <el-col :span="7.5"> |
| 176 | <el-form-item label="起始站" prop="originstation"> | 187 | <el-form-item label="起始站" prop="originstation"> |
| 177 | - <el-input v-model="originstation" | ||
| 178 | - :disabled="dialogStatus === 'update'"></el-input> | 188 | + |
| 189 | + <el-select filterable clearable placeholder="请选择起始站" :remote-method="remoteMethodAirport" | ||
| 190 | + allow-create v-model="originstation" remote> | ||
| 191 | + <el-option v-for="item in airportCode" | ||
| 192 | + :key="item.airportid" :label="item.airportid" | ||
| 193 | + :value="item.airportid" :disabled="dialogStatus === 'update'"> | ||
| 194 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 195 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 196 | + </el-option> | ||
| 197 | + </el-select> | ||
| 179 | </el-form-item> | 198 | </el-form-item> |
| 180 | </el-col> | 199 | </el-col> |
| 181 | <el-col :span="7.5"> | 200 | <el-col :span="7.5"> |
| 182 | <el-form-item label="目的站" prop="destinationstation"> | 201 | <el-form-item label="目的站" prop="destinationstation"> |
| 183 | - <el-input v-model="destinationstation" | ||
| 184 | - :disabled="dialogStatus === 'update'"></el-input> | 202 | + <el-select filterable clearable placeholder="请选择起始站" :remote-method="remoteMethodAirport" |
| 203 | + allow-create v-model="destinationstation" remote> | ||
| 204 | + <el-option v-for="item in airportCode" | ||
| 205 | + :key="item.airportid" :label="item.airportid" | ||
| 206 | + :value="item.airportid" :disabled="dialogStatus === 'update'"> | ||
| 207 | + <span style="float: left">{{ item.airportdescchn }}</span> | ||
| 208 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportid }}</span> | ||
| 209 | + </el-option> | ||
| 210 | + </el-select> | ||
| 185 | </el-form-item> | 211 | </el-form-item> |
| 186 | </el-col> | 212 | </el-col> |
| 187 | 213 | ||
| @@ -192,18 +218,18 @@ | @@ -192,18 +218,18 @@ | ||
| 192 | 218 | ||
| 193 | <el-row> | 219 | <el-row> |
| 194 | <el-col :span="7.5"> | 220 | <el-col :span="7.5"> |
| 195 | - <el-form-item label="运单件数" prop="price"> | 221 | + <el-form-item label="运单件数" prop="awbprice"> |
| 196 | <el-input v-model="tidyModel.awbprice"></el-input> | 222 | <el-input v-model="tidyModel.awbprice"></el-input> |
| 197 | </el-form-item> | 223 | </el-form-item> |
| 198 | </el-col> | 224 | </el-col> |
| 199 | <el-col :span="7.5"> | 225 | <el-col :span="7.5"> |
| 200 | - <el-form-item label="运单重量" prop="weight"> | 226 | + <el-form-item label="运单重量" prop="awbweight"> |
| 201 | <el-input v-model="tidyModel.awbweight"></el-input> | 227 | <el-input v-model="tidyModel.awbweight"></el-input> |
| 202 | </el-form-item> | 228 | </el-form-item> |
| 203 | </el-col> | 229 | </el-col> |
| 204 | <el-col :span="7.5"> | 230 | <el-col :span="7.5"> |
| 205 | <el-col :span="7.5"> | 231 | <el-col :span="7.5"> |
| 206 | - <el-form-item label="装载开始时间" prop="endtime"> | 232 | + <el-form-item label="装载开始时间" prop="starttime"> |
| 207 | <el-date-picker v-model="tidyModel.starttime" value-format="yyyy-MM-dd HH:mm:ss" | 233 | <el-date-picker v-model="tidyModel.starttime" value-format="yyyy-MM-dd HH:mm:ss" |
| 208 | type="datetime" | 234 | type="datetime" |
| 209 | placeholder="请输入"></el-date-picker> | 235 | placeholder="请输入"></el-date-picker> |
| @@ -222,13 +248,13 @@ | @@ -222,13 +248,13 @@ | ||
| 222 | <el-input v-model="tidyModel.weight"></el-input> | 248 | <el-input v-model="tidyModel.weight"></el-input> |
| 223 | </el-form-item> | 249 | </el-form-item> |
| 224 | </el-col> | 250 | </el-col> |
| 225 | - <el-col :span="7.5"> | ||
| 226 | - <el-form-item label="装载结束时间" prop="endtime"> | ||
| 227 | - <el-date-picker v-model="tidyModel.endtime" value-format="yyyy-MM-dd HH:mm:ss" | ||
| 228 | - type="datetime" | ||
| 229 | - placeholder="请输入"></el-date-picker> | ||
| 230 | - </el-form-item> | ||
| 231 | - </el-col> | 251 | +<!-- <el-col :span="7.5">--> |
| 252 | +<!-- <el-form-item label="装载结束时间" prop="endtime">--> | ||
| 253 | +<!-- <el-date-picker v-model="tidyModel.endtime" value-format="yyyy-MM-dd HH:mm:ss"--> | ||
| 254 | +<!-- type="datetime"--> | ||
| 255 | +<!-- placeholder="请输入"></el-date-picker>--> | ||
| 256 | +<!-- </el-form-item>--> | ||
| 257 | +<!-- </el-col>--> | ||
| 232 | </el-row> | 258 | </el-row> |
| 233 | <el-row> | 259 | <el-row> |
| 234 | <el-col :span="7.5"> | 260 | <el-col :span="7.5"> |
| @@ -238,9 +264,16 @@ | @@ -238,9 +264,16 @@ | ||
| 238 | </el-col> | 264 | </el-col> |
| 239 | <el-col :span="7.5"> | 265 | <el-col :span="7.5"> |
| 240 | <el-form-item label="海关关区" prop="customcode"> | 266 | <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> | 267 | + <el-select v-model="tidyModel.customcode" placeholder="请选择关区代码" |
| 268 | + allow-create | ||
| 269 | + default-first-option | ||
| 270 | + filterable clearable remote :remote-method="remoteMethodCustomCode" :loading="customLoading" | ||
| 271 | + > | ||
| 272 | + <el-option v-for="item in customCodeList" :key="item.customcode" :label="item.customcode" | ||
| 273 | + :value="item.customcode"> | ||
| 274 | + <span style="float: left">{{ item.customcode }}</span> | ||
| 275 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.customname }}</span> | ||
| 276 | + </el-option> | ||
| 244 | </el-select> | 277 | </el-select> |
| 245 | </el-form-item> | 278 | </el-form-item> |
| 246 | </el-col> | 279 | </el-col> |
| @@ -249,12 +282,11 @@ | @@ -249,12 +282,11 @@ | ||
| 249 | <div slot="footer" class="dialog-footer"> | 282 | <div slot="footer" class="dialog-footer"> |
| 250 | <el-button @click="dialogFormVisible = false">取消</el-button> | 283 | <el-button @click="dialogFormVisible = false">取消</el-button> |
| 251 | <el-button type="primary" @click="dialogStatus==='create'?createData():updateData()">保存</el-button> | 284 | <el-button type="primary" @click="dialogStatus==='create'?createData():updateData()">保存</el-button> |
| 252 | - <el-button type="success" @click="handleSaveAndSend">保存并发送</el-button> | ||
| 253 | </div> | 285 | </div> |
| 254 | </el-dialog> | 286 | </el-dialog> |
| 255 | <el-dialog title="收发明细" :visible.sync="dialogTableVisible"> | 287 | <el-dialog title="收发明细" :visible.sync="dialogTableVisible"> |
| 256 | <el-table :data="detailData" border> | 288 | <el-table :data="detailData" border> |
| 257 | - <el-table-column label="操作时间" width="150"> | 289 | + <el-table-column label="操作时间" width="180"> |
| 258 | <template slot-scope="scope"> | 290 | <template slot-scope="scope"> |
| 259 | {{scope.row.busdate}} | 291 | {{scope.row.busdate}} |
| 260 | </template> | 292 | </template> |
| @@ -284,6 +316,11 @@ | @@ -284,6 +316,11 @@ | ||
| 284 | {{scope.row.cusrestext}} | 316 | {{scope.row.cusrestext}} |
| 285 | </template> | 317 | </template> |
| 286 | </el-table-column> | 318 | </el-table-column> |
| 319 | + <el-table-column label="操作类型" width="100"> | ||
| 320 | + <template slot-scope="scope"> | ||
| 321 | + {{scope.row.opertype}} | ||
| 322 | + </template> | ||
| 323 | + </el-table-column> | ||
| 287 | <el-table-column label="操作人" width="100"> | 324 | <el-table-column label="操作人" width="100"> |
| 288 | <template slot-scope="scope"> | 325 | <template slot-scope="scope"> |
| 289 | {{scope.row.operusername}} | 326 | {{scope.row.operusername}} |
| @@ -291,7 +328,27 @@ | @@ -291,7 +328,27 @@ | ||
| 291 | </el-table-column> | 328 | </el-table-column> |
| 292 | </el-table> | 329 | </el-table> |
| 293 | </el-dialog> | 330 | </el-dialog> |
| 294 | - | 331 | + <el-dialog title="删除原因" :visible.sync="dialogDeleteVisible" width="30%"> |
| 332 | + <el-form ref="tidyDeleteForm" :model="respModel" :rules="tidyDeleteRules" | ||
| 333 | + label-width="120px" style="margin-right: 50px"> | ||
| 334 | + <el-form-item label="删除原因" prop="reason"> | ||
| 335 | + <el-input v-model="respModel.reason" placeholder="删除原因"></el-input> | ||
| 336 | + </el-form-item> | ||
| 337 | + <el-form-item label="删除操作人" prop="contactName"> | ||
| 338 | + <el-input v-model="respModel.contactName" placeholder="操作人姓名"></el-input> | ||
| 339 | + </el-form-item> | ||
| 340 | + <el-form-item label="操作人Tel" prop="contactTel"> | ||
| 341 | + <el-input v-model="respModel.contactTel" placeholder="删除操作人联系方式"></el-input> | ||
| 342 | + </el-form-item> | ||
| 343 | + <el-form-item label="备注"> | ||
| 344 | + <el-input v-model="respModel.content" type="textarea"></el-input> | ||
| 345 | + </el-form-item> | ||
| 346 | + </el-form> | ||
| 347 | + <div slot="footer" class="dialog-footer"> | ||
| 348 | + <el-button @click="dialogDeleteVisible = false">取消</el-button> | ||
| 349 | + <el-button type="primary" @click="sendTidyDelete()">发送</el-button> | ||
| 350 | + </div> | ||
| 351 | + </el-dialog> | ||
| 295 | </div> | 352 | </div> |
| 296 | </template> | 353 | </template> |
| 297 | <script> | 354 | <script> |
| @@ -299,10 +356,15 @@ | @@ -299,10 +356,15 @@ | ||
| 299 | import treeToArray from '@/utils/customEval' | 356 | import treeToArray from '@/utils/customEval' |
| 300 | import Pagination from '@/components/Pagination' | 357 | import Pagination from '@/components/Pagination' |
| 301 | 358 | ||
| 302 | - import {getMt520XListForParam, deleteByIsDelete, updateStatus, updateMt520X, addMt520X} from '@/api/exitTidy' | 359 | + import { |
| 360 | + getMt520XListForParam, deleteByIsDelete, | ||
| 361 | + updateStatus, updateMt520X, addMt520X, | ||
| 362 | + sendCreateMt5202,sendRemoveMt5202 } from '@/api/exitTidy' | ||
| 303 | import {Message} from "element-ui"; | 363 | import {Message} from "element-ui"; |
| 304 | import {getResponseForParam} from '@/api/responseDetail' | 364 | import {getResponseForParam} from '@/api/responseDetail' |
| 305 | import {validAwb, validAlphabets, validAlphabetsAndNum, validAlphabetsAndSpanceKey,validatorNum} from "@/utils/validate" | 365 | import {validAwb, validAlphabets, validAlphabetsAndNum, validAlphabetsAndSpanceKey,validatorNum} from "@/utils/validate" |
| 366 | + import {getCustomCode,getAirportCode} from "@/api/country"; | ||
| 367 | + import util from "@/common/js/util.js"; | ||
| 306 | 368 | ||
| 307 | export default { | 369 | export default { |
| 308 | name: "ExitTidy", | 370 | name: "ExitTidy", |
| @@ -316,11 +378,13 @@ | @@ -316,11 +378,13 @@ | ||
| 316 | callback() | 378 | callback() |
| 317 | } | 379 | } |
| 318 | const validatorAwbh = (rule, value, callback) => { | 380 | const validatorAwbh = (rule, value, callback) => { |
| 319 | - if (!validAlphabetsAndNum(value)) { | 381 | + if (value !=='' && value !== undefined && !validAlphabetsAndNum(value)) { |
| 320 | callback("只能输入字母和数字") | 382 | callback("只能输入字母和数字") |
| 321 | - } | 383 | + }else{ |
| 322 | callback() | 384 | callback() |
| 323 | } | 385 | } |
| 386 | + | ||
| 387 | + } | ||
| 324 | const validatorAlphabets = (rule, value, callback) => { | 388 | const validatorAlphabets = (rule, value, callback) => { |
| 325 | if (!validAlphabets(value)) { | 389 | if (!validAlphabets(value)) { |
| 326 | callback("只能输入字母") | 390 | callback("只能输入字母") |
| @@ -348,35 +412,41 @@ | @@ -348,35 +412,41 @@ | ||
| 348 | create: '添加出港理货', | 412 | create: '添加出港理货', |
| 349 | addAwbh: '添加分单理货' | 413 | addAwbh: '添加分单理货' |
| 350 | }, | 414 | }, |
| 351 | - customcodeList: [4604, 4620], | 415 | + customCodeList: [], |
| 416 | + airportCode:[], | ||
| 352 | tidyQuery: { | 417 | tidyQuery: { |
| 353 | pageSize: 1, | 418 | pageSize: 1, |
| 354 | - limitSize: 100, | 419 | + limitSize: 30, |
| 355 | awba: undefined, | 420 | awba: undefined, |
| 356 | carrier: undefined, | 421 | carrier: undefined, |
| 357 | flightno: undefined, | 422 | flightno: undefined, |
| 358 | flightdate: undefined, | 423 | flightdate: undefined, |
| 359 | originstation: undefined, | 424 | originstation: undefined, |
| 360 | destinationstation: undefined, | 425 | destinationstation: undefined, |
| 361 | - customcode: undefined | 426 | + customcode: undefined, |
| 427 | + rcfdep: "5202" | ||
| 362 | }, | 428 | }, |
| 363 | tidyRoles: { | 429 | tidyRoles: { |
| 364 | - awba: [{required: true, trigger: 'blur', validator: validatorAwb}], | ||
| 365 | - awbh: [{required: true, trigger: 'blur', validator: validatorAwbh}], | ||
| 366 | - goodsname: [{required: true, trigger: 'blur', validator: validAlphabetsSpanceKey}], | ||
| 367 | - carrier: [{required: true, trigger: 'blur', validator: validatorAwbh}], | ||
| 368 | - flightno: [{required: true, trigger: 'blur', validator: validatorAwbh}], | ||
| 369 | - originstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], | ||
| 370 | - destinationstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], | ||
| 371 | - weight: [{required: true, trigger: 'change', validator: validatorNums}], | ||
| 372 | - piece: [{required: true, trigger: 'change', validator: validatorNums}], | 430 | + awba: [{required: true, message: "主单号不能为空"},{ trigger: 'blur', validator: validatorAwb}], |
| 431 | + awbh: [{trigger: 'blur', validator: validatorAwbh}], | ||
| 432 | + goodsname: [{required: true, message: "货物描述不能为空"},{ trigger: 'blur', validator: validAlphabetsSpanceKey}], | ||
| 433 | + carrier: [{required: true, message:"承运人不能为空"},{trigger: 'blur', validator: validatorAwbh}], | ||
| 434 | + flightno: [{required: true, message:"航班号不能为空"}, { trigger: 'blur', validator: validatorAwbh}], | ||
| 435 | + originstation: [{required: true, message:"起始站不能为空"}, {trigger: 'blur', validator: validatorAlphabets}], | ||
| 436 | + destinationstation: [{required: true, message:"目的站不能为空"}, { trigger: 'blur', validator: validatorAlphabets}], | ||
| 437 | + weight: [{required: true, message:"重量不能为空"}, { trigger: 'change', validator: validatorNums}], | ||
| 438 | + piece: [{required: true, message:"件数不能为空"}, { trigger: 'change', validator: validatorNums}], | ||
| 439 | + | ||
| 373 | }, | 440 | }, |
| 374 | tidyData: [], | 441 | tidyData: [], |
| 375 | detailData: [], | 442 | detailData: [], |
| 376 | dialogTableVisible: false, | 443 | dialogTableVisible: false, |
| 444 | + dialogDeleteVisible: false, | ||
| 377 | dialogStatus: undefined, | 445 | dialogStatus: undefined, |
| 378 | disabledStatus: false, | 446 | disabledStatus: false, |
| 447 | + fenStatus: undefined, | ||
| 379 | listLoading: false, | 448 | listLoading: false, |
| 449 | + customLoading:false, | ||
| 380 | dialogFormVisible: false, | 450 | dialogFormVisible: false, |
| 381 | tidyModel: { | 451 | tidyModel: { |
| 382 | carrier: undefined, | 452 | carrier: undefined, |
| @@ -396,7 +466,27 @@ | @@ -396,7 +466,27 @@ | ||
| 396 | awbpiece: undefined, | 466 | awbpiece: undefined, |
| 397 | awbweight: undefined, | 467 | awbweight: undefined, |
| 398 | rcfdep: 'MT5202', | 468 | rcfdep: 'MT5202', |
| 399 | - } | 469 | + }, |
| 470 | + respModel : { | ||
| 471 | + uuid: undefined, | ||
| 472 | + reason: undefined, | ||
| 473 | + contactName: undefined, | ||
| 474 | + contactTel: undefined, | ||
| 475 | + content: '', | ||
| 476 | + flightNo: undefined, | ||
| 477 | + awba: undefined, | ||
| 478 | + customCode: undefined, | ||
| 479 | + flightDate: undefined, | ||
| 480 | + awbh: undefined, | ||
| 481 | + rcfdep: 'MT5202', | ||
| 482 | + }, | ||
| 483 | + tidyDeleteRules: { | ||
| 484 | + reason: [{required: true, message: '删除原因不能为空', trigger: 'blur'}], | ||
| 485 | + contactName: [{required: true, message: '删除操作人不能为空', trigger: 'blur'}], | ||
| 486 | + contactTel: [{required: true, message: '操作人联系方式不能为空', trigger: 'blur'}] | ||
| 487 | + }, | ||
| 488 | + | ||
| 489 | + rows:{}, | ||
| 400 | } | 490 | } |
| 401 | }, | 491 | }, |
| 402 | created() { | 492 | created() { |
| @@ -489,11 +579,11 @@ | @@ -489,11 +579,11 @@ | ||
| 489 | getList() { | 579 | getList() { |
| 490 | this.listLoading = true | 580 | this.listLoading = true |
| 491 | //根据是否有主单号 来给查询条件赋值 | 581 | //根据是否有主单号 来给查询条件赋值 |
| 492 | - if (this.tidyQuery.awba != undefined && this.tidyQuery.awba != '') { | 582 | + if (this.tidyQuery.awba !== undefined && this.tidyQuery.awba !== '') { |
| 493 | getMt520XListForParam(this.tidyQuery).then(res => { | 583 | getMt520XListForParam(this.tidyQuery).then(res => { |
| 494 | this.tidyData = res.data.dataList | 584 | this.tidyData = res.data.dataList |
| 495 | this.total = res.data.count | 585 | this.total = res.data.count |
| 496 | - if (res.data.count > 0) { | 586 | + if (res.data.dataList.length > 0) { |
| 497 | this.tidyQuery.carrier = this.tidyData[0].carrier | 587 | this.tidyQuery.carrier = this.tidyData[0].carrier |
| 498 | this.tidyQuery.flightno = this.tidyData[0].flightno | 588 | this.tidyQuery.flightno = this.tidyData[0].flightno |
| 499 | this.tidyQuery.flightdate = this.tidyData[0].flightdate | 589 | this.tidyQuery.flightdate = this.tidyData[0].flightdate |
| @@ -522,11 +612,11 @@ | @@ -522,11 +612,11 @@ | ||
| 522 | }, | 612 | }, |
| 523 | // 搜索 | 613 | // 搜索 |
| 524 | handleSerach() { | 614 | handleSerach() { |
| 525 | - this.tidyQuery.carrier = undefined | ||
| 526 | - this.tidyQuery.flightno = undefined | ||
| 527 | - this.tidyQuery.originstation = undefined | ||
| 528 | - this.tidyQuery.flightdate = undefined | ||
| 529 | - this.tidyQuery.destinationstation = undefined | 615 | + // this.tidyQuery.carrier = undefined |
| 616 | + // this.tidyQuery.flightno = undefined | ||
| 617 | + // this.tidyQuery.originstation = undefined | ||
| 618 | + // this.tidyQuery.flightdate = undefined | ||
| 619 | + // this.tidyQuery.destinationstation = undefined | ||
| 530 | this.getList() | 620 | this.getList() |
| 531 | }, | 621 | }, |
| 532 | // 收发明细 | 622 | // 收发明细 |
| @@ -535,22 +625,57 @@ | @@ -535,22 +625,57 @@ | ||
| 535 | carrier: row.carrier, | 625 | carrier: row.carrier, |
| 536 | flightNo: row.flightno, | 626 | flightNo: row.flightno, |
| 537 | flightDate: row.flightdate, | 627 | flightDate: row.flightdate, |
| 628 | + opertype: row.opertype, | ||
| 538 | awba: row.awba, | 629 | awba: row.awba, |
| 539 | awbh: row.awbh, | 630 | awbh: row.awbh, |
| 540 | - messageType: 'MT5202' | 631 | + rcfdep: 'MT5202' |
| 541 | } | 632 | } |
| 542 | this.dialogTableVisible = true | 633 | this.dialogTableVisible = true |
| 543 | getResponseForParam(resQuery).then(res => { | 634 | getResponseForParam(resQuery).then(res => { |
| 544 | this.detailData = res.data | 635 | this.detailData = res.data |
| 545 | }) | 636 | }) |
| 546 | }, | 637 | }, |
| 547 | - | ||
| 548 | //发送舱单报 | 638 | //发送舱单报 |
| 549 | handleAwbSend(row) { | 639 | handleAwbSend(row) { |
| 640 | + delete row.children | ||
| 641 | + delete row.parent | ||
| 642 | + this.rows = row; | ||
| 643 | + this.$confirm("是否发送", "确认消息", { | ||
| 644 | + distinguishCancelAndClose: true, | ||
| 645 | + confirmButtonText: '发送', | ||
| 646 | + cancelButtonText: '取消' | ||
| 647 | + }).then(() => { | ||
| 648 | + console.log(row) | ||
| 550 | 649 | ||
| 650 | + sendCreateMt5202(row).then(res => { | ||
| 651 | + if (res.data.count > 0) { | ||
| 652 | + Message.success(res.data.respMessage) | ||
| 653 | + // this.getList() | ||
| 654 | + this.rows.status="23"; | ||
| 655 | + this.rows.ext5="新增报发送成功"; | ||
| 656 | + }else { | ||
| 657 | + Message.error(res.data.respMessage) | ||
| 658 | + } | ||
| 659 | + }) | ||
| 660 | + }).catch(error =>{ | ||
| 661 | + Message.error(error.message) | ||
| 662 | + }) | ||
| 663 | + }, | ||
| 664 | + // 发送舱单报自灰 | ||
| 665 | + addStatus(status){ | ||
| 666 | + if(status=='23' || status=='24'||status=='25'){ | ||
| 667 | + return true; | ||
| 668 | + }else if(status=='22' ) { | ||
| 669 | + return false; | ||
| 670 | + } | ||
| 551 | }, | 671 | }, |
| 552 | //新增分单理货 | 672 | //新增分单理货 |
| 553 | handleAddAwbh(row) { | 673 | handleAddAwbh(row) { |
| 674 | + | ||
| 675 | + this.fenStatus='addAwbh' | ||
| 676 | + // 清空from列表 | ||
| 677 | + this.restModel(); | ||
| 678 | + | ||
| 554 | this.tidyModel.carrier = row.carrier | 679 | this.tidyModel.carrier = row.carrier |
| 555 | this.tidyModel.awba = row.awba | 680 | this.tidyModel.awba = row.awba |
| 556 | this.tidyModel.flightdate = row.flightdate | 681 | this.tidyModel.flightdate = row.flightdate |
| @@ -558,12 +683,71 @@ | @@ -558,12 +683,71 @@ | ||
| 558 | this.tidyModel.originstation = row.originstation | 683 | this.tidyModel.originstation = row.originstation |
| 559 | this.tidyModel.destinationstation = row.destinationstation | 684 | this.tidyModel.destinationstation = row.destinationstation |
| 560 | this.tidyModel.customcode = row.customcode | 685 | this.tidyModel.customcode = row.customcode |
| 561 | - this.dialogStatus = 'addAwbh' | 686 | + // this.dialogStatus = 'addAwbh' |
| 687 | + this.dialogStatus = 'create' | ||
| 562 | this.dialogFormVisible = true | 688 | this.dialogFormVisible = true |
| 563 | this.$nextTick(() => { | 689 | this.$nextTick(() => { |
| 564 | this.$refs.tidyFormData.clearValidate() | 690 | this.$refs.tidyFormData.clearValidate() |
| 565 | }) | 691 | }) |
| 566 | }, | 692 | }, |
| 693 | + // 发删除报 | ||
| 694 | + handleSendDelete(row){ | ||
| 695 | + | ||
| 696 | + this.rows = row; | ||
| 697 | + | ||
| 698 | + this.respModel = { | ||
| 699 | + carrier: undefined, | ||
| 700 | + reason: undefined, | ||
| 701 | + contactName: undefined, | ||
| 702 | + contactTel: undefined, | ||
| 703 | + content: '', | ||
| 704 | + flightNo: undefined, | ||
| 705 | + awba: undefined, | ||
| 706 | + customCode: undefined, | ||
| 707 | + flightDate: undefined, | ||
| 708 | + awbh: undefined, | ||
| 709 | + rcfdep: 'MT5202', | ||
| 710 | + } | ||
| 711 | + this.dialogDeleteVisible = true | ||
| 712 | + this.respModel.carrier = row.carrier | ||
| 713 | + this.respModel.flightNo = row.flightno | ||
| 714 | + this.respModel.awba = row.awba | ||
| 715 | + this.respModel.customCode = row.customcode | ||
| 716 | + this.respModel.flightDate = row.flightdate | ||
| 717 | + if(row.awbh === null){ | ||
| 718 | + this.respModel.awbh = '' | ||
| 719 | + }else { | ||
| 720 | + this.respModel.awbh = row.awbh | ||
| 721 | + } | ||
| 722 | + this.$nextTick(() => { | ||
| 723 | + this.$refs.tidyDeleteForm.clearValidate() | ||
| 724 | + }) | ||
| 725 | + }, | ||
| 726 | + // 删除舱单报自灰 | ||
| 727 | + deleteStatus(status){ | ||
| 728 | + if(status=='23' || status=='24'||status=='25'){ | ||
| 729 | + return true; | ||
| 730 | + }else if(status=='22' ) { | ||
| 731 | + return false; | ||
| 732 | + } | ||
| 733 | + }, | ||
| 734 | + // 发送删除报 | ||
| 735 | + sendTidyDelete(){ | ||
| 736 | + this.$refs.tidyDeleteForm.validate(valid =>{ | ||
| 737 | + if(valid){ | ||
| 738 | + sendRemoveMt5202(this.respModel).then(res =>{ | ||
| 739 | + if(res.data.count >0){ | ||
| 740 | + Message.success(res.data.respMessage) | ||
| 741 | + this.dialogDeleteVisible = false | ||
| 742 | + this.rows.status="24"; | ||
| 743 | + this.rows.ext5="删除报发送成功"; | ||
| 744 | + }else { | ||
| 745 | + Message.error(res.data.respMessage) | ||
| 746 | + } | ||
| 747 | + }) | ||
| 748 | + } | ||
| 749 | + }) | ||
| 750 | + }, | ||
| 567 | // 删除当前运单 | 751 | // 删除当前运单 |
| 568 | handleAwbDelete(row) { | 752 | handleAwbDelete(row) { |
| 569 | delete row.parent | 753 | delete row.parent |
| @@ -575,16 +759,10 @@ | @@ -575,16 +759,10 @@ | ||
| 575 | }).then(() => { | 759 | }).then(() => { |
| 576 | deleteByIsDelete(row).then(res => { | 760 | deleteByIsDelete(row).then(res => { |
| 577 | if (res.data.count > 0) { | 761 | if (res.data.count > 0) { |
| 578 | - this.$message({ | ||
| 579 | - type: 'success', | ||
| 580 | - message: '删除成功' | ||
| 581 | - }) | 762 | + Message.success("删除成功") |
| 582 | this.getList() | 763 | this.getList() |
| 583 | } else { | 764 | } else { |
| 584 | - this.$message({ | ||
| 585 | - type: 'error', | ||
| 586 | - message: '删除异常,请稍后重试' | ||
| 587 | - }) | 765 | + Message.success("删除异常,请稍后重试") |
| 588 | } | 766 | } |
| 589 | }) | 767 | }) |
| 590 | }).catch(action => { | 768 | }).catch(action => { |
| @@ -599,27 +777,23 @@ | @@ -599,27 +777,23 @@ | ||
| 599 | }, | 777 | }, |
| 600 | // 更新运单为可发送状态 | 778 | // 更新运单为可发送状态 |
| 601 | handleAwbStatus(row) { | 779 | handleAwbStatus(row) { |
| 602 | - delete row.parent | ||
| 603 | - delete row.children | 780 | + |
| 604 | this.$confirm("是否发送更改状态", "确认消息", { | 781 | this.$confirm("是否发送更改状态", "确认消息", { |
| 605 | distinguishCancelAndClose: true, | 782 | distinguishCancelAndClose: true, |
| 606 | confirmButtonText: '确认更改', | 783 | confirmButtonText: '确认更改', |
| 607 | cancelButtonText: '取消更改' | 784 | cancelButtonText: '取消更改' |
| 608 | }).then(() => { | 785 | }).then(() => { |
| 609 | - updateStatus(row).then(res => { | ||
| 610 | - if (res.data.count > 0) { | ||
| 611 | - this.$message({ | ||
| 612 | - type: 'success', | ||
| 613 | - message: '当前运单状态已更改' | ||
| 614 | - }) | ||
| 615 | - this.getList() | ||
| 616 | - } else { | ||
| 617 | - this.$message({ | ||
| 618 | - type: 'error', | ||
| 619 | - message: '更新失败,请稍后重试' | ||
| 620 | - }) | ||
| 621 | - } | ||
| 622 | - }) | 786 | + if (row.status!==22){ |
| 787 | + row.status =22; | ||
| 788 | + } | ||
| 789 | + // updateStatus(row).then(res => { | ||
| 790 | + // if (res.data.count > 0) { | ||
| 791 | + // Message.success(res.data.respMessage) | ||
| 792 | + // this.getList() | ||
| 793 | + // } else { | ||
| 794 | + // Message.error(res.data.respMessage) | ||
| 795 | + // } | ||
| 796 | + // }) | ||
| 623 | }).catch(action => { | 797 | }).catch(action => { |
| 624 | this.$message({ | 798 | this.$message({ |
| 625 | type: 'info', | 799 | type: 'info', |
| @@ -654,6 +828,7 @@ | @@ -654,6 +828,7 @@ | ||
| 654 | }, | 828 | }, |
| 655 | // 新增出港理货弹框 | 829 | // 新增出港理货弹框 |
| 656 | handelAddTidyInfo() { | 830 | handelAddTidyInfo() { |
| 831 | + this.fenStatus=undefined; | ||
| 657 | this.restModel() | 832 | this.restModel() |
| 658 | // 给model赋值,所使用数据是以单独单号查询数据所得 | 833 | // 给model赋值,所使用数据是以单独单号查询数据所得 |
| 659 | this.tidyModel.carrier = this.tidyQuery.carrier | 834 | this.tidyModel.carrier = this.tidyQuery.carrier |
| @@ -686,6 +861,11 @@ | @@ -686,6 +861,11 @@ | ||
| 686 | }, | 861 | }, |
| 687 | // 更新出港理货弹框 | 862 | // 更新出港理货弹框 |
| 688 | handleEdit(row) { | 863 | handleEdit(row) { |
| 864 | + if(row.awbh !==''){ | ||
| 865 | + this.fenStatus='addAwbh' | ||
| 866 | + }else { | ||
| 867 | + this.fenStatus=undefined | ||
| 868 | + } | ||
| 689 | this.tidyModel = Object.assign({}, row) | 869 | this.tidyModel = Object.assign({}, row) |
| 690 | this.dialogStatus = 'update' | 870 | this.dialogStatus = 'update' |
| 691 | this.dialogFormVisible = true | 871 | this.dialogFormVisible = true |
| @@ -712,20 +892,51 @@ | @@ -712,20 +892,51 @@ | ||
| 712 | } | 892 | } |
| 713 | }) | 893 | }) |
| 714 | }, | 894 | }, |
| 715 | - // 保存并发送 | ||
| 716 | - handleSaveAndSend() { | ||
| 717 | - | 895 | + // 获取机场三字码 |
| 896 | + remoteMethodAirport(query){ | ||
| 897 | + this.airportCode = [] | ||
| 898 | + if (query !== '') { | ||
| 899 | + this.listLoading = true | ||
| 900 | + getAirportCode({airportid: query}).then(res => { | ||
| 901 | + if(res !== null){ | ||
| 902 | + setTimeout(() => { | ||
| 903 | + this.listLoading = false | ||
| 904 | + this.airportCode = res.data.data | ||
| 905 | + }, 200) | ||
| 906 | + } | ||
| 907 | + }) | ||
| 908 | + } else { | ||
| 909 | + this.airportCode = [] | ||
| 910 | + } | ||
| 911 | + }, | ||
| 912 | + // 关区代码 | ||
| 913 | + remoteMethodCustomCode(query){ | ||
| 914 | + this.customCodeList = [] | ||
| 915 | + if (query !== '') { | ||
| 916 | + this.customLoading = true | ||
| 917 | + getCustomCode({customcode: query}).then(res => { | ||
| 918 | + if(res !== null){ | ||
| 919 | + setTimeout(() => { | ||
| 920 | + this.customLoading = false | ||
| 921 | + this.customCodeList = res.data.data | ||
| 922 | + }, 200) | ||
| 923 | + } | ||
| 924 | + }) | ||
| 925 | + } else { | ||
| 926 | + this.airportCode = [] | ||
| 927 | + } | ||
| 718 | }, | 928 | }, |
| 719 | // 新增理货弹框 | 929 | // 新增理货弹框 |
| 720 | handleAddTidy() { | 930 | handleAddTidy() { |
| 721 | - const row = { | ||
| 722 | - 'messageType': 'MT5201' | 931 | + const query = { |
| 932 | + 'messageType': 'MT5202' | ||
| 723 | } | 933 | } |
| 724 | - this.$router.push({name: '出港航班信息', params: {scopeRow: row}}) | 934 | + this.$router.push({name: '出港航班信息', params: {scopeRow: query}}) |
| 725 | }, | 935 | }, |
| 726 | // 返回 | 936 | // 返回 |
| 727 | handelBackStep() { | 937 | handelBackStep() { |
| 728 | - this.$router.push({name: '出港航班信息', params: {scopeRow: this.tidyModel}}) | 938 | + this.tidyQuery.rcfdep = 'MT5202' |
| 939 | + this.$router.push({name: '出港航班信息', params: {scopeRow: this.tidyQuery}}) | ||
| 729 | } | 940 | } |
| 730 | } | 941 | } |
| 731 | } | 942 | } |
| @@ -466,6 +466,7 @@ | @@ -466,6 +466,7 @@ | ||
| 466 | import {Message} from "element-ui"; | 466 | import {Message} from "element-ui"; |
| 467 | 467 | ||
| 468 | import {validAwb, validFlightNo} from '@/utils/validate' | 468 | import {validAwb, validFlightNo} from '@/utils/validate' |
| 469 | + import util from '@/common/js/util' | ||
| 469 | 470 | ||
| 470 | export default { | 471 | export default { |
| 471 | name: 'OrgManifest', | 472 | name: 'OrgManifest', |
| @@ -823,7 +824,7 @@ | @@ -823,7 +824,7 @@ | ||
| 823 | }, | 824 | }, |
| 824 | by1: { | 825 | by1: { |
| 825 | get: function () { | 826 | get: function () { |
| 826 | - return this.temp.awbinfo.by1 | 827 | + return util.checkNull(this.temp.awbinfo.by1)?'':this.temp.awbinfo.by1 |
| 827 | }, | 828 | }, |
| 828 | set: function (val) { | 829 | set: function (val) { |
| 829 | this.temp.awbinfo.by1 = val.toUpperCase().trim() | 830 | this.temp.awbinfo.by1 = val.toUpperCase().trim() |
| @@ -74,6 +74,7 @@ | @@ -74,6 +74,7 @@ | ||
| 74 | <el-col :span="24"> | 74 | <el-col :span="24"> |
| 75 | <template> | 75 | <template> |
| 76 | <el-table | 76 | <el-table |
| 77 | + v-loading="listLoading" | ||
| 77 | ref="multipleTable" | 78 | ref="multipleTable" |
| 78 | :data="tableData" | 79 | :data="tableData" |
| 79 | tooltip-effect="dark" | 80 | tooltip-effect="dark" |
| @@ -81,9 +82,8 @@ | @@ -81,9 +82,8 @@ | ||
| 81 | <el-table-column | 82 | <el-table-column |
| 82 | fixed="left" | 83 | fixed="left" |
| 83 | label="修改状态" | 84 | label="修改状态" |
| 84 | - width="140"> | 85 | + width="100"> |
| 85 | <template slot-scope="scope"> | 86 | <template slot-scope="scope"> |
| 86 | - <el-button @click="handleClick(scope.row)" type="text" size="small">修改状态</el-button> | ||
| 87 | <el-button v-if="scope.row.turntype=='MT6202'" type="text" @click="seeimport(scope.row)" size="mini">分拨申请</el-button> | 87 | <el-button v-if="scope.row.turntype=='MT6202'" type="text" @click="seeimport(scope.row)" size="mini">分拨申请</el-button> |
| 88 | <el-button v-else type="text" @click="seearrive(scope.row)" size="mini">分拨运抵</el-button> | 88 | <el-button v-else type="text" @click="seearrive(scope.row)" size="mini">分拨运抵</el-button> |
| 89 | </template> | 89 | </template> |
| @@ -131,39 +131,54 @@ | @@ -131,39 +131,54 @@ | ||
| 131 | <el-table-column | 131 | <el-table-column |
| 132 | prop="status" | 132 | prop="status" |
| 133 | label="状态" | 133 | label="状态" |
| 134 | - width="100"> | 134 | + width="100" :formatter="formatStatus"> |
| 135 | </el-table-column> | 135 | </el-table-column> |
| 136 | <el-table-column | 136 | <el-table-column |
| 137 | - prop="repick" | ||
| 138 | label="回执内容" | 137 | label="回执内容" |
| 139 | width="250"> | 138 | width="250"> |
| 139 | + <template slot-scope="scope"> | ||
| 140 | + <span v-if="scope.row.status=='01' || scope.row.status=='11'" style="color: #67C23A"> | ||
| 141 | + {{scope.row.ext5}} | ||
| 142 | + </span> | ||
| 143 | + <span v-else-if="scope.row.status=='02' || scope.row.status=='03'" style="color: #E6A23C"> | ||
| 144 | + {{scope.row.ext5}} | ||
| 145 | + </span> | ||
| 146 | + <span v-else-if="scope.row.status=='12' || scope.row.status=='13'" style="color: #F56C6C"> | ||
| 147 | + {{scope.row.ext5}} | ||
| 148 | + </span> | ||
| 149 | + <span v-else style="color: #909399;"> | ||
| 150 | + {{scope.row.ext5}} | ||
| 151 | + </span> | ||
| 152 | + </template> | ||
| 140 | </el-table-column> | 153 | </el-table-column> |
| 141 | <el-table-column | 154 | <el-table-column |
| 142 | label="修改状态" | 155 | label="修改状态" |
| 143 | - width="400"> | 156 | + width="550"> |
| 144 | <template slot-scope="scope"> | 157 | <template slot-scope="scope"> |
| 145 | <el-button | 158 | <el-button |
| 146 | v-if="scope.row.turntype=='MT6202'" | 159 | v-if="scope.row.turntype=='MT6202'" |
| 147 | size="mini" | 160 | size="mini" |
| 148 | type="primary" | 161 | type="primary" |
| 149 | - @click="importDetail(scope.$index, scope.row)">收发明细 | 162 | + @click="handleDetail(scope.$index, scope.row)">收发明细 |
| 150 | </el-button> | 163 | </el-button> |
| 151 | <el-button | 164 | <el-button |
| 152 | v-else | 165 | v-else |
| 153 | size="mini" | 166 | size="mini" |
| 154 | type="primary" | 167 | type="primary" |
| 155 | - @click="arriveDetail(scope.$index, scope.row)">收发明细 | 168 | + @click="handleDetail(scope.$index, scope.row)">收发明细 |
| 156 | </el-button> | 169 | </el-button> |
| 157 | <el-button | 170 | <el-button |
| 158 | v-if="scope.row.turntype=='MT6202'" | 171 | v-if="scope.row.turntype=='MT6202'" |
| 159 | size="mini" | 172 | size="mini" |
| 160 | type="primary" | 173 | type="primary" |
| 174 | + :disabled="btSendStatusFormater(scope.row.status)" | ||
| 161 | @click="importSend(scope.$index, scope.row)">申请分拨 | 175 | @click="importSend(scope.$index, scope.row)">申请分拨 |
| 162 | </el-button> | 176 | </el-button> |
| 163 | <el-button | 177 | <el-button |
| 164 | v-else | 178 | v-else |
| 165 | size="mini" | 179 | size="mini" |
| 166 | type="primary" | 180 | type="primary" |
| 181 | + :disabled="btSendStatusFormater(scope.row.status)" | ||
| 167 | @click="arriveSend(scope.$index, scope.row)">分拨运抵 | 182 | @click="arriveSend(scope.$index, scope.row)">分拨运抵 |
| 168 | </el-button> | 183 | </el-button> |
| 169 | <el-button | 184 | <el-button |
| @@ -182,14 +197,21 @@ | @@ -182,14 +197,21 @@ | ||
| 182 | v-if="scope.row.turntype=='MT6202'" | 197 | v-if="scope.row.turntype=='MT6202'" |
| 183 | size="mini" | 198 | size="mini" |
| 184 | type="primary" | 199 | type="primary" |
| 185 | - @click="arriveDel(scope.$index, scope.row)">申请分拨删除 | 200 | + :disabled="btDeleStatusFormater(scope.row.status)" |
| 201 | + @click="importDel(scope.$index, scope.row)">申请分拨删除 | ||
| 186 | </el-button> | 202 | </el-button> |
| 187 | <el-button | 203 | <el-button |
| 188 | v-else | 204 | v-else |
| 189 | size="mini" | 205 | size="mini" |
| 190 | type="primary" | 206 | type="primary" |
| 207 | + :disabled="btDeleStatusFormater(scope.row.status)" | ||
| 191 | @click="arriveDel(scope.$index, scope.row)">分拨运抵删除 | 208 | @click="arriveDel(scope.$index, scope.row)">分拨运抵删除 |
| 192 | </el-button> | 209 | </el-button> |
| 210 | + <el-button | ||
| 211 | + size="mini" | ||
| 212 | + type="primary" | ||
| 213 | + @click="UpdateStatus(scope.$index, scope.row)">更改状态 | ||
| 214 | + </el-button> | ||
| 193 | </template> | 215 | </template> |
| 194 | </el-table-column> | 216 | </el-table-column> |
| 195 | </el-table> | 217 | </el-table> |
| @@ -203,11 +225,11 @@ | @@ -203,11 +225,11 @@ | ||
| 203 | <el-pagination | 225 | <el-pagination |
| 204 | @size-change="handleSizeChange" | 226 | @size-change="handleSizeChange" |
| 205 | @current-change="handleCurrentChange" | 227 | @current-change="handleCurrentChange" |
| 206 | - :current-page="currentPage4" | 228 | + :current-page="currentPage" |
| 207 | :page-sizes="[100, 200, 300, 400]" | 229 | :page-sizes="[100, 200, 300, 400]" |
| 208 | - :page-size="100" | 230 | + :page-size="pageSize" |
| 209 | layout="total, sizes, prev, pager, next, jumper" | 231 | layout="total, sizes, prev, pager, next, jumper" |
| 210 | - :total="400"> | 232 | + :total="total"> |
| 211 | </el-pagination> | 233 | </el-pagination> |
| 212 | </div> | 234 | </div> |
| 213 | </el-col> | 235 | </el-col> |
| @@ -279,20 +301,20 @@ | @@ -279,20 +301,20 @@ | ||
| 279 | <el-col :span="5"> | 301 | <el-col :span="5"> |
| 280 | <el-form-item label="运抵件数" prop="turnpiece"> | 302 | <el-form-item label="运抵件数" prop="turnpiece"> |
| 281 | <div v-if="dialogStatus === 'update'"> | 303 | <div v-if="dialogStatus === 'update'"> |
| 282 | - <el-input v-model="AruleForm.turnpiece"></el-input> | 304 | + <el-input type="number" v-model="AruleForm.turnpiece"></el-input> |
| 283 | </div> | 305 | </div> |
| 284 | <div v-else> | 306 | <div v-else> |
| 285 | - <el-input disabled="" v-model="AruleForm.turnpiece"></el-input> | 307 | + <el-input type="number" disabled="" v-model="AruleForm.turnpiece"></el-input> |
| 286 | </div> | 308 | </div> |
| 287 | </el-form-item> | 309 | </el-form-item> |
| 288 | </el-col> | 310 | </el-col> |
| 289 | <el-col :span="5"> | 311 | <el-col :span="5"> |
| 290 | <el-form-item label="运抵重量" prop="turnweight"> | 312 | <el-form-item label="运抵重量" prop="turnweight"> |
| 291 | <div v-if="dialogStatus === 'update'"> | 313 | <div v-if="dialogStatus === 'update'"> |
| 292 | - <el-input v-model="AruleForm.turnweight"></el-input> | 314 | + <el-input type="number" v-model="AruleForm.turnweight"></el-input> |
| 293 | </div> | 315 | </div> |
| 294 | <div v-else> | 316 | <div v-else> |
| 295 | - <el-input disabled="" v-model="AruleForm.turnweight"></el-input> | 317 | + <el-input type="number" disabled="" v-model="AruleForm.turnweight"></el-input> |
| 296 | </div> | 318 | </div> |
| 297 | </el-form-item> | 319 | </el-form-item> |
| 298 | </el-col> | 320 | </el-col> |
| @@ -424,6 +446,26 @@ | @@ -424,6 +446,26 @@ | ||
| 424 | </div> | 446 | </div> |
| 425 | </el-form-item> | 447 | </el-form-item> |
| 426 | </el-col> | 448 | </el-col> |
| 449 | + <el-col :span="5"> | ||
| 450 | + <el-form-item label="卸货地" prop="ext2"> | ||
| 451 | + <div v-if="dialogStatus === 'update'"> | ||
| 452 | + <el-input v-model="IruleForm.ext2"></el-input> | ||
| 453 | + </div> | ||
| 454 | + <div v-else> | ||
| 455 | + <el-input disabled="" v-model="IruleForm.ext2"></el-input> | ||
| 456 | + </div> | ||
| 457 | + </el-form-item> | ||
| 458 | + </el-col> | ||
| 459 | + <el-col :span="5"> | ||
| 460 | + <el-form-item label="车辆所属" prop="ext1"> | ||
| 461 | + <div v-if="dialogStatus === 'update'"> | ||
| 462 | + <el-input v-model="IruleForm.ext1"></el-input> | ||
| 463 | + </div> | ||
| 464 | + <div v-else> | ||
| 465 | + <el-input disabled="" v-model="IruleForm.ext1"></el-input> | ||
| 466 | + </div> | ||
| 467 | + </el-form-item> | ||
| 468 | + </el-col> | ||
| 427 | </el-row> | 469 | </el-row> |
| 428 | </el-form> | 470 | </el-form> |
| 429 | </el-dialog> | 471 | </el-dialog> |
| @@ -441,6 +483,38 @@ | @@ -441,6 +483,38 @@ | ||
| 441 | </span> | 483 | </span> |
| 442 | </el-dialog> | 484 | </el-dialog> |
| 443 | </el-row> | 485 | </el-row> |
| 486 | + <!--发送删除报修改报提示框--> | ||
| 487 | + <el-row> | ||
| 488 | + <el-dialog :title="'提交'+Reason[udStatus]+'信息'" :visible.sync="dialogFormVisible"> | ||
| 489 | + <el-form :model="Udform" :rules="udrules" ref="Udform" class="demo-ruleForm"> | ||
| 490 | + <el-form-item label="操作原因" prop="operreason"> | ||
| 491 | + <el-input type="textarea" v-model="Udform.operreason"></el-input> | ||
| 492 | + </el-form-item> | ||
| 493 | + <el-form-item label="操作人" prop="operperson"> | ||
| 494 | + <el-input v-model="Udform.operperson"></el-input> | ||
| 495 | + </el-form-item> | ||
| 496 | + <el-form-item label="联系电话" prop="opertel"> | ||
| 497 | + <el-input v-model="Udform.opertel"></el-input> | ||
| 498 | + </el-form-item> | ||
| 499 | + </el-form> | ||
| 500 | + <div slot="footer" class="dialog-footer"> | ||
| 501 | + <el-button @click="dialogFormVisible = false">取 消</el-button> | ||
| 502 | + <el-button type="primary" @click="deleteIdForm('Udform')">确 定</el-button> | ||
| 503 | + </div> | ||
| 504 | + </el-dialog> | ||
| 505 | + </el-row> | ||
| 506 | + <!--明细列表弹出框--> | ||
| 507 | + <el-row> | ||
| 508 | + <el-dialog title="回执明细列表" :visible.sync="dialogTableVisible" width="70%"> | ||
| 509 | + <el-table :data="gridData"> | ||
| 510 | + <el-table-column property="busdate" label="时间" width="160"></el-table-column> | ||
| 511 | + <el-table-column property="username" label="操作人" width="130"></el-table-column> | ||
| 512 | + <el-table-column property="buspiece" label="发送件数" width="130"></el-table-column> | ||
| 513 | + <el-table-column property="busweight" label="发送重量" width="130"></el-table-column> | ||
| 514 | + <el-table-column property="cusrestext" label="回执内容"></el-table-column> | ||
| 515 | + </el-table> | ||
| 516 | + </el-dialog> | ||
| 517 | + </el-row> | ||
| 444 | </el-main> | 518 | </el-main> |
| 445 | </el-container> | 519 | </el-container> |
| 446 | </template> | 520 | </template> |
| @@ -452,9 +526,13 @@ | @@ -452,9 +526,13 @@ | ||
| 452 | .sel{display: inline;} | 526 | .sel{display: inline;} |
| 453 | .mark{height:24px;} | 527 | .mark{height:24px;} |
| 454 | .bg{height:24px;text-align: center;line-height:24px;min-height: 24px} | 528 | .bg{height:24px;text-align: center;line-height:24px;min-height: 24px} |
| 529 | + .el-input-group{ | ||
| 530 | + display: table; | ||
| 531 | + } | ||
| 455 | </style> | 532 | </style> |
| 456 | <script> | 533 | <script> |
| 457 | - import { QueryData,ediAllocat } from '../../api/Allocat' | 534 | + import{addResponse,selectResponseList} from "../../api/InResponse"; |
| 535 | + import { QueryData,ediAllocat,sendCreateMt6202,sendRemoveMt6202,sendCreateMt3202,sendRemoveMt3202 } from '../../api/Allocat' | ||
| 458 | export default{ | 536 | export default{ |
| 459 | data(){ | 537 | data(){ |
| 460 | return{ | 538 | return{ |
| @@ -494,7 +572,8 @@ | @@ -494,7 +572,8 @@ | ||
| 494 | }, { | 572 | }, { |
| 495 | value: '08', | 573 | value: '08', |
| 496 | label: '舱单删除报转人工' | 574 | label: '舱单删除报转人工' |
| 497 | - }], | 575 | + } |
| 576 | + ], | ||
| 498 | options2: [ | 577 | options2: [ |
| 499 | { | 578 | { |
| 500 | value: '', | 579 | value: '', |
| @@ -505,7 +584,8 @@ | @@ -505,7 +584,8 @@ | ||
| 505 | }, { | 584 | }, { |
| 506 | value: 'MT3202', | 585 | value: 'MT3202', |
| 507 | label: '分拨运抵' | 586 | label: '分拨运抵' |
| 508 | - }], | 587 | + } |
| 588 | + ], | ||
| 509 | options3: [ | 589 | options3: [ |
| 510 | { | 590 | { |
| 511 | value: '4604', | 591 | value: '4604', |
| @@ -520,7 +600,9 @@ | @@ -520,7 +600,9 @@ | ||
| 520 | tableData: [], | 600 | tableData: [], |
| 521 | multipleSelection: [], | 601 | multipleSelection: [], |
| 522 | labelPosition:'left', | 602 | labelPosition:'left', |
| 523 | - currentPage4: 4, | 603 | + currentPage:1, |
| 604 | + pageSize:100, | ||
| 605 | + total:0, | ||
| 524 | dialogStatus:'', | 606 | dialogStatus:'', |
| 525 | IouterVisible: false, | 607 | IouterVisible: false, |
| 526 | AouterVisible: false, | 608 | AouterVisible: false, |
| @@ -540,7 +622,9 @@ | @@ -540,7 +622,9 @@ | ||
| 540 | turnpiece:'', | 622 | turnpiece:'', |
| 541 | turnweight:'', | 623 | turnweight:'', |
| 542 | turnunloading:'', | 624 | turnunloading:'', |
| 543 | - goodsname:'' | 625 | + goodsname:'', |
| 626 | + ext2:'', | ||
| 627 | + ext1:'' | ||
| 544 | }, | 628 | }, |
| 545 | Arules: { | 629 | Arules: { |
| 546 | awba: [ | 630 | awba: [ |
| @@ -580,7 +664,9 @@ | @@ -580,7 +664,9 @@ | ||
| 580 | turnpiece:undefined, | 664 | turnpiece:undefined, |
| 581 | turnweight:undefined, | 665 | turnweight:undefined, |
| 582 | turnunloading:undefined, | 666 | turnunloading:undefined, |
| 583 | - pno:undefined | 667 | + pno:undefined, |
| 668 | + ext1:undefined, | ||
| 669 | + ext2:undefined | ||
| 584 | }, | 670 | }, |
| 585 | Irules: { | 671 | Irules: { |
| 586 | awba: [ | 672 | awba: [ |
| @@ -610,33 +696,267 @@ | @@ -610,33 +696,267 @@ | ||
| 610 | turnunLoading: [ | 696 | turnunLoading: [ |
| 611 | { required: true, message: '请选择分拨到达地', trigger: 'change' } | 697 | { required: true, message: '请选择分拨到达地', trigger: 'change' } |
| 612 | ], | 698 | ], |
| 699 | + ext2: [ | ||
| 700 | + { required: true, message: '请输入卸货地代码', trigger: 'change' } | ||
| 701 | + ], | ||
| 702 | + ext1: [ | ||
| 703 | + { required: true, message: '请输入车辆所属承运人代码', trigger: 'change' } | ||
| 704 | + ], | ||
| 613 | }, | 705 | }, |
| 706 | + Udform:{ | ||
| 707 | + operreason:'', | ||
| 708 | + operperson:'', | ||
| 709 | + opertel:'', | ||
| 710 | + flightdate:'', | ||
| 711 | + flightno:'', | ||
| 712 | + carrier:'', | ||
| 713 | + awbano:'', | ||
| 714 | + awbhno:'', | ||
| 715 | + bustype:'', | ||
| 716 | + busdate:'', | ||
| 717 | + busweight:'', | ||
| 718 | + buspiece:'', | ||
| 719 | + opertype:'', | ||
| 720 | + }, | ||
| 721 | + udrules:{ | ||
| 722 | + operreason: [{required: true, message: '请输入操作原因', trigger: 'blur'}], | ||
| 723 | + operperson: [{required: true, message: '请输入操作人', trigger: 'blur'}], | ||
| 724 | + opertel: [{required: true, message: '请输入操作人联系电话', trigger: 'blur'}], | ||
| 725 | + }, | ||
| 726 | + Reason:{ | ||
| 727 | + update: '修改', | ||
| 728 | + delete: '删除' | ||
| 729 | + }, | ||
| 730 | + udStatus:'', | ||
| 731 | + dialogFormVisible: false, | ||
| 732 | + rows:{}, | ||
| 733 | + loading:false, | ||
| 734 | + dialogTableVisible:false, | ||
| 735 | + gridData:[], | ||
| 736 | + listLoading:false | ||
| 614 | } | 737 | } |
| 615 | }, | 738 | }, |
| 616 | methods:{ | 739 | methods:{ |
| 740 | + //更改状态 | ||
| 741 | + UpdateStatus(column,row){ | ||
| 742 | + this.$confirm("是否发送更改状态", "确认消息", { | ||
| 743 | + distinguishCancelAndClose: true, | ||
| 744 | + confirmButtonText: '确认更改', | ||
| 745 | + cancelButtonText: '取消更改' | ||
| 746 | + }).then(() => { | ||
| 747 | + row.status = '22'; | ||
| 748 | + }).catch(action => { | ||
| 749 | + this.$message({ | ||
| 750 | + type: 'info', | ||
| 751 | + message: action === 'cancel' | ||
| 752 | + ? '取消状态更改' | ||
| 753 | + : '状态更改取消' | ||
| 754 | + }) | ||
| 755 | + }) | ||
| 756 | + }, | ||
| 757 | + //回执收发明细 | ||
| 758 | + handleDetail(index,row){ | ||
| 759 | + if(row.flightno.length>4){ | ||
| 760 | + row.flightno=row.flightno.substring(2); | ||
| 761 | + } | ||
| 762 | + let params={awbano:row.awba,awbhno:row.awbh,carrier:row.carrier,flightno:row.flightno,flightdate:row.flightdate,bustype:row.turntype} | ||
| 763 | + selectResponseList(params).then(res=>{ | ||
| 764 | + this.dialogTableVisible=true; | ||
| 765 | + let response=res.data.data; | ||
| 766 | + this.gridData=response; | ||
| 767 | + }); | ||
| 768 | + }, | ||
| 769 | + //状态适配 | ||
| 770 | + formatStatus:function (row,column) { | ||
| 771 | + return row.status=='01'?'接受申报':row.status=='02'?'待人工审核':row.status=='03'?'退单' | ||
| 772 | + :row.status=='11'?'放行':row.status=='12'?'拒装':row.status=='13'?'禁卸' | ||
| 773 | + :row.status=='21'?'可自动发送':row.status=='22'?'未发送':row.status=='23'?'已发送新增报' | ||
| 774 | + :row.status=='24'?'已发送删除报':row.status=='25'?'已发送修改报':''; | ||
| 775 | + }, | ||
| 776 | + //发送舱单报按钮判定事件 | ||
| 777 | + btSendStatusFormater:(status) => { | ||
| 778 | + if(status=='23' || status=='24'||status=='25'){ | ||
| 779 | + return true; | ||
| 780 | + }else if(status=='22' ) { | ||
| 781 | + return false; | ||
| 782 | + } | ||
| 783 | + }, | ||
| 784 | + btDeleStatusFormater:(status) => { | ||
| 785 | + if(status=='23' || status=='24'||status=='25'){ | ||
| 786 | + return true; | ||
| 787 | + }else if(status=='22' ) { | ||
| 788 | + return false; | ||
| 789 | + } | ||
| 790 | + }, | ||
| 791 | + //发送分拨申请报 | ||
| 792 | + importSend(index,row){ | ||
| 793 | + const map = {'mt6202':row} | ||
| 794 | + sendCreateMt6202(map).then(res=>{ | ||
| 795 | + let response=res.data; | ||
| 796 | + //console.log(res); | ||
| 797 | + this.code=response.code; | ||
| 798 | + if(this.code=='200'){ | ||
| 799 | + row.status='23' | ||
| 800 | + row.ext5='分拨申请发送成功'; | ||
| 801 | + this.outerVisible = false; | ||
| 802 | + this.centerDialogVisible=true; | ||
| 803 | + this.msg=response.msg; | ||
| 804 | + }else{ | ||
| 805 | + this.outerVisible = false; | ||
| 806 | + this.centerDialogVisible=true; | ||
| 807 | + this.msg=response.msg; | ||
| 808 | + } | ||
| 809 | + }); | ||
| 810 | + }, | ||
| 811 | + //发送分拨申请删除报 | ||
| 812 | + importDel(index,row){ | ||
| 813 | + this.dialogFormVisible=true; | ||
| 814 | + this.udStatus='delete'; | ||
| 815 | + this.Udform.awbano=row.awba; | ||
| 816 | + this.Udform.awbhno=row.awbh; | ||
| 817 | + this.Udform.carrier=row.carrier; | ||
| 818 | + this.Udform.flightno=row.flightno.substring(2); | ||
| 819 | + this.Udform.flightdate=row.flightdate; | ||
| 820 | + this.Udform.bustype='MT6202'; | ||
| 821 | + this.Udform.busdate=Date.parse(new Date()); | ||
| 822 | + this.Udform.busweight=row.weight; | ||
| 823 | + this.Udform.buspiece=row.piece; | ||
| 824 | + this.Udform.opertype='发送分拨申请删除报'; | ||
| 825 | + if(row.awbh==null){ | ||
| 826 | + row.awbh=""; | ||
| 827 | + } | ||
| 828 | + this.rows=row; | ||
| 829 | + }, | ||
| 830 | + //发送分拨申请删除报表单 | ||
| 831 | + deleteIdForm(formName){ | ||
| 832 | + this.$refs[formName].validate((valid) => { | ||
| 833 | + if (valid) { | ||
| 834 | + const map = {'flightNo':this.rows.flightno, | ||
| 835 | + 'flightDate':this.rows.flightdate, | ||
| 836 | + 'awba':this.rows.awba, | ||
| 837 | + 'content':'', | ||
| 838 | + 'customCode':this.rows.customcode, | ||
| 839 | + 'reason' :this.Udform.operreason, | ||
| 840 | + 'contactName':this.Udform.operperson, | ||
| 841 | + 'contactTel':this.Udform.opertel, | ||
| 842 | + 'carrier':this.rows.carrier} | ||
| 843 | + if(this.rows.turntype=='MT6202'){ | ||
| 844 | + sendRemoveMt6202(map).then(res=>{ | ||
| 845 | + let response=res.data; | ||
| 846 | + //console.log(res); | ||
| 847 | + this.code=response.code; | ||
| 848 | + if(this.code=='200'){ | ||
| 849 | + this.rows.status='24'; | ||
| 850 | + this.rows.ext5='分拨申请删除报发送成功'; | ||
| 851 | + this.dialogFormVisible=false; | ||
| 852 | + this.outerVisible = false; | ||
| 853 | + this.centerDialogVisible=true; | ||
| 854 | + this.msg=response.msg; | ||
| 855 | + }else{ | ||
| 856 | + this.dialogFormVisible=false; | ||
| 857 | + this.outerVisible = false; | ||
| 858 | + this.centerDialogVisible=true; | ||
| 859 | + this.msg=response.msg; | ||
| 860 | + } | ||
| 861 | + }); | ||
| 862 | + }else{ | ||
| 863 | + sendRemoveMt3202(map).then(res=>{ | ||
| 864 | + let response=res.data; | ||
| 865 | + //console.log(res); | ||
| 866 | + this.code=response.code; | ||
| 867 | + if(this.code=='200'){ | ||
| 868 | + this.rows.status='24'; | ||
| 869 | + this.rows.ext5='分拨运抵删除报发送成功'; | ||
| 870 | + this.dialogFormVisible=false; | ||
| 871 | + this.outerVisible = false; | ||
| 872 | + this.centerDialogVisible=true; | ||
| 873 | + this.msg=response.msg; | ||
| 874 | + }else{ | ||
| 875 | + this.dialogFormVisible=false; | ||
| 876 | + this.outerVisible = false; | ||
| 877 | + this.centerDialogVisible=true; | ||
| 878 | + this.msg=response.msg; | ||
| 879 | + } | ||
| 880 | + }); | ||
| 881 | + }} | ||
| 882 | + else { | ||
| 883 | + console.log('error submit!!'); | ||
| 884 | + return false; | ||
| 885 | + } | ||
| 886 | + }); | ||
| 887 | + | ||
| 888 | + }, | ||
| 889 | + //发送分拨运抵报 | ||
| 890 | + arriveSend(index,row){ | ||
| 891 | + | ||
| 892 | + const map = {'mt3202':row} | ||
| 893 | + sendCreateMt3202(map).then(res=>{ | ||
| 894 | + let response=res.data; | ||
| 895 | + //console.log(res); | ||
| 896 | + this.code=response.code; | ||
| 897 | + if(this.code=='200'){ | ||
| 898 | + row.status='23' | ||
| 899 | + row.ext5='分拨运抵发送成功'; | ||
| 900 | + this.outerVisible = false; | ||
| 901 | + this.centerDialogVisible=true; | ||
| 902 | + this.msg=response.msg; | ||
| 903 | + }else{ | ||
| 904 | + this.outerVisible = false; | ||
| 905 | + this.centerDialogVisible=true; | ||
| 906 | + this.msg=response.msg; | ||
| 907 | + } | ||
| 908 | + }); | ||
| 909 | + }, | ||
| 910 | + //发送分拨返抵删除报 | ||
| 911 | + arriveDel(index,row){ | ||
| 912 | + this.dialogFormVisible=true; | ||
| 913 | + this.udStatus='delete'; | ||
| 914 | + this.Udform.awbano=row.awba; | ||
| 915 | + this.Udform.awbhno=row.awbh; | ||
| 916 | + this.Udform.carrier=row.carrier; | ||
| 917 | + this.Udform.flightno=row.flightno.substring(2); | ||
| 918 | + this.Udform.flightdate=row.flightdate; | ||
| 919 | + this.Udform.bustype='MT3202'; | ||
| 920 | + this.Udform.busdate=Date.parse(new Date()); | ||
| 921 | + this.Udform.busweight=row.weight; | ||
| 922 | + this.Udform.buspiece=row.piece; | ||
| 923 | + this.Udform.opertype='发送分拨运抵删除报'; | ||
| 924 | + if(row.awbh==null){ | ||
| 925 | + row.awbh=""; | ||
| 926 | + } | ||
| 927 | + this.rows=row; | ||
| 928 | + }, | ||
| 617 | handleClick(row) { | 929 | handleClick(row) { |
| 618 | console.log(row); | 930 | console.log(row); |
| 619 | }, | 931 | }, |
| 620 | handleSizeChange(val) { | 932 | handleSizeChange(val) { |
| 621 | - console.log(`每页 ${val} 条`); | 933 | + this.pageSize=val; |
| 934 | + this.Query(); | ||
| 622 | }, | 935 | }, |
| 623 | handleCurrentChange(val) { | 936 | handleCurrentChange(val) { |
| 624 | - console.log(`当前页: ${val}`); | 937 | + this.currentPage=val; |
| 938 | + this.query(); | ||
| 625 | }, | 939 | }, |
| 626 | //条件查询 | 940 | //条件查询 |
| 627 | Query(){ | 941 | Query(){ |
| 942 | + this.listLoading = true; | ||
| 628 | QueryData(this.defaultQuery).then(res =>{ | 943 | QueryData(this.defaultQuery).then(res =>{ |
| 629 | - //console.log(res); | 944 | + console.log(res); |
| 630 | let response=res.data.data; | 945 | let response=res.data.data; |
| 631 | - this.tableData=response; | 946 | + this.tableData=response.list; |
| 947 | + this.total=response.total; | ||
| 948 | + this.listLoading = false; | ||
| 632 | }); | 949 | }); |
| 633 | }, | 950 | }, |
| 634 | getList(){ | 951 | getList(){ |
| 635 | this.defaultQuery=this.$route.params; | 952 | this.defaultQuery=this.$route.params; |
| 953 | + this.listLoading = true; | ||
| 636 | QueryData(this.defaultQuery).then(res =>{ | 954 | QueryData(this.defaultQuery).then(res =>{ |
| 637 | //console.log(res); | 955 | //console.log(res); |
| 638 | let response=res.data.data; | 956 | let response=res.data.data; |
| 639 | - this.tableData=response; | 957 | + this.tableData=response.list; |
| 958 | + this.total=response.total; | ||
| 959 | + this.listLoading = false; | ||
| 640 | }); | 960 | }); |
| 641 | }, | 961 | }, |
| 642 | //运抵信息编辑 | 962 | //运抵信息编辑 |
| @@ -52,7 +52,7 @@ | @@ -52,7 +52,7 @@ | ||
| 52 | </el-col> | 52 | </el-col> |
| 53 | <el-col :span="12"> | 53 | <el-col :span="12"> |
| 54 | <el-button type="primary" @click="submitForm('ruleForm')">保存</el-button> | 54 | <el-button type="primary" @click="submitForm('ruleForm')">保存</el-button> |
| 55 | - <el-button type="primary" @click="submitForm('ruleForm')">保存发送</el-button> | 55 | + <el-button type="primary" @click="back">返回</el-button> |
| 56 | </el-col> | 56 | </el-col> |
| 57 | </el-row> | 57 | </el-row> |
| 58 | <!--对话提示框--> | 58 | <!--对话提示框--> |
| @@ -91,7 +91,8 @@ | @@ -91,7 +91,8 @@ | ||
| 91 | turnweight:'', | 91 | turnweight:'', |
| 92 | customcode:'', | 92 | customcode:'', |
| 93 | turnunloading:'', | 93 | turnunloading:'', |
| 94 | - goodsname:'' | 94 | + goodsname:'', |
| 95 | + status:'22' | ||
| 95 | }, | 96 | }, |
| 96 | rules: { | 97 | rules: { |
| 97 | awba: [ | 98 | awba: [ |
| @@ -118,9 +119,9 @@ | @@ -118,9 +119,9 @@ | ||
| 118 | customcode: [ | 119 | customcode: [ |
| 119 | { required: true, message: '请选择海关关区', trigger: 'change' } | 120 | { required: true, message: '请选择海关关区', trigger: 'change' } |
| 120 | ], | 121 | ], |
| 121 | - turnunLoading: [ | 122 | + turnunloading: [ |
| 122 | { required: true, message: '请选择分拨到达地', trigger: 'change' } | 123 | { required: true, message: '请选择分拨到达地', trigger: 'change' } |
| 123 | - ], | 124 | + ] |
| 124 | }, | 125 | }, |
| 125 | options2: [ | 126 | options2: [ |
| 126 | { | 127 | { |
| @@ -178,7 +179,10 @@ | @@ -178,7 +179,10 @@ | ||
| 178 | DialogVisible(){ | 179 | DialogVisible(){ |
| 179 | this.centerDialogVisible=false; | 180 | this.centerDialogVisible=false; |
| 180 | this.$router.push({name:'运单分拨申报',params:{awba:this.ruleForm.awba}}); | 181 | this.$router.push({name:'运单分拨申报',params:{awba:this.ruleForm.awba}}); |
| 181 | - } | 182 | + }, |
| 183 | + back(){ | ||
| 184 | + this.$router.go(-1);//返回上一层 | ||
| 185 | + }, | ||
| 182 | }, | 186 | }, |
| 183 | mounted(){ | 187 | mounted(){ |
| 184 | this.getDefaultData(); | 188 | this.getDefaultData(); |
| @@ -12,7 +12,7 @@ | @@ -12,7 +12,7 @@ | ||
| 12 | <el-row type="flex" class="row-bg" justify="center"> | 12 | <el-row type="flex" class="row-bg" justify="center"> |
| 13 | <el-col :span="5"> | 13 | <el-col :span="5"> |
| 14 | <el-form-item label="航班号" prop="flightno"> | 14 | <el-form-item label="航班号" prop="flightno"> |
| 15 | - <el-input placeholder="" v-model="ruleForm.flightno" style="width:100%"></el-input> | 15 | + <el-input placeholder="" v-model="flightno" style="width:100%"></el-input> |
| 16 | </el-form-item> | 16 | </el-form-item> |
| 17 | </el-col> | 17 | </el-col> |
| 18 | <el-col :span="5"> | 18 | <el-col :span="5"> |
| @@ -26,12 +26,42 @@ | @@ -26,12 +26,42 @@ | ||
| 26 | </el-col> | 26 | </el-col> |
| 27 | <el-col :span="5"> | 27 | <el-col :span="5"> |
| 28 | <el-form-item label="始发站" prop="originstation"> | 28 | <el-form-item label="始发站" prop="originstation"> |
| 29 | - <el-input placeholder="" v-model="ruleForm.originstation"></el-input> | 29 | + <el-select v-model="originstation" |
| 30 | + filterable | ||
| 31 | + allow-create | ||
| 32 | + default-first-option | ||
| 33 | + remote | ||
| 34 | + :remote-method="remoteMethod" | ||
| 35 | + :loading="loading" | ||
| 36 | + placeholder="请选择"> | ||
| 37 | + <el-option | ||
| 38 | + v-for="item in options" | ||
| 39 | + :key="item.airportid" | ||
| 40 | + :label="item.airportid" | ||
| 41 | + :value="item.airportid"> | ||
| 42 | + <span style="float: left">{{ item.airportid }}</span> | ||
| 43 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportdescchn }}</span> | ||
| 44 | + </el-option> | ||
| 45 | + </el-select> | ||
| 30 | </el-form-item> | 46 | </el-form-item> |
| 31 | </el-col> | 47 | </el-col> |
| 32 | <el-col :span="5"> | 48 | <el-col :span="5"> |
| 33 | <el-form-item label="目的站" prop="destinationstation"> | 49 | <el-form-item label="目的站" prop="destinationstation"> |
| 34 | - <el-input placeholder="" v-model="ruleForm.destinationstation" :disabled="true"></el-input> | 50 | + <el-select v-model="destinationstation" filterable |
| 51 | + allow-create | ||
| 52 | + default-first-option | ||
| 53 | + remote | ||
| 54 | + :remote-method="remoteMethod" | ||
| 55 | + :loading="loading" placeholder="请选择"> | ||
| 56 | + <el-option | ||
| 57 | + v-for="item in options2" | ||
| 58 | + :key="item.airportid" | ||
| 59 | + :label="item.airportid" | ||
| 60 | + :value="item.airportid"> | ||
| 61 | + <span style="float: left">{{ item.airportid }}</span> | ||
| 62 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportdescchn }}</span> | ||
| 63 | + </el-option> | ||
| 64 | + </el-select> | ||
| 35 | </el-form-item> | 65 | </el-form-item> |
| 36 | </el-col> | 66 | </el-col> |
| 37 | </el-row> | 67 | </el-row> |
| @@ -56,6 +86,7 @@ | @@ -56,6 +86,7 @@ | ||
| 56 | </style> | 86 | </style> |
| 57 | 87 | ||
| 58 | <script> | 88 | <script> |
| 89 | + import { selectAirport } from '../../api/mt1201' | ||
| 59 | export default { | 90 | export default { |
| 60 | data() { | 91 | data() { |
| 61 | return { | 92 | return { |
| @@ -64,8 +95,12 @@ | @@ -64,8 +95,12 @@ | ||
| 64 | flightno:'', | 95 | flightno:'', |
| 65 | flightdate:'', | 96 | flightdate:'', |
| 66 | originstation:'', | 97 | originstation:'', |
| 67 | - destinationstation:'CGO' | 98 | + destinationstation:'' |
| 68 | }, | 99 | }, |
| 100 | + options: [], | ||
| 101 | + options2:[], | ||
| 102 | + airportid:'', | ||
| 103 | + loading: false, | ||
| 69 | /*表单校验规则*/ | 104 | /*表单校验规则*/ |
| 70 | rules: { | 105 | rules: { |
| 71 | flightno: [ | 106 | flightno: [ |
| @@ -74,11 +109,11 @@ | @@ -74,11 +109,11 @@ | ||
| 74 | ], | 109 | ], |
| 75 | originstation: [ | 110 | originstation: [ |
| 76 | {required: true, message: '请输入航班起始站', trigger: 'blur'}, | 111 | {required: true, message: '请输入航班起始站', trigger: 'blur'}, |
| 77 | - {min: 3, max: 5, message: '长度为 3 ', trigger: 'blur'} | 112 | + {min: 3, max: 3, message: '长度为 3 ', trigger: 'blur'} |
| 78 | ], | 113 | ], |
| 79 | destinationstation: [ | 114 | destinationstation: [ |
| 80 | {required: true, message: '请输入目的站', trigger: 'blur'}, | 115 | {required: true, message: '请输入目的站', trigger: 'blur'}, |
| 81 | - {min: 3, max: 5, message: '长度为 3 ', trigger: 'blur'} | 116 | + {min: 3, max: 3, message: '长度为 3 ', trigger: 'blur'} |
| 82 | ], | 117 | ], |
| 83 | flightdate: [ | 118 | flightdate: [ |
| 84 | { required: true, message: '请选择日期', trigger: 'blur' } | 119 | { required: true, message: '请选择日期', trigger: 'blur' } |
| @@ -87,11 +122,29 @@ | @@ -87,11 +122,29 @@ | ||
| 87 | }; | 122 | }; |
| 88 | }, | 123 | }, |
| 89 | methods:{ | 124 | methods:{ |
| 125 | + remoteMethod:function(query) { | ||
| 126 | + this.options = []; | ||
| 127 | + this.options2=[]; | ||
| 128 | + let param={airportid:query}; | ||
| 129 | + this.loading = true; | ||
| 130 | + selectAirport(param).then(res=>{ | ||
| 131 | + if (res !== '') { | ||
| 132 | + setTimeout(() => { | ||
| 133 | + this.loading = false; | ||
| 134 | + this.options=res.data.data; | ||
| 135 | + this.options2=res.data.data; | ||
| 136 | + }, 200); | ||
| 137 | + } else { | ||
| 138 | + this.options = []; | ||
| 139 | + this.options2=[]; | ||
| 140 | + } | ||
| 141 | + }); | ||
| 142 | + }, | ||
| 90 | /*按钮点击请求方法*/ | 143 | /*按钮点击请求方法*/ |
| 91 | submitForm(formName) { | 144 | submitForm(formName) { |
| 92 | this.$refs[formName].validate((valid) => { | 145 | this.$refs[formName].validate((valid) => { |
| 93 | if (valid) { | 146 | if (valid) { |
| 94 | - this.$router.push({name:'进港原始舱单',params:{flightno:this.ruleForm.flightno,flightdate:this.dateConversion(this.ruleForm.flightdate),originstation:this.ruleForm.originstation,destinationstation:this.ruleForm.destinationstation}}); | 147 | + this.$router.push({path:'/origmaster',query:{flightno:JSON.stringify(this.ruleForm.flightno),flightdate:JSON.stringify(this.dateConversion(this.ruleForm.flightdate)),originstation:JSON.stringify(this.ruleForm.originstation),destinationstation:JSON.stringify(this.ruleForm.destinationstation),awba:JSON.stringify("")}}); |
| 95 | } else { | 148 | } else { |
| 96 | console.log('error submit!!'); | 149 | console.log('error submit!!'); |
| 97 | return false; | 150 | return false; |
| @@ -106,16 +159,44 @@ | @@ -106,16 +159,44 @@ | ||
| 106 | }, | 159 | }, |
| 107 | /*加载默认参数*/ | 160 | /*加载默认参数*/ |
| 108 | getDefaultData(){ | 161 | getDefaultData(){ |
| 109 | - if(this.$route.params.row!=null){ | ||
| 110 | - this.ruleForm.flightno=this.$route.params.row.flightno; | ||
| 111 | - this.ruleForm.flightdate=this.$route.params.row.flightdate; | ||
| 112 | - this.ruleForm.originstation=this.$route.params.row.originstation; | 162 | + if(this.$route.query!=null){ |
| 163 | + this.ruleForm.flightno=JSON.parse(this.$route.query.flightno); | ||
| 164 | + this.ruleForm.flightdate=JSON.parse(this.$route.query.flightdate); | ||
| 165 | + this.ruleForm.originstation=JSON.parse(this.$route.query.originstation); | ||
| 166 | + this.ruleForm.destinationstation=JSON.parse(this.$route.query.destinationstation); | ||
| 167 | + } | ||
| 168 | + } | ||
| 169 | + }, | ||
| 170 | + computed:{ | ||
| 171 | + originstation:{ | ||
| 172 | + get:function () { | ||
| 173 | + return this.ruleForm.originstation; | ||
| 174 | + }, | ||
| 175 | + set:function (val) { | ||
| 176 | + this.ruleForm.originstation=val.toUpperCase(); | ||
| 177 | + } | ||
| 178 | + }, | ||
| 179 | + destinationstation:{ | ||
| 180 | + get:function () { | ||
| 181 | + return this.ruleForm.destinationstation; | ||
| 182 | + }, | ||
| 183 | + set:function (val) { | ||
| 184 | + this.ruleForm.destinationstation=val.toUpperCase(); | ||
| 185 | + } | ||
| 186 | + }, | ||
| 187 | + flightno:{ | ||
| 188 | + get:function () { | ||
| 189 | + return this.ruleForm.flightno; | ||
| 190 | + }, | ||
| 191 | + set:function (val) { | ||
| 192 | + this.ruleForm.flightno=val.toUpperCase(); | ||
| 113 | } | 193 | } |
| 114 | } | 194 | } |
| 115 | }, | 195 | }, |
| 116 | /*渲染方法*/ | 196 | /*渲染方法*/ |
| 117 | mounted(){ | 197 | mounted(){ |
| 118 | this.getDefaultData(); | 198 | this.getDefaultData(); |
| 119 | - } | 199 | + //this.getFlightList(); |
| 200 | + }, | ||
| 120 | }; | 201 | }; |
| 121 | </script> | 202 | </script> |
| @@ -12,7 +12,7 @@ | @@ -12,7 +12,7 @@ | ||
| 12 | <el-row type="flex" class="row-bg" justify="center"> | 12 | <el-row type="flex" class="row-bg" justify="center"> |
| 13 | <el-col :span="5"> | 13 | <el-col :span="5"> |
| 14 | <el-form-item label="航班号" prop="flightno"> | 14 | <el-form-item label="航班号" prop="flightno"> |
| 15 | - <el-input placeholder="" v-model="ruleForm.flightno" style="width:100%"></el-input> | 15 | + <el-input onkeyup="value=value.replace(/[\u4e00-\u9fa5]/ig,'')" placeholder="" v-model="flightno" style="width:100%"></el-input> |
| 16 | </el-form-item> | 16 | </el-form-item> |
| 17 | </el-col> | 17 | </el-col> |
| 18 | <el-col :span="5"> | 18 | <el-col :span="5"> |
| @@ -25,13 +25,50 @@ | @@ -25,13 +25,50 @@ | ||
| 25 | </el-form-item> | 25 | </el-form-item> |
| 26 | </el-col> | 26 | </el-col> |
| 27 | <el-col :span="5"> | 27 | <el-col :span="5"> |
| 28 | - <el-form-item label="始发站" prop="originstation"> | 28 | + <!--<el-form-item label="始发站" prop="originstation"> |
| 29 | <el-input placeholder="" v-model="ruleForm.originstation"></el-input> | 29 | <el-input placeholder="" v-model="ruleForm.originstation"></el-input> |
| 30 | + </el-form-item>--> | ||
| 31 | + <el-form-item label="始发站" prop="originstation"> | ||
| 32 | + <el-select v-model="originstation" filterable | ||
| 33 | + allow-create | ||
| 34 | + default-first-option | ||
| 35 | + remote | ||
| 36 | + :remote-method="remoteMethod" | ||
| 37 | + :loading="loading" | ||
| 38 | + placeholder="请选择"> | ||
| 39 | + <el-option | ||
| 40 | + v-for="item in options" | ||
| 41 | + :key="item.airportid" | ||
| 42 | + :label="item.airportid" | ||
| 43 | + :value="item.airportid"> | ||
| 44 | + <span style="float: left">{{ item.airportid }}</span> | ||
| 45 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportdescchn }}</span> | ||
| 46 | + </el-option> | ||
| 47 | + </el-select> | ||
| 30 | </el-form-item> | 48 | </el-form-item> |
| 31 | </el-col> | 49 | </el-col> |
| 32 | <el-col :span="5"> | 50 | <el-col :span="5"> |
| 33 | - <el-form-item label="目的站" prop="destinationstation"> | 51 | + <!--<el-form-item label="目的站" prop="destinationstation"> |
| 34 | <el-input placeholder="" v-model="ruleForm.destinationstation" :disabled="true"></el-input> | 52 | <el-input placeholder="" v-model="ruleForm.destinationstation" :disabled="true"></el-input> |
| 53 | + </el-form-item>--> | ||
| 54 | + <el-form-item label="目的站" prop="destinationstation"> | ||
| 55 | + <el-select v-model="destinationstation" | ||
| 56 | + filterable | ||
| 57 | + allow-create | ||
| 58 | + default-first-option | ||
| 59 | + remote | ||
| 60 | + :remote-method="remoteMethod" | ||
| 61 | + :loading="loading" | ||
| 62 | + placeholder="请选择"> | ||
| 63 | + <el-option | ||
| 64 | + v-for="item in options" | ||
| 65 | + :key="item.airportid" | ||
| 66 | + :label="item.airportid" | ||
| 67 | + :value="item.airportid"> | ||
| 68 | + <span style="float: left">{{ item.airportid }}</span> | ||
| 69 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.airportdescchn }}</span> | ||
| 70 | + </el-option> | ||
| 71 | + </el-select> | ||
| 35 | </el-form-item> | 72 | </el-form-item> |
| 36 | </el-col> | 73 | </el-col> |
| 37 | </el-row> | 74 | </el-row> |
| @@ -56,6 +93,7 @@ | @@ -56,6 +93,7 @@ | ||
| 56 | </style> | 93 | </style> |
| 57 | 94 | ||
| 58 | <script> | 95 | <script> |
| 96 | + import { selectAirport } from '../../api/mt1201' | ||
| 59 | export default { | 97 | export default { |
| 60 | data() { | 98 | data() { |
| 61 | return { | 99 | return { |
| @@ -64,8 +102,11 @@ | @@ -64,8 +102,11 @@ | ||
| 64 | flightno: '', | 102 | flightno: '', |
| 65 | flightdate:'', | 103 | flightdate:'', |
| 66 | originstation:'', | 104 | originstation:'', |
| 67 | - destinationstation:'CGO' | 105 | + destinationstation:'', |
| 68 | }, | 106 | }, |
| 107 | + options: [], | ||
| 108 | + airportid:'', | ||
| 109 | + loading: false, | ||
| 69 | /*表单验证方法*/ | 110 | /*表单验证方法*/ |
| 70 | rules: { | 111 | rules: { |
| 71 | flightno: [ | 112 | flightno: [ |
| @@ -74,11 +115,11 @@ | @@ -74,11 +115,11 @@ | ||
| 74 | ], | 115 | ], |
| 75 | originstation: [ | 116 | originstation: [ |
| 76 | {required: true, message: '请输入航班起始站', trigger: 'blur'}, | 117 | {required: true, message: '请输入航班起始站', trigger: 'blur'}, |
| 77 | - {min: 3, max: 5, message: '长度为 3 ', trigger: 'blur'} | 118 | + {min: 3, max: 3, message: '长度为 3 ', trigger: 'blur'} |
| 78 | ], | 119 | ], |
| 79 | destinationstation: [ | 120 | destinationstation: [ |
| 80 | {required: true, message: '请输入目的站', trigger: 'blur'}, | 121 | {required: true, message: '请输入目的站', trigger: 'blur'}, |
| 81 | - {min: 3, max: 5, message: '长度为 3 ', trigger: 'blur'} | 122 | + {min: 3, max: 3, message: '长度为 3 ', trigger: 'blur'} |
| 82 | ], | 123 | ], |
| 83 | flightdate: [ | 124 | flightdate: [ |
| 84 | { required: true, message: '请选择日期', trigger: 'change' } | 125 | { required: true, message: '请选择日期', trigger: 'change' } |
| @@ -86,12 +127,54 @@ | @@ -86,12 +127,54 @@ | ||
| 86 | } | 127 | } |
| 87 | }; | 128 | }; |
| 88 | }, | 129 | }, |
| 130 | + computed:{ | ||
| 131 | + originstation:{ | ||
| 132 | + get:function () { | ||
| 133 | + return this.ruleForm.originstation; | ||
| 134 | + }, | ||
| 135 | + set:function (val) { | ||
| 136 | + this.ruleForm.originstation=val.toUpperCase(); | ||
| 137 | + } | ||
| 138 | + }, | ||
| 139 | + destinationstation:{ | ||
| 140 | + get:function () { | ||
| 141 | + return this.ruleForm.destinationstation; | ||
| 142 | + }, | ||
| 143 | + set:function (val) { | ||
| 144 | + this.ruleForm.destinationstation=val.toUpperCase(); | ||
| 145 | + } | ||
| 146 | + }, | ||
| 147 | + flightno:{ | ||
| 148 | + get:function () { | ||
| 149 | + return this.ruleForm.flightno; | ||
| 150 | + }, | ||
| 151 | + set:function (val) { | ||
| 152 | + this.ruleForm.flightno=val.toUpperCase(); | ||
| 153 | + } | ||
| 154 | + } | ||
| 155 | + }, | ||
| 89 | methods:{ | 156 | methods:{ |
| 157 | + remoteMethod:function(query) { | ||
| 158 | + this.options = []; | ||
| 159 | + let params={airportid:query}; | ||
| 160 | + this.loading = true; | ||
| 161 | + selectAirport(params).then(res=>{ | ||
| 162 | + if (res !== '') { | ||
| 163 | + setTimeout(() => { | ||
| 164 | + this.loading = false; | ||
| 165 | + this.options=res.data.data; | ||
| 166 | + this.options2=res.data.data; | ||
| 167 | + }, 200); | ||
| 168 | + } else { | ||
| 169 | + this.options = []; | ||
| 170 | + } | ||
| 171 | + }); | ||
| 172 | + }, | ||
| 90 | /*按钮点击请求方法*/ | 173 | /*按钮点击请求方法*/ |
| 91 | submitForm(formName) { | 174 | submitForm(formName) { |
| 92 | this.$refs[formName].validate((valid) => { | 175 | this.$refs[formName].validate((valid) => { |
| 93 | if (valid) { | 176 | if (valid) { |
| 94 | - this.$router.push({name:'进港理货舱单',params:{flightno:this.ruleForm.flightno,flightdate:this.dateConversion(this.ruleForm.flightdate),originstation:this.ruleForm.originstation,destinationstation:this.ruleForm.destinationstation}}) | 177 | + this.$router.push({path:'/tallymaster',query:{flightno:JSON.stringify(this.ruleForm.flightno),flightdate:JSON.stringify(this.dateConversion(this.ruleForm.flightdate)),originstation:JSON.stringify(this.ruleForm.originstation),destinationstation:JSON.stringify(this.ruleForm.destinationstation),awba:JSON.stringify("")}}) |
| 95 | } else { | 178 | } else { |
| 96 | //console.log('error submit!!'); | 179 | //console.log('error submit!!'); |
| 97 | return false; | 180 | return false; |
| @@ -106,10 +189,11 @@ | @@ -106,10 +189,11 @@ | ||
| 106 | }, | 189 | }, |
| 107 | /*获取默认值方法*/ | 190 | /*获取默认值方法*/ |
| 108 | getDefaultData(){ | 191 | getDefaultData(){ |
| 109 | - if(this.$route.params.row!=null){ | ||
| 110 | - this.ruleForm.flightno=this.$route.params.row.flightno; | ||
| 111 | - this.ruleForm.flightdate=this.$route.params.row.flightdate; | ||
| 112 | - this.ruleForm.originstation=this.$route.params.row.originstation; | 192 | + if(this.$route.query!=null){ |
| 193 | + this.ruleForm.flightno=JSON.parse(this.$route.query.flightno); | ||
| 194 | + this.ruleForm.flightdate=JSON.parse(this.$route.query.flightdate); | ||
| 195 | + this.ruleForm.originstation=JSON.parse(this.$route.query.originstation); | ||
| 196 | + this.ruleForm.destinationstation=JSON.parse(this.$route.query.destinationstation); | ||
| 113 | } | 197 | } |
| 114 | } | 198 | } |
| 115 | }, | 199 | }, |
| @@ -48,11 +48,17 @@ | @@ -48,11 +48,17 @@ | ||
| 48 | </el-select> | 48 | </el-select> |
| 49 | </el-col> | 49 | </el-col> |
| 50 | </el-form-item> | 50 | </el-form-item> |
| 51 | + <el-form-item label="卸货地" prop="ext2"> | ||
| 52 | + <el-input v-model="ruleForm.ext2"></el-input> | ||
| 53 | + </el-form-item> | ||
| 54 | + <el-form-item label="车辆所发属" prop="ext1"> | ||
| 55 | + <el-input v-model="ruleForm.ext1"></el-input> | ||
| 56 | + </el-form-item> | ||
| 51 | </el-form> | 57 | </el-form> |
| 52 | </el-col> | 58 | </el-col> |
| 53 | <el-col :span="12"> | 59 | <el-col :span="12"> |
| 54 | <el-button type="primary" @click="submitForm('ruleForm')">保存</el-button> | 60 | <el-button type="primary" @click="submitForm('ruleForm')">保存</el-button> |
| 55 | - <el-button type="primary" @click="submitSend('ruleForm')">保存发送</el-button> | 61 | + <el-button type="primary" @click="back">返回</el-button> |
| 56 | </el-col> | 62 | </el-col> |
| 57 | </el-row> | 63 | </el-row> |
| 58 | <!--对话提示框--> | 64 | <!--对话提示框--> |
| @@ -91,7 +97,10 @@ | @@ -91,7 +97,10 @@ | ||
| 91 | turnweight:'', | 97 | turnweight:'', |
| 92 | customcode:'', | 98 | customcode:'', |
| 93 | turnunloading:'', | 99 | turnunloading:'', |
| 94 | - pno:'' | 100 | + pno:'', |
| 101 | + ext2:'', | ||
| 102 | + ext1:'', | ||
| 103 | + status:'22' | ||
| 95 | }, | 104 | }, |
| 96 | rules: { | 105 | rules: { |
| 97 | awba: [ | 106 | awba: [ |
| @@ -115,9 +124,15 @@ | @@ -115,9 +124,15 @@ | ||
| 115 | customcode: [ | 124 | customcode: [ |
| 116 | { required: true, message: '请选择海关关区', trigger: 'change' } | 125 | { required: true, message: '请选择海关关区', trigger: 'change' } |
| 117 | ], | 126 | ], |
| 118 | - turnunLoading: [ | 127 | + turnunloading: [ |
| 119 | { required: true, message: '请选择分拨到达地', trigger: 'change' } | 128 | { required: true, message: '请选择分拨到达地', trigger: 'change' } |
| 120 | ], | 129 | ], |
| 130 | + ext2: [ | ||
| 131 | + { required: true, message: '请输入卸货地', trigger: 'change' } | ||
| 132 | + ], | ||
| 133 | + ext1: [ | ||
| 134 | + { required: true, message: '请输入运输车辆所属承运人代码', trigger: 'change' } | ||
| 135 | + ] | ||
| 121 | }, | 136 | }, |
| 122 | options2: [ | 137 | options2: [ |
| 123 | { | 138 | { |
| @@ -175,7 +190,10 @@ | @@ -175,7 +190,10 @@ | ||
| 175 | DialogVisible(){ | 190 | DialogVisible(){ |
| 176 | this.centerDialogVisible=false; | 191 | this.centerDialogVisible=false; |
| 177 | this.$router.push({name:'运单分拨申报',params:{awba:this.ruleForm.awba}}); | 192 | this.$router.push({name:'运单分拨申报',params:{awba:this.ruleForm.awba}}); |
| 178 | - } | 193 | + }, |
| 194 | + back(){ | ||
| 195 | + this.$router.go(-1);//返回上一层 | ||
| 196 | + }, | ||
| 179 | }, | 197 | }, |
| 180 | mounted(){ | 198 | mounted(){ |
| 181 | this.getDefaultData(); | 199 | this.getDefaultData(); |
| @@ -3,9 +3,9 @@ | @@ -3,9 +3,9 @@ | ||
| 3 | <el-main > | 3 | <el-main > |
| 4 | <!--检索条件--> | 4 | <!--检索条件--> |
| 5 | <el-row> | 5 | <el-row> |
| 6 | - <el-col :span="4"> | ||
| 7 | - <div class="grid-content bg-purple"> | ||
| 8 | - <el-input v-model="carrier" placeholder=""> | 6 | + <el-col :span="5"> |
| 7 | + <div class="block"> | ||
| 8 | + <el-input v-model="vcarrier" placeholder=""> | ||
| 9 | <template slot="prepend">航班号</template> | 9 | <template slot="prepend">航班号</template> |
| 10 | </el-input> | 10 | </el-input> |
| 11 | </div> | 11 | </div> |
| @@ -30,6 +30,7 @@ | @@ -30,6 +30,7 @@ | ||
| 30 | <el-row> | 30 | <el-row> |
| 31 | <template> | 31 | <template> |
| 32 | <el-table | 32 | <el-table |
| 33 | + v-loading="tableloading" | ||
| 33 | :data="tableData" | 34 | :data="tableData" |
| 34 | style="width: 100%" | 35 | style="width: 100%" |
| 35 | :default-sort = "{prop: 'date', order: 'descending'}" | 36 | :default-sort = "{prop: 'date', order: 'descending'}" |
| @@ -90,6 +91,11 @@ | @@ -90,6 +91,11 @@ | ||
| 90 | </el-container> | 91 | </el-container> |
| 91 | 92 | ||
| 92 | </template> | 93 | </template> |
| 94 | +<style scoped> | ||
| 95 | + .el-input-group{ | ||
| 96 | + display: table; | ||
| 97 | + } | ||
| 98 | +</style> | ||
| 93 | 99 | ||
| 94 | <script> | 100 | <script> |
| 95 | import { selectFlightLists } from '../../api/mt1201' | 101 | import { selectFlightLists } from '../../api/mt1201' |
| @@ -97,12 +103,13 @@ | @@ -97,12 +103,13 @@ | ||
| 97 | data() { | 103 | data() { |
| 98 | /*初始化值*/ | 104 | /*初始化值*/ |
| 99 | return { | 105 | return { |
| 100 | - carrier:undefined, | 106 | + carrier:'', |
| 101 | tableData: [], | 107 | tableData: [], |
| 102 | flighttime: undefined, | 108 | flighttime: undefined, |
| 103 | currentPage:1, | 109 | currentPage:1, |
| 104 | pageSize:10, | 110 | pageSize:10, |
| 105 | - total:0 | 111 | + total:0, |
| 112 | + tableloading:true | ||
| 106 | } | 113 | } |
| 107 | }, | 114 | }, |
| 108 | methods: { | 115 | methods: { |
| @@ -126,17 +133,28 @@ | @@ -126,17 +133,28 @@ | ||
| 126 | selectFlightLists(params).then(res=>{ | 133 | selectFlightLists(params).then(res=>{ |
| 127 | let response=res.data.data; | 134 | let response=res.data.data; |
| 128 | this.tableData=response.list; | 135 | this.tableData=response.list; |
| 136 | + this.tableloading=false; | ||
| 129 | this.total=response.total; | 137 | this.total=response.total; |
| 130 | this.listLoading = false; | 138 | this.listLoading = false; |
| 131 | }); | 139 | }); |
| 132 | }, | 140 | }, |
| 133 | /*原始舱单跳转*/ | 141 | /*原始舱单跳转*/ |
| 134 | handleEdit(index, row) { | 142 | handleEdit(index, row) { |
| 135 | - this.$router.push({name:'原始舱单',params:{index,row}}) | 143 | + this.$router.push({path:'/enter',query:{flightno:JSON.stringify(row.flightno),flightdate:JSON.stringify(row.flightdate),originstation:JSON.stringify(row.originstation),destinationstation:JSON.stringify(row.destinationstation)}}) |
| 136 | }, | 144 | }, |
| 137 | /*进港理货跳转*/ | 145 | /*进港理货跳转*/ |
| 138 | handleDelete(index, row) { | 146 | handleDelete(index, row) { |
| 139 | - this.$router.push({name:'进港理货',params:{index,row}}) | 147 | + this.$router.push({path:'entertall',query:{flightno:JSON.stringify(row.flightno),flightdate:JSON.stringify(row.flightdate),originstation:JSON.stringify(row.originstation),destinationstation:JSON.stringify(row.destinationstation)}}) |
| 148 | + } | ||
| 149 | + }, | ||
| 150 | + computed:{ | ||
| 151 | + vcarrier:{ | ||
| 152 | + get:function () { | ||
| 153 | + return this.carrier; | ||
| 154 | + }, | ||
| 155 | + set:function (val) { | ||
| 156 | + this.carrier=val.toUpperCase(); | ||
| 157 | + } | ||
| 140 | } | 158 | } |
| 141 | }, | 159 | }, |
| 142 | /*渲染方法*/ | 160 | /*渲染方法*/ |
| @@ -42,7 +42,15 @@ | @@ -42,7 +42,15 @@ | ||
| 42 | </el-col> | 42 | </el-col> |
| 43 | <el-col :span="4" class="pub"> | 43 | <el-col :span="4" class="pub"> |
| 44 | <div class="grid-content"> | 44 | <div class="grid-content"> |
| 45 | - <el-button type="primary" size="mini">导出PDF</el-button> | 45 | + <el-dropdown @command="handleCommand"> |
| 46 | + <el-button size="mini" type="primary"> | ||
| 47 | + 导出文件<i class="el-icon-arrow-down el-icon--right"></i> | ||
| 48 | + </el-button> | ||
| 49 | + <el-dropdown-menu slot="dropdown"> | ||
| 50 | + <el-dropdown-item command="PDF">导出PDF</el-dropdown-item> | ||
| 51 | + <el-dropdown-item command="EXCEL">导出EXCEL</el-dropdown-item> | ||
| 52 | + </el-dropdown-menu> | ||
| 53 | + </el-dropdown> | ||
| 46 | </div> | 54 | </div> |
| 47 | </el-col> | 55 | </el-col> |
| 48 | </div> | 56 | </div> |
| @@ -58,6 +66,9 @@ | @@ -58,6 +66,9 @@ | ||
| 58 | <el-col :span="24"> | 66 | <el-col :span="24"> |
| 59 | <template> | 67 | <template> |
| 60 | <el-table | 68 | <el-table |
| 69 | + class="table" | ||
| 70 | + id="pdfDom" | ||
| 71 | + v-loading="tableloading" | ||
| 61 | ref="multipleTable" | 72 | ref="multipleTable" |
| 62 | :data="tableData" | 73 | :data="tableData" |
| 63 | tooltip-effect="dark" | 74 | tooltip-effect="dark" |
| @@ -72,10 +83,17 @@ | @@ -72,10 +83,17 @@ | ||
| 72 | width="50"> | 83 | width="50"> |
| 73 | </el-table-column> | 84 | </el-table-column> |
| 74 | <el-table-column | 85 | <el-table-column |
| 75 | - prop="waybill" | ||
| 76 | label="运单号" | 86 | label="运单号" |
| 77 | - width="160" | ||
| 78 | - show-overflow-tooltip> | 87 | + width="185" |
| 88 | + > | ||
| 89 | + <template slot-scope="scope"> | ||
| 90 | + <span v-if="scope.row.awbh==''||scope.row.awbh==null"> | ||
| 91 | + {{scope.row.awba}} | ||
| 92 | + </span> | ||
| 93 | + <span v-else> | ||
| 94 | + {{scope.row.awbh}} | ||
| 95 | + </span> | ||
| 96 | + </template> | ||
| 79 | </el-table-column> | 97 | </el-table-column> |
| 80 | <el-table-column | 98 | <el-table-column |
| 81 | prop="awbinfo.pcs" | 99 | prop="awbinfo.pcs" |
| @@ -109,18 +127,30 @@ | @@ -109,18 +127,30 @@ | ||
| 109 | <el-table-column | 127 | <el-table-column |
| 110 | prop="status" | 128 | prop="status" |
| 111 | label="状态" | 129 | label="状态" |
| 112 | - width="100"> | 130 | + width="100" :formatter="formatStatus"> |
| 113 | </el-table-column> | 131 | </el-table-column> |
| 114 | <el-table-column | 132 | <el-table-column |
| 115 | - prop="customText" | ||
| 116 | - label="回执信息" | ||
| 117 | - width="180"> | ||
| 118 | - </el-table-column> | 133 | + label="回执内容" |
| 134 | + width="250"> | ||
| 135 | + <template slot-scope="scope"> | ||
| 136 | + <span v-if="scope.row.status=='01' || scope.row.status=='11'" style="color: #67C23A"> | ||
| 137 | + {{scope.row.ext5}} | ||
| 138 | + </span> | ||
| 139 | + <span v-else-if="scope.row.status=='02' || scope.row.status=='03'" style="color: #E6A23C"> | ||
| 140 | + {{scope.row.ext5}} | ||
| 141 | + </span> | ||
| 142 | + <span v-else-if="scope.row.status=='12' || scope.row.status=='13'" style="color: #F56C6C"> | ||
| 143 | + {{scope.row.ext5}} | ||
| 144 | + </span> | ||
| 145 | + <span v-else style="color: #909399;"> | ||
| 146 | + {{scope.row.ext5}} | ||
| 147 | + </span> | ||
| 148 | + </template> | ||
| 119 | </el-table-column> | 149 | </el-table-column> |
| 120 | <el-table-column | 150 | <el-table-column |
| 121 | prop="operation" | 151 | prop="operation" |
| 122 | label="操作" | 152 | label="操作" |
| 123 | - width="750" | 153 | + width="850" |
| 124 | show-overflow-tooltip> | 154 | show-overflow-tooltip> |
| 125 | <template slot-scope="scope"> | 155 | <template slot-scope="scope"> |
| 126 | <el-button | 156 | <el-button |
| @@ -143,17 +173,20 @@ | @@ -143,17 +173,20 @@ | ||
| 143 | <el-button | 173 | <el-button |
| 144 | size="mini" | 174 | size="mini" |
| 145 | type="primary" | 175 | type="primary" |
| 146 | - @click="handleSend(scope.$index, scope.row)">发送舱单报 | 176 | + @click="handleSend(scope.$index, scope.row)" |
| 177 | + :disabled="btSendStatusFormater(scope.row.status)">发送舱单报 | ||
| 147 | </el-button> | 178 | </el-button> |
| 148 | <el-button | 179 | <el-button |
| 149 | size="mini" | 180 | size="mini" |
| 150 | type="primary" | 181 | type="primary" |
| 151 | - @click="handleUpdate(scope.$index, scope.row)">发送舱单修改报 | 182 | + @click="handleUpdate(scope.$index, scope.row)" |
| 183 | + :disabled="btEditStatusFormater(scope.row.status)">发送舱单修改报 | ||
| 152 | </el-button> | 184 | </el-button> |
| 153 | <el-button | 185 | <el-button |
| 154 | size="mini" | 186 | size="mini" |
| 155 | type="primary" | 187 | type="primary" |
| 156 | - @click="handleDelete(scope.$index, scope.row)">发送舱单删除报 | 188 | + @click="handleDelete(scope.$index, scope.row)" |
| 189 | + :disabled="btDeleStatusFormater(scope.row.status)">发送舱单删除报 | ||
| 157 | </el-button> | 190 | </el-button> |
| 158 | <el-button | 191 | <el-button |
| 159 | v-if="scope.row.awbh==''||scope.row.awbh==null" | 192 | v-if="scope.row.awbh==''||scope.row.awbh==null" |
| @@ -181,6 +214,11 @@ | @@ -181,6 +214,11 @@ | ||
| 181 | type="primary" | 214 | type="primary" |
| 182 | @click="Allocatearrive(scope.$index, scope.row)">分拨运抵 | 215 | @click="Allocatearrive(scope.$index, scope.row)">分拨运抵 |
| 183 | </el-button> | 216 | </el-button> |
| 217 | + <el-button | ||
| 218 | + size="mini" | ||
| 219 | + type="primary" | ||
| 220 | + @click="UpdateStatus(scope.$index, scope.row)">更改状态 | ||
| 221 | + </el-button> | ||
| 184 | </template> | 222 | </template> |
| 185 | </el-table-column> | 223 | </el-table-column> |
| 186 | </el-table> | 224 | </el-table> |
| @@ -270,12 +308,12 @@ | @@ -270,12 +308,12 @@ | ||
| 270 | <el-row style="margin-bottom: 0px;"> | 308 | <el-row style="margin-bottom: 0px;"> |
| 271 | <el-col :span="3"> | 309 | <el-col :span="3"> |
| 272 | <el-form-item label="起始站" prop="awbinfo.sairportid" > | 310 | <el-form-item label="起始站" prop="awbinfo.sairportid" > |
| 273 | - <el-input v-model="ruleForm.awbinfo.sairportid"></el-input> | 311 | + <el-input v-model="ruleForm.awbinfo.sairportid" onkeyup="this.value=this.value.toUpperCase()"></el-input> |
| 274 | </el-form-item> | 312 | </el-form-item> |
| 275 | </el-col> | 313 | </el-col> |
| 276 | <el-col :span="3"> | 314 | <el-col :span="3"> |
| 277 | <el-form-item label="承运人1" prop="awbinfo.by1"> | 315 | <el-form-item label="承运人1" prop="awbinfo.by1"> |
| 278 | - <el-input v-model="ruleForm.awbinfo.by1"></el-input> | 316 | + <el-input v-model="ruleForm.awbinfo.by1" onkeyup="this.value=this.value.toUpperCase()"></el-input> |
| 279 | </el-form-item> | 317 | </el-form-item> |
| 280 | </el-col> | 318 | </el-col> |
| 281 | <el-col :span="3"> | 319 | <el-col :span="3"> |
| @@ -285,27 +323,27 @@ | @@ -285,27 +323,27 @@ | ||
| 285 | </el-col> | 323 | </el-col> |
| 286 | <el-col :span="3"> | 324 | <el-col :span="3"> |
| 287 | <el-form-item label="承运人2" prop="awbinfo.by2"> | 325 | <el-form-item label="承运人2" prop="awbinfo.by2"> |
| 288 | - <el-input v-model="ruleForm.awbinfo.by2"></el-input> | 326 | + <el-input v-model="ruleForm.awbinfo.by2" onkeyup="this.value=this.value.toUpperCase()"></el-input> |
| 289 | </el-form-item> | 327 | </el-form-item> |
| 290 | </el-col> | 328 | </el-col> |
| 291 | <el-col :span="3"> | 329 | <el-col :span="3"> |
| 292 | <el-form-item label="到达站2" prop="awbinfo.dest2"> | 330 | <el-form-item label="到达站2" prop="awbinfo.dest2"> |
| 293 | - <el-input v-model="ruleForm.awbinfo.dest2"></el-input> | 331 | + <el-input v-model="ruleForm.awbinfo.dest2" onkeyup="this.value=this.value.toUpperCase()"></el-input> |
| 294 | </el-form-item> | 332 | </el-form-item> |
| 295 | </el-col> | 333 | </el-col> |
| 296 | <el-col :span="3"> | 334 | <el-col :span="3"> |
| 297 | <el-form-item label="承运人3" prop="awbinfo.by3"> | 335 | <el-form-item label="承运人3" prop="awbinfo.by3"> |
| 298 | - <el-input v-model="ruleForm.awbinfo.by3"></el-input> | 336 | + <el-input v-model="ruleForm.awbinfo.by3" onkeyup="this.value=this.value.toUpperCase()"></el-input> |
| 299 | </el-form-item> | 337 | </el-form-item> |
| 300 | </el-col> | 338 | </el-col> |
| 301 | <el-col :span="3"> | 339 | <el-col :span="3"> |
| 302 | <el-form-item label="到达站3" prop="awbinfo.dest3"> | 340 | <el-form-item label="到达站3" prop="awbinfo.dest3"> |
| 303 | - <el-input v-model="ruleForm.awbinfo.dest3"></el-input> | 341 | + <el-input v-model="ruleForm.awbinfo.dest3" onkeyup="this.value=this.value.toUpperCase()"></el-input> |
| 304 | </el-form-item> | 342 | </el-form-item> |
| 305 | </el-col> | 343 | </el-col> |
| 306 | <el-col :span="3"> | 344 | <el-col :span="3"> |
| 307 | <el-form-item label="目的站" prop="awbinfo.eairportid"> | 345 | <el-form-item label="目的站" prop="awbinfo.eairportid"> |
| 308 | - <el-input v-model="ruleForm.awbinfo.eairportid"></el-input> | 346 | + <el-input v-model="ruleForm.awbinfo.eairportid" onkeyup="this.value=this.value.toUpperCase()"></el-input> |
| 309 | </el-form-item> | 347 | </el-form-item> |
| 310 | </el-col> | 348 | </el-col> |
| 311 | </el-row> | 349 | </el-row> |
| @@ -319,22 +357,22 @@ | @@ -319,22 +357,22 @@ | ||
| 319 | <el-row class="product"> | 357 | <el-row class="product"> |
| 320 | <el-col :span="6"> | 358 | <el-col :span="6"> |
| 321 | <el-form-item label="总件数" prop="awbinfo.pcs"> | 359 | <el-form-item label="总件数" prop="awbinfo.pcs"> |
| 322 | - <el-input v-model="ruleForm.awbinfo.pcs"></el-input> | 360 | + <el-input type="number" v-model="ruleForm.awbinfo.pcs" ></el-input> |
| 323 | </el-form-item> | 361 | </el-form-item> |
| 324 | </el-col> | 362 | </el-col> |
| 325 | <el-col :span="6"> | 363 | <el-col :span="6"> |
| 326 | <el-form-item label="总重量" prop="awbinfo.weight"> | 364 | <el-form-item label="总重量" prop="awbinfo.weight"> |
| 327 | - <el-input v-model="ruleForm.awbinfo.weight"></el-input> | 365 | + <el-input type="number" v-model="ruleForm.awbinfo.weight"></el-input> |
| 328 | </el-form-item> | 366 | </el-form-item> |
| 329 | </el-col> | 367 | </el-col> |
| 330 | <el-col :span="6"> | 368 | <el-col :span="6"> |
| 331 | <el-form-item label="舱单件数" prop="piece"> | 369 | <el-form-item label="舱单件数" prop="piece"> |
| 332 | - <el-input v-model="ruleForm.piece"></el-input> | 370 | + <el-input type="number" v-model="ruleForm.piece"></el-input> |
| 333 | </el-form-item> | 371 | </el-form-item> |
| 334 | </el-col> | 372 | </el-col> |
| 335 | <el-col :span="6"> | 373 | <el-col :span="6"> |
| 336 | <el-form-item label="舱单重量" prop="weight"> | 374 | <el-form-item label="舱单重量" prop="weight"> |
| 337 | - <el-input v-model="ruleForm.weight"></el-input> | 375 | + <el-input type="number" v-model="ruleForm.weight"></el-input> |
| 338 | </el-form-item> | 376 | </el-form-item> |
| 339 | </el-col> | 377 | </el-col> |
| 340 | </el-row> | 378 | </el-row> |
| @@ -353,8 +391,8 @@ | @@ -353,8 +391,8 @@ | ||
| 353 | </el-form-item> | 391 | </el-form-item> |
| 354 | </el-col> | 392 | </el-col> |
| 355 | <el-col :span="6"> | 393 | <el-col :span="6"> |
| 356 | - <el-form-item label="海关状态" prop="ext5"> | ||
| 357 | - <el-select v-model="ruleForm.ext5" placeholder="" style="display:inline"> | 394 | + <el-form-item label="海关状态" prop="awbinfo.awbtype"> |
| 395 | + <el-select v-model="ruleForm.awbinfo.awbtype" placeholder="" style="display:inline"> | ||
| 358 | <el-option v-for="(item,index) in customext5" :key="index" :label="item.label" | 396 | <el-option v-for="(item,index) in customext5" :key="index" :label="item.label" |
| 359 | :value="item.value"></el-option> | 397 | :value="item.value"></el-option> |
| 360 | </el-select> | 398 | </el-select> |
| @@ -362,9 +400,21 @@ | @@ -362,9 +400,21 @@ | ||
| 362 | </el-col> | 400 | </el-col> |
| 363 | <el-col :span="6"> | 401 | <el-col :span="6"> |
| 364 | <el-form-item label="海关关区" prop="customcode"> | 402 | <el-form-item label="海关关区" prop="customcode"> |
| 365 | - <el-select v-model="ruleForm.customcode" placeholder="" style="display:inline"> | ||
| 366 | - <el-option v-for="(item,index) in customcodes" :key="index" :label="item.label" | ||
| 367 | - :value="item.value"></el-option> | 403 | + <el-select v-model="ruleForm.customcode" |
| 404 | + filterable | ||
| 405 | + allow-create | ||
| 406 | + default-first-option | ||
| 407 | + remote | ||
| 408 | + :remote-method="remoteMethod2" | ||
| 409 | + :loading="loading" placeholder="请选择" style="display:inline"> | ||
| 410 | + <el-option | ||
| 411 | + v-for="item in customcodes" | ||
| 412 | + :key="item.customcode" | ||
| 413 | + :label="item.customcode" | ||
| 414 | + :value="item.customcode"> | ||
| 415 | + <span style="float: left">{{ item.customcode }}</span> | ||
| 416 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.customname }}</span> | ||
| 417 | + </el-option> | ||
| 368 | </el-select> | 418 | </el-select> |
| 369 | </el-form-item> | 419 | </el-form-item> |
| 370 | </el-col> | 420 | </el-col> |
| @@ -391,9 +441,21 @@ | @@ -391,9 +441,21 @@ | ||
| 391 | </el-col> | 441 | </el-col> |
| 392 | <el-col :span="6"> | 442 | <el-col :span="6"> |
| 393 | <el-form-item label="国家代码" prop="awbinfo.shprcountyr"> | 443 | <el-form-item label="国家代码" prop="awbinfo.shprcountyr"> |
| 394 | - <el-select v-model="ruleForm.awbinfo.shprcountyr" placeholder="" style="display:inline"> | ||
| 395 | - <el-option v-for="item in shprcountyrs" :key="item" :label="item" | ||
| 396 | - :value="item"></el-option> | 444 | + <el-select v-model="ruleForm.awbinfo.shprcountyr" |
| 445 | + filterable | ||
| 446 | + allow-create | ||
| 447 | + default-first-option | ||
| 448 | + remote | ||
| 449 | + :remote-method="remoteMethod" | ||
| 450 | + :loading="loading" placeholder="请选择"> | ||
| 451 | + <el-option | ||
| 452 | + v-for="item in shprcountyrs" | ||
| 453 | + :key="item.countryCode" | ||
| 454 | + :label="item.countryCode" | ||
| 455 | + :value="item.countryCode"> | ||
| 456 | + <span style="float: left">{{ item.countryNameCn }}</span> | ||
| 457 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.countryCode }}</span> | ||
| 458 | + </el-option> | ||
| 397 | </el-select> | 459 | </el-select> |
| 398 | </el-form-item> | 460 | </el-form-item> |
| 399 | </el-col> | 461 | </el-col> |
| @@ -421,10 +483,23 @@ | @@ -421,10 +483,23 @@ | ||
| 421 | </el-form-item> | 483 | </el-form-item> |
| 422 | </el-col> | 484 | </el-col> |
| 423 | <el-col :span="6"> | 485 | <el-col :span="6"> |
| 486 | + | ||
| 424 | <el-form-item label="国家代码" prop="awbinfo.cnscountyr"> | 487 | <el-form-item label="国家代码" prop="awbinfo.cnscountyr"> |
| 425 | - <el-select v-model="ruleForm.awbinfo.cnscountyr" placeholder="" style="display:inline"> | ||
| 426 | - <el-option v-for="item in cnscountyrs" :key="item" :label="item" | ||
| 427 | - :value="item"></el-option> | 488 | + <el-select v-model="ruleForm.awbinfo.cnscountyr" |
| 489 | + filterable | ||
| 490 | + allow-create | ||
| 491 | + default-first-option | ||
| 492 | + remote | ||
| 493 | + :remote-method="remoteMethod" | ||
| 494 | + :loading="loading" placeholder="请选择"> | ||
| 495 | + <el-option | ||
| 496 | + v-for="item in cnscountyrs" | ||
| 497 | + :key="item.countryCode" | ||
| 498 | + :label="item.countryCode" | ||
| 499 | + :value="item.countryCode"> | ||
| 500 | + <span style="float: left">{{ item.countryNameCn }}</span> | ||
| 501 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.countryCode }}</span> | ||
| 502 | + </el-option> | ||
| 428 | </el-select> | 503 | </el-select> |
| 429 | </el-form-item> | 504 | </el-form-item> |
| 430 | </el-col> | 505 | </el-col> |
| @@ -518,17 +593,17 @@ | @@ -518,17 +593,17 @@ | ||
| 518 | </el-col> | 593 | </el-col> |
| 519 | <el-col :span="2" class="pub"> | 594 | <el-col :span="2" class="pub"> |
| 520 | <div class="grid-content"> | 595 | <div class="grid-content"> |
| 521 | - <el-button type="primary" size="mini">返回</el-button> | 596 | + <el-button type="primary" @click="back" size="mini">返回</el-button> |
| 522 | </div> | 597 | </div> |
| 523 | </el-col> | 598 | </el-col> |
| 524 | <el-col :span="2.5" class="pub"> | 599 | <el-col :span="2.5" class="pub"> |
| 525 | - <div class="grid-content"><span>主单数:999</span></div> | 600 | + <div class="grid-content"><span>主单数:{{sumNmmsCount}}</span></div> |
| 526 | </el-col> | 601 | </el-col> |
| 527 | <el-col :span="3.5" class="pub"> | 602 | <el-col :span="3.5" class="pub"> |
| 528 | - <div class="grid-content"><span>舱单总件数:999999</span></div> | 603 | + <div class="grid-content"><span>舱单总件数:{{sumNmmsPrice}}</span></div> |
| 529 | </el-col> | 604 | </el-col> |
| 530 | <el-col :span="4" class="pub"> | 605 | <el-col :span="4" class="pub"> |
| 531 | - <div class="grid-content"><span>舱单总重量:999999</span></div> | 606 | + <div class="grid-content"><span>舱单总重量:{{sumNmmsWeight}}</span></div> |
| 532 | </el-col> | 607 | </el-col> |
| 533 | </el-row> | 608 | </el-row> |
| 534 | <!--对话提示框--> | 609 | <!--对话提示框--> |
| @@ -545,6 +620,38 @@ | @@ -545,6 +620,38 @@ | ||
| 545 | </span> | 620 | </span> |
| 546 | </el-dialog> | 621 | </el-dialog> |
| 547 | </el-row> | 622 | </el-row> |
| 623 | + <!--发送删除报修改报提示框--> | ||
| 624 | + <el-row> | ||
| 625 | + <el-dialog :title="'提交'+Reason[udStatus]+'信息'" :visible.sync="dialogFormVisible"> | ||
| 626 | + <el-form :model="Udform" :rules="udrules" ref="Udform" class="demo-ruleForm"> | ||
| 627 | + <el-form-item label="操作原因" prop="operreason"> | ||
| 628 | + <el-input type="textarea" v-model="Udform.operreason"></el-input> | ||
| 629 | + </el-form-item> | ||
| 630 | + <el-form-item label="操作人" prop="operperson"> | ||
| 631 | + <el-input v-model="Udform.operperson"></el-input> | ||
| 632 | + </el-form-item> | ||
| 633 | + <el-form-item label="联系电话" prop="opertel"> | ||
| 634 | + <el-input v-model="Udform.opertel"></el-input> | ||
| 635 | + </el-form-item> | ||
| 636 | + </el-form> | ||
| 637 | + <div slot="footer" class="dialog-footer"> | ||
| 638 | + <el-button @click="dialogFormVisible = false">取 消</el-button> | ||
| 639 | + <el-button type="primary" @click="udStatus==='delete'?deleteUdForm('Udform'):updateUdForm('Udform')">确 定</el-button> | ||
| 640 | + </div> | ||
| 641 | + </el-dialog> | ||
| 642 | + </el-row> | ||
| 643 | + <!--明细列表弹出框--> | ||
| 644 | + <el-row> | ||
| 645 | + <el-dialog title="回执明细列表" :visible.sync="dialogTableVisible" width="70%"> | ||
| 646 | + <el-table :data="gridData"> | ||
| 647 | + <el-table-column property="busdate" label="时间" width="160"></el-table-column> | ||
| 648 | + <el-table-column property="username" label="操作人" width="130"></el-table-column> | ||
| 649 | + <el-table-column property="buspiece" label="发送件数" width="130"></el-table-column> | ||
| 650 | + <el-table-column property="busweight" label="发送重量" width="130"></el-table-column> | ||
| 651 | + <el-table-column property="cusrestext" label="回执内容"></el-table-column> | ||
| 652 | + </el-table> | ||
| 653 | + </el-dialog> | ||
| 654 | + </el-row> | ||
| 548 | </el-main> | 655 | </el-main> |
| 549 | </el-container> | 656 | </el-container> |
| 550 | </template> | 657 | </template> |
| @@ -598,10 +705,23 @@ | @@ -598,10 +705,23 @@ | ||
| 598 | .pub { | 705 | .pub { |
| 599 | margin-right: 10px; | 706 | margin-right: 10px; |
| 600 | } | 707 | } |
| 708 | + .el-dropdown { | ||
| 709 | + vertical-align: top; | ||
| 710 | + } | ||
| 711 | + .el-dropdown + .el-dropdown { | ||
| 712 | + margin-left: 15px; | ||
| 713 | + } | ||
| 714 | + .el-icon-arrow-down { | ||
| 715 | + font-size: 12px; | ||
| 716 | + } | ||
| 601 | </style> | 717 | </style> |
| 602 | 718 | ||
| 603 | <script> | 719 | <script> |
| 604 | - import { getMt1201List,addMt1201,ediMt1201,getFenList } from '../../api/mt1201' | 720 | + import { getMt1201List,addMt1201,ediMt1201,getFenList,getCountryCode,selectCustomcode,sendCreateMt1201,sendEditeMt1201,sendRemoveMt1201 } from '../../api/mt1201' |
| 721 | + import{addResponse,selectResponseList} from "../../api/InResponse"; | ||
| 722 | + import FileSaver from "file-saver"; | ||
| 723 | + import XLSX from "xlsx"; | ||
| 724 | + import htmlToPdf from "../../api/htmlToPdf" | ||
| 605 | export default { | 725 | export default { |
| 606 | data() { | 726 | data() { |
| 607 | /*初始数据*/ | 727 | /*初始数据*/ |
| @@ -630,11 +750,15 @@ | @@ -630,11 +750,15 @@ | ||
| 630 | update: '编辑', | 750 | update: '编辑', |
| 631 | create: '添加' | 751 | create: '添加' |
| 632 | }, | 752 | }, |
| 753 | + Reason:{ | ||
| 754 | + update: '修改', | ||
| 755 | + delete: '删除' | ||
| 756 | + }, | ||
| 633 | ruleForm: { | 757 | ruleForm: { |
| 634 | awba: undefined, | 758 | awba: undefined, |
| 635 | awbh: undefined, | 759 | awbh: undefined, |
| 636 | passage: undefined, | 760 | passage: undefined, |
| 637 | - customcode: '-1', | 761 | + customcode: undefined, |
| 638 | flightno: undefined, | 762 | flightno: undefined, |
| 639 | flightdate: undefined, | 763 | flightdate: undefined, |
| 640 | originstation: undefined, | 764 | originstation: undefined, |
| @@ -645,8 +769,7 @@ | @@ -645,8 +769,7 @@ | ||
| 645 | splitcode: 'T', | 769 | splitcode: 'T', |
| 646 | uldType: undefined, | 770 | uldType: undefined, |
| 647 | uldNo: undefined, | 771 | uldNo: undefined, |
| 648 | - status: undefined, | ||
| 649 | - ext5:'-1', | 772 | + status: '22', |
| 650 | awbinfo: { | 773 | awbinfo: { |
| 651 | specopeid: undefined, | 774 | specopeid: undefined, |
| 652 | shprname: undefined, | 775 | shprname: undefined, |
| @@ -666,7 +789,7 @@ | @@ -666,7 +789,7 @@ | ||
| 666 | cnsrctcname: undefined, | 789 | cnsrctcname: undefined, |
| 667 | cnsrctctel: undefined, | 790 | cnsrctctel: undefined, |
| 668 | cargonm: undefined, | 791 | cargonm: undefined, |
| 669 | - sairportid: undefined, | 792 | + sairportid: '', |
| 670 | dest1city: undefined, | 793 | dest1city: undefined, |
| 671 | by1: undefined, | 794 | by1: undefined, |
| 672 | dest1: undefined, | 795 | dest1: undefined, |
| @@ -678,57 +801,21 @@ | @@ -678,57 +801,21 @@ | ||
| 678 | csgcustomerid: undefined, | 801 | csgcustomerid: undefined, |
| 679 | paymodel: 'PP', | 802 | paymodel: 'PP', |
| 680 | pcs: undefined, | 803 | pcs: undefined, |
| 681 | - weight: undefined | 804 | + weight: undefined, |
| 805 | + awbtype:'001', | ||
| 682 | }, | 806 | }, |
| 683 | - waybill:undefined | 807 | + waybill:undefined, |
| 808 | + customText:undefined | ||
| 684 | }, | 809 | }, |
| 685 | - paymodel:[{value:'PP',label:'预付'},{value:'DP',label:'到付'}], | 810 | + paymodel:[{value:'PP',label:'预付'},{value:'CC',label:'到付'}], |
| 686 | customext5: [ | 811 | customext5: [ |
| 687 | - { | ||
| 688 | - value: '-1', | ||
| 689 | - label: '请选择' | ||
| 690 | - }, | ||
| 691 | - { | ||
| 692 | - value: '001', | ||
| 693 | - label: '进出口货物' | ||
| 694 | - }, | ||
| 695 | - { | ||
| 696 | - value: '002', | ||
| 697 | - label: '国际转运货物' | ||
| 698 | - }, | ||
| 699 | - { | ||
| 700 | - value: '003', | ||
| 701 | - label: '过境货物' | ||
| 702 | - }, | ||
| 703 | - { | ||
| 704 | - value: '004', | ||
| 705 | - label: '暂时进出境集装箱' | ||
| 706 | - }, | ||
| 707 | - { | ||
| 708 | - value: '007', | ||
| 709 | - label: '互市贸易' | ||
| 710 | - }, | ||
| 711 | - { | ||
| 712 | - value: '008', | ||
| 713 | - label: '惰性物料' | ||
| 714 | - }], | ||
| 715 | - customcodes:[ | ||
| 716 | - { | ||
| 717 | - value: '-1', | ||
| 718 | - label: '请选择' | ||
| 719 | - }, | ||
| 720 | - { | ||
| 721 | - value: '4604', | ||
| 722 | - label: '4604' | ||
| 723 | - }, | ||
| 724 | - { | ||
| 725 | - value: '4620', | ||
| 726 | - label: '4620' | ||
| 727 | - }, | ||
| 728 | - { | ||
| 729 | - value: '4613', | ||
| 730 | - label: '4613' | ||
| 731 | - }], | 812 | + {value:'001',label:'普通货物'}, |
| 813 | + {value:'002',label:'国际转运货物'}, | ||
| 814 | + {value:'003',label:'国内转关'}, | ||
| 815 | + {value:'004',label:'空箱'}, | ||
| 816 | + {value:'005',label:'快件'}], | ||
| 817 | + customcodes:[], | ||
| 818 | + customcode:'', | ||
| 732 | rules: { | 819 | rules: { |
| 733 | waybill: [{required: true, message: '请输入运单号', trigger: 'blur'}], | 820 | waybill: [{required: true, message: '请输入运单号', trigger: 'blur'}], |
| 734 | flightno: [{required: true, message: '航班号必须输入', trigger: 'blur'}], | 821 | flightno: [{required: true, message: '航班号必须输入', trigger: 'blur'}], |
| @@ -752,23 +839,146 @@ | @@ -752,23 +839,146 @@ | ||
| 752 | 'awbinfo.cnsnaddress': [{required: true, message: '收获地址不能为空', trigger: 'blur'}], | 839 | 'awbinfo.cnsnaddress': [{required: true, message: '收获地址不能为空', trigger: 'blur'}], |
| 753 | 'awbinfo.cnscountyr': [{required: true, message: '国家代码不能为空', trigger: 'change'}], | 840 | 'awbinfo.cnscountyr': [{required: true, message: '国家代码不能为空', trigger: 'change'}], |
| 754 | 'awbinfo.paymodel':[{required: true, message: '付费方式必须选择', trigger: 'change'}], | 841 | 'awbinfo.paymodel':[{required: true, message: '付费方式必须选择', trigger: 'change'}], |
| 842 | + 'awbinfo.awbtype':[{required: true, message: '海关状态必须选择', trigger: 'change'}], | ||
| 755 | customcode:[{required: true, message: '海关关区必须选择', trigger: 'change'}], | 843 | customcode:[{required: true, message: '海关关区必须选择', trigger: 'change'}], |
| 756 | goodsname:[{required: true, message: '货物描述必须填写', trigger: 'blur'}] | 844 | goodsname:[{required: true, message: '货物描述必须填写', trigger: 'blur'}] |
| 757 | }, | 845 | }, |
| 758 | labelPosition: 'left', | 846 | labelPosition: 'left', |
| 759 | splitcodes: [{value:'T',label:'否'},{value:'P',label:'是'}], | 847 | splitcodes: [{value:'T',label:'否'},{value:'P',label:'是'}], |
| 760 | - shprcountyrs:['US','CN'], | ||
| 761 | - cnscountyrs:['US','CN'], | 848 | + shprcountyrs:[], |
| 849 | + cnscountyrs:[], | ||
| 850 | + countryCode:'', | ||
| 762 | msg:'', | 851 | msg:'', |
| 763 | code:'', | 852 | code:'', |
| 764 | centerDialogVisible:false, | 853 | centerDialogVisible:false, |
| 765 | - FenStatus:'' | 854 | + FenStatus:'', |
| 855 | + sumNmmsCount:0, | ||
| 856 | + sumNmmsPrice:0, | ||
| 857 | + sumNmmsWeight:0, | ||
| 858 | + dialogFormVisible: false, | ||
| 859 | + formLabelWidth: '100px', | ||
| 860 | + Udform:{ | ||
| 861 | + operreason:'', | ||
| 862 | + operperson:'', | ||
| 863 | + opertel:'', | ||
| 864 | + flightdate:'', | ||
| 865 | + flightno:'', | ||
| 866 | + carrier:'', | ||
| 867 | + awbano:'', | ||
| 868 | + awbhno:'', | ||
| 869 | + bustype:'', | ||
| 870 | + busdate:'', | ||
| 871 | + busweight:'', | ||
| 872 | + buspiece:'', | ||
| 873 | + opertype:'', | ||
| 874 | + cusrestext:'' | ||
| 875 | + }, | ||
| 876 | + udrules:{ | ||
| 877 | + operreason: [{required: true, message: '请输入操作原因', trigger: 'blur'}], | ||
| 878 | + operperson: [{required: true, message: '请输入操作人', trigger: 'blur'}], | ||
| 879 | + opertel: [{required: true, message: '请输入操作人联系电话', trigger: 'blur'}], | ||
| 880 | + }, | ||
| 881 | + udStatus:'', | ||
| 882 | + loading:false, | ||
| 883 | + temprows:{}, | ||
| 884 | + dialogTableVisible:false, | ||
| 885 | + gridData:[], | ||
| 886 | + tableloading:true, | ||
| 887 | + htmlTitle:'' | ||
| 766 | } | 888 | } |
| 767 | }, | 889 | }, |
| 768 | methods: { | 890 | methods: { |
| 891 | + //导出PDF,EXCEL文件 | ||
| 892 | + handleCommand(command) { | ||
| 893 | + if(command=='EXCEL'){ | ||
| 894 | + this.$message('正在为您下载' + command+'文件'); | ||
| 895 | + this.downLoad(); | ||
| 896 | + }else{ | ||
| 897 | + this.htmlTitle=this.defaultQuery.flightno+this.defaultQuery.flightdate; | ||
| 898 | + htmlToPdf.downloadPDF(document.querySelector('#pdfDom'), this.htmlTitle) | ||
| 899 | + this.$message('正在为您下载' + command+'文件'); | ||
| 900 | + //this.getPdf(); | ||
| 901 | + } | ||
| 902 | + }, | ||
| 903 | + downLoad(){ | ||
| 904 | + var wb = XLSX.utils.table_to_book(document.querySelector(".table")); | ||
| 905 | + var wbout = XLSX.write(wb, { | ||
| 906 | + bookType: "xlsx", | ||
| 907 | + bookSST: true, | ||
| 908 | + type: "array" | ||
| 909 | + }); | ||
| 910 | + try { | ||
| 911 | + FileSaver.saveAs( | ||
| 912 | + new Blob([wbout], { type: "application/octet-stream" }), | ||
| 913 | + this.defaultQuery.flightno+this.defaultQuery.flightdate+ ".xlsx" // name+'.xlsx'表示导出的excel表格名字 | ||
| 914 | + ); | ||
| 915 | + } catch (e) { | ||
| 916 | + if (typeof console !== "undefined") console.log(e, wbout); | ||
| 917 | + } | ||
| 918 | + return wbout; | ||
| 919 | + }, | ||
| 920 | + //回执收发明细 | ||
| 921 | + handleDetail(index,row){ | ||
| 922 | + if(row.flightno.length>4){ | ||
| 923 | + row.flightno=row.flightno.substring(2); | ||
| 924 | + } | ||
| 925 | + let params={awbano:row.awba,awbhno:row.awbh,carrier:row.carrier,flightno:row.flightno,flightdate:row.flightdate,bustype:'MT1201'} | ||
| 926 | + selectResponseList(params).then(res=>{ | ||
| 927 | + this.dialogTableVisible=true; | ||
| 928 | + let response=res.data.data; | ||
| 929 | + this.gridData=response; | ||
| 930 | + }); | ||
| 931 | + }, | ||
| 932 | + //更改状态 | ||
| 933 | + UpdateStatus(column,row){ | ||
| 934 | + this.$confirm("是否发送更改状态", "确认消息", { | ||
| 935 | + distinguishCancelAndClose: true, | ||
| 936 | + confirmButtonText: '确认更改', | ||
| 937 | + cancelButtonText: '取消更改' | ||
| 938 | + }).then(() => { | ||
| 939 | + row.status = '22'; | ||
| 940 | + }).catch(action => { | ||
| 941 | + this.$message({ | ||
| 942 | + type: 'info', | ||
| 943 | + message: action === 'cancel' | ||
| 944 | + ? '取消状态更改' | ||
| 945 | + : '状态更改取消' | ||
| 946 | + }) | ||
| 947 | + }) | ||
| 948 | + }, | ||
| 949 | + //状态识别 | ||
| 950 | + formatStatus: function(row,column){ | ||
| 951 | + return row.status=='01'?'接受申报':row.status=='02'?'待人工审核':row.status=='03'?'退单' | ||
| 952 | + :row.status=='11'?'放行':row.status=='12'?'拒装':row.status=='13'?'禁卸' | ||
| 953 | + :row.status=='21'?'可自动发送':row.status=='22'?'未发送':row.status=='23'?'已发送新增报' | ||
| 954 | + :row.status=='24'?'已发送删除报':row.status=='25'?'已发送修改报':''; | ||
| 955 | + }, | ||
| 956 | + //发送舱单报按钮,删除,修改判定事件 | ||
| 957 | + btSendStatusFormater:(status) => { | ||
| 958 | + if(status=='23' || status=='24'||status=='25'){ | ||
| 959 | + return true; | ||
| 960 | + }else if(status=='22' ) { | ||
| 961 | + return false; | ||
| 962 | + } | ||
| 963 | + }, | ||
| 964 | + btEditStatusFormater:(status) => { | ||
| 965 | + if(status=='23' || status=='24'||status=='25'){ | ||
| 966 | + return true; | ||
| 967 | + }else if(status=='22' ) { | ||
| 968 | + return false; | ||
| 969 | + } | ||
| 970 | + }, | ||
| 971 | + btDeleStatusFormater:(status) => { | ||
| 972 | + if(status=='23' || status=='24'||status=='25'){ | ||
| 973 | + return true; | ||
| 974 | + }else if(status=='22' ) { | ||
| 975 | + return false; | ||
| 976 | + } | ||
| 977 | + }, | ||
| 769 | /*多选框功能*/ | 978 | /*多选框功能*/ |
| 770 | handleSelectionChange(val) { | 979 | handleSelectionChange(val) { |
| 771 | this.multipleSelection = val; | 980 | this.multipleSelection = val; |
| 981 | + console.log(val) | ||
| 772 | }, | 982 | }, |
| 773 | /*编辑主单信息*/ | 983 | /*编辑主单信息*/ |
| 774 | handleEdit(index, row){ | 984 | handleEdit(index, row){ |
| @@ -777,6 +987,7 @@ | @@ -777,6 +987,7 @@ | ||
| 777 | this.FenStatus='ediAwbh'; | 987 | this.FenStatus='ediAwbh'; |
| 778 | this.ruleForm=row; | 988 | this.ruleForm=row; |
| 779 | this.ruleForm.originstation=row.originstation+"-"+row.destinationstation; | 989 | this.ruleForm.originstation=row.originstation+"-"+row.destinationstation; |
| 990 | + this.ruleForm.flightno=row.carrier+row.flightno; | ||
| 780 | this.FenQuery.awba=row.awba; | 991 | this.FenQuery.awba=row.awba; |
| 781 | this.FenQuery.flightno= row.flightno; | 992 | this.FenQuery.flightno= row.flightno; |
| 782 | this.FenQuery.flightdate=row.flightdate | 993 | this.FenQuery.flightdate=row.flightdate |
| @@ -795,7 +1006,142 @@ | @@ -795,7 +1006,142 @@ | ||
| 795 | 1006 | ||
| 796 | }, | 1007 | }, |
| 797 | //发送舱单报 | 1008 | //发送舱单报 |
| 798 | - handleSend(index,row){}, | 1009 | + handleSend(index,row){ |
| 1010 | + if(row.flightno.length>4){ | ||
| 1011 | + row.flightno=row.flightno.substring(2) | ||
| 1012 | + }else{ | ||
| 1013 | + row.flightno=row.flightno; | ||
| 1014 | + } | ||
| 1015 | + const map = {'mt1201':row} | ||
| 1016 | + sendCreateMt1201(map).then(res=>{ | ||
| 1017 | + let response=res.data; | ||
| 1018 | + //console.log(res); | ||
| 1019 | + this.code=response.code; | ||
| 1020 | + if(this.code=='200'){ | ||
| 1021 | + row.status='23' | ||
| 1022 | + row.customText='舱单报发送成功'; | ||
| 1023 | + this.outerVisible = false; | ||
| 1024 | + this.centerDialogVisible=true; | ||
| 1025 | + this.msg=response.msg; | ||
| 1026 | + }else{ | ||
| 1027 | + this.outerVisible = false; | ||
| 1028 | + this.centerDialogVisible=true; | ||
| 1029 | + this.msg=response.msg; | ||
| 1030 | + } | ||
| 1031 | + }); | ||
| 1032 | + }, | ||
| 1033 | + //发送舱单删除报 | ||
| 1034 | + handleDelete(index,row){ | ||
| 1035 | + this.udStatus='delete'; | ||
| 1036 | + this.dialogFormVisible=true; | ||
| 1037 | + this.Udform.awbano=row.awba; | ||
| 1038 | + this.Udform.awbhno=row.awbh; | ||
| 1039 | + this.Udform.carrier=row.carrier; | ||
| 1040 | + this.Udform.flightno=row.flightno.substring(2); | ||
| 1041 | + this.Udform.flightdate=row.flightdate; | ||
| 1042 | + this.Udform.bustype='MT1201'; | ||
| 1043 | + this.Udform.busdate=Date.parse(new Date()); | ||
| 1044 | + this.Udform.busweight=row.weight; | ||
| 1045 | + this.Udform.buspiece=row.piece; | ||
| 1046 | + this.Udform.opertype='发送舱单删除报'; | ||
| 1047 | + if(row.flightno.length>4){ | ||
| 1048 | + row.flightno=row.flightno.substring(2); | ||
| 1049 | + } | ||
| 1050 | + this.temprows= row; | ||
| 1051 | + }, | ||
| 1052 | + //提交发送舱单删除报表单 | ||
| 1053 | + deleteUdForm(formName){ | ||
| 1054 | + this.$refs[formName].validate((valid) => { | ||
| 1055 | + if (valid) { | ||
| 1056 | + const map = {'flightNo':this.temprows.flightno, | ||
| 1057 | + 'flightDate':this.temprows.flightdate, | ||
| 1058 | + 'awba':this.temprows.awba, | ||
| 1059 | + 'content':'', | ||
| 1060 | + 'customCode':this.temprows.customcode, | ||
| 1061 | + 'awbh':this.temprows.awbh, | ||
| 1062 | + 'reason' :this.Udform.operreason, | ||
| 1063 | + 'contactName':this.Udform.operperson, | ||
| 1064 | + 'contactTel':this.Udform.opertel, | ||
| 1065 | + 'carrier':this.Udform.carrier} | ||
| 1066 | + sendRemoveMt1201(map).then(res=>{ | ||
| 1067 | + let response=res.data; | ||
| 1068 | + //console.log(res); | ||
| 1069 | + this.code=response.code; | ||
| 1070 | + if(this.code=='200'){ | ||
| 1071 | + this.temprows.status='24'; | ||
| 1072 | + this.temprows.customText='舱单删除报发送成功'; | ||
| 1073 | + this.dialogFormVisible=false; | ||
| 1074 | + this.outerVisible = false; | ||
| 1075 | + this.centerDialogVisible=true; | ||
| 1076 | + this.msg=response.msg; | ||
| 1077 | + }else{ | ||
| 1078 | + this.dialogFormVisible=false; | ||
| 1079 | + this.outerVisible = false; | ||
| 1080 | + this.centerDialogVisible=true; | ||
| 1081 | + this.msg=response.msg; | ||
| 1082 | + } | ||
| 1083 | + }); | ||
| 1084 | + } else { | ||
| 1085 | + console.log('error submit!!'); | ||
| 1086 | + return false; | ||
| 1087 | + } | ||
| 1088 | + }); | ||
| 1089 | + | ||
| 1090 | + }, | ||
| 1091 | + /*发送舱单修改报*/ | ||
| 1092 | + handleUpdate(index,row){ | ||
| 1093 | + this.udStatus='update'; | ||
| 1094 | + this.dialogFormVisible=true; | ||
| 1095 | + this.Udform.awbano=row.awba; | ||
| 1096 | + this.Udform.awbhno=row.awbh; | ||
| 1097 | + this.Udform.carrier=row.carrier; | ||
| 1098 | + this.Udform.flightno=row.flightno.substring(2); | ||
| 1099 | + this.Udform.flightdate=row.flightdate; | ||
| 1100 | + this.Udform.bustype='MT1201'; | ||
| 1101 | + this.Udform.busdate=Date.parse(new Date()); | ||
| 1102 | + this.Udform.busweight=row.weight; | ||
| 1103 | + this.Udform.buspiece=row.piece; | ||
| 1104 | + this.Udform.opertype='发送舱单修改报'; | ||
| 1105 | + if(row.flightno.length>4){ | ||
| 1106 | + row.flightno=row.flightno.substring(2); | ||
| 1107 | + }else{ | ||
| 1108 | + row.flightno=row.flightno; | ||
| 1109 | + }; | ||
| 1110 | + this.temprows=row; | ||
| 1111 | + }, | ||
| 1112 | + //提交发送舱单修改报表单 | ||
| 1113 | + updateUdForm(formName){ | ||
| 1114 | + this.$refs[formName].validate((valid) => { | ||
| 1115 | + if (valid) { | ||
| 1116 | + const map = {'mt1201':this.temprows, | ||
| 1117 | + 'reason' :this.Udform.operreason, | ||
| 1118 | + 'contactName':this.Udform.operperson, | ||
| 1119 | + 'contactTel':this.Udform.opertel} | ||
| 1120 | + sendEditeMt1201(map).then(res=>{ | ||
| 1121 | + let response=res.data; | ||
| 1122 | + //console.log(res); | ||
| 1123 | + this.code=response.code; | ||
| 1124 | + if(this.code=='200'){ | ||
| 1125 | + this.temprows.status='25' | ||
| 1126 | + this.temprows.customText='舱单修改报发送成功'; | ||
| 1127 | + this.dialogFormVisible=false; | ||
| 1128 | + this.outerVisible = false; | ||
| 1129 | + this.centerDialogVisible=true; | ||
| 1130 | + this.msg=response.msg; | ||
| 1131 | + }else{ | ||
| 1132 | + this.dialogFormVisible=false; | ||
| 1133 | + this.outerVisible = false; | ||
| 1134 | + this.centerDialogVisible=true; | ||
| 1135 | + this.msg=response.msg; | ||
| 1136 | + } | ||
| 1137 | + }); | ||
| 1138 | + } else { | ||
| 1139 | + console.log('error submit!!'); | ||
| 1140 | + return false; | ||
| 1141 | + } | ||
| 1142 | + }); | ||
| 1143 | + | ||
| 1144 | + }, | ||
| 799 | /*编辑分单列表信息*/ | 1145 | /*编辑分单列表信息*/ |
| 800 | handleClick(row) { | 1146 | handleClick(row) { |
| 801 | this.outerVisible = true; | 1147 | this.outerVisible = true; |
| @@ -807,18 +1153,64 @@ | @@ -807,18 +1153,64 @@ | ||
| 807 | }, | 1153 | }, |
| 808 | /*获取默认值*/ | 1154 | /*获取默认值*/ |
| 809 | getDefaultData(){ | 1155 | getDefaultData(){ |
| 810 | - this.defaultQuery.flightno = this.$route.params.flightno; | ||
| 811 | - this.defaultQuery.flightdate = this.$route.params.flightdate; | ||
| 812 | - this.defaultQuery.originstation = this.$route.params.originstation; | ||
| 813 | - this.defaultQuery.destinationstation = this.$route.params.destinationstation; | ||
| 814 | - this.defaultQuery.awba=this.$route.params.awba; | 1156 | + this.defaultQuery.flightno = JSON.parse(this.$route.query.flightno); |
| 1157 | + this.defaultQuery.flightdate = JSON.parse(this.$route.query.flightdate); | ||
| 1158 | + this.defaultQuery.originstation = JSON.parse(this.$route.query.originstation); | ||
| 1159 | + this.defaultQuery.destinationstation = JSON.parse(this.$route.query.destinationstation); | ||
| 1160 | + this.defaultQuery.awba=JSON.parse(this.$route.query.awba); | ||
| 815 | }, | 1161 | }, |
| 816 | /*获取默认数据列表*/ | 1162 | /*获取默认数据列表*/ |
| 817 | getList(){ | 1163 | getList(){ |
| 818 | getMt1201List(this.defaultQuery).then(res =>{ | 1164 | getMt1201List(this.defaultQuery).then(res =>{ |
| 819 | - //console.log(res); | 1165 | + this.sumNmmsCount=0; |
| 1166 | + this.sumNmmsPrice=0; | ||
| 1167 | + this.sumNmmsWeight=0; | ||
| 820 | let response=res.data.data; | 1168 | let response=res.data.data; |
| 821 | this.tableData=response; | 1169 | this.tableData=response; |
| 1170 | + this.tableloading=false; | ||
| 1171 | + response.forEach((item,i) => { | ||
| 1172 | + if(item.awba!=null&&item.awbh==""); | ||
| 1173 | + this.sumNmmsCount=Number(this.sumNmmsCount)+1; | ||
| 1174 | + this.sumNmmsPrice=Number(this.sumNmmsPrice)+Number(item.piece); | ||
| 1175 | + this.sumNmmsWeight=Number(this.sumNmmsWeight)+Number(item.weight); | ||
| 1176 | + }) | ||
| 1177 | + }); | ||
| 1178 | + }, | ||
| 1179 | + /*获取国家代码*/ | ||
| 1180 | + remoteMethod:function(query){ | ||
| 1181 | + this.shprcountyrs=[]; | ||
| 1182 | + this.cnscountyrs=[]; | ||
| 1183 | + let params={countryCode:query}; | ||
| 1184 | + this.loading = true; | ||
| 1185 | + getCountryCode(params).then(res =>{ | ||
| 1186 | + if (res !== '') { | ||
| 1187 | + setTimeout(() => { | ||
| 1188 | + this.loading = false; | ||
| 1189 | + this.shprcountyrs=res.data.data; | ||
| 1190 | + this.cnscountyrs=res.data.data; | ||
| 1191 | + }, 200); | ||
| 1192 | + } else { | ||
| 1193 | + this.shprcountyrs = []; | ||
| 1194 | + this.cnscountyrs=[]; | ||
| 1195 | + } | ||
| 1196 | + | ||
| 1197 | + }); | ||
| 1198 | + }, | ||
| 1199 | + //获取关区代码 | ||
| 1200 | + remoteMethod2:function(query){ | ||
| 1201 | + this.customcodes=[]; | ||
| 1202 | + let params={customcode:query}; | ||
| 1203 | + this.loading = true; | ||
| 1204 | + selectCustomcode(params).then(res =>{ | ||
| 1205 | + if (res !== '') { | ||
| 1206 | + setTimeout(() => { | ||
| 1207 | + this.loading = false; | ||
| 1208 | + this.customcodes=res.data.data; | ||
| 1209 | + }, 200); | ||
| 1210 | + } else { | ||
| 1211 | + this.customcodes = []; | ||
| 1212 | + } | ||
| 1213 | + | ||
| 822 | }); | 1214 | }); |
| 823 | }, | 1215 | }, |
| 824 | //新增原始舱单按钮 | 1216 | //新增原始舱单按钮 |
| @@ -826,9 +1218,9 @@ | @@ -826,9 +1218,9 @@ | ||
| 826 | this.dialogStatus="create"; | 1218 | this.dialogStatus="create"; |
| 827 | this.outerVisible = true; | 1219 | this.outerVisible = true; |
| 828 | this.FenStatus='ediAwbh'; | 1220 | this.FenStatus='ediAwbh'; |
| 829 | - this.ruleForm.flightno=this.$route.params.flightno; | ||
| 830 | - this.ruleForm.flightdate=this.$route.params.flightdate; | ||
| 831 | - this.ruleForm.originstation=this.$route.params.originstation+"-"+this.$route.params.destinationstation; | 1221 | + this.ruleForm.flightno=JSON.parse(this.$route.query.flightno); |
| 1222 | + this.ruleForm.flightdate=JSON.parse(this.$route.query.flightdate); | ||
| 1223 | + this.ruleForm.originstation=JSON.parse(this.$route.query.originstation)+"-"+JSON.parse(this.$route.query.destinationstation); | ||
| 832 | }, | 1224 | }, |
| 833 | //新增原始分单 | 1225 | //新增原始分单 |
| 834 | addFen(formName){ | 1226 | addFen(formName){ |
| @@ -840,6 +1232,7 @@ | @@ -840,6 +1232,7 @@ | ||
| 840 | createData(formName){ | 1232 | createData(formName){ |
| 841 | this.$refs[formName].validate((valid) => { | 1233 | this.$refs[formName].validate((valid) => { |
| 842 | if (valid) { | 1234 | if (valid) { |
| 1235 | + this.ruleForm.status='22' | ||
| 843 | addMt1201(this.ruleForm).then(res=>{ | 1236 | addMt1201(this.ruleForm).then(res=>{ |
| 844 | let response=res.data; | 1237 | let response=res.data; |
| 845 | //console.log(res); | 1238 | //console.log(res); |
| @@ -899,15 +1292,18 @@ | @@ -899,15 +1292,18 @@ | ||
| 899 | }, | 1292 | }, |
| 900 | //分拨申请 | 1293 | //分拨申请 |
| 901 | Importallocation(index,row){ | 1294 | Importallocation(index,row){ |
| 902 | - this.$router.push({name:'进港分拨',params:{carrier:row.carrier,flightno:row.flightno.substr(2),awba:row.awba,flightdate:row.flightdate, | 1295 | + this.$router.push({name:'进港分拨',params:{carrier:row.carrier,flightno:row.flightno,awba:row.awba,flightdate:row.flightdate, |
| 903 | turnpiece:row.awbinfo.pcs,turnweight:row.awbinfo.weight,customcode:row.customcode}}); | 1296 | turnpiece:row.awbinfo.pcs,turnweight:row.awbinfo.weight,customcode:row.customcode}}); |
| 904 | 1297 | ||
| 905 | }, | 1298 | }, |
| 906 | //分拨运抵 | 1299 | //分拨运抵 |
| 907 | Allocatearrive(index,row){ | 1300 | Allocatearrive(index,row){ |
| 908 | - this.$router.push({name:'分拨运抵',params:{carrier:row.carrier,flightno:row.flightno.substr(2),awba:row.awba,flightdate:row.flightdate, | 1301 | + this.$router.push({name:'分拨运抵',params:{carrier:row.carrier,flightno:row.flightno,awba:row.awba,flightdate:row.flightdate, |
| 909 | turnpiece:row.awbinfo.pcs,turnweight:row.awbinfo.weight,customcode:row.customcode,goodsname:row.goodsname}}); | 1302 | turnpiece:row.awbinfo.pcs,turnweight:row.awbinfo.weight,customcode:row.customcode,goodsname:row.goodsname}}); |
| 910 | - } | 1303 | + }, |
| 1304 | + back(){ | ||
| 1305 | + this.$router.go(-1);//返回上一层 | ||
| 1306 | + }, | ||
| 911 | 1307 | ||
| 912 | }, | 1308 | }, |
| 913 | /*渲染方法*/ | 1309 | /*渲染方法*/ |
| @@ -39,8 +39,10 @@ | @@ -39,8 +39,10 @@ | ||
| 39 | <el-col :span="24"> | 39 | <el-col :span="24"> |
| 40 | <template> | 40 | <template> |
| 41 | <el-table | 41 | <el-table |
| 42 | + ref="multipleTable" | ||
| 42 | :data="tableData" | 43 | :data="tableData" |
| 43 | tooltip-effect="dark" | 44 | tooltip-effect="dark" |
| 45 | + v-loading="tableLoading" | ||
| 44 | style="width: 100%" | 46 | style="width: 100%" |
| 45 | @selection-change="handleSelectionChange" | 47 | @selection-change="handleSelectionChange" |
| 46 | row-key="uuid" | 48 | row-key="uuid" |
| @@ -52,10 +54,17 @@ | @@ -52,10 +54,17 @@ | ||
| 52 | width="50"> | 54 | width="50"> |
| 53 | </el-table-column> | 55 | </el-table-column> |
| 54 | <el-table-column | 56 | <el-table-column |
| 55 | - prop="waybill" | ||
| 56 | label="运单号" | 57 | label="运单号" |
| 57 | - width="160" | 58 | + width="185" |
| 58 | show-overflow-tooltip> | 59 | show-overflow-tooltip> |
| 60 | + <template slot-scope="scope"> | ||
| 61 | + <span v-if="scope.row.awbh==''||scope.row.awbh==null"> | ||
| 62 | + {{scope.row.awba}} | ||
| 63 | + </span> | ||
| 64 | + <span v-else> | ||
| 65 | + {{scope.row.awbh}} | ||
| 66 | + </span> | ||
| 67 | + </template> | ||
| 59 | </el-table-column> | 68 | </el-table-column> |
| 60 | <el-table-column | 69 | <el-table-column |
| 61 | prop="totalpiece" | 70 | prop="totalpiece" |
| @@ -90,23 +99,36 @@ | @@ -90,23 +99,36 @@ | ||
| 90 | <el-table-column | 99 | <el-table-column |
| 91 | prop="status" | 100 | prop="status" |
| 92 | label="状态" | 101 | label="状态" |
| 93 | - width="100"> | 102 | + width="100" :formatter="formatStatus"> |
| 94 | </el-table-column> | 103 | </el-table-column> |
| 95 | <el-table-column | 104 | <el-table-column |
| 96 | - prop="receipt" | ||
| 97 | - label="回执信息" | ||
| 98 | - width="180"> | 105 | + label="回执内容" |
| 106 | + width="250"> | ||
| 107 | + <template slot-scope="scope"> | ||
| 108 | + <span v-if="scope.row.status=='01' || scope.row.status=='11'" style="color: #67C23A"> | ||
| 109 | + {{scope.row.ext5}} | ||
| 110 | + </span> | ||
| 111 | + <span v-else-if="scope.row.status=='02' || scope.row.status=='03'" style="color: #E6A23C"> | ||
| 112 | + {{scope.row.ext5}} | ||
| 113 | + </span> | ||
| 114 | + <span v-else-if="scope.row.status=='12' || scope.row.status=='13'" style="color: #F56C6C"> | ||
| 115 | + {{scope.row.ext5}} | ||
| 116 | + </span> | ||
| 117 | + <span v-else style="color: #909399;"> | ||
| 118 | + {{scope.row.ext5}} | ||
| 119 | + </span> | ||
| 120 | + </template> | ||
| 99 | </el-table-column> | 121 | </el-table-column> |
| 100 | <el-table-column | 122 | <el-table-column |
| 101 | prop="operation" | 123 | prop="operation" |
| 102 | label="操作" | 124 | label="操作" |
| 103 | - width="450" | 125 | + width="550" |
| 104 | show-overflow-tooltip> | 126 | show-overflow-tooltip> |
| 105 | <template slot-scope="scope"> | 127 | <template slot-scope="scope"> |
| 106 | <el-button | 128 | <el-button |
| 107 | size="mini" | 129 | size="mini" |
| 108 | type="primary" | 130 | type="primary" |
| 109 | - @click="handleEdit(scope.$index, scope.row)">收发明细</el-button> | 131 | + @click="handleDetail(scope.$index, scope.row)">收发明细</el-button> |
| 110 | <el-button | 132 | <el-button |
| 111 | v-if="scope.row.awbh==''||scope.row.awbh==null" | 133 | v-if="scope.row.awbh==''||scope.row.awbh==null" |
| 112 | size="mini" | 134 | size="mini" |
| @@ -121,11 +143,18 @@ | @@ -121,11 +143,18 @@ | ||
| 121 | <el-button | 143 | <el-button |
| 122 | size="mini" | 144 | size="mini" |
| 123 | type="primary" | 145 | type="primary" |
| 124 | - @click="handleDelete(scope.$index, scope.row)">发送理货报</el-button> | 146 | + :disabled="btSendStatusFormater(scope.row.status)" |
| 147 | + @click="handleCreate(scope.$index, scope.row)">发送理货报</el-button> | ||
| 148 | + <el-button | ||
| 149 | + size="mini" | ||
| 150 | + type="primary" | ||
| 151 | + :disabled="btDeleStatusFormater(scope.row.status)" | ||
| 152 | + @click="handleDelete(scope.$index, scope.row)">发送理货删除报</el-button> | ||
| 125 | <el-button | 153 | <el-button |
| 126 | size="mini" | 154 | size="mini" |
| 127 | type="primary" | 155 | type="primary" |
| 128 | - @click="handleDelete(scope.$index, scope.row)">发送舱单删除报</el-button> | 156 | + @click="UpdateStatus(scope.$index, scope.row)">更改状态 |
| 157 | + </el-button> | ||
| 129 | </template> | 158 | </template> |
| 130 | </el-table-column> | 159 | </el-table-column> |
| 131 | </el-table> | 160 | </el-table> |
| @@ -184,12 +213,12 @@ | @@ -184,12 +213,12 @@ | ||
| 184 | <el-row class="flightInfo"> | 213 | <el-row class="flightInfo"> |
| 185 | <el-col :span="6"> | 214 | <el-col :span="6"> |
| 186 | <el-form-item label="起始站" prop="originstation"> | 215 | <el-form-item label="起始站" prop="originstation"> |
| 187 | - <el-input disabled="" v-model="ruleForm.originstation"></el-input> | 216 | + <el-input disabled="" v-model="ruleForm.originstation" onkeyup="this.value=this.value.toUpperCase()"></el-input> |
| 188 | </el-form-item> | 217 | </el-form-item> |
| 189 | </el-col> | 218 | </el-col> |
| 190 | <el-col :span="6"> | 219 | <el-col :span="6"> |
| 191 | <el-form-item label="目的站" prop="destinationstation"> | 220 | <el-form-item label="目的站" prop="destinationstation"> |
| 192 | - <el-input disabled="" v-model="ruleForm.destinationstation"></el-input> | 221 | + <el-input disabled="" v-model="ruleForm.destinationstation" onkeyup="this.value=this.value.toUpperCase()"></el-input> |
| 193 | </el-form-item> | 222 | </el-form-item> |
| 194 | </el-col> | 223 | </el-col> |
| 195 | <el-col :span="6"> | 224 | <el-col :span="6"> |
| @@ -207,22 +236,22 @@ | @@ -207,22 +236,22 @@ | ||
| 207 | <el-row class="product"> | 236 | <el-row class="product"> |
| 208 | <el-col :span="6"> | 237 | <el-col :span="6"> |
| 209 | <el-form-item label="舱单件数" prop="pcs"> | 238 | <el-form-item label="舱单件数" prop="pcs"> |
| 210 | - <el-input v-model="ruleForm.pcs"></el-input> | 239 | + <el-input type="number" v-model="ruleForm.pcs"></el-input> |
| 211 | </el-form-item> | 240 | </el-form-item> |
| 212 | </el-col> | 241 | </el-col> |
| 213 | <el-col :span="6"> | 242 | <el-col :span="6"> |
| 214 | <el-form-item label="舱单重量" prop="wei"> | 243 | <el-form-item label="舱单重量" prop="wei"> |
| 215 | - <el-input v-model="ruleForm.wei"></el-input> | 244 | + <el-input type="number" v-model="ruleForm.wei"></el-input> |
| 216 | </el-form-item> | 245 | </el-form-item> |
| 217 | </el-col> | 246 | </el-col> |
| 218 | <el-col :span="6"> | 247 | <el-col :span="6"> |
| 219 | <el-form-item label="理货件数" prop="piece"> | 248 | <el-form-item label="理货件数" prop="piece"> |
| 220 | - <el-input v-model="ruleForm.piece"></el-input> | 249 | + <el-input type="number" v-model="ruleForm.piece"></el-input> |
| 221 | </el-form-item> | 250 | </el-form-item> |
| 222 | </el-col> | 251 | </el-col> |
| 223 | <el-col :span="6"> | 252 | <el-col :span="6"> |
| 224 | <el-form-item label="理货重量" prop="weight"> | 253 | <el-form-item label="理货重量" prop="weight"> |
| 225 | - <el-input v-model="ruleForm.weight"></el-input> | 254 | + <el-input type="number" v-model="ruleForm.weight"></el-input> |
| 226 | </el-form-item> | 255 | </el-form-item> |
| 227 | </el-col> | 256 | </el-col> |
| 228 | </el-row> | 257 | </el-row> |
| @@ -230,9 +259,21 @@ | @@ -230,9 +259,21 @@ | ||
| 230 | <el-row class="flightInfo"> | 259 | <el-row class="flightInfo"> |
| 231 | <el-col :span="6"> | 260 | <el-col :span="6"> |
| 232 | <el-form-item label="海关关区" prop="customcode"> | 261 | <el-form-item label="海关关区" prop="customcode"> |
| 233 | - <el-select v-model="ruleForm.customcode" placeholder="" style="display:inline"> | ||
| 234 | - <el-option v-for="(item,index) in customcodes" :key="index" :label="item.label" | ||
| 235 | - :value="item.value"></el-option> | 262 | + <el-select v-model="ruleForm.customcode" |
| 263 | + filterable | ||
| 264 | + allow-create | ||
| 265 | + default-first-option | ||
| 266 | + remote | ||
| 267 | + :remote-method="remoteMethod2" | ||
| 268 | + :loading="loading" placeholder="请选择" style="display:inline"> | ||
| 269 | + <el-option | ||
| 270 | + v-for="item in customcodes" | ||
| 271 | + :key="item.customcode" | ||
| 272 | + :label="item.customcode" | ||
| 273 | + :value="item.customcode"> | ||
| 274 | + <span style="float: left">{{ item.customcode }}</span> | ||
| 275 | + <span style="float: right; color: #8492a6; font-size: 13px">{{ item.customname }}</span> | ||
| 276 | + </el-option> | ||
| 236 | </el-select> | 277 | </el-select> |
| 237 | </el-form-item> | 278 | </el-form-item> |
| 238 | </el-col> | 279 | </el-col> |
| @@ -301,7 +342,6 @@ | @@ -301,7 +342,6 @@ | ||
| 301 | </el-table-column> | 342 | </el-table-column> |
| 302 | </el-table> | 343 | </el-table> |
| 303 | </template> | 344 | </template> |
| 304 | - | ||
| 305 | </el-col> | 345 | </el-col> |
| 306 | </el-row> | 346 | </el-row> |
| 307 | </el-form> | 347 | </el-form> |
| @@ -310,10 +350,10 @@ | @@ -310,10 +350,10 @@ | ||
| 310 | <el-row> | 350 | <el-row> |
| 311 | <el-col :span="2.5"><div class="grid-content"><el-button type="primary" v-on:click="addTally" size="mini">新增进港理货</el-button></div></el-col> | 351 | <el-col :span="2.5"><div class="grid-content"><el-button type="primary" v-on:click="addTally" size="mini">新增进港理货</el-button></div></el-col> |
| 312 | <el-col :span="2.5"><div class="grid-content"><el-button type="primary" size="mini">批量发送删除报</el-button></div></el-col> | 352 | <el-col :span="2.5"><div class="grid-content"><el-button type="primary" size="mini">批量发送删除报</el-button></div></el-col> |
| 313 | - <el-col :span="2"><div class="grid-content"><el-button type="primary" size="mini">返回</el-button></div></el-col> | ||
| 314 | - <el-col :span="2.5"><div class="grid-content"><span>主单数:999</span></div></el-col> | ||
| 315 | - <el-col :span="3.5"><div class="grid-content"><span>理货总件数:999999</span></div></el-col> | ||
| 316 | - <el-col :span="4"><div class="grid-content"><span>理货总重量:999999</span></div></el-col> | 353 | + <el-col :span="2"><div class="grid-content"><el-button type="primary" @click="back" size="mini">返回</el-button></div></el-col> |
| 354 | + <el-col :span="2.5"><div class="grid-content"><span>主单数:{{sumNmmsCount}}</span></div></el-col> | ||
| 355 | + <el-col :span="3.5"><div class="grid-content"><span>理货总件数:{{sumNmmsPrice}}</span></div></el-col> | ||
| 356 | + <el-col :span="4"><div class="grid-content"><span>理货总重量:{{sumNmmsWeight}}</span></div></el-col> | ||
| 317 | </el-row> | 357 | </el-row> |
| 318 | <!--对话提示框--> | 358 | <!--对话提示框--> |
| 319 | <el-row> | 359 | <el-row> |
| @@ -329,6 +369,38 @@ | @@ -329,6 +369,38 @@ | ||
| 329 | </span> | 369 | </span> |
| 330 | </el-dialog> | 370 | </el-dialog> |
| 331 | </el-row> | 371 | </el-row> |
| 372 | + <!--发送删除报修改报提示框--> | ||
| 373 | + <el-row> | ||
| 374 | + <el-dialog :title="'提交'+Reason[udStatus]+'信息'" :visible.sync="dialogFormVisible"> | ||
| 375 | + <el-form :model="Udform" :rules="udrules" ref="Udform" class="demo-ruleForm"> | ||
| 376 | + <el-form-item label="操作原因" prop="operreason"> | ||
| 377 | + <el-input type="textarea" v-model="Udform.operreason"></el-input> | ||
| 378 | + </el-form-item> | ||
| 379 | + <el-form-item label="操作人" prop="operperson"> | ||
| 380 | + <el-input v-model="Udform.operperson"></el-input> | ||
| 381 | + </el-form-item> | ||
| 382 | + <el-form-item label="联系电话" prop="opertel"> | ||
| 383 | + <el-input v-model="Udform.opertel"></el-input> | ||
| 384 | + </el-form-item> | ||
| 385 | + </el-form> | ||
| 386 | + <div slot="footer" class="dialog-footer"> | ||
| 387 | + <el-button @click="dialogFormVisible = false">取 消</el-button> | ||
| 388 | + <el-button type="primary" @click="deleteUdForm('Udform')">确 定</el-button> | ||
| 389 | + </div> | ||
| 390 | + </el-dialog> | ||
| 391 | + </el-row> | ||
| 392 | + <!--明细列表弹出框--> | ||
| 393 | + <el-row> | ||
| 394 | + <el-dialog title="回执明细列表" :visible.sync="dialogTableVisible" width="70%"> | ||
| 395 | + <el-table :data="gridData"> | ||
| 396 | + <el-table-column property="busdate" label="时间" width="160"></el-table-column> | ||
| 397 | + <el-table-column property="username" label="操作人" width="130"></el-table-column> | ||
| 398 | + <el-table-column property="buspiece" label="发送件数" width="130"></el-table-column> | ||
| 399 | + <el-table-column property="busweight" label="发送重量" width="130"></el-table-column> | ||
| 400 | + <el-table-column property="cusrestext" label="回执内容"></el-table-column> | ||
| 401 | + </el-table> | ||
| 402 | + </el-dialog> | ||
| 403 | + </el-row> | ||
| 332 | </el-main> | 404 | </el-main> |
| 333 | </el-container> | 405 | </el-container> |
| 334 | </template> | 406 | </template> |
| @@ -367,7 +439,8 @@ | @@ -367,7 +439,8 @@ | ||
| 367 | </style> | 439 | </style> |
| 368 | 440 | ||
| 369 | <script> | 441 | <script> |
| 370 | - import { getMt5201List,addMt5201,ediMt5201,delMt5201} from '../../api/mt5201' | 442 | + import{addResponse,selectResponseList} from "../../api/InResponse"; |
| 443 | + import { getMt5201List,addMt5201,ediMt5201,delMt5201,sendCreateMt520x,sendRemoveMt520x,selectCustomcode} from '../../api/mt5201' | ||
| 371 | export default { | 444 | export default { |
| 372 | data() { | 445 | data() { |
| 373 | return { | 446 | return { |
| @@ -376,7 +449,7 @@ | @@ -376,7 +449,7 @@ | ||
| 376 | flightdate:undefined, | 449 | flightdate:undefined, |
| 377 | originstation:undefined, | 450 | originstation:undefined, |
| 378 | destinationstation:undefined, | 451 | destinationstation:undefined, |
| 379 | - awba:undefined | 452 | + awba:undefined, |
| 380 | }, | 453 | }, |
| 381 | tableData: [], | 454 | tableData: [], |
| 382 | tableData2: [], | 455 | tableData2: [], |
| @@ -388,23 +461,7 @@ | @@ -388,23 +461,7 @@ | ||
| 388 | update: '编辑', | 461 | update: '编辑', |
| 389 | create: '添加' | 462 | create: '添加' |
| 390 | }, | 463 | }, |
| 391 | - customcodes:[ | ||
| 392 | - { | ||
| 393 | - value: '-1', | ||
| 394 | - label: '请选择' | ||
| 395 | - }, | ||
| 396 | - { | ||
| 397 | - value: '4604', | ||
| 398 | - label: '4604' | ||
| 399 | - }, | ||
| 400 | - { | ||
| 401 | - value: '4620', | ||
| 402 | - label: '4620' | ||
| 403 | - }, | ||
| 404 | - { | ||
| 405 | - value: '4613', | ||
| 406 | - label: '4613' | ||
| 407 | - }], | 464 | + customcodes:[], |
| 408 | ruleForm:{ | 465 | ruleForm:{ |
| 409 | awba:undefined, | 466 | awba:undefined, |
| 410 | awbh:undefined, | 467 | awbh:undefined, |
| @@ -417,14 +474,15 @@ | @@ -417,14 +474,15 @@ | ||
| 417 | weight:undefined, | 474 | weight:undefined, |
| 418 | starttime:undefined, | 475 | starttime:undefined, |
| 419 | endtime:undefined, | 476 | endtime:undefined, |
| 420 | - customcode:"-1", | 477 | + customcode:undefined, |
| 421 | goodsname:undefined, | 478 | goodsname:undefined, |
| 422 | actime:undefined, | 479 | actime:undefined, |
| 423 | rcfdep:"MT5201", | 480 | rcfdep:"MT5201", |
| 424 | - status:undefined, | 481 | + status:'22', |
| 425 | isdelete:undefined, | 482 | isdelete:undefined, |
| 426 | pcs:undefined, | 483 | pcs:undefined, |
| 427 | - wei:undefined | 484 | + wei:undefined, |
| 485 | + ext5:undefined | ||
| 428 | }, | 486 | }, |
| 429 | FenStatus:'', | 487 | FenStatus:'', |
| 430 | rules: { | 488 | rules: { |
| @@ -440,9 +498,201 @@ | @@ -440,9 +498,201 @@ | ||
| 440 | }, | 498 | }, |
| 441 | centerDialogVisible:false, | 499 | centerDialogVisible:false, |
| 442 | msg:'', | 500 | msg:'', |
| 501 | + sumNmmsCount:0, | ||
| 502 | + sumNmmsPrice:0, | ||
| 503 | + sumNmmsWeight:0, | ||
| 504 | + Udform:{ | ||
| 505 | + operreason:'', | ||
| 506 | + operperson:'', | ||
| 507 | + opertel:'', | ||
| 508 | + flightdate:'', | ||
| 509 | + flightno:'', | ||
| 510 | + carrier:'', | ||
| 511 | + awbano:'', | ||
| 512 | + awbhno:'', | ||
| 513 | + bustype:'', | ||
| 514 | + busdate:'', | ||
| 515 | + busweight:'', | ||
| 516 | + buspiece:'', | ||
| 517 | + opertype:'', | ||
| 518 | + }, | ||
| 519 | + udrules:{ | ||
| 520 | + operreason: [{required: true, message: '请输入操作原因', trigger: 'blur'}], | ||
| 521 | + operperson: [{required: true, message: '请输入操作人', trigger: 'blur'}], | ||
| 522 | + opertel: [{required: true, message: '请输入操作人联系电话', trigger: 'blur'}], | ||
| 523 | + }, | ||
| 524 | + Reason:{ | ||
| 525 | + update: '修改', | ||
| 526 | + delete: '删除' | ||
| 527 | + }, | ||
| 528 | + udStatus:'', | ||
| 529 | + dialogFormVisible: false, | ||
| 530 | + rows:{}, | ||
| 531 | + loading:false, | ||
| 532 | + dialogTableVisible:false, | ||
| 533 | + gridData:[], | ||
| 534 | + tableLoading:false | ||
| 443 | } | 535 | } |
| 444 | }, | 536 | }, |
| 445 | methods: { | 537 | methods: { |
| 538 | + //更改状态 | ||
| 539 | + UpdateStatus(column,row){ | ||
| 540 | + this.$confirm("是否发送更改状态", "确认消息", { | ||
| 541 | + distinguishCancelAndClose: true, | ||
| 542 | + confirmButtonText: '确认更改', | ||
| 543 | + cancelButtonText: '取消更改' | ||
| 544 | + }).then(() => { | ||
| 545 | + row.status = '22'; | ||
| 546 | + }).catch(action => { | ||
| 547 | + this.$message({ | ||
| 548 | + type: 'info', | ||
| 549 | + message: action === 'cancel' | ||
| 550 | + ? '取消状态更改' | ||
| 551 | + : '状态更改取消' | ||
| 552 | + }) | ||
| 553 | + }) | ||
| 554 | + }, | ||
| 555 | + //发送舱单报按钮判定事件 | ||
| 556 | + btSendStatusFormater:(status) => { | ||
| 557 | + if(status=='23' || status=='24'||status=='25'){ | ||
| 558 | + return true; | ||
| 559 | + }else if(status=='22' ) { | ||
| 560 | + return false; | ||
| 561 | + } | ||
| 562 | + }, | ||
| 563 | + btDeleStatusFormater:(status) => { | ||
| 564 | + if(status=='23' || status=='24'||status=='25'){ | ||
| 565 | + return true; | ||
| 566 | + }else if(status=='22' ) { | ||
| 567 | + return false; | ||
| 568 | + } | ||
| 569 | + }, | ||
| 570 | + //回执收发明细 | ||
| 571 | + handleDetail(index,row){ | ||
| 572 | + if(row.flightno.length>4){ | ||
| 573 | + row.flightno=row.flightno.substring(2); | ||
| 574 | + } | ||
| 575 | + let params={awbano:row.awba,awbhno:row.awbh,carrier:row.carrier,flightno:row.flightno,flightdate:row.flightdate,bustype:'MT5201'} | ||
| 576 | + selectResponseList(params).then(res=>{ | ||
| 577 | + this.dialogTableVisible=true; | ||
| 578 | + let response=res.data.data; | ||
| 579 | + this.gridData=response; | ||
| 580 | + }); | ||
| 581 | + }, | ||
| 582 | + //状态适配 | ||
| 583 | + formatStatus:function (row,column) { | ||
| 584 | + return row.status=='01'?'接受申报':row.status=='02'?'待人工审核':row.status=='03'?'退单' | ||
| 585 | + :row.status=='11'?'放行':row.status=='12'?'拒装':row.status=='13'?'禁卸' | ||
| 586 | + :row.status=='21'?'可自动发送':row.status=='22'?'未发送':row.status=='23'?'已发送新增报' | ||
| 587 | + :row.status=='24'?'已发送删除报':row.status=='25'?'已发送修改报':''; | ||
| 588 | + }, | ||
| 589 | + //获取关区代码 | ||
| 590 | + remoteMethod2:function(query){ | ||
| 591 | + this.customcodes=[]; | ||
| 592 | + let params={customcode:query}; | ||
| 593 | + this.loading = true; | ||
| 594 | + selectCustomcode(params).then(res =>{ | ||
| 595 | + if (res !== '') { | ||
| 596 | + setTimeout(() => { | ||
| 597 | + this.loading = false; | ||
| 598 | + this.customcodes=res.data.data; | ||
| 599 | + }, 200); | ||
| 600 | + } else { | ||
| 601 | + this.customcodes = []; | ||
| 602 | + } | ||
| 603 | + | ||
| 604 | + }); | ||
| 605 | + }, | ||
| 606 | + //发送理货报 | ||
| 607 | + handleCreate(index,row){ | ||
| 608 | + if(row.flightno.length>4){ | ||
| 609 | + row.flightno=row.flightno.substring(2) | ||
| 610 | + }else{ | ||
| 611 | + row.flightno=row.flightno; | ||
| 612 | + } | ||
| 613 | + if(row.awbh==null){ | ||
| 614 | + row.awbh=""; | ||
| 615 | + } | ||
| 616 | + const map = {'mt520x':row} | ||
| 617 | + sendCreateMt520x(map).then(res=>{ | ||
| 618 | + let response=res.data; | ||
| 619 | + //console.log(res); | ||
| 620 | + this.code=response.code; | ||
| 621 | + if(this.code=='200'){ | ||
| 622 | + row.status='23' | ||
| 623 | + row.ext5='理货报发送成功'; | ||
| 624 | + this.outerVisible = false; | ||
| 625 | + this.centerDialogVisible=true; | ||
| 626 | + this.msg=response.msg; | ||
| 627 | + }else{ | ||
| 628 | + this.outerVisible = false; | ||
| 629 | + this.centerDialogVisible=true; | ||
| 630 | + this.msg=response.msg; | ||
| 631 | + } | ||
| 632 | + }); | ||
| 633 | + }, | ||
| 634 | + //发送理货删除报 | ||
| 635 | + handleDelete(index,row){ | ||
| 636 | + this.dialogFormVisible=true; | ||
| 637 | + this.udStatus='delete'; | ||
| 638 | + this.Udform.awbano=row.awba; | ||
| 639 | + this.Udform.awbhno=row.awbh; | ||
| 640 | + this.Udform.carrier=row.carrier; | ||
| 641 | + this.Udform.flightno=row.flightno.substring(2); | ||
| 642 | + this.Udform.flightdate=row.flightdate; | ||
| 643 | + this.Udform.bustype='MT5201'; | ||
| 644 | + this.Udform.busdate=Date.parse(new Date()); | ||
| 645 | + this.Udform.busweight=row.weight; | ||
| 646 | + this.Udform.buspiece=row.piece; | ||
| 647 | + this.Udform.opertype='发送理货删除报'; | ||
| 648 | + if(row.flightno.length>4){ | ||
| 649 | + row.flightno=row.flightno.substring(2); | ||
| 650 | + } | ||
| 651 | + if(row.awbh==null){ | ||
| 652 | + row.awbh=""; | ||
| 653 | + } | ||
| 654 | + this.rows=row; | ||
| 655 | + }, | ||
| 656 | + //发送理化删除报提交表单 | ||
| 657 | + deleteUdForm(formName){ | ||
| 658 | + this.$refs[formName].validate((valid) => { | ||
| 659 | + if (valid) { | ||
| 660 | + const map = {'flightNo':this.rows.flightno, | ||
| 661 | + 'flightDate':this.rows.flightdate, | ||
| 662 | + 'awba':this.rows.awba, | ||
| 663 | + 'content':'', | ||
| 664 | + 'customCode':this.rows.customcode, | ||
| 665 | + 'awbh':this.rows.awbh, | ||
| 666 | + 'reason' :this.Udform.operreason, | ||
| 667 | + 'contactName':this.Udform.operperson, | ||
| 668 | + 'contactTel':this.Udform.opertel, | ||
| 669 | + 'rcfdep':this.rows.rcfdep, | ||
| 670 | + 'carrier':this.rows.carrier} | ||
| 671 | + sendRemoveMt520x(map).then(res=>{ | ||
| 672 | + let response=res.data; | ||
| 673 | + //console.log(res); | ||
| 674 | + this.code=response.code; | ||
| 675 | + if(this.code=='200'){ | ||
| 676 | + this.rows.status='24'; | ||
| 677 | + this.rows.ext5='理货删除报发送成功'; | ||
| 678 | + this.dialogFormVisible=false; | ||
| 679 | + this.outerVisible = false; | ||
| 680 | + this.centerDialogVisible=true; | ||
| 681 | + this.msg=response.msg; | ||
| 682 | + }else{ | ||
| 683 | + this.dialogFormVisible=false; | ||
| 684 | + this.outerVisible = false; | ||
| 685 | + this.centerDialogVisible=true; | ||
| 686 | + this.msg=response.msg; | ||
| 687 | + } | ||
| 688 | + }); | ||
| 689 | + } else { | ||
| 690 | + console.log('error submit!!'); | ||
| 691 | + return false; | ||
| 692 | + } | ||
| 693 | + }); | ||
| 694 | + | ||
| 695 | + }, | ||
| 446 | //批量选中事件 | 696 | //批量选中事件 |
| 447 | handleSelectionChange(val) { | 697 | handleSelectionChange(val) { |
| 448 | this.multipleSelection = val; | 698 | this.multipleSelection = val; |
| @@ -453,6 +703,7 @@ | @@ -453,6 +703,7 @@ | ||
| 453 | this.dialogStatus='update'; | 703 | this.dialogStatus='update'; |
| 454 | this.FenStatus='ediAwbh'; | 704 | this.FenStatus='ediAwbh'; |
| 455 | this.ruleForm=row; | 705 | this.ruleForm=row; |
| 706 | + this.ruleForm.flightno=row.carrier+row.flightno; | ||
| 456 | }, | 707 | }, |
| 457 | //编辑分单 | 708 | //编辑分单 |
| 458 | handleFen(index,row){ | 709 | handleFen(index,row){ |
| @@ -470,17 +721,28 @@ | @@ -470,17 +721,28 @@ | ||
| 470 | }, | 721 | }, |
| 471 | //获取默认值 | 722 | //获取默认值 |
| 472 | getDefaultData(){ | 723 | getDefaultData(){ |
| 473 | - this.defaultQuery.flightno=this.$route.params.flightno; | ||
| 474 | - this.defaultQuery.flightdate=this.$route.params.flightdate; | ||
| 475 | - this.defaultQuery.originstation=this.$route.params.originstation; | ||
| 476 | - this.defaultQuery.destinationstation=this.$route.params.destinationstation; | 724 | + this.defaultQuery.flightno = JSON.parse(this.$route.query.flightno); |
| 725 | + this.defaultQuery.flightdate = JSON.parse(this.$route.query.flightdate); | ||
| 726 | + this.defaultQuery.originstation = JSON.parse(this.$route.query.originstation); | ||
| 727 | + this.defaultQuery.destinationstation = JSON.parse(this.$route.query.destinationstation); | ||
| 728 | + this.defaultQuery.awba=JSON.parse(this.$route.query.awba); | ||
| 477 | }, | 729 | }, |
| 478 | //获取进港理货列表 | 730 | //获取进港理货列表 |
| 479 | getMt5201List(){ | 731 | getMt5201List(){ |
| 732 | + this.tableLoading=true; | ||
| 480 | getMt5201List(this.defaultQuery).then(res =>{ | 733 | getMt5201List(this.defaultQuery).then(res =>{ |
| 481 | - console.log(res); | 734 | + this.sumNmmsCount=0; |
| 735 | + this.sumNmmsPrice=0; | ||
| 736 | + this.sumNmmsWeight=0; | ||
| 482 | let response=res.data.data; | 737 | let response=res.data.data; |
| 483 | this.tableData=response; | 738 | this.tableData=response; |
| 739 | + this.tableLoading=false; | ||
| 740 | + response.forEach((item,i) => { | ||
| 741 | + if(item.awba!=null&&item.awbh==""); | ||
| 742 | + this.sumNmmsCount=Number(this.sumNmmsCount)+1; | ||
| 743 | + this.sumNmmsPrice=Number(this.sumNmmsPrice)+Number(item.piece); | ||
| 744 | + this.sumNmmsWeight=Number(this.sumNmmsWeight)+Number(item.weight); | ||
| 745 | + }) | ||
| 484 | }); | 746 | }); |
| 485 | }, | 747 | }, |
| 486 | //新增理货按钮事件 | 748 | //新增理货按钮事件 |
| @@ -488,15 +750,17 @@ | @@ -488,15 +750,17 @@ | ||
| 488 | this.outerVisible = true; | 750 | this.outerVisible = true; |
| 489 | this.dialogStatus="create"; | 751 | this.dialogStatus="create"; |
| 490 | this.FenStatus='ediAwbh'; | 752 | this.FenStatus='ediAwbh'; |
| 491 | - this.ruleForm.flightno=this.$route.params.flightno; | ||
| 492 | - this.ruleForm.flightdate=this.$route.params.flightdate; | ||
| 493 | - this.ruleForm.originstation=this.$route.params.originstation; | ||
| 494 | - this.ruleForm.destinationstation=this.$route.params.destinationstation; | 753 | + this.ruleForm.flightno=JSON.parse(this.$route.query.flightno); |
| 754 | + this.ruleForm.flightdate=JSON.parse(this.$route.query.flightdate); | ||
| 755 | + this.ruleForm.originstation=JSON.parse(this.$route.query.originstation); | ||
| 756 | + this.ruleForm.destinationstation=JSON.parse(this.$route.query.destinationstation); | ||
| 495 | }, | 757 | }, |
| 496 | //新增原始舱单数据 | 758 | //新增原始舱单数据 |
| 497 | createData(formName){ | 759 | createData(formName){ |
| 498 | this.$refs[formName].validate((valid) => { | 760 | this.$refs[formName].validate((valid) => { |
| 499 | if (valid) { | 761 | if (valid) { |
| 762 | + this.ruleForm.status='22'; | ||
| 763 | + //this.ruleForm.endtime=this.ruleForm.starttime.add(Calendar.MINUTE, 15); | ||
| 500 | addMt5201(this.ruleForm).then(res=>{ | 764 | addMt5201(this.ruleForm).then(res=>{ |
| 501 | let response=res.data; | 765 | let response=res.data; |
| 502 | this.code=response.code; | 766 | this.code=response.code; |
| @@ -543,6 +807,9 @@ | @@ -543,6 +807,9 @@ | ||
| 543 | } | 807 | } |
| 544 | }); | 808 | }); |
| 545 | }, | 809 | }, |
| 810 | + back(){ | ||
| 811 | + this.$router.go(-1);//返回上一层 | ||
| 812 | + }, | ||
| 546 | }, | 813 | }, |
| 547 | //渲染方法 | 814 | //渲染方法 |
| 548 | mounted(){ | 815 | mounted(){ |
| @@ -15,7 +15,7 @@ | @@ -15,7 +15,7 @@ | ||
| 15 | </el-col> | 15 | </el-col> |
| 16 | <el-col :span="5"> | 16 | <el-col :span="5"> |
| 17 | <div class="grid-content"> | 17 | <div class="grid-content"> |
| 18 | - <el-input placeholder="" v-model="defaultQuery.carrier"> | 18 | + <el-input placeholder="" v-model="vcarrier"> |
| 19 | <template slot="prepend">承运人</template> | 19 | <template slot="prepend">承运人</template> |
| 20 | </el-input> | 20 | </el-input> |
| 21 | </div> | 21 | </div> |
| @@ -67,9 +67,9 @@ | @@ -67,9 +67,9 @@ | ||
| 67 | <el-col :span="8" style="margin-right: 0px"> | 67 | <el-col :span="8" style="margin-right: 0px"> |
| 68 | <el-button type="primary" v-on:click="QueryData">查询</el-button> | 68 | <el-button type="primary" v-on:click="QueryData">查询</el-button> |
| 69 | </el-col> | 69 | </el-col> |
| 70 | - <el-col :span="16" style="margin-right: 0px"> | 70 | + <!--<el-col :span="16" style="margin-right: 0px"> |
| 71 | <el-button type="primary">批量修改状态</el-button> | 71 | <el-button type="primary">批量修改状态</el-button> |
| 72 | - </el-col> | 72 | + </el-col>--> |
| 73 | </el-col> | 73 | </el-col> |
| 74 | </el-row> | 74 | </el-row> |
| 75 | <!--查询结果样式--> | 75 | <!--查询结果样式--> |
| @@ -85,10 +85,12 @@ | @@ -85,10 +85,12 @@ | ||
| 85 | <el-col :span="24"> | 85 | <el-col :span="24"> |
| 86 | <template> | 86 | <template> |
| 87 | <el-table | 87 | <el-table |
| 88 | + v-loading="tableloading" | ||
| 88 | ref="multipleTable" | 89 | ref="multipleTable" |
| 89 | :data="tableData" | 90 | :data="tableData" |
| 90 | tooltip-effect="dark" | 91 | tooltip-effect="dark" |
| 91 | style="width: 100%" | 92 | style="width: 100%" |
| 93 | + :default-sort = "{prop: 'date', order: 'descending'}" | ||
| 92 | @selection-change="handleSelectionChange"> | 94 | @selection-change="handleSelectionChange"> |
| 93 | <el-table-column | 95 | <el-table-column |
| 94 | type="selection" | 96 | type="selection" |
| @@ -97,21 +99,22 @@ | @@ -97,21 +99,22 @@ | ||
| 97 | <el-table-column | 99 | <el-table-column |
| 98 | fixed="left" | 100 | fixed="left" |
| 99 | label="操作" | 101 | label="操作" |
| 100 | - width="135"> | 102 | + width="75"> |
| 101 | <template slot-scope="scope"> | 103 | <template slot-scope="scope"> |
| 102 | <el-button | 104 | <el-button |
| 103 | - v-if="scope.row.rcfdep=='MT1201'" | 105 | + v-if="scope.row.stype=='MT1201'" |
| 104 | @click="handleClick(scope.row)" type="text" size="small">原始舱单</el-button> | 106 | @click="handleClick(scope.row)" type="text" size="small">原始舱单</el-button> |
| 105 | <el-button | 107 | <el-button |
| 106 | v-else | 108 | v-else |
| 107 | @click="handleTally(scope.row)" type="text" size="small">进港理货</el-button> | 109 | @click="handleTally(scope.row)" type="text" size="small">进港理货</el-button> |
| 108 | - <el-button @click="handleClick(scope.row)" type="text" size="small">修改状态</el-button> | ||
| 109 | </template> | 110 | </template> |
| 110 | </el-table-column> | 111 | </el-table-column> |
| 111 | <el-table-column | 112 | <el-table-column |
| 112 | - prop="carrierno" | ||
| 113 | label="航班号" | 113 | label="航班号" |
| 114 | width="75"> | 114 | width="75"> |
| 115 | + <template slot-scope="scope"> | ||
| 116 | + <span>{{scope.row.carrier}}{{scope.row.flightno}}</span> | ||
| 117 | + </template> | ||
| 115 | </el-table-column> | 118 | </el-table-column> |
| 116 | <el-table-column | 119 | <el-table-column |
| 117 | prop="flightdate" | 120 | prop="flightdate" |
| @@ -119,16 +122,30 @@ | @@ -119,16 +122,30 @@ | ||
| 119 | width="95"> | 122 | width="95"> |
| 120 | </el-table-column> | 123 | </el-table-column> |
| 121 | <el-table-column | 124 | <el-table-column |
| 122 | - prop="segment" | ||
| 123 | label="航段" | 125 | label="航段" |
| 124 | - width="85" | ||
| 125 | - > | 126 | + width="90"> |
| 127 | + <template slot-scope="scope"> | ||
| 128 | + <span>{{scope.row.originstation}}-{{scope.row.destinationstation}}</span> | ||
| 129 | + </template> | ||
| 126 | </el-table-column> | 130 | </el-table-column> |
| 127 | <el-table-column | 131 | <el-table-column |
| 128 | - prop="awba" | ||
| 129 | label="主单号" | 132 | label="主单号" |
| 130 | width="115" | 133 | width="115" |
| 131 | > | 134 | > |
| 135 | + <template slot-scope="scope"> | ||
| 136 | + <span v-if="scope.row.stype=='MT1201'&&scope.row.awbh==''" style="background-color:#67C23A;width: 100%;height:100%;display:block"> | ||
| 137 | + {{scope.row.awba}} | ||
| 138 | + </span> | ||
| 139 | + <span v-else-if="scope.row.stype=='MT1201'&&scope.row.awbh!=''" style="background-color:#409eff;width: 100%;height:100%;display:block;"> | ||
| 140 | + {{scope.row.awba}} | ||
| 141 | + </span> | ||
| 142 | + <span v-else-if="scope.row.stype=='MT5201'&&scope.row.awbh==''" style="background-color:#FF8C00;width: 100%;height:100%;display:block;"> | ||
| 143 | + {{scope.row.awba}} | ||
| 144 | + </span> | ||
| 145 | + <span v-else-if="scope.row.stype=='MT5201'&&scope.row.awbh!=''" style="background-color:#e6a23c;width: 100%;height:100%;display:block;"> | ||
| 146 | + {{scope.row.awba}} | ||
| 147 | + </span> | ||
| 148 | + </template> | ||
| 132 | </el-table-column> | 149 | </el-table-column> |
| 133 | <el-table-column | 150 | <el-table-column |
| 134 | prop="awbh" | 151 | prop="awbh" |
| @@ -138,7 +155,7 @@ | @@ -138,7 +155,7 @@ | ||
| 138 | <el-table-column | 155 | <el-table-column |
| 139 | prop="piece" | 156 | prop="piece" |
| 140 | label="件数" | 157 | label="件数" |
| 141 | - width="50"> | 158 | + width="60"> |
| 142 | </el-table-column> | 159 | </el-table-column> |
| 143 | <el-table-column | 160 | <el-table-column |
| 144 | prop="weight" | 161 | prop="weight" |
| @@ -159,12 +176,25 @@ | @@ -159,12 +176,25 @@ | ||
| 159 | <el-table-column | 176 | <el-table-column |
| 160 | prop="status" | 177 | prop="status" |
| 161 | label="状态" | 178 | label="状态" |
| 162 | - width="90"> | 179 | + width="90" :formatter="formatStatus"> |
| 163 | </el-table-column> | 180 | </el-table-column> |
| 164 | <el-table-column | 181 | <el-table-column |
| 165 | - prop="repick" | ||
| 166 | label="回执内容" | 182 | label="回执内容" |
| 167 | width="250"> | 183 | width="250"> |
| 184 | + <template slot-scope="scope"> | ||
| 185 | + <span v-if="scope.row.status=='01' || scope.row.status=='11'" style="color: #67C23A"> | ||
| 186 | + {{scope.row.ext5}} | ||
| 187 | + </span> | ||
| 188 | + <span v-else-if="scope.row.status=='02' || scope.row.status=='03'" style="color: #E6A23C"> | ||
| 189 | + {{scope.row.ext5}} | ||
| 190 | + </span> | ||
| 191 | + <span v-else-if="scope.row.status=='12' || scope.row.status=='13'" style="color: #F56C6C"> | ||
| 192 | + {{scope.row.ext5}} | ||
| 193 | + </span> | ||
| 194 | + <span v-else style="color: #909399;"> | ||
| 195 | + {{scope.row.ext5}} | ||
| 196 | + </span> | ||
| 197 | + </template> | ||
| 168 | </el-table-column> | 198 | </el-table-column> |
| 169 | </el-table> | 199 | </el-table> |
| 170 | </template> | 200 | </template> |
| @@ -177,11 +207,11 @@ | @@ -177,11 +207,11 @@ | ||
| 177 | <el-pagination | 207 | <el-pagination |
| 178 | @size-change="handleSizeChange" | 208 | @size-change="handleSizeChange" |
| 179 | @current-change="handleCurrentChange" | 209 | @current-change="handleCurrentChange" |
| 180 | - :current-page="currentPage4" | 210 | + :current-page="currentPage" |
| 181 | :page-sizes="[100, 200, 300, 400]" | 211 | :page-sizes="[100, 200, 300, 400]" |
| 182 | - :page-size="100" | 212 | + :page-size="pageSize" |
| 183 | layout="total, sizes, prev, pager, next, jumper" | 213 | layout="total, sizes, prev, pager, next, jumper" |
| 184 | - :total="400"> | 214 | + :total="total"> |
| 185 | </el-pagination> | 215 | </el-pagination> |
| 186 | </div> | 216 | </div> |
| 187 | </el-col> | 217 | </el-col> |
| @@ -198,12 +228,15 @@ | @@ -198,12 +228,15 @@ | ||
| 198 | .sel{display: inline;} | 228 | .sel{display: inline;} |
| 199 | .mark{height:24px;} | 229 | .mark{height:24px;} |
| 200 | .bg{height:24px;text-align: center;line-height:24px;min-height: 24px} | 230 | .bg{height:24px;text-align: center;line-height:24px;min-height: 24px} |
| 201 | - .mainse{background: #5BB75B} | ||
| 202 | - .fense{background-color: #12B399} | ||
| 203 | - .tallse{background-color: #FA9403} | ||
| 204 | - .tallfense{background-color: #C55124} | 231 | + .mainse{background: #67C23A} |
| 232 | + .fense{background-color: #409eff} | ||
| 233 | + .tallse{background-color: #FF8C00} | ||
| 234 | + .tallfense{background-color: #e6a23c} | ||
| 205 | .cell{background: #5BB75B} | 235 | .cell{background: #5BB75B} |
| 206 | .cell2{background-color: #12B399} | 236 | .cell2{background-color: #12B399} |
| 237 | + .el-input-group{ | ||
| 238 | + display: table; | ||
| 239 | + } | ||
| 207 | </style> | 240 | </style> |
| 208 | <script> | 241 | <script> |
| 209 | import { QueryData } from '../../api/wayDeclaration' | 242 | import { QueryData } from '../../api/wayDeclaration' |
| @@ -220,22 +253,22 @@ | @@ -220,22 +253,22 @@ | ||
| 220 | }, | 253 | }, |
| 221 | options: [ | 254 | options: [ |
| 222 | { | 255 | { |
| 223 | - value: '01', | ||
| 224 | - label: '选择状态' | 256 | + value: '', |
| 257 | + label: '业务状态' | ||
| 225 | }, { | 258 | }, { |
| 226 | - value: '02', | 259 | + value: '22', |
| 227 | label: '未发送' | 260 | label: '未发送' |
| 228 | }, { | 261 | }, { |
| 229 | - value: '03', | 262 | + value: '23', |
| 230 | label: '已发舱单报' | 263 | label: '已发舱单报' |
| 231 | }, { | 264 | }, { |
| 232 | - value: '04', | 265 | + value: '03', |
| 233 | label: '舱单报退单' | 266 | label: '舱单报退单' |
| 234 | }], | 267 | }], |
| 235 | options2: [ | 268 | options2: [ |
| 236 | { | 269 | { |
| 237 | value: '', | 270 | value: '', |
| 238 | - label: '选择状态' | 271 | + label: '业务类型' |
| 239 | }, { | 272 | }, { |
| 240 | value: 'MT1201', | 273 | value: 'MT1201', |
| 241 | label: '原始舱单' | 274 | label: '原始舱单' |
| @@ -245,7 +278,10 @@ | @@ -245,7 +278,10 @@ | ||
| 245 | }], | 278 | }], |
| 246 | tableData: [], | 279 | tableData: [], |
| 247 | multipleSelection: [], | 280 | multipleSelection: [], |
| 248 | - currentPage4: 4 | 281 | + currentPage:1, |
| 282 | + pageSize:100, | ||
| 283 | + total:0, | ||
| 284 | + tableloading:false | ||
| 249 | } | 285 | } |
| 250 | }, | 286 | }, |
| 251 | methods:{ | 287 | methods:{ |
| @@ -256,25 +292,41 @@ | @@ -256,25 +292,41 @@ | ||
| 256 | console.log(row); | 292 | console.log(row); |
| 257 | }, | 293 | }, |
| 258 | handleSizeChange(val) { | 294 | handleSizeChange(val) { |
| 259 | - console.log(`每页 ${val} 条`); | 295 | + this.pageSize=val; |
| 296 | + this.QueryData(); | ||
| 260 | }, | 297 | }, |
| 261 | handleCurrentChange(val) { | 298 | handleCurrentChange(val) { |
| 262 | - console.log(`当前页: ${val}`); | 299 | + this.currentPage=val; |
| 300 | + this.QueryData(); | ||
| 301 | + }, | ||
| 302 | + //状态适配 | ||
| 303 | + formatStatus:function (row,column) { | ||
| 304 | + return row.status=='01'?'接受申报':row.status=='02'?'待人工审核':row.status=='03'?'退单' | ||
| 305 | + :row.status=='11'?'放行':row.status=='12'?'拒装':row.status=='13'?'禁卸' | ||
| 306 | + :row.status=='21'?'可自动发送':row.status=='22'?'未发送':row.status=='23'?'已发送新增报' | ||
| 307 | + :row.status=='24'?'已发送删除报':row.status=='25'?'已发送修改报':''; | ||
| 263 | }, | 308 | }, |
| 264 | //条件查询方法 | 309 | //条件查询方法 |
| 265 | QueryData(){ | 310 | QueryData(){ |
| 266 | - QueryData(this.defaultQuery).then(res =>{ | ||
| 267 | - //console.log(res); | 311 | + let params={currentPage:this.currentPage,pageSize:this.pageSize,awba:this.defaultQuery.awba,carrier:this.defaultQuery.carrier, |
| 312 | + flightno:this.defaultQuery.flightno,flightdate:this.defaultQuery.flightdate,status:this.defaultQuery.status,messageType:this.defaultQuery.messageType}; | ||
| 313 | + this.tableloading=true; | ||
| 314 | + QueryData(params).then(res =>{ | ||
| 268 | let response=res.data.data; | 315 | let response=res.data.data; |
| 269 | - this.tableData=response; | 316 | + console.log(response) |
| 317 | + this.tableData=response.list; | ||
| 318 | + this.total=response.total; | ||
| 319 | + this.tableloading = false; | ||
| 270 | }); | 320 | }); |
| 271 | }, | 321 | }, |
| 272 | //点击进入原始页面 | 322 | //点击进入原始页面 |
| 273 | handleClick(row){ | 323 | handleClick(row){ |
| 274 | - this.$router.push({name:'进港原始舱单',params:{flightno:row.carrierno,destinationstation:row.destinationstation,awba:row.awba,flightdate:row.flightdate,originstation:row.originstation}}); | 324 | + this.$router.push({path:'/origmaster',query:{flightno:JSON.stringify(row.carrier+row.flightno),destinationstation:JSON.stringify(row.destinationstation),awba:JSON.stringify(row.awba),flightdate:JSON.stringify(row.flightdate),originstation:JSON.stringify(row.originstation)}}); |
| 275 | }, | 325 | }, |
| 276 | //点击进入理货页面 | 326 | //点击进入理货页面 |
| 277 | - handleTally(row){}, | 327 | + handleTally(row){ |
| 328 | + this.$router.push({path:'/tallymaster',query:{flightno:JSON.stringify(row.carrier+row.flightno),destinationstation:JSON.stringify(row.destinationstation),awba:JSON.stringify(row.awba),flightdate:JSON.stringify(row.flightdate),originstation:JSON.stringify(row.originstation)}}); | ||
| 329 | + }, | ||
| 278 | //table显示时间转换 | 330 | //table显示时间转换 |
| 279 | timestampToTime(timestamp) { | 331 | timestampToTime(timestamp) { |
| 280 | var date = new Date(timestamp);//时间戳为10位需*1000,时间戳为13位的话不需乘1000 | 332 | var date = new Date(timestamp);//时间戳为10位需*1000,时间戳为13位的话不需乘1000 |
| @@ -286,7 +338,17 @@ | @@ -286,7 +338,17 @@ | ||
| 286 | var s = (date.getSeconds() < 10 ? '0'+date.getSeconds() : date.getSeconds()); | 338 | var s = (date.getSeconds() < 10 ? '0'+date.getSeconds() : date.getSeconds()); |
| 287 | return Y+M+D+h+m+s; | 339 | return Y+M+D+h+m+s; |
| 288 | }, | 340 | }, |
| 341 | + }, | ||
| 342 | + computed:{ | ||
| 343 | + vcarrier:{ | ||
| 344 | + get:function () { | ||
| 345 | + return this.defaultQuery.carrier; | ||
| 346 | + }, | ||
| 347 | + set:function (val) { | ||
| 348 | + this.defaultQuery.carrier=val.toUpperCase(); | ||
| 289 | } | 349 | } |
| 350 | + } | ||
| 351 | + }, | ||
| 290 | 352 | ||
| 291 | } | 353 | } |
| 292 | </script> | 354 | </script> |
static/favicon.ico
100755 → 100644
不能预览此文件类型
static/favicon.ico.bal
0 → 100755
不能预览此文件类型
static/images/air-banner.png
0 → 100644
82.3 KB
-
请 注册 或 登录 后发表评论