jinhui.wang

version:0.5.7,bug修复,页面缓存,大小写转换,件数重量精确

...@@ -26,6 +26,14 @@ export function findFltById(data) { ...@@ -26,6 +26,14 @@ export function findFltById(data) {
26 26
27 }) 27 })
28 } 28 }
29 +//删除航班
30 +export function delFlight(data) {
31 + return request({
32 + url: '/FlightPreserveController/delFlight/'+ data,
33 + method: 'post'
34 +
35 + })
36 +}
29 //新增修改 37 //新增修改
30 export function saveOrUpdate(data) { 38 export function saveOrUpdate(data) {
31 return request({ 39 return request({
......
...@@ -15,13 +15,18 @@ ...@@ -15,13 +15,18 @@
15 :lazy="lazy" 15 :lazy="lazy"
16 :downShiftKey="shiftKey" 16 :downShiftKey="shiftKey"
17 :limitStart="limitStart" 17 :limitStart="limitStart"
18 + :row-key="rowKey"
19 + :default-expand-all="defaultExpandAll"
20 + :tree-props="{ children: 'children', hasChildren: 'hasChildren' }"
18 v-loading="loading" 21 v-loading="loading"
22 + @sort-change="sortChange"
19 @select="tableSelect" 23 @select="tableSelect"
20 @select-all="tableSelectAll" 24 @select-all="tableSelectAll"
21 @select-change="SelectChange" 25 @select-change="SelectChange"
22 > 26 >
23 <el-table-column 27 <el-table-column
24 - v-for="(item, index) in newHeader" 28 + v-for="(item, index) in headerData"
29 + :column-key="item.value"
25 :type="item.type" 30 :type="item.type"
26 :prop="item.value" 31 :prop="item.value"
27 :label="item.name" 32 :label="item.name"
...@@ -32,12 +37,13 @@ ...@@ -32,12 +37,13 @@
32 :sortable="item.sorTable" 37 :sortable="item.sorTable"
33 :formatter="formatter" 38 :formatter="formatter"
34 header-align="center" 39 header-align="center"
40 + :sort-orders="['descending', 'ascending', null]"
35 :slotHeader="slotHeader" 41 :slotHeader="slotHeader"
36 :key="index" 42 :key="index"
37 > 43 >
38 - <template v-if="item.slot" slot-scope=""> 44 + <!-- <template v-if="item.slot" slot-scope="">
39 <Item :dom="item.slot" @change="itemChange"></Item> 45 <Item :dom="item.slot" @change="itemChange"></Item>
40 - </template> 46 + </template> -->
41 </el-table-column> 47 </el-table-column>
42 <slot></slot> 48 <slot></slot>
43 </el-table> 49 </el-table>
...@@ -64,8 +70,8 @@ ...@@ -64,8 +70,8 @@
64 <script> 70 <script>
65 // import infoTable from "./info.vue"; 71 // import infoTable from "./info.vue";
66 import Item from "./item.vue"; 72 import Item from "./item.vue";
67 -import dictLabels from "../../assets/languages/dictLabels.js" 73 +import dictLabels from "../../assets/languages/dictLabels.js";
68 -import { scrollTo } from '@/utils/scroll-to' 74 +import { scrollTo } from "@/utils/scroll-to";
69 export default { 75 export default {
70 name: "Table", 76 name: "Table",
71 components: { 77 components: {
...@@ -136,9 +142,9 @@ export default { ...@@ -136,9 +142,9 @@ export default {
136 type: Boolean, 142 type: Boolean,
137 default: true, 143 default: true,
138 }, 144 },
139 - shiftKey:{ 145 + shiftKey: {
140 - type:Boolean, 146 + type: Boolean,
141 - default:false, 147 + default: false,
142 }, 148 },
143 page: { 149 page: {
144 type: Number, 150 type: Number,
...@@ -148,9 +154,9 @@ export default { ...@@ -148,9 +154,9 @@ export default {
148 type: Number, 154 type: Number,
149 default: 20, 155 default: 20,
150 }, 156 },
151 - limitStart:{ 157 + limitStart: {
152 - type:Number, 158 + type: Number,
153 - default:0, 159 + default: 0,
154 }, 160 },
155 paginationBackground: { 161 paginationBackground: {
156 type: Boolean, 162 type: Boolean,
...@@ -164,6 +170,14 @@ export default { ...@@ -164,6 +170,14 @@ export default {
164 type: Number, 170 type: Number,
165 default: 0, 171 default: 0,
166 }, 172 },
173 + rowKey: {
174 + type: String,
175 + default: "",
176 + },
177 + defaultExpandAll: {
178 + type: Boolean,
179 + default: false,
180 + },
167 }, 181 },
168 inheritAttrs: false, 182 inheritAttrs: false,
169 data() { 183 data() {
...@@ -171,7 +185,7 @@ export default { ...@@ -171,7 +185,7 @@ export default {
171 newHeader: [], 185 newHeader: [],
172 selectTable: [], 186 selectTable: [],
173 pageNum: 1, 187 pageNum: 1,
174 - start:-1, 188 + start: -1,
175 // { 189 // {
176 // type: "selection", 190 // type: "selection",
177 // name: "", 191 // name: "",
...@@ -187,20 +201,28 @@ export default { ...@@ -187,20 +201,28 @@ export default {
187 created() { 201 created() {
188 this.newHeader = this.headerData; 202 this.newHeader = this.headerData;
189 }, 203 },
190 - mounted() { 204 + mounted() {},
191 - },
192 methods: { 205 methods: {
193 nextClick() { 206 nextClick() {
194 - this.$emit('currentChange',{page:this.pageNum + 1,start:this.limitStart + this.limitSize}) 207 + this.$emit("currentChange", {
195 - scrollTo(0,800); 208 + page: this.pageNum + 1,
209 + start: this.limitStart + this.limitSize,
210 + });
211 + scrollTo(0, 800);
196 }, 212 },
197 prevClick() { 213 prevClick() {
198 - this.$emit('currentChange',{page:this.pageNum - 1,start:this.limitStart - this.limitSiz}) 214 + this.$emit("currentChange", {
199 - scrollTo(0,800); 215 + page: this.pageNum - 1,
216 + start: this.limitStart - this.limitSiz,
217 + });
218 + scrollTo(0, 800);
200 }, 219 },
201 currentChange(val) { 220 currentChange(val) {
202 - this.$emit('currentChange',{page:val,start: val*this.limitSize+1}); 221 + this.$emit("currentChange", {
203 - scrollTo(0,800); 222 + page: val,
223 + start: val * this.limitSize + 1,
224 + });
225 + scrollTo(0, 800);
204 }, 226 },
205 tableSelect(selection, row) { 227 tableSelect(selection, row) {
206 let end = row.index; 228 let end = row.index;
...@@ -208,20 +230,17 @@ export default { ...@@ -208,20 +230,17 @@ export default {
208 const sum = Math.abs(this.start - end); 230 const sum = Math.abs(this.start - end);
209 const min = Math.min(this.start, end); 231 const min = Math.min(this.start, end);
210 let i; 232 let i;
211 - if ( 233 + if (this.start === -1 && selection.includes(this.data[row.index])) {
212 - this.start === -1 &&
213 - selection.includes(this.data[row.index])
214 - ) {
215 for (i = 0; i < sum; i++) { 234 for (i = 0; i < sum; i++) {
216 this.$refs.tables.toggleRowSelection(this.data[i], true); 235 this.$refs.tables.toggleRowSelection(this.data[i], true);
217 this.selectTable.push(this.data[i]); 236 this.selectTable.push(this.data[i]);
218 } 237 }
219 } else if (selection.includes(this.data[row.index])) { 238 } else if (selection.includes(this.data[row.index])) {
220 - if(!selection.includes(this.data[this.start])){ 239 + if (!selection.includes(this.data[this.start])) {
221 this.$refs.tables.toggleRowSelection(this.data[this.start], true); 240 this.$refs.tables.toggleRowSelection(this.data[this.start], true);
222 this.selectTable.push(this.data[this.start]); 241 this.selectTable.push(this.data[this.start]);
223 } 242 }
224 - for (i = this.start+1; i <= this.start+sum; i++) { 243 + for (i = this.start + 1; i <= this.start + sum; i++) {
225 this.$refs.tables.toggleRowSelection(this.data[i], true); 244 this.$refs.tables.toggleRowSelection(this.data[i], true);
226 this.selectTable.push(this.data[i]); 245 this.selectTable.push(this.data[i]);
227 } 246 }
...@@ -244,7 +263,7 @@ export default { ...@@ -244,7 +263,7 @@ export default {
244 } 263 }
245 } 264 }
246 } 265 }
247 - selection = this.selectTable 266 + selection = this.selectTable;
248 this.$emit("tableSelect", { selection, row }); 267 this.$emit("tableSelect", { selection, row });
249 }, 268 },
250 tableSelectAll(selection) { 269 tableSelectAll(selection) {
...@@ -253,13 +272,13 @@ export default { ...@@ -253,13 +272,13 @@ export default {
253 SelectChange(selection) { 272 SelectChange(selection) {
254 this.$emit("SelectChange", selection); 273 this.$emit("SelectChange", selection);
255 }, 274 },
256 - clearTable(){ 275 + clearTable() {
257 - this.selectTable = [] 276 + this.selectTable = [];
258 - this.$refs.tables.clearSelection() 277 + this.$refs.tables.clearSelection();
259 - },
260 - itemChange(val) {
261 - console.log(val)
262 }, 278 },
279 + // itemChange(val) {
280 + // console.log(val);
281 + // },
263 // checkChange(val) { 282 // checkChange(val) {
264 // console.log(val); 283 // console.log(val);
265 // }, 284 // },
...@@ -269,10 +288,29 @@ export default { ...@@ -269,10 +288,29 @@ export default {
269 // bottom(val) { 288 // bottom(val) {
270 // console.log(val); 289 // console.log(val);
271 // }, 290 // },
291 + sortChange({ column, prop, order }) {
292 + this.$emit("sortChange",{prop:prop, order:order})
293 + },
294 + compare(propertyName, sort) {
295 + return function (obj1, obj2) {
296 + var value1 = obj1[propertyName];
297 + var value2 = obj2[propertyName];
298 + if (typeof value1 === "string" && typeof value2 === "string") {
299 + const res = value1.localeCompare(value2, "zh");
300 + return sort === "ascending" ? res : -res;
301 + } else {
302 + if (value1 <= value2) {
303 + return sort === "ascending" ? -1 : 1;
304 + } else if (value1 > value2) {
305 + return sort === "ascending" ? 1 : -1;
306 + }
307 + }
308 + };
309 + },
272 formatter(row, column, cellValue, index) { 310 formatter(row, column, cellValue, index) {
273 - if(dictLabels[column.property]){ 311 + if (dictLabels[column.property]) {
274 - if(dictLabels[column.property][cellValue]){ 312 + if (dictLabels[column.property][cellValue]) {
275 - return dictLabels[column.property][cellValue]; 313 + return dictLabels[column.property][cellValue];
276 } 314 }
277 } 315 }
278 return cellValue; 316 return cellValue;
......
...@@ -67,20 +67,6 @@ export const constantRoutes = [ ...@@ -67,20 +67,6 @@ export const constantRoutes = [
67 ] 67 ]
68 }, 68 },
69 { 69 {
70 - path: '/user',
71 - component: Layout,
72 - hidden: true,
73 - redirect: 'noredirect',
74 - children: [
75 - {
76 - path: 'profile',
77 - component: (resolve) => require(['@/views/systemConfig/userConfig/profile/index'], resolve),
78 - name: 'Profile',
79 - meta: { title: '个人中心', icon: 'user' }
80 - }
81 - ]
82 - },
83 - {
84 path: '/', 70 path: '/',
85 component: Layout, 71 component: Layout,
86 hidden: true, 72 hidden: true,
...@@ -89,13 +75,13 @@ export const constantRoutes = [ ...@@ -89,13 +75,13 @@ export const constantRoutes = [
89 { 75 {
90 path: '/flightAllocConfig/:handle/:id', 76 path: '/flightAllocConfig/:handle/:id',
91 component: (resolve) => require(['@/views/allocationConfig/flightAllocConfig/info'], resolve), 77 component: (resolve) => require(['@/views/allocationConfig/flightAllocConfig/info'], resolve),
92 - name: 'flightAllocConfigInfo', 78 + name: 'FlightAllocConfigInfo',
93 meta: { title: '航班配舱', icon: 'user', breadcrumb: true } 79 meta: { title: '航班配舱', icon: 'user', breadcrumb: true }
94 }, 80 },
95 { 81 {
96 path: '/flightAllocConfig/:handle', 82 path: '/flightAllocConfig/:handle',
97 component: (resolve) => require(['@/views/allocationConfig/flightAllocConfig/info'], resolve), 83 component: (resolve) => require(['@/views/allocationConfig/flightAllocConfig/info'], resolve),
98 - name: 'flightAllocConfigAdd', 84 + name: 'FlightAllocConfigInfo',
99 meta: { title: '添加航班配舱', icon: 'user', breadcrumb: false } 85 meta: { title: '添加航班配舱', icon: 'user', breadcrumb: false }
100 }, 86 },
101 ] 87 ]
......
...@@ -42,5 +42,5 @@ module.exports = { ...@@ -42,5 +42,5 @@ module.exports = {
42 /** 42 /**
43 * 版本号 43 * 版本号
44 */ 44 */
45 - version:'version:0.5.6' 45 + version:'version:0.5.7'
46 } 46 }
......
1 import axios from 'axios' 1 import axios from 'axios'
2 -import { Message,MessageBox } from 'element-ui' 2 +import { Message, MessageBox } from 'element-ui'
3 import store from '@/store' 3 import store from '@/store'
4 -import { getToken } from '@/utils/auth' 4 +import { getToken, setToken } from '@/utils/auth'
5 import errorCode from '@/utils/errorCode' 5 import errorCode from '@/utils/errorCode'
6 6
7 axios.defaults.headers['Content-Type'] = 'application/json;charset=utf-8' 7 axios.defaults.headers['Content-Type'] = 'application/json;charset=utf-8'
...@@ -9,9 +9,9 @@ axios.defaults.headers['Content-Type'] = 'application/json;charset=utf-8' ...@@ -9,9 +9,9 @@ axios.defaults.headers['Content-Type'] = 'application/json;charset=utf-8'
9 const service = axios.create({ 9 const service = axios.create({
10 // axios中请求配置有baseURL选项,表示请求URL公共部分 10 // axios中请求配置有baseURL选项,表示请求URL公共部分
11 //baseURL: process.env.VUE_APP_BASE_API, 11 //baseURL: process.env.VUE_APP_BASE_API,
12 - baseURL: `http://47.103.140.98:7001/IMAC2`, //阿里云服务器 12 + baseURL: `http://47.103.140.98:7001/iMAC`, //阿里云服务器
13 - // baseURL: 'https://imacuat.zmd.apac.fedex.com/IMAC2', //uat服务器 13 + // baseURL: 'https://imacuat.zmd.apac.fedex.com/iMAC', //uat服务器
14 - // baseURL: 'http://192.168.1.133:7001/IMAC2', //测试服务器 14 + // baseURL: 'http://192.168.1.133:7001/iMAC', //测试服务器
15 15
16 // 超时 16 // 超时
17 timeout: 30000 17 timeout: 30000
...@@ -53,6 +53,9 @@ service.interceptors.request.use(config => { ...@@ -53,6 +53,9 @@ service.interceptors.request.use(config => {
53 53
54 // 响应拦截器 54 // 响应拦截器
55 service.interceptors.response.use(res => { 55 service.interceptors.response.use(res => {
56 + if(res.headers['token']){
57 + setToken(decodeURI(res.headers['token']))
58 + }
56 // 未设置状态码则默认成功状态 59 // 未设置状态码则默认成功状态
57 const code = res.data.code || 200; 60 const code = res.data.code || 200;
58 // 获取错误信息 61 // 获取错误信息
......
...@@ -6,8 +6,8 @@ const mimeMap = { ...@@ -6,8 +6,8 @@ const mimeMap = {
6 zip: 'application/zip' 6 zip: 'application/zip'
7 } 7 }
8 // const baseUrl = 'https://imacuat.zmd.apac.fedex.com/iMAC' //uat服务器 8 // const baseUrl = 'https://imacuat.zmd.apac.fedex.com/iMAC' //uat服务器
9 -const baseUrl = 'http://47.103.140.98:7001/IMAC2' //阿里云服务器 9 +const baseUrl = 'http://47.103.140.98:7001/iMAC' //阿里云服务器
10 -// const baseUrl = 'http://192.168.1.133:7001/IMAC2' //测试服务器 10 +// const baseUrl = 'http://192.168.1.133:7001/iMAC' //测试服务器
11 11
12 export function downLoadZip(str, filename) { 12 export function downLoadZip(str, filename) {
13 var url = baseUrl + str 13 var url = baseUrl + str
......
...@@ -3,7 +3,6 @@ ...@@ -3,7 +3,6 @@
3 <el-form 3 <el-form
4 ref="form" 4 ref="form"
5 v-model="formData" 5 v-model="formData"
6 - v-show="formShow"
7 class="form-header" 6 class="form-header"
8 label-position="right" 7 label-position="right"
9 label-width="auto" 8 label-width="auto"
...@@ -35,6 +34,26 @@ ...@@ -35,6 +34,26 @@
35 </el-form-item> 34 </el-form-item>
36 </el-col> 35 </el-col>
37 <el-col :span="6"> 36 <el-col :span="6">
37 + <el-form-item label="海关回执状态">
38 + <el-select
39 + placeholder="不限"
40 + v-model="formData.customsReceiptStatusId"
41 + class="formItem"
42 + multiple
43 + clearable
44 + >
45 + <el-option
46 + v-for="item in selectData.findConditionData
47 + .cargoCustomsReturnStatus"
48 + :label="item.chineseName"
49 + :value="item.id"
50 + :key="item.id"
51 + >
52 + </el-option>
53 + </el-select>
54 + </el-form-item>
55 + </el-col>
56 + <el-col :span="6">
38 <el-form-item label="货物状态"> 57 <el-form-item label="货物状态">
39 <el-select 58 <el-select
40 placeholder="不限" 59 placeholder="不限"
...@@ -58,7 +77,7 @@ ...@@ -58,7 +77,7 @@
58 class="formItem" 77 class="formItem"
59 type="textarea" 78 type="textarea"
60 placeholder="请输入运单号(回车分割)" 79 placeholder="请输入运单号(回车分割)"
61 - v-model="formData.waybillNo" 80 + v-model.trim="formData.waybillNo"
62 rows="1" 81 rows="1"
63 ></el-input> 82 ></el-input>
64 </el-form-item> 83 </el-form-item>
...@@ -208,26 +227,6 @@ ...@@ -208,26 +227,6 @@
208 ></el-input> 227 ></el-input>
209 </el-form-item> 228 </el-form-item>
210 </el-col> 229 </el-col>
211 - <el-col :span="6">
212 - <el-form-item label="海关回执状态">
213 - <el-select
214 - placeholder="不限"
215 - v-model="formData.customsReceiptStatusId"
216 - class="formItem"
217 - multiple
218 - clearable
219 - >
220 - <el-option
221 - v-for="item in selectData.findConditionData
222 - .cargoCustomsReturnStatus"
223 - :label="item.chineseName"
224 - :value="item.id"
225 - :key="item.id"
226 - >
227 - </el-option>
228 - </el-select>
229 - </el-form-item>
230 - </el-col>
231 <el-col :span="24"> 230 <el-col :span="24">
232 <el-form-item label="Handling Code"> 231 <el-form-item label="Handling Code">
233 <el-empty 232 <el-empty
...@@ -316,6 +315,7 @@ ...@@ -316,6 +315,7 @@
316 @tableSelect="tableSelect" 315 @tableSelect="tableSelect"
317 @tableSelectAll="tableSelectAll" 316 @tableSelectAll="tableSelectAll"
318 @currentChange="currentChange" 317 @currentChange="currentChange"
318 + @sortChange="sortChange"
319 ></Tables> 319 ></Tables>
320 <Dialog 320 <Dialog
321 :tableData="tableSelection" 321 :tableData="tableSelection"
...@@ -334,6 +334,7 @@ import { downLoadXlsx } from "@/utils/zipdownload"; ...@@ -334,6 +334,7 @@ import { downLoadXlsx } from "@/utils/zipdownload";
334 import { upCase } from "@/utils/FedEx"; 334 import { upCase } from "@/utils/FedEx";
335 335
336 export default { 336 export default {
337 + name:"CargoAllocation",
337 components: { 338 components: {
338 Dialog, 339 Dialog,
339 }, 340 },
...@@ -815,7 +816,6 @@ export default { ...@@ -815,7 +816,6 @@ export default {
815 shiftKey: false, 816 shiftKey: false,
816 createDate: null, 817 createDate: null,
817 loading: false, 818 loading: false,
818 - formShow:true,
819 downLoadingTip: { 819 downLoadingTip: {
820 tip: "", 820 tip: "",
821 downloading: false, 821 downloading: false,
...@@ -868,11 +868,6 @@ export default { ...@@ -868,11 +868,6 @@ export default {
868 }); 868 });
869 }, 869 },
870 mounted() { 870 mounted() {
871 - // this.selectData.HandlingCode.forEach((item,index)=>{
872 - // if(item.id === 108093){
873 - // this.selectData.HandlingCode.unshift(this.HandlingCode.splice(index,1)[0])
874 - // }
875 - // })
876 window.addEventListener("keydown", (code) => { 871 window.addEventListener("keydown", (code) => {
877 if (code.keyCode === 16 && code.shiftKey) { 872 if (code.keyCode === 16 && code.shiftKey) {
878 this.shiftKey = true; 873 this.shiftKey = true;
...@@ -885,6 +880,7 @@ export default { ...@@ -885,6 +880,7 @@ export default {
885 }); 880 });
886 }, 881 },
887 methods: { 882 methods: {
883 + //查询
888 select() { 884 select() {
889 this.loading = true; 885 this.loading = true;
890 this.dataInfo(); 886 this.dataInfo();
...@@ -915,6 +911,7 @@ export default { ...@@ -915,6 +911,7 @@ export default {
915 this.loading = false; 911 this.loading = false;
916 }); 912 });
917 }, 913 },
914 + //总和
918 cargoTotal() { 915 cargoTotal() {
919 this.allWeight = 0; 916 this.allWeight = 0;
920 this.allQty = 0; 917 this.allQty = 0;
...@@ -923,10 +920,11 @@ export default { ...@@ -923,10 +920,11 @@ export default {
923 this.allWeight = this.allWeight + item.actualWeight; 920 this.allWeight = this.allWeight + item.actualWeight;
924 this.allQty = this.allQty + item.qty; 921 this.allQty = this.allQty + item.qty;
925 }); 922 });
926 - this.allWeight = this.allWeight.toFixed(); 923 + this.allWeight = this.allWeight.toFixed(2);
927 this.allQty = this.allQty.toFixed(); 924 this.allQty = this.allQty.toFixed();
928 } 925 }
929 }, 926 },
927 + //数据初始化
930 dataInfo() { 928 dataInfo() {
931 this.formData.ursaList = null; 929 this.formData.ursaList = null;
932 this.formData.siteNameList = null; 930 this.formData.siteNameList = null;
...@@ -972,6 +970,7 @@ export default { ...@@ -972,6 +970,7 @@ export default {
972 this.formData.page = this.page; 970 this.formData.page = this.page;
973 this.formData.size = this.size; 971 this.formData.size = this.size;
974 }, 972 },
973 + //导出表格
975 xlsx(val) { 974 xlsx(val) {
976 this.downLoadingTip.downloading = true; 975 this.downLoadingTip.downloading = true;
977 this.dataInfo(); 976 this.dataInfo();
...@@ -999,19 +998,27 @@ export default { ...@@ -999,19 +998,27 @@ export default {
999 }); 998 });
1000 } 999 }
1001 }, 1000 },
1001 + //表格选择
1002 tableSelect(val) { 1002 tableSelect(val) {
1003 this.tableSelection = val.selection; 1003 this.tableSelection = val.selection;
1004 this.cargoTotal(); 1004 this.cargoTotal();
1005 }, 1005 },
1006 + //表格全选
1006 tableSelectAll(val) { 1007 tableSelectAll(val) {
1007 this.tableSelection = val; 1008 this.tableSelection = val;
1008 this.cargoTotal(); 1009 this.cargoTotal();
1009 }, 1010 },
1011 + //分页
1010 currentChange(val) { 1012 currentChange(val) {
1011 this.formData.limitStart = val.start; 1013 this.formData.limitStart = val.start;
1012 this.page = val.page; 1014 this.page = val.page;
1013 this.select(); 1015 this.select();
1014 }, 1016 },
1017 + //排序
1018 + sortChange(val){
1019 + this.tableData.sort(this.$refs.newTables.compare(val.prop,val.order));
1020 + },
1021 + //添加到航班
1015 addFit() { 1022 addFit() {
1016 let open = true; 1023 let open = true;
1017 this.tableSelection.forEach((item) => { 1024 this.tableSelection.forEach((item) => {
...@@ -1031,6 +1038,7 @@ export default { ...@@ -1031,6 +1038,7 @@ export default {
1031 this.$refs.newTables.clearTable(); 1038 this.$refs.newTables.clearTable();
1032 } 1039 }
1033 }, 1040 },
1041 + //关闭弹框
1034 dialogBeforeClose(val) { 1042 dialogBeforeClose(val) {
1035 this.dialogVisible = val.close; 1043 this.dialogVisible = val.close;
1036 if (val.reload) { 1044 if (val.reload) {
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
10 > 10 >
11 <el-form-item label="航班号"> 11 <el-form-item label="航班号">
12 <el-input 12 <el-input
13 - v-model.trim="queryParams.purposeOfFlightNo" 13 + v-model.trim="purposeOfFlightNo"
14 placeholder="航班号" 14 placeholder="航班号"
15 @keyup.enter.native="getList" 15 @keyup.enter.native="getList"
16 ></el-input> 16 ></el-input>
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
36 type="primary" 36 type="primary"
37 icon="el-icon-plus" 37 icon="el-icon-plus"
38 size="mini" 38 size="mini"
39 - @click="$router.push({ name: 'flightAllocConfigAdd', params: { handle: 'add' } })" 39 + @click="$router.push({ name: 'FlightAllocConfigInfo', params: { handle: 'add' } })"
40 >添加</el-button 40 >添加</el-button
41 > 41 >
42 </div> 42 </div>
...@@ -131,6 +131,7 @@ import { ...@@ -131,6 +131,7 @@ import {
131 import { parseTime } from "@/utils/FedEx"; 131 import { parseTime } from "@/utils/FedEx";
132 132
133 export default { 133 export default {
134 + name:"FlightAllocConfig",
134 data() { 135 data() {
135 return { 136 return {
136 queryParams: { 137 queryParams: {
...@@ -172,7 +173,7 @@ export default { ...@@ -172,7 +173,7 @@ export default {
172 //跳转到查看,修改页面 173 //跳转到查看,修改页面
173 handleClick(flightiId, handle) { 174 handleClick(flightiId, handle) {
174 this.$router.push({ 175 this.$router.push({
175 - name: "flightAllocConfigInfo", 176 + name: "FlightAllocConfigInfo",
176 params: { handle: handle, id: flightiId }, 177 params: { handle: handle, id: flightiId },
177 }); 178 });
178 }, 179 },
...@@ -225,6 +226,16 @@ export default { ...@@ -225,6 +226,16 @@ export default {
225 }, 226 },
226 created() { 227 created() {
227 this.getList(); 228 this.getList();
229 + },
230 + computed:{
231 + purposeOfFlightNo: {
232 + get: function () {
233 + return this.queryParams.purposeOfFlightNo;
234 + },
235 + set: function (val) {
236 + this.queryParams.purposeOfFlightNo = val.toUpperCase()
237 + },
238 + },
228 } 239 }
229 }; 240 };
230 </script> 241 </script>
......
...@@ -2,16 +2,31 @@ ...@@ -2,16 +2,31 @@
2 <div style="margin: 40px" v-loading="loading"> 2 <div style="margin: 40px" v-loading="loading">
3 <el-empty description="找不到这条数据!" v-if="isEmpty"></el-empty> 3 <el-empty description="找不到这条数据!" v-if="isEmpty"></el-empty>
4 <template v-else> 4 <template v-else>
5 - <el-form ref="form" :model="form" label-width="200px" size="small" :disabled="disable" :rules="rules"> 5 + <el-form
6 + ref="form"
7 + :model="form"
8 + label-width="200px"
9 + size="small"
10 + :disabled="disable"
11 + :rules="rules"
12 + >
6 <el-row :gutter="20"> 13 <el-row :gutter="20">
7 <el-col :span="12"> 14 <el-col :span="12">
8 <el-form-item label="航班号" prop="purposeOfFlightNo"> 15 <el-form-item label="航班号" prop="purposeOfFlightNo">
9 - <el-input v-model.trim="form.purposeOfFlightNo" style="width: 60%" :disabled="nameDisabled"></el-input> 16 + <el-input
17 + v-model.trim="form.purposeOfFlightNo"
18 + style="width: 60%"
19 + :disabled="nameDisabled"
20 + ></el-input>
10 </el-form-item> 21 </el-form-item>
11 </el-col> 22 </el-col>
12 <el-col :span="12"> 23 <el-col :span="12">
13 <el-form-item label="航班预审" prop="isNeedRequired"> 24 <el-form-item label="航班预审" prop="isNeedRequired">
14 - <el-switch v-model="isNeedRequired" :active-value="1" :inactive-value="0"> 25 + <el-switch
26 + v-model="isNeedRequired"
27 + :active-value="1"
28 + :inactive-value="0"
29 + >
15 </el-switch> 30 </el-switch>
16 </el-form-item> 31 </el-form-item>
17 </el-col> 32 </el-col>
...@@ -19,80 +34,140 @@ ...@@ -19,80 +34,140 @@
19 <el-form-item> 34 <el-form-item>
20 <el-row :gutter="20"> 35 <el-row :gutter="20">
21 <el-col :span="6"> 36 <el-col :span="6">
22 - <el-radio v-model="isLocation" label="1" size="mini">站点包含</el-radio> 37 + <el-radio v-model="isLocation" label="1" size="mini"
23 - <el-radio v-model="isLocation" label="2" size="mini">站点不包含</el-radio> 38 + >站点包含</el-radio
39 + >
40 + <el-radio v-model="isLocation" label="2" size="mini"
41 + >站点不包含</el-radio
42 + >
24 </el-col> 43 </el-col>
25 <el-col :span="6"> 44 <el-col :span="6">
26 - <el-alert title="提示:站点之间用回车符分隔" type="warning" show-icon size="mini" :closable="false" 45 + <el-alert
27 - style="height: 30px; width: fit-content"> 46 + title="提示:站点之间用回车符分隔"
47 + type="warning"
48 + show-icon
49 + size="mini"
50 + :closable="false"
51 + style="height: 30px; width: fit-content"
52 + >
28 </el-alert> 53 </el-alert>
29 </el-col> 54 </el-col>
30 </el-row> 55 </el-row>
31 </el-form-item> 56 </el-form-item>
32 57
33 <el-form-item label="站点包含" v-show="isLocation == 1"> 58 <el-form-item label="站点包含" v-show="isLocation == 1">
34 - <el-input type="textarea" v-model="form.location" :rows="6" resize="none" style="width: 600px"></el-input> 59 + <el-input
60 + type="textarea"
61 + v-model="form.location"
62 + :rows="6"
63 + resize="none"
64 + style="width: 600px"
65 + ></el-input>
35 </el-form-item> 66 </el-form-item>
36 <el-form-item label="站点不包含" v-show="isLocation == 2"> 67 <el-form-item label="站点不包含" v-show="isLocation == 2">
37 - <el-input type="textarea" v-model="form.notLocation" :rows="6" resize="none" style="width: 600px"></el-input> 68 + <el-input
69 + type="textarea"
70 + v-model="form.notLocation"
71 + :rows="6"
72 + resize="none"
73 + style="width: 600px"
74 + ></el-input>
38 </el-form-item> 75 </el-form-item>
39 76
40 <el-form-item> 77 <el-form-item>
41 - <el-alert title="提示:URSA之间用分号分隔,例:F2;F3;P_" type="warning" show-icon size="mini" :closable="false" 78 + <el-alert
42 - style="height: 30px; width: fit-content"> 79 + title="提示:URSA之间用分号分隔,例:F2;F3;P_"
80 + type="warning"
81 + show-icon
82 + size="mini"
83 + :closable="false"
84 + style="height: 30px; width: fit-content"
85 + >
43 </el-alert> 86 </el-alert>
44 </el-form-item> 87 </el-form-item>
45 <el-row :gutter="20"> 88 <el-row :gutter="20">
46 <el-col :span="10"> 89 <el-col :span="10">
47 <el-form-item label="URSA包含"> 90 <el-form-item label="URSA包含">
48 - <el-input type="textarea" v-model.trim="form.includeUrsa" :rows="6" resize="none"></el-input> 91 + <el-input
92 + type="textarea"
93 + v-model.trim="form.includeUrsa"
94 + :rows="6"
95 + resize="none"
96 + ></el-input>
49 </el-form-item> 97 </el-form-item>
50 </el-col> 98 </el-col>
51 <el-col :span="10"> 99 <el-col :span="10">
52 <el-form-item label="URSA不包含"> 100 <el-form-item label="URSA不包含">
53 - <el-input type="textarea" v-model.trim="form.notIncludeUrsa" :rows="6" resize="none"></el-input> 101 + <el-input
102 + type="textarea"
103 + v-model.trim="form.notIncludeUrsa"
104 + :rows="6"
105 + resize="none"
106 + ></el-input>
54 </el-form-item> 107 </el-form-item>
55 </el-col> 108 </el-col>
56 </el-row> 109 </el-row>
57 110
58 <el-form-item label="件数"> 111 <el-form-item label="件数">
59 <el-col :span="3"> 112 <el-col :span="3">
60 - <!-- <el-input v-model="form.minNumOfPieces"></el-input> --> 113 + <el-input
61 - <el-input-number v-model=" 114 + class="numberInput"
62 - form.minNumOfPieces == 0 115 + v-model.trim="minNumOfPieces"
63 - ? (form.minNumOfPieces = undefined) 116 + ></el-input>
64 - : form.minNumOfPieces 117 + <!-- <el-input-number
65 - " :precision="0" :controls="false" style="width: 100%" :min="1"></el-input-number> 118 + v-model="minNumOfPieces"
119 + :precision="0"
120 + :controls="false"
121 + style="width: 100%"
122 + ></el-input-number> -->
66 </el-col> 123 </el-col>
67 <el-col style="text-align: center" :span="1">-</el-col> 124 <el-col style="text-align: center" :span="1">-</el-col>
68 <el-col :span="3"> 125 <el-col :span="3">
69 - <!-- <el-input v-model="form.maxNumOfPieces"></el-input> --> 126 + <el-input
70 - <el-input-number v-model=" 127 + class="numberInput"
128 + v-model.trim="maxNumOfPieces"
129 + ></el-input>
130 + <!-- <el-input-number
131 + v-model="
71 form.maxNumOfPieces == 0 132 form.maxNumOfPieces == 0
72 - ? form.maxNumOfPieces=undefined 133 + ? (form.maxNumOfPieces = undefined)
73 : form.maxNumOfPieces 134 : form.maxNumOfPieces
74 - " :precision="0" :controls="false" style="width: 100%" :min="form.minNumOfPieces"></el-input-number> 135 + "
136 + :precision="0"
137 + :controls="false"
138 + style="width: 100%"
139 + ></el-input-number> -->
75 </el-col> 140 </el-col>
76 </el-form-item> 141 </el-form-item>
77 142
78 <el-form-item label="重量"> 143 <el-form-item label="重量">
79 <el-col :span="3"> 144 <el-col :span="3">
80 - <!-- <el-input v-model="form.minWeight"></el-input> --> 145 + <el-input class="numberInput" v-model.trim="minWeight"></el-input>
81 - <el-input-number v-model=" 146 + <!-- <el-input-number
147 + v-model="
82 form.minWeight == 0 148 form.minWeight == 0
83 ? (form.minWeight = undefined) 149 ? (form.minWeight = undefined)
84 : form.minWeight 150 : form.minWeight
85 - " :precision="2" :controls="false" style="width: 100%" :min="0.01"></el-input-number> 151 + "
152 + :precision="2"
153 + :controls="false"
154 + style="width: 100%"
155 + ></el-input-number> -->
86 </el-col> 156 </el-col>
87 <el-col :span="1" style="text-align: center"><span>Kg</span></el-col> 157 <el-col :span="1" style="text-align: center"><span>Kg</span></el-col>
88 <el-col style="text-align: center" :span="1">-</el-col> 158 <el-col style="text-align: center" :span="1">-</el-col>
89 <el-col :span="3"> 159 <el-col :span="3">
90 - <!-- <el-input v-model="form.maxWeight"></el-input> --> 160 + <el-input class="numberInput" v-model.trim="maxWeight"></el-input>
91 - <el-input-number v-model=" 161 + <!-- <el-input-number
162 + v-model="
92 form.maxWeight == 0 163 form.maxWeight == 0
93 ? (form.maxWeight = undefined) 164 ? (form.maxWeight = undefined)
94 : form.maxWeight 165 : form.maxWeight
95 - " :precision="2" :controls="false" style="width: 100%" :min="form.minWeight"></el-input-number> 166 + "
167 + :precision="2"
168 + :controls="false"
169 + style="width: 100%"
170 + ></el-input-number> -->
96 </el-col> 171 </el-col>
97 <el-col :span="1" style="text-align: center"><span>Kg</span></el-col> 172 <el-col :span="1" style="text-align: center"><span>Kg</span></el-col>
98 </el-form-item> 173 </el-form-item>
...@@ -102,7 +177,10 @@ ...@@ -102,7 +177,10 @@
102 <el-checkbox-group v-model="form.typeOfGoods"> 177 <el-checkbox-group v-model="form.typeOfGoods">
103 <el-row> 178 <el-row>
104 <el-col :span="2" v-for="item in cargoType" :key="item.id"> 179 <el-col :span="2" v-for="item in cargoType" :key="item.id">
105 - <el-checkbox :label="item.chineseName" :name="item.chineseName"> 180 + <el-checkbox
181 + :label="item.chineseName"
182 + :name="item.chineseName"
183 + >
106 </el-checkbox> 184 </el-checkbox>
107 </el-col> 185 </el-col>
108 </el-row> 186 </el-row>
...@@ -115,7 +193,11 @@ ...@@ -115,7 +193,11 @@
115 <el-checkbox-group v-model="form.declarationCategory"> 193 <el-checkbox-group v-model="form.declarationCategory">
116 <el-row> 194 <el-row>
117 <el-col :span="3" v-for="item in cargoStatus" :key="item.id"> 195 <el-col :span="3" v-for="item in cargoStatus" :key="item.id">
118 - <el-checkbox :label="item.chineseName" :name="item.chineseName" disabled></el-checkbox> 196 + <el-checkbox
197 + :label="item.chineseName"
198 + :name="item.chineseName"
199 + disabled
200 + ></el-checkbox>
119 </el-col> 201 </el-col>
120 </el-row> 202 </el-row>
121 </el-checkbox-group> 203 </el-checkbox-group>
...@@ -127,7 +209,10 @@ ...@@ -127,7 +209,10 @@
127 <el-checkbox-group v-model="form.serviceCode"> 209 <el-checkbox-group v-model="form.serviceCode">
128 <el-row> 210 <el-row>
129 <el-col :span="2" v-for="item in serviceCode" :key="item.id"> 211 <el-col :span="2" v-for="item in serviceCode" :key="item.id">
130 - <el-checkbox :label="item.englishName" :name="item.englishName"></el-checkbox> 212 + <el-checkbox
213 + :label="item.englishName"
214 + :name="item.englishName"
215 + ></el-checkbox>
131 </el-col> 216 </el-col>
132 </el-row> 217 </el-row>
133 </el-checkbox-group> 218 </el-checkbox-group>
...@@ -139,7 +224,10 @@ ...@@ -139,7 +224,10 @@
139 <el-checkbox-group v-model="form.handlingCode"> 224 <el-checkbox-group v-model="form.handlingCode">
140 <el-row> 225 <el-row>
141 <el-col :span="3" v-for="item in handlingCode" :key="item.id"> 226 <el-col :span="3" v-for="item in handlingCode" :key="item.id">
142 - <el-checkbox :label="item.englishName" :name="item.englishName"></el-checkbox> 227 + <el-checkbox
228 + :label="item.englishName"
229 + :name="item.englishName"
230 + ></el-checkbox>
143 </el-col> 231 </el-col>
144 </el-row> 232 </el-row>
145 </el-checkbox-group> 233 </el-checkbox-group>
...@@ -151,332 +239,402 @@ ...@@ -151,332 +239,402 @@
151 <el-checkbox-group v-model="form.subCategory"> 239 <el-checkbox-group v-model="form.subCategory">
152 <el-row> 240 <el-row>
153 <el-col :span="3" v-for="item in subCategory" :key="item.id"> 241 <el-col :span="3" v-for="item in subCategory" :key="item.id">
154 - <el-checkbox :label="item.englishName" :name="item.englishName"></el-checkbox> 242 + <el-checkbox
243 + :label="item.englishName"
244 + :name="item.englishName"
245 + ></el-checkbox>
155 </el-col> 246 </el-col>
156 </el-row> 247 </el-row>
157 </el-checkbox-group> 248 </el-checkbox-group>
158 </el-card> 249 </el-card>
159 </el-form-item> 250 </el-form-item>
160 251
161 - <el-form-item> 252 + <el-form-item> </el-form-item>
162 -
163 - </el-form-item>
164 </el-form> 253 </el-form>
165 - <div style="marginLeft:200px"> 254 + <div style="marginleft: 200px">
166 - <el-button type="primary" size="small" v-if="$route.params.handle != 'detail'" @click="submit('form')" 255 + <el-button
167 - :loading="btnLoading"> 256 + type="primary"
168 - <span v-if="$route.params.handle === 'add'">添加</span> 257 + size="small"
169 - <span v-else>保存</span> 258 + v-if="$route.params.handle != 'detail'"
170 - </el-button> 259 + @click="submit('form')"
171 - <el-button size="small" @click="close">取消</el-button> 260 + :loading="btnLoading"
261 + >
262 + <span v-if="$route.params.handle === 'add'">添加</span>
263 + <span v-else>保存</span>
264 + </el-button>
265 + <el-button size="small" @click="close">取消</el-button>
172 </div> 266 </div>
173 </template> 267 </template>
174 </div> 268 </div>
175 </template> 269 </template>
176 270
177 <script> 271 <script>
178 - import { 272 +import {
179 - findByFlightId, 273 + findByFlightId,
180 - updateOrAddFlight, 274 + updateOrAddFlight,
181 - allDictData, 275 + allDictData,
182 - findDestinationFltRuleByActualFlight, 276 + findDestinationFltRuleByActualFlight,
183 - } from "@/api/destinationFlight"; 277 +} from "@/api/destinationFlight";
184 278
185 - export default { 279 +export default {
186 - data() { 280 + name:"",
187 - return { 281 + data() {
188 - form: { 282 + return {
189 - typeOfGoods: [], 283 + form: {
190 - declarationCategory: [], 284 + minNumOfPieces: undefined,
191 - serviceCode: [], 285 + maxNumOfPieces: undefined,
192 - subCategory: [], 286 + minWeight: undefined,
193 - handlingCode:[], 287 + maxWeight: undefined,
194 - },
195 - rules: {
196 - purposeOfFlightNo: [{
197 - required: true,
198 - message: "请输入航班号",
199 - trigger: "blur"
200 - }, ],
201 - },
202 typeOfGoods: [], 288 typeOfGoods: [],
203 declarationCategory: [], 289 declarationCategory: [],
204 - formServiceCode: [],
205 - formHandlingCode:[],
206 - formSubCategory: [],
207 - cargoType: [],
208 - cargoStatus: [],
209 serviceCode: [], 290 serviceCode: [],
210 - handlingCode:[],
211 subCategory: [], 291 subCategory: [],
212 - isLocation: "1", 292 + handlingCode: [],
213 - isNeedRequired: 0,
214 - disable: false,
215 - nameDisabled: false,
216 - btnLoading: false,
217 - loading: true,
218 - isEmpty: false,
219 - };
220 - },
221 - methods: {
222 - //排序
223 - sorttodo(arr, englishName){
224 - var index = 1, newArr = [], length = arr.length;
225 - for ( var i=0; i<length; i++){
226 - if ( arr[i].englishName === englishName ){
227 - newArr[0] = arr[i];
228 - }
229 - else{
230 - newArr[index++] = arr[i];
231 - }
232 - }
233 - return newArr;
234 }, 293 },
235 - 294 + rules: {
236 - submit(form) { 295 + purposeOfFlightNo: [
237 - this.$refs[form].validate((valid) => { 296 + {
238 - if (!valid) { 297 + required: true,
239 - return false; 298 + message: "请输入航班号",
240 - } 299 + trigger: "blur",
241 - }); 300 + },
242 - 301 + ],
243 - this.btnLoading = true; 302 + },
244 - let handle = this.$route.params.handle; 303 + typeOfGoods: [],
245 - if (handle === "update") { 304 + declarationCategory: [],
246 - //修改,获取id 305 + formServiceCode: [],
247 - this.form.id = this.$route.params.id; 306 + formHandlingCode: [],
307 + formSubCategory: [],
308 + cargoType: [],
309 + cargoStatus: [],
310 + serviceCode: [],
311 + handlingCode: [],
312 + subCategory: [],
313 + isLocation: "1",
314 + isNeedRequired: 0,
315 + disable: false,
316 + nameDisabled: false,
317 + btnLoading: false,
318 + loading: true,
319 + isEmpty: false,
320 + };
321 + },
322 + methods: {
323 + //排序
324 + sorttodo(arr, englishName) {
325 + var index = 1,
326 + newArr = [],
327 + length = arr.length;
328 + for (var i = 0; i < length; i++) {
329 + if (arr[i].englishName === englishName) {
330 + newArr[0] = arr[i];
331 + } else {
332 + newArr[index++] = arr[i];
248 } 333 }
334 + }
335 + return newArr;
336 + },
249 337
250 - //调用接口 338 + submit(form) {
251 - this.typeOfGoods = this.form.typeOfGoods; 339 + this.$refs[form].validate((valid) => {
252 - this.declarationCategory = this.form.declarationCategory; 340 + if (!valid) {
253 - this.formServiceCode = this.form.serviceCode; 341 + return false;
254 - this.formHandlingCode = this.form.handlingCode;
255 - this.formSubCategory = this.form.subCategory;
256 - this.form.isNeedRequired = this.isNeedRequired;
257 - if (this.isLocation == 1) {
258 - this.form.notLocation = "";
259 - } else {
260 - this.form.location = "";
261 } 342 }
262 - if ( 343 + });
263 - this.form.includeUrsa && 344 +
264 - this.form.includeUrsa.length != 0 && 345 + this.btnLoading = true;
265 - this.form.notIncludeUrsa && 346 + let handle = this.$route.params.handle;
266 - this.form.notIncludeUrsa.length != 0 347 + if (handle === "update") {
267 - ) { 348 + //修改,获取id
268 - let include = this.form.includeUrsa.split(";"); 349 + this.form.id = this.$route.params.id;
269 - let notInclude = this.form.notIncludeUrsa.split(";"); 350 + }
270 - let errorList = []; 351 +
271 - notInclude.forEach((element) => { 352 + //调用接口
272 - if (element.indexOf("_") > 0) { 353 + this.typeOfGoods = this.form.typeOfGoods;
273 - errorList.push(element); 354 + this.declarationCategory = this.form.declarationCategory;
274 - } else { 355 + this.formServiceCode = this.form.serviceCode;
275 - let flag = 0; 356 + this.formHandlingCode = this.form.handlingCode;
276 - for (let i = 0; i < include.length; i++) { 357 + this.formSubCategory = this.form.subCategory;
277 - if ( 358 + this.form.isNeedRequired = this.isNeedRequired;
278 - element == "" || 359 + this.form.purposeOfFlightNo = this.form.purposeOfFlightNo.toUpperCase();
279 - (include[i].indexOf("_") > 0 && 360 + if (this.isLocation == 1) {
280 - include[i].substring(0, 1) == element.substring(0, 1)) 361 + this.form.notLocation = "";
281 - ) { 362 + } else {
282 - flag = 1; 363 + this.form.location = "";
283 - break; 364 + }
284 - } 365 + if (
285 - } 366 + this.form.includeUrsa &&
286 - if (flag == 0) { 367 + this.form.includeUrsa.length != 0 &&
287 - errorList.push(element); 368 + this.form.notIncludeUrsa &&
369 + this.form.notIncludeUrsa.length != 0
370 + ) {
371 + let include = this.form.includeUrsa.split(";");
372 + let notInclude = this.form.notIncludeUrsa.split(";");
373 + let errorList = [];
374 + notInclude.forEach((element) => {
375 + if (element.indexOf("_") > 0) {
376 + errorList.push(element);
377 + } else {
378 + let flag = 0;
379 + for (let i = 0; i < include.length; i++) {
380 + if (
381 + element == "" ||
382 + (include[i].indexOf("_") > 0 &&
383 + include[i].substring(0, 1) == element.substring(0, 1))
384 + ) {
385 + flag = 1;
386 + break;
288 } 387 }
289 } 388 }
290 - }); 389 + if (flag == 0) {
291 - console.log(errorList); 390 + errorList.push(element);
292 - if (errorList.length != 0) { 391 + }
293 - this.$message({
294 - showClose: true,
295 - message: "URSA不包含中[" +
296 - errorList +
297 - "]错误,URSA不包含必须属于URSA包含中的类型",
298 - type: "error",
299 - });
300 - this.btnLoading = false;
301 - return;
302 } 392 }
393 + });
394 + console.log(errorList);
395 + if (errorList.length != 0) {
396 + this.$message({
397 + showClose: true,
398 + message:
399 + "URSA不包含中[" +
400 + errorList +
401 + "]错误,URSA不包含必须属于URSA包含中的类型",
402 + type: "error",
403 + });
404 + this.btnLoading = false;
405 + return;
303 } 406 }
304 - updateOrAddFlight(this.form).then((response) => { 407 + }
305 - if (response.code === 200) { 408 + updateOrAddFlight(this.form).then((response) => {
409 + if (response.code === 200) {
410 + this.$message({
411 + showClose: true,
412 + message: "成功",
413 + type: "success",
414 + });
415 + this.close();
416 + } else {
417 + this.$message({
418 + showClose: true,
419 + message: response.msg,
420 + type: "error",
421 + });
422 + this.btnLoading = false;
423 + }
424 + });
425 + this.form.typeOfGoods = this.typeOfGoods;
426 + this.form.declarationCategory = this.declarationCategory;
427 + this.form.serviceCode = this.formServiceCode;
428 + this.form.handlingCode = this.formHandlingCode;
429 + this.form.subCategory = this.formSubCategory;
430 + },
431 + close() {
432 + this.$store.state.tagsView.visitedViews.splice(
433 + this.$store.state.tagsView.visitedViews.findIndex(
434 + (item) => item.path === this.$route.path
435 + ),
436 + 1
437 + );
438 + this.$router.push(
439 + this.$store.state.tagsView.visitedViews[
440 + this.$store.state.tagsView.visitedViews.length - 1
441 + ].path
442 + );
443 + },
444 + },
445 + created() {
446 + let handle = this.$route.params.handle;
447 +
448 + allDictData().then((response) => {
449 + if (response.code != 200) {
450 + this.$message({
451 + showClose: true,
452 + message: response.msg,
453 + type: "error",
454 + });
455 + reuturn;
456 + }
457 + let dict = response.data;
458 + this.cargoType = dict.cargoType;
459 + this.cargoStatus = dict.cargoStatus;
460 + this.serviceCode = dict.serviceCode.sort((a, b) =>
461 + a.englishName.localeCompare(b.englishName)
462 + );
463 +
464 + this.handlingCode = this.sorttodo(dict.handlingCode, "BLANK");
465 + this.subCategory = dict.subCategory;
466 + });
467 + if (handle === "detail") {
468 + this.disable = true;
469 + }
470 +
471 + if (handle != "add") {
472 + this.nameDisabled = true;
473 + let id = this.$route.params.id;
474 +
475 + if (isNaN(Number(id))) {
476 + findDestinationFltRuleByActualFlight(id).then((response) => {
477 + if (response.code != 200) {
306 this.$message({ 478 this.$message({
307 showClose: true, 479 showClose: true,
308 - message: "成功", 480 + message: response.msg,
309 - type: "success", 481 + type: "error",
310 }); 482 });
311 - this.close(); 483 + this.isEmpty = true;
484 + } else if (response.data == null) {
485 + this.isEmpty = true;
312 } else { 486 } else {
487 + let info = response.data;
488 + info.typeOfGoods = info.typeOfGoods
489 + ? info.typeOfGoods.split(";")
490 + : [];
491 + info.declarationCategory = info.declarationCategory
492 + ? info.declarationCategory.split(";")
493 + : [];
494 + info.serviceCode = info.serviceCode
495 + ? info.serviceCode.split(";")
496 + : [];
497 + info.handlingCode = info.handlingCode
498 + ? info.handlingCode.split(";")
499 + : [];
500 + info.subCategory = info.subCategory
501 + ? info.subCategory.split(";")
502 + : [];
503 + this.form = info;
504 + if (info.notLocation != null || info.notLocation == "") {
505 + this.isLocation = "2";
506 + } else {
507 + this.isLocation = "1";
508 + }
509 + this.isNeedRequired = info.isNeedRequired;
510 + }
511 + this.loading = false;
512 + });
513 + } else {
514 + //货物信息
515 + findByFlightId(id).then((response) => {
516 + if (response.code != 200) {
313 this.$message({ 517 this.$message({
314 showClose: true, 518 showClose: true,
315 message: response.msg, 519 message: response.msg,
316 type: "error", 520 type: "error",
317 }); 521 });
318 - this.btnLoading = false; 522 + this.isEmpty = true;
523 + } else {
524 + let info = response.data.list;
525 + info.typeOfGoods = info.typeOfGoods
526 + ? info.typeOfGoods.split(";")
527 + : [];
528 + info.declarationCategory = info.declarationCategory
529 + ? info.declarationCategory.split(";")
530 + : [];
531 + info.serviceCode = info.serviceCode
532 + ? info.serviceCode.split(";")
533 + : [];
534 + info.handlingCode = info.handlingCode
535 + ? info.handlingCode.split(";")
536 + : [];
537 + info.subCategory = info.subCategory
538 + ? info.subCategory.split(";")
539 + : [];
540 + this.form = info;
541 + if (info.notLocation != null || info.notLocation == "") {
542 + this.isLocation = "2";
543 + } else {
544 + this.isLocation = "1";
545 + }
546 + let isNeedRequired = response.data.isNeedRequired;
547 + this.form.isNeedRequired = isNeedRequired;
548 + this.isNeedRequired = isNeedRequired;
319 } 549 }
550 + this.loading = false;
320 }); 551 });
321 - this.form.typeOfGoods = this.typeOfGoods; 552 + }
322 - this.form.declarationCategory = this.declarationCategory; 553 + } else {
323 - this.form.serviceCode = this.formServiceCode; 554 + this.loading = false;
324 - this.form.handlingCode = this.formHandlingCode; 555 + }
325 - this.form.subCategory = this.formSubCategory; 556 + },
557 + computed: {
558 + minNumOfPieces: {
559 + get: function () {
560 + return this.form.minNumOfPieces;
326 }, 561 },
327 - close() { 562 + set: function (val) {
328 - this.$store.state.tagsView.visitedViews.splice( 563 + if (val == 0 || val == null || val == "-") {
329 - this.$store.state.tagsView.visitedViews.findIndex( 564 + this.form.minNumOfPieces = undefined;
330 - (item) => item.path === this.$route.path 565 + } else if (!isNaN(val)) {
331 - ), 566 + this.form.minNumOfPieces = val;
332 - 1 567 + }
333 - );
334 - this.$router.push(
335 - this.$store.state.tagsView.visitedViews[
336 - this.$store.state.tagsView.visitedViews.length - 1
337 - ].path
338 - );
339 }, 568 },
340 }, 569 },
341 - created() { 570 + maxNumOfPieces: {
342 - let handle = this.$route.params.handle; 571 + get: function () {
343 - 572 + return this.form.maxNumOfPieces;
344 - allDictData().then((response) => { 573 + },
345 - if (response.code != 200) { 574 + set: function (val) {
346 - this.$message({ 575 + if (val == 0 || val == null || val == "-") {
347 - showClose: true, 576 + this.form.maxNumOfPieces = undefined;
348 - message: response.msg, 577 + } else if (!isNaN(val)) {
349 - type: "error", 578 + this.form.maxNumOfPieces = val;
350 - });
351 - reuturn;
352 } 579 }
353 - let dict = response.data; 580 + },
354 - this.cargoType = dict.cargoType; 581 + },
355 - this.cargoStatus = dict.cargoStatus; 582 + minWeight: {
356 - this.serviceCode = dict.serviceCode.sort((a, b) => 583 + get: function () {
357 - a.englishName.localeCompare(b.englishName) 584 + return this.form.minWeight;
358 - ); 585 + },
359 - 586 + set: function (val) {
360 - 587 + if (val == null || val == "-") {
361 - this.handlingCode =this.sorttodo(dict.handlingCode,"BLANK"); 588 + this.form.minWeight = undefined;
362 - this.subCategory = dict.subCategory; 589 + } else if (!isNaN(val)) {
363 - }); 590 + this.form.minWeight = val;
364 - if (handle === "detail") {
365 - this.disable = true;
366 - }
367 -
368 - if (handle != "add") {
369 - this.nameDisabled = true;
370 - let id = this.$route.params.id;
371 -
372 - if (isNaN(Number(id))) {
373 - findDestinationFltRuleByActualFlight(id).then((response) => {
374 - if (response.code != 200) {
375 - this.$message({
376 - showClose: true,
377 - message: response.msg,
378 - type: "error",
379 - });
380 - this.isEmpty = true;
381 - } else if (response.data == null) {
382 - this.isEmpty = true;
383 - } else {
384 - let info = response.data;
385 - info.typeOfGoods = info.typeOfGoods ?
386 - info.typeOfGoods.split(";") :
387 - [];
388 - info.declarationCategory = info.declarationCategory ?
389 - info.declarationCategory.split(";") :
390 - [];
391 - info.serviceCode = info.serviceCode ?
392 - info.serviceCode.split(";") :
393 - [];
394 - info.handlingCode = info.handlingCode ?
395 - info.handlingCode.split(";") :
396 - [];
397 - info.subCategory = info.subCategory ?
398 - info.subCategory.split(";") :
399 - [];
400 - this.form = info;
401 - if (info.notLocation != null || info.notLocation == "") {
402 - this.isLocation = "2";
403 - } else {
404 - this.isLocation = "1";
405 - }
406 - this.isNeedRequired = info.isNeedRequired;
407 - }
408 - this.loading = false;
409 - });
410 - } else {
411 - //货物信息
412 - findByFlightId(id).then((response) => {
413 - if (response.code != 200) {
414 - this.$message({
415 - showClose: true,
416 - message: response.msg,
417 - type: "error",
418 - });
419 - this.isEmpty = true;
420 - } else {
421 - let info = response.data.list;
422 - info.typeOfGoods = info.typeOfGoods ?
423 - info.typeOfGoods.split(";") :
424 - [];
425 - info.declarationCategory = info.declarationCategory ?
426 - info.declarationCategory.split(";") :
427 - [];
428 - info.serviceCode = info.serviceCode ?
429 - info.serviceCode.split(";") :
430 - [];
431 - info.handlingCode = info.handlingCode ?
432 - info.handlingCode.split(";") :
433 - [];
434 - info.subCategory = info.subCategory ?
435 - info.subCategory.split(";") :
436 - [];
437 - this.form = info;
438 - if (info.notLocation != null || info.notLocation == "") {
439 - this.isLocation = "2";
440 - } else {
441 - this.isLocation = "1";
442 - }
443 - let isNeedRequired = response.data.isNeedRequired;
444 - this.form.isNeedRequired = isNeedRequired;
445 - this.isNeedRequired = isNeedRequired;
446 - }
447 - this.loading = false;
448 - });
449 } 591 }
450 - } else { 592 + },
451 - this.loading = false;
452 - }
453 }, 593 },
454 - }; 594 + maxWeight: {
595 + get: function () {
596 + return this.form.maxWeight;
597 + },
598 + set: function (val) {
599 + if (val == null || val == "-") {
600 + this.form.maxWeight = undefined;
601 + } else if (!isNaN(val)) {
602 + this.form.maxWeight = val;
603 + }
604 + },
605 + },
606 + },
607 +};
455 </script> 608 </script>
456 <style rel="stylesheet/scss" lang="scss"> 609 <style rel="stylesheet/scss" lang="scss">
457 - .el-textarea.is-disabled .el-textarea__inner { 610 +.el-textarea.is-disabled .el-textarea__inner {
458 - background-color: rgba(255, 255, 255, 0.5); 611 + background-color: rgba(255, 255, 255, 0.5);
459 - color: #303133; 612 + color: #303133;
460 - } 613 +}
461 614
462 - .el-input.is-disabled .el-input__inner { 615 +.el-input.is-disabled .el-input__inner {
463 - background-color: rgba(255, 255, 255, 0.5); 616 + background-color: rgba(255, 255, 255, 0.5);
464 - color: #303133; 617 + color: #303133;
465 - } 618 +}
466 619
467 - .el-checkbox__input.is-disabled.is-checked .el-checkbox__inner { 620 +.el-checkbox__input.is-disabled.is-checked .el-checkbox__inner {
468 - background-color: rgba(255, 255, 255, 0.5); 621 + background-color: rgba(255, 255, 255, 0.5);
469 - } 622 +}
470 623
471 - .el-checkbox__input.is-disabled+span.el-checkbox__label { 624 +.el-checkbox__input.is-disabled + span.el-checkbox__label {
472 - color: #303133; 625 + color: #303133;
473 - } 626 +}
474 627
475 - .el-checkbox__input.is-disabled.is-checked .el-checkbox__inner::after { 628 +.el-checkbox__input.is-disabled.is-checked .el-checkbox__inner::after {
476 - border-color: #303133; 629 + border-color: #303133;
477 - } 630 +}
478 631
479 - .el-checkbox__input.is-disabled.is-checked .el-checkbox__inner { 632 +.el-checkbox__input.is-disabled.is-checked .el-checkbox__inner {
480 - border-color: #606266; 633 + border-color: #606266;
634 +}
635 +.numberInput {
636 + input {
637 + text-align: center;
481 } 638 }
639 +}
482 </style> 640 </style>
......
...@@ -148,7 +148,7 @@ ...@@ -148,7 +148,7 @@
148 findSourceFlightAndFlightDateApi 148 findSourceFlightAndFlightDateApi
149 } from "@/api/sourceFlightRules"; 149 } from "@/api/sourceFlightRules";
150 export default { 150 export default {
151 - name: "SourceFlightRules", 151 + name: "FlightRandConfig",
152 data() { 152 data() {
153 return { 153 return {
154 // data 中设定 154 // data 中设定
...@@ -234,8 +234,9 @@ ...@@ -234,8 +234,9 @@
234 methods: { 234 methods: {
235 //跳转到查看,修改页面 235 //跳转到查看,修改页面
236 handleClick(flightiId, handle) { 236 handleClick(flightiId, handle) {
237 + this.openFlightDate = false
237 this.$router.push({ 238 this.$router.push({
238 - name: "flightAllocConfigInfo", 239 + name: "FlightAllocConfigInfo",
239 params: { 240 params: {
240 handle: handle, 241 handle: handle,
241 id: flightiId 242 id: flightiId
......
...@@ -44,6 +44,7 @@ ...@@ -44,6 +44,7 @@
44 importcaPreReview, 44 importcaPreReview,
45 } from "@/api/caPreReviewImport"; 45 } from "@/api/caPreReviewImport";
46 export default { 46 export default {
47 + name:"CAPreReviewImport",
47 data() { 48 data() {
48 return { 49 return {
49 // 遮罩层 50 // 遮罩层
......
...@@ -73,6 +73,7 @@ import { ...@@ -73,6 +73,7 @@ import {
73 importFlight, 73 importFlight,
74 } from "@/api/flightInfoImport"; 74 } from "@/api/flightInfoImport";
75 export default { 75 export default {
76 + name:"FlightInformationImport",
76 data() { 77 data() {
77 return { 78 return {
78 flightType: [], 79 flightType: [],
......
...@@ -51,8 +51,11 @@ ...@@ -51,8 +51,11 @@
51 <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button> 51 <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
52 <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button> 52 <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
53 <el-button type="primary" icon="el-icon-plus" size="mini" @click="handleAdd">新增</el-button> 53 <el-button type="primary" icon="el-icon-plus" size="mini" @click="handleAdd">新增</el-button>
54 + <el-button type="danger" icon="el-icon-delete" size="mini" :disabled="multiple" @click="handleDelete">删除
55 + </el-button>
54 <el-button type="primary" icon="el-icon-circle-check" size="mini" @click="handleFlightStatus('flightStatus10')">自动配舱开启</el-button> 56 <el-button type="primary" icon="el-icon-circle-check" size="mini" @click="handleFlightStatus('flightStatus10')">自动配舱开启</el-button>
55 <el-button type="primary" icon="el-icon-circle-close" size="mini" @click="handleFlightStatus('flightStatus80')">自动配舱关闭</el-button> 57 <el-button type="primary" icon="el-icon-circle-close" size="mini" @click="handleFlightStatus('flightStatus80')">自动配舱关闭</el-button>
58 +
56 </el-form> 59 </el-form>
57 <!-- <el-row :gutter="10" class="mb8"> 60 <!-- <el-row :gutter="10" class="mb8">
58 <el-col :span="1.5"> 61 <el-col :span="1.5">
...@@ -112,7 +115,7 @@ ...@@ -112,7 +115,7 @@
112 class-name="small-padding fixed-width" width="130" fixed="right"> 115 class-name="small-padding fixed-width" width="130" fixed="right">
113 <template slot-scope="scope"> 116 <template slot-scope="scope">
114 <el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)">修改</el-button> 117 <el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)">修改</el-button>
115 - <!-- <el-button size="mini" type="text" icon="el-icon-delete" @click="handleDeleteorPlayorpause(scope.row,0,'删除')"> 118 + <!-- <el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row,'删除')">
116 删除</el-button> --> 119 删除</el-button> -->
117 </template> 120 </template>
118 </el-table-column> 121 </el-table-column>
...@@ -178,14 +181,14 @@ ...@@ -178,14 +181,14 @@
178 <el-col :span="12"> 181 <el-col :span="12">
179 <el-form-item label="原始重量(KG)" prop="originalWeight"> 182 <el-form-item label="原始重量(KG)" prop="originalWeight">
180 <el-input-number @change="LowHighAvailable" placeholder="请输入原始重量(KG)" style="width:93%" 183 <el-input-number @change="LowHighAvailable" placeholder="请输入原始重量(KG)" style="width:93%"
181 - v-model="form.originalWeight" :precision="2"></el-input-number> 184 + v-model="form.originalWeight"></el-input-number>
182 </el-form-item> 185 </el-form-item>
183 </el-col> 186 </el-col>
184 187
185 <el-col :span="12"> 188 <el-col :span="12">
186 <el-form-item label="额外增重百分比" prop="extraWeightPercent"> 189 <el-form-item label="额外增重百分比" prop="extraWeightPercent">
187 <el-input-number @change="LowHighAvailable" placeholder="请输入额外增重百分比" style="width:93%" 190 <el-input-number @change="LowHighAvailable" placeholder="请输入额外增重百分比" style="width:93%"
188 - v-model="form.extraWeightPercent" :precision="2"></el-input-number> 191 + v-model="form.extraWeightPercent"></el-input-number>
189 </el-form-item> 192 </el-form-item>
190 </el-col> 193 </el-col>
191 194
...@@ -207,14 +210,14 @@ ...@@ -207,14 +210,14 @@
207 <el-col :span="12"> 210 <el-col :span="12">
208 <el-form-item label="高价百分比" prop="highPriceWeightPercent"> 211 <el-form-item label="高价百分比" prop="highPriceWeightPercent">
209 <el-input-number :disabled="ishighPriceWeightPercent" @change="LowHighAvailable" placeholder="请输入高价百分比" style="width:93%" 212 <el-input-number :disabled="ishighPriceWeightPercent" @change="LowHighAvailable" placeholder="请输入高价百分比" style="width:93%"
210 - v-model="form.highPriceWeightPercent" :precision="2"></el-input-number> 213 + v-model="form.highPriceWeightPercent"></el-input-number>
211 </el-form-item> 214 </el-form-item>
212 </el-col> 215 </el-col>
213 216
214 <el-col :span="12"> 217 <el-col :span="12">
215 <el-form-item label="低价百分比" prop="lowPriceWeightPercent"> 218 <el-form-item label="低价百分比" prop="lowPriceWeightPercent">
216 <el-input-number :disabled="true" placeholder="请输入低价百分比" style="width:93%" 219 <el-input-number :disabled="true" placeholder="请输入低价百分比" style="width:93%"
217 - v-model="form.lowPriceWeightPercent" :precision="2"></el-input-number> 220 + v-model="form.lowPriceWeightPercent"></el-input-number>
218 </el-form-item> 221 </el-form-item>
219 </el-col> 222 </el-col>
220 223
...@@ -264,10 +267,19 @@ ...@@ -264,10 +267,19 @@
264 <el-button @click="cancel">取 消</el-button> 267 <el-button @click="cancel">取 消</el-button>
265 </div> 268 </div>
266 </el-dialog> 269 </el-dialog>
270 +
271 + <el-dialog title="未删除成功航班" width="40%" center :visible.sync="dialogTableVisible">
272 + <el-table :data="gridData">
273 + <el-table-column property="fltNo" label="航班号" width="150"></el-table-column>
274 + <el-table-column property="fltDate" label="航班日期" width="200"></el-table-column>
275 + <el-table-column property="alloctedWeight" label="已配重量" width="200"></el-table-column>
276 + </el-table>
277 + </el-dialog>
267 </div> 278 </div>
268 </template> 279 </template>
269 <script> 280 <script>
270 import { 281 import {
282 + delFlight,
271 findFltConditionDataApi, 283 findFltConditionDataApi,
272 findAllFltDataApi, 284 findAllFltDataApi,
273 findFltById, 285 findFltById,
...@@ -277,9 +289,11 @@ ...@@ -277,9 +289,11 @@
277 289
278 } from "@/api/findAllFltData"; 290 } from "@/api/findAllFltData";
279 export default { 291 export default {
280 - name: "findAllFltData", 292 + name: "FlightInformationMaintenance",
281 data() { 293 data() {
282 return { 294 return {
295 + gridData:[],
296 + dialogTableVisible: false,
283 //高价百分比是否打开 297 //高价百分比是否打开
284 ishighPriceWeightPercent:true, 298 ishighPriceWeightPercent:true,
285 //form属性禁用状态 299 //form属性禁用状态
...@@ -624,40 +638,34 @@ ...@@ -624,40 +638,34 @@
624 638
625 }); 639 });
626 }, 640 },
627 - /** 删除 启用 停用按钮操作 */ 641 + /** 删除按钮操作 */
628 - handleDeleteorPlayorpause(row, status, statusText) { 642 + handleDelete(row) {
629 - 643 + const fIds =this.ids;
630 - //删除前需要停用 644 + this.$confirm('是否确认删除所选数据?', "警告", {
631 - if (status === 0 && row.status != '3') { 645 + confirmButtonText: "确定",
632 - this.$message({ 646 + cancelButtonText: "取消",
633 - message: '请停用后删除', 647 + type: "warning"
634 - type: 'warning' 648 + }).then(function() {
635 - }); 649 + return delFlight(fIds);
636 - return; 650 + }).then(response => {
637 - } 651 + this.findAllFltData();
638 - 652 + if(response.data.length>0){
639 - this.$confirm('是否确认' + statusText + '此数据项?', "警告", { 653 + this.gridData=response.data;
640 - confirmButtonText: "确定", 654 + this.$confirm(response.msg, '提示', {
641 - cancelButtonText: "取消", 655 + confirmButtonText: '查看删除失败航班信息',
642 - type: "warning" 656 + cancelButtonText: '取消',
643 - }).then(function() { 657 + type: 'warning',
644 - 658 + center: true
645 - let disable = { 659 + }).then(() => {
646 - id: row.id, 660 + this.dialogTableVisible=true;
647 - status: status 661 + }).catch(function() { });
648 - };
649 662
650 - return delOrEnableORDisableApi(disable); 663 + }else{
651 - }).then(response => { 664 + this.msgSuccess(response.msg);
652 - if (response.code == 200) { 665 + }
653 - this.findAllFltData(); 666 + }).catch(function() {});
654 - this.msgSuccess(statusText + "成功"); 667 + },
655 - } else {
656 - this.msgError(response.msg);
657 - }
658 668
659 - }).catch(function() {});
660 - },
661 /** 提交按钮 */ 669 /** 提交按钮 */
662 submitForm: function() { 670 submitForm: function() {
663 this.$refs["form"].validate(valid => { 671 this.$refs["form"].validate(valid => {
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
3 <el-form 3 <el-form
4 ref="cargoForm" 4 ref="cargoForm"
5 class="form-header" 5 class="form-header"
6 - label-position="top" 6 + label-position="right"
7 label-width="auto" 7 label-width="auto"
8 size="small" 8 size="small"
9 :model="formData" 9 :model="formData"
...@@ -51,7 +51,7 @@ ...@@ -51,7 +51,7 @@
51 <el-form-item label="运单号"> 51 <el-form-item label="运单号">
52 <el-input 52 <el-input
53 type="textarea" 53 type="textarea"
54 - v-model="formData.waybillNo" 54 + v-model.trim="formData.waybillNo"
55 class="formItem" 55 class="formItem"
56 placeholder="请输入运单号(回车间隔)" 56 placeholder="请输入运单号(回车间隔)"
57 rows="1" 57 rows="1"
...@@ -117,113 +117,106 @@ ...@@ -117,113 +117,106 @@
117 ></el-input> 117 ></el-input>
118 </el-form-item> 118 </el-form-item>
119 </el-col> 119 </el-col>
120 - <el-col :span="24"> 120 + <el-col :span="24" v-show="formShow">
121 - <el-collapse> 121 + <el-row type="flex" style="flexWrap: wrap!important">
122 - <el-collapse-item> 122 + <el-col :span="6">
123 - <template slot="title"> 123 + <el-form-item label="ACCS原航班日期">
124 - <span style="fontWeight:900;color:#409EFF;fontSize:14px"><i class="el-icon-s-tools"></i>更多查询条件</span> 124 + <el-date-picker
125 - </template> 125 + class="formItem"
126 - <el-row type="flex" style="flexWrap: wrap!important"> 126 + v-model="flightTime"
127 - <el-col :span="6"> 127 + type="daterange"
128 - <el-form-item label="ACCS原航班日期"> 128 + range-separator="至"
129 - <el-date-picker 129 + start-placeholder="开始日期"
130 - class="formItem" 130 + end-placeholder="结束日期"
131 - v-model="flightTime" 131 + :value-format="valueFormat"
132 - type="daterange" 132 + >
133 - range-separator="至" 133 + </el-date-picker>
134 - start-placeholder="开始日期" 134 + </el-form-item>
135 - end-placeholder="结束日期" 135 + </el-col>
136 - :value-format="valueFormat" 136 + <el-col :span="6">
137 - > 137 + <el-form-item label="ACCS原航班号">
138 - </el-date-picker> 138 + <el-input type="text" v-model="fltNo" class="formItem" placeholder="请输入ACCS航班号"></el-input>
139 - </el-form-item> 139 + </el-form-item>
140 - </el-col> 140 + </el-col>
141 - <el-col :span="6"> 141 + <el-col :span="6">
142 - <el-form-item label="ACCS原航班号"> 142 + <el-form-item label="取件日期">
143 - <el-input type="text" v-model="fltNo" class="formItem" placeholder="请输入ACCS航班号"></el-input> 143 + <el-date-picker
144 - </el-form-item> 144 + class="formItem"
145 - </el-col> 145 + v-model="formData.pickUpDate"
146 - <el-col :span="6"> 146 + type="date"
147 - <el-form-item label="取件日期"> 147 + placeholder="选择日期"
148 - <el-date-picker 148 + :value-format="valueFormat"
149 - class="formItem" 149 + >
150 - v-model="formData.pickUpDate" 150 + </el-date-picker>
151 - type="date" 151 + </el-form-item>
152 - placeholder="选择日期" 152 + </el-col>
153 - :value-format="valueFormat" 153 + <el-col :span="6">
154 - > 154 + <el-form-item label="创建日期">
155 - </el-date-picker> 155 + <el-date-picker
156 - </el-form-item> 156 + class="formItem"
157 - </el-col> 157 + v-model="createDate"
158 - <el-col :span="6"> 158 + type="daterange"
159 - <el-form-item label="创建日期"> 159 + range-separator="至"
160 - <el-date-picker 160 + start-placeholder="开始日期"
161 - class="formItem" 161 + end-placeholder="结束日期"
162 - v-model="createDate" 162 + :value-format="valueFormat"
163 - type="daterange" 163 + >
164 - range-separator="至" 164 + </el-date-picker>
165 - start-placeholder="开始日期" 165 + </el-form-item>
166 - end-placeholder="结束日期" 166 + </el-col>
167 - :value-format="valueFormat" 167 + <el-col :span="6">
168 - > 168 + <el-form-item label="货物状态">
169 - </el-date-picker> 169 + <el-select
170 - </el-form-item> 170 + placeholder="不限"
171 - </el-col> 171 + v-model="formData.statusId"
172 - <el-col :span="6"> 172 + class="formItem"
173 - <el-form-item label="货物状态"> 173 + filterable
174 - <el-select 174 + clearable
175 - placeholder="不限" 175 + >
176 - v-model="formData.statusId" 176 + <el-option
177 - class="formItem" 177 + v-for="item in findConditionData.cargoStatus"
178 - filterable 178 + :label="item.chineseName"
179 - clearable 179 + :value="item.id"
180 - > 180 + :key="item.id"
181 - <el-option 181 + >
182 - v-for="item in findConditionData.cargoStatus" 182 + </el-option>
183 - :label="item.chineseName" 183 + </el-select>
184 - :value="item.id" 184 + </el-form-item>
185 - :key="item.id" 185 + </el-col>
186 - > 186 + <el-col :span="6">
187 - </el-option> 187 + <el-form-item label="是否自动">
188 - </el-select> 188 + <el-select
189 - </el-form-item> 189 + placeholder="不限"
190 - </el-col> 190 + v-model="formData.allocationTypeId"
191 - <el-col :span="6"> 191 + class="formItem"
192 - <el-form-item label="是否自动"> 192 + clearable
193 - <el-select 193 + >
194 - placeholder="不限" 194 + <el-option
195 - v-model="formData.allocationTypeId" 195 + label="手动"
196 - class="formItem" 196 + value="1"
197 - clearable 197 + >
198 - > 198 + </el-option>
199 - <el-option 199 + <el-option
200 - label="手动" 200 + label="自动"
201 - value="1" 201 + value="2"
202 - > 202 + >
203 - </el-option> 203 + </el-option>
204 - <el-option 204 + </el-select>
205 - label="自动" 205 + </el-form-item>
206 - value="2" 206 + </el-col>
207 - > 207 + <!-- <el-col :span="6">
208 - </el-option> 208 + <el-form-item label="口岸代码">
209 - </el-select> 209 + <el-select
210 - </el-form-item> 210 + placeholder="不限"
211 - </el-col> 211 + v-model="formData.portName"
212 - <!-- <el-col :span="6"> 212 + class="formItem"
213 - <el-form-item label="口岸代码"> 213 + clearable
214 - <el-select 214 + >
215 - placeholder="不限" 215 +
216 - v-model="formData.portName" 216 + </el-select>
217 - class="formItem" 217 + </el-form-item>
218 - clearable 218 + </el-col> -->
219 - > 219 + </el-row>
220 -
221 - </el-select>
222 - </el-form-item>
223 - </el-col> -->
224 - </el-row>
225 - </el-collapse-item>
226 - </el-collapse>
227 </el-col> 220 </el-col>
228 </el-row> 221 </el-row>
229 <div style="paddingLeft: 10px;marginTop:20px"> 222 <div style="paddingLeft: 10px;marginTop:20px">
...@@ -250,6 +243,8 @@ ...@@ -250,6 +243,8 @@
250 <span style="paddingRight: 50px">总重量:{{ allWeight }}</span> 243 <span style="paddingRight: 50px">总重量:{{ allWeight }}</span>
251 <span>总件数:{{ allQty }}</span> 244 <span>总件数:{{ allQty }}</span>
252 </div> 245 </div>
246 + <RightToolbar :showSearch.sync="formShow" size="small"></RightToolbar>
247 + <!-- <div style="formShow" @click="formShow = !formShow">{{formShow?'收起条件':'更多条件'}}</div> -->
253 </div> 248 </div>
254 </el-form> 249 </el-form>
255 <Tables 250 <Tables
...@@ -265,6 +260,7 @@ ...@@ -265,6 +260,7 @@
265 @tableSelect="tableSelect" 260 @tableSelect="tableSelect"
266 @tableSelectAll="tableSelectAll" 261 @tableSelectAll="tableSelectAll"
267 @currentChange="currentChange" 262 @currentChange="currentChange"
263 + @sortChange="sortChange"
268 ></Tables> 264 ></Tables>
269 </div> 265 </div>
270 </template> 266 </template>
...@@ -275,7 +271,7 @@ import { downLoadXlsx } from "@/utils/zipdownload"; ...@@ -275,7 +271,7 @@ import { downLoadXlsx } from "@/utils/zipdownload";
275 import { upCase } from "@/utils/FedEx" 271 import { upCase } from "@/utils/FedEx"
276 272
277 export default { 273 export default {
278 - name:"queryCargo", 274 + name:"QueryCargo",
279 data() { 275 data() {
280 return { 276 return {
281 formData: { 277 formData: {
...@@ -759,9 +755,12 @@ export default { ...@@ -759,9 +755,12 @@ export default {
759 limitSize: 100, //无限制-1 755 limitSize: 100, //无限制-1
760 page:1, 756 page:1,
761 progress:0, 757 progress:0,
758 + formShow:true,
762 }; 759 };
763 }, 760 },
764 - 761 + activated(){
762 + console.log("cargo")
763 + },
765 created() { 764 created() {
766 //查询条件 765 //查询条件
767 findConditionData().then((res) => { 766 findConditionData().then((res) => {
...@@ -885,6 +884,9 @@ export default { ...@@ -885,6 +884,9 @@ export default {
885 this.page = val.page; 884 this.page = val.page;
886 this.select() 885 this.select()
887 }, 886 },
887 + sortChange(val){
888 + this.tableData.sort();
889 + },
888 // 导出表格 890 // 导出表格
889 xlse(page) { 891 xlse(page) {
890 this.progress = 1; 892 this.progress = 1;
...@@ -906,7 +908,7 @@ export default { ...@@ -906,7 +908,7 @@ export default {
906 this.downLoadingTip.tip = ""; 908 this.downLoadingTip.tip = "";
907 }) 909 })
908 } else { 910 } else {
909 - if(this.totalCount < 80000){ 911 + if(this.totalCount < 100000){
910 this.downLoadingTip.tip = "正在导出全部结果集请耐心等待" 912 this.downLoadingTip.tip = "正在导出全部结果集请耐心等待"
911 cargoXlse.cargoConditionDto.limitStart = 0; 913 cargoXlse.cargoConditionDto.limitStart = 0;
912 cargoXlse.cargoConditionDto.limitSize = -1; 914 cargoXlse.cargoConditionDto.limitSize = -1;
...@@ -967,14 +969,23 @@ export default { ...@@ -967,14 +969,23 @@ export default {
967 969
968 <style scoped> 970 <style scoped>
969 .tips { 971 .tips {
970 - float: right; 972 + display: inline-block;
971 color: #606266; 973 color: #606266;
972 font-size: 14px; 974 font-size: 14px;
973 - margin-right: 40px; 975 + margin-top: 10px;
976 + margin-left: 50px;
974 } 977 }
975 .progress{ 978 .progress{
976 width:200px; 979 width:200px;
977 display: inline-block; 980 display: inline-block;
978 margin:0 0 0 20px; 981 margin:0 0 0 20px;
979 } 982 }
983 +.formShow{
984 + height:48px;
985 + line-height: 48px;
986 + font-weight: 900;
987 + color: rgb(64, 158, 255);
988 + font-size: 14px;
989 + float: right;
990 +}
980 </style> 991 </style>
...\ No newline at end of file ...\ No newline at end of file
......
...@@ -35,9 +35,9 @@ module.exports = { ...@@ -35,9 +35,9 @@ module.exports = {
35 proxy: { 35 proxy: {
36 // detail: https://cli.vuejs.org/config/#devserver-proxy 36 // detail: https://cli.vuejs.org/config/#devserver-proxy
37 [process.env.VUE_APP_BASE_API]: { 37 [process.env.VUE_APP_BASE_API]: {
38 - // target: `https://imacuat.zmd.apac.fedex.com/IMAC2`, //uat服务器 38 + // target: `https://imacuat.zmd.apac.fedex.com/iMAC`, //uat服务器
39 - target: `http://47.103.140.98:7001/IMAC2`, //阿里云服务器 39 + target: `http://47.103.140.98:7001/iMAC`, //阿里云服务器
40 - // target: `http://192.168.1.133:7001/IMAC2`, //测试服务器 40 + // target: `http://192.168.1.133:7001/iMAC`, //测试服务器
41 changeOrigin: true, 41 changeOrigin: true,
42 pathRewrite: { 42 pathRewrite: {
43 ['^' + process.env.VUE_APP_BASE_API]: '' 43 ['^' + process.env.VUE_APP_BASE_API]: ''
......