jinhui.wang

ver:1.9.0;新增特殊规则配舱,航班迁转,白名单异步导入,操作日志,样式修正,bug修复

Showing 40 changed files with 2748 additions and 243 deletions
...@@ -60,7 +60,7 @@ export function downloadExcel(data) { ...@@ -60,7 +60,7 @@ export function downloadExcel(data) {
60 }) 60 })
61 } 61 }
62 62
63 -//释放 63 +//释放
64 export function releaseCargo(data) { 64 export function releaseCargo(data) {
65 return request({ 65 return request({
66 url: '/cargo/releaseCargo', 66 url: '/cargo/releaseCargo',
...@@ -106,3 +106,29 @@ export function getFlightsRoutes(data) { ...@@ -106,3 +106,29 @@ export function getFlightsRoutes(data) {
106 data: data 106 data: data
107 }) 107 })
108 } 108 }
109 +
110 +//航班迁转
111 +/**
112 + * @param ids * 货物id list
113 + * @param flightId * 航班id
114 + * @param route * 航线
115 + */
116 +export function batchMoveCargoToOtherFlight(data) {
117 + return request({
118 + url: '/cargo/batchMoveCargoToOtherFlight',
119 + method: 'post',
120 + data: data
121 + })
122 +}
123 +
124 +//生成历史数据文件
125 +/**
126 + * @param 同货物查询
127 + */
128 +export function historyCargo(data) {
129 + return request({
130 + url: '/cargo/historyCargo',
131 + method: 'post',
132 + data: data
133 + })
134 +}
...\ No newline at end of file ...\ No newline at end of file
......
...@@ -72,3 +72,17 @@ export function updateAutoPushBatch(data) { ...@@ -72,3 +72,17 @@ export function updateAutoPushBatch(data) {
72 data: data 72 data: data
73 }) 73 })
74 } 74 }
75 +
76 +//白名单自动配舱开关
77 +/**
78 + * @param updateIds idList *
79 + * @param status 状态 * 1开 0关
80 + */
81 +export function updateWhiteListSwitchBatch(data) {
82 + return request({
83 + url: '/FlightPreserveController/updateWhiteListSwitchBatch',
84 + method: 'post',
85 + data: data
86 + })
87 +}
88 +
......
...@@ -60,3 +60,28 @@ export function findStationName() { ...@@ -60,3 +60,28 @@ export function findStationName() {
60 method: 'post', 60 method: 'post',
61 }) 61 })
62 } 62 }
63 +
64 +//批量导入
65 +export function uploadGoodsExcel(file, goodsStation) {
66 + let formData = new FormData();
67 + formData.append("file", file);
68 + formData.append("goodsStation", goodsStation);
69 + return request({
70 + url: '/goods/uploadGoodsExcel',
71 + method: 'post',
72 + data: formData
73 + })
74 +}
75 +
76 +//查询上传日志
77 +/**
78 + * @param page 页长 *
79 + * @param size 页数 *
80 + */
81 +export function userImportLog(data) {
82 + return request({
83 + url: '/goods/userImportLog',
84 + method: 'post',
85 + data: data
86 + })
87 +}
...\ No newline at end of file ...\ No newline at end of file
......
1 +import request from '@/utils/request'
2 +import axios from 'axios';
3 +import settings from "@/settings"
4 +import { getToken } from '@/utils/auth'
5 +
6 +//模板下载
7 +export function downLoadTemplate(template) {
8 + return request({
9 + url: '/flightInfoImport/downLoadTemplate?template=' + template,
10 + method: 'get',
11 + responseType: 'blob',
12 + })
13 +}
14 +
15 +//航班目的地批量导入
16 +/**
17 + * @param file * 文件
18 + * @param beginDate * 时间
19 + */
20 +export function importFlightDestination(file, date) {
21 + let formData = new FormData();
22 + formData.append("file", file);
23 + formData.append("beginDate", date);
24 + return axios({
25 + method: 'post',
26 + url: settings.baseURL + '/flightDestination/importFlightDestination',
27 + headers: { 'Authorization': 'Bearer ' + getToken() },
28 + data: formData
29 + })
30 + // return request({
31 + // url: '/flightDestination/importFlightDestination',
32 + // method: 'post',
33 + // data: formData
34 + // })
35 +}
36 +
37 +//URSA目的地批量导入
38 +/**
39 + * @param file * 文件
40 + * @param beginDate * 时间
41 + */
42 +export function importUrsaDestination(file, date) {
43 + let formData = new FormData();
44 + formData.append("file", file);
45 + formData.append("beginDate", date);
46 + return axios({
47 + method: 'post',
48 + url: settings.baseURL + '/ursaDestination/importUrsaDestination',
49 + headers: { 'Authorization': 'Bearer ' + getToken() },
50 + data: formData
51 + })
52 + // return request({
53 + // url: '/ursaDestination/importUrsaDestination',
54 + // method: 'post',
55 + // data: formData
56 + // })
57 +}
58 +
59 +//航班目的地查询
60 +/**
61 + * @param page * 页数
62 + * @param size * 长度
63 + * @param area 地区
64 + * @param fltNo 航班号
65 + */
66 +export function searchFlightDestination(data) {
67 + return request({
68 + url: '/flightDestination/searchFlightDestination',
69 + method: 'post',
70 + data: data
71 + })
72 +}
73 +
74 +//URSA目的地查询
75 +/**
76 + * @param page * 页数
77 + * @param size * 长度
78 + * @param area 地区
79 + * @param ursa ursa list
80 + */
81 +export function searchUrsaDestination(data) {
82 + return request({
83 + url: '/ursaDestination/searchUrsaDestination',
84 + method: 'post',
85 + data: data
86 + })
87 +}
88 +
89 +//preMde查询
90 +/**
91 + * @param flightNo 航班号
92 + * @param fltDateStart 航班开始时间
93 + * @param fltDateEnd 航班结束时间
94 + * @param flightRoute 航线
95 + * @param waybillNo 运单号
96 + * @param ursa ursa
97 + * @param typeName 申报类别
98 + * @param siteName 站点
99 + * @param regionArray 区域 list
100 + * @param areaArray 地区 list
101 + * @param serviceTypeArray 服务代码 list
102 + * @param page * 页数
103 + * @param size * 长度
104 + */
105 +export function findDmPreMdeData(data) {
106 + return request({
107 + url: '/dmPreMde/findDmPreMdeData',
108 + method: 'post',
109 + data: data
110 + })
111 +}
112 +
113 +//preMde页面查询条件
114 +/**
115 + */
116 +export function findDmPreMdeCondition(data) {
117 + return request({
118 + url: '/dmPreMde/findDmPreMdeCondition',
119 + method: 'post',
120 + data: data
121 + })
122 +}
123 +
124 +//报表查询
125 +/**
126 + * @param ursas ursaslist
127 + * @param serviceTypeArray serviceTypelist
128 + * @param regionArray 区域
129 + * @param areaArray 地区
130 + * @param pickUpDate 取件日期
131 + * @param dimensionName 维度名
132 + */
133 +export function findPreMdeReport(data) {
134 + return request({
135 + url: '/preMdeReport/findPreMdeReport',
136 + method: 'post',
137 + data: data
138 + })
139 +}
...\ No newline at end of file ...\ No newline at end of file
1 +import request from '@/utils/request'
2 +
3 +//特殊规则查询
4 +/**
5 + * @param page * 页数
6 + * @param size * 页长
7 + * @param shipperAccount shipperAccount集合
8 + */
9 +export function queryShipperAccountRule(data) {
10 + return request({
11 + url: 'shipperAccount/queryShipperAccountRule',
12 + method: 'post',
13 + data: data
14 + })
15 +}
16 +
17 +//特殊规则新增
18 +/**
19 + * @param id ID (修改必填)
20 + * @param shipperAccount * shipperAccount
21 + * @param flightNo * 航班号
22 + * @param flightRoute * 航线
23 + * @param flightDate * 航班日期
24 + * @param groupAllWeight 预配重量
25 + * @param includeUrsa * ursa包含
26 + * @param notIncludeUrsa ursa不包含
27 + * @param classificationList 申报类型
28 + * @param serviceCodeList servceCode
29 + */
30 +export function saveOrUpdate(data) {
31 + return request({
32 + url: 'shipperAccount/saveOrUpdate',
33 + method: 'post',
34 + data: data
35 + })
36 +}
37 +
38 +//特殊规则详情
39 +/**
40 + * @param id * ID
41 + */
42 +export function queryShipperAccountRuleById(data) {
43 + return request({
44 + url: 'shipperAccount/queryShipperAccountRuleById',
45 + method: 'post',
46 + data: data
47 + })
48 +}
49 +
50 +//特殊规则删除
51 +/**
52 + * @param accsFlightNo * 航班号
53 + * @param shipperAccount * shipperAccount
54 + * @param status * 状态 0 停用 1启用 2 已删除
55 + */
56 +export function changeStatusById(data) {
57 + return request({
58 + url: '/shipperAccount/changeStatusById',
59 + method: 'post',
60 + data: data
61 + })
62 +}
63 +
64 +//特殊规则获取释放仓位重量
65 +/**
66 + * @param id ID *
67 + */
68 +export function getReleaseWeight(data) {
69 + return request({
70 + url: '/shipperAccount/getReleaseWeight',
71 + method: 'post',
72 + data: data
73 + })
74 +}
...\ No newline at end of file ...\ No newline at end of file
...@@ -39,3 +39,45 @@ export function findCargoDataChangeLog(data) { ...@@ -39,3 +39,45 @@ export function findCargoDataChangeLog(data) {
39 method: 'post', 39 method: 'post',
40 }) 40 })
41 } 41 }
42 +
43 +// 功能模块查询
44 +/**
45 + *
46 + */
47 +export function findModuleCondition() {
48 + return request({
49 + url: '/systemOperationLog/findModuleCondition',
50 + method: 'post',
51 + })
52 +}
53 +
54 +//操作日志查询
55 +/**
56 + * @param module 功能模块
57 + * @param createTimeStart 操作时间开始
58 + * @param createTimeEnd 操作时间结束
59 + * @param page 页数
60 + * @param size 页长
61 + */
62 +export function getSystemOperationLogData(data) {
63 + return request({
64 + url: '/systemOperationLog/getSystemOperationLogData',
65 + method: 'post',
66 + data: data
67 + })
68 +}
69 +
70 +//归档数据查询
71 +/**
72 + * @param createTimeStart 操作时间开始
73 + * @param createTimeEnd 操作时间结束
74 + * @param page 页数
75 + * @param size 页长
76 + */
77 +export function findArchiveCargoLog(data) {
78 + return request({
79 + url: '/archiveCargoLog/findArchiveCargoLog',
80 + method: 'post',
81 + data: data
82 + })
83 +}
...\ No newline at end of file ...\ No newline at end of file
......
...@@ -63,11 +63,11 @@ let ductLabels = { ...@@ -63,11 +63,11 @@ let ductLabels = {
63 "1": "是", 63 "1": "是",
64 "2": "否", 64 "2": "否",
65 }, 65 },
66 - // "whiteListSwitch": { 66 + "whiteListSwitch": {
67 - // "1": "开启", 67 + "1": "开启",
68 - // "0": "关闭", 68 + "0": "关闭",
69 - // null: '关闭' 69 + null: '关闭'
70 - // } 70 + }
71 }, 71 },
72 "flightRand": {//航班顺位设置 72 "flightRand": {//航班顺位设置
73 "status": { 73 "status": {
......
...@@ -131,7 +131,7 @@ let tableHeaders = { ...@@ -131,7 +131,7 @@ let tableHeaders = {
131 status: 1 131 status: 1
132 }, 132 },
133 { 133 {
134 - columnChineseName: "申报类", 134 + columnChineseName: "申报类",
135 columnName: "typeName", 135 columnName: "typeName",
136 columnWidth: "100", 136 columnWidth: "100",
137 ext1: "sorTable", 137 ext1: "sorTable",
...@@ -521,6 +521,12 @@ let tableHeaders = { ...@@ -521,6 +521,12 @@ let tableHeaders = {
521 status: 1 521 status: 1
522 }, 522 },
523 { 523 {
524 + columnChineseName: "白名单是否自动配舱",
525 + columnName: "whiteListSwitch",
526 + columnWidth: "160",
527 + status: 1
528 + },
529 + {
524 columnChineseName: "总重量", 530 columnChineseName: "总重量",
525 columnName: "totalWeight", 531 columnName: "totalWeight",
526 columnWidth: "90", 532 columnWidth: "90",
...@@ -539,6 +545,18 @@ let tableHeaders = { ...@@ -539,6 +545,18 @@ let tableHeaders = {
539 status: 1 545 status: 1
540 }, 546 },
541 { 547 {
548 + columnChineseName: "预留特殊舱位重量",
549 + columnName: "accountTotalWeight",
550 + columnWidth: "130",
551 + status: 1
552 + },
553 + {
554 + columnChineseName: "特殊舱位已配重量",
555 + columnName: "accountAllocatedWeight",
556 + columnWidth: "130",
557 + status: 1
558 + },
559 + {
542 columnChineseName: "已配体积(m³)", 560 columnChineseName: "已配体积(m³)",
543 columnName: "alloctedVolume", 561 columnName: "alloctedVolume",
544 columnWidth: "120", 562 columnWidth: "120",
...@@ -704,13 +722,20 @@ let tableHeaders = { ...@@ -704,13 +722,20 @@ let tableHeaders = {
704 status: 1 722 status: 1
705 }, 723 },
706 { 724 {
707 - columnChineseName: "申报类", 725 + columnChineseName: "申报类",
708 columnName: "typeName", 726 columnName: "typeName",
709 columnWidth: "100", 727 columnWidth: "100",
710 ext1: "sorTable", 728 ext1: "sorTable",
711 status: 1 729 status: 1
712 }, 730 },
713 { 731 {
732 + columnChineseName: "ACCSpool",
733 + columnName: "accsPool",
734 + columnWidth: "120",
735 + ext1: "sorTable",
736 + status: 1
737 + },
738 + {
714 columnChineseName: "HandlingCode", 739 columnChineseName: "HandlingCode",
715 columnName: "handingCode", 740 columnName: "handingCode",
716 columnWidth: "150", 741 columnWidth: "150",
...@@ -739,6 +764,13 @@ let tableHeaders = { ...@@ -739,6 +764,13 @@ let tableHeaders = {
739 status: 1 764 status: 1
740 }, 765 },
741 { 766 {
767 + columnChineseName: "体积",
768 + columnName: "volume",
769 + columnWidth: "100",
770 + ext1: "sorTable",
771 + status: 1
772 + },
773 + {
742 columnChineseName: "收件人国家代码", 774 columnChineseName: "收件人国家代码",
743 columnName: "consigneeCountry", 775 columnName: "consigneeCountry",
744 columnWidth: "150", 776 columnWidth: "150",
...@@ -793,6 +825,13 @@ let tableHeaders = { ...@@ -793,6 +825,13 @@ let tableHeaders = {
793 status: 1 825 status: 1
794 }, 826 },
795 { 827 {
828 + columnChineseName: "终配航线",
829 + columnName: "finalFlightRoute",
830 + columnWidth: "140",
831 + ext1: "sorTable",
832 + status: 1
833 + },
834 + {
796 columnChineseName: "二配航班号", 835 columnChineseName: "二配航班号",
797 columnName: "twoMatchFlightNo", 836 columnName: "twoMatchFlightNo",
798 columnWidth: "120", 837 columnWidth: "120",
...@@ -807,6 +846,13 @@ let tableHeaders = { ...@@ -807,6 +846,13 @@ let tableHeaders = {
807 status: 1 846 status: 1
808 }, 847 },
809 { 848 {
849 + columnChineseName: "二配航线",
850 + columnName: "twoFlightRoute",
851 + columnWidth: "140",
852 + ext1: "sorTable",
853 + status: 1
854 + },
855 + {
810 columnChineseName: "预配航班号", 856 columnChineseName: "预配航班号",
811 columnName: "preplanFlightNo", 857 columnName: "preplanFlightNo",
812 columnWidth: "120", 858 columnWidth: "120",
...@@ -1220,7 +1266,8 @@ let tableHeaders = { ...@@ -1220,7 +1266,8 @@ let tableHeaders = {
1220 columnName: "remarksDetail", 1266 columnName: "remarksDetail",
1221 columnWidth: "450", 1267 columnWidth: "450",
1222 align: 'left', 1268 align: 'left',
1223 - status: 1 1269 + status: 1,
1270 + ext1: 'slot',
1224 }, 1271 },
1225 { 1272 {
1226 columnChineseName: "处理状态级别", 1273 columnChineseName: "处理状态级别",
...@@ -1493,91 +1540,726 @@ let tableHeaders = { ...@@ -1493,91 +1540,726 @@ let tableHeaders = {
1493 //特殊配舱规则 1540 //特殊配舱规则
1494 "superAllocation": [ 1541 "superAllocation": [
1495 { 1542 {
1496 - columnChineseName: "ShipperAccount", 1543 + columnChineseName: "发件人账号",
1497 columnName: "shipperAccount", 1544 columnName: "shipperAccount",
1498 columnWidth: "", 1545 columnWidth: "",
1499 ext1: "", 1546 ext1: "",
1500 status: 1 1547 status: 1
1501 }, 1548 },
1502 { 1549 {
1503 - columnChineseName: "原航班", 1550 + columnChineseName: "航班日期",
1504 - columnName: "accsFlightNo", 1551 + columnName: "flightDate",
1552 + columnWidth: "",
1553 + ext1: "",
1554 + status: 1
1555 + },
1556 + {
1557 + columnChineseName: "航班号",
1558 + columnName: "flightNo",
1559 + columnWidth: "",
1560 + ext1: "",
1561 + status: 1
1562 + },
1563 + {
1564 + columnChineseName: "航线",
1565 + columnName: "flightRoute",
1566 + columnWidth: "",
1567 + ext1: "",
1568 + status: 1
1569 + },
1570 + {
1571 + columnChineseName: "URSA",
1572 + columnName: "includeUrsa",
1573 + columnWidth: "",
1574 + ext1: "",
1575 + status: 1
1576 + },
1577 + {
1578 + columnChineseName: "申报类型",
1579 + columnName: "classification",
1580 + columnWidth: "",
1581 + ext1: "",
1582 + status: 1
1583 + },
1584 + {
1585 + columnChineseName: "服务类型",
1586 + columnName: "serviceCode",
1587 + columnWidth: "",
1588 + ext1: "",
1589 + status: 1
1590 + },
1591 + {
1592 + columnChineseName: "预留舱位",
1593 + columnName: "groupAllWeight",
1594 + columnWidth: "",
1595 + ext1: "",
1596 + status: 1
1597 + },
1598 + {
1599 + columnChineseName: "已配舱位",
1600 + columnName: "accountAllocatedWeight",
1601 + columnWidth: "",
1602 + ext1: "",
1603 + status: 1
1604 + },
1605 + ],
1606 + //航班目的地
1607 + "flightToArea": [
1608 + {
1609 + columnChineseName: "生效开始时间",
1610 + columnName: "beginDate",
1611 + columnWidth: "",
1612 + ext1: "",
1613 + status: 1
1614 + },
1615 + {
1616 + columnChineseName: "生效结束时间",
1617 + columnName: "endDate",
1618 + columnWidth: "",
1619 + ext1: "",
1620 + status: 1
1621 + },
1622 + {
1623 + columnChineseName: "区域",
1624 + columnName: "region",
1625 + columnWidth: "",
1626 + ext1: "",
1627 + status: 1
1628 + },
1629 + {
1630 + columnChineseName: "地区",
1631 + columnName: "area",
1632 + columnWidth: "",
1633 + ext1: "",
1634 + status: 1
1635 + },
1636 + {
1637 + columnChineseName: "航班",
1638 + columnName: "fltNo",
1639 + columnWidth: "",
1640 + ext1: "",
1641 + status: 1
1642 + },
1643 + {
1644 + columnChineseName: "航线",
1645 + columnName: "route",
1646 + columnWidth: "",
1647 + ext1: "",
1648 + status: 1
1649 + },
1650 + {
1651 + columnChineseName: "操作人",
1652 + columnName: "createUserName",
1653 + columnWidth: "",
1654 + ext1: "",
1655 + status: 1
1656 + },
1657 + {
1658 + columnChineseName: "操作时间",
1659 + columnName: "createTime",
1660 + columnWidth: "",
1661 + ext1: "",
1662 + status: 1
1663 + },
1664 + ],
1665 + //ursa目的地
1666 + "ursaToArea": [
1667 + {
1668 + columnChineseName: "生效开始时间",
1669 + columnName: "beginDate",
1670 + columnWidth: "150",
1671 + ext1: "",
1672 + status: 1
1673 + },
1674 + {
1675 + columnChineseName: "生效结束时间",
1676 + columnName: "endDate",
1505 columnWidth: "150", 1677 columnWidth: "150",
1506 ext1: "", 1678 ext1: "",
1507 status: 1 1679 status: 1
1508 }, 1680 },
1509 { 1681 {
1682 + columnChineseName: "区域",
1683 + columnName: "region",
1684 + columnWidth: "120",
1685 + ext1: "",
1686 + status: 1
1687 + },
1688 + {
1689 + columnChineseName: "地区",
1690 + columnName: "area",
1691 + columnWidth: "120",
1692 + ext1: "",
1693 + status: 1
1694 + },
1695 + {
1696 + columnChineseName: "URSA",
1697 + columnName: "ursa",
1698 + columnWidth: "",
1699 + ext1: "",
1700 + status: 1
1701 + },
1702 + {
1510 columnChineseName: "操作人", 1703 columnChineseName: "操作人",
1511 - columnName: "updateUserName", 1704 + columnName: "createUserName",
1512 columnWidth: "100", 1705 columnWidth: "100",
1513 ext1: "", 1706 ext1: "",
1514 status: 1 1707 status: 1
1515 }, 1708 },
1516 { 1709 {
1517 columnChineseName: "操作时间", 1710 columnChineseName: "操作时间",
1518 - columnName: "updateTime", 1711 + columnName: "createTime",
1519 columnWidth: "200", 1712 columnWidth: "200",
1520 ext1: "", 1713 ext1: "",
1521 status: 1 1714 status: 1
1522 }, 1715 },
1523 ], 1716 ],
1524 - "newSuperAllocation": [ 1717 + //preMde查询
1718 + "preMdeSelect": [
1525 { 1719 {
1526 - columnChineseName: "航班日期", 1720 + columnChineseName: "地区",
1527 - columnName: "", 1721 + columnName: "area",
1528 columnWidth: "", 1722 columnWidth: "",
1529 ext1: "", 1723 ext1: "",
1530 status: 1 1724 status: 1
1531 }, 1725 },
1532 { 1726 {
1533 - columnChineseName: "航班号", 1727 + columnChineseName: "区域",
1534 - columnName: "", 1728 + columnName: "region",
1535 columnWidth: "", 1729 columnWidth: "",
1536 ext1: "", 1730 ext1: "",
1537 status: 1 1731 status: 1
1538 }, 1732 },
1539 { 1733 {
1540 - columnChineseName: "航线", 1734 + columnChineseName: "口岸代码",
1541 - columnName: "", 1735 + columnName: "portName",
1736 + columnWidth: "",
1737 + ext1: "",
1738 + status: 1
1739 + },
1740 + {
1741 + columnChineseName: "取件日期",
1742 + columnName: "pickUpDate",
1743 + columnWidth: "100",
1744 + ext1: "",
1745 + status: 1
1746 + },
1747 + {
1748 + columnChineseName: "取件扫描号",
1749 + columnName: "pickUpScanNo",
1750 + columnWidth: "100",
1751 + ext1: "",
1752 + status: 1
1753 + },
1754 + {
1755 + columnChineseName: "站点",
1756 + columnName: "siteName",
1757 + columnWidth: "",
1758 + ext1: "",
1759 + status: 1
1760 + },
1761 + {
1762 + columnChineseName: "运单号",
1763 + columnName: "waybillNo",
1764 + columnWidth: "120",
1765 + ext1: "",
1766 + status: 1
1767 + },
1768 + {
1769 + columnChineseName: "总单号",
1770 + columnName: "totalWaybillNo",
1771 + columnWidth: "120",
1772 + ext1: "",
1773 + status: 1
1774 + },
1775 + {
1776 + columnChineseName: "服务类型",
1777 + columnName: "serviceType",
1778 + columnWidth: "",
1779 + ext1: "",
1780 + status: 1
1781 + },
1782 + {
1783 + columnChineseName: "服务代码",
1784 + columnName: "serviceCode",
1542 columnWidth: "", 1785 columnWidth: "",
1543 ext1: "", 1786 ext1: "",
1544 status: 1 1787 status: 1
1545 }, 1788 },
1546 { 1789 {
1547 columnChineseName: "URSA", 1790 columnChineseName: "URSA",
1548 - columnName: "", 1791 + columnName: "ursa",
1549 columnWidth: "", 1792 columnWidth: "",
1550 ext1: "", 1793 ext1: "",
1551 status: 1 1794 status: 1
1552 }, 1795 },
1553 { 1796 {
1554 columnChineseName: "申报类型", 1797 columnChineseName: "申报类型",
1555 - columnName: "", 1798 + columnName: "typeName",
1556 columnWidth: "", 1799 columnWidth: "",
1557 ext1: "", 1800 ext1: "",
1558 status: 1 1801 status: 1
1559 }, 1802 },
1560 { 1803 {
1561 - columnChineseName: "服务类型", 1804 + columnChineseName: "HangdingCode",
1562 - columnName: "", 1805 + columnName: "handingCode",
1806 + columnWidth: "120",
1807 + ext1: "",
1808 + status: 1
1809 + },
1810 + {
1811 + columnChineseName: "subcategory",
1812 + columnName: "subCategory",
1813 + columnWidth: "120",
1814 + ext1: "",
1815 + status: 1
1816 + },
1817 + {
1818 + columnChineseName: "件数",
1819 + columnName: "qty",
1563 columnWidth: "", 1820 columnWidth: "",
1564 ext1: "", 1821 ext1: "",
1565 status: 1 1822 status: 1
1566 }, 1823 },
1567 { 1824 {
1568 - columnChineseName: "预留仓位", 1825 + columnChineseName: "实际重量",
1569 - columnName: "", 1826 + columnName: "actualWeight",
1570 columnWidth: "", 1827 columnWidth: "",
1571 ext1: "", 1828 ext1: "",
1572 status: 1 1829 status: 1
1573 }, 1830 },
1574 { 1831 {
1575 - columnChineseName: "已配仓位", 1832 + columnChineseName: "体积",
1576 - columnName: "", 1833 + columnName: "volume",
1577 columnWidth: "", 1834 columnWidth: "",
1578 ext1: "", 1835 ext1: "",
1579 status: 1 1836 status: 1
1580 }, 1837 },
1838 + {
1839 + columnChineseName: "收件人国家代码",
1840 + columnName: "consigneeCountry",
1841 + columnWidth: "130",
1842 + ext1: "",
1843 + status: 1
1844 + },
1845 + {
1846 + columnChineseName: "品名描述",
1847 + columnName: "nameDescription",
1848 + columnWidth: "",
1849 + ext1: "",
1850 + status: 1
1851 + },
1852 + {
1853 + columnChineseName: "ACCS原航班号",
1854 + columnName: "flightNo",
1855 + columnWidth: "120",
1856 + ext1: "",
1857 + status: 1
1858 + },
1859 + {
1860 + columnChineseName: "ACCS原航班日期",
1861 + columnName: "flightDate",
1862 + columnWidth: "130",
1863 + ext1: "",
1864 + status: 1
1865 + },
1866 + {
1867 + columnChineseName: "ACCS原航线",
1868 + columnName: "flightRoute",
1869 + columnWidth: "120",
1870 + ext1: "",
1871 + status: 1
1872 + },
1873 + {
1874 + columnChineseName: "手否RDE手工录入",
1875 + columnName: "manualRde",
1876 + columnWidth: "130",
1877 + ext1: "",
1878 + status: 1
1879 + },
1880 + {
1881 + columnChineseName: "发件人帐号",
1882 + columnName: "shipperAccount",
1883 + columnWidth: "120",
1884 + ext1: "",
1885 + status: 1
1886 + },
1887 + {
1888 + columnChineseName: "发件公司中文名称",
1889 + columnName: "shipperCompany",
1890 + columnWidth: "130",
1891 + ext1: "",
1892 + status: 1
1893 + },
1894 + {
1895 + columnChineseName: "始发地城市名称",
1896 + columnName: "originCity",
1897 + columnWidth: "130",
1898 + ext1: "",
1899 + status: 1
1900 + },
1901 + {
1902 + columnChineseName: "创建时间",
1903 + columnName: "createTime",
1904 + columnWidth: "",
1905 + ext1: "",
1906 + status: 1
1907 + },
1908 + ],
1909 + "report": [
1910 + {
1911 + columnChineseName: "地区",
1912 + columnName: "area",
1913 + columnWidth: "",
1914 + ext1: "",
1915 + status: 1
1916 + },
1917 + {
1918 + columnChineseName: "区域",
1919 + columnName: "region",
1920 + columnWidth: "",
1921 + ext1: "",
1922 + status: 1
1923 + },
1924 + {
1925 + columnChineseName: "口岸代码",
1926 + columnName: "portName",
1927 + columnWidth: "",
1928 + ext1: "",
1929 + status: 1
1930 + },
1931 + {
1932 + columnChineseName: "取件日期",
1933 + columnName: "pickUpDate",
1934 + columnWidth: "100",
1935 + ext1: "",
1936 + status: 1
1937 + },
1938 + {
1939 + columnChineseName: "取件扫描号",
1940 + columnName: "pickUpScanNo",
1941 + columnWidth: "100",
1942 + ext1: "",
1943 + status: 1
1944 + },
1945 + {
1946 + columnChineseName: "站点",
1947 + columnName: "siteName",
1948 + columnWidth: "",
1949 + ext1: "",
1950 + status: 1
1951 + },
1952 + {
1953 + columnChineseName: "运单号",
1954 + columnName: "waybillNo",
1955 + columnWidth: "120",
1956 + ext1: "",
1957 + status: 1
1958 + },
1959 + {
1960 + columnChineseName: "总单号",
1961 + columnName: "totalWaybillNo",
1962 + columnWidth: "120",
1963 + ext1: "",
1964 + status: 1
1965 + },
1966 + {
1967 + columnChineseName: "服务类型",
1968 + columnName: "serviceType",
1969 + columnWidth: "",
1970 + ext1: "",
1971 + status: 1
1972 + },
1973 + {
1974 + columnChineseName: "服务代码",
1975 + columnName: "serviceCode",
1976 + columnWidth: "",
1977 + ext1: "",
1978 + status: 1
1979 + },
1980 + {
1981 + columnChineseName: "URSA",
1982 + columnName: "ursa",
1983 + columnWidth: "",
1984 + ext1: "",
1985 + status: 1
1986 + },
1987 + {
1988 + columnChineseName: "申报类型",
1989 + columnName: "typeName",
1990 + columnWidth: "",
1991 + ext1: "",
1992 + status: 1
1993 + },
1994 + {
1995 + columnChineseName: "HangdingCode",
1996 + columnName: "handingCode",
1997 + columnWidth: "120",
1998 + ext1: "",
1999 + status: 1
2000 + },
2001 + {
2002 + columnChineseName: "subcategory",
2003 + columnName: "subCategory",
2004 + columnWidth: "120",
2005 + ext1: "",
2006 + status: 1
2007 + },
2008 + {
2009 + columnChineseName: "件数",
2010 + columnName: "qty",
2011 + columnWidth: "",
2012 + ext1: "",
2013 + status: 1
2014 + },
2015 + {
2016 + columnChineseName: "实际重量",
2017 + columnName: "actualWeight",
2018 + columnWidth: "",
2019 + ext1: "",
2020 + status: 1
2021 + },
2022 + {
2023 + columnChineseName: "体积",
2024 + columnName: "volume",
2025 + columnWidth: "",
2026 + ext1: "",
2027 + status: 1
2028 + },
2029 + {
2030 + columnChineseName: "收件人国家代码",
2031 + columnName: "consigneeCountry",
2032 + columnWidth: "130",
2033 + ext1: "",
2034 + status: 1
2035 + },
2036 + {
2037 + columnChineseName: "品名描述",
2038 + columnName: "nameDescription",
2039 + columnWidth: "",
2040 + ext1: "",
2041 + status: 1
2042 + },
2043 + {
2044 + columnChineseName: "ACCS原航班号",
2045 + columnName: "flightNo",
2046 + columnWidth: "120",
2047 + ext1: "",
2048 + status: 1
2049 + },
2050 + {
2051 + columnChineseName: "ACCS原航班日期",
2052 + columnName: "flightDate",
2053 + columnWidth: "130",
2054 + ext1: "",
2055 + status: 1
2056 + },
2057 + {
2058 + columnChineseName: "ACCS原航线",
2059 + columnName: "flightRoute",
2060 + columnWidth: "120",
2061 + ext1: "",
2062 + status: 1
2063 + },
2064 + {
2065 + columnChineseName: "手否RDE手工录入",
2066 + columnName: "manualRde",
2067 + columnWidth: "130",
2068 + ext1: "",
2069 + status: 1
2070 + },
2071 + {
2072 + columnChineseName: "发件人帐号",
2073 + columnName: "shipperAccount",
2074 + columnWidth: "120",
2075 + ext1: "",
2076 + status: 1
2077 + },
2078 + {
2079 + columnChineseName: "发件公司中文名称",
2080 + columnName: "shipperCompany",
2081 + columnWidth: "130",
2082 + ext1: "",
2083 + status: 1
2084 + },
2085 + {
2086 + columnChineseName: "始发地城市名称",
2087 + columnName: "originCity",
2088 + columnWidth: "130",
2089 + ext1: "",
2090 + status: 1
2091 + },
2092 + {
2093 + columnChineseName: "创建时间",
2094 + columnName: "createTime",
2095 + columnWidth: "",
2096 + ext1: "",
2097 + status: 1
2098 + },
2099 + ],
2100 + 'goodsLogStation': [
2101 + {
2102 + columnChineseName: "上传文件名",
2103 + columnName: "uploadFileName",
2104 + columnWidth: "",
2105 + ext1: "",
2106 + status: 1
2107 + },
2108 + {
2109 + columnChineseName: "货站名称",
2110 + columnName: "ext",
2111 + columnWidth: "",
2112 + ext1: "",
2113 + status: 1
2114 + },
2115 + {
2116 + columnChineseName: "上传时间",
2117 + columnName: "uploadTime",
2118 + columnWidth: "",
2119 + ext1: "",
2120 + status: 1
2121 + },
2122 + {
2123 + columnChineseName: "执行时间",
2124 + columnName: "executionTime",
2125 + columnWidth: "",
2126 + ext1: "",
2127 + status: 1
2128 + },
2129 + {
2130 + columnChineseName: "完成时间",
2131 + columnName: "completeTime",
2132 + columnWidth: "",
2133 + ext1: "",
2134 + status: 1
2135 + },
2136 + {
2137 + columnChineseName: "执行数量",
2138 + columnName: "executionCount",
2139 + columnWidth: "",
2140 + ext1: "",
2141 + status: 1
2142 + },
2143 + {
2144 + columnChineseName: "执行结果",
2145 + columnName: "executionResult",
2146 + columnWidth: "",
2147 + ext1: "",
2148 + status: 1
2149 + },
2150 + {
2151 + columnChineseName: "执行步骤",
2152 + columnName: "status",
2153 + columnWidth: "",
2154 + ext1: "",
2155 + status: 1
2156 + },
2157 + ],
2158 + //操作日志
2159 + "operationLog": [
2160 + {
2161 + columnChineseName: "功能模块",
2162 + columnName: "module",
2163 + columnWidth: "120",
2164 + ext1: "",
2165 + status: 1
2166 + },
2167 + {
2168 + columnChineseName: "操作时间",
2169 + columnName: "createTime",
2170 + columnWidth: "150",
2171 + ext1: "",
2172 + status: 1
2173 + },
2174 + {
2175 + columnChineseName: "操作人",
2176 + columnName: "userName",
2177 + columnWidth: "120",
2178 + ext1: "",
2179 + status: 1
2180 + },
2181 + {
2182 + columnChineseName: "操作描述",
2183 + columnName: "describe",
2184 + columnWidth: "",
2185 + ext1: "",
2186 + status: 1
2187 + },
2188 + {
2189 + columnChineseName: "操作结果",
2190 + columnName: "result",
2191 + columnWidth: "",
2192 + ext1: "slot",
2193 + status: 1
2194 + },
2195 +
2196 + {
2197 + columnChineseName: "备注",
2198 + columnName: "remark",
2199 + columnWidth: "100",
2200 + ext1: "slot",
2201 + status: 1
2202 + },
2203 + {
2204 + columnChineseName: "操作参数",
2205 + columnName: "requestParameters",
2206 + columnWidth: "100",
2207 + ext1: "slot",
2208 + status: 1
2209 + },
2210 +
2211 + ],
2212 + //历史数据文件查询
2213 + "archiveData": [
2214 + {
2215 + columnChineseName: "文件名",
2216 + columnName: "packageName",
2217 + columnWidth: "",
2218 + ext1: "",
2219 + status: 1
2220 + },
2221 + {
2222 + columnChineseName: "创建时间",
2223 + columnName: "createTime",
2224 + columnWidth: "",
2225 + ext1: "",
2226 + status: 1
2227 + },
2228 + {
2229 + columnChineseName: "创建人",
2230 + columnName: "userName",
2231 + columnWidth: "",
2232 + ext1: "",
2233 + status: 1
2234 + },
2235 + {
2236 + columnChineseName: "处理状态",
2237 + columnName: "status",
2238 + columnWidth: "",
2239 + ext1: "",
2240 + status: 1
2241 + },
2242 + {
2243 + columnChineseName: "处理时间",
2244 + columnName: "updateTime",
2245 + columnWidth: "",
2246 + ext1: "",
2247 + status: 1
2248 + },
2249 + {
2250 + columnChineseName: "查询条件",
2251 + columnName: "queryParameter",
2252 + columnWidth: "",
2253 + ext1: "slot",
2254 + status: 1
2255 + },
2256 + {
2257 + columnChineseName: "下载地址",
2258 + columnName: "downloadPath",
2259 + columnWidth: "",
2260 + ext1: "slot",
2261 + status: 1
2262 + },
1581 ] 2263 ]
1582 } 2264 }
1583 2265
......
...@@ -68,6 +68,15 @@ Vue.component('HeaderSetting', HeaderSetting) ...@@ -68,6 +68,15 @@ Vue.component('HeaderSetting', HeaderSetting)
68 Vue.component('Drag', Drag) 68 Vue.component('Drag', Drag)
69 69
70 Vue.use(permission) 70 Vue.use(permission)
71 +
72 +Vue.directive('focus', {
73 + inserted: function (el) {
74 + // el表示指令所绑定的元素
75 + el.querySelector('input').focus()
76 + }
77 +});
78 +
79 +
71 /** 80 /**
72 * If you don't want to use mock-server 81 * If you don't want to use mock-server
73 * you want to use MockJs for mock api 82 * you want to use MockJs for mock api
......
...@@ -62,16 +62,15 @@ export const constantRoutes = [ ...@@ -62,16 +62,15 @@ export const constantRoutes = [
62 { 62 {
63 path: 'index', 63 path: 'index',
64 component: (resolve) => require(['@/views/index'], resolve), 64 component: (resolve) => require(['@/views/index'], resolve),
65 - name: '首页', 65 + name: 'Index',
66 meta: { title: '首页', icon: 'home', noCache: true, affix: true } 66 meta: { title: '首页', icon: 'home', noCache: true, affix: true }
67 - } 67 + },
68 ] 68 ]
69 }, 69 },
70 { 70 {
71 - path: '/', 71 + path: '',
72 component: Layout, 72 component: Layout,
73 hidden: true, 73 hidden: true,
74 - redirect: 'noredirect',
75 children: [ 74 children: [
76 { 75 {
77 path: '/info/:handle/:id|:routeStatus|:fltNo|:route|:fltDate|:status', 76 path: '/info/:handle/:id|:routeStatus|:fltNo|:route|:fltDate|:status',
...@@ -89,15 +88,21 @@ export const constantRoutes = [ ...@@ -89,15 +88,21 @@ export const constantRoutes = [
89 path: '/upDateResult->:from', 88 path: '/upDateResult->:from',
90 component: (resolve) => require(['@/views/preMdeConfig/upDateResult'], resolve), 89 component: (resolve) => require(['@/views/preMdeConfig/upDateResult'], resolve),
91 name: 'UpDateResult', 90 name: 'UpDateResult',
92 - meta: { title: '导入信息', icon: 'user' } 91 + meta: { title: '错误信息提示', icon: 'user' }
92 + },
93 + {
94 + path: '/goodsLog',
95 + component: (resolve) => require(['@/views/basicInformation/goodsStation/goodsUploadLog'], resolve),
96 + name: 'GoodsUploadLog',
97 + meta: { title: '导入日志', icon: 'user' }
93 }, 98 },
94 ] 99 ]
95 - } 100 + },
96 ] 101 ]
97 102
98 export default new Router({ 103 export default new Router({
99 mode: 'history', // 去掉url中的# 104 mode: 'history', // 去掉url中的#
100 scrollBehavior: () => ({ y: 0 }), 105 scrollBehavior: () => ({ y: 0 }),
101 routes: constantRoutes, 106 routes: constantRoutes,
102 - base: settings.routerBase 107 + base: settings.routerBase,
103 }) 108 })
......
...@@ -58,5 +58,5 @@ module.exports = { ...@@ -58,5 +58,5 @@ module.exports = {
58 /** 58 /**
59 * 版本号 59 * 版本号
60 */ 60 */
61 - version: 'version:1.7.0' 61 + version: 'version:1.9.0'
62 } 62 }
......
...@@ -81,3 +81,9 @@ export function isArray(arg) { ...@@ -81,3 +81,9 @@ export function isArray(arg) {
81 } 81 }
82 return Array.isArray(arg) 82 return Array.isArray(arg)
83 } 83 }
84 +
85 +// 验证手机号码
86 +export function validPhoneNumber(value) {
87 + const reg = /^(13[0-9]|14[579]|15[0-3,5-9]|16[6]|17[0135678]|18[0-9]|19[89])\d{8}$/;
88 + return reg.test(value)
89 +}
...\ No newline at end of file ...\ No newline at end of file
......
...@@ -8,15 +8,16 @@ const mimeMap = { ...@@ -8,15 +8,16 @@ const mimeMap = {
8 } 8 }
9 const baseUrl = settings.downLoadURL //uat服务器 9 const baseUrl = settings.downLoadURL //uat服务器
10 10
11 -export function downLoadZip(str, filename) { 11 +export function downLoadZip(str, data, filename) {
12 var url = baseUrl + str 12 var url = baseUrl + str
13 axios({ 13 axios({
14 - method: 'get', 14 + method: 'post',
15 url: url, 15 url: url,
16 + data: data,
16 responseType: 'blob', 17 responseType: 'blob',
17 headers: { 'Authorization': decodeURIComponent(getToken()) } 18 headers: { 'Authorization': decodeURIComponent(getToken()) }
18 }).then(res => { 19 }).then(res => {
19 - resolveBlob(res, mimeMap.zip) 20 + resolveBlob(res, mimeMap.zip, filename)
20 }) 21 })
21 } 22 }
22 23
...@@ -52,7 +53,6 @@ export function downLoadXlsx(str, data, fileName) { ...@@ -52,7 +53,6 @@ export function downLoadXlsx(str, data, fileName) {
52 timeout: 500000, 53 timeout: 500000,
53 responseType: 'blob', 54 responseType: 'blob',
54 headers: { 'Authorization': decodeURIComponent(getToken()) } 55 headers: { 'Authorization': decodeURIComponent(getToken()) }
55 - // headers: { 'Authorization': decodeURIComponent(getToken()) }
56 //uat环境token需要做url解码处理 56 //uat环境token需要做url解码处理
57 }).then(res => { 57 }).then(res => {
58 if (res.status === 200) { 58 if (res.status === 200) {
...@@ -107,3 +107,4 @@ export function cargoTableXlsxPre(val) { ...@@ -107,3 +107,4 @@ export function cargoTableXlsxPre(val) {
107 aLink.click() 107 aLink.click()
108 document.body.removeChild(aLink); 108 document.body.removeChild(aLink);
109 } 109 }
110 +
......
...@@ -142,10 +142,10 @@ ...@@ -142,10 +142,10 @@
142 </el-col> 142 </el-col>
143 <el-col :span="24"> 143 <el-col :span="24">
144 <el-form-item label="Handling Code"> 144 <el-form-item label="Handling Code">
145 - <el-empty description="暂无数据" v-if=" 145 + <!-- <el-empty description="暂无数据" v-if="
146 !selectData.HandlingCode || selectData.HandlingCode.length == 0 146 !selectData.HandlingCode || selectData.HandlingCode.length == 0
147 - "></el-empty> 147 + "></el-empty> -->
148 - <el-checkbox-group v-model="handingCodes" v-else> 148 + <el-checkbox-group v-model="handingCodes">
149 <el-row> 149 <el-row>
150 <el-col :span="2" v-for="item in selectData.HandlingCode" :key="item.id"> 150 <el-col :span="2" v-for="item in selectData.HandlingCode" :key="item.id">
151 <el-checkbox :label="item.chineseName" v-model="item.chineseName"> 151 <el-checkbox :label="item.chineseName" v-model="item.chineseName">
...@@ -158,10 +158,10 @@ ...@@ -158,10 +158,10 @@
158 </el-col> 158 </el-col>
159 <el-col :span="24"> 159 <el-col :span="24">
160 <el-form-item label="Sub Category"> 160 <el-form-item label="Sub Category">
161 - <el-empty description="暂无数据" v-if=" 161 + <!-- <el-empty description="暂无数据" v-if="
162 !selectData.SubCategory || selectData.SubCategory.length == 0 162 !selectData.SubCategory || selectData.SubCategory.length == 0
163 - "></el-empty> 163 + "></el-empty> -->
164 - <el-checkbox-group v-model="subCategorys" v-else> 164 + <el-checkbox-group v-model="subCategorys">
165 <el-row> 165 <el-row>
166 <el-col :span="2" v-for="item in selectData.SubCategory" :key="item.id"> 166 <el-col :span="2" v-for="item in selectData.SubCategory" :key="item.id">
167 <el-checkbox :label="item.chineseName" v-model="item.chineseName"> 167 <el-checkbox :label="item.chineseName" v-model="item.chineseName">
...@@ -175,14 +175,14 @@ ...@@ -175,14 +175,14 @@
175 </el-row> 175 </el-row>
176 <div style="margin: 0 0 0 10px"> 176 <div style="margin: 0 0 0 10px">
177 <el-button type="primary" icon="el-icon-search" size="mini" :loading="loading" @click="select(0)">查询</el-button> 177 <el-button type="primary" icon="el-icon-search" size="mini" :loading="loading" @click="select(0)">查询</el-button>
178 - <el-button :type="downLoadingTip.downloading ? 'warning' : 'primary'" size="mini" 178 + <el-button :type="downLoadingTip.downloading ? 'warning' : 'primary'" size="mini" icon="el-icon-download"
179 - v-hasPermi="['allocation:cargo:export']" icon="el-icon-download" @click="xlsx(0)" 179 + v-hasPermi="['allocation:cargo:export']" @click="xlsx(0)" :loading="downLoadingTip.downloading"
180 - :loading="downLoadingTip.downloading" :disabled="tableData.length <= 0">{{ 180 + :disabled="tableData.length <= 0">{{
181 downLoadingTip.downloading ? downLoadingTip.tip : "导出本页查询结果" 181 downLoadingTip.downloading ? downLoadingTip.tip : "导出本页查询结果"
182 }}</el-button> 182 }}</el-button>
183 - <el-button :type="downLoadingTip.downloading ? 'warning' : 'primary'" size="mini" 183 + <el-button :type="downLoadingTip.downloading ? 'warning' : 'primary'" size="mini" icon="el-icon-download"
184 - v-hasPermi="['allocation:cargo:export']" icon="el-icon-download" @click="xlsx(1)" 184 + v-hasPermi="['allocation:cargo:export']" @click="xlsx(1)" :loading="downLoadingTip.downloading"
185 - :loading="downLoadingTip.downloading" :disabled="tableData.length <= 0">{{ 185 + :disabled="tableData.length <= 0">{{
186 downLoadingTip.downloading ? downLoadingTip.tip : "导出全部查询结果" 186 downLoadingTip.downloading ? downLoadingTip.tip : "导出全部查询结果"
187 }}</el-button> 187 }}</el-button>
188 <el-button type="primary" size="mini" icon="el-icon-plus" v-hasPermi="['allocation:cargo:allocation']" 188 <el-button type="primary" size="mini" icon="el-icon-plus" v-hasPermi="['allocation:cargo:allocation']"
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
8 <el-table-column type="index" label="序号" align="center"> 8 <el-table-column type="index" label="序号" align="center">
9 </el-table-column> 9 </el-table-column>
10 <el-table-column v-for="(item, index) in cargoHeader" header-align="center" align="center" :prop="item.value" 10 <el-table-column v-for="(item, index) in cargoHeader" header-align="center" align="center" :prop="item.value"
11 - :label="item.name" :key="index" :show-overflow-tooltip="true" :formatter="formatter"> 11 + :label="item.name" :key="index" :width="item.width" :show-overflow-tooltip="true" :formatter="formatter">
12 </el-table-column> 12 </el-table-column>
13 </el-table> 13 </el-table>
14 <el-form ref="form" class="form-header" label-position="right" label-width="auto" 14 <el-form ref="form" class="form-header" label-position="right" label-width="auto"
...@@ -65,24 +65,25 @@ export default { ...@@ -65,24 +65,25 @@ export default {
65 ids: [], 65 ids: [],
66 fltNo: undefined, 66 fltNo: undefined,
67 fltDate: undefined, 67 fltDate: undefined,
68 - route: undefined, 68 + route: null,
69 overweight: false, 69 overweight: false,
70 + notInWhite: false,
70 }, 71 },
71 cargoHeader: [ 72 cargoHeader: [
72 - { name: "口岸代码", value: "portName" }, 73 + { name: "口岸代码", value: "portName", width: "" },
73 - { name: "运单号", value: "waybillNo" }, 74 + { name: "运单号", value: "waybillNo", width: "" },
74 - { name: "货物状态", value: "statusName" }, 75 + { name: "货物状态", value: "statusName", width: "" },
75 - { name: "站点", value: "siteName" }, 76 + { name: "站点", value: "siteName", width: "" },
76 - { name: "申报类型", value: "typeName" }, 77 + { name: "申报类型", value: "typeName", width: "" },
77 - { name: "URSA", value: "ursa" }, 78 + { name: "URSA", value: "ursa", width: "" },
78 - { name: "实际重量", value: "actualWeight" }, 79 + { name: "实际重量", value: "actualWeight", width: "" },
79 - { name: "件数", value: "qty" }, 80 + { name: "件数", value: "qty", width: "" },
80 - { name: "ACCS原航班号", value: "fltNoAccs" }, 81 + { name: "ACCS原航班号", value: "fltNoAccs", width: "120" },
81 - { name: "ACCS原航班日期", value: "fltDateAccs" }, 82 + { name: "ACCS原航班日期", value: "fltDateAccs", width: "130" },
82 - { name: "品名描述", value: "nameDescription" }, 83 + { name: "品名描述", value: "nameDescription", width: "" },
83 - { name: "是否自动", value: "cargoRulesStatus" }, 84 + { name: "是否自动", value: "cargoRulesStatus", width: "" },
84 - { name: "创建人", value: "createUserName" }, 85 + { name: "创建人", value: "createUserName", width: "" },
85 - { name: "创建时间", value: "createTime" }, 86 + { name: "创建时间", value: "createTime", width: "" },
86 ], 87 ],
87 routeList: [], 88 routeList: [],
88 rules: { 89 rules: {
...@@ -120,11 +121,16 @@ export default { ...@@ -120,11 +121,16 @@ export default {
120 route: undefined, 121 route: undefined,
121 flightId: undefined, 122 flightId: undefined,
122 overweight: false, 123 overweight: false,
124 + notInWhite: false,
123 }; 125 };
124 this.routeList = [] 126 this.routeList = []
125 }, 127 },
126 //确定配舱 128 //确定配舱
127 submit() { 129 submit() {
130 + this.formData.overweight = false
131 + this.formData.notInWhite = false
132 + this.$refs.form.validate(val => {
133 + if (val) {
128 this.loading = true; 134 this.loading = true;
129 let arr = []; 135 let arr = [];
130 this.tableData.forEach((item) => { 136 this.tableData.forEach((item) => {
...@@ -138,50 +144,66 @@ export default { ...@@ -138,50 +144,66 @@ export default {
138 }) 144 })
139 if (this.formData.fltNo && this.formData.fltDate) { 145 if (this.formData.fltNo && this.formData.fltDate) {
140 allocationFlight(this.formData).then((res) => { 146 allocationFlight(this.formData).then((res) => {
141 - this.loading = false; 147 + //code 200 配舱成功 202重量已满需要确认 203货物不在白名单需要确认 其余code直接输出msg 接口先判断重量后判断白名单 overweight/notInWhite初始默认false
142 - //code 200 配舱成功 202 重量已满需要确认 其余code直接输出msg
143 if (res.code === 200) { 148 if (res.code === 200) {
149 + this.loading = false;
144 this.msgSuccess('货物配舱成功') 150 this.msgSuccess('货物配舱成功')
145 this.cleaerForm(); 151 this.cleaerForm();
146 this.$emit("dialogBeforeClose", { close: false, reload: true }); 152 this.$emit("dialogBeforeClose", { close: false, reload: true });
147 } else if (res.code === 202) { 153 } else if (res.code === 202) {
148 - this.$confirm(res.msg, "提示", { 154 + //超重航班确实是否继续配舱
155 + this.reallocationFlight(res.msg, 'overweight')
156 + } else if (res.code === 203) {
157 + //不存在白名单中确实是否继续配舱
158 + this.reallocationFlight(res.msg, 'notInWhite')
159 + } else {
160 + this.loading = false;
161 + this.msgWarning(res.msg)
162 + }
163 + }).catch(() => {
164 + this.loading = false;
165 + });
166 + } else {
167 + this.loading = false;
168 + this.msgWarning('航班号或航班日期不能为空')
169 + }
170 + }
171 + })
172 + },
173 + //手动配舱超重或白名单不存在提示
174 + reallocationFlight(msg, status) {
175 + this.$confirm(msg, "提示", {
149 confirmButtonText: "确定", 176 confirmButtonText: "确定",
150 cancelButtonText: "取消", 177 cancelButtonText: "取消",
151 type: "warning", 178 type: "warning",
152 - }) 179 + }).then(() => {
153 - .then(() => { 180 + if (status == 'overweight') {
154 this.formData.overweight = true; //确定继续overweight变为true再次请求接口 181 this.formData.overweight = true; //确定继续overweight变为true再次请求接口
182 + } else {
183 + this.formData.notInWhite = true; //确定继续notInWhite变为true再次请求接口
184 + }
155 allocationFlight(this.formData).then((res) => { 185 allocationFlight(this.formData).then((res) => {
156 if (res.code === 200) { 186 if (res.code === 200) {
187 + this.loading = false
157 this.msgSuccess('货物配舱成功') 188 this.msgSuccess('货物配舱成功')
189 + this.cleaerForm();
190 + this.$emit("dialogBeforeClose", { close: false, reload: true });
191 + } else if (res.code === 203) {
192 + this.reallocationFlight(res.msg, 'notInWhite')
158 } else { 193 } else {
159 this.msgWarning(res.msg) 194 this.msgWarning(res.msg)
195 + this.loading = false
160 } 196 }
161 }); 197 });
162 - this.cleaerForm(); 198 + }).catch(() => {
163 - this.$emit("dialogBeforeClose", { close: false, reload: true });
164 - })
165 - .catch(() => {
166 - //取消 取消当前配舱
167 this.msgSuccess('配舱已取消') 199 this.msgSuccess('配舱已取消')
200 + this.loading = false
168 this.cleaerForm(); 201 this.cleaerForm();
169 this.$emit("dialogBeforeClose", { 202 this.$emit("dialogBeforeClose", {
170 close: false, 203 close: false,
171 reload: true, 204 reload: true,
172 }); 205 });
173 - }); 206 + })
174 - } else {
175 - this.loading = false;
176 - this.msgWarning(res.msg)
177 - }
178 - }).catch(() => {
179 - this.loading = false;
180 - });
181 - } else {
182 - this.loading = false;
183 - this.msgWarning('航班号或航班日期不能为空')
184 - }
185 }, 207 },
186 dialogBeforeClose() { 208 dialogBeforeClose() {
187 this.cleaerForm(); 209 this.cleaerForm();
...@@ -201,6 +223,7 @@ export default { ...@@ -201,6 +223,7 @@ export default {
201 //日期选择变化 223 //日期选择变化
202 dateChange(val) { 224 dateChange(val) {
203 this.routeList = [] 225 this.routeList = []
226 + this.formData.route = null
204 if (this.formData.fltNo && this.formData.fltNo != null && this.formData.fltNo != '') { 227 if (this.formData.fltNo && this.formData.fltNo != null && this.formData.fltNo != '') {
205 if (this.formData.fltDate && this.formData.fltDate != null && this.formData.fltDate != '') { 228 if (this.formData.fltDate && this.formData.fltDate != null && this.formData.fltDate != '') {
206 let obj = { 229 let obj = {
......
...@@ -47,6 +47,8 @@ export default { ...@@ -47,6 +47,8 @@ export default {
47 }, 47 },
48 watch: { 48 watch: {
49 open(val) { 49 open(val) {
50 + this.routeList = []
51 + this.submitData = []
50 if (val) { 52 if (val) {
51 this.fltNo = this.fltData.fltNo 53 this.fltNo = this.fltData.fltNo
52 this.fltDate = this.fltData.fltDate 54 this.fltDate = this.fltData.fltDate
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
11 <el-row class="mb20"> 11 <el-row class="mb20">
12 <el-col :span="6"> 12 <el-col :span="6">
13 <el-form-item label="航班号" prop="fltNo"> 13 <el-form-item label="航班号" prop="fltNo">
14 - <el-input v-model.tirm="infoForm.fltNo" @change="getRoutes" :disabled="fltNoDisabled"> 14 + <el-input v-model.trim="infoForm.fltNo" @change="getRoutes" :disabled="fltNoDisabled">
15 </el-input> 15 </el-input>
16 </el-form-item> 16 </el-form-item>
17 </el-col> 17 </el-col>
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
24 </el-col> 24 </el-col>
25 <el-col :span="6" v-if="infoForm.route != null && infoForm.route != ' ' && infoForm.route != ''"> 25 <el-col :span="6" v-if="infoForm.route != null && infoForm.route != ' ' && infoForm.route != ''">
26 <el-form-item label="航线"> 26 <el-form-item label="航线">
27 - <el-input v-model.tirm="infoForm.route" @change="getRoutes" disabled> 27 + <el-input v-model.trim="infoForm.route" @change="getRoutes" disabled>
28 </el-input> 28 </el-input>
29 </el-form-item> 29 </el-form-item>
30 </el-col> 30 </el-col>
...@@ -618,7 +618,7 @@ export default { ...@@ -618,7 +618,7 @@ export default {
618 this.isEmpty = true 618 this.isEmpty = true
619 } 619 }
620 } else { 620 } else {
621 - this.msgWarning("查询到数据!") 621 + this.msgWarning("查询到数据!")
622 this.isEmpty = true 622 this.isEmpty = true
623 } 623 }
624 }).catch(err => { 624 }).catch(err => {
...@@ -639,6 +639,9 @@ export default { ...@@ -639,6 +639,9 @@ export default {
639 if (this.$route.params.handle != 'add') { 639 if (this.$route.params.handle != 'add') {
640 findDestinationFltRuleByFlightNo(obj).then(res => { 640 findDestinationFltRuleByFlightNo(obj).then(res => {
641 if (res.code === 200) { 641 if (res.code === 200) {
642 + if (res.data.routeList.length <= 0) {
643 + this.msgWarning('未查询到航线信息!')
644 + } else {
642 this.routeList = res.data.routeList 645 this.routeList = res.data.routeList
643 if (res.data.list.length > 0) { 646 if (res.data.list.length > 0) {
644 //请求到数据 647 //请求到数据
...@@ -823,6 +826,7 @@ export default { ...@@ -823,6 +826,7 @@ export default {
823 } 826 }
824 } 827 }
825 } 828 }
829 + }
826 } else { 830 } else {
827 this.msgWarning(res.msg) 831 this.msgWarning(res.msg)
828 } 832 }
...@@ -851,6 +855,7 @@ export default { ...@@ -851,6 +855,7 @@ export default {
851 }) 855 })
852 }) 856 })
853 } else { 857 } else {
858 + this.msgWarning('未查询到航线信息!')
854 this.routeList = [] 859 this.routeList = []
855 this.infoForm.list = [] 860 this.infoForm.list = []
856 } 861 }
...@@ -1192,3 +1197,26 @@ export default { ...@@ -1192,3 +1197,26 @@ export default {
1192 } 1197 }
1193 } 1198 }
1194 </style> 1199 </style>
1200 +.fontWeight {
1201 + font-size: 16px;
1202 + font-weight: 700;
1203 + text-indent: 2em;
1204 +}
1205 +
1206 +.rowPadding {
1207 + padding: 10px 50px;
1208 + font-size: 12px;
1209 +}
1210 +
1211 +.routeTip {
1212 + margin-left: 35px;
1213 + margin-bottom: 20px;
1214 + font-size: 16px;
1215 + color: #ff4949;
1216 +}
1217 +
1218 +.numberInput {
1219 + input {
1220 + text-align: center;
1221 + }
1222 +}
......
...@@ -67,7 +67,8 @@ ...@@ -67,7 +67,8 @@
67 <el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="150"> 67 <el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="150">
68 <template slot-scope="scope"> 68 <template slot-scope="scope">
69 <el-button size="mini" type="text" icon="el-icon-edit" 69 <el-button size="mini" type="text" icon="el-icon-edit"
70 - @click="handleClick(scope.row.actualFlight, 'detail', scope.row.flightDate, ' ', ' ')">查看配置维度 70 + @click="handleClick(scope.row.actualFlight, 'detail', scope.row.flightDate, ' ', ' ')">
71 + 查看配置维度
71 </el-button> 72 </el-button>
72 </template> 73 </template>
73 </el-table-column> 74 </el-table-column>
...@@ -268,7 +269,7 @@ export default { ...@@ -268,7 +269,7 @@ export default {
268 }, 269 },
269 methods: { 270 methods: {
270 //跳转到查看,修改页面 271 //跳转到查看,修改页面
271 - handleClick(fltNo, handle, fltDate, route) { 272 + handleClick(fltNo, handle, fltDate, route, status) {
272 this.openFlightDate = false; 273 this.openFlightDate = false;
273 let obj = { 274 let obj = {
274 id: ' ', 275 id: ' ',
...@@ -277,8 +278,8 @@ export default { ...@@ -277,8 +278,8 @@ export default {
277 fltDate: fltDate != null ? fltDate : ' ', 278 fltDate: fltDate != null ? fltDate : ' ',
278 route: route, 279 route: route,
279 routeStatus: 'FlightRandConfig', 280 routeStatus: 'FlightRandConfig',
280 - status: ' ', 281 + status: status,
281 - createStatus: 1 282 + createStatus: 1,
282 } 283 }
283 this.$router.push({ 284 this.$router.push({
284 name: "FlightAllocConfigInfo", 285 name: "FlightAllocConfigInfo",
......
...@@ -72,7 +72,6 @@ export default { ...@@ -72,7 +72,6 @@ export default {
72 this.$message.error("下载失败"); 72 this.$message.error("下载失败");
73 } 73 }
74 }); 74 });
75 -
76 }, 75 },
77 uploadExcel(option) { 76 uploadExcel(option) {
78 //上传excel 77 //上传excel
......
...@@ -60,6 +60,12 @@ ...@@ -60,6 +60,12 @@
60 @click="autoPushBatch('open')" v-hasPermi="['base:flightInfo:autoPushOpen']">自动推送开启</el-button> 60 @click="autoPushBatch('open')" v-hasPermi="['base:flightInfo:autoPushOpen']">自动推送开启</el-button>
61 <el-button type="primary" icon="el-icon-circle-close" size="mini" :disabled="ids.length == 0" 61 <el-button type="primary" icon="el-icon-circle-close" size="mini" :disabled="ids.length == 0"
62 @click="autoPushBatch('close')" v-hasPermi="['base:flightInfo:autoPushClose']">自动推送关闭</el-button> 62 @click="autoPushBatch('close')" v-hasPermi="['base:flightInfo:autoPushClose']">自动推送关闭</el-button>
63 + <el-button type="primary" icon="el-icon-circle-check" size="mini" :disabled="ids.length == 0"
64 + @click="whiteListSwitchStatus(1)" v-hasPermi="['base:flightInfo:whiteOpen']">白名单自动配舱开启
65 + </el-button>
66 + <el-button type="primary" icon="el-icon-circle-close" size="mini" :disabled="ids.length == 0"
67 + @click="whiteListSwitchStatus(0)" v-hasPermi="['base:flightInfo:whiteClose']">白名单自动配舱关闭
68 + </el-button>
63 <el-button type="danger" icon="el-icon-delete" size="mini" :disabled="ids.length == 0" @click="handleDelete" 69 <el-button type="danger" icon="el-icon-delete" size="mini" :disabled="ids.length == 0" @click="handleDelete"
64 v-hasPermi="['base:flightInfo:delete']">删除 70 v-hasPermi="['base:flightInfo:delete']">删除
65 </el-button> 71 </el-button>
...@@ -195,20 +201,20 @@ ...@@ -195,20 +201,20 @@
195 <el-col :span="12"> 201 <el-col :span="12">
196 <el-form-item label="高价百分比" prop="highPriceWeightPercent"> 202 <el-form-item label="高价百分比" prop="highPriceWeightPercent">
197 <el-input-number class="wid80" :disabled="ishighPriceWeightPercent" @change="LowHighAvailable" 203 <el-input-number class="wid80" :disabled="ishighPriceWeightPercent" @change="LowHighAvailable"
198 - placeholder="请输入高价百分比" v-model="form.highPriceWeightPercent"></el-input-number> 204 + placeholder="开启高地价后可修改" v-model="form.highPriceWeightPercent"></el-input-number>
199 </el-form-item> 205 </el-form-item>
200 </el-col> 206 </el-col>
201 </el-row> 207 </el-row>
202 <el-row> 208 <el-row>
203 <el-col :span="12"> 209 <el-col :span="12">
204 <el-form-item label="低价百分比" prop="lowPriceWeightPercent"> 210 <el-form-item label="低价百分比" prop="lowPriceWeightPercent">
205 - <el-input-number class="wid80" :disabled="true" placeholder="请输入低价百分比" 211 + <el-input-number class="wid80" :disabled="true" placeholder="开启高地价后计算"
206 v-model="form.lowPriceWeightPercent"></el-input-number> 212 v-model="form.lowPriceWeightPercent"></el-input-number>
207 </el-form-item> 213 </el-form-item>
208 </el-col> 214 </el-col>
209 <el-col :span="12"> 215 <el-col :span="12">
210 <el-form-item label="高价可配重量" prop="highAvailableWeight"> 216 <el-form-item label="高价可配重量" prop="highAvailableWeight">
211 - <el-input-number class="wid80" :disabled="true" placeholder="请输入高价可配重量" v-model="form.highAvailableWeight" 217 + <el-input-number class="wid80" :disabled="true" placeholder="开启高地价后计算" v-model="form.highAvailableWeight"
212 :precision="2"></el-input-number> 218 :precision="2"></el-input-number>
213 </el-form-item> 219 </el-form-item>
214 </el-col> 220 </el-col>
...@@ -216,7 +222,7 @@ ...@@ -216,7 +222,7 @@
216 <el-row> 222 <el-row>
217 <el-col :span="12"> 223 <el-col :span="12">
218 <el-form-item label="低价可配重量" prop="lowAvailableWeight"> 224 <el-form-item label="低价可配重量" prop="lowAvailableWeight">
219 - <el-input-number class="wid80" :disabled="true" placeholder="请输入低价可配重量" v-model="form.lowAvailableWeight" 225 + <el-input-number class="wid80" :disabled="true" placeholder="开启高地价后计算" v-model="form.lowAvailableWeight"
220 :precision="2"></el-input-number> 226 :precision="2"></el-input-number>
221 </el-form-item> 227 </el-form-item>
222 </el-col> 228 </el-col>
...@@ -242,12 +248,12 @@ ...@@ -242,12 +248,12 @@
242 </el-col> 248 </el-col>
243 <el-col :span="12"> 249 <el-col :span="12">
244 <el-form-item label="特殊规则预留总重量" prop="accountTotalWeight"> 250 <el-form-item label="特殊规则预留总重量" prop="accountTotalWeight">
245 - <el-input class="wid80" v-model="form.accountTotalWeight" disabled /> 251 + <el-input class="wid80" v-model="form.accountTotalWeight" disabled placeholder="配置特殊规则后计算" />
246 </el-form-item> 252 </el-form-item>
247 </el-col> 253 </el-col>
248 <el-col :span="12"> 254 <el-col :span="12">
249 <el-form-item label="特殊规则已配重量" prop="accountAllocatedWeight"> 255 <el-form-item label="特殊规则已配重量" prop="accountAllocatedWeight">
250 - <el-input class="wid80" v-model="form.accountAllocatedWeight" disabled /> 256 + <el-input class="wid80" v-model="form.accountAllocatedWeight" disabled placeholder="配置特殊规则后计算" />
251 </el-form-item> 257 </el-form-item>
252 </el-col> 258 </el-col>
253 </el-row> 259 </el-row>
...@@ -278,6 +284,7 @@ import { ...@@ -278,6 +284,7 @@ import {
278 findFltCommonConf, 284 findFltCommonConf,
279 updateStatusBatch, 285 updateStatusBatch,
280 updateAutoPushBatch, 286 updateAutoPushBatch,
287 + updateWhiteListSwitchBatch
281 } from "@/api/findAllFltData"; 288 } from "@/api/findAllFltData";
282 import { getpreAudit } from '@/api/system/preReview.js' 289 import { getpreAudit } from '@/api/system/preReview.js'
283 import { queryRouteByFltNo } from '@/api/destinationFlight.js' 290 import { queryRouteByFltNo } from '@/api/destinationFlight.js'
...@@ -491,6 +498,8 @@ export default { ...@@ -491,6 +498,8 @@ export default {
491 //输入航班号后 498 //输入航班号后
492 blurfltNo() { 499 blurfltNo() {
493 this.routeList = [] 500 this.routeList = []
501 + this.form.accountTotalWeight = 0
502 + this.form.accountAllocatedWeight = 0
494 if ( 503 if (
495 this.form.fltNo != null && 504 this.form.fltNo != null &&
496 this.form.fltNo != undefined && 505 this.form.fltNo != undefined &&
...@@ -677,7 +686,7 @@ export default { ...@@ -677,7 +686,7 @@ export default {
677 this.$set( 686 this.$set(
678 this.form, 687 this.form,
679 "highAvailableWeight", 688 "highAvailableWeight",
680 - (Weight - this.form.alloctedWeight) * 689 + (Weight - this.form.accountTotalWeight - (this.form.alloctedWeight - this.form.accountAllocatedWeight)) *
681 (this.form.highPriceWeightPercent / 100) 690 (this.form.highPriceWeightPercent / 100)
682 ); 691 );
683 this.$set( 692 this.$set(
...@@ -713,7 +722,7 @@ export default { ...@@ -713,7 +722,7 @@ export default {
713 this.$set( 722 this.$set(
714 this.form, 723 this.form,
715 "lowAvailableWeight", 724 "lowAvailableWeight",
716 - Weight - this.form.alloctedWeight - this.form.highAvailableWeight 725 + (Weight - this.form.accountTotalWeight - (this.form.alloctedWeight - this.form.accountAllocatedWeight)) - this.form.highAvailableWeight
717 ); 726 );
718 //this.form.lowAvailableWeight = Weightall - this.form.HighAvailableWeight; 727 //this.form.lowAvailableWeight = Weightall - this.form.HighAvailableWeight;
719 } else if ( 728 } else if (
...@@ -793,7 +802,7 @@ export default { ...@@ -793,7 +802,7 @@ export default {
793 route: val.flightKindName != 'Purple Tail' ? val.route : ' ', 802 route: val.flightKindName != 'Purple Tail' ? val.route : ' ',
794 routeStatus: 'flightInformationMaintenance' + val.flightKindName, 803 routeStatus: 'flightInformationMaintenance' + val.flightKindName,
795 status: ' ', 804 status: ' ',
796 - createStatus: 1 805 + createStatus: 1,
797 } 806 }
798 this.$router.push({ 807 this.$router.push({
799 name: 'FlightAllocConfigInfo', 808 name: 'FlightAllocConfigInfo',
...@@ -891,6 +900,7 @@ export default { ...@@ -891,6 +900,7 @@ export default {
891 //取消按钮 900 //取消按钮
892 cancel() { 901 cancel() {
893 this.routeList = [] 902 this.routeList = []
903 + this.ishighPriceWeightPercent = true
894 this.routeMultiple = false 904 this.routeMultiple = false
895 this.open = false; 905 this.open = false;
896 this.findAllFltData(); 906 this.findAllFltData();
...@@ -974,6 +984,26 @@ export default { ...@@ -974,6 +984,26 @@ export default {
974 this.findAllFltData(); 984 this.findAllFltData();
975 } 985 }
976 }, 986 },
987 + //白名单配舱开关
988 + whiteListSwitchStatus(val) {
989 + let obj = {
990 + updateIds: []
991 + }
992 + obj.status = val
993 + this.ids.forEach(item => {
994 + obj.updateIds.push(item.id)
995 + })
996 + updateWhiteListSwitchBatch(obj).then(res => {
997 + if (res.code === 200) {
998 + this.msgSuccess(res.msg)
999 + this.findAllFltData()
1000 + } else {
1001 + this.msgWarning(res.msg)
1002 + }
1003 + }).catch(err => {
1004 + console.log(err)
1005 + })
1006 + },
977 //航线修改 1007 //航线修改
978 routeChange(val) { 1008 routeChange(val) {
979 this.$forceUpdate() 1009 this.$forceUpdate()
......
1 <template> 1 <template>
2 <div> 2 <div>
3 - <el-dialog :title="openStatus == 'add'?'新 增':'导出Excel'" :visible.sync="open" width="25%" 3 + <el-dialog :title="openStatus == 'add' ? '新 增' : openStatus == 'downloadExcel' ? '导出Excel' : '导入Excel'"
4 - :close-on-click-modal="false" :show-close="false" append-to-body center> 4 + :visible.sync="open" width="25%" :close-on-click-modal="false" :show-close="false" append-to-body center>
5 <el-form class="form-header" :model="formData" size="small" ref="addForm" label-width="auto" 5 <el-form class="form-header" :model="formData" size="small" ref="addForm" label-width="auto"
6 label-position="left" style="margin-bottom:10px" :rules="rules" @submit.native.prevent> 6 label-position="left" style="margin-bottom:10px" :rules="rules" @submit.native.prevent>
7 <div v-if="openStatus == 'add'"> 7 <div v-if="openStatus == 'add'">
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
15 </el-input> 15 </el-input>
16 </el-form-item> 16 </el-form-item>
17 </div> 17 </div>
18 - <div v-else> 18 + <div v-else-if="openStatus == 'downloadExcel'">
19 <el-form-item label="货站名称" prop="goodsStation"> 19 <el-form-item label="货站名称" prop="goodsStation">
20 <el-select class="selectWidth100" v-model.lazy="formData.goodsStation" filterable 20 <el-select class="selectWidth100" v-model.lazy="formData.goodsStation" filterable
21 :loading="goodsStationLoading" placeholder="不限"> 21 :loading="goodsStationLoading" placeholder="不限">
...@@ -25,18 +25,36 @@ ...@@ -25,18 +25,36 @@
25 </el-select> 25 </el-select>
26 </el-form-item> 26 </el-form-item>
27 </div> 27 </div>
28 + <div v-else>
29 + <el-form-item label="货站名称" prop="uploadGoodsStation">
30 + <el-input type="text" v-model="formData.uploadGoodsStation" maxlength="25"
31 + placeholder="请输入货站名称">
32 + </el-input>
33 + </el-form-item>
34 + <el-form-item prop="file" label-width="0px">
35 + <el-upload ref="upload" action="/goods/uploadGoodsExcel" name="file" :http-request="uploadExcel"
36 + :on-remove="handleRemove" :limit="1" :on-exceed="handleExceed" accept=".xlsx"
37 + class="upload-demo">
38 + <el-button type="primary" icon="el-icon-upload2" size="small">选择文件</el-button>
39 + </el-upload>
40 + </el-form-item>
41 + </div>
28 </el-form> 42 </el-form>
29 <div slot="footer" class="dialog-footer"> 43 <div slot="footer" class="dialog-footer">
30 - <el-button v-if='openStatus == "add"' type="primary" :loading="loading" @click="submit">确 定</el-button> 44 + <el-button v-if='openStatus == "add"' type="primary" size="small" :loading="loading" @click="submit">确 定
31 - <el-button v-else type="primary" :loading="downloading" @click="download">导出Excel</el-button> 45 + </el-button>
32 - <el-button @click="close">取 消</el-button> 46 + <el-button v-else-if="openStatus == 'downloadExcel'" type="primary" size="small" :loading="downloading"
47 + @click="download">导出Excel</el-button>
48 + <el-button v-else type="primary" :loading="loading" size="small" @click="upload">导入Excel
49 + </el-button>
50 + <el-button style="margin-top:10px" size="small" @click="close">取 消</el-button>
33 </div> 51 </div>
34 </el-dialog> 52 </el-dialog>
35 </div> 53 </div>
36 </template> 54 </template>
37 55
38 <script> 56 <script>
39 -import { batchAddGoods, findStationName } from "@/api/goodsStation" 57 +import { batchAddGoods, findStationName, uploadGoodsExcel } from "@/api/goodsStation"
40 import { downLoadXlsx } from "@/utils/zipdownload"; 58 import { downLoadXlsx } from "@/utils/zipdownload";
41 59
42 export default { 60 export default {
...@@ -55,7 +73,9 @@ export default { ...@@ -55,7 +73,9 @@ export default {
55 return { 73 return {
56 formData: { 74 formData: {
57 goodsStation: null, 75 goodsStation: null,
58 - goodsList: '' 76 + uploadGoodsStation: null,
77 + goodsList: '',
78 + file: null
59 }, 79 },
60 goodsStationList: [], 80 goodsStationList: [],
61 rules: { 81 rules: {
...@@ -73,7 +93,23 @@ export default { ...@@ -73,7 +93,23 @@ export default {
73 trigger: "blur", 93 trigger: "blur",
74 }, 94 },
75 ], 95 ],
96 + uploadGoodsStation: [
97 + {
98 + required: true,
99 + message: "货站名称不能为空",
100 + trigger: "change",
101 + },
102 + ],
103 + // file: [
104 + // {
105 + // required: true,
106 + // message: "文件不能为空",
107 + // trigger: "change",
108 + // },
109 + // ]
76 }, 110 },
111 + fileList: [],
112 + errorData: [],
77 goodsStationLoading: false, 113 goodsStationLoading: false,
78 downloading: false, 114 downloading: false,
79 loading: false, 115 loading: false,
...@@ -134,6 +170,51 @@ export default { ...@@ -134,6 +170,51 @@ export default {
134 } 170 }
135 }) 171 })
136 }, 172 },
173 + //选择文件
174 + uploadExcel(option) {
175 + this.formData.file = option.file
176 + },
177 + //导入Excel
178 + upload() {
179 + this.loading = true;
180 + if (this.formData.file != null && this.formData.file != '') {
181 + this.$refs['addForm'].validate(val => {
182 + if (val) {
183 + const file = this.formData.file;
184 + let goodsStation = this.formData.uploadGoodsStation
185 + uploadGoodsExcel(file, goodsStation).then((res) => {
186 + this.loading = false;
187 + if (res.code != 200) {
188 + if (res.code == 603) {
189 + this.$alert(res.msg, "提示", {
190 + confirmButtonText: "确定",
191 + type: "warning",
192 + });
193 + } else if (res.code === 201) {
194 + this.$message.warning(res.msg);
195 + if (res.data) {
196 + this.errorData = res.data;
197 + this.$router.push({ name: 'UpDateResult', params: { data: this.errorData, from: 'FlightInformationImport' } })
198 + }
199 + } else {
200 + this.$message.warning(res.msg);
201 + }
202 + } else {
203 + this.$message.success(res.msg);
204 + }
205 + setTimeout(() => {
206 + this.close()
207 + }, 1000);
208 + });
209 + } else {
210 + this.loading = false;
211 + }
212 + })
213 + } else {
214 + this.loading = false;
215 + this.msgWarning('请选择文件后再导入!')
216 + }
217 + },
137 //导出Excel 218 //导出Excel
138 download() { 219 download() {
139 this.$refs['addForm'].validate(val => { 220 this.$refs['addForm'].validate(val => {
...@@ -152,12 +233,31 @@ export default { ...@@ -152,12 +233,31 @@ export default {
152 }) 233 })
153 234
154 }, 235 },
236 + handleRemove(file, fileList) {
237 + //清掉上传的文件
238 + this.errorData = [];
239 + this.fileList = [];
240 + this.formData.file = null
241 + },
242 + handleExceed(files) {
243 + //重复上传文件
244 + let file = {};
245 + file.file = files[0];
246 + file.name = files[0].name;
247 + this.fileList = [];
248 + this.fileList.push(file);
249 + this.formData.file = file
250 + this.uploadExcel(file);
251 + },
155 //取消 252 //取消
156 close() { 253 close() {
157 this.formData = { 254 this.formData = {
158 goodsStation: null, 255 goodsStation: null,
159 goodsList: null 256 goodsList: null
160 } 257 }
258 + if (this.openStatus == 'uploadExcel') {
259 + this.$refs['upload'].clearFiles()
260 + }
161 this.$refs["addForm"].clearValidate(); 261 this.$refs["addForm"].clearValidate();
162 this.$emit('close') 262 this.$emit('close')
163 } 263 }
...@@ -168,5 +268,15 @@ export default { ...@@ -168,5 +268,15 @@ export default {
168 </script> 268 </script>
169 269
170 <style lang="scss" scoped> 270 <style lang="scss" scoped>
271 +.upload-demo {
171 272
273 + .el-upload-list__item:first-child {
274 + margin-top: 5px !important;
275 + }
276 +
277 + .el-upload-list {
278 + display: inline-block;
279 + margin-left: 10px;
280 + }
281 +}
172 </style> 282 </style>
...\ No newline at end of file ...\ No newline at end of file
......
1 +<template>
2 + <div style="padding:10px">
3 + <div style="margin-bottom:10px">
4 + <el-button type="primary" icon="el-icon-refresh" size="small" :loading="loading" @click="selectLog(1)">查 询
5 + </el-button>
6 + </div>
7 + <Tables ref="goodsLogStation" ductName="goodsLogStation" :data="logTabelData" :headerData="logTabelHeader"
8 + :selection="false" :order="true" :selectFixed="false" :loading="loading" :totalCount="logCount"
9 + :limitSize="logData.size" :page="logData.page" layout="total,prev, pager, next, jumper, ->"
10 + :pageSizes="[100]" :height="tableHeight" @currentChange="logCurrentChange">
11 + </Tables>
12 + </div>
13 +</template>
14 +
15 +<script>
16 +import { userImportLog } from "@/api/goodsStation"
17 +
18 +export default {
19 + name: 'GoodsUploadLog',
20 + data() {
21 + return {
22 + logData: {
23 + page: 1,
24 + size: 50
25 + },
26 + logTabelData: [],
27 + logTabelHeader: this.tableHeaders['goodsLogStation'],
28 + logCount: 0,
29 + tableHeight: null,
30 + loading: false,
31 + }
32 + },
33 + created() {
34 + this.selectLog()
35 + },
36 + watch: {
37 + $route(to, from) {
38 + if (to.name == 'GoodsUploadLog') {
39 + this.selectLog()
40 + }
41 + }
42 + },
43 + methods: {
44 + //日志查询
45 + selectLog(val) {
46 + if (val === 1) {
47 + this.logData.page = 1
48 + }
49 + this.loading = true
50 + userImportLog(this.logData).then(res => {
51 + this.loading = false
52 + if (res.code === 200) {
53 + this.logCount = res.data.total
54 + this.logTabelData = res.data.list
55 + } else {
56 + this.msgWarning(res.msg)
57 + }
58 + }).catch(err => {
59 + this.loading = false
60 + console.log(err)
61 + })
62 + },
63 + //日志分页
64 + logCurrentChange(val) {
65 + this.logData.page = val.page
66 + this.selectLog()
67 + },
68 + }
69 +}
70 +
71 +</script>
72 +
73 +<style lang="scss" scoped>
74 +
75 +</style>
...\ No newline at end of file ...\ No newline at end of file
...@@ -27,18 +27,17 @@ ...@@ -27,18 +27,17 @@
27 style="margin-left:10px" :disabled="checkData.length == 0" @click="batchDel"> 27 style="margin-left:10px" :disabled="checkData.length == 0" @click="batchDel">
28 删 除 28 删 除
29 </el-button> 29 </el-button>
30 - <el-button type="primary" icon="el-icon-download" size="small" style="margin-right:10px" 30 + <el-button type="primary" icon="el-icon-download" size="small" style="margin-left:10px"
31 @click="downloadTempleate">下载模板 31 @click="downloadTempleate">下载模板
32 </el-button> 32 </el-button>
33 - <el-button icon="el-icon-download" type="primary" size="small" style="margin-right:10px" 33 + <el-button icon="el-icon-download" type="primary" size="small" style="margin-left:10px"
34 @click="downloadExcel"> 34 @click="downloadExcel">
35 导出Excel 35 导出Excel
36 </el-button> 36 </el-button>
37 - <el-upload action="/goods/importGoods" name="file" :http-request="uploadExcel" :on-remove="handleRemove" 37 + <el-button type="primary" icon="el-icon-upload2" size="small" @click="uploadExcel"
38 - :limit="1" :on-exceed="handleExceed" :file-list="fileList" accept=".xlsx" class="upload-demo" 38 + v-hasPermi="['base:goodsStation:add']">导入Excel</el-button>
39 - v-hasPermi="['base:goodsStation:add']"> 39 + <el-button icon="el-icon-document" type="primary" size="small" @click="selectLog()">查询导入日志
40 - <el-button type="primary" icon="el-icon-upload2" size="small">导入Excel</el-button> 40 + </el-button>
41 - </el-upload>
42 </div> 41 </div>
43 <Tables ref="goodsStation" ductName="goodsStation" :data="tableData" :headerData="tableHeader" :selection="true" 42 <Tables ref="goodsStation" ductName="goodsStation" :data="tableData" :headerData="tableHeader" :selection="true"
44 :order="true" :selectFixed="false" :totalCount="totalCount" :loading="loading" 43 :order="true" :selectFixed="false" :totalCount="totalCount" :loading="loading"
...@@ -60,7 +59,7 @@ ...@@ -60,7 +59,7 @@
60 59
61 <script> 60 <script>
62 import { downLoadTemplate } from "@/api/flightInfoImport"; 61 import { downLoadTemplate } from "@/api/flightInfoImport";
63 -import { importGoods, batchDeleteGoods, searchGoods } from "@/api/goodsStation" 62 +import { batchDeleteGoods, searchGoods } from "@/api/goodsStation"
64 import Dialog from './dialog.vue' 63 import Dialog from './dialog.vue'
65 64
66 export default { 65 export default {
...@@ -189,29 +188,9 @@ export default { ...@@ -189,29 +188,9 @@ export default {
189 this.selection() 188 this.selection()
190 }, 189 },
191 //上传excel 190 //上传excel
192 - uploadExcel(option) { 191 + uploadExcel() {
193 - const file = option.file; 192 + this.openStatus = 'uploadExcel'
194 - this.loading = true; 193 + this.open = true
195 - importGoods(file, '').then((res) => {
196 - this.loading = false;
197 - if (res.code != 200) {
198 - if (res.code == 603) {
199 - this.$alert(res.msg, "提示", {
200 - confirmButtonText: "确定",
201 - type: "warning",
202 - });
203 - } else if (res.code === 201) {
204 - this.$message.warning(res.msg);
205 - this.errorData = res.data;
206 - this.$router.push({ name: 'UpDateResult', params: { data: this.errorData, from: 'FlightInformationImport' } })
207 - } else {
208 - this.$message.warning(res.msg);
209 - }
210 - } else {
211 - this.$message.success(res.msg);
212 - this.selection(1)
213 - }
214 - });
215 }, 194 },
216 //下载模板 195 //下载模板
217 downloadTempleate() { 196 downloadTempleate() {
...@@ -245,6 +224,9 @@ export default { ...@@ -245,6 +224,9 @@ export default {
245 this.fileList.push(file); 224 this.fileList.push(file);
246 this.uploadExcel(file); 225 this.uploadExcel(file);
247 }, 226 },
227 + selectLog() {
228 + this.$router.push({ name: 'GoodsUploadLog' })
229 + },
248 close() { 230 close() {
249 this.open = false 231 this.open = false
250 this.openStatus = '' 232 this.openStatus = ''
...@@ -260,16 +242,5 @@ export default { ...@@ -260,16 +242,5 @@ export default {
260 </script> 242 </script>
261 243
262 <style lang="scss" scoped> 244 <style lang="scss" scoped>
263 -.upload-demo {
264 - display: flex;
265 245
266 - .el-upload-list__item:first-child {
267 - margin-top: 5px !important;
268 - }
269 -
270 - .el-upload-list {
271 - display: inline-block;
272 - margin-left: 10px;
273 - }
274 -}
275 </style> 246 </style>
...\ No newline at end of file ...\ No newline at end of file
......
1 -<template>
2 - <div>
3 - <el-dialog title="新 增" :visible.sync="dialogVisible" width="50%" top="1vh" :close-on-click-modal="false"
4 - :show-close="false" append-to-body center>
5 - <el-table ref="filterTable" class="mt20" :data="resultData" size="small" border>
6 - <el-table-column label="行号" prop="line" width="50" align="center">
7 - </el-table-column>
8 - <el-table-column label="错误信息" prop="errorMessage" width="200">
9 - <template slot-scope="scope">
10 - <div v-for="(m, key) in scope.row.errorMessage" :key="key">
11 - {{ m }}
12 - </div>
13 - </template>
14 - </el-table-column>
15 - <el-table-column v-if="resultData.length == 0"></el-table-column>
16 - <el-table-column v-for="(value, key) in this.resultData[0]" :key="key"
17 - v-if="key != 'errorMessage' && key != 'line'" header-align="center" align="center" :label="key"
18 - :prop="key"></el-table-column>
19 - </el-table>
20 - <div slot="footer" class="dialog-footer">
21 - <el-button @click="close">取 消</el-button>
22 - </div>
23 - </el-dialog>
24 - </div>
25 -</template>
26 -
27 -<script>
28 -
29 -export default {
30 - name: 'UpDateResult',
31 - props: {
32 - dialogVisible: {
33 - type: Boolean,
34 - default: false
35 - },
36 - resultData: {
37 - type: Array,
38 - default: null
39 - }
40 - },
41 - data() {
42 - return {
43 - }
44 - },
45 - wactch: {
46 - dialogVisible(val) {
47 - if (val) {
48 - }
49 - }
50 - },
51 - methods: {
52 - close() {
53 - this.$emit('close')
54 - }
55 - }
56 -}
57 -</script>
58 -
59 -<style lang="scss" scoped>
60 -
61 -</style>
...\ No newline at end of file ...\ No newline at end of file
...@@ -8,9 +8,9 @@ ...@@ -8,9 +8,9 @@
8 <el-input type="text" v-model="formData.goodsStation" maxlength="25" placeholder="请输入货站名称"> 8 <el-input type="text" v-model="formData.goodsStation" maxlength="25" placeholder="请输入货站名称">
9 </el-input> 9 </el-input>
10 </el-form-item> 10 </el-form-item>
11 - <el-form-item label="航班" prop="flightList"> 11 + <el-form-item label="航班" prop="flightList">
12 <el-input type="textarea" v-model="flightList" rows="4" maxlength="125" 12 <el-input type="textarea" v-model="flightList" rows="4" maxlength="125"
13 - placeholder="请输入航班,多个用“;”隔开"> 13 + placeholder="请输入航班,多个用“;”隔开">
14 </el-input> 14 </el-input>
15 </el-form-item> 15 </el-form-item>
16 </el-form> 16 </el-form>
......
...@@ -93,5 +93,4 @@ export default { ...@@ -93,5 +93,4 @@ export default {
93 </script> 93 </script>
94 94
95 <style scoped> 95 <style scoped>
96 -
97 </style> 96 </style>
...\ No newline at end of file ...\ No newline at end of file
......
...@@ -165,6 +165,14 @@ ...@@ -165,6 +165,14 @@
165 }}</el-button> 165 }}</el-button>
166 <el-button type="primary" size="small" icon="el-icon-s-flag" :disabled="selectTable.length == 0" 166 <el-button type="primary" size="small" icon="el-icon-s-flag" :disabled="selectTable.length == 0"
167 v-hasPermi="['base:cargo:release']" @click="release">释放舱位</el-button> 167 v-hasPermi="['base:cargo:release']" @click="release">释放舱位</el-button>
168 + <el-button type="primary" size="small" icon="el-icon-sort" :disabled="selectTable.length == 0" @click="transfer"
169 + v-hasPermi="['log:cargo:flightTransfer']">航班迁转</el-button>
170 + <!-- <el-button type="primary" size="small" :disabled="cargoPlaneTime == null || cargoPlaneTime.length <= 0"
171 + @click="historyFlie" v-hasPermi="['log:cargo:archiveData']">
172 + <el-tooltip class="item" effect="dark" content="请先选择配置航班日期" placement="top">
173 + <span class="el-icon-warning-outline">生成归档数据</span>
174 + </el-tooltip>
175 + </el-button> -->
168 <span class="ml20" style="color: #ffba00">全部导出上限80000条数据</span> 176 <span class="ml20" style="color: #ffba00">全部导出上限80000条数据</span>
169 <el-progress v-if="progress != 0" class="progress" :stroke-width="12" :show-text="true" :percentage="progress" 177 <el-progress v-if="progress != 0" class="progress" :stroke-width="12" :show-text="true" :percentage="progress"
170 :status="progress == 100 ? 'success' : 'warning'"></el-progress> 178 :status="progress == 100 ? 'success' : 'warning'"></el-progress>
...@@ -208,18 +216,21 @@ ...@@ -208,18 +216,21 @@
208 </div> 216 </div>
209 </el-dialog> 217 </el-dialog>
210 <Dialog :dialogVisible="openView" :cargoData="cargoLog" @close="viewClose" /> 218 <Dialog :dialogVisible="openView" :cargoData="cargoLog" @close="viewClose" />
219 + <Info :tableData="selectTable" :dialogVisible="openTransfer" @dialogBeforeClose="dialogBeforeClose" />
211 </div> 220 </div>
212 </template> 221 </template>
213 222
214 <script> 223 <script>
215 -import { findConditionData, findCargoData, releaseCargo, getFlightsRoutes } from "@/api/cargoSelect"; 224 +import { findConditionData, findCargoData, releaseCargo, getFlightsRoutes, historyCargo } from "@/api/cargoSelect";
216 import { downLoadXlsx } from "@/utils/zipdownload"; 225 import { downLoadXlsx } from "@/utils/zipdownload";
217 import Dialog from "./dialog.vue"; 226 import Dialog from "./dialog.vue";
227 +import Info from './info.vue'
218 228
219 export default { 229 export default {
220 name: "QueryCargo", 230 name: "QueryCargo",
221 components: { 231 components: {
222 - Dialog 232 + Dialog,
233 + Info
223 }, 234 },
224 data() { 235 data() {
225 return { 236 return {
...@@ -330,6 +341,7 @@ export default { ...@@ -330,6 +341,7 @@ export default {
330 tableHeight: null, 341 tableHeight: null,
331 dialogVisible: false, 342 dialogVisible: false,
332 openView: false, 343 openView: false,
344 + openTransfer: false,
333 formShow: true, //菜单隐藏 345 formShow: true, //菜单隐藏
334 }; 346 };
335 }, 347 },
...@@ -340,6 +352,7 @@ export default { ...@@ -340,6 +352,7 @@ export default {
340 } else { 352 } else {
341 this.tableHeader = this.tableHeaders['cargo'] 353 this.tableHeader = this.tableHeaders['cargo']
342 } 354 }
355 + this.select(0)
343 }, 356 },
344 357
345 activated() { 358 activated() {
...@@ -476,6 +489,7 @@ export default { ...@@ -476,6 +489,7 @@ export default {
476 }, 489 },
477 //查询 490 //查询
478 async select(val) { 491 async select(val) {
492 + this.selectTable = []
479 this.tableData = []; 493 this.tableData = [];
480 this.allWeight = 0; 494 this.allWeight = 0;
481 this.allQty = 0; 495 this.allQty = 0;
...@@ -508,10 +522,9 @@ export default { ...@@ -508,10 +522,9 @@ export default {
508 .catch(() => { 522 .catch(() => {
509 this.tableLoading = false; 523 this.tableLoading = false;
510 }); 524 });
511 - this.$refs.newTables.clearTable();
512 this.cargoTotal(); 525 this.cargoTotal();
513 }, 526 },
514 - //释放 527 + //释放
515 release() { 528 release() {
516 let idList = [] 529 let idList = []
517 this.selectTable.map(item => { 530 this.selectTable.map(item => {
...@@ -534,7 +547,7 @@ export default { ...@@ -534,7 +547,7 @@ export default {
534 val === item.id ? item.msg = item.msg + '正在释放中,请勿重复释放。' : '' 547 val === item.id ? item.msg = item.msg + '正在释放中,请勿重复释放。' : ''
535 }) 548 })
536 res.data['noFlight'].map(val => { 549 res.data['noFlight'].map(val => {
537 - val === item.id ? item.msg = item.msg + '已释放位。' : '' 550 + val === item.id ? item.msg = item.msg + '已释放位。' : ''
538 }) 551 })
539 res.data['pushFalse'].map(val => { 552 res.data['pushFalse'].map(val => {
540 val === item.id ? item.msg = item.msg + '该货物配舱结果已回推ACCS,不能释放。' : '' 553 val === item.id ? item.msg = item.msg + '该货物配舱结果已回推ACCS,不能释放。' : ''
...@@ -548,6 +561,26 @@ export default { ...@@ -548,6 +561,26 @@ export default {
548 console.log(err) 561 console.log(err)
549 }) 562 })
550 }, 563 },
564 + transfer() {
565 + this.openTransfer = true
566 + },
567 + //生成历史数据文件
568 + historyFlie() {
569 + if (new Date(this.cargoPlaneTime[1]).getTime() - new Date(this.cargoPlaneTime[0]).getTime() > 2592000000) {
570 + this.msgWarning('配载日期区间不能大于31天!')
571 + } else {
572 + this.dataInfo();
573 + historyCargo(this.formData).then(res => {
574 + if (res.code === 200) {
575 + this.msgSuccess('操作成功,正在生成中,稍后可在下载页面查看!')
576 + } else {
577 + this.msgWarning(res.msg)
578 + }
579 + }).catch(err => {
580 + console.log(err)
581 + })
582 + }
583 + },
551 //关闭弹窗 584 //关闭弹窗
552 close() { 585 close() {
553 this.dialogVisible = false 586 this.dialogVisible = false
...@@ -725,6 +758,11 @@ export default { ...@@ -725,6 +758,11 @@ export default {
725 viewClose() { 758 viewClose() {
726 this.openView = false 759 this.openView = false
727 }, 760 },
761 + //关闭迁转
762 + dialogBeforeClose() {
763 + this.openTransfer = false
764 + this.select(0)
765 + },
728 //设置关闭 766 //设置关闭
729 headerSetClose(val) { 767 headerSetClose(val) {
730 if (val == 1) { 768 if (val == 1) {
......
1 +<template>
2 + <div>
3 + <el-dialog title="货物配舱" width="80%" :visible.sync="dialogVisible" :close-on-click-modal="false" :show-close="false"
4 + :append-to-body="true">
5 + <el-divider content-position="left">已选货物信息</el-divider>
6 + <el-table :data="tableData" size="mini" height="200" max-height="200" border stripe highlight-current-row
7 + style="width: 100%">
8 + <el-table-column type="index" label="序号" align="center">
9 + </el-table-column>
10 + <el-table-column v-for="(item, index) in cargoHeader" header-align="center" align="center" :prop="item.value"
11 + :label="item.name" :key="index" :width="item.width" :show-overflow-tooltip="true" :formatter="formatter">
12 + </el-table-column>
13 + </el-table>
14 + <el-form ref="form" class="form-header" label-position="right" label-width="auto"
15 + style="width: 400px; margin: 30px auto" :model="formData" :rules="rules">
16 + <el-form-item label="航班号" prop="fltNo">
17 + <el-input class="formItem" v-model="fltNo" size="medium" placeholder="请输入航班号" maxlength="20"
18 + style="width: 350px" @change="dateChange"></el-input>
19 + </el-form-item>
20 + <el-form-item label="航班日期:" prop="fltDate">
21 + <el-date-picker class="formItem" v-model="formData.fltDate" type="date" placeholder="选择日期"
22 + value-format="yyyy-MM-dd" size="medium" style="width: 350px" @change="dateChange">
23 + </el-date-picker>
24 + </el-form-item>
25 + <el-form-item prop="route">
26 + <template slot="label">
27 + <div style="display:inline-block">航线:
28 + <el-tooltip class="item" effect="dark" content="选择航线需要先输入航班号和航班日期,才能选择对应得航线" placement="top-start">
29 + <span class="el-icon-warning" style="color:#1890ff;font-size:16px"></span>
30 + </el-tooltip>
31 + </div>
32 + </template>
33 + <el-select class="formItem" v-model="formData.route" placeholder="不限" :disabled="routeList.length == 0">
34 + <el-option v-for="(item, index) in routeList" :label="item.route" :value="item.route" :key="index">
35 + <Tooltips :content="item.route" :refName="item.route"></Tooltips>
36 + </el-option>
37 + </el-select>
38 + </el-form-item>
39 + </el-form>
40 + <div slot="footer">
41 + <el-button @click="dialogBeforeClose">取 消</el-button>
42 + <el-button type="primary" @click="submit" :loading="loading">确 定</el-button>
43 + </div>
44 + </el-dialog>
45 + </div>
46 +</template>
47 +
48 +<script>
49 +import { batchMoveCargoToOtherFlight, findFlightRoute } from "@/api/cargoSelect";
50 +
51 +export default {
52 + props: {
53 + dialogVisible: {
54 + type: Boolean,
55 + default: false,
56 + },
57 + tableData: {
58 + type: Array,
59 + default: null,
60 + },
61 + },
62 + data() {
63 + return {
64 + formData: {
65 + ids: [],
66 + fltNo: undefined,
67 + fltDate: undefined,
68 + route: null,
69 + overweight: false,
70 + notInWhite: false,
71 + },
72 + cargoHeader: [
73 + { name: "口岸代码", value: "portName", width: "" },
74 + { name: "运单号", value: "waybillNo", width: "" },
75 + { name: "货物状态", value: "statusName", width: "" },
76 + { name: "站点", value: "siteName", width: "" },
77 + { name: "申报类型", value: "typeName", width: "" },
78 + { name: "URSA", value: "ursa", width: "" },
79 + { name: "实际重量", value: "actualWeight", width: "" },
80 + { name: "件数", value: "qty", width: "" },
81 + { name: "ACCS原航班号", value: "fltNoAccs", width: "120" },
82 + { name: "ACCS原航班日期", value: "fltDateAccs", width: "130" },
83 + { name: "品名描述", value: "nameDescription", width: "" },
84 + { name: "是否自动", value: "cargoRulesStatus", width: "" },
85 + { name: "创建人", value: "createUserName", width: "" },
86 + { name: "创建时间", value: "createTime", width: "" },
87 + ],
88 + routeList: [],
89 + rules: {
90 + fltNo: [
91 + {
92 + required: true,
93 + message: "航班号不能为空",
94 + trigger: "blur",
95 + },
96 + ],
97 + fltDate: [
98 + {
99 + required: true,
100 + message: "航班日期不能为空",
101 + trigger: "blur",
102 + },
103 + ],
104 + route: [
105 + {
106 + required: true,
107 + message: "航线不能为空",
108 + trigger: "blur",
109 + },
110 + ],
111 + },
112 + loading: false,
113 + };
114 + },
115 + methods: {
116 + cleaerForm() {
117 + this.formData = {
118 + ids: [],
119 + fltNo: undefined,
120 + fltDate: undefined,
121 + route: undefined,
122 + flightId: undefined,
123 + overweight: false,
124 + notInWhite: false,
125 + };
126 + this.routeList = []
127 + },
128 + //确定配舱
129 + submit() {
130 + this.formData.overweight = false
131 + this.formData.notInWhite = false
132 + this.$refs.form.validate(val => {
133 + if (val) {
134 + this.loading = true;
135 + let arr = [];
136 + this.tableData.forEach((item) => {
137 + arr.push(item.id);
138 + });
139 + this.formData.ids = arr;
140 + this.routeList.forEach(item => {
141 + if (item.route === this.formData.route) {
142 + this.formData.flightId = item.id
143 + }
144 + })
145 + if (this.formData.fltNo && this.formData.fltDate) {
146 + batchMoveCargoToOtherFlight(this.formData).then((res) => {
147 + //code 200 配舱成功 202重量已满需要确认 203货物不在白名单需要确认 其余code直接输出msg 接口先判断重量后判断白名单 overweight/notInWhite初始默认false
148 + if (res.code === 200) {
149 + this.loading = false;
150 + this.msgSuccess(res.msg)
151 + this.cleaerForm();
152 + this.$emit("dialogBeforeClose", { close: false, reload: true });
153 + } else if (res.code === 201) {
154 + this.loading = false;
155 + let arr = []
156 + res.data.forEach(item => {
157 + let obj = {
158 + waybillNo: item.split(':')[0],
159 + errorMessage: item.split(':')[1]
160 + }
161 + arr.push(obj)
162 + })
163 + this.$router.push({ name: 'UpDateResult', params: { data: arr, from: 'queryCargo' } })
164 + this.dialogBeforeClose()
165 + } else if (res.code === 202) {
166 + this.reBatchMoveCargoToOtherFlight(res.msg, 'overweight')
167 + } else if (res.code === 203) {
168 + this.reBatchMoveCargoToOtherFlight(res.msg, 'notInWhite')
169 + } else {
170 + this.loading = false;
171 + this.dialogBeforeClose()
172 + this.msgWarning(res.msg)
173 + }
174 + }).catch(() => {
175 + this.loading = false;
176 + });
177 + } else {
178 + this.loading = false;
179 + this.msgWarning('航班号或航班日期不能为空')
180 + }
181 + }
182 + })
183 + },
184 + //迁转白名单/超重确认
185 + reBatchMoveCargoToOtherFlight(msg, status) {
186 + this.$confirm(msg, "提示", {
187 + confirmButtonText: "确定",
188 + cancelButtonText: "取消",
189 + type: "warning",
190 + }).then(() => {
191 + if (status == 'overweight') {
192 + this.formData.overweight = true; //确定继续overweight变为true再次请求接口
193 + } else {
194 + this.formData.notInWhite = true; //确定继续notInWhite变为true再次请求接口
195 + }
196 + batchMoveCargoToOtherFlight(this.formData).then((res) => {
197 + if (res.code === 200) {
198 + this.loading = false
199 + this.msgSuccess('航班迁转成功')
200 + this.cleaerForm();
201 + this.$emit("dialogBeforeClose", { close: false, reload: true });
202 + } else if (res.code === 201) {
203 + let arr = []
204 + res.data.forEach(item => {
205 + let obj = {
206 + waybillNo: item.split(':')[0],
207 + errorMessage: item.split(':')[1]
208 + }
209 + arr.push(obj)
210 + })
211 + this.$router.push({ name: 'UpDateResult', params: { data: arr, from: 'queryCargo' } })
212 + this.dialogBeforeClose()
213 + } else if (res.code === 203) {
214 + this.reBatchMoveCargoToOtherFlight(res.msg, 'notInWhite')
215 + } else {
216 + this.msgWarning(res.msg)
217 + this.loading = false
218 + }
219 + })
220 + }).ctach(() => {
221 + //取消 取消当前配舱
222 + this.loading = false
223 + this.msgSuccess('迁转已取消')
224 + this.cleaerForm();
225 + this.$emit("dialogBeforeClose", {
226 + close: false,
227 + reload: true,
228 + });
229 + })
230 + },
231 + dialogBeforeClose() {
232 + this.cleaerForm();
233 + this.$refs['form'].clearValidate();
234 + this.$emit("dialogBeforeClose", { close: false, reload: true });
235 + },
236 + formatter(row, column, cellValue, index) {
237 + if (column.property == "cargoRulesStatus") {
238 + if (cellValue == 1) {
239 + return "手动"
240 + } else {
241 + return "自动"
242 + }
243 + }
244 + return cellValue
245 + },
246 + //日期选择变化
247 + dateChange(val) {
248 + this.routeList = []
249 + this.formData.route = null
250 + if (this.formData.fltNo && this.formData.fltNo != null && this.formData.fltNo != '') {
251 + if (this.formData.fltDate && this.formData.fltDate != null && this.formData.fltDate != '') {
252 + let obj = {
253 + fltNo: this.formData.fltNo,
254 + fltDate: this.formData.fltDate,
255 + }
256 + findFlightRoute(obj).then(res => {
257 + if (res.code === 200) {
258 + res.data[0].route.indexOf(';') <= 0 ?
259 + this.routeList = res.data :
260 + res.data[0].route.split(';').forEach(item => {
261 + this.routeList.push({ id: res.data[0].id, route: item })
262 + })
263 + } else {
264 + this.msgWarning(res.msg)
265 + }
266 + }).catch(err => {
267 + console.log(err)
268 + })
269 + } else {
270 + this.msgWarning('航班日期不能为空')
271 + }
272 + } else {
273 + this.msgWarning('航班号不能为空')
274 + }
275 + }
276 + },
277 + computed: {
278 + fltNo: {
279 + get: function () {
280 + return this.formData.fltNo;
281 + },
282 + set: function (val) {
283 + this.formData.fltNo = this.upCase(val);
284 + },
285 + },
286 + },
287 +};
288 +</script>
289 +
290 +<style>
291 +
292 +</style>
...\ No newline at end of file ...\ No newline at end of file
1 <template> 1 <template>
2 - <div class="login" :style="display"> 2 + <div class="login">
3 <el-form ref="loginForm" :model="loginForm" :rules="loginRules" class="login-form"> 3 <el-form ref="loginForm" :model="loginForm" :rules="loginRules" class="login-form">
4 <h3 class="title">IMAC后台管理系统</h3> 4 <h3 class="title">IMAC后台管理系统</h3>
5 <el-form-item prop="username"> 5 <el-form-item prop="username">
...@@ -13,8 +13,9 @@ ...@@ -13,8 +13,9 @@
13 <svg-icon slot="prefix" icon-class="password" class="el-input__icon input-icon" /> 13 <svg-icon slot="prefix" icon-class="password" class="el-input__icon input-icon" />
14 </el-input> 14 </el-input>
15 </el-form-item> 15 </el-form-item>
16 +
16 <!-- <el-checkbox v-model="loginForm.rememberMe" style="margin:0px 0px 25px 0px;">记住密码</el-checkbox> --> 17 <!-- <el-checkbox v-model="loginForm.rememberMe" style="margin:0px 0px 25px 0px;">记住密码</el-checkbox> -->
17 - <el-form-item style="width: 100%; marginTop: 44px"> 18 + <el-form-item style="width: 100%; marginTop: 65px">
18 <el-button :loading="loading" size="medium" type="primary" style="width: 100%" 19 <el-button :loading="loading" size="medium" type="primary" style="width: 100%"
19 @click.native.prevent="handleLogin"> 20 @click.native.prevent="handleLogin">
20 <span v-if="!loading">登 录</span> 21 <span v-if="!loading">登 录</span>
...@@ -30,9 +31,6 @@ ...@@ -30,9 +31,6 @@
30 </template> 31 </template>
31 32
32 <script> 33 <script>
33 -import { getCodeImg } from "@/api/login";
34 -//import Cookies from "js-cookie";
35 -import { encrypt } from "@/utils/jsencrypt";
36 34
37 export default { 35 export default {
38 name: "Login", 36 name: "Login",
...@@ -55,7 +53,6 @@ export default { ...@@ -55,7 +53,6 @@ export default {
55 }, 53 },
56 loading: false, 54 loading: false,
57 redirect: undefined, 55 redirect: undefined,
58 - display: "display:flex",
59 }; 56 };
60 }, 57 },
61 watch: { 58 watch: {
...@@ -63,8 +60,8 @@ export default { ...@@ -63,8 +60,8 @@ export default {
63 handler: function (route) { 60 handler: function (route) {
64 this.redirect = route.query && route.query.redirect; 61 this.redirect = route.query && route.query.redirect;
65 }, 62 },
66 - immediate: true 63 + immediate: true,
67 - } 64 + },
68 }, 65 },
69 created() { 66 created() {
70 this.getCookie(); 67 this.getCookie();
...@@ -101,12 +98,16 @@ export default { ...@@ -101,12 +98,16 @@ export default {
101 } 98 }
102 this.$store 99 this.$store
103 .dispatch("Login", this.loginForm) 100 .dispatch("Login", this.loginForm)
104 - .then(() => { 101 + .then(res => {
102 + this.loading = false;
103 + if (res.code != 200) {
104 + this.msgWarning(res.msg)
105 + }
105 this.$router.push({ path: this.redirect || "/" }).catch(() => { }); 106 this.$router.push({ path: this.redirect || "/" }).catch(() => { });
106 }) 107 })
107 - .catch(() => { 108 + .catch(err => {
108 this.loading = false; 109 this.loading = false;
109 - //this.getCode(); 110 + this.msgWarning(err)
110 }); 111 });
111 } 112 }
112 }); 113 });
......
...@@ -4,9 +4,11 @@ ...@@ -4,9 +4,11 @@
4 <!-- <el-table-column label="行号" prop="line" width="50" align="center"> 4 <!-- <el-table-column label="行号" prop="line" width="50" align="center">
5 </el-table-column> --> 5 </el-table-column> -->
6 <el-table-column label="序号" type="index" width="70" align="center" /> 6 <el-table-column label="序号" type="index" width="70" align="center" />
7 + <el-table-column label="运单号" prop="waybillNo" width="150" v-if="fromRoute == 'queryCargo'" />
7 <el-table-column label="错误信息" prop="errorMessage"> 8 <el-table-column label="错误信息" prop="errorMessage">
8 <template slot-scope="scope"> 9 <template slot-scope="scope">
9 - {{scope.row}} 10 + <span v-if="fromRoute == 'queryCargo'">{{ scope.row.errorMessage }}</span>
11 + <span v-else> {{ scope.row }}</span>
10 <!-- <div v-for="(m, key) in scope.row.errorMessage" :key="key"> 12 <!-- <div v-for="(m, key) in scope.row.errorMessage" :key="key">
11 {{ m }} 13 {{ m }}
12 </div> --> 14 </div> -->
...@@ -42,6 +44,7 @@ export default { ...@@ -42,6 +44,7 @@ export default {
42 }, 44 },
43 methods: { 45 methods: {
44 close() { 46 close() {
47 + this.$store.dispatch('tagsView/delView', this.$route)
45 this.$store.state.tagsView.visitedViews.splice( 48 this.$store.state.tagsView.visitedViews.splice(
46 this.$store.state.tagsView.visitedViews.findIndex( 49 this.$store.state.tagsView.visitedViews.findIndex(
47 (item) => item.path === this.$route.path 50 (item) => item.path === this.$route.path
......
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
26 <div v-else-if="dictName == '航线'"> 26 <div v-else-if="dictName == '航线'">
27 <div v-if="status == 'add'"> 27 <div v-if="status == 'add'">
28 <el-form-item label="航班号" prop="fltNo"> 28 <el-form-item label="航班号" prop="fltNo">
29 - <el-input type="text" v-model="newDictionary.fltNo" placeholder="请输入航班号" maxlength="50"> 29 + <el-input type="text" v-model="newDictionary.fltNo" placeholder="请输入航班号" maxlength="20">
30 </el-input> 30 </el-input>
31 </el-form-item> 31 </el-form-item>
32 <el-form-item label="航线" prop="route"> 32 <el-form-item label="航线" prop="route">
......
...@@ -314,7 +314,6 @@ export default { ...@@ -314,7 +314,6 @@ export default {
314 }, 314 },
315 //修改 315 //修改
316 // upDate(val) { 316 // upDate(val) {
317 - // console.log(val)
318 // this.status = val.status 317 // this.status = val.status
319 // this.addDictionary = val.data 318 // this.addDictionary = val.data
320 // this.open = true 319 // this.open = true
......
1 +<template>
2 + <div class="menuDrawer">
3 + <el-dialog :title="drawerTitle" width="50%" :visible.sync="dialogVisible" :close-on-click-modal="false" :show-close="false"
4 + :append-to-body="true">
5 + <el-form ref="userForm" :model="menuForm" :disabled="menuFormDisabled" :rules="rules" label-width="auto"
6 + style="margin: 10px">
7 + <el-row>
8 + <el-col :span="12">
9 + <el-form-item label="菜单名称" prop="">
10 + <!-- <el-input
11 + placeholder="请输入权限名"
12 + :disabled="menuFormDisabled"
13 + v-model="menuData.userName"
14 + size="mini"
15 + ></el-input> -->
16 + </el-form-item>
17 + </el-col>
18 + <el-col :span="12">
19 + <el-form-item label="菜单路由" prop="">
20 + <!-- <el-input
21 + placeholder="请输入权限名"
22 + :disabled="menuFormDisabled"
23 + v-model="menuData.userName"
24 + size="mini"
25 + ></el-input> -->
26 + </el-form-item>
27 + </el-col>
28 + <el-col :span="12">
29 + <el-form-item label="组件名称" prop="">
30 + <!-- <el-input
31 + placeholder="请输入权限名"
32 + :disabled="menuFormDisabled"
33 + v-model="menuData.userName"
34 + size="mini"
35 + ></el-input> -->
36 + </el-form-item>
37 + </el-col>
38 + <el-col :span="24">
39 + <el-form-item label="菜单状态" prop="">
40 + <el-switch v-model="menuData.menuStatus" active-color="#13ce66" inactive-color="#ff4949"
41 + :disabled="menuFormDisabled"></el-switch>
42 + </el-form-item>
43 + </el-col>
44 + <el-col :span="24">
45 + <el-form-item label="图标选择" prop="">
46 + <iconSelect @selected="selected"></iconSelect>
47 + </el-form-item>
48 + </el-col>
49 + <el-col :span="24">
50 + <el-form-item label="权限设置" prop="">
51 + <el-col :span="6">
52 + <el-radio label="页面" size="medium"></el-radio>
53 + </el-col>
54 + <el-col :span="6">
55 + <el-radio label="按钮" size="medium"></el-radio>
56 + </el-col>
57 + <el-col :span="24">
58 + <el-card shadow="never">
59 + <el-input placeholder=""></el-input>
60 + </el-card>
61 + </el-col>
62 + </el-form-item>
63 + </el-col>
64 + </el-row>
65 + </el-form>
66 +
67 + <div slot="footer">
68 + <el-button @click="handleClose">取 消</el-button>
69 + <el-button type="primary" @click="submit">确 定</el-button>
70 + </div>
71 + </el-dialog>
72 + </div>
73 +</template>
74 +
75 +<script>
76 +import iconSelect from "@/components/IconSelect";
77 +export default {
78 + components: {
79 + iconSelect,
80 + },
81 + props: {
82 + drawerTitle: {
83 + type: String,
84 + default: "",
85 + },
86 + menuFormDisabled: {
87 + type: Boolean,
88 + default: false,
89 + },
90 + dialogVisible: {
91 + type: Boolean,
92 + default: false,
93 + },
94 + menuData: {
95 + type: Object,
96 + default: null,
97 + },
98 + },
99 + data() {
100 + return {
101 + menuForm: {},
102 + rules: {}
103 + };
104 + },
105 + updated() {
106 + this.menuForm = this.menuData;
107 + },
108 + watch: {
109 + dialogVisible(val, oldVal) {
110 + if (val) {
111 + this.menuForm = this.menuData;
112 + }
113 + }
114 + },
115 + methods: {
116 + handleClose() {
117 + this.$emit("handleClose", false);
118 + },
119 + selected(val) {
120 + console.log(val);
121 + },
122 + submit() { },
123 + },
124 +};
125 +</script>
126 +
127 +<style>
128 +</style>
...\ No newline at end of file ...\ No newline at end of file
...@@ -44,9 +44,13 @@ ...@@ -44,9 +44,13 @@
44 <script> 44 <script>
45 import { getAllAuth, updateStatus } from "@/api/system/user.js"; 45 import { getAllAuth, updateStatus } from "@/api/system/user.js";
46 import dictLabels from "@/assets/languages/dictLabels.js"; 46 import dictLabels from "@/assets/languages/dictLabels.js";
47 +import Drawer from "./drawer.vue";
47 48
48 export default { 49 export default {
49 name: "MenuConfig", 50 name: "MenuConfig",
51 + components: {
52 + Drawer,
53 + },
50 data() { 54 data() {
51 return { 55 return {
52 drawer: false, 56 drawer: false,
......
1 +<template>
2 + <div>
3 + <el-dialog :title="title" :visible.sync="dialogVisible" width="60%" top="8vh" :before-close="close"
4 + append-to-body :close-on-click-modal="false" @submit.native.prevent>
5 + <el-form class="form-header" ref="superAllocationForm" :model="formData" label-width="auto"
6 + label-position="left" style="margin-bottom:10px" @submit.native.prevent size="small" :rules="rules">
7 + <el-row>
8 + <el-col :span="22">
9 + <el-form-item label="发件人账号" prop="shipperAccount">
10 + <el-input type="textarea" v-model="formData.shipperAccount" placeholder="请输入发件人账号,多个以“;”分割"
11 + maxlength="50" rows="4" :disabled="disabled" />
12 + </el-form-item>
13 + </el-col>
14 + <el-col :span="12">
15 + <el-form-item label="航班号" prop="flightNo">
16 + <el-input class="formItem" ref="flightNoFormItem" v-focus v-model="formData.flightNo"
17 + maxlength="20" placeholder="请输入航班号" @change="getRoute" :disabled="disabled">
18 + </el-input>
19 + </el-form-item>
20 + </el-col>
21 + <el-col :span="12">
22 + <el-form-item label="航班日期" prop="flightDate">
23 + <el-date-picker class="formItem" v-model="formData.flightDate" type="date"
24 + placeholder="选择日期" value-format="yyyy-MM-dd" @change="getRoute" :disabled="disabled">
25 + </el-date-picker>
26 + </el-form-item>
27 + </el-col>
28 + </el-row>
29 + <el-row>
30 + <el-col :span="12">
31 + <el-form-item label="航线" prop="flightRoute">
32 + <el-select class="formItem" v-model="formData.flightRoute" placeholder="未设置"
33 + :disabled="routeList.length == 0 || disabled" @change="routeChange">
34 + <el-option v-for="(item, index) in routeList" :label="item.route" :value="item.route"
35 + :key="item.id">
36 + <Tooltips :content="item.route" :refName="item.route"></Tooltips>
37 + </el-option>
38 + </el-select>
39 + </el-form-item>
40 + </el-col>
41 + <el-col :span="12">
42 + <el-form-item label="预留舱位(KG)" prop="groupAllWeight">
43 + <el-input class="formItem" v-model="formData.groupAllWeight" placeholder="请输入预留舱位"
44 + oninput="value=value.replace(/[^\d\.\-]/g,'')">
45 + </el-input>
46 + </el-form-item>
47 + </el-col>
48 + </el-row>
49 + <el-row>
50 + <el-col :span="12">
51 + <el-form-item label="URSA包含" prop="includeUrsa">
52 + <el-input class="formItem" v-model="formData.includeUrsa"
53 + placeholder="URSA之间用分号分隔,例:F2;F3;P_" type="textarea" rows="3" maxlength="100">
54 + </el-input>
55 + </el-form-item>
56 + </el-col>
57 + <el-col :span="12">
58 + <el-form-item label="URSA不包含" prop="notIncludeUrsa">
59 + <el-input class="formItem" v-model="formData.notIncludeUrsa"
60 + placeholder="URSA之间用分号分隔,例:F2;F3;P_" type="textarea" rows="3" maxlength="100">
61 + </el-input>
62 + </el-form-item>
63 + </el-col>
64 + </el-row>
65 + <el-row>
66 + <el-col :span="24">
67 + <el-form-item label="申报类别" prop="classificationList">
68 + <el-card shadow="never" style="width: 95%">
69 + <el-checkbox-group v-model="formData.classificationList">
70 + <el-row>
71 + <el-col v-for="item in checkBoxItem.cargoType" :span="2" :key="item.id">
72 + <el-checkbox v-if="item.status === 1" :label="item.chineseName"
73 + :name="item.chineseName" :key="item.code">
74 + <Tooltips :content="item.chineseName" :refName="item.chineseName">
75 + </Tooltips>
76 + </el-checkbox>
77 + </el-col>
78 + </el-row>
79 + </el-checkbox-group>
80 + </el-card>
81 + </el-form-item>
82 + </el-col>
83 + </el-row>
84 + <el-row>
85 + <el-col :span="24">
86 + <el-form-item label="Service Code" prop="serviceCodeList">
87 + <el-card shadow="never" style="width: 95%">
88 + <el-checkbox-group v-model="formData.serviceCodeList">
89 + <el-row>
90 + <el-col v-for="item in checkBoxItem.serviceCode" :span="2" :key="item.id">
91 + <el-checkbox
92 + v-if="item.status === 1 || checkBoxItem.serviceCode.includes(item.chineseName)"
93 + :label="item.chineseName" :name="item.chineseName"
94 + :disabled="checkBoxItem.serviceCode.includes(item.chineseName) && item.status == 0"
95 + :key="item.code">
96 + <Tooltips :content="item.chineseName" :refName="item.chineseName">
97 + </Tooltips>
98 + </el-checkbox>
99 + </el-col>
100 + </el-row>
101 + </el-checkbox-group>
102 + </el-card>
103 + </el-form-item>
104 + </el-col>
105 + </el-row>
106 + </el-form>
107 + <span slot="footer" class="dialog-footer">
108 + <el-button type="primary" :loading="loading" @click="submit">确 定</el-button>
109 + <el-button @click="close">取 消</el-button>
110 + </span>
111 + </el-dialog>
112 + </div>
113 +</template>
114 +
115 +<script>
116 +import { findFlightRoute } from "@/api/cargoSelect";
117 +import { allDictData } from "@/api/destinationFlight";
118 +import { saveOrUpdate } from "@/api/supserAllocation"
119 +
120 +export default {
121 + name: '',
122 + props: {
123 + dialogVisible: {
124 + type: Boolean,
125 + default: false
126 + },
127 + ruleData: {
128 + type: Object,
129 + default: null
130 + },
131 + status: {
132 + type: String,
133 + default: ''
134 + }
135 + },
136 + data() {
137 + return {
138 + formData: {
139 + flightNo: '',
140 + flightDate: '',
141 + flightRoute: null,
142 + classificationList: [],
143 + serviceCodeList: []
144 + },
145 + routeList: [],
146 + checkBoxItem: {
147 + cargoType: [],
148 + serviceCode: []
149 + },
150 + rules: {
151 + shipperAccount: [
152 + {
153 + required: true,
154 + message: "发件人账号不能为空",
155 + trigger: "blur",
156 + },
157 + ],
158 + flightDate: [
159 + {
160 + required: true,
161 + message: "航班日期不能为空",
162 + trigger: "blur",
163 + },
164 + ],
165 + flightNo: [
166 + {
167 + required: true,
168 + message: "航班号不能为空",
169 + trigger: "blur",
170 + },
171 + ],
172 + flightRoute: [
173 + {
174 + required: true,
175 + message: "航线不能为空",
176 + trigger: "change",
177 + },
178 + ],
179 + groupAllWeight: [
180 + {
181 + required: true,
182 + message: "预留舱位不能为空",
183 + trigger: "blur",
184 + },
185 + ],
186 + includeUrsa: [
187 + {
188 + required: true,
189 + message: "URSA不能为空",
190 + trigger: "blur",
191 + },
192 + ],
193 + },
194 + title: '',
195 + loading: false,
196 + disabled: false
197 + }
198 + },
199 + created() {
200 + this.getCheckData()
201 + },
202 + watch: {
203 + dialogVisible(val) {
204 + if (val) {
205 + if (this.status == 'add') {
206 + this.title = '新增'
207 + this.$nextTick(() => {
208 + this.$refs["superAllocationForm"].clearValidate();
209 + })
210 + } else if (this.status == 'update') {
211 + this.title = '修改'
212 + this.formData = this.ruleData
213 + this.disabled = true
214 + this.getRoute(1)
215 + } else if (this.status == 'copy') {
216 + this.title = '复制'
217 + this.formData = this.ruleData
218 + this.getRoute(1)
219 + }
220 + }
221 + }
222 + },
223 + methods: {
224 + //获取复选框数据
225 + getCheckData() {
226 + allDictData().then(res => {
227 + if (res.code === 200) {
228 + this.checkBoxItem.cargoType = res.data.cargoType
229 + this.checkBoxItem.serviceCode = res.data.serviceCode
230 + } else {
231 + this.msgWarning(res.msg)
232 + }
233 + }).catch(err => {
234 + console.log(err)
235 + })
236 + },
237 + //获取航线
238 + getRoute(val) {
239 + this.routeList = []
240 + if (val != 1) {
241 + this.formData.flightRoute = null
242 + }
243 + this.formData.flightNo = this.formData.flightNo.toUpperCase()
244 + let obj = {
245 + fltNo: this.formData.flightNo,
246 + fltDate: this.formData.flightDate
247 + }
248 + findFlightRoute(obj).then(res => {
249 + if (res.code === 200) {
250 + this.routeList = res.data
251 + } else {
252 + this.msgWarning(res.msg)
253 + }
254 + this.$refs['superAllocationForm'].clearValidate('flightRoute')
255 + }).catch(err => {
256 + console.log(err)
257 + })
258 + },
259 + //提交
260 + submit() {
261 + this.$refs["superAllocationForm"].validate((valid) => {
262 + if (valid) {
263 + this.loading = true
264 + this.formData.shipperAccount = this.formData.shipperAccount.replace(/;/g, ";")
265 + this.formData.includeUrsa = this.formData.includeUrsa.replace(/;/g, ";")
266 + if (this.formData.notIncludeUrsa && this.formData.notIncludeUrsa != null && this.formData.notIncludeUrsa != '') {
267 + this.formData.notIncludeUrsa = this.formData.notIncludeUrsa.replace(/;/g, ";")
268 + }
269 + saveOrUpdate(this.formData).then(res => {
270 + this.loading = false
271 + if (res.code === 200) {
272 + this.msgSuccess('操作成功!')
273 + this.close()
274 + } else {
275 + this.msgWarning(res.msg)
276 + }
277 + }).catch(err => {
278 + this.loading = false
279 + console.log(err)
280 + })
281 + }
282 + })
283 + },
284 + routeChange() {
285 + this.$forceUpdate()
286 + },
287 + close() {
288 + this.formData = {
289 + flightNo: '',
290 + flightDate: '',
291 + classificationList: [],
292 + serviceCodeList: []
293 + }
294 + this.$refs["superAllocationForm"].clearValidate();
295 + this.routeList = []
296 + this.disabled = false
297 + this.$emit('close')
298 + }
299 + }
300 +}
301 +</script>
302 +
303 +<style lang="scss" scoped>
304 +
305 +</style>
...\ No newline at end of file ...\ No newline at end of file
1 +<template>
2 + <div style="padding:20px 0">
3 + <el-form class="form-header" ref="dictForm" label-width="auto" label-position="left" style="margin-bottom:10px"
4 + @submit.native.prevent size="small">
5 + <el-row>
6 + <el-col :span="6">
7 + <el-form-item label="发件人账号">
8 + <el-input type="textarea" v-model="selectionData.shipperAccount" placeholder="请输入发件人账号,多个以“;”分割"
9 + maxlength="50" rows="4" />
10 + </el-form-item>
11 + </el-col>
12 + </el-row>
13 + </el-form>
14 + <div style="margin-left:20px;margin-bottom:10px">
15 + <el-button icon="el-icon-search" type="primary" size="small" @click="selection(1)">查 询
16 + </el-button>
17 + <el-button v-hasPermi="['log:superAllocation:add']" icon="el-icon-plus" type="primary" size="small"
18 + @click="add">添 加
19 + </el-button>
20 + </div>
21 + <Tables ref="supserAllocation" ductName="supserAllocation" :data="tableData" :headerData="tableHeader"
22 + :selection="false" :order="true" :selectFixed="false" :pagination="true" :totalCount="totalCount"
23 + :loading="loading" :limitSize="selectionData.size" :page="selectionData.page"
24 + layout="total,prev, pager, next, jumper, ->" :pageSizes="[100]" :height="tableHeight"
25 + @currentChange="currentChange">
26 + <template slot="optionColumn">
27 + <el-table-column label="操作" width="250" align="center">
28 + <template slot-scope="scope">
29 + <el-button size="mini" type="text" v-if="scope.row.status != 0" icon="el-icon-edit"
30 + v-hasPermi="['log:superAllocation:update']" @click="update(scope.row, 'update')">修改
31 + </el-button>
32 + <el-button type="text" v-if="scope.row.status === 1" size="mini" icon="el-icon-video-pause"
33 + v-hasPermi="['log:superAllocation:openClose']" @click="changeStatus(scope.row)">
34 + 停 用</el-button>
35 + <el-button type="text" v-if="scope.row.status === 0" size="mini" icon="el-icon-video-pause"
36 + v-hasPermi="['log:superAllocation:openClose']" @click="changeStatus(scope.row)">
37 + 启 用</el-button>
38 + <el-button type="text" icon="el-icon-document-copy" size="mini"
39 + v-hasPermi="['log:superAllocation:copy']" @click="update(scope.row, 'copy')">复 制
40 + </el-button>
41 + <el-button size="mini" type="text" icon="el-icon-delete" style="color:#ff4949"
42 + v-hasPermi="['log:superAllocation:delete']" @click="del(scope.row)">删除</el-button>
43 + </template>
44 + </el-table-column>
45 + </template>
46 + </Tables>
47 + <Dialog :dialogVisible="dialogVisible" :ruleData="ruleData" :status="dialogStatus" @close="close" />
48 + </div>
49 +</template>
50 +
51 +<script>
52 +import { queryShipperAccountRule, changeStatusById, queryShipperAccountRuleById, getReleaseWeight } from "@/api/supserAllocation"
53 +import Dialog from './dialog.vue';
54 +
55 +export default {
56 + name: 'SuperAllocation',
57 + components: {
58 + Dialog
59 + },
60 + data() {
61 + return {
62 + selectionData: {
63 + shipperAccount: null,
64 + page: 1,
65 + size: 20,
66 + },
67 + tableData: [],
68 + tableHeader: this.tableHeaders['superAllocation'],
69 + ruleData: {
70 + classificationList: [],
71 + serviceCodeList: []
72 + },
73 + dialogStatus: 'add',
74 + tableHeight: null,
75 + totalCount: 0,
76 + dialogVisible: false,
77 + loading: false,
78 + }
79 + },
80 + created() {
81 + },
82 + mounted() {
83 + this.tableHeight = window.innerHeight - this.$refs.supserAllocation.$el.offsetHeight - 250
84 + this.selection(1)
85 + },
86 + methods: {
87 + //查询
88 + selection(val) {
89 + this.tableData = []
90 + this.loading = true
91 + if (val === 1) {
92 + this.selectionData.page = 1
93 + }
94 + queryShipperAccountRule(this.selectionData).then(res => {
95 + this.loading = false
96 + if (res.code === 200) {
97 + this.tableData = res.data.list
98 + this.totalCount = res.data.total
99 + } else {
100 + this.msgWarning(res.msg)
101 + }
102 + }).catch(err => {
103 + this.loading = false
104 + console.log(err)
105 + })
106 + },
107 + //新增
108 + add() {
109 + this.dialogStatus = 'add'
110 + this.dialogVisible = true
111 + },
112 + //修改
113 + update(val, status) {
114 + this.dialogStatus = status
115 + queryShipperAccountRuleById({ id: val.id }).then(res => {
116 + if (res.code === 200) {
117 + this.ruleData = res.data
118 + if (this.ruleData.classificationList == null || this.ruleData.classificationList.length < 1) {
119 + this.ruleData.classificationList = []
120 + }
121 + if (this.ruleData.serviceCodeList == null || this.ruleData.serviceCodeList.length < 1) {
122 + this.ruleData.serviceCodeList = []
123 + }
124 + if (status == 'copy') {
125 + this.ruleData.id = undefined
126 + }
127 + this.dialogVisible = true
128 + } else {
129 + this.msgWarning(res.msg)
130 + }
131 + }).catch(err => {
132 + console.log(err)
133 + })
134 + },
135 + //删除
136 + del(val) {
137 + getReleaseWeight({ id: val.id }).then(res => {
138 + if (res.code === 200) {
139 + this.$confirm(`是否要删除记录!预计释放舱位${res.data}`, "注意!", {
140 + confirmButtonText: "确定",
141 + cancelButtonText: '取消',
142 + type: "warning",
143 + }).then(() => {
144 + changeStatusById({ id: val.id, status: 2 }).then(res => {
145 + if (res.code === 200) {
146 + this.msgSuccess(`删除成功!已释放舱位${res.data}`)
147 + this.selection(1)
148 + } else {
149 + this.msgWarning(res.msg)
150 + }
151 + }).catch(err => {
152 + console.log(err)
153 + })
154 + }).catch(() => { })
155 + } else {
156 + this.msgWarning(res.code)
157 + }
158 + }).catch(err => {
159 + console.log(err)
160 + })
161 + },
162 + //停用启用
163 + changeStatus(val) {
164 + let status = 0
165 + let tip = ''
166 + if (val.status == 0) {
167 + status = 1
168 + tip = '启用'
169 + } else if (val.status == 1) {
170 + status = 0
171 + tip = '停用'
172 + }
173 + if (tip === "停用") {
174 + getReleaseWeight({ id: val.id }).then(res => {
175 + if (res.code === 200) {
176 + this.$confirm(`预计释放舱位为${res.data},是否确定!`, "注意!", {
177 + confirmButtonText: "确定",
178 + cancelButtonText: '取消',
179 + type: "warning",
180 + }).then(() => {
181 + this.statusChange({ id: val.id, status: status, tip: tip })
182 + }).catch(() => { })
183 + } else {
184 + this.msgWarning(res.msg)
185 + }
186 + }).catch(err => {
187 + console.log(err)
188 + })
189 + } else {
190 + this.$confirm(`是否要${tip}记录!`, "注意!", {
191 + confirmButtonText: "确定",
192 + cancelButtonText: '取消',
193 + type: "warning",
194 + }).then(() => {
195 + this.statusChange({ id: val.id, status: status, tip: tip })
196 + }).catch(() => { })
197 + }
198 + },
199 + //复制
200 + copy(val) {
201 + this.dialogStatus = 'copy'
202 + this.ruleData = JSON.parse(JSON.stringify(val))
203 + this.ruleData.id = undefined
204 + this.dialogVisible = true
205 + },
206 + //状态修改请求
207 + statusChange(val) {
208 + changeStatusById(val).then(res => {
209 + if (res.code === 200) {
210 + if (val.tip == '停用') {
211 + this.msgSuccess(`${val.tip}成功!已释放${res.data}`)
212 + } else {
213 + this.msgSuccess(`${val.tip}成功!`)
214 + }
215 + this.selection(1)
216 + } else {
217 + this.msgWarning(res.msg)
218 + }
219 + }).catch(err => {
220 + console.log(err)
221 + })
222 + },
223 + //关闭
224 + close() {
225 + this.dialogVisible = false
226 + this.ruleData = {}
227 + this.selection(1)
228 + },
229 + //翻页
230 + currentChange(val) {
231 + this.selectionData.page = val.page
232 + this.selection()
233 + },
234 + }
235 +}
236 +
237 +</script>
238 +
239 +<style lang="scss" scoped>
240 +
241 +</style>
...\ No newline at end of file ...\ No newline at end of file
1 +<template>
2 + <div>
3 + <el-form ref="archiveDataForm" class="form-header" :model="selectForm" label-width="auto" size="small"
4 + @submit.native.prevent>
5 + <el-row>
6 + <el-col :span="6">
7 + <el-form-item label="操作时间">
8 + <el-date-picker class="formItem" v-model="selectForm.dateList" type="daterange"
9 + range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期"
10 + value-format="yyyy-MM-dd" clearable>
11 + </el-date-picker>
12 + </el-form-item>
13 + </el-col>
14 + </el-row>
15 + </el-form>
16 + <div class="ml20 mb20">
17 + <el-button type="primary" size="small" icon="el-icon-search" :loading="loading" @click="selectLog(1)">查 询
18 + </el-button>
19 + </div>
20 + <Tables ref="archiveDataTables" ductName="archiveDataTables" :order="true" :border='true' :data="data"
21 + :headerData="tableHeader" tableAlign="center" :showOverflowTooltip="true" :height="tableHeight"
22 + :page="selectForm.page" :limitSize="selectForm.size" :pageSizes="[20]" :totalCount="total"
23 + :loading="loading" @currentChange="currentChange">
24 + <template v-slot:queryParameter="scope">
25 + <el-popover placement="top" width="350" trigger="hover">
26 + <ul style="height:300px;overflow-y:scroll;"
27 + v-if="scope.row.queryParameter != null && scope.row.queryParameter != ''">
28 + <li v-for="(item, index) in JSON.stringify(JSON.parse(scope.row.queryParameter)).split(',')"
29 + :key="index" style="border-bottom:1px solid #E4E7ED;margin-bottom:5px">{{ item }}</li>
30 + </ul>
31 + <el-button type="text" slot="reference">查 看</el-button>
32 + </el-popover>
33 + </template>
34 + <template v-slot:downloadPath="scope">
35 + <el-button v-if="scope.row.downloadPath != null && scope.row.status == 1" type="text" size="mini"
36 + icon="el-icon-download" @click="download(scope.row)">下载
37 + </el-button>
38 + <span v-else>暂无下载</span>
39 + </template>
40 + </Tables>
41 + </div>
42 +</template>
43 +
44 +<script>
45 +import { findArchiveCargoLog, isExistZip } from "@/api/system/logConfig.js";
46 +import { downLoadZip } from "@/utils/zipdownload";
47 +
48 +export default {
49 + data() {
50 + return {
51 + selectForm: {
52 + dateList: [],
53 + page: 1,
54 + size: 20
55 + },
56 + data: [],
57 + tableHeader: this.tableHeaders['archiveData'],
58 + tableHeight: null,
59 + total: 0,
60 + loading: false,
61 + }
62 + },
63 + created() {
64 + this.selectLog()
65 + },
66 + mounted() {
67 + this.tableHeight = window.innerHeight - this.$refs.archiveDataForm.$el.offsetHeight - 200
68 + },
69 + methods: {
70 + selectLog(val) {
71 + this.loading = true
72 + if (val == 1) {
73 + this.selectForm.page = 1
74 + }
75 + let obj = {}
76 + if (this.selectForm.dateList && this.selectForm.dateList.length > 0) {
77 + obj.createTimeStart = this.selectForm.dateList[0]
78 + obj.createTimeEnd = this.selectForm.dateList[1]
79 + }
80 + obj.page = this.selectForm.page
81 + obj.size = this.selectForm.size
82 + findArchiveCargoLog(obj).then(res => {
83 + this.loading = false
84 + if (res.code === 200) {
85 + this.data = res.data.list
86 + this.total = res.data.total
87 + } else {
88 + this.msgWarning(res.msg)
89 + }
90 + }).catch(err => {
91 + this.loading = true
92 + console.log(err)
93 + })
94 + },
95 + download(val) {
96 + isExistZip(val).then(res => {
97 + if (res.code === 200) {
98 + setTimeout(() => {
99 + let url = '/archiveCargoLog/downloadZip'
100 + let filename = val.packageName
101 + downLoadZip(url, val, filename)
102 + }, 500);
103 + } else {
104 + this.msgWarning(res.msg)
105 + }
106 + }).catch(err => {
107 + console.log(err)
108 + })
109 + },
110 + currentChange(val) {
111 + this.selectForm.page = val.page
112 + this.selectLog()
113 + }
114 + }
115 +}
116 +</script>
117 +
118 +<style lang="scss" scoped>
119 +
120 +</style>
...\ No newline at end of file ...\ No newline at end of file
...@@ -69,12 +69,19 @@ ...@@ -69,12 +69,19 @@
69 </template> 69 </template>
70 <template v-slot:flightFltNo="scope"> 70 <template v-slot:flightFltNo="scope">
71 <el-link v-if="scope.row.allocDimId" type="primary" 71 <el-link v-if="scope.row.allocDimId" type="primary"
72 - @click="$router.push({ name: 'FlightAllocConfigInfo', params: { id: scope.row.allocDimId, handle: 'detail', fltNo: scope.row.flightFltNo, fltDate: scope.row.flightFltDate ? scope.row.flightFltDate : ' ', routeStatus: 'dmLog', route: scope.row.currentFlightRoute ? scope.row.currentFlightRoute : ' ', status: ' ', createStatus: 1 } })"> 72 + @click="$router.push({ name: 'FlightAllocConfigInfo', params: { id: scope.row.allocDimId, handle: 'detail', fltNo: scope.row.flightFltNo, fltDate: scope.row.flightFltDate ? scope.row.flightFltDate : ' ', routeStatus: 'dmLog', route: scope.row.currentFlightRoute ? scope.row.currentFlightRoute : ' ', status: ' ', createStatus: 1, } })">
73 {{ 73 {{
74 scope.row.flightFltNo 74 scope.row.flightFltNo
75 }}<i class="el-icon-link"></i> </el-link> 75 }}<i class="el-icon-link"></i> </el-link>
76 <span v-else>{{ scope.row.flightFltNo }}</span> 76 <span v-else>{{ scope.row.flightFltNo }}</span>
77 </template> 77 </template>
78 + <template v-slot:remarksDetail="scope">
79 + <span v-if="scope.row.remarksDetail == null || scope.row.remarksDetail == ''">{{ scope.row.remarksDetail
80 + }}</span>
81 + <div v-else>
82 + <div v-for="item in scope.row.remarksDetail.split('\\r\\n')">{{ item }}</div>
83 + </div>
84 + </template>
78 </Tables> 85 </Tables>
79 </div> 86 </div>
80 </template> 87 </template>
...@@ -137,7 +144,7 @@ export default { ...@@ -137,7 +144,7 @@ export default {
137 getDmDataList(this.selectForm).then((res) => { 144 getDmDataList(this.selectForm).then((res) => {
138 this.loading = false; 145 this.loading = false;
139 if (res.code === 200) { 146 if (res.code === 200) {
140 - this.total = res.data.total; 147 + this.total = res.data.total
141 if (res.data.total === 0) { 148 if (res.data.total === 0) {
142 this.msgWarning('未查询到数据') 149 this.msgWarning('未查询到数据')
143 } else { 150 } else {
......
...@@ -64,6 +64,7 @@ export default { ...@@ -64,6 +64,7 @@ export default {
64 }, 64 },
65 //返回 65 //返回
66 close() { 66 close() {
67 + this.$store.dispatch('tagsView/delView', this.$route)
67 this.$store.state.tagsView.visitedViews.splice( 68 this.$store.state.tagsView.visitedViews.splice(
68 this.$store.state.tagsView.visitedViews.findIndex( 69 this.$store.state.tagsView.visitedViews.findIndex(
69 (item) => item.path === this.$route.path 70 (item) => item.path === this.$route.path
......
1 +<template>
2 + <div>
3 + <el-form ref="operationLogForm" class="form-header" :model="selectForm" label-width="auto" size="small"
4 + @submit.native.prevent>
5 + <el-row>
6 + <el-col :span="6">
7 + <el-form-item label="功能模块">
8 + <el-select v-model="selectForm.module" class="formItem" placeholder="不限" clearable>
9 + <el-option v-for="item in moduleList" :label="item" :value="item" :key="item"></el-option>
10 + </el-select>
11 + </el-form-item>
12 + </el-col>
13 + <el-col :span="6">
14 + <el-form-item label="操作描述">
15 + <el-input v-model="selectForm.describe" class="formItem" placeholder="请输入操作描述" clearable>
16 + </el-input>
17 + </el-form-item>
18 + </el-col>
19 + <el-col :span="6">
20 + <el-form-item label="操作人">
21 + <el-input v-model="selectForm.userName" class="formItem" placeholder="请输入操作人" clearable>
22 + </el-input>
23 + </el-form-item>
24 + </el-col>
25 + <el-col :span="6">
26 + <el-form-item label="操作时间">
27 + <el-date-picker class="formItem" v-model="dateList" type="daterange" range-separator="至"
28 + start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd" clearable>
29 + </el-date-picker>
30 + </el-form-item>
31 + </el-col>
32 + </el-row>
33 + </el-form>
34 + <div class="ml20 mb20">
35 + <el-button type="primary" size="small" icon="el-icon-search" :loading="loading" @click="selectLog(1)">查 询
36 + </el-button>
37 + </div>
38 + <Tables ref="operationLogTables" ductName="operationLogTables" :order="true" :border='false' :data="data"
39 + :headerData="tableHeader" tableAlign="center" :showOverflowTooltip="true" :height="tableHeight"
40 + :page="selectForm.page" :limitSize="selectForm.size" :pageSizes="[100]" :totalCount="total"
41 + :loading="loading" @currentChange="currentChange">
42 + <template v-slot:result="scope">
43 + <span>
44 + {{ scope.row.result != null && typeof JSON.parse(scope.row.result) == 'object' ?
45 + JSON.parse(scope.row.result).msg :
46 + scope.row.result
47 + }}
48 + </span>
49 + </template>
50 + <template v-slot:remark="scope">
51 + <el-popover placement="top" width="400" trigger="hover"
52 + v-if="scope.row.remark != null && scope.row.remark != ''">
53 + <ul style="height:300px;overflow-y:scroll;">
54 + <li v-for="(item, index) in scope.row.remark.split('\n')" :key="index"
55 + style="border-bottom:1px solid #E4E7ED;margin-bottom:5px">{{ item }}</li>
56 + </ul>
57 + <el-button type="text" slot="reference">查 看</el-button>
58 + </el-popover>
59 + </template>
60 + <template v-slot:requestParameters="scope">
61 + <el-popover placement="top" width="400" trigger="hover"
62 + v-if="scope.row.requestParameters != null && scope.row.requestParameters != ''">
63 + <ul style="height:300px;overflow-y:scroll;">
64 + <li v-for="(item, index) in JSON.stringify(JSON.parse(scope.row.requestParameters)).split(',')"
65 + :key="index" style="border-bottom:1px solid #E4E7ED;margin-bottom:5px">{{ item }}</li>
66 + </ul>
67 + <el-button type="text" slot="reference">查 看</el-button>
68 + </el-popover>
69 + </template>
70 + </Tables>
71 + </div>
72 +</template>
73 +
74 +<script>
75 +import { findModuleCondition, getSystemOperationLogData } from "@/api/system/logConfig.js";
76 +
77 +export default {
78 + name: 'OperationLog',
79 + data() {
80 + return {
81 + selectForm: {
82 + module: null,
83 + describe: null,
84 + userName: null,
85 + page: 1,
86 + size: 100
87 + },
88 + data: [],
89 + tableHeader: this.tableHeaders['operationLog'],
90 + moduleList: [],
91 + dateList: [],
92 + defaultProps: {
93 + children: 'children',
94 + label: 'label'
95 + },
96 + tableHeight: null,
97 + total: 0,
98 + loading: false
99 + }
100 + },
101 + created() {
102 + this.getModule()
103 + this.selectLog(1)
104 + },
105 + activated() {
106 + this.selectLog();
107 + },
108 + mounted() {
109 + this.tableHeight = window.innerHeight - this.$refs.operationLogForm.$el.offsetHeight - 240
110 + },
111 + methods: {
112 + getModule() {
113 + findModuleCondition().then(res => {
114 + if (res.code === 200) {
115 + this.moduleList = res.data.module
116 + } else {
117 + this.msgWarning(res.msg)
118 + }
119 + }).catch(err => {
120 + console.log(err)
121 + })
122 + },
123 + selectLog(val) {
124 + this.loading = true
125 + this.data = []
126 + if (val == 1) {
127 + this.selectForm.page = 1
128 + }
129 + let obj = {}
130 + obj.module = this.selectForm.module
131 + if (this.dateList && this.dateList.length > 0) {
132 + obj.createTimeStart = this.dateList[0]
133 + obj.createTimeEnd = this.dateList[1]
134 + } else {
135 + obj.createTimeStart = null
136 + obj.createTimeEnd = null
137 + }
138 + obj.describe = this.selectForm.describe
139 + obj.userName = this.selectForm.userName
140 + obj.page = this.selectForm.page
141 + obj.size = this.selectForm.size
142 + getSystemOperationLogData(obj).then(res => {
143 + this.loading = false
144 + if (res.code === 200) {
145 + this.data = res.data.list
146 + this.total = res.data.total
147 + } else {
148 + this.msgWarning(res.msg)
149 + }
150 + }).catch(err => {
151 + this.loading = false
152 + console.log(err)
153 + })
154 + },
155 + currentChange(val) {
156 + this.selectForm.page = val.page
157 + this.selectLog()
158 + }
159 + }
160 +}
161 +
162 +</script>
163 +
164 +<style lang="scss" scoped>
165 +
166 +</style>
...\ No newline at end of file ...\ No newline at end of file