Commit 2c711627 authored by 邓晓峰's avatar 邓晓峰

fix: gitlab-ci.yml

parent 4bfa0ce4
Pipeline #22188 passed with stages
in 27 minutes 50 seconds
......@@ -13,7 +13,7 @@ stages:
install:
stage: install
script:
- npm install
- npm run init
cache:
key: ${CI_COMMIT_REF_SLUG}
paths:
......
......@@ -25,11 +25,5 @@ export default {
activeRule: genActiveRule('/civbase/civweb4'),
props: {},
},
// {
// name: 'civweb5',
// entry: `//${window.location.host}/civweb5`,
// container: '#micro-container',
// activeRule: genActiveRule('/civbase/civweb5'),
// },
],
};
......@@ -34,6 +34,20 @@ module.exports = {
'/cityinterface': '/cityinterface',
},
},
'/cityjson': {
target: 'https://pv.sohu.com',
// target: 'http://192.168.19.102:8055',
// target: 'https://panda-water.com',
// target: 'http://192.168.12.8:8098',
// target: 'http://192.168.10.20:8888',
changeOrigin: true,
headers: {
'Access-Control-Allow-Origin': '*',
},
pathRewrite: {
'/cityjson': '/cityjson',
},
},
'/Publish': {
// target: 'http://192.168.12.8:8098',
// target: 'http://192.168.10.20:8888',
......
......@@ -231,9 +231,9 @@
}
},
"@ant-design/react-slick": {
"version": "0.27.14",
"resolved": "https://g.civnet.cn:4873/@ant-design%2freact-slick/-/react-slick-0.27.14.tgz",
"integrity": "sha1-oQgsRzTlfHupxB0DU3X1v1d/O14=",
"version": "0.28.1",
"resolved": "https://g.civnet.cn:4873/@ant-design%2freact-slick/-/react-slick-0.28.1.tgz",
"integrity": "sha1-Lgcgg4y1eriBg4TcyWsqjGH80B4=",
"dev": true,
"requires": {
"@babel/runtime": "^7.10.4",
......@@ -7151,14 +7151,29 @@
}
},
"@wisdom-utils/components": {
"version": "0.0.4",
"resolved": "https://g.civnet.cn:4873/@wisdom-utils%2fcomponents/-/components-0.0.4.tgz",
"integrity": "sha512-+G/0eSHsney5VePzjAPmXcW8xKclUnac+h+Xi7xxXAfHGYn8ruYj4a3eT9XcnvqDSHvEHSIRH23a8weTdIDjzw=="
"version": "0.0.6",
"resolved": "https://g.civnet.cn:4873/@wisdom-utils%2fcomponents/-/components-0.0.6.tgz",
"integrity": "sha512-OX62BwTK3LGDxOz+H2eX/HbOs6ALDdZA6LDGkSMHGShbVPQvXl/RyGwn9nGIV3cHMI0dDc5MF/2mNaLDs1A6WQ==",
"requires": {
"react": "^16.14.0"
},
"dependencies": {
"react": {
"version": "16.14.0",
"resolved": "https://g.civnet.cn:4873/react/-/react-16.14.0.tgz",
"integrity": "sha512-0X2CImDkJGApiAlcf0ODKIneSwBPhqJawOa5wCtKbu7ZECrmS26NvtSILynQ66cgkT/RJ4LidJOc3bUESwmU8g==",
"requires": {
"loose-envify": "^1.1.0",
"object-assign": "^4.1.1",
"prop-types": "^15.6.2"
}
}
}
},
"@wisdom-utils/utils": {
"version": "0.0.19",
"resolved": "https://g.civnet.cn:4873/@wisdom-utils%2futils/-/utils-0.0.19.tgz",
"integrity": "sha512-Y8zEIaDfZ/D0M8sb0KJoikRoT/x7rUKrbxC8UZkNwmrQqm+yyALPV2GqfTXYHHYCvgQ+zpD/E3uP3leKCAJ97Q==",
"version": "0.0.23",
"resolved": "https://g.civnet.cn:4873/@wisdom-utils%2futils/-/utils-0.0.23.tgz",
"integrity": "sha512-NhRZIySKvS8ooVuuFsPtYJi+hsmu3r5UAT1rFyPZYxjmegva/taSK4viRQs1BarUpBIMwF0vIZakkhoXRlbz/w==",
"requires": {
"axios": "^0.21.1",
"cookie": "^0.4.1",
......@@ -7171,24 +7186,11 @@
"query-string": "^6.13.8"
},
"dependencies": {
"axios": {
"version": "0.21.1",
"resolved": "https://g.civnet.cn:4873/axios/-/axios-0.21.1.tgz",
"integrity": "sha1-IlY0gZYvTWvemnbVFu8OXTwJsrg=",
"requires": {
"follow-redirects": "^1.10.0"
}
},
"cookie": {
"version": "0.4.1",
"resolved": "https://g.civnet.cn:4873/cookie/-/cookie-0.4.1.tgz",
"integrity": "sha512-ZwrFkGJxUR3EIoXtO+yVE69Eb7KlixbaeAWfBQB9vVsNn/o+Yw69gBWSSDK825hQNdN+wF8zELf3dFNl/kxkUA=="
},
"follow-redirects": {
"version": "1.13.1",
"resolved": "https://g.civnet.cn:4873/follow-redirects/-/follow-redirects-1.13.1.tgz",
"integrity": "sha1-X2m4Ezds7k/QR0o6uoNd8Eq3Y7c="
},
"query-string": {
"version": "6.13.8",
"resolved": "https://g.civnet.cn:4873/query-string/-/query-string-6.13.8.tgz",
......@@ -7542,14 +7544,14 @@
"dev": true
},
"antd": {
"version": "4.9.4",
"resolved": "https://g.civnet.cn:4873/antd/-/antd-4.9.4.tgz",
"integrity": "sha1-EpCSvEpnx3QUXLJFDkBG0noay7E=",
"version": "4.10.1",
"resolved": "https://g.civnet.cn:4873/antd/-/antd-4.10.1.tgz",
"integrity": "sha1-rTkPU11D5+HULTFrPULZ4PbkJiY=",
"dev": true,
"requires": {
"@ant-design/colors": "^5.0.0",
"@ant-design/icons": "^4.3.0",
"@ant-design/react-slick": "~0.27.0",
"@ant-design/react-slick": "~0.28.1",
"@babel/runtime": "^7.11.2",
"array-tree-filter": "^2.1.0",
"classnames": "^2.2.6",
......@@ -7560,33 +7562,33 @@
"rc-cascader": "~1.4.0",
"rc-checkbox": "~2.3.0",
"rc-collapse": "~3.1.0",
"rc-dialog": "~8.4.0",
"rc-drawer": "~4.1.0",
"rc-dialog": "~8.5.1",
"rc-drawer": "~4.2.0",
"rc-dropdown": "~3.2.0",
"rc-field-form": "~1.17.0",
"rc-image": "~4.2.0",
"rc-field-form": "~1.17.3",
"rc-image": "~5.0.2",
"rc-input-number": "~6.1.0",
"rc-mentions": "~1.5.0",
"rc-menu": "~8.10.0",
"rc-motion": "^2.4.0",
"rc-notification": "~4.5.2",
"rc-pagination": "~3.1.2",
"rc-picker": "~2.4.1",
"rc-picker": "~2.5.1",
"rc-progress": "~3.1.0",
"rc-rate": "~2.9.0",
"rc-resize-observer": "^0.2.3",
"rc-select": "~11.5.3",
"rc-slider": "~9.6.1",
"rc-resize-observer": "^1.0.0",
"rc-select": "~12.1.0",
"rc-slider": "~9.7.1",
"rc-steps": "~4.1.0",
"rc-switch": "~3.2.0",
"rc-table": "~7.11.0",
"rc-table": "~7.12.0",
"rc-tabs": "~11.7.0",
"rc-textarea": "~0.3.0",
"rc-tooltip": "~5.0.0",
"rc-tree": "~4.0.0",
"rc-tree-select": "~4.2.0",
"rc-upload": "~3.3.1",
"rc-util": "^5.1.0",
"rc-tree": "~4.1.0",
"rc-tree-select": "~4.3.0",
"rc-upload": "~3.3.4",
"rc-util": "^5.6.6",
"scroll-into-view-if-needed": "^2.2.25",
"warning": "^4.0.3"
},
......@@ -7596,6 +7598,29 @@
"resolved": "https://g.civnet.cn:4873/lodash/-/lodash-4.17.20.tgz",
"integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==",
"dev": true
},
"rc-resize-observer": {
"version": "1.0.0",
"resolved": "https://g.civnet.cn:4873/rc-resize-observer/-/rc-resize-observer-1.0.0.tgz",
"integrity": "sha1-l/uJhW9i/sMqtuQJM5Nc9Y4uEC0=",
"dev": true,
"requires": {
"@babel/runtime": "^7.10.1",
"classnames": "^2.2.1",
"rc-util": "^5.0.0",
"resize-observer-polyfill": "^1.5.1"
}
},
"rc-util": {
"version": "5.6.6",
"resolved": "https://g.civnet.cn:4873/rc-util/-/rc-util-5.6.6.tgz",
"integrity": "sha1-YmMqirMdzEdNKO/5qlw/8kBeEUY=",
"dev": true,
"requires": {
"@babel/runtime": "^7.12.5",
"react-is": "^16.12.0",
"shallowequal": "^1.1.0"
}
}
}
},
......@@ -7994,12 +8019,18 @@
"dev": true
},
"axios": {
"version": "0.19.2",
"resolved": "https://g.civnet.cn:4873/axios/-/axios-0.19.2.tgz",
"integrity": "sha512-fjgm5MvRHLhx+osE2xoekY70AhARk3a6hkN+3Io1jc00jtquGvxYlKlsFUhmUET0V5te6CcZI7lcv2Ym61mjHA==",
"dev": true,
"version": "0.21.1",
"resolved": "https://g.civnet.cn:4873/axios/-/axios-0.21.1.tgz",
"integrity": "sha1-IlY0gZYvTWvemnbVFu8OXTwJsrg=",
"requires": {
"follow-redirects": "1.5.10"
"follow-redirects": "^1.10.0"
},
"dependencies": {
"follow-redirects": {
"version": "1.13.1",
"resolved": "https://g.civnet.cn:4873/follow-redirects/-/follow-redirects-1.13.1.tgz",
"integrity": "sha1-X2m4Ezds7k/QR0o6uoNd8Eq3Y7c="
}
}
},
"axobject-query": {
......@@ -11291,9 +11322,9 @@
"dev": true
},
"dayjs": {
"version": "1.9.7",
"resolved": "https://g.civnet.cn:4873/dayjs/-/dayjs-1.9.7.tgz",
"integrity": "sha1-SyYLsX3O7S1fKQON/uA8ZaZ4b8A=",
"version": "1.10.3",
"resolved": "https://g.civnet.cn:4873/dayjs/-/dayjs-1.10.3.tgz",
"integrity": "sha1-zzNXyOf1CEMoJjcWcuvzdst9YZs=",
"dev": true
},
"debug": {
......@@ -18658,13 +18689,15 @@
"dev": true
},
"kit_global_config": {
"version": "1.0.12",
"resolved": "https://g.civnet.cn:4873/kit_global_config/-/kit_global_config-1.0.12.tgz",
"integrity": "sha512-gFp7NhmlLsNE2V8QC7b1NKVUeWmPSDH8EUlbfEH5/9Y6Zzydsyy2bJEdbXmHf3N8/6Yb7W0IpdOZqdtB7KEf6A==",
"version": "1.0.19",
"resolved": "https://g.civnet.cn:4873/kit_global_config/-/kit_global_config-1.0.19.tgz",
"integrity": "sha512-6BtvJHZV3B7DWPmiKkZXpvtel5BLgn8XC4ruBVTvZpHIUammkJLubYyNk7oA00TXZITJ1SD9AkuZNvNC2lOayg==",
"requires": {
"@babel/runtime": "^7.10.5",
"js-base64": "^3.5.2",
"kit_utils": "^1.3.6"
"kit_utils": "^1.3.6",
"lodash.get": "^4.4.2",
"lodash.set": "^4.3.2"
}
},
"kit_logger": {
......@@ -19438,8 +19471,7 @@
"lodash.get": {
"version": "4.4.2",
"resolved": "https://g.civnet.cn:4873/lodash.get/-/lodash.get-4.4.2.tgz",
"integrity": "sha1-LRd/ZS+jHpObRDjVNBSZ36OCXpk=",
"dev": true
"integrity": "sha1-LRd/ZS+jHpObRDjVNBSZ36OCXpk="
},
"lodash.isequal": {
"version": "4.5.0",
......@@ -19464,6 +19496,11 @@
"integrity": "sha1-vMbEmkKihA7Zl/Mj6tpezRguC/4=",
"dev": true
},
"lodash.set": {
"version": "4.3.2",
"resolved": "https://g.civnet.cn:4873/lodash.set/-/lodash.set-4.3.2.tgz",
"integrity": "sha1-2HV7HagH3eJIFrDWqEvqGnYjCyM="
},
"lodash.snakecase": {
"version": "4.1.1",
"resolved": "https://g.civnet.cn:4873/lodash.snakecase/-/lodash.snakecase-4.1.1.tgz",
......@@ -24711,11 +24748,12 @@
}
},
"rc-cascader": {
"version": "1.4.0",
"resolved": "https://g.civnet.cn:4873/rc-cascader/-/rc-cascader-1.4.0.tgz",
"integrity": "sha512-6kgQljDQEKjVAVRkZtvvoi+2qv4u42M6oLuvt4ZDBa16r3X9ZN8TAq3atVyC840ivbGKlHT50OcdVx/iwiHc1w==",
"version": "1.4.2",
"resolved": "https://g.civnet.cn:4873/rc-cascader/-/rc-cascader-1.4.2.tgz",
"integrity": "sha1-yqgQmOPvTV+CP5FW9tjW29YyGvo=",
"dev": true,
"requires": {
"@babel/runtime": "^7.12.5",
"array-tree-filter": "^2.1.0",
"rc-trigger": "^5.0.4",
"rc-util": "^5.0.1",
......@@ -24746,26 +24784,26 @@
}
},
"rc-dialog": {
"version": "8.4.6",
"resolved": "https://g.civnet.cn:4873/rc-dialog/-/rc-dialog-8.4.6.tgz",
"integrity": "sha1-ag/4FVObaOcFy50vyUCjgQOdET8=",
"version": "8.5.1",
"resolved": "https://g.civnet.cn:4873/rc-dialog/-/rc-dialog-8.5.1.tgz",
"integrity": "sha1-3zFt2T4WhdffH15BZO41y6Spr4g=",
"dev": true,
"requires": {
"@babel/runtime": "^7.10.1",
"classnames": "^2.2.6",
"rc-motion": "^2.3.0",
"rc-util": "^5.0.1"
"rc-util": "^5.6.1"
}
},
"rc-drawer": {
"version": "4.1.0",
"resolved": "https://g.civnet.cn:4873/rc-drawer/-/rc-drawer-4.1.0.tgz",
"integrity": "sha512-kjeQFngPjdzAFahNIV0EvEBoIKMOnvUsAxpkSPELoD/1DuR4nLafom5ryma+TIxGwkFJ92W6yjsMi1U9aiOTeQ==",
"version": "4.2.0",
"resolved": "https://g.civnet.cn:4873/rc-drawer/-/rc-drawer-4.2.0.tgz",
"integrity": "sha1-AqYrXwF3/URf+2QZFn4vZ8yegvM=",
"dev": true,
"requires": {
"@babel/runtime": "^7.10.1",
"classnames": "^2.2.6",
"rc-util": "^5.0.1"
"rc-util": "^5.6.2"
}
},
"rc-dropdown": {
......@@ -24791,15 +24829,14 @@
}
},
"rc-image": {
"version": "4.2.0",
"resolved": "https://g.civnet.cn:4873/rc-image/-/rc-image-4.2.0.tgz",
"integrity": "sha1-O3qXf57PusBGKWwpCNmcsfh5XGU=",
"version": "5.0.2",
"resolved": "https://g.civnet.cn:4873/rc-image/-/rc-image-5.0.2.tgz",
"integrity": "sha1-WwCzIB70u5748Ypv/mByQBHzy6M=",
"dev": true,
"requires": {
"@ant-design/icons": "^4.2.2",
"@babel/runtime": "^7.11.2",
"classnames": "^2.2.6",
"rc-dialog": "~8.4.0",
"rc-dialog": "~8.5.1",
"rc-util": "^5.0.6"
}
},
......@@ -24868,10 +24905,36 @@
"rc-util": "^5.0.1"
}
},
"rc-overflow": {
"version": "1.0.2",
"resolved": "https://g.civnet.cn:4873/rc-overflow/-/rc-overflow-1.0.2.tgz",
"integrity": "sha1-9WvNkgApl5mJ9XbVUIS4H5YywZw=",
"dev": true,
"requires": {
"@babel/runtime": "^7.11.1",
"classnames": "^2.2.1",
"rc-resize-observer": "^1.0.0",
"rc-util": "^5.5.1"
},
"dependencies": {
"rc-resize-observer": {
"version": "1.0.0",
"resolved": "https://g.civnet.cn:4873/rc-resize-observer/-/rc-resize-observer-1.0.0.tgz",
"integrity": "sha1-l/uJhW9i/sMqtuQJM5Nc9Y4uEC0=",
"dev": true,
"requires": {
"@babel/runtime": "^7.10.1",
"classnames": "^2.2.1",
"rc-util": "^5.0.0",
"resize-observer-polyfill": "^1.5.1"
}
}
}
},
"rc-pagination": {
"version": "3.1.2",
"resolved": "https://g.civnet.cn:4873/rc-pagination/-/rc-pagination-3.1.2.tgz",
"integrity": "sha1-q16s2cUfhp41DSJFBkur6RvB8EY=",
"version": "3.1.3",
"resolved": "https://g.civnet.cn:4873/rc-pagination/-/rc-pagination-3.1.3.tgz",
"integrity": "sha1-r9d5g5/vqyyxQkjV57dAJ5YLtIs=",
"dev": true,
"requires": {
"@babel/runtime": "^7.10.1",
......@@ -24879,9 +24942,9 @@
}
},
"rc-picker": {
"version": "2.4.3",
"resolved": "https://g.civnet.cn:4873/rc-picker/-/rc-picker-2.4.3.tgz",
"integrity": "sha1-rRXuHYXks+IT7GYhXs055qCb6ZU=",
"version": "2.5.2",
"resolved": "https://g.civnet.cn:4873/rc-picker/-/rc-picker-2.5.2.tgz",
"integrity": "sha1-NtkbjN3b+LJHSvKcKFO3dQKn+wE=",
"dev": true,
"requires": {
"@babel/runtime": "^7.10.1",
......@@ -24895,9 +24958,9 @@
}
},
"rc-progress": {
"version": "3.1.1",
"resolved": "https://g.civnet.cn:4873/rc-progress/-/rc-progress-3.1.1.tgz",
"integrity": "sha512-1ns3pW7ll9bHfdXtlVLF+vngdvlxiCDtiqwXnZFEdurst11JTiPxVdeqnCNbhWx5hP4kCKkAPqG1N0FVfTSUGA==",
"version": "3.1.3",
"resolved": "https://g.civnet.cn:4873/rc-progress/-/rc-progress-3.1.3.tgz",
"integrity": "sha1-132P0m2dlI1ywqKLZLcabobfJCY=",
"dev": true,
"requires": {
"@babel/runtime": "^7.10.1",
......@@ -24928,24 +24991,24 @@
}
},
"rc-select": {
"version": "11.5.3",
"resolved": "https://g.civnet.cn:4873/rc-select/-/rc-select-11.5.3.tgz",
"integrity": "sha1-aCkT82aVlvt5TitKXGGZdMWrRdE=",
"version": "12.1.0",
"resolved": "https://g.civnet.cn:4873/rc-select/-/rc-select-12.1.0.tgz",
"integrity": "sha1-jaiVKOpBMscSCPlTp+deoc1Pi98=",
"dev": true,
"requires": {
"@babel/runtime": "^7.10.1",
"classnames": "2.x",
"rc-motion": "^2.0.1",
"rc-overflow": "^1.0.0",
"rc-trigger": "^5.0.4",
"rc-util": "^5.0.1",
"rc-virtual-list": "^3.2.0",
"warning": "^4.0.3"
"rc-virtual-list": "^3.2.0"
}
},
"rc-slider": {
"version": "9.6.5",
"resolved": "https://g.civnet.cn:4873/rc-slider/-/rc-slider-9.6.5.tgz",
"integrity": "sha1-gmzXumnYfEiyWLqjQiolt/jFYgw=",
"version": "9.7.1",
"resolved": "https://g.civnet.cn:4873/rc-slider/-/rc-slider-9.7.1.tgz",
"integrity": "sha1-Y1NRd6dKPuRPCQkJ6Mb5hCbrnbo=",
"dev": true,
"requires": {
"@babel/runtime": "^7.10.1",
......@@ -24978,16 +25041,30 @@
}
},
"rc-table": {
"version": "7.11.3",
"resolved": "https://g.civnet.cn:4873/rc-table/-/rc-table-7.11.3.tgz",
"integrity": "sha1-o1KiImZLG3Rvhy+zXGemeTTXPqs=",
"version": "7.12.3",
"resolved": "https://g.civnet.cn:4873/rc-table/-/rc-table-7.12.3.tgz",
"integrity": "sha1-yG6TtA3D4riq6eVK16paZP99Jh4=",
"dev": true,
"requires": {
"@babel/runtime": "^7.10.1",
"classnames": "^2.2.5",
"rc-resize-observer": "^0.2.0",
"rc-resize-observer": "^1.0.0",
"rc-util": "^5.4.0",
"shallowequal": "^1.1.0"
},
"dependencies": {
"rc-resize-observer": {
"version": "1.0.0",
"resolved": "https://g.civnet.cn:4873/rc-resize-observer/-/rc-resize-observer-1.0.0.tgz",
"integrity": "sha1-l/uJhW9i/sMqtuQJM5Nc9Y4uEC0=",
"dev": true,
"requires": {
"@babel/runtime": "^7.10.1",
"classnames": "^2.2.1",
"rc-util": "^5.0.0",
"resize-observer-polyfill": "^1.5.1"
}
}
}
},
"rc-tabs": {
......@@ -25055,9 +25132,9 @@
}
},
"rc-tree": {
"version": "4.0.0",
"resolved": "https://g.civnet.cn:4873/rc-tree/-/rc-tree-4.0.0.tgz",
"integrity": "sha1-L5crSl4j6hffBeyffsQ941C+o78=",
"version": "4.1.1",
"resolved": "https://g.civnet.cn:4873/rc-tree/-/rc-tree-4.1.1.tgz",
"integrity": "sha1-1A9BizG3XmGIbjlpSB3xREIyyYs=",
"dev": true,
"requires": {
"@babel/runtime": "^7.10.1",
......@@ -25068,14 +25145,14 @@
}
},
"rc-tree-select": {
"version": "4.2.0",
"resolved": "https://g.civnet.cn:4873/rc-tree-select/-/rc-tree-select-4.2.0.tgz",
"integrity": "sha1-yhkWOyzP4Hcv17gUgmbd3Rl9D+E=",
"version": "4.3.0",
"resolved": "https://g.civnet.cn:4873/rc-tree-select/-/rc-tree-select-4.3.0.tgz",
"integrity": "sha1-cUpP5liqc/KnsKpL1uQ75jGUps4=",
"dev": true,
"requires": {
"@babel/runtime": "^7.10.1",
"classnames": "2.x",
"rc-select": "^11.1.1",
"rc-select": "^12.0.0",
"rc-tree": "^4.0.0",
"rc-util": "^5.0.5"
}
......@@ -13,6 +13,7 @@
"author": "dengxiaofeng",
"license": "MIT",
"scripts": {
"init": "npm install --registry=https://g.civnet.cn:4873",
"analyze:clean": "rimraf stats.json",
"preanalyze": "npm run analyze:clean",
"analyze": "node ./internals/scripts/analyze.js",
......@@ -84,8 +85,8 @@
"dependencies": {
"@babel/polyfill": "7.4.3",
"@babel/runtime": "^7.10.5",
"@wisdom-utils/components": "0.0.4",
"@wisdom-utils/utils": "0.0.19",
"@wisdom-utils/components": "0.0.6",
"@wisdom-utils/utils": "0.0.23",
"animate.css": "^4.1.1",
"chalk": "2.4.2",
"compression": "1.7.4",
......@@ -101,7 +102,7 @@
"ip": "1.1.5",
"js-base64": "^3.5.2",
"js-cookie": "^2.2.1",
"kit_global_config": "^1.0.12",
"kit_global_config": "^1.0.19",
"kit_logger": "^1.0.2",
"kit_utils": "^1.3.6",
"lodash": "4.17.11",
......@@ -149,8 +150,7 @@
"@umijs/fabric": "^2.2.0",
"@umijs/hooks": "^1.9.3",
"add-asset-html-webpack-plugin": "3.1.3",
"antd": "^4.9.4",
"axios": "^0.19.2",
"antd": "^4.10.1",
"babel-core": "7.0.0-bridge.0",
"babel-eslint": "10.0.1",
"babel-loader": "8.0.5",
......
import baseService from './service/base';
import notificationService from './service/notification';
export { baseService, notificationService };
......@@ -11,7 +11,8 @@ export const API = {
GET_USER_INFO: '/CityInterface/rest/services.svc/getUserInfo',
GET_OA: '/CityInterface/rest/services/OA.svc/getLoginInfo',
GET_LOGS: '/CityInterface/rest/services/portal.svc/OMMonitor/SaveLoginInfo',
GET_CITY: 'https://pv.sohu.com/cityjson?ie=utf-8',
//https://pv.sohu.com
GET_CITY: '/cityjson?ie=utf-8',
GET_ALL_GROUPS_INFO_FORUSER:
'CityInterface/rest/Services/Portal.svc/AuthorityManage/GetAllGroupsInfoForUser',
GET_WEATHER: '/CityInterface/rest/services/CountyProduct.svc/GetWeather',
......
......@@ -94,6 +94,9 @@ const initGlobalConfig = () => {
actionCreators.getConfig(
Object.assign({}, data, {
hasGateWay,
apiGatewayDomain: `${
window.location.origin
}/Publish/GateWay`,
}),
),
);
......
......@@ -139,16 +139,22 @@ const GlobalHeaderRight = props => {
const goHome = event => {
event.stopPropagation();
const url = _.isString(props.global.homepage)
? props.global.homepage
: props.global.homepage.url;
props.global.homepage ? props.history.replace(`/civweb4/${url}`) : null;
const url = _.isString(props.global.get('homepage'))
? props.global.get('homepage')
: props.global.get('homepage.url');
// // props.history.replace(`/civweb4/${url}`)
url ? (
window.share.event.emit('listenerMointer', {
label: '首页',
url: url,
})
) : null;
};
const handleOrder = event => {
event.stopPropagation();
const widgetConfig = getConfig(
props.global.widgets.concat(props.global.uiwidgets),
props.global.get('widgets').concat(props.global.get('uiwidgets')),
MESSAGE_BOX_URL,
'url',
);
......
......@@ -146,18 +146,10 @@ const SearchPanel = props => {
const handlerMore = event => {
event.persist && event.persist();
event && event.nativeEvent.stopImmediatePropagation();
setVisible(true);
setVisible(!visible);
props.onClose && props.onClose(event);
};
// const historyProduct = (event, item) => {
// event.persist && event.persist()
// event && event.stopPropagation();
// const findIndex = props.menu.findIndex(k => k.name === item.name);
// props.updateCurrentIndex && props.updateCurrentIndex(findIndex);
// }
const handlerDelHistory = () => {
props.clearRecentProduct && props.clearRecentProduct();
};
......@@ -353,16 +345,14 @@ const SearchPanel = props => {
</>
)}
</div>
{visible ? (
<Modal
visible={visible}
triggerElRef={props.target}
{...props}
matchValue={matchValue}
goFeature={goFeature}
goProduct={goProduct}
/>
) : null}
<Modal
visible={visible}
triggerElRef={props.target}
{...props}
matchValue={matchValue}
goFeature={goFeature}
goProduct={goProduct}
/>
</div>
);
};
......
......@@ -22,6 +22,7 @@ import {
} from './constants';
import createMessage from './message';
import service from '../../api/service/notification';
import { isJSON } from '../../utils/utils';
/* eslint-disable */
// eslint-disable-next-line no-undef
const Logger = logger('mqtt');
......@@ -627,7 +628,7 @@ class Notifier {
: '刚刚';
const message = {
id: hisMessage.HisID,
infoContent: this._siteConfig.MessageLevel === DEFAULT_PARSE_LEVEL ? hisMessage.InfoContent: JSON.parse(hisMessage.InfoContent),
infoContent: this._siteConfig.MessageLevel === DEFAULT_PARSE_LEVEL ? hisMessage.InfoContent: isJSON(hisMessage.InfoContent) ? JSON.parse(hisMessage.InfoContent): hisMessage.InfoContent,
time: `${timeMss}`,
infoType: this.getMessageType(hisMessage.InfoType),
dateTime: hisMessage.HisCreateTime,
......
import { Tabs } from 'antd';
import { Sticky } from 'react-sticky';
import React from 'react';
import React, { useState, useRef, useCallback } from 'react';
import { useHistory, useLocation } from 'react-router-dom';
const TabPanes = props => {
const [activeKey, setActiveKey] = useState('');
const [panes, setPanes] = useState([
{
title: '首页',
key: 'home',
closable: false,
path: '/',
},
]);
const { TabPane } = Tabs;
const [isReload, setIsReload] = useState(false);
const [selectedPanel, setSelectedPanel] = useState({});
const pathRef = useRef(null);
const renderTabBar = (props, DefaultTabBar) => (
<Sticky bottomOffset={80}>
{({ stylle }) => <DefaultTabBar {...props} style={{ ...stylle }} />}
</Sticky>
);
const {
storeData: { curTab, reloadPath },
setStoreData,
defaultActiveKey,
panesItem,
tabActiveKey,
} = props;
const TabRoute = () => {};
const history = useHistory();
const { pathnname, search } = useLocation();
const fullPath = pathnname + search;
const storeTabs = useCallback(
ps => {
const pathArr = ps.reduce((prev, next) => [...prev, next.path], []);
// setStoreData('SET_CURTAB', pathArr)
},
[setStoreData],
);
const resetTabs = useCallback(() => {
const initPanes = curTab.reduce((prev, next) => {});
});
};
......@@ -13,8 +13,8 @@ import Icon, {
import Draggable from './draggable';
import styles from './index.less';
const { TabPane } = Tabs;
//
// const { TabPane } = Tabs;
const HistorySvg = () => (
<svg
className="icon"
......@@ -54,7 +54,7 @@ function itemRender(current, type, originalElement) {
}
const Modal = props => {
const dragRef = useRef(null);
const [isWidgetShow, setIsWidgetShow] = useState(false);
const [isWidgetShow, setIsWidgetShow] = useState(props.visible);
const [keyword, setKeyWord] = useState(props.value);
const [searchProduct, setSearchProduct] = useState([]);
// const [tabIndex]
......@@ -97,6 +97,10 @@ const Modal = props => {
});
setFasts(searchResult);
}, [keyword]);
useEffect(() => {
setIsWidgetShow(props.visible);
}, [props.visible]);
const transformSearchHistory = () => {
const label = keyword !== '' ? '你是不是想搜:' : '搜索历史:';
const data = keyword !== '' ? searchProduct : recentKeywords;
......@@ -243,60 +247,61 @@ const Modal = props => {
setKeyWord(value);
};
const onClose = () => {
setIsWidgetShow(true);
setIsWidgetShow(false);
};
if (isWidgetShow) {
if (!isWidgetShow) {
return null;
}
const children = (
<Draggable
dragHandleClassName={styles.header}
default={Object.assign(
Object.assign({}, target),
{},
{
width: 420,
height: 680,
},
)}
bounds="window"
minHeight={400}
minWidth={360}
enableUserSelectHack={false}
>
<div className={styles['base-wedget']} ref={dragRef}>
<div className={styles.header}>
搜索更多
{/* eslint-disable-next-line react/button-has-type */}
<button
className={classNames(styles.btn, styles.close)}
onClick={onClose}
>
<CloseOutlined />
</button>
</div>
<div className={styles.body}>
<div className={styles.search}>
<AutoComplete
options={transformSearchHistory()}
dropdownClassName={styles.searchList}
value={keyword}
onSelect={onSelect}
onSearch={handleSearch}
onChange={handleChange}
onFocus={handleFocus}
if (props.visible) {
const children = (
<Draggable
dragHandleClassName={styles.header}
default={Object.assign(
Object.assign({}, target),
{},
{
width: 420,
height: 680,
},
)}
bounds="window"
minHeight={400}
minWidth={360}
enableUserSelectHack={false}
>
<div className={styles['base-wedget']} ref={dragRef}>
<div className={styles.header}>
搜索更多
{/* eslint-disable-next-line react/button-has-type */}
<button
className={classNames(styles.btn, styles.close)}
onClick={onClose}
>
<Input
size="middle"
placeholder="请输入"
allowClear
suffix={<SearchOutlined className="site-form-item-icon" />}
/>
</AutoComplete>
<CloseOutlined />
</button>
</div>
<div className={styles.result}>
{transformSearchFasts()}
{/* <Tabs defaultActiveKey="1" size="small">
<div className={styles.body}>
<div className={styles.search}>
<AutoComplete
options={transformSearchHistory()}
dropdownClassName={styles.searchList}
value={keyword}
onSelect={onSelect}
onSearch={handleSearch}
onChange={handleChange}
onFocus={handleFocus}
>
<Input
size="middle"
placeholder="请输入"
allowClear
suffix={<SearchOutlined className="site-form-item-icon" />}
/>
</AutoComplete>
</div>
<div className={styles.result}>
{transformSearchFasts()}
{/* <Tabs defaultActiveKey="1" size="small">
<TabPane tab="产品功能入口" key="1">
{
transformSeachProductList()
......@@ -310,12 +315,13 @@ const Modal = props => {
</TabPane>
</Tabs> */}
</div>
</div>
</div>
</div>
</Draggable>
);
return ReactDOM.createPortal(children, document.body);
</Draggable>
);
return ReactDOM.createPortal(children, document.body);
}
};
export default Modal;
......@@ -74,10 +74,6 @@ const appReducer = (state = initialState, action) => {
action.data,
{
allWidgets: action.data.widgets || [],
baseURL: {
dev: window.location.origin,
prod: window.location.origin,
},
env: process.env.NODE_ENV === 'development' ? 'daily' : 'prod',
},
);
......
......@@ -359,8 +359,8 @@ const BasicLayout = props => {
}, [props.currentMenuIndex]);
useEffect(() => {
if (_.isEmpty(props.global.token)) {
history.replace(`/user/login?client=${props.global.client}`);
if (_.isEmpty(props.global.get('token'))) {
history.replace(`/user/login?client=${props.global.get('client')}`);
return;
}
siteAction.getCityStationsForUser().then(res => {
......@@ -370,9 +370,9 @@ const BasicLayout = props => {
useMemo(() => {
window.share.event.on('listenerRemoveTab', () => {
props.updateSelectedKeys(`/civweb4/?client=${props.global.client}`);
props.updatePathname(`/civweb4/?client=${props.global.client}`);
history.push(`/civweb4/?client=${props.global.client}`);
props.updateSelectedKeys(`/civweb4/?client=${props.global.get('client')}`);
props.updatePathname(`/civweb4/?client=${props.global.get('client')}`);
history.push(`/civweb4/?client=${props.global.get('client')}`);
});
window.share.event.removeAllListeners('listenerRemoveSigleTab');
}, [props.pathname]);
......@@ -426,7 +426,7 @@ const BasicLayout = props => {
};
const handleLogo = event => {
props.global.userInfo.site ? history.replace(`/industry`) : null;
props.global.get('userInfo.site') ? history.replace(`/industry`) : null;
};
const transformPopupMenu = useCallback(key => {
......@@ -449,7 +449,7 @@ const BasicLayout = props => {
collapsed: collapse,
};
const headerContentRender = renderTitle(
props.global.title,
props.global.get('title'),
siteAction,
cityData,
siteLoading,
......@@ -506,7 +506,7 @@ const BasicLayout = props => {
return (
<ProLayout
logo={false}
title={props.global && props.global.title}
title={props.global && props.global.get('title')}
headerRender={false}
rightContentRender={() => null}
collapsedButtonRender={false}
......@@ -620,12 +620,12 @@ const BasicLayout = props => {
<SecurityLayout loading updateCurrentIndex={props.updateCurrentIndex}>
<ProLayout
logo={`http://panda-water.cn/web4/${
props.global.bannerLogo
? props.global.bannerLogo
props.global.get('bannerLogo')
? props.global.get('bannerLogo')
: 'assets/images/logo/单独图案-白色.svg'
}`}
siderWidth="145px"
title={props.global && props.global.title}
title={props.global && props.global.get('title')}
onCollapse={collapse => handlerCollapsed(collapse)}
onMenuHeaderClick={event => handleLogo(event)}
menuExtraRender={props.menu.length > 0 ? extraRender.render : null}
......
......@@ -353,6 +353,7 @@ class Site {
ignoreSite: true,
})
.then(res => {
// eslint-disable-next-line no-debugger
const { token } = res;
if (token) {
this.beforeChangeCheck(token, site);
......@@ -364,6 +365,7 @@ class Site {
}
beforeChangeCheck(token, site) {
// eslint-disable-next-line no-undef
services
.getUserInfo({
......
......@@ -135,6 +135,7 @@ export const defaultApp = () => {
const config = createStoreage.get('globalConfig');
if (config && config.token) {
// const startWith = config.homepage ? config.homepage.split('/') : [];
// console.log(findPathByLeafId(config.homepage, '', 'url'))
const basePath =
config.homepage !== '' && FILTER_FOLER_REG.test(config.homepage)
? 'civweb4'
......
......@@ -70,6 +70,7 @@ class Login {
subOID: 'subOID',
site: this.getLocalSiteBytoken(token),
'request.preventCache': Date.now(),
ignoreSite: true,
})
.then(response => {
if (response && !response.errMsg) {
......@@ -434,6 +435,7 @@ class Login {
referer: self.globalConfig.client,
skipMenuTest: 1,
qrcode: code,
cacheBust: true,
})
.then(response => {
if (response.token) {
......
......@@ -13,7 +13,7 @@ export const guid = function(prefix) {
) {
const r = (date + Math.random() * 16) % 16 | 0;
date = Math.floor(date / 16);
return (c == 'x' ? r : (r & 0x3) | 0x8).toString(16);
return (c === 'x' ? r : (r & 0x3) | 0x8).toString(16);
});
return prefix + uuid.replace(/-/g, '.');
};
......@@ -58,11 +58,8 @@ const generRotes = (widgets, parent, level = 0) => {
},
});
} else {
const baseURL = FILTER_FOLER_REG.test(item.url)
? 'civweb4'
: item.url.replace(/\s/g, '') === ''
? ''
: 'civweb5';
const baseURL = item.product || 'civweb4';
//item.product ? item.product : item.url.replace(/\s/g, '') === '' ? '' : 'civweb5';
let url =
item.hasOwnProperty('url') && !isUrl(url) && baseURL !== ''
? `/${baseURL}/${item.url.replace(/\s*/g, '')}`
......@@ -84,6 +81,7 @@ const generRotes = (widgets, parent, level = 0) => {
target: isUrl(url) ? '_blank' : '',
key: guid('panda'),
hideInMenu: l > 3,
application: item.product,
extData: {
...item,
icon: (item && item.icon.replace(/\s*/g, '')) || '_',
......
......@@ -131,3 +131,26 @@ export function isJSON(str) {
export function isString(str) {
return toString.call(str) === '[object String]';
}
export const getKeyName = path => {
const truePath = path.split('?')[0];
const curRoute = [].filter(item => item.path.includes(truePath));
if (!curRoute[0]) {
return {
title: '暂无权限',
tabKey: '403',
};
}
const { name, key, component } = curRoute[0];
return { title: name, tabKey: key, component };
};
export const asyncAction = action => {
const wait = new Promise(resolve => resolve(action));
return callback => {
wait.then(() => setTimeout(() => callback()));
};
};
export const closeTabAction = (history, returnUrl, callback) => {};
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment