正在显示
12 个修改的文件
包含
192 行增加
和
84 行删除
@@ -29,7 +29,8 @@ module.exports = { | @@ -29,7 +29,8 @@ module.exports = { | ||
29 | assetsPublicPath: '/', | 29 | assetsPublicPath: '/', |
30 | proxyTable: { | 30 | proxyTable: { |
31 | '/api':{ | 31 | '/api':{ |
32 | - target: 'http://192.168.1.53:12343',//设置你调用的接口域名和端口号 别忘了加http | 32 | + // target: 'http://192.168.1.53:12343',//设置你调用的接口域名和端口号 别忘了加http |
33 | + target: 'http://localhost:12343',//设置你调用的接口域名和端口号 别忘了加http | ||
33 | changeOrigin: true, | 34 | changeOrigin: true, |
34 | pathRewrite: { | 35 | pathRewrite: { |
35 | '^/api': '/'//这里理解成用‘/api’代替target里面的地址,后面组件中我们掉接口时直接用api代替 比如我要调用'http://40.00.100.100:3002/user/add',直接写‘/api/user/add’即可 | 36 | '^/api': '/'//这里理解成用‘/api’代替target里面的地址,后面组件中我们掉接口时直接用api代替 比如我要调用'http://40.00.100.100:3002/user/add',直接写‘/api/user/add’即可 |
@@ -8,7 +8,7 @@ export const deleteByIsDelete = params => { return http.del(`${baseUrl}/deleteBy | @@ -8,7 +8,7 @@ export const deleteByIsDelete = params => { return http.del(`${baseUrl}/deleteBy | ||
8 | 8 | ||
9 | export const updateStatus = params => { return http.put(`${baseUrl}/updateStatus`, params) }; | 9 | export const updateStatus = params => { return http.put(`${baseUrl}/updateStatus`, params) }; |
10 | 10 | ||
11 | -export const updateMT2201 = params => { return http.put(`${baseUrl}/updateMT2201`,params)}; | 11 | +export const updateMT2201 = params => { return http.put(`${baseUrl}/updateMt2201`,params)}; |
12 | 12 | ||
13 | export const addMt2201 = params => { return http.post(`${baseUrl}/addMt2201`,params)}; | 13 | export const addMt2201 = params => { return http.post(`${baseUrl}/addMt2201`,params)}; |
14 | 14 |
@@ -29,12 +29,12 @@ export default { | @@ -29,12 +29,12 @@ export default { | ||
29 | }, | 29 | }, |
30 | limit: { | 30 | limit: { |
31 | type: Number, | 31 | type: Number, |
32 | - default: 20 | 32 | + default: 100 |
33 | }, | 33 | }, |
34 | pageSizes: { | 34 | pageSizes: { |
35 | type: Array, | 35 | type: Array, |
36 | default() { | 36 | default() { |
37 | - return [10, 20, 30, 50] | 37 | + return [10, 20, 30, 50, 100] |
38 | } | 38 | } |
39 | }, | 39 | }, |
40 | layout: { | 40 | layout: { |
@@ -92,7 +92,7 @@ export default { | @@ -92,7 +92,7 @@ export default { | ||
92 | <style scoped> | 92 | <style scoped> |
93 | .pagination-container { | 93 | .pagination-container { |
94 | background: #fff; | 94 | background: #fff; |
95 | - padding: 32px 16px; | 95 | + /*padding: 32px 16px;*/ |
96 | } | 96 | } |
97 | .pagination-container.hidden { | 97 | .pagination-container.hidden { |
98 | display: none; | 98 | display: none; |
@@ -33,8 +33,8 @@ Vue.use(Vuex) | @@ -33,8 +33,8 @@ Vue.use(Vuex) | ||
33 | Vue.prototype.$axios = axios; | 33 | Vue.prototype.$axios = axios; |
34 | 34 | ||
35 | //NProgress.configure({ showSpinner: false }); | 35 | //NProgress.configure({ showSpinner: false }); |
36 | -console.log("mainjs:"); | ||
37 | -console.log(rout.routes); | 36 | +// console.log("mainjs:"); |
37 | +// console.log(rout.routes); | ||
38 | const router = new VueRouter({ | 38 | const router = new VueRouter({ |
39 | routes:rout.routes | 39 | routes:rout.routes |
40 | }); | 40 | }); |
@@ -61,7 +61,7 @@ router.beforeEach((to, from, next) => { | @@ -61,7 +61,7 @@ router.beforeEach((to, from, next) => { | ||
61 | } | 61 | } |
62 | }); | 62 | }); |
63 | 63 | ||
64 | -var message = Vue.prototype.$message; | 64 | +const message = Vue.prototype.$message; |
65 | axios.defaults.baseURL = '/api'; | 65 | axios.defaults.baseURL = '/api'; |
66 | axios.interceptors.response.use( | 66 | axios.interceptors.response.use( |
67 | res => { | 67 | res => { |
@@ -15,9 +15,9 @@ import ExitArrive from './views/nmms/ExitArrive.vue' | @@ -15,9 +15,9 @@ import ExitArrive from './views/nmms/ExitArrive.vue' | ||
15 | import ExitManifest from './views/nmms/ExitManifest.vue' | 15 | import ExitManifest from './views/nmms/ExitManifest.vue' |
16 | import ExitLoading from './views/nmms/ExitLoading.vue' | 16 | import ExitLoading from './views/nmms/ExitLoading.vue' |
17 | import ExitFlightDesc from './views/nmms/ExitFlightDesc.vue' | 17 | import ExitFlightDesc from './views/nmms/ExitFlightDesc.vue' |
18 | -import LostLoadChange from './views/lostLoadChange/lostLoadChange.vue' | ||
19 | import LostLoad from './views/lostLoadChange/lostLoading.vue' | 18 | import LostLoad from './views/lostLoadChange/lostLoading.vue' |
20 | -// import Form from './views/nav1/Form.vue' | 19 | +import LostLoadChange from './views/lostLoadChange/lostLoadChange.vue' |
20 | + | ||
21 | 21 | ||
22 | import User from './views/nav1/user.vue' | 22 | import User from './views/nav1/user.vue' |
23 | import Page4 from './views/nav2/Page4.vue' | 23 | import Page4 from './views/nav2/Page4.vue' |
@@ -77,8 +77,8 @@ let routes = [ | @@ -77,8 +77,8 @@ let routes = [ | ||
77 | iconCls: 'el-icon-collection', | 77 | iconCls: 'el-icon-collection', |
78 | children: [ | 78 | children: [ |
79 | {path: '/flight', component: ExitFlight, name: '出港航班申报'}, | 79 | {path: '/flight', component: ExitFlight, name: '出港航班申报'}, |
80 | - {path: '/pre', component: ExitPre, name: '出港预配舱单'}, | ||
81 | {path: '/manifest', component: ExitManifest, name: '出港运单申报'}, | 80 | {path: '/manifest', component: ExitManifest, name: '出港运单申报'}, |
81 | + {path: '/pre', component: ExitPre, name: '出港预配舱单'}, | ||
82 | {path: '/arrive', component: ExitArrive, name: '出港运抵'}, | 82 | {path: '/arrive', component: ExitArrive, name: '出港运抵'}, |
83 | {path: '/loadingView', component: ExitFlightDesc, name: '出港航班信息'}, | 83 | {path: '/loadingView', component: ExitFlightDesc, name: '出港航班信息'}, |
84 | {path: '/loading', component: ExitLoading, name: '出港装载'}, | 84 | {path: '/loading', component: ExitLoading, name: '出港装载'}, |
@@ -43,7 +43,7 @@ export function validAlphabetsAndNum(str) { | @@ -43,7 +43,7 @@ export function validAlphabetsAndNum(str) { | ||
43 | 43 | ||
44 | /* 大小写字母数字空格*/ | 44 | /* 大小写字母数字空格*/ |
45 | export function validAlphabetsAndSpanceKey(str) { | 45 | export function validAlphabetsAndSpanceKey(str) { |
46 | - const reg = /^[0-9a-zA-Z ]+$/ | 46 | + const reg = /^[0-9a-zA-Z\s]+$/ |
47 | return reg.test(str) | 47 | return reg.test(str) |
48 | } | 48 | } |
49 | 49 | ||
@@ -88,3 +88,14 @@ export function validEmail(email) { | @@ -88,3 +88,14 @@ export function validEmail(email) { | ||
88 | const re = /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/ | 88 | const re = /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/ |
89 | return re.test(email) | 89 | return re.test(email) |
90 | } | 90 | } |
91 | + | ||
92 | +/** | ||
93 | + * | ||
94 | + * 整数和小数,小数最多两位 | ||
95 | + * @param value | ||
96 | + * @returns {boolean} | ||
97 | + */ | ||
98 | +export function validatorNum(value) { | ||
99 | + const reg = /^(\d*)+(\.[0-9]{1,2})?$/ | ||
100 | + return reg.test(value) | ||
101 | +} |
@@ -60,7 +60,7 @@ | @@ -60,7 +60,7 @@ | ||
60 | <template slot-scope="scope"> | 60 | <template slot-scope="scope"> |
61 | <span v-if="scope.row.offload ==='001'">未落装</span> | 61 | <span v-if="scope.row.offload ==='001'">未落装</span> |
62 | <span v-if="scope.row.offload ==='002'">已落装</span> | 62 | <span v-if="scope.row.offload ==='002'">已落装</span> |
63 | - <span v-if="scope.row.offload ==='003'">以落装改配</span> | 63 | + <span v-if="scope.row.offload ==='003'">已落装改配</span> |
64 | </template> | 64 | </template> |
65 | </el-table-column> | 65 | </el-table-column> |
66 | <el-table-column label="状态" width="90px" align="center"> | 66 | <el-table-column label="状态" width="90px" align="center"> |
@@ -119,7 +119,7 @@ | @@ -119,7 +119,7 @@ | ||
119 | <el-button size="mini" type="primary" @click="handleAwbSend(scope.row)" | 119 | <el-button size="mini" type="primary" @click="handleAwbSend(scope.row)" |
120 | :disabled="scope.row.status !=='00'">发送舱单报 | 120 | :disabled="scope.row.status !=='00'">发送舱单报 |
121 | </el-button> | 121 | </el-button> |
122 | - <el-button size="mini" type="danger" @click="handleAwbDelete(scope.row)">发删除报</el-button> | 122 | + <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单</el-button> |
123 | 123 | ||
124 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" | 124 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" |
125 | :disabled="scope.row.status ==='00'">修改状态 | 125 | :disabled="scope.row.status ==='00'">修改状态 |
@@ -288,7 +288,7 @@ | @@ -288,7 +288,7 @@ | ||
288 | 288 | ||
289 | import {getMt3201ListForParam, deleteByIsDelete, updateStatus, updateMT3201, addMt3201} from '@/api/exitArrive' | 289 | import {getMt3201ListForParam, deleteByIsDelete, updateStatus, updateMT3201, addMt3201} from '@/api/exitArrive' |
290 | import {Message} from "element-ui"; | 290 | import {Message} from "element-ui"; |
291 | - import {validAwb, validAlphabets, validAlphabetsAndNum,validAlphabetsAndSpanceKey} from "@/utils/validate"; | 291 | + import {validAwb, validAlphabets, validAlphabetsAndNum,validAlphabetsAndSpanceKey,validatorNum} from "@/utils/validate"; |
292 | import {getResponseForParam} from '@/api/responseDetail' | 292 | import {getResponseForParam} from '@/api/responseDetail' |
293 | 293 | ||
294 | export default { | 294 | export default { |
@@ -320,9 +320,16 @@ | @@ -320,9 +320,16 @@ | ||
320 | } | 320 | } |
321 | callback() | 321 | callback() |
322 | } | 322 | } |
323 | + const validatorNums = (rule, value, callback) => { | ||
324 | + if (!validatorNum(value)) { | ||
325 | + callback("只能输入数字,并且小数位最多两位") | ||
326 | + } | ||
327 | + callback() | ||
328 | + } | ||
323 | return { | 329 | return { |
324 | func: treeToArray, | 330 | func: treeToArray, |
325 | total: 1, | 331 | total: 1, |
332 | + isAdmin: false, | ||
326 | arriveQuery: { | 333 | arriveQuery: { |
327 | pageSize: 1, | 334 | pageSize: 1, |
328 | limitSize: 100, | 335 | limitSize: 100, |
@@ -353,8 +360,8 @@ | @@ -353,8 +360,8 @@ | ||
353 | flightno: [{required: true, trigger: 'blur', validator: validatorAwbh}], | 360 | flightno: [{required: true, trigger: 'blur', validator: validatorAwbh}], |
354 | originstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], | 361 | originstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], |
355 | destinationstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], | 362 | destinationstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], |
356 | - piece: [{type: 'number', required: true, trigger: 'change', message: '只能输入数字'}], | ||
357 | - weight: [{type: 'number', required: true, trigger: 'change', message: '只能输入数字'}], | 363 | + weight: [{required: true, trigger: 'change', validator: validatorNums}], |
364 | + piece: [{required: true, trigger: 'change', validator: validatorNums}], | ||
358 | }, | 365 | }, |
359 | arriveData: [], | 366 | arriveData: [], |
360 | detailData: [], | 367 | detailData: [], |
@@ -389,6 +396,10 @@ | @@ -389,6 +396,10 @@ | ||
389 | this.arriveQuery.destinationstation = this.$route.params.flightData.destinationstation | 396 | this.arriveQuery.destinationstation = this.$route.params.flightData.destinationstation |
390 | this.getList() | 397 | this.getList() |
391 | } | 398 | } |
399 | + let username = JSON.parse(sessionStorage.getItem('user')).username | ||
400 | + if(username === 'admin'){ | ||
401 | + this.isAdmin = true | ||
402 | + } | ||
392 | }, | 403 | }, |
393 | computed: { | 404 | computed: { |
394 | awba: { | 405 | awba: { |
@@ -107,7 +107,7 @@ | @@ -107,7 +107,7 @@ | ||
107 | <el-button size="mini" type="primary" @click="handleSendAwb(scope.row)" | 107 | <el-button size="mini" type="primary" @click="handleSendAwb(scope.row)" |
108 | :disabled="scope.row.status !=='00'">发送舱单报 | 108 | :disabled="scope.row.status !=='00'">发送舱单报 |
109 | </el-button> | 109 | </el-button> |
110 | - <el-button size="mini" type="danger" @click="handleAwbDelete(scope.row)">发删除报</el-button> | 110 | + <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单</el-button> |
111 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" | 111 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" |
112 | :disabled="scope.row.status ==='00'">更改状态 | 112 | :disabled="scope.row.status ==='00'">更改状态 |
113 | </el-button> | 113 | </el-button> |
@@ -196,12 +196,12 @@ | @@ -196,12 +196,12 @@ | ||
196 | <el-row> | 196 | <el-row> |
197 | <el-col :span="7.5"> | 197 | <el-col :span="7.5"> |
198 | <el-form-item label="运单件数" prop="price"> | 198 | <el-form-item label="运单件数" prop="price"> |
199 | - <el-input v-model.number="loadingModel.awbprice"></el-input> | 199 | + <el-input v-model="loadingModel.awbprice"></el-input> |
200 | </el-form-item> | 200 | </el-form-item> |
201 | </el-col> | 201 | </el-col> |
202 | <el-col :span="7.5"> | 202 | <el-col :span="7.5"> |
203 | <el-form-item label="运单重量" prop="weight"> | 203 | <el-form-item label="运单重量" prop="weight"> |
204 | - <el-input v-model.number="loadingModel.awbweight"></el-input> | 204 | + <el-input v-model="loadingModel.awbweight"></el-input> |
205 | </el-form-item> | 205 | </el-form-item> |
206 | </el-col> | 206 | </el-col> |
207 | <el-col :span="7.5"> | 207 | <el-col :span="7.5"> |
@@ -211,7 +211,6 @@ | @@ -211,7 +211,6 @@ | ||
211 | :value="item"></el-option> | 211 | :value="item"></el-option> |
212 | </el-select> | 212 | </el-select> |
213 | </el-form-item> | 213 | </el-form-item> |
214 | - | ||
215 | </el-col> | 214 | </el-col> |
216 | </el-row> | 215 | </el-row> |
217 | <el-row> | 216 | <el-row> |
@@ -281,7 +280,7 @@ | @@ -281,7 +280,7 @@ | ||
281 | import Pagination from '@/components/Pagination' | 280 | import Pagination from '@/components/Pagination' |
282 | import {getMt4201ListForParam, deleteByIsDelete, updateStatus, updateMT4201, addMt4201} from '@/api/exitLoading' | 281 | import {getMt4201ListForParam, deleteByIsDelete, updateStatus, updateMT4201, addMt4201} from '@/api/exitLoading' |
283 | import {Message} from "element-ui"; | 282 | import {Message} from "element-ui"; |
284 | - import {validAwb, validAlphabets, validAlphabetsAndNum, validAlphabetsAndSpanceKey} from "@/utils/validate" | 283 | + import {validAwb, validAlphabets, validAlphabetsAndNum, validAlphabetsAndSpanceKey,validatorNum} from "@/utils/validate" |
285 | export default { | 284 | export default { |
286 | name: "ExitLoading", | 285 | name: "ExitLoading", |
287 | components: {treeTable, Pagination}, | 286 | components: {treeTable, Pagination}, |
@@ -311,9 +310,16 @@ | @@ -311,9 +310,16 @@ | ||
311 | } | 310 | } |
312 | callback() | 311 | callback() |
313 | } | 312 | } |
313 | + const validatorNums = (rule, value, callback) => { | ||
314 | + if (!validatorNum(value)) { | ||
315 | + callback("只能输入数字,并且小数位最多两位") | ||
316 | + } | ||
317 | + callback() | ||
318 | + } | ||
314 | return { | 319 | return { |
315 | func: treeToArray, | 320 | func: treeToArray, |
316 | total: 1, | 321 | total: 1, |
322 | + isAdmin:false, | ||
317 | dialogMap: { | 323 | dialogMap: { |
318 | update: '编辑出港装载', | 324 | update: '编辑出港装载', |
319 | create: '添加出港装载', | 325 | create: '添加出港装载', |
@@ -380,6 +386,10 @@ | @@ -380,6 +386,10 @@ | ||
380 | this.loadingQuery.destinationstation = this.$route.params.flightData.destinationstation | 386 | this.loadingQuery.destinationstation = this.$route.params.flightData.destinationstation |
381 | this.getList() | 387 | this.getList() |
382 | } | 388 | } |
389 | + let username = JSON.parse(sessionStorage.getItem('user')).username | ||
390 | + if(username === 'admin'){ | ||
391 | + this.isAdmin = true | ||
392 | + } | ||
383 | }, | 393 | }, |
384 | computed: { | 394 | computed: { |
385 | carrier: { | 395 | carrier: { |
@@ -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="listQuery.awba" placeholder="请输入主单号"></el-input> | 35 | + <el-input v-model="listQuery.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"> |
@@ -128,18 +128,16 @@ | @@ -128,18 +128,16 @@ | ||
128 | <p></p> | 128 | <p></p> |
129 | <el-button size="mini" type="primary" @click="handleAwbEdit(scope.row)">发修改报</el-button> | 129 | <el-button size="mini" type="primary" @click="handleAwbEdit(scope.row)">发修改报</el-button> |
130 | 130 | ||
131 | - <el-button size="mini" type="danger" @click="handleAwbDelete(scope.row)">发删除报</el-button> | 131 | + <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)" | 132 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" |
133 | :disabled="scope.row.status === '01'">更改状态 | 133 | :disabled="scope.row.status === '01'">更改状态 |
134 | </el-button> | 134 | </el-button> |
135 | - | ||
136 | - | ||
137 | </template> | 135 | </template> |
138 | </el-table-column> | 136 | </el-table-column> |
139 | </tree-table> | 137 | </tree-table> |
140 | <div class="btnFoot"> | 138 | <div class="btnFoot"> |
141 | <el-row> | 139 | <el-row> |
142 | - <el-button type="primary" size="mini" | 140 | + <el-button type="primary" size="mini" v-if="preData.flightno !== undefined || preData.length> 0" |
143 | @click="handleAddpreInfo">新增预配舱单 | 141 | @click="handleAddpreInfo">新增预配舱单 |
144 | </el-button> | 142 | </el-button> |
145 | <el-button type="primary" size="mini" @click="handelBackStep" | 143 | <el-button type="primary" size="mini" @click="handelBackStep" |
@@ -162,7 +160,7 @@ | @@ -162,7 +160,7 @@ | ||
162 | </el-form-item> | 160 | </el-form-item> |
163 | </el-col> | 161 | </el-col> |
164 | <el-col :span="7.5" v-if="dialogStatus === 'addAwbh'"> | 162 | <el-col :span="7.5" v-if="dialogStatus === 'addAwbh'"> |
165 | - <el-form-item label="分单号"> | 163 | + <el-form-item label="分单号" prop="awbh"> |
166 | <el-input v-model="awbh" clearable/> | 164 | <el-input v-model="awbh" clearable/> |
167 | </el-form-item> | 165 | </el-form-item> |
168 | </el-col> | 166 | </el-col> |
@@ -204,18 +202,59 @@ | @@ -204,18 +202,59 @@ | ||
204 | </el-col> | 202 | </el-col> |
205 | </el-row> | 203 | </el-row> |
206 | <div class="grid-content content"> | 204 | <div class="grid-content content"> |
207 | - 货物信息 | 205 | + 航程信息 |
208 | </div> | 206 | </div> |
207 | + <div> | ||
208 | + <el-row> | ||
209 | + <el-col :span="7.5"> | ||
210 | + <el-form-item label="承运人" prop="carrier"> | ||
211 | + <el-input v-model="carrier" disabled clearable/> | ||
212 | + </el-form-item> | ||
213 | + </el-col> | ||
214 | + <el-col :span="7.5"> | ||
215 | + <el-form-item label="到达航站" prop="destinationstation"> | ||
216 | + <el-input v-model="destinationstation" disabled clearable/> | ||
217 | + </el-form-item> | ||
218 | + </el-col> | ||
219 | + </el-row> | ||
220 | + <el-row> | ||
221 | + <el-col :span="7.5"> | ||
222 | + <el-form-item label="承运人1"> | ||
223 | + <el-input v-model="by1" clearable/> | ||
224 | + </el-form-item> | ||
225 | + </el-col> | ||
226 | + <el-col :span="7.5"> | ||
227 | + <el-form-item label="到达航站1"> | ||
228 | + <el-input v-model="dest1" clearable></el-input> | ||
229 | + </el-form-item> | ||
230 | + </el-col> | ||
231 | + </el-row> | ||
232 | + <el-row> | ||
233 | + <el-col :span="7.5"> | ||
234 | + <el-form-item label="承运人2"> | ||
235 | + <el-input v-model="by2" clearable/> | ||
236 | + </el-form-item> | ||
237 | + </el-col> | ||
238 | + <el-col :span="7.5"> | ||
239 | + <el-form-item label="到达航站2"> | ||
240 | + <el-input v-model="dest2" clearable/> | ||
241 | + </el-form-item> | ||
242 | + </el-col> | ||
209 | 243 | ||
244 | + </el-row> | ||
245 | + </div> | ||
246 | + <div class="grid-content content"> | ||
247 | + 货物信息 | ||
248 | + </div> | ||
210 | <el-row> | 249 | <el-row> |
211 | <el-col :span="7.5"> | 250 | <el-col :span="7.5"> |
212 | - <el-form-item label="运单件数" prop="piece"> | ||
213 | - <el-input v-model.number="preModel.awbinfo.pcs" clearable/> | 251 | + <el-form-item label="运单件数" prop="awbinfo.pcs"> |
252 | + <el-input v-model="preModel.awbinfo.pcs" clearable/> | ||
214 | </el-form-item> | 253 | </el-form-item> |
215 | </el-col> | 254 | </el-col> |
216 | <el-col :span="7.5"> | 255 | <el-col :span="7.5"> |
217 | - <el-form-item label="运单重量" prop="weight"> | ||
218 | - <el-input v-model.number="preModel.awbinfo.weight" clearable/> | 256 | + <el-form-item label="运单重量" prop="awbinfo.weight"> |
257 | + <el-input v-model="preModel.awbinfo.weight" clearable/> | ||
219 | </el-form-item> | 258 | </el-form-item> |
220 | </el-col> | 259 | </el-col> |
221 | <el-col :span="7.5"> | 260 | <el-col :span="7.5"> |
@@ -227,13 +266,13 @@ | @@ -227,13 +266,13 @@ | ||
227 | <el-row> | 266 | <el-row> |
228 | <el-col :span="7.5" v-if="dialogStatus !=='addAwbh'"> | 267 | <el-col :span="7.5" v-if="dialogStatus !=='addAwbh'"> |
229 | <el-form-item label="预配件数" prop="piece"> | 268 | <el-form-item label="预配件数" prop="piece"> |
230 | - <el-input v-model.number="preModel.piece" clearable/> | 269 | + <el-input v-model="preModel.piece" clearable/> |
231 | </el-form-item> | 270 | </el-form-item> |
232 | </el-col> | 271 | </el-col> |
233 | <el-col :span="8" v-if="dialogStatus ==='addAwbh'"> | 272 | <el-col :span="8" v-if="dialogStatus ==='addAwbh'"> |
234 | <el-col :span="13"> | 273 | <el-col :span="13"> |
235 | <el-form-item label="预配件数" prop="piece"> | 274 | <el-form-item label="预配件数" prop="piece"> |
236 | - <el-input v-model.number="preModel.piece" clearable/> | 275 | + <el-input v-model="preModel.piece" clearable/> |
237 | </el-form-item> | 276 | </el-form-item> |
238 | </el-col> | 277 | </el-col> |
239 | <el-col :span="8"> | 278 | <el-col :span="8"> |
@@ -242,13 +281,13 @@ | @@ -242,13 +281,13 @@ | ||
242 | </el-col> | 281 | </el-col> |
243 | <el-col :span="7.5" v-if="dialogStatus !=='addAwbh'"> | 282 | <el-col :span="7.5" v-if="dialogStatus !=='addAwbh'"> |
244 | <el-form-item label="预配重量" prop="weight"> | 283 | <el-form-item label="预配重量" prop="weight"> |
245 | - <el-input v-model.number="preModel.weight" clearable/> | 284 | + <el-input v-model="preModel.weight" clearable/> |
246 | </el-form-item> | 285 | </el-form-item> |
247 | </el-col> | 286 | </el-col> |
248 | <el-col :span="8" v-if="dialogStatus ==='addAwbh'"> | 287 | <el-col :span="8" v-if="dialogStatus ==='addAwbh'"> |
249 | <el-col :span="13"> | 288 | <el-col :span="13"> |
250 | <el-form-item label="预配重量" prop="weight"> | 289 | <el-form-item label="预配重量" prop="weight"> |
251 | - <el-input v-model.number="preModel.weight" clearable/> | 290 | + <el-input v-model="preModel.weight" clearable/> |
252 | </el-form-item> | 291 | </el-form-item> |
253 | </el-col> | 292 | </el-col> |
254 | <el-col :span="8"> | 293 | <el-col :span="8"> |
@@ -257,10 +296,10 @@ | @@ -257,10 +296,10 @@ | ||
257 | </el-col> | 296 | </el-col> |
258 | 297 | ||
259 | <el-col :span="7.5"> | 298 | <el-col :span="7.5"> |
260 | - <el-form-item label="预配时间" prop="pretime"> | 299 | + <el-form-item label="预配时间" prop="actime"> |
261 | <el-date-picker value-format="yyyy-MM-dd HH:mm:ss" | 300 | <el-date-picker value-format="yyyy-MM-dd HH:mm:ss" |
262 | v-model="preModel.actime" align="right" | 301 | v-model="preModel.actime" align="right" |
263 | - type="date" placeholder="请选择"/> | 302 | + type="datetime" placeholder="请选择"/> |
264 | </el-form-item> | 303 | </el-form-item> |
265 | </el-col> | 304 | </el-col> |
266 | </el-row> | 305 | </el-row> |
@@ -275,7 +314,7 @@ | @@ -275,7 +314,7 @@ | ||
275 | </el-form-item> | 314 | </el-form-item> |
276 | </el-col> | 315 | </el-col> |
277 | <el-col :span="7.5"> | 316 | <el-col :span="7.5"> |
278 | - <el-form-item label="海关状态" prop="ex5"> | 317 | + <el-form-item label="海关状态"> |
279 | <el-select v-model="preModel.awbtype" class="filter-item" placeholder="请录入货物类型"> | 318 | <el-select v-model="preModel.awbtype" class="filter-item" placeholder="请录入货物类型"> |
280 | <el-option v-for="item in customTypes" :key="item.value" :label="item.label" | 319 | <el-option v-for="item in customTypes" :key="item.value" :label="item.label" |
281 | :value="item.value"/> | 320 | :value="item.value"/> |
@@ -331,7 +370,7 @@ | @@ -331,7 +370,7 @@ | ||
331 | </el-col> | 370 | </el-col> |
332 | <el-col :span="7.5"> | 371 | <el-col :span="7.5"> |
333 | <el-form-item label="城市代码"> | 372 | <el-form-item label="城市代码"> |
334 | - <el-input v-model="preModel.awbinfo.shpcitycode" clearable/> | 373 | + <el-input v-model="scityid" maxlength="5" clearable/> |
335 | </el-form-item> | 374 | </el-form-item> |
336 | </el-col> | 375 | </el-col> |
337 | </el-row> | 376 | </el-row> |
@@ -409,7 +448,7 @@ | @@ -409,7 +448,7 @@ | ||
409 | </el-col> | 448 | </el-col> |
410 | <el-col :span="7.5"> | 449 | <el-col :span="7.5"> |
411 | <el-form-item label="城市代码"> | 450 | <el-form-item label="城市代码"> |
412 | - <el-input v-model="preModel.awbinfo.cnscitycode" clearable/> | 451 | + <el-input v-model="ecityid" clearable maxlength="5"/> |
413 | </el-form-item> | 452 | </el-form-item> |
414 | </el-col> | 453 | </el-col> |
415 | </el-row> | 454 | </el-row> |
@@ -484,7 +523,7 @@ | @@ -484,7 +523,7 @@ | ||
484 | </el-form> | 523 | </el-form> |
485 | <div slot="footer" class="dialog-footer"> | 524 | <div slot="footer" class="dialog-footer"> |
486 | <el-button @click="dialogFormVisible = false">取消</el-button> | 525 | <el-button @click="dialogFormVisible = false">取消</el-button> |
487 | - <el-button type="primary" @click="dialogStatus==='create'?createData():updateData()">保存</el-button> | 526 | + <el-button type="primary" @click="dialogStatus !=='create'? createData():updateData()">保存</el-button> |
488 | <el-button type="success" @click="handleSaveAndSend">保存并发送</el-button> | 527 | <el-button type="success" @click="handleSaveAndSend">保存并发送</el-button> |
489 | </div> | 528 | </div> |
490 | </el-dialog> | 529 | </el-dialog> |
@@ -538,7 +577,13 @@ | @@ -538,7 +577,13 @@ | ||
538 | import {getMt2201ListForParam, deleteByIsDelete, updateStatus, updateMT2201, addMt2201} from '@/api/exitPre' | 577 | import {getMt2201ListForParam, deleteByIsDelete, updateStatus, updateMT2201, addMt2201} from '@/api/exitPre' |
539 | import {Message} from "element-ui"; | 578 | import {Message} from "element-ui"; |
540 | import {getResponseForParam} from '@/api/responseDetail' | 579 | import {getResponseForParam} from '@/api/responseDetail' |
541 | - import {validAwb, validAlphabets, validAlphabetsAndNum, validAlphabetsAndSpanceKey} from "@/utils/validate" | 580 | + import { |
581 | + validAwb, | ||
582 | + validAlphabets, | ||
583 | + validAlphabetsAndNum, | ||
584 | + validAlphabetsAndSpanceKey, | ||
585 | + validatorNum | ||
586 | + } from "@/utils/validate" | ||
542 | 587 | ||
543 | export default { | 588 | export default { |
544 | name: "ExitPre", | 589 | name: "ExitPre", |
@@ -569,9 +614,16 @@ | @@ -569,9 +614,16 @@ | ||
569 | } | 614 | } |
570 | callback() | 615 | callback() |
571 | } | 616 | } |
617 | + const validatorNums = (rule, value, callback) => { | ||
618 | + if (!validatorNum(value)) { | ||
619 | + callback("只能输入数字,并且小数位最多两位") | ||
620 | + } | ||
621 | + callback() | ||
622 | + } | ||
572 | return { | 623 | return { |
573 | func: treeToArray, | 624 | func: treeToArray, |
574 | total: 1, | 625 | total: 1, |
626 | + isAdmin:false, | ||
575 | listQuery: { | 627 | listQuery: { |
576 | pageSize: 1, | 628 | pageSize: 1, |
577 | limitSize: 100, | 629 | limitSize: 100, |
@@ -607,19 +659,20 @@ | @@ -607,19 +659,20 @@ | ||
607 | awbPiece: undefined, | 659 | awbPiece: undefined, |
608 | awbWeight: undefined, | 660 | awbWeight: undefined, |
609 | preRoles: { | 661 | preRoles: { |
610 | - weight: [{type: 'number', required: true, message: '重量必须为数字', trigger: 'change'}], | ||
611 | - piece: [{type: 'number', required: true, message: '件数必须为数字', trigger: 'change'}], | ||
612 | - destinationstation: [{required: true, message: '运单目的地必须输入', trigger: 'change'}], | ||
613 | - originstation: [{required: true, message: '运单起始站必须数据', trigger: 'change'}], | 662 | + weight: [{required: true, trigger: 'change', validator: validatorNums}], |
663 | + piece: [{required: true, trigger: 'change', validator: validatorNums}], | ||
664 | + destinationstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], | ||
665 | + originstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], | ||
614 | flightdate: [{required: true, message: '航班日期必须输入', trigger: 'change'}], | 666 | flightdate: [{required: true, message: '航班日期必须输入', trigger: 'change'}], |
615 | carrier: [{required: true, trigger: 'blur', validator: validatorAwbh}], | 667 | carrier: [{required: true, trigger: 'blur', validator: validatorAwbh}], |
616 | flightno: [{required: true, trigger: 'blur', validator: validatorAwbh}], | 668 | flightno: [{required: true, trigger: 'blur', validator: validatorAwbh}], |
617 | - pretime: [{required: true, trigger: 'blur', message: '预配时间不能为空'}], | 669 | + actime: [{required: true, trigger: 'blur', message: '预配时间不能为空'}], |
618 | customcode: [{required: true, message: '关区代码必须选择', trigger: 'change'}], | 670 | customcode: [{required: true, message: '关区代码必须选择', trigger: 'change'}], |
619 | awba: [{required: true, trigger: 'blur', validator: validatorAwb}], | 671 | awba: [{required: true, trigger: 'blur', validator: validatorAwb}], |
672 | + awbh: [{required: true, trigger: 'blur', validator: validatorAwbh}], | ||
620 | 'awbinfo.collected': [{required: true, message: '付款方式必选', trigger: 'change'}], | 673 | 'awbinfo.collected': [{required: true, message: '付款方式必选', trigger: 'change'}], |
621 | goodsname: [{required: true, trigger: 'change', validator: validAlphabetsSpanceKey}], | 674 | goodsname: [{required: true, trigger: 'change', validator: validAlphabetsSpanceKey}], |
622 | - ex5: [{required: true, message: '货物描述不能为空', trigger: 'change'}], | 675 | + ex5: [{required: true, message: '货物描述不能为空', trigger: 'blur'}], |
623 | 'awbinfo.sairportid': [{required: true, message: '起始航站不能为空', trigger: 'change'}], | 676 | 'awbinfo.sairportid': [{required: true, message: '起始航站不能为空', trigger: 'change'}], |
624 | 'awbinfo.shprname': [{required: true, message: '发货人不能为空', trigger: 'change'}], | 677 | 'awbinfo.shprname': [{required: true, message: '发货人不能为空', trigger: 'change'}], |
625 | 'awbinfo.shprtel': [{required: true, message: '发货电话不能为空', trigger: 'change'}], | 678 | 'awbinfo.shprtel': [{required: true, message: '发货电话不能为空', trigger: 'change'}], |
@@ -629,6 +682,8 @@ | @@ -629,6 +682,8 @@ | ||
629 | 'awbinfo.cnsntel': [{required: true, message: '收货电话不能为空', trigger: 'change'}], | 682 | 'awbinfo.cnsntel': [{required: true, message: '收货电话不能为空', trigger: 'change'}], |
630 | 'awbinfo.cnsnaddress': [{required: true, message: '收获地址不能为空', trigger: 'change'}], | 683 | 'awbinfo.cnsnaddress': [{required: true, message: '收获地址不能为空', trigger: 'change'}], |
631 | 'awbinfo.cnscountyr': [{required: true, message: '国家代码不能为空', trigger: 'change'}], | 684 | 'awbinfo.cnscountyr': [{required: true, message: '国家代码不能为空', trigger: 'change'}], |
685 | + 'awbinfo.weight': [{required: true, trigger: 'change', validator: validatorNums}], | ||
686 | + 'awbinfo.pcs': [{required: true, trigger: 'change', validator: validatorNums}], | ||
632 | }, | 687 | }, |
633 | preModel: { | 688 | preModel: { |
634 | awba: undefined, | 689 | awba: undefined, |
@@ -651,6 +706,8 @@ | @@ -651,6 +706,8 @@ | ||
651 | awbinfo: { | 706 | awbinfo: { |
652 | pcs: undefined, | 707 | pcs: undefined, |
653 | weight: undefined, | 708 | weight: undefined, |
709 | + scityid: undefined, | ||
710 | + ecityid: undefined, | ||
654 | specopeid: undefined, | 711 | specopeid: undefined, |
655 | shprname: undefined, | 712 | shprname: undefined, |
656 | shprmobiletype: undefined, | 713 | shprmobiletype: undefined, |
@@ -709,6 +766,10 @@ | @@ -709,6 +766,10 @@ | ||
709 | this.getList() | 766 | this.getList() |
710 | } | 767 | } |
711 | this.getCountryList() | 768 | this.getCountryList() |
769 | + let username = JSON.parse(sessionStorage.getItem('user')).username | ||
770 | + if(username === 'admin'){ | ||
771 | + this.isAdmin = true | ||
772 | + } | ||
712 | }, | 773 | }, |
713 | computed: { | 774 | computed: { |
714 | awba: { | 775 | awba: { |
@@ -768,7 +829,7 @@ | @@ -768,7 +829,7 @@ | ||
768 | return this.preModel.goodsname | 829 | return this.preModel.goodsname |
769 | }, | 830 | }, |
770 | set: function (val) { | 831 | set: function (val) { |
771 | - this.preModel.goodsname = val.toUpperCase().trim() | 832 | + this.preModel.goodsname = val.toUpperCase() |
772 | } | 833 | } |
773 | }, | 834 | }, |
774 | specopeid: { | 835 | specopeid: { |
@@ -784,7 +845,7 @@ | @@ -784,7 +845,7 @@ | ||
784 | return this.preModel.awbinfo.shprname | 845 | return this.preModel.awbinfo.shprname |
785 | }, | 846 | }, |
786 | set: function (val) { | 847 | set: function (val) { |
787 | - this.preModel.awbinfo.shprname = val.toUpperCase().trim() | 848 | + this.preModel.awbinfo.shprname = val.toUpperCase() |
788 | } | 849 | } |
789 | }, | 850 | }, |
790 | shpraddress: { | 851 | shpraddress: { |
@@ -792,7 +853,7 @@ | @@ -792,7 +853,7 @@ | ||
792 | return this.preModel.awbinfo.shpraddress | 853 | return this.preModel.awbinfo.shpraddress |
793 | }, | 854 | }, |
794 | set: function (val) { | 855 | set: function (val) { |
795 | - this.preModel.awbinfo.shpraddress = val.toUpperCase().trim() | 856 | + this.preModel.awbinfo.shpraddress = val.toUpperCase() |
796 | } | 857 | } |
797 | }, | 858 | }, |
798 | shprcountyr: { | 859 | shprcountyr: { |
@@ -808,7 +869,23 @@ | @@ -808,7 +869,23 @@ | ||
808 | return this.preModel.awbinfo.shpaeocode | 869 | return this.preModel.awbinfo.shpaeocode |
809 | }, | 870 | }, |
810 | set: function (val) { | 871 | set: function (val) { |
811 | - this.preModel.awbinfo.shpaeocode = val.toUpperCase().trim() | 872 | + this.preModel.awbinfo.shpaeocode = val.toUpperCase() |
873 | + } | ||
874 | + }, | ||
875 | + scityid: { | ||
876 | + get: function () { | ||
877 | + return this.preModel.awbinfo.scityid | ||
878 | + }, | ||
879 | + set: function (val) { | ||
880 | + this.preModel.awbinfo.scityid = val.toUpperCase().trim() | ||
881 | + } | ||
882 | + }, | ||
883 | + ecityid: { | ||
884 | + get: function () { | ||
885 | + return this.preModel.awbinfo.ecityid | ||
886 | + }, | ||
887 | + set: function (val) { | ||
888 | + this.preModel.awbinfo.ecityid = val.toUpperCase().trim() | ||
812 | } | 889 | } |
813 | }, | 890 | }, |
814 | cnsnname: { | 891 | cnsnname: { |
@@ -816,7 +893,7 @@ | @@ -816,7 +893,7 @@ | ||
816 | return this.preModel.awbinfo.cnsnname | 893 | return this.preModel.awbinfo.cnsnname |
817 | }, | 894 | }, |
818 | set: function (val) { | 895 | set: function (val) { |
819 | - this.preModel.awbinfo.cnsnname = val.toUpperCase().trim() | 896 | + this.preModel.awbinfo.cnsnname = val.toUpperCase() |
820 | } | 897 | } |
821 | }, | 898 | }, |
822 | cnsnaddress: { | 899 | cnsnaddress: { |
@@ -824,7 +901,7 @@ | @@ -824,7 +901,7 @@ | ||
824 | return this.preModel.awbinfo.cnsnaddress | 901 | return this.preModel.awbinfo.cnsnaddress |
825 | }, | 902 | }, |
826 | set: function (val) { | 903 | set: function (val) { |
827 | - this.preModel.awbinfo.cnsnaddress = val.toUpperCase().trim() | 904 | + this.preModel.awbinfo.cnsnaddress = val.toUpperCase() |
828 | } | 905 | } |
829 | }, | 906 | }, |
830 | cnscountyr: { | 907 | cnscountyr: { |
@@ -832,7 +909,7 @@ | @@ -832,7 +909,7 @@ | ||
832 | return this.preModel.awbinfo.cnscountyr | 909 | return this.preModel.awbinfo.cnscountyr |
833 | }, | 910 | }, |
834 | set: function (val) { | 911 | set: function (val) { |
835 | - this.preModel.awbinfo.cnscountyr = val.toUpperCase().trim() | 912 | + this.preModel.awbinfo.cnscountyr = val.toUpperCase() |
836 | } | 913 | } |
837 | }, | 914 | }, |
838 | cnsrctcname: { | 915 | cnsrctcname: { |
@@ -851,14 +928,6 @@ | @@ -851,14 +928,6 @@ | ||
851 | this.preModel.awbinfo.cnsaeocode = val.toUpperCase().trim() | 928 | this.preModel.awbinfo.cnsaeocode = val.toUpperCase().trim() |
852 | } | 929 | } |
853 | }, | 930 | }, |
854 | - sairportid: { | ||
855 | - get: function () { | ||
856 | - return this.preModel.awbinfo.sairportid | ||
857 | - }, | ||
858 | - set: function (val) { | ||
859 | - this.preModel.awbinfo.sairportid = val.toUpperCase().trim() | ||
860 | - } | ||
861 | - }, | ||
862 | by1: { | 931 | by1: { |
863 | get: function () { | 932 | get: function () { |
864 | return this.preModel.awbinfo.by1 | 933 | return this.preModel.awbinfo.by1 |
@@ -907,14 +976,6 @@ | @@ -907,14 +976,6 @@ | ||
907 | this.preModel.awbinfo.dest3 = val.toUpperCase().trim() | 976 | this.preModel.awbinfo.dest3 = val.toUpperCase().trim() |
908 | } | 977 | } |
909 | }, | 978 | }, |
910 | - eairportid: { | ||
911 | - get: function () { | ||
912 | - return this.preModel.awbinfo.eairportid | ||
913 | - }, | ||
914 | - set: function (val) { | ||
915 | - this.preModel.awbinfo.eairportid = val.toUpperCase().trim() | ||
916 | - } | ||
917 | - } | ||
918 | }, | 979 | }, |
919 | methods: { | 980 | methods: { |
920 | // >>>>>>>>>>>>>>>>获取list集合<<<<<<<<<<<<<<<<<< | 981 | // >>>>>>>>>>>>>>>>获取list集合<<<<<<<<<<<<<<<<<< |
@@ -970,6 +1031,8 @@ | @@ -970,6 +1031,8 @@ | ||
970 | pcs: undefined, | 1031 | pcs: undefined, |
971 | weight: undefined, | 1032 | weight: undefined, |
972 | specopeid: undefined, | 1033 | specopeid: undefined, |
1034 | + scityid: undefined, | ||
1035 | + ecityid: undefined, | ||
973 | shprname: undefined, | 1036 | shprname: undefined, |
974 | shprmobiletype: undefined, | 1037 | shprmobiletype: undefined, |
975 | shprtel: undefined, | 1038 | shprtel: undefined, |
@@ -1024,7 +1087,7 @@ | @@ -1024,7 +1087,7 @@ | ||
1024 | createData() { | 1087 | createData() { |
1025 | this.$refs.preFormData.validate(valid => { | 1088 | this.$refs.preFormData.validate(valid => { |
1026 | if (valid) { | 1089 | if (valid) { |
1027 | - updateMT2201(this.preModel).then(res => { | 1090 | + addMt2201(this.preModel).then(res => { |
1028 | if (res.data.count > 0) { | 1091 | if (res.data.count > 0) { |
1029 | Message.success("新增成功") | 1092 | Message.success("新增成功") |
1030 | this.dialogFormVisible = false | 1093 | this.dialogFormVisible = false |
@@ -1204,8 +1267,8 @@ | @@ -1204,8 +1267,8 @@ | ||
1204 | residuePiece += childrenList[i].piece | 1267 | residuePiece += childrenList[i].piece |
1205 | residueWeight += childrenList[i].weight | 1268 | residueWeight += childrenList[i].weight |
1206 | } | 1269 | } |
1207 | - this.awbPiece =res.data.dataList[0].piece- residuePiece | ||
1208 | - this.awbWeight = res.data.dataList[0].weight- residueWeight | 1270 | + this.awbPiece = res.data.dataList[0].piece - residuePiece |
1271 | + this.awbWeight = res.data.dataList[0].weight - residueWeight | ||
1209 | } | 1272 | } |
1210 | }) | 1273 | }) |
1211 | this.dialogStatus = 'addAwbh' | 1274 | this.dialogStatus = 'addAwbh' |
@@ -109,7 +109,7 @@ | @@ -109,7 +109,7 @@ | ||
109 | <el-button size="mini" type="primary" @click="handleAwbSend(scope.row)" | 109 | <el-button size="mini" type="primary" @click="handleAwbSend(scope.row)" |
110 | :disabled="scope.row.status !=='00'">发舱单报 | 110 | :disabled="scope.row.status !=='00'">发舱单报 |
111 | </el-button> | 111 | </el-button> |
112 | - <el-button size="mini" type="danger" @click="handleAwbDelete(scope.row)">发删除报</el-button> | 112 | + <el-button size="mini" type="danger" v-if="isAdmin" @click="handleAwbDelete(scope.row)">删除运单</el-button> |
113 | 113 | ||
114 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" | 114 | <el-button size="mini" type="warning" @click="handleAwbStatus(scope.row)" |
115 | :disabled="scope.row.status ==='00'">更改状态 | 115 | :disabled="scope.row.status ==='00'">更改状态 |
@@ -193,12 +193,12 @@ | @@ -193,12 +193,12 @@ | ||
193 | <el-row> | 193 | <el-row> |
194 | <el-col :span="7.5"> | 194 | <el-col :span="7.5"> |
195 | <el-form-item label="运单件数" prop="price"> | 195 | <el-form-item label="运单件数" prop="price"> |
196 | - <el-input v-model.number="tidyModel.awbprice"></el-input> | 196 | + <el-input v-model="tidyModel.awbprice"></el-input> |
197 | </el-form-item> | 197 | </el-form-item> |
198 | </el-col> | 198 | </el-col> |
199 | <el-col :span="7.5"> | 199 | <el-col :span="7.5"> |
200 | <el-form-item label="运单重量" prop="weight"> | 200 | <el-form-item label="运单重量" prop="weight"> |
201 | - <el-input v-model.number="tidyModel.awbweight"></el-input> | 201 | + <el-input v-model="tidyModel.awbweight"></el-input> |
202 | </el-form-item> | 202 | </el-form-item> |
203 | </el-col> | 203 | </el-col> |
204 | <el-col :span="7.5"> | 204 | <el-col :span="7.5"> |
@@ -214,12 +214,12 @@ | @@ -214,12 +214,12 @@ | ||
214 | <el-row> | 214 | <el-row> |
215 | <el-col :span="7.5"> | 215 | <el-col :span="7.5"> |
216 | <el-form-item label="装载件数" prop="piece"> | 216 | <el-form-item label="装载件数" prop="piece"> |
217 | - <el-input v-model.number="tidyModel.piece"></el-input> | 217 | + <el-input v-model="tidyModel.piece"></el-input> |
218 | </el-form-item> | 218 | </el-form-item> |
219 | </el-col> | 219 | </el-col> |
220 | <el-col :span="7.5"> | 220 | <el-col :span="7.5"> |
221 | <el-form-item label="装载重量" prop="weight"> | 221 | <el-form-item label="装载重量" prop="weight"> |
222 | - <el-input v-model.number="tidyModel.weight"></el-input> | 222 | + <el-input v-model="tidyModel.weight"></el-input> |
223 | </el-form-item> | 223 | </el-form-item> |
224 | </el-col> | 224 | </el-col> |
225 | <el-col :span="7.5"> | 225 | <el-col :span="7.5"> |
@@ -302,7 +302,7 @@ | @@ -302,7 +302,7 @@ | ||
302 | import {getMt520XListForParam, deleteByIsDelete, updateStatus, updateMt520X, addMt520X} from '@/api/exitTidy' | 302 | import {getMt520XListForParam, deleteByIsDelete, updateStatus, updateMt520X, addMt520X} from '@/api/exitTidy' |
303 | import {Message} from "element-ui"; | 303 | import {Message} from "element-ui"; |
304 | import {getResponseForParam} from '@/api/responseDetail' | 304 | import {getResponseForParam} from '@/api/responseDetail' |
305 | - import {validAwb, validAlphabets, validAlphabetsAndNum, validAlphabetsAndSpanceKey} from "@/utils/validate" | 305 | + import {validAwb, validAlphabets, validAlphabetsAndNum, validAlphabetsAndSpanceKey,validatorNum} from "@/utils/validate" |
306 | 306 | ||
307 | export default { | 307 | export default { |
308 | name: "ExitTidy", | 308 | name: "ExitTidy", |
@@ -333,9 +333,16 @@ | @@ -333,9 +333,16 @@ | ||
333 | } | 333 | } |
334 | callback() | 334 | callback() |
335 | } | 335 | } |
336 | + const validatorNums = (rule, value, callback) => { | ||
337 | + if (!validatorNum(value)) { | ||
338 | + callback("只能输入数字,并且小数位最多两位") | ||
339 | + } | ||
340 | + callback() | ||
341 | + } | ||
336 | return { | 342 | return { |
337 | func: treeToArray, | 343 | func: treeToArray, |
338 | total: 1, | 344 | total: 1, |
345 | + isAdmin:false, | ||
339 | dialogMap: { | 346 | dialogMap: { |
340 | update: '编辑出港理货', | 347 | update: '编辑出港理货', |
341 | create: '添加出港理货', | 348 | create: '添加出港理货', |
@@ -361,8 +368,8 @@ | @@ -361,8 +368,8 @@ | ||
361 | flightno: [{required: true, trigger: 'blur', validator: validatorAwbh}], | 368 | flightno: [{required: true, trigger: 'blur', validator: validatorAwbh}], |
362 | originstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], | 369 | originstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], |
363 | destinationstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], | 370 | destinationstation: [{required: true, trigger: 'blur', validator: validatorAlphabets}], |
364 | - piece: [{type: 'number', required: true, trigger: 'change', message: '只能输入数字'}], | ||
365 | - weight: [{type: 'number', required: true, trigger: 'change', message: '只能输入数字'}], | 371 | + weight: [{required: true, trigger: 'change', validator: validatorNums}], |
372 | + piece: [{required: true, trigger: 'change', validator: validatorNums}], | ||
366 | }, | 373 | }, |
367 | tidyData: [], | 374 | tidyData: [], |
368 | detailData: [], | 375 | detailData: [], |
@@ -404,6 +411,10 @@ | @@ -404,6 +411,10 @@ | ||
404 | } | 411 | } |
405 | this.getList() | 412 | this.getList() |
406 | } | 413 | } |
414 | + let username = JSON.parse(sessionStorage.getItem('user')).username | ||
415 | + if(username === 'admin'){ | ||
416 | + this.isAdmin = true | ||
417 | + } | ||
407 | }, | 418 | }, |
408 | watch: { | 419 | watch: { |
409 | 'tidyModel.endtime': function (newValue, oldValue) { | 420 | 'tidyModel.endtime': function (newValue, oldValue) { |
@@ -648,6 +648,7 @@ | @@ -648,6 +648,7 @@ | ||
648 | 'awbinfo.cnscountyr': [{required: true, message: '国家代码不能为空', trigger: 'change'}], | 648 | 'awbinfo.cnscountyr': [{required: true, message: '国家代码不能为空', trigger: 'change'}], |
649 | 'awbinfo.cnscomidpre': [{required: true, message: '企业代码类型不能为空', trigger: 'change'}], | 649 | 'awbinfo.cnscomidpre': [{required: true, message: '企业代码类型不能为空', trigger: 'change'}], |
650 | 'awbinfo.cnscomidno': [{required: true, message: '企业代码不能为空', trigger: 'change'}], | 650 | 'awbinfo.cnscomidno': [{required: true, message: '企业代码不能为空', trigger: 'change'}], |
651 | + | ||
651 | } | 652 | } |
652 | } | 653 | } |
653 | }, | 654 | }, |
-
请 注册 或 登录 后发表评论