jinhui.wang

ver:1.3.0,文本域输入限制高度限制,组件更新,样式修改,文本修正

This diff is collapsed. Click to expand it.
...@@ -8,6 +8,10 @@ ...@@ -8,6 +8,10 @@
8 width: 100% !important; 8 width: 100% !important;
9 } 9 }
10 10
11 + .wid95 {
12 + width: 95% !important;
13 + }
14 +
11 .wid90 { 15 .wid90 {
12 width: 90% !important; 16 width: 90% !important;
13 } 17 }
...@@ -80,9 +84,9 @@ ...@@ -80,9 +84,9 @@
80 margin-left: 20px; 84 margin-left: 20px;
81 } 85 }
82 86
83 - .el-dialog:not(.is-fullscreen) { 87 + // .el-dialog:not(.is-fullscreen) {
84 - margin-top: 6vh !important; 88 + // margin-top: 6vh !important;
85 - } 89 + // }
86 90
87 .el-table { 91 .el-table {
88 92
...@@ -108,13 +112,13 @@ ...@@ -108,13 +112,13 @@
108 .form-header { 112 .form-header {
109 font-size: 15px; 113 font-size: 15px;
110 color: #6379bb; 114 color: #6379bb;
111 - border-bottom: 1px solid #ddd; 115 + // border-bottom: 1px solid #ddd;
112 margin: 8px 10px 25px 10px; 116 margin: 8px 10px 25px 10px;
113 padding-top: 15px; 117 padding-top: 15px;
114 padding-bottom: 5px; 118 padding-bottom: 5px;
115 119
116 .formItem { 120 .formItem {
117 - width: 90%; 121 + width: 95%;
118 // max-width: 300px; 122 // max-width: 300px;
119 } 123 }
120 } 124 }
......
...@@ -26,6 +26,10 @@ html { ...@@ -26,6 +26,10 @@ html {
26 height: 100%; 26 height: 100%;
27 } 27 }
28 28
29 +input {
30 + background-color: #fff !important;
31 +}
32 +
29 *, 33 *,
30 *:before, 34 *:before,
31 *:after { 35 *:after {
...@@ -193,8 +197,8 @@ aside { ...@@ -193,8 +197,8 @@ aside {
193 197
194 .el-table__body-wrapper { 198 .el-table__body-wrapper {
195 &::-webkit-scrollbar { 199 &::-webkit-scrollbar {
196 - height: 10px; 200 + height: 7px;
197 - width: 10px; 201 + width: 7px;
198 } 202 }
199 203
200 &::-webkit-scrollbar-track { 204 &::-webkit-scrollbar-track {
...@@ -210,6 +214,13 @@ aside { ...@@ -210,6 +214,13 @@ aside {
210 } 214 }
211 } 215 }
212 216
217 +.el-scrollbar__wrap {
218 + &::-webkit-scrollbar {
219 + height: 0px;
220 + width: 0px;
221 + }
222 +}
223 +
213 // 解决表格固定列问题 224 // 解决表格固定列问题
214 .el-table__fixed, 225 .el-table__fixed,
215 .el-table__fixed-right { 226 .el-table__fixed-right {
......
...@@ -133,7 +133,7 @@ export default { ...@@ -133,7 +133,7 @@ export default {
133 }); 133 });
134 }, 134 },
135 local(val) { 135 local(val) {
136 - this.$i18n.locale = val; //此处val为 zh 或者 en 136 + // this.$i18n.locale = val; //此处val为 zh 或者 en
137 }, 137 },
138 }, 138 },
139 }; 139 };
......
...@@ -11,20 +11,18 @@ import App from './App' ...@@ -11,20 +11,18 @@ import App from './App'
11 import store from './store' 11 import store from './store'
12 import router from './router' 12 import router from './router'
13 import permission from './directive/permission' 13 import permission from './directive/permission'
14 +// import i18n from './i18n/index'
14 15
15 import './assets/icons' // icon 16 import './assets/icons' // icon
16 import './permission' // permission control 17 import './permission' // permission control
17 -//import { getDicts } from "@/api/system/dict/data"; 18 +import { parseTime, resetForm, addDateRange, selectDictLabel, selectDictLabels, download, handleTree, upCase, nowDate } from "@/utils/FedEx";
18 -//import { getConfigKey } from "@/api/system/config";
19 -import { parseTime, resetForm, addDateRange, selectDictLabel, selectDictLabels, download, handleTree } from "@/utils/FedEx";
20 import Pagination from "@/components/Pagination"; 19 import Pagination from "@/components/Pagination";
21 // 自定义表格工具扩展 20 // 自定义表格工具扩展
22 import RightToolbar from "@/components/RightToolbar" 21 import RightToolbar from "@/components/RightToolbar"
23 import Table from "@/components/Table" 22 import Table from "@/components/Table"
23 +import tableHeaders from '@/assets/languages/tableHeaders'
24 24
25 // 全局方法挂载 25 // 全局方法挂载
26 -//Vue.prototype.getDicts = getDicts
27 -//Vue.prototype.getConfigKey = getConfigKey
28 Vue.prototype.parseTime = parseTime 26 Vue.prototype.parseTime = parseTime
29 Vue.prototype.resetForm = resetForm 27 Vue.prototype.resetForm = resetForm
30 Vue.prototype.addDateRange = addDateRange 28 Vue.prototype.addDateRange = addDateRange
...@@ -32,11 +30,18 @@ Vue.prototype.selectDictLabel = selectDictLabel ...@@ -32,11 +30,18 @@ Vue.prototype.selectDictLabel = selectDictLabel
32 Vue.prototype.selectDictLabels = selectDictLabels 30 Vue.prototype.selectDictLabels = selectDictLabels
33 Vue.prototype.download = download 31 Vue.prototype.download = download
34 Vue.prototype.handleTree = handleTree 32 Vue.prototype.handleTree = handleTree
33 +Vue.prototype.upCase = upCase
34 +Vue.prototype.nowDate = nowDate
35 +Vue.prototype.tableHeaders = tableHeaders
35 36
36 Vue.prototype.msgSuccess = function (msg) { 37 Vue.prototype.msgSuccess = function (msg) {
37 this.$message({ showClose: true, message: msg, type: "success" }); 38 this.$message({ showClose: true, message: msg, type: "success" });
38 } 39 }
39 40
41 +Vue.prototype.msgWarning = function (msg) {
42 + this.$message({ showClose: true, message: msg, type: "warning" });
43 +}
44 +
40 Vue.prototype.msgError = function (msg) { 45 Vue.prototype.msgError = function (msg) {
41 this.$message({ showClose: true, message: msg, type: "error" }); 46 this.$message({ showClose: true, message: msg, type: "error" });
42 } 47 }
...@@ -48,7 +53,7 @@ Vue.prototype.msgInfo = function (msg) { ...@@ -48,7 +53,7 @@ Vue.prototype.msgInfo = function (msg) {
48 // 全局组件挂载 53 // 全局组件挂载
49 Vue.component('Pagination', Pagination) 54 Vue.component('Pagination', Pagination)
50 Vue.component('RightToolbar', RightToolbar) 55 Vue.component('RightToolbar', RightToolbar)
51 -Vue.component('Tables',Table) 56 +Vue.component('Tables', Table)
52 57
53 Vue.use(permission) 58 Vue.use(permission)
54 /** 59 /**
...@@ -62,8 +67,7 @@ Vue.use(permission) ...@@ -62,8 +67,7 @@ Vue.use(permission)
62 67
63 Vue.use(Element, { 68 Vue.use(Element, {
64 //size: Cookies.get('size') || 'medium' // set element-ui default size 69 //size: Cookies.get('size') || 'medium' // set element-ui default size
65 - size: localStorage.getItem('size') || 'medium' // set element-ui default size 70 + // size: localStorage.getItem('size') || 'medium' // set element-ui default size
66 -
67 }) 71 })
68 72
69 Vue.config.productionTip = false 73 Vue.config.productionTip = false
...@@ -72,5 +76,6 @@ new Vue({ ...@@ -72,5 +76,6 @@ new Vue({
72 el: '#app', 76 el: '#app',
73 router, 77 router,
74 store, 78 store,
79 + // i18n,
75 render: h => h(App) 80 render: h => h(App)
76 }) 81 })
......
...@@ -3,10 +3,10 @@ ...@@ -3,10 +3,10 @@
3 * Copyright (c) 2019 FedEx 3 * Copyright (c) 2019 FedEx
4 */ 4 */
5 5
6 - const baseURL = process.env.VUE_APP_BASE_API 6 +const baseURL = process.env.VUE_APP_BASE_API
7 7
8 - // 日期格式化 8 +// 日期格式化
9 - export function parseTime(time, pattern) { 9 +export function parseTime(time, pattern) {
10 //debugger 10 //debugger
11 if (arguments.length === 0 || !time) { 11 if (arguments.length === 0 || !time) {
12 return null 12 return null
...@@ -45,17 +45,17 @@ ...@@ -45,17 +45,17 @@
45 return value || 0 45 return value || 0
46 }) 46 })
47 return time_str 47 return time_str
48 - } 48 +}
49 49
50 - // 表单重置 50 +// 表单重置
51 - export function resetForm(refName) { 51 +export function resetForm(refName) {
52 if (this.$refs[refName]) { 52 if (this.$refs[refName]) {
53 this.$refs[refName].resetFields(); 53 this.$refs[refName].resetFields();
54 } 54 }
55 - } 55 +}
56 56
57 - // 添加日期范围 57 +// 添加日期范围
58 - export function addDateRange(params, dateRange, propName) { 58 +export function addDateRange(params, dateRange, propName) {
59 var search = params; 59 var search = params;
60 search.params = {}; 60 search.params = {};
61 if (null != dateRange && '' != dateRange) { 61 if (null != dateRange && '' != dateRange) {
...@@ -68,10 +68,10 @@ ...@@ -68,10 +68,10 @@
68 } 68 }
69 } 69 }
70 return search; 70 return search;
71 - } 71 +}
72 72
73 - // 回显数据字典 73 +// 回显数据字典
74 - export function selectDictLabel(datas, value) { 74 +export function selectDictLabel(datas, value) {
75 var actions = []; 75 var actions = [];
76 Object.keys(datas).some((key) => { 76 Object.keys(datas).some((key) => {
77 if (datas[key].dictValue == ('' + value)) { 77 if (datas[key].dictValue == ('' + value)) {
...@@ -80,10 +80,10 @@ ...@@ -80,10 +80,10 @@
80 } 80 }
81 }) 81 })
82 return actions.join(''); 82 return actions.join('');
83 - } 83 +}
84 84
85 - // 回显数据字典(字符串数组) 85 +// 回显数据字典(字符串数组)
86 - export function selectDictLabels(datas, value, separator) { 86 +export function selectDictLabels(datas, value, separator) {
87 var actions = []; 87 var actions = [];
88 var currentSeparator = undefined === separator ? "," : separator; 88 var currentSeparator = undefined === separator ? "," : separator;
89 var temp = value.split(currentSeparator); 89 var temp = value.split(currentSeparator);
...@@ -95,15 +95,15 @@ ...@@ -95,15 +95,15 @@
95 }) 95 })
96 }) 96 })
97 return actions.join('').substring(0, actions.join('').length - 1); 97 return actions.join('').substring(0, actions.join('').length - 1);
98 - } 98 +}
99 99
100 - // 通用下载方法 100 +// 通用下载方法
101 - export function download(fileName) { 101 +export function download(fileName) {
102 window.location.href = baseURL + "/common/download?fileName=" + encodeURI(fileName) + "&delete=" + true; 102 window.location.href = baseURL + "/common/download?fileName=" + encodeURI(fileName) + "&delete=" + true;
103 - } 103 +}
104 104
105 - // 字符串格式化(%s ) 105 +// 字符串格式化(%s )
106 - export function sprintf(str) { 106 +export function sprintf(str) {
107 var args = arguments, flag = true, i = 1; 107 var args = arguments, flag = true, i = 1;
108 str = str.replace(/%s/g, function () { 108 str = str.replace(/%s/g, function () {
109 var arg = args[i++]; 109 var arg = args[i++];
...@@ -114,24 +114,24 @@ ...@@ -114,24 +114,24 @@
114 return arg; 114 return arg;
115 }); 115 });
116 return flag ? str : ''; 116 return flag ? str : '';
117 - } 117 +}
118 118
119 - // 转换字符串,undefined,null等转化为"" 119 +// 转换字符串,undefined,null等转化为""
120 - export function praseStrEmpty(str) { 120 +export function praseStrEmpty(str) {
121 if (!str || str == "undefined" || str == "null") { 121 if (!str || str == "undefined" || str == "null") {
122 return ""; 122 return "";
123 } 123 }
124 return str; 124 return str;
125 - } 125 +}
126 126
127 - /** 127 +/**
128 * 构造树型结构数据 128 * 构造树型结构数据
129 * @param {*} data 数据源 129 * @param {*} data 数据源
130 * @param {*} id id字段 默认 'id' 130 * @param {*} id id字段 默认 'id'
131 * @param {*} parentId 父节点字段 默认 'parentId' 131 * @param {*} parentId 父节点字段 默认 'parentId'
132 * @param {*} children 孩子节点字段 默认 'children' 132 * @param {*} children 孩子节点字段 默认 'children'
133 */ 133 */
134 - export function handleTree(data, id, parentId, children) { 134 +export function handleTree(data, id, parentId, children) {
135 let config = { 135 let config = {
136 id: id || 'id', 136 id: id || 'id',
137 parentId: parentId || 'parentId', 137 parentId: parentId || 'parentId',
...@@ -173,10 +173,16 @@ ...@@ -173,10 +173,16 @@
173 } 173 }
174 } 174 }
175 return tree; 175 return tree;
176 - } 176 +}
177 177
178 - //字符串英文转大写,;转英文; 178 +//字符串英文转大写,;转英文;
179 - export function upCase(str){ 179 +export function upCase(str) {
180 - let newStr = str.replace(/;/g,";").toUpperCase(); 180 + let newStr = str.replace(/;/g, ";").toUpperCase();
181 return newStr; 181 return newStr;
182 - }
...\ No newline at end of file ...\ No newline at end of file
182 +}
183 +
184 +//当前日期
185 +export function nowDate() {
186 + let date = new Date()
187 + return `${date.getFullYear()}-${(date.getMonth() + 1) > 9 ? (date.getMonth() + 1) : '0' + (date.getMonth() + 1)}-${(date.getDate()) > 9 ? date.getDate() : '0' + (date.getDate())}`
188 +}
...\ No newline at end of file ...\ No newline at end of file
......
...@@ -204,293 +204,7 @@ export default { ...@@ -204,293 +204,7 @@ export default {
204 customsReceiptStatusId: null, 204 customsReceiptStatusId: null,
205 accsPool: "OSPR" 205 accsPool: "OSPR"
206 }, //查询数据 206 }, //查询数据
207 - tableHeader: [ 207 + tableHeader: this.tableHeaders['cargoAllocation'], //表头数据
208 - {
209 - name: "口岸代码",
210 - value: "portName",
211 - width: "100",
212 - align: "center",
213 - sorTable: true,
214 - },
215 - {
216 - name: "取件日期",
217 - value: "pickUpDate",
218 - width: "120",
219 - align: "center",
220 - sorTable: true,
221 - },
222 - {
223 - name: "取件扫描号",
224 - value: "pickUpScanNo",
225 - width: "120",
226 - align: "center",
227 - sorTable: true,
228 - },
229 - {
230 - name: "站点",
231 - value: "siteName",
232 - width: "80",
233 - align: "center",
234 - sorTable: true,
235 - },
236 - {
237 - name: "运单号",
238 - value: "waybillNo",
239 - width: "120",
240 - align: "center",
241 - sorTable: true,
242 - },
243 - {
244 - name: "总单号",
245 - value: "totalWaybillNo",
246 - width: "120",
247 - align: "center",
248 - sorTable: true,
249 - },
250 - {
251 - name: "服务类型",
252 - value: "serviceTypeName",
253 - width: "100",
254 - align: "center",
255 - sorTable: true,
256 - },
257 - {
258 - name: "服务代码",
259 - value: "serviceCode",
260 - width: "100",
261 - align: "center",
262 - },
263 - {
264 - name: "URSA",
265 - value: "ursa",
266 - width: "100",
267 - align: "center",
268 - sorTable: true,
269 - },
270 - {
271 - name: "申报类型",
272 - value: "typeName",
273 - width: "100",
274 - align: "center",
275 - sorTable: true,
276 - },
277 - {
278 - name: "HandlingCode",
279 - value: "handingCode",
280 - width: "150",
281 - align: "center",
282 - sorTable: true,
283 - },
284 - {
285 - name: "subcategory",
286 - value: "subCategory",
287 - width: "140",
288 - align: "center",
289 - sorTable: true,
290 - },
291 - {
292 - name: "件数",
293 - value: "qty",
294 - width: "80",
295 - align: "center",
296 - sorTable: true,
297 - },
298 - {
299 - name: "实际重量",
300 - value: "actualWeight",
301 - width: "100",
302 - align: "center",
303 - sorTable: true,
304 - },
305 - {
306 - name: "收件人国家代码",
307 - value: "consigneeCountry",
308 - width: "150",
309 - align: "center",
310 - sorTable: true,
311 - },
312 - {
313 - name: "品名描述",
314 - value: "nameDescription",
315 - width: "100",
316 - align: "center",
317 - },
318 - {
319 - name: "海关回执状态",
320 - value: "customsReceiptStatusName",
321 - width: "140",
322 - align: "center",
323 - sorTable: true,
324 - },
325 - {
326 - name: "预审状态",
327 - value: "preQualificationStatus",
328 - width: "100",
329 - align: "center",
330 - sorTable: true,
331 - },
332 - {
333 - name: "航班预审意见",
334 - value: "caPretrialOpinion",
335 - width: "120",
336 - align: "center",
337 - },
338 - {
339 - name: "货物状态",
340 - value: "statusName",
341 - width: "100",
342 - align: "center",
343 - sorTable: true,
344 - },
345 - {
346 - name: "终配航班号",
347 - value: "finalFlightNo",
348 - width: "120",
349 - align: "center",
350 - sorTable: true,
351 - },
352 - {
353 - name: "终配航班日期",
354 - value: "finalFlightTime",
355 - width: "140",
356 - align: "center",
357 - sorTable: true,
358 - },
359 - {
360 - name: "二配航班号",
361 - value: "twoMatchFlightNo",
362 - width: "120",
363 - align: "center",
364 - sorTable: true,
365 - },
366 - {
367 - name: "二配航班日期",
368 - value: "twoMatchFlightTime",
369 - width: "150",
370 - align: "center",
371 - sorTable: true,
372 - },
373 - {
374 - name: "预配航班号",
375 - value: "preplanFlightNo",
376 - width: "120",
377 - align: "center",
378 - sorTable: true,
379 - },
380 - {
381 - name: "预配航班日期",
382 - value: "preplanFlightTime",
383 - width: "150",
384 - align: "center",
385 - sorTable: true,
386 - },
387 - {
388 - name: "ACCS原航班号",
389 - value: "fltNoAccs",
390 - width: "150",
391 - align: "center",
392 - sorTable: true,
393 - },
394 - {
395 - name: "ACCS原航班日期",
396 - value: "fltDateAccs",
397 - width: "150",
398 - align: "center",
399 - sorTable: true,
400 - },
401 - {
402 - name: "ACCS原航线",
403 - value: "accsFlightRoute",
404 - width: "140",
405 - align: "center",
406 - sorTable: true,
407 - },
408 - {
409 - name: "是否RDE手工录入",
410 - value: "manualRde",
411 - width: "170",
412 - align: "center",
413 - sorTable: true,
414 - },
415 - {
416 - name: "是否自动",
417 - value: "cargoRulesStatus",
418 - width: "100",
419 - align: "center",
420 - sorTable: true,
421 - },
422 - {
423 - name: "发件人账号",
424 - value: "shipperAccount",
425 - width: "120",
426 - align: "center",
427 - },
428 - {
429 - name: "发件公司中文名称",
430 - value: "shipperCompany",
431 - width: "150",
432 - align: "center",
433 - },
434 - {
435 - name: "始发地城市名称",
436 - value: "originCity",
437 - width: "130",
438 - align: "center",
439 - },
440 - {
441 - name: "收件地",
442 - value: "destinationSiteName",
443 - width: "90",
444 - align: "center",
445 - },
446 - {
447 - name: "尺寸",
448 - value: "sizeStr",
449 - width: "80",
450 - align: "center",
451 - sorTable: true,
452 - },
453 - {
454 - name: "大货预审意见(是否可以配置航班)",
455 - value: "bigPretrialOpinion",
456 - width: "250",
457 - align: "center",
458 - },
459 - {
460 - name: "大货预审时间",
461 - value: "bigPretrialTime",
462 - width: "120",
463 - align: "center",
464 - },
465 - {
466 - name: "海关回执时间",
467 - value: "customsReceiptTime",
468 - width: "150",
469 - align: "center",
470 - sorTable: true,
471 - },
472 - {
473 - name: "航班预审时间",
474 - value: "caPretrialTime",
475 - width: "150",
476 - align: "center",
477 - sorTable: true,
478 - },
479 - {
480 - name: "创建人",
481 - value: "createUserName",
482 - width: "90",
483 - align: "center",
484 - sorTable: true,
485 - },
486 - {
487 - name: "创建时间",
488 - value: "createTime",
489 - width: "100",
490 - align: "center",
491 - sorTable: true,
492 - },
493 - ], //表头数据
494 tableData: [], //表格数据 208 tableData: [], //表格数据
495 tableSelection: [], //选中数据 209 tableSelection: [], //选中数据
496 selectData: { 210 selectData: {
......
...@@ -50,7 +50,7 @@ ...@@ -50,7 +50,7 @@
50 <el-button type="text" size="mini" icon="el-icon-edit" v-hasPermi="['allocation:alloc:update']" 50 <el-button type="text" size="mini" icon="el-icon-edit" v-hasPermi="['allocation:alloc:update']"
51 @click="handleClick(scope.row.id, 'update')">修改</el-button> 51 @click="handleClick(scope.row.id, 'update')">修改</el-button>
52 <el-button type="text" size="mini" icon="el-icon-delete" v-hasPermi="['allocation:alloc:delete']" 52 <el-button type="text" size="mini" icon="el-icon-delete" v-hasPermi="['allocation:alloc:delete']"
53 - @click="del(scope.row.id, scope.row.status)">删除</el-button> 53 + @click="del(scope.row.id, scope.row.status)" style="color:#ff4949">删除</el-button>
54 <el-button type="text" size="mini" icon="el-icon-video-pause" v-hasPermi="['allocation:alloc:openClose']" 54 <el-button type="text" size="mini" icon="el-icon-video-pause" v-hasPermi="['allocation:alloc:openClose']"
55 @click="changeStatus(scope.row.id, 3)" v-if="scope.row.status == '1'">停用</el-button> 55 @click="changeStatus(scope.row.id, 3)" v-if="scope.row.status == '1'">停用</el-button>
56 <el-button type="text" size="mini" icon="el-icon-video-play" v-hasPermi="['allocation:alloc:openClose']" 56 <el-button type="text" size="mini" icon="el-icon-video-play" v-hasPermi="['allocation:alloc:openClose']"
......
...@@ -51,8 +51,8 @@ ...@@ -51,8 +51,8 @@
51 <template slot-scope="scope"> 51 <template slot-scope="scope">
52 <el-button size="mini" type="text" icon="el-icon-edit" v-hasPermi="['allocation:rand:update']" 52 <el-button size="mini" type="text" icon="el-icon-edit" v-hasPermi="['allocation:rand:update']"
53 @click="handleUpdate(scope.row)">修改</el-button> 53 @click="handleUpdate(scope.row)">修改</el-button>
54 - <el-button size="mini" type="text" icon="el-icon-delete" v-hasPermi="['allocation:rand:delete']" 54 + <el-button size="mini" type="text" icon="el-icon-delete" style="color:#ff4949"
55 - @click="handleDeleteorPlayorpause(scope.row, 0, '删除')"> 55 + v-hasPermi="['allocation:rand:delete']" @click="handleDeleteorPlayorpause(scope.row, 0, '删除')">
56 删除</el-button> 56 删除</el-button>
57 <el-button size="mini" type="text" icon="el-icon-video-play" v-if="scope.row.status == '3'" 57 <el-button size="mini" type="text" icon="el-icon-video-play" v-if="scope.row.status == '3'"
58 v-hasPermi="['allocation:rand:openClose']" @click="handleDeleteorPlayorpause(scope.row, 1, '启用')">启用 58 v-hasPermi="['allocation:rand:openClose']" @click="handleDeleteorPlayorpause(scope.row, 1, '启用')">启用
......
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
25 <el-col :span="6"> 25 <el-col :span="6">
26 <el-form-item label="运单号"> 26 <el-form-item label="运单号">
27 <el-input clearable type="textarea" v-model="queryParams.waybillNo" class="formItem" 27 <el-input clearable type="textarea" v-model="queryParams.waybillNo" class="formItem"
28 - placeholder="请输入运单号(回车间隔)" :rows="1"></el-input> 28 + placeholder="请输入运单号(回车间隔)" :rows="1" :maxlength="12000"></el-input>
29 </el-form-item> 29 </el-form-item>
30 </el-col> 30 </el-col>
31 </el-row> 31 </el-row>
......
...@@ -213,322 +213,7 @@ export default { ...@@ -213,322 +213,7 @@ export default {
213 limitStart: 1, 213 limitStart: 1,
214 limitSize: 100, 214 limitSize: 100,
215 }, //表单数据 215 }, //表单数据
216 - tableHeader: [ 216 + tableHeader: this.tableHeaders['cargo'], //表头数据
217 - {
218 - name: "口岸代码",
219 - value: "portName",
220 - width: "100",
221 - align: "center",
222 - sorTable: true,
223 - },
224 - {
225 - name: "取件日期",
226 - value: "pickUpDate",
227 - width: "120",
228 - align: "center",
229 - sorTable: true,
230 - },
231 - {
232 - name: "取件扫描号",
233 - value: "pickUpScanNo",
234 - width: "120",
235 - align: "center",
236 - sorTable: true,
237 - },
238 - {
239 - name: "站点",
240 - value: "siteName",
241 - width: "80",
242 - align: "center",
243 - sorTable: true,
244 - },
245 - {
246 - name: "运单号",
247 - value: "waybillNo",
248 - width: "120",
249 - align: "center",
250 - sorTable: true,
251 - },
252 - {
253 - name: "总单号",
254 - value: "totalWaybillNo",
255 - width: "120",
256 - align: "center",
257 - sorTable: true,
258 - },
259 - {
260 - name: "服务类型",
261 - value: "serviceTypeName",
262 - width: "100",
263 - align: "center",
264 - sorTable: true,
265 - },
266 - {
267 - name: "服务代码",
268 - value: "serviceCode",
269 - width: "100",
270 - align: "center",
271 - sorTable: false,
272 - },
273 - {
274 - name: "URSA",
275 - value: "ursa",
276 - width: "100",
277 - align: "center",
278 - sorTable: true,
279 - },
280 - {
281 - name: "推送状态",
282 - value: "cargoAllocationDataStatus",
283 - width: "100",
284 - align: "center",
285 - sorTable: true,
286 - },
287 - {
288 - name: "配舱状态",
289 - value: "flightIdImac",
290 - width: "100",
291 - align: "center",
292 - sorTable: true,
293 - },
294 - {
295 - name: "释放状态",
296 - value: "releasing",
297 - width: "100",
298 - align: "center",
299 - sorTable: true,
300 - },
301 - {
302 - name: "申报类型",
303 - value: "typeName",
304 - width: "100",
305 - align: "center",
306 - sorTable: true,
307 - },
308 - {
309 - name: "ACCSpool",
310 - value: "accsPool",
311 - width: "120",
312 - align: "center",
313 - sorTable: true,
314 - },
315 - {
316 - name: "HandlingCode",
317 - value: "handingCode",
318 - width: "150",
319 - align: "center",
320 - sorTable: true,
321 - },
322 - {
323 - name: "subcategory",
324 - value: "subCategory",
325 - width: "140",
326 - align: "center",
327 - sorTable: true,
328 - },
329 - {
330 - name: "件数",
331 - value: "qty",
332 - width: "80",
333 - align: "center",
334 - sorTable: true,
335 - },
336 - {
337 - name: "实际重量",
338 - value: "actualWeight",
339 - width: "100",
340 - align: "center",
341 - sorTable: true,
342 - },
343 - {
344 - name: "收件人国家代码",
345 - value: "consigneeCountry",
346 - width: "150",
347 - align: "center",
348 - sorTable: true,
349 - },
350 - {
351 - name: "品名描述",
352 - value: "nameDescription",
353 - width: "100",
354 - align: "center",
355 - },
356 - {
357 - name: "海关回执状态",
358 - value: "customsReceiptStatusName",
359 - width: "140",
360 - align: "center",
361 - sorTable: true,
362 - },
363 - {
364 - name: "预审状态",
365 - value: "preQualificationStatus",
366 - width: "100",
367 - align: "center",
368 - sorTable: true,
369 - },
370 - {
371 - name: "航班预审意见",
372 - value: "caPretrialOpinion",
373 - width: "120",
374 - align: "center",
375 - },
376 - {
377 - name: "货物状态",
378 - value: "statusName",
379 - width: "100",
380 - align: "center",
381 - sorTable: true,
382 - },
383 - {
384 - name: "终配航班号",
385 - value: "finalFlightNo",
386 - width: "120",
387 - align: "center",
388 - sorTable: true,
389 - },
390 - {
391 - name: "终配航班日期",
392 - value: "finalFlightTime",
393 - width: "140",
394 - align: "center",
395 - sorTable: true,
396 - },
397 - {
398 - name: "二配航班号",
399 - value: "twoMatchFlightNo",
400 - width: "120",
401 - align: "center",
402 - sorTable: true,
403 - },
404 - {
405 - name: "二配航班日期",
406 - value: "twoMatchFlightTime",
407 - width: "150",
408 - align: "center",
409 - sorTable: true,
410 - },
411 - {
412 - name: "预配航班号",
413 - value: "preplanFlightNo",
414 - width: "120",
415 - align: "center",
416 - sorTable: true,
417 - },
418 - {
419 - name: "预配航班日期",
420 - value: "preplanFlightTime",
421 - width: "150",
422 - align: "center",
423 - sorTable: true,
424 - },
425 - {
426 - name: "ACCS原航班号",
427 - value: "fltNoAccs",
428 - width: "150",
429 - align: "center",
430 - sorTable: true,
431 - },
432 - {
433 - name: "ACCS原航班日期",
434 - value: "fltDateAccs",
435 - width: "150",
436 - align: "center",
437 - sorTable: true,
438 - },
439 - {
440 - name: "ACCS原航线",
441 - value: "accsFlightRoute",
442 - width: "140",
443 - align: "center",
444 - sorTable: true,
445 - },
446 - {
447 - name: "是否RDE手工录入",
448 - value: "manualRde",
449 - width: "170",
450 - align: "center",
451 - sorTable: true,
452 - },
453 - {
454 - name: "是否自动",
455 - value: "cargoRulesStatus",
456 - width: "100",
457 - align: "center",
458 - sorTable: true,
459 - },
460 - {
461 - name: "发件人账号",
462 - value: "shipperAccount",
463 - width: "120",
464 - align: "center",
465 - },
466 - {
467 - name: "发件公司中文名称",
468 - value: "shipperCompany",
469 - width: "150",
470 - align: "center",
471 - },
472 - {
473 - name: "始发地城市名称",
474 - value: "originCity",
475 - width: "130",
476 - align: "center",
477 - },
478 - {
479 - name: "收件地",
480 - value: "destinationSiteName",
481 - width: "90",
482 - align: "center",
483 - },
484 - {
485 - name: "尺寸",
486 - value: "sizeStr",
487 - width: "80",
488 - align: "center",
489 - sorTable: true,
490 - },
491 - {
492 - name: "大货预审意见(是否可以配置航班)",
493 - value: "bigPretrialOpinion",
494 - width: "250",
495 - align: "center",
496 - },
497 - {
498 - name: "大货预审时间",
499 - value: "bigPretrialTime",
500 - width: "120",
501 - align: "center",
502 - },
503 - {
504 - name: "海关回执时间",
505 - value: "customsReceiptTime",
506 - width: "150",
507 - align: "center",
508 - sorTable: true,
509 - },
510 - {
511 - name: "航班预审时间",
512 - value: "caPretrialTime",
513 - width: "150",
514 - align: "center",
515 - sorTable: true,
516 - },
517 - {
518 - name: "创建人",
519 - value: "createUserName",
520 - width: "90",
521 - align: "center",
522 - sorTable: true,
523 - },
524 - {
525 - name: "创建时间",
526 - value: "createTime",
527 - width: "100",
528 - align: "center",
529 - sorTable: true,
530 - },
531 - ], //表头数据
532 releaseHeader: [ 217 releaseHeader: [
533 { 218 {
534 name: "提示信息", 219 name: "提示信息",
......
...@@ -98,10 +98,7 @@ export default { ...@@ -98,10 +98,7 @@ export default {
98 if (res.code === 200) { 98 if (res.code === 200) {
99 this.treeData = this.treeDataInfo(res.data); 99 this.treeData = this.treeDataInfo(res.data);
100 } else { 100 } else {
101 - this.$message({ 101 + this.msgWarning(res.msg)
102 - message: res.msg,
103 - type: "warning",
104 - });
105 } 102 }
106 }) 103 })
107 .catch((err) => { 104 .catch((err) => {
...@@ -144,16 +141,10 @@ export default { ...@@ -144,16 +141,10 @@ export default {
144 .then((res) => { 141 .then((res) => {
145 this.loading = false; 142 this.loading = false;
146 if (res.code === 200) { 143 if (res.code === 200) {
147 - this.$message({ 144 + this.msgSuccess('操作成功,需重新登录已获取新权限。')
148 - message: "操作成功,新增权限需重新登陆后刷新。",
149 - type: "success",
150 - });
151 this.$emit("handleClose", false); 145 this.$emit("handleClose", false);
152 } else { 146 } else {
153 - this.$message({ 147 + this.msgWarning(res.msg)
154 - message: res.msg,
155 - type: "warning",
156 - });
157 } 148 }
158 }) 149 })
159 .catch((err) => { 150 .catch((err) => {
......
...@@ -30,9 +30,9 @@ ...@@ -30,9 +30,9 @@
30 <el-button type="primary" icon="el-icon-plus" size="mini" @click="addRole" v-hasPermi="['system:role:add']">新增角色 30 <el-button type="primary" icon="el-icon-plus" size="mini" @click="addRole" v-hasPermi="['system:role:add']">新增角色
31 </el-button> 31 </el-button>
32 </div> 32 </div>
33 - <Tables ductName="role" :data="data" :headerData="tableHeader" :infoData="tableHeader" :totalCount="total" 33 + <Tables ref="role" ductName="role" :data="data" :headerData="tableHeader" :totalCount="total"
34 :limitSize="formData.size" :page="formData.page" :pageSizes="[20, 30, 40, 50]" :loading="tableLoading" 34 :limitSize="formData.size" :page="formData.page" :pageSizes="[20, 30, 40, 50]" :loading="tableLoading"
35 - height="600" @sizeChange="sizeChange" @currentChange="currentChange"> 35 + :height="tableHeight" @sizeChange="sizeChange" @currentChange="currentChange">
36 <template slot="optionColumn"> 36 <template slot="optionColumn">
37 <el-table-column header-align="center" align="center" label="操作"> 37 <el-table-column header-align="center" align="center" label="操作">
38 <template slot-scope="scope"> 38 <template slot-scope="scope">
...@@ -55,7 +55,7 @@ ...@@ -55,7 +55,7 @@
55 55
56 <script> 56 <script>
57 import Drawer from "./drawer.vue"; 57 import Drawer from "./drawer.vue";
58 -import { MessageBox } from "element-ui"; 58 +
59 import { 59 import {
60 getRoleList, 60 getRoleList,
61 detailRole, 61 detailRole,
...@@ -77,44 +77,7 @@ export default { ...@@ -77,44 +77,7 @@ export default {
77 name: null, 77 name: null,
78 }, //查询条件 78 }, //查询条件
79 data: [], //表格数据 79 data: [], //表格数据
80 - tableHeader: [ 80 + tableHeader: this.tableHeaders['role'], //表头数据
81 - {
82 - name: "角色名称",
83 - value: "name",
84 - width: "150px",
85 - align: "center",
86 - },
87 - {
88 - name: "角色状态",
89 - value: "valid",
90 - width: "150px",
91 - align: "center",
92 - },
93 - {
94 - name: "创建人",
95 - value: "createUserName",
96 - width: "150px",
97 - align: "center",
98 - },
99 - {
100 - name: "创建时间",
101 - value: "createTime",
102 - width: "150px",
103 - align: "center",
104 - },
105 - {
106 - name: "修改时间",
107 - value: "updateTime",
108 - width: "150px",
109 - align: "center",
110 - },
111 - {
112 - name: "备注",
113 - value: "remark",
114 - width: "400px",
115 - align: "center",
116 - },
117 - ], //表头数据
118 roleData: {}, //角色详情 81 roleData: {}, //角色详情
119 createTime: [], 82 createTime: [],
120 drawer: false, 83 drawer: false,
...@@ -122,6 +85,7 @@ export default { ...@@ -122,6 +85,7 @@ export default {
122 roleFormDisabled: false, 85 roleFormDisabled: false,
123 tableLoading: false, 86 tableLoading: false,
124 total: 0, 87 total: 0,
88 + tableHeight: null
125 }; 89 };
126 }, 90 },
127 created() { 91 created() {
...@@ -129,6 +93,9 @@ export default { ...@@ -129,6 +93,9 @@ export default {
129 this.selectRoleList(); 93 this.selectRoleList();
130 } 94 }
131 }, 95 },
96 + mounted() {
97 + this.tableHeight = window.innerHeight - this.$refs.selectionRoleForm.$el.offsetHeight - 250
98 + },
132 activated() { 99 activated() {
133 this.selectRoleList(); 100 this.selectRoleList();
134 }, 101 },
...@@ -153,10 +120,7 @@ export default { ...@@ -153,10 +120,7 @@ export default {
153 this.data = res.data.list; 120 this.data = res.data.list;
154 this.total = res.data.total; 121 this.total = res.data.total;
155 } else { 122 } else {
156 - this.$message({ 123 + this.msgWarning(res.msg)
157 - message: res.msg,
158 - type: "warning",
159 - });
160 } 124 }
161 }) 125 })
162 .catch((err) => { 126 .catch((err) => {
...@@ -171,10 +135,7 @@ export default { ...@@ -171,10 +135,7 @@ export default {
171 if (res.code === 200) { 135 if (res.code === 200) {
172 this.roleData = res.data; 136 this.roleData = res.data;
173 } else { 137 } else {
174 - this.$message({ 138 + this.msgWarning(res.msg)
175 - message: res.msg,
176 - type: "warning",
177 - });
178 } 139 }
179 }) 140 })
180 .catch((err) => { 141 .catch((err) => {
...@@ -206,7 +167,7 @@ export default { ...@@ -206,7 +167,7 @@ export default {
206 row.row.valid == 1 167 row.row.valid == 1
207 ? ((msg = "是否关闭此角色"), (status.valid = 2)) 168 ? ((msg = "是否关闭此角色"), (status.valid = 2))
208 : ((msg = "是否启用此角色"), (status.valid = 1)); 169 : ((msg = "是否启用此角色"), (status.valid = 1));
209 - MessageBox.confirm(msg, "注意", { 170 + this.$confirm(msg, "注意", {
210 confirmButtonText: "确定", 171 confirmButtonText: "确定",
211 cancelButtonText: "取消", 172 cancelButtonText: "取消",
212 type: "warning", 173 type: "warning",
...@@ -214,16 +175,10 @@ export default { ...@@ -214,16 +175,10 @@ export default {
214 .then(() => { 175 .then(() => {
215 updateRoleStatus(status).then((res) => { 176 updateRoleStatus(status).then((res) => {
216 if (res.code === 200) { 177 if (res.code === 200) {
217 - this.$message({ 178 + this.msgSuccess('操作成功')
218 - message: "操作成功",
219 - type: "success",
220 - });
221 this.selectRoleList(); 179 this.selectRoleList();
222 } else { 180 } else {
223 - this.$message({ 181 + this.msgWarning(res.msg)
224 - message: res.msg,
225 - type: "warning",
226 - });
227 } 182 }
228 }); 183 });
229 }) 184 })
...@@ -231,7 +186,7 @@ export default { ...@@ -231,7 +186,7 @@ export default {
231 }, 186 },
232 //删除角色 187 //删除角色
233 removeRole(row) { 188 removeRole(row) {
234 - MessageBox.confirm( 189 + this.$confirm(
235 "如删除此角色,角色下所有用户将从中被剔除,可能会对用户操作造成影响!", 190 "如删除此角色,角色下所有用户将从中被剔除,可能会对用户操作造成影响!",
236 "注意", 191 "注意",
237 { 192 {
...@@ -247,13 +202,10 @@ export default { ...@@ -247,13 +202,10 @@ export default {
247 confirmDel: false, 202 confirmDel: false,
248 }).then((res) => { 203 }).then((res) => {
249 if (res.code === 200) { 204 if (res.code === 200) {
250 - this.$message({ 205 + this.msgSuccess('删除成功')
251 - message: "删除成功",
252 - type: "success",
253 - });
254 this.selectRoleList(); 206 this.selectRoleList();
255 } else if (res.code === 202) { 207 } else if (res.code === 202) {
256 - MessageBox.confirm(res.msg, "注意", { 208 + this.$confirm(res.msg, "注意", {
257 confirmButtonText: "确定", 209 confirmButtonText: "确定",
258 cancelButtonText: "取消", 210 cancelButtonText: "取消",
259 type: "warning", 211 type: "warning",
...@@ -265,20 +217,14 @@ export default { ...@@ -265,20 +217,14 @@ export default {
265 confirmDel: true, 217 confirmDel: true,
266 }).then((res) => { 218 }).then((res) => {
267 if (res.code === 200) { 219 if (res.code === 200) {
268 - this.$message({ 220 + this.msgSuccess('操作成功')
269 - message: "操作成功",
270 - type: "success",
271 - });
272 this.selectRoleList(); 221 this.selectRoleList();
273 } 222 }
274 }); 223 });
275 }) 224 })
276 .catch(() => { }); 225 .catch(() => { });
277 } else { 226 } else {
278 - this.$message({ 227 + this.msgWarning(res.msg)
279 - message: res.msg,
280 - type: "warning",
281 - });
282 } 228 }
283 }); 229 });
284 }) 230 })
......
...@@ -172,8 +172,6 @@ export default { ...@@ -172,8 +172,6 @@ export default {
172 }, 172 },
173 }; 173 };
174 }, 174 },
175 - created() {
176 - },
177 watch: { 175 watch: {
178 drawer(val, oldVal) { 176 drawer(val, oldVal) {
179 if (val) { 177 if (val) {
...@@ -209,10 +207,7 @@ export default { ...@@ -209,10 +207,7 @@ export default {
209 } 207 }
210 }); 208 });
211 } else { 209 } else {
212 - this.$message({ 210 + this.msgWarning(res.msg)
213 - message: res.msg,
214 - type: "warning",
215 - });
216 } 211 }
217 }) 212 })
218 .catch((err) => { 213 .catch((err) => {
...@@ -225,17 +220,13 @@ export default { ...@@ -225,17 +220,13 @@ export default {
225 if (res.code === 200) { 220 if (res.code === 200) {
226 this.portNameList = res.data; 221 this.portNameList = res.data;
227 } else { 222 } else {
228 - this.$message({ 223 + this.msgWarning(res.msg)
229 - message: res.msg,
230 - type: "warning",
231 - });
232 } 224 }
233 }) 225 })
234 .catch((err) => { 226 .catch((err) => {
235 console.log(err); 227 console.log(err);
236 }); 228 });
237 }, 229 },
238 -
239 //关闭 230 //关闭
240 handleClose() { 231 handleClose() {
241 this.roleid = []; 232 this.roleid = [];
...@@ -246,7 +237,6 @@ export default { ...@@ -246,7 +237,6 @@ export default {
246 this.clearValidate('userForm') 237 this.clearValidate('userForm')
247 this.$emit("handleClose", false); 238 this.$emit("handleClose", false);
248 }, 239 },
249 -
250 //提交 240 //提交
251 submit() { 241 submit() {
252 if (this.port.join(",").length > 0) { 242 if (this.port.join(",").length > 0) {
...@@ -258,16 +248,10 @@ export default { ...@@ -258,16 +248,10 @@ export default {
258 .then((res) => { 248 .then((res) => {
259 this.loading = false; 249 this.loading = false;
260 if (res.code === 200) { 250 if (res.code === 200) {
261 - this.$message({ 251 + this.msgSuccess('操作成功,需重新登录已获取新权限。')
262 - message: "操作成功",
263 - type: "success",
264 - });
265 this.$emit("handleClose", false); 252 this.$emit("handleClose", false);
266 } else { 253 } else {
267 - this.$message({ 254 + this.msgWarning(res.msg)
268 - message: res.msg,
269 - type: "warning",
270 - });
271 } 255 }
272 }) 256 })
273 .catch((err) => { 257 .catch((err) => {
...@@ -275,10 +259,7 @@ export default { ...@@ -275,10 +259,7 @@ export default {
275 console.log(err); 259 console.log(err);
276 }); 260 });
277 } else { 261 } else {
278 - this.$message({ 262 + this.msgWarning('口岸不能为空')
279 - message: "口岸不能为空",
280 - type: "warning",
281 - });
282 } 263 }
283 }, 264 },
284 }, 265 },
......
...@@ -29,8 +29,8 @@ ...@@ -29,8 +29,8 @@
29 </el-button> 29 </el-button>
30 </div> 30 </div>
31 <Tables ductName="user" :data="data" :headerData="tableHeader" :limitSize="formData.size" :totalCount="total" 31 <Tables ductName="user" :data="data" :headerData="tableHeader" :limitSize="formData.size" :totalCount="total"
32 - :loading="loading" :page="formData.page" :pageSizes="[20, 30, 40, 50]" height="600" @sizeChange="sizeChange" 32 + :loading="loading" :page="formData.page" :pageSizes="[20, 30, 40, 50]" :height="tableHeight"
33 - @currentChange="currentChange"> 33 + @sizeChange="sizeChange" @currentChange="currentChange">
34 <template slot="optionColumn"> 34 <template slot="optionColumn">
35 <el-table-column header-align="center" align="center" width="auto" label="操作"> 35 <el-table-column header-align="center" align="center" width="auto" label="操作">
36 <template slot-scope="scope"> 36 <template slot-scope="scope">
...@@ -87,7 +87,6 @@ ...@@ -87,7 +87,6 @@
87 87
88 <script> 88 <script>
89 import Drawer from "./drawer.vue"; 89 import Drawer from "./drawer.vue";
90 -import { MessageBox } from "element-ui";
91 import { listUser, detailUser, updateUserStatus } from "@/api/system/user.js"; 90 import { listUser, detailUser, updateUserStatus } from "@/api/system/user.js";
92 export default { 91 export default {
93 name: "UserConfig", 92 name: "UserConfig",
...@@ -103,56 +102,7 @@ export default { ...@@ -103,56 +102,7 @@ export default {
103 username: null, 102 username: null,
104 phone: null, 103 phone: null,
105 }, //查询条件 104 }, //查询条件
106 - tableHeader: [ 105 + tableHeader: this.tableHeaders['user'], //表头数据
107 - {
108 - name: "员工号",
109 - value: "loginName",
110 - width: "150px",
111 - align: "center",
112 - },
113 - {
114 - name: "用户姓名",
115 - value: "username",
116 - width: "150px",
117 - align: "center",
118 - },
119 - {
120 - name: "所属口岸",
121 - value: "portName",
122 - width: "150px",
123 - align: "center",
124 - },
125 - {
126 - name: "所属角色",
127 - value: "roleNames",
128 - width: "150px",
129 - align: "center",
130 - },
131 - {
132 - name: "电子邮箱",
133 - value: "email",
134 - width: "150px",
135 - align: "center",
136 - },
137 - {
138 - name: "用户状态",
139 - value: "isValid",
140 - width: "100px",
141 - align: "center",
142 - },
143 - {
144 - name: "修改时间",
145 - value: "updateTime",
146 - width: "150px",
147 - align: "center",
148 - },
149 - {
150 - name: "备注",
151 - value: "remark",
152 - width: "150px",
153 - align: "center",
154 - },
155 - ], //表头数据
156 userData: {}, //用户详情 106 userData: {}, //用户详情
157 data: [], //用户列表 107 data: [], //用户列表
158 drawer: false, 108 drawer: false,
...@@ -161,6 +111,7 @@ export default { ...@@ -161,6 +111,7 @@ export default {
161 drawerTitle: "", 111 drawerTitle: "",
162 total: 0, 112 total: 0,
163 loading: false, 113 loading: false,
114 + tableHeight: null
164 }; 115 };
165 }, 116 },
166 created() { 117 created() {
...@@ -168,6 +119,9 @@ export default { ...@@ -168,6 +119,9 @@ export default {
168 this.selectUser(); 119 this.selectUser();
169 } 120 }
170 }, 121 },
122 + mounted() {
123 + this.tableHeight = window.innerHeight - this.$refs.selectionUserForm.$el.offsetHeight - 250
124 + },
171 activated() { 125 activated() {
172 this.selectUser(); 126 this.selectUser();
173 }, 127 },
...@@ -189,10 +143,7 @@ export default { ...@@ -189,10 +143,7 @@ export default {
189 this.total = res.data.total; 143 this.total = res.data.total;
190 this.formData.page = res.data.page; 144 this.formData.page = res.data.page;
191 } else { 145 } else {
192 - this.$message({ 146 + this.msgWarning(res.msg)
193 - message: res.msg,
194 - type: "warning",
195 - });
196 } 147 }
197 }) 148 })
198 .catch((err) => { 149 .catch((err) => {
...@@ -200,7 +151,6 @@ export default { ...@@ -200,7 +151,6 @@ export default {
200 console.log(err); 151 console.log(err);
201 }); 152 });
202 }, 153 },
203 -
204 //用户详情 154 //用户详情
205 userDetail(id) { 155 userDetail(id) {
206 detailUser(id) 156 detailUser(id)
...@@ -213,17 +163,13 @@ export default { ...@@ -213,17 +163,13 @@ export default {
213 ? this.userData.portName = this.userData.portName.split(",") 163 ? this.userData.portName = this.userData.portName.split(",")
214 : ''; 164 : '';
215 } else { 165 } else {
216 - this.$message({ 166 + this.msgWarning(res.msg)
217 - message: res.msg,
218 - type: "warning",
219 - });
220 } 167 }
221 }) 168 })
222 .catch((err) => { 169 .catch((err) => {
223 console.log(err); 170 console.log(err);
224 }); 171 });
225 }, 172 },
226 -
227 //新增用户 173 //新增用户
228 addUser() { 174 addUser() {
229 this.userData = {}; 175 this.userData = {};
...@@ -231,7 +177,6 @@ export default { ...@@ -231,7 +177,6 @@ export default {
231 this.drawerTitle = "新增用户"; 177 this.drawerTitle = "新增用户";
232 this.userFormDisabled = false; 178 this.userFormDisabled = false;
233 }, 179 },
234 -
235 //查询修改用户 180 //查询修改用户
236 buttonClick(row, status) { 181 buttonClick(row, status) {
237 this.userDetail(row.row.id); 182 this.userDetail(row.row.id);
...@@ -239,7 +184,6 @@ export default { ...@@ -239,7 +184,6 @@ export default {
239 ? (this.userFormDisabled = true) 184 ? (this.userFormDisabled = true)
240 : (this.userFormDisabled = false); 185 : (this.userFormDisabled = false);
241 }, 186 },
242 -
243 //修改用户状态 187 //修改用户状态
244 userStatus(row) { 188 userStatus(row) {
245 let msg = ""; 189 let msg = "";
...@@ -247,7 +191,7 @@ export default { ...@@ -247,7 +191,7 @@ export default {
247 row.row.isValid == 1 191 row.row.isValid == 1
248 ? ((msg = "是否要停用此用户"), (nowValid = 2)) 192 ? ((msg = "是否要停用此用户"), (nowValid = 2))
249 : ((msg = "是否要启用此用户"), (nowValid = 1)); 193 : ((msg = "是否要启用此用户"), (nowValid = 1));
250 - MessageBox.confirm(msg, "提示", { 194 + this.$confirm(msg, "提示", {
251 confirmButtonText: "确定", 195 confirmButtonText: "确定",
252 cancelButtonText: "取消", 196 cancelButtonText: "取消",
253 type: "warning", 197 type: "warning",
...@@ -256,16 +200,10 @@ export default { ...@@ -256,16 +200,10 @@ export default {
256 updateUserStatus({ id: row.row.id, isValid: nowValid }).then( 200 updateUserStatus({ id: row.row.id, isValid: nowValid }).then(
257 (res) => { 201 (res) => {
258 if (res.code === 200) { 202 if (res.code === 200) {
259 - this.$message({ 203 + this.msgSuccess('操作成功')
260 - message: "操作成功",
261 - type: "success",
262 - });
263 this.selectUser(); 204 this.selectUser();
264 } else { 205 } else {
265 - this.$message({ 206 + this.msgWarning(res.msg)
266 - message: res.msg,
267 - type: "warning",
268 - });
269 } 207 }
270 } 208 }
271 ); 209 );
...@@ -273,12 +211,11 @@ export default { ...@@ -273,12 +211,11 @@ export default {
273 .catch((err) => { 211 .catch((err) => {
274 console.log(err); 212 console.log(err);
275 }) 213 })
276 - .catch(() => []); 214 + .catch(() => { });
277 }, 215 },
278 -
279 //删除用户 216 //删除用户
280 removeUser(row) { 217 removeUser(row) {
281 - MessageBox.confirm("是否要删除此用户", "提示", { 218 + this.$confirm("是否要删除此用户", "提示", {
282 confirmButtonText: "确定删除", 219 confirmButtonText: "确定删除",
283 cancelButtonText: "取消", 220 cancelButtonText: "取消",
284 type: "warning", 221 type: "warning",
...@@ -286,36 +223,27 @@ export default { ...@@ -286,36 +223,27 @@ export default {
286 .then(() => { 223 .then(() => {
287 updateUserStatus({ id: row.row.id, isValid: 0 }).then((res) => { 224 updateUserStatus({ id: row.row.id, isValid: 0 }).then((res) => {
288 if (res.code === 200) { 225 if (res.code === 200) {
289 - this.$message({ 226 + this.msgSuccess('操作成功')
290 - message: "操作成功",
291 - type: "success",
292 - });
293 this.selectUser(); 227 this.selectUser();
294 } else { 228 } else {
295 - this.$message({ 229 + this.msgWarning(res.msg)
296 - message: res.msg,
297 - type: "warning",
298 - });
299 } 230 }
300 }); 231 });
301 }) 232 })
302 .catch((err) => { 233 .catch((err) => {
303 console.log(err); 234 console.log(err);
304 }) 235 })
305 - .catch(() => []); 236 + .catch(() => { });
306 }, 237 },
307 -
308 handleClose(val) { 238 handleClose(val) {
309 this.drawer = val; 239 this.drawer = val;
310 this.userData = {}; 240 this.userData = {};
311 this.selectUser(); 241 this.selectUser();
312 }, 242 },
313 -
314 currentChange(val) { 243 currentChange(val) {
315 this.formData.page = val.page; 244 this.formData.page = val.page;
316 this.selectUser(); 245 this.selectUser();
317 }, 246 },
318 -
319 sizeChange(val) { 247 sizeChange(val) {
320 this.formData.size = val; 248 this.formData.size = val;
321 this.selectUser() 249 this.selectUser()
......