Browse Source

Merge branch 'dev' of https://gitea.anxinyun.cn/gao.zhiyuan/Highways4Good into dev

release_0.0.4
wangyue 2 years ago
parent
commit
06063067ea
  1. 24
      api/app/lib/controllers/data/index.js
  2. 2
      api/app/lib/controllers/data/overspeed.js
  3. 2
      api/app/lib/controllers/overview/conserve.js
  4. 1
      api/app/lib/index.js
  5. 4
      api/app/lib/routes/data/index.js
  6. 4
      api/log/development.log
  7. 22
      web/client/assets/color.less
  8. 4
      web/client/index.ejs
  9. 2
      web/client/index.html
  10. 6
      web/client/src/layout/actions/global.js
  11. 3
      web/client/src/layout/components/header/index.js
  12. 18
      web/client/src/layout/containers/layout/index.js
  13. 4
      web/client/src/sections/fillion/components/bridgeTable.js
  14. 32
      web/client/src/sections/fillion/components/highways/highwaysdata.js
  15. 18
      web/client/src/sections/fillion/components/highwaysTable.js
  16. 42
      web/client/src/sections/fillion/components/infor/details.js
  17. 9
      web/client/src/sections/fillion/components/inforTable.js
  18. 87
      web/client/src/sections/fillion/components/operationalTable.js
  19. 20
      web/client/src/sections/fillion/components/project/project.js
  20. 3
      web/client/src/sections/fillion/components/publicTable.js
  21. 15
      web/client/src/sections/fillion/components/transportationTable.js
  22. 5
      web/client/src/sections/organization/components/depModal.js
  23. 2
      web/client/src/sections/organization/components/userModal.js
  24. 3
      web/client/src/sections/organization/containers/user.js
  25. 4
      web/client/src/sections/quanju/containers/footer/build/Leftbottom.js
  26. 4
      web/client/src/sections/quanju/containers/footer/build/Rightcenter.js
  27. 2
      web/client/src/sections/quanju/containers/footer/build/index.js
  28. 3
      web/client/src/sections/quanju/containers/footer/conserve/right/right-center.js
  29. 13
      web/client/src/sections/quanju/containers/footer/conserve/right/right-top.js
  30. 6
      web/client/src/sections/quanju/containers/footer/guanli/index.js
  31. 2
      web/client/src/sections/quanju/containers/heand/index.js
  32. 8
      web/config.js
  33. 2
      web/package.json
  34. 2
      web/routes/attachment/index.js

24
api/app/lib/controllers/data/index.js

@ -2,6 +2,7 @@
const fs = require('fs'); const fs = require('fs');
const xlsxDownload = require('../../../../utils/xlsxDownload.js'); const xlsxDownload = require('../../../../utils/xlsxDownload.js');
const moment = require('moment'); const moment = require('moment');
const request = require('superagent');
async function dataExport (ctx) { async function dataExport (ctx) {
try { try {
@ -105,6 +106,27 @@ async function dataExport (ctx) {
} }
} }
async function godTrans (ctx) {
try {
const models = ctx.fs.dc.models;
const { userId } = ctx.fs.api
const res = await request.get('https://report.amap.com/ajax/districtRank.do?linksType=1&cityCode=360100')
const data = JSON.parse(res.text)
const nanchang = data.find(item => item.name == '南昌县') || {}
ctx.status = 200
ctx.body = nanchang
} catch (error) {
ctx.fs.logger.error(`path: ${ctx.path}, error: ${error}`);
ctx.status = 400;
ctx.body = {
message: typeof error == 'string' ? error : undefined
}
}
}
module.exports = { module.exports = {
dataExport dataExport,
godTrans
}; };

2
api/app/lib/controllers/data/overspeed.js

@ -43,7 +43,7 @@ async function overspeedGet (ctx) {
if (testTime) { if (testTime) {
findOption.where.testTime = testTime findOption.where.testTime = testTime
} }
const overspeedRes = await models.Overspeed.findAll(findOption) const overspeedRes = await models.Overspeed.findAndCountAll(findOption)
ctx.status = 200; ctx.status = 200;
ctx.body = overspeedRes ctx.body = overspeedRes

2
api/app/lib/controllers/overview/conserve.js

@ -10,7 +10,7 @@ async function statistic (ctx) {
where: { where: {
reportType: 'conserve', reportType: 'conserve',
}, },
attributes: ['id', 'road', 'time', 'projectType', 'projectType'], attributes: ['id', 'road', 'time', 'projectType', 'projectType', 'roadSectionStart', 'roadSectionEnd'],
include: [{ include: [{
model: models.User, model: models.User,
attributes: ['name'] attributes: ['name']

1
api/app/lib/index.js

@ -23,7 +23,6 @@ module.exports.entry = function (app, router, opts) {
module.exports.models = function (dc) { // dc = { orm: Sequelize对象, ORM: Sequelize, models: {} } module.exports.models = function (dc) { // dc = { orm: Sequelize对象, ORM: Sequelize, models: {} }
fs.readdirSync(path.join(__dirname, '/models')).forEach((filename) => { fs.readdirSync(path.join(__dirname, '/models')).forEach((filename) => {
console.log(filename);
require(`./models/${filename}`)(dc) require(`./models/${filename}`)(dc)
}); });

4
api/app/lib/routes/data/index.js

@ -15,6 +15,10 @@ module.exports = function (app, router, opts) {
app.fs.api.logAttr['GET/data/export'] = { content: '导出数据', visible: true }; app.fs.api.logAttr['GET/data/export'] = { content: '导出数据', visible: true };
router.get('/data/export', dataIndex.dataExport); router.get('/data/export', dataIndex.dataExport);
// god 交通
app.fs.api.logAttr['GET/data/god_trans'] = { content: '获取高德交通数据', visible: true };
router.get('/data/god_trans', dataIndex.godTrans);
// 运政 // 运政
//客运车 //客运车
async function setVehicleType (ctx, next) { async function setVehicleType (ctx, next) {

4
api/log/development.log

@ -10008,3 +10008,7 @@
2022-07-27 15:49:28.071 - error: path: /vehicle/3/specific, error: TypeError: Cannot read property 'destroy' of undefined 2022-07-27 15:49:28.071 - error: path: /vehicle/3/specific, error: TypeError: Cannot read property 'destroy' of undefined
2022-07-27 15:50:36.847 - error: path: /vehicle/3/specific, error: TypeError: Cannot read property 'destroy' of undefined 2022-07-27 15:50:36.847 - error: path: /vehicle/3/specific, error: TypeError: Cannot read property 'destroy' of undefined
2022-07-27 15:51:05.608 - error: path: /vehicle/3/specific, error: TypeError: Cannot read property 'destroy' of undefined 2022-07-27 15:51:05.608 - error: path: /vehicle/3/specific, error: TypeError: Cannot read property 'destroy' of undefined
2022-07-28 10:56:48.597 - debug: [FS-LOGGER] Init.
2022-07-28 10:56:48.738 - info: [FS-ATTACHMENT] Inject attachment mw into router.
2022-07-28 10:56:48.738 - info: [FS-AUTH] Inject auth and api mv into router.
2022-07-28 11:01:45.098 - error: path: /department, error: 部门名称重复

22
web/client/assets/color.less

@ -1149,10 +1149,10 @@ tr > .ant-picker-cell-in-view.ant-picker-cell-range-hover-start:last-child::afte
.ant-mentions-dropdown-menu-item-active {background-color: @item-hover-bg;} .ant-mentions-dropdown-menu-item-active {background-color: @item-hover-bg;}
.ant-menu-item-danger.ant-menu-item {color: #ff4d4f;} .ant-menu-item-danger.ant-menu-item {color: #ff4d4f;}
.ant-menu-item-danger.ant-menu-item:hover, .ant-menu-item-danger.ant-menu-item-active {color: #ff4d4f;} .ant-menu-item-danger.ant-menu-item:hover, .ant-menu-item-danger.ant-menu-item-active {color: #ff4d4f;}
.ant-menu-item-danger.ant-menu-item:active {background: color(~`colorPalette("@{slider-rail-background-color}", 1)`);} .ant-menu-item-danger.ant-menu-item:active {background: color(~`colorPalette("@{select-clear-background}", 1)`);}
.ant-menu-item-danger.ant-menu-item-selected {color: #ff4d4f;} .ant-menu-item-danger.ant-menu-item-selected {color: #ff4d4f;}
.ant-menu-item-danger.ant-menu-item-selected > a, .ant-menu-item-danger.ant-menu-item-selected > a:hover {color: #ff4d4f;} .ant-menu-item-danger.ant-menu-item-selected > a, .ant-menu-item-danger.ant-menu-item-selected > a:hover {color: #ff4d4f;}
.ant-menu:not(.ant-menu-horizontal) .ant-menu-item-danger.ant-menu-item-selected {background-color: color(~`colorPalette("@{slider-rail-background-color}", 1)`);} .ant-menu:not(.ant-menu-horizontal) .ant-menu-item-danger.ant-menu-item-selected {background-color: color(~`colorPalette("@{select-clear-background}", 1)`);}
.ant-menu-inline .ant-menu-item-danger.ant-menu-item::after {border-right-color: #ff4d4f;} .ant-menu-inline .ant-menu-item-danger.ant-menu-item::after {border-right-color: #ff4d4f;}
.ant-menu-dark .ant-menu-item-danger.ant-menu-item, .ant-menu-dark .ant-menu-item-danger.ant-menu-item:hover, .ant-menu-dark .ant-menu-item-danger.ant-menu-item > a {color: #ff4d4f;} .ant-menu-dark .ant-menu-item-danger.ant-menu-item, .ant-menu-dark .ant-menu-item-danger.ant-menu-item:hover, .ant-menu-dark .ant-menu-item-danger.ant-menu-item > a {color: #ff4d4f;}
.ant-menu-dark.ant-menu-dark:not(.ant-menu-horizontal) .ant-menu-item-danger.ant-menu-item-selected {color: #fff;background-color: #ff4d4f;} .ant-menu-dark.ant-menu-dark:not(.ant-menu-horizontal) .ant-menu-item-danger.ant-menu-item-selected {color: #fff;background-color: #ff4d4f;}
@ -1722,11 +1722,11 @@ tr.ant-table-expanded-row:hover > td {background: @table-expanded-row-bg;}
.ant-tag-checkable:active, .ant-tag-checkable-checked {color: #fff;} .ant-tag-checkable:active, .ant-tag-checkable-checked {color: #fff;}
.ant-tag-checkable-checked {background-color: @primary-color;} .ant-tag-checkable-checked {background-color: @primary-color;}
.ant-tag-checkable:active {background-color: color(~`colorPalette("@{primary-color}", 7)`);} .ant-tag-checkable:active {background-color: color(~`colorPalette("@{primary-color}", 7)`);}
.ant-tag-pink {color: #c41d7f;background: color(~`colorPalette("@{table-expand-icon-bg}", 1)`);border-color: #ffadd2;} .ant-tag-pink {color: #c41d7f;background: color(~`colorPalette("@{modal-footer-border-color-split}", 1)`);border-color: #ffadd2;}
.ant-tag-pink-inverse {color: #fff;background: #eb2f96;border-color: #eb2f96;} .ant-tag-pink-inverse {color: #fff;background: #eb2f96;border-color: #eb2f96;}
.ant-tag-magenta {color: #c41d7f;background: color(~`colorPalette("@{table-expand-icon-bg}", 1)`);border-color: #ffadd2;} .ant-tag-magenta {color: #c41d7f;background: color(~`colorPalette("@{modal-footer-border-color-split}", 1)`);border-color: #ffadd2;}
.ant-tag-magenta-inverse {color: #fff;background: #eb2f96;border-color: #eb2f96;} .ant-tag-magenta-inverse {color: #fff;background: #eb2f96;border-color: #eb2f96;}
.ant-tag-red {color: #cf1322;background: color(~`colorPalette("@{slider-rail-background-color}", 1)`);border-color: #ffa39e;} .ant-tag-red {color: #cf1322;background: color(~`colorPalette("@{select-clear-background}", 1)`);border-color: #ffa39e;}
.ant-tag-red-inverse {color: #fff;background: #f5222d;border-color: #f5222d;} .ant-tag-red-inverse {color: #fff;background: #f5222d;border-color: #f5222d;}
.ant-tag-volcano {color: #d4380d;background: #fff2e8;border-color: #ffbb96;} .ant-tag-volcano {color: #d4380d;background: #fff2e8;border-color: #ffbb96;}
.ant-tag-volcano-inverse {color: #fff;background: #fa541c;border-color: #fa541c;} .ant-tag-volcano-inverse {color: #fff;background: #fa541c;border-color: #fa541c;}
@ -1734,19 +1734,19 @@ tr.ant-table-expanded-row:hover > td {background: @table-expanded-row-bg;}
.ant-tag-orange-inverse {color: #fff;background: #fa8c16;border-color: #fa8c16;} .ant-tag-orange-inverse {color: #fff;background: #fa8c16;border-color: #fa8c16;}
.ant-tag-yellow {color: #d4b106;background: #feffe6;border-color: #fffb8f;} .ant-tag-yellow {color: #d4b106;background: #feffe6;border-color: #fffb8f;}
.ant-tag-yellow-inverse {color: #fff;background: #fadb14;border-color: #fadb14;} .ant-tag-yellow-inverse {color: #fff;background: #fadb14;border-color: #fadb14;}
.ant-tag-gold {color: #d48806;background: #fffbe6;border-color: #ffe58f;} .ant-tag-gold {color: #d48806;background: color(~`colorPalette("@{error-color-deprecated-border}", 1)`);border-color: #ffe58f;}
.ant-tag-gold-inverse {color: #fff;background: #faad14;border-color: #faad14;} .ant-tag-gold-inverse {color: #fff;background: #faad14;border-color: #faad14;}
.ant-tag-cyan {color: #08979c;background: #e6fffb;border-color: #87e8de;} .ant-tag-cyan {color: #08979c;background: #e6fffb;border-color: #87e8de;}
.ant-tag-cyan-inverse {color: #fff;background: #13c2c2;border-color: #13c2c2;} .ant-tag-cyan-inverse {color: #fff;background: #13c2c2;border-color: #13c2c2;}
.ant-tag-lime {color: #7cb305;background: #fcffe6;border-color: #eaff8f;} .ant-tag-lime {color: #7cb305;background: color(~`colorPalette("@{steps-nav-arrow-color}", 1)`);border-color: #eaff8f;}
.ant-tag-lime-inverse {color: #fff;background: #a0d911;border-color: #a0d911;} .ant-tag-lime-inverse {color: #fff;background: #a0d911;border-color: #a0d911;}
.ant-tag-green {color: #389e0d;background: #f6ffed;border-color: #b7eb8f;} .ant-tag-green {color: #389e0d;background: #f6ffed;border-color: #b7eb8f;}
.ant-tag-green-inverse {color: #fff;background: #52c41a;border-color: #52c41a;} .ant-tag-green-inverse {color: #fff;background: #52c41a;border-color: #52c41a;}
.ant-tag-blue {color: #096dd9;background: #e6f7ff;border-color: #91d5ff;} .ant-tag-blue {color: #096dd9;background: color(~`colorPalette("@{pagination-item-input-bg}", 1)`);border-color: color(~`colorPalette("@{pagination-item-input-bg}", 3)`);}
.ant-tag-blue-inverse {color: #fff;background: #1890ff;border-color: #1890ff;} .ant-tag-blue-inverse {color: #fff;background: #1890ff;border-color: #1890ff;}
.ant-tag-geekblue {color: #1d39c4;background: color(~`colorPalette("@{cascader-menu-bg}", 1)`);border-color: #adc6ff;} .ant-tag-geekblue {color: #1d39c4;background: color(~`colorPalette("@{modal-content-bg}", 1)`);border-color: #adc6ff;}
.ant-tag-geekblue-inverse {color: #fff;background: #2f54eb;border-color: #2f54eb;} .ant-tag-geekblue-inverse {color: #fff;background: #2f54eb;border-color: #2f54eb;}
.ant-tag-purple {color: #531dab;background: color(~`colorPalette("@{disabled-color-dark}", 4)`);border-color: #d3adf7;} .ant-tag-purple {color: #531dab;background: #f9f0ff;border-color: #d3adf7;}
.ant-tag-purple-inverse {color: #fff;background: #722ed1;border-color: #722ed1;} .ant-tag-purple-inverse {color: #fff;background: #722ed1;border-color: #722ed1;}
.ant-tag-success {color: #52c41a;background: @success-color-deprecated-bg;border-color: @success-color-deprecated-border;} .ant-tag-success {color: #52c41a;background: @success-color-deprecated-bg;border-color: @success-color-deprecated-border;}
.ant-tag-processing {color: @primary-color;background: @info-color-deprecated-bg;border-color: @info-color-deprecated-border;} .ant-tag-processing {color: @primary-color;background: @info-color-deprecated-bg;border-color: @info-color-deprecated-border;}
@ -1984,7 +1984,7 @@ a.ant-typography.ant-typography-disabled:hover, .ant-typography a.ant-typography
.ant-upload-list-picture .ant-upload-list-item-error, .ant-upload-list-picture-card .ant-upload-list-item-error {border-color: #ff4d4f;} .ant-upload-list-picture .ant-upload-list-item-error, .ant-upload-list-picture-card .ant-upload-list-item-error {border-color: #ff4d4f;}
.ant-upload-list-picture .ant-upload-list-item:hover .ant-upload-list-item-info, .ant-upload-list-picture-card .ant-upload-list-item:hover .ant-upload-list-item-info {background: transparent;} .ant-upload-list-picture .ant-upload-list-item:hover .ant-upload-list-item-info, .ant-upload-list-picture-card .ant-upload-list-item:hover .ant-upload-list-item-info {background: transparent;}
.ant-upload-list-picture .ant-upload-list-item-uploading, .ant-upload-list-picture-card .ant-upload-list-item-uploading {border-style: dashed;} .ant-upload-list-picture .ant-upload-list-item-uploading, .ant-upload-list-picture-card .ant-upload-list-item-uploading {border-style: dashed;}
.ant-upload-list-picture .ant-upload-list-item-error .ant-upload-list-item-thumbnail .anticon svg path[fill='#e6f7ff'], .ant-upload-list-picture-card .ant-upload-list-item-error .ant-upload-list-item-thumbnail .anticon svg path[fill='#e6f7ff'] {fill: @error-color-deprecated-bg;} .ant-upload-list-picture .ant-upload-list-item-error .ant-upload-list-item-thumbnail .anticon svg path[fill='color(~`colorPalette("@{pagination-item-input-bg}", 1)`)'], .ant-upload-list-picture-card .ant-upload-list-item-error .ant-upload-list-item-thumbnail .anticon svg path[fill='color(~`colorPalette("@{pagination-item-input-bg}", 1)`)'] {fill: @error-color-deprecated-bg;}
.ant-upload-list-picture .ant-upload-list-item-error .ant-upload-list-item-thumbnail .anticon svg path[fill='#1890ff'], .ant-upload-list-picture-card .ant-upload-list-item-error .ant-upload-list-item-thumbnail .anticon svg path[fill='#1890ff'] {fill: #ff4d4f;} .ant-upload-list-picture .ant-upload-list-item-error .ant-upload-list-item-thumbnail .anticon svg path[fill='#1890ff'], .ant-upload-list-picture-card .ant-upload-list-item-error .ant-upload-list-item-thumbnail .anticon svg path[fill='#1890ff'] {fill: #ff4d4f;}
.ant-upload-list-picture-card .ant-upload-list-item-info::before {background-color: rgba(0, 0, 0, 0.5);} .ant-upload-list-picture-card .ant-upload-list-item-info::before {background-color: rgba(0, 0, 0, 0.5);}
.ant-upload-list-picture-card .ant-upload-list-item-actions .anticon-eye, .ant-upload-list-picture-card .ant-upload-list-item-actions .anticon-download, .ant-upload-list-picture-card .ant-upload-list-item-actions .anticon-delete {color: rgba(255, 255, 255, 0.85);} .ant-upload-list-picture-card .ant-upload-list-item-actions .anticon-eye, .ant-upload-list-picture-card .ant-upload-list-item-actions .anticon-download, .ant-upload-list-picture-card .ant-upload-list-item-actions .anticon-delete {color: rgba(255, 255, 255, 0.85);}

4
web/client/index.ejs

@ -18,12 +18,12 @@
</head> </head>
<body style="background: transparent"> <body style="background: transparent">
<link <!-- <link
rel="stylesheet/less" rel="stylesheet/less"
type="text/css" type="text/css"
href="/assets/color.less" href="/assets/color.less"
rel="external nofollow" rel="external nofollow"
/> /> -->
<script> <script>
window.less = { window.less = {

2
web/client/index.html

@ -18,7 +18,7 @@
</head> </head>
<body> <body>
<link rel="stylesheet/less" type="text/css" href="/assets/color.less" rel="external nofollow" /> <!-- <link rel="stylesheet/less" type="text/css" href="/assets/color.less" rel="external nofollow" /> -->
<script> <script>
window.less = { window.less = {
async: false, async: false,

6
web/client/src/layout/actions/global.js

@ -3,7 +3,7 @@ import { RouteRequest } from '@peace/utils';
import { RouteTable } from '$utils' import { RouteTable } from '$utils'
export const INIT_LAYOUT = 'INIT_LAYOUT'; export const INIT_LAYOUT = 'INIT_LAYOUT';
export function initLayout(title, copyright, sections, actions) { export function initLayout (title, copyright, sections, actions) {
return { return {
type: INIT_LAYOUT, type: INIT_LAYOUT,
payload: { payload: {
@ -16,7 +16,7 @@ export function initLayout(title, copyright, sections, actions) {
} }
export const RESIZE = 'RESIZE'; export const RESIZE = 'RESIZE';
export function resize(clientHeight, clientWidth) { export function resize (clientHeight, clientWidth) {
return { return {
type: RESIZE, type: RESIZE,
payload: { payload: {
@ -27,7 +27,7 @@ export function resize(clientHeight, clientWidth) {
} }
export const INIT_API_ROOT = 'INIT_API_ROOT'; export const INIT_API_ROOT = 'INIT_API_ROOT';
export function initApiRoot() { export function initApiRoot () {
return dispatch => { return dispatch => {
RouteRequest.get(RouteTable.apiRoot).then(res => { RouteRequest.get(RouteTable.apiRoot).then(res => {
localStorage.setItem('tyApiRoot', res.root); localStorage.setItem('tyApiRoot', res.root);

3
web/client/src/layout/components/header/index.js

@ -52,7 +52,8 @@ const Header = props => {
<div id="nav" className={styles['header-nav']}> <div id="nav" className={styles['header-nav']}>
<Menu <Menu
mode='horizontal' mode='horizontal'
selectedKeys={[current]} style={{ border: 0 }} selectedKeys={[current]}
style={{ border: 0 }}
onClick={handelClick} onClick={handelClick}
> >
<div style={{ display: 'inline-block', cursor: "pointer" }} onClick={() => history.push(`/quanju`)}>进入大屏</div> <div style={{ display: 'inline-block', cursor: "pointer" }} onClick={() => history.push(`/quanju`)}>进入大屏</div>

18
web/client/src/layout/containers/layout/index.js

@ -51,15 +51,9 @@ const LayoutContainer = props => {
}) })
}, [true]) }, [true])
useEffect(() => { useEffect(() => {
window.less.modifyVars(themeName == 'light' ? lightVars : darkVars).then(() => {
resize_(collapsed)
}).catch(error => {
resize_(collapsed)
message.error(`主题切换失败`);
});
scrollbar = new PerfectScrollbar('#page-content', { suppressScrollX: true }); scrollbar = new PerfectScrollbar('#page-content', { suppressScrollX: true });
}, []) }, [])
useEffect(() => { useEffect(() => {
NProgress.done(); NProgress.done();
if (!user || !user.authorized) { if (!user || !user.authorized) {
@ -89,13 +83,13 @@ const LayoutContainer = props => {
padding: '8px', padding: '8px',
height: clientHeight - 16 + 68, height: clientHeight - 16 + 68,
} }
if (themeName == 'light') { // if (themeName == 'light') {
contentStyle.background = '#fff'; contentStyle.background = '#fff';
} // }
return ( return (
<Layout id="layout"> <Layout id="layout">
<Layout.Header style={{ padding: 0 }} > <Layout.Header style={{ padding: 0, background: '#fff' }} >
<Header <Header
user={user} user={user}
pathname={location.pathname} pathname={location.pathname}
@ -138,7 +132,7 @@ const LayoutContainer = props => {
) )
} }
function mapStateToProps(state) { function mapStateToProps (state) {
const { global, auth, ajaxResponse } = state; const { global, auth, ajaxResponse } = state;
return { return {
title: global.title, title: global.title,

4
web/client/src/sections/fillion/components/bridgeTable.js

@ -26,7 +26,7 @@ const BrideTable = (props) => {
const [delet, setDelet] = useState() const [delet, setDelet] = useState()
const ref = useRef() const ref = useRef()
useEffect(() => { ref.current.reload() }, [modalVisible, modalVisibleyilan,whichofits,delet]) useEffect(() => { ref.current.reload() }, [whichofits,delet])
const columns = { const columns = {
tab1: [ tab1: [
{ {
@ -1861,6 +1861,7 @@ const BrideTable = (props) => {
rewkeys={'bridge'} rewkeys={'bridge'}
data={date} data={date}
recortd={recortd} recortd={recortd}
setDelet={setDelet}
// sitename={sitename} // sitename={sitename}
setRecortd={setRecortd} setRecortd={setRecortd}
/> : ''} /> : ''}
@ -1870,6 +1871,7 @@ const BrideTable = (props) => {
modalRecord={modalRecord} modalRecord={modalRecord}
typecard={typecard} typecard={typecard}
rewkeys={'bridge'} rewkeys={'bridge'}
setDelet={setDelet}
recortd={recortd} recortd={recortd}
setRecortd={setRecortd} setRecortd={setRecortd}
/> : ''} /> : ''}

32
web/client/src/sections/fillion/components/highways/highwaysdata.js

@ -6,7 +6,7 @@ import { putOperaTional,putHighways } from "../../actions/infor"
import { _ } from 'lodash' import { _ } from 'lodash'
const HightModal = (props) => { const HightModal = (props) => {
const { visible, onVisibleChange, typecard, rewkeys, recortd, dispatch, setRecortd } = props const { visible, onVisibleChange, typecard, rewkeys, recortd, dispatch, setRecortd,setDelet } = props
const [success,setSuccess]=useState() const [success,setSuccess]=useState()
useEffect(() => { useEffect(() => {
@ -25,8 +25,7 @@ const HightModal = (props) => {
onVisibleChange={onVisibleChange} onVisibleChange={onVisibleChange}
onFinish={(values) => { onFinish={(values) => {
if (rewkeys === 'passenger') { if (rewkeys === 'passenger') {
setDelet(values)
console.log(values)
const query = { ...values, id:recortd?.id } const query = { ...values, id:recortd?.id }
dispatch(putOperaTional(query)).then((res) => { dispatch(putOperaTional(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
@ -35,8 +34,8 @@ const HightModal = (props) => {
} }
if (rewkeys === 'highways') { if (rewkeys === 'highways') {
setDelet(values)
console.log(values)
const query = { ...values, id:recortd?.id } const query = { ...values, id:recortd?.id }
dispatch(putHighways(query)).then((res) => { dispatch(putHighways(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
@ -55,29 +54,40 @@ const HightModal = (props) => {
name='name' name='name'
width="md" width="md"
label='类型' label='类型'
tooltip="最长为 24 位"
placeholder="请输入名称" placeholder="请输入名称"
// value={recortd?.[0]?.value} // value={recortd?.[0]?.value}
disabled disabled
rules={[{ required: true, message: "必填" }]}
/> />
<ProFormText <ProFormText
name='count' name='count'
width="md" width="md"
label='数量' label='数量'
tooltip="最长为 24 位"
placeholder="请输入名称" placeholder="请输入数量"
rules={[
{required: true,
message:'请输入整数',
pattern:RegExp(/^[0-9]\d*$/,'g'),
},
// getValueFromEvent=(event)=>{
// return event.target.value.replace(/\D/g,'')
// }
]}
/> />
</ProForm.Group> </ProForm.Group>
: <ProForm.Group> : <ProForm.Group>
<ProFormText {/* <ProFormText
name={newlys?.[0]?.type} name={newlys?.[0]?.type}
width="md" width="md"
label={newlys?.[0]?.name} label={newlys?.[0]?.name}
tooltip="最长为 24 位"
placeholder="请输入名称" placeholder="请输入名称"
/> /> */}
</ProForm.Group>} </ProForm.Group>}
</ModalForm> </ModalForm>

18
web/client/src/sections/fillion/components/highwaysTable.js

@ -16,9 +16,10 @@ const HigwaysTable = (props) => {
const [typecard, setTypecard] = useState(); const [typecard, setTypecard] = useState();
const [recortd, setRecortd] = useState() const [recortd, setRecortd] = useState()
const [sitename, setSitename] = useState()//桥梁名称 const [sitename, setSitename] = useState()//桥梁名称
const [delet, setDelet] = useState()
const ref = useRef() const ref = useRef()
useEffect(() => { ref.current.reload() }, [ modalVisibleyilan]) useEffect(() => { ref.current.reload() }, [ delet])
//打开弹窗 //打开弹窗
const hightModal = (type, record) => { const hightModal = (type, record) => {
setModalVisibleyilan(true); setModalVisibleyilan(true);
@ -106,18 +107,18 @@ const exports = (ids, counts) => {
actionRef={ref} actionRef={ref}
scroll={{ x: 800 }} scroll={{ x: 800 }}
options={false} options={false}
ref={c => { finishedProductTable = c; }} // ref={c => { finishedProductTable = c; }}
style={{ width: "100% ", overflow: "auto", height: '760px' }} style={{ width: "100% ", overflow: "auto", height: '760px' }}
rowKey='id' rowKey='id'
onReset={(v) => { onReset={(v) => {
setSitename('') setSitename('')
}} }}
rowSelection={{ // rowSelection={{
selectedRowKeys: rowSelected, // selectedRowKeys: rowSelected,
onChange: (selectedRowKeys) => { // onChange: (selectedRowKeys) => {
setRowSelected(selectedRowKeys); // setRowSelected(selectedRowKeys);
}, // },
}} // }}
columns={columns} columns={columns}
dataSource={counts || []} dataSource={counts || []}
@ -143,6 +144,7 @@ const exports = (ids, counts) => {
rewkeys={'highways'} rewkeys={'highways'}
recortd={recortd} recortd={recortd}
setRecortd={setRecortd} setRecortd={setRecortd}
setDelet={setDelet}
/> : ''} /> : ''}
</Spin > </Spin >
) )

42
web/client/src/sections/fillion/components/infor/details.js

@ -6,7 +6,7 @@ import { putRoadway, putSpecificVehicle, putHouseholds, putCircuit, putVehicle,
import { putBridge } from "../../actions/infor" import { putBridge } from "../../actions/infor"
import _ from 'lodash' import _ from 'lodash'
const UserModal = (props) => { const UserModal = (props) => {
const { visible, onVisibleChange, typecard, rewkeys, data, recortd, sitename, dispatch, setRecortd, setMonitor } = props const { visible, onVisibleChange, typecard, rewkeys, data, recortd, sitename, dispatch, setRecortd, setMonitor,setDelet,whichofits } = props
const [newlys, setNewlys] = useState() //必填数据 const [newlys, setNewlys] = useState() //必填数据
const [newlysay, setNewlysay] = useState() //处理hou const [newlysay, setNewlysay] = useState() //处理hou
const [records, setRecords] = useState()//处理 const [records, setRecords] = useState()//处理
@ -148,32 +148,37 @@ const UserModal = (props) => {
visible={visible} visible={visible}
onVisibleChange={onVisibleChange} onVisibleChange={onVisibleChange}
onFinish={(values) => { onFinish={(values) => {
console.log(values)
if (Object.values(values).length > 0) { if (Object.values(values).length > 0) {
if (rewkeys === 'transportation') { if (rewkeys === 'transportation') {
if (typecard == '111') {
const query = { ...values, level: sitename, roadId: records?.[0]?.value || '' } if (typecard == '111') {
setDelet(values)
const query = { ...values, level: whichofits, roadId: records?.[0]?.value || '' }
dispatch(putRoadway(query)).then((res) => { dispatch(putRoadway(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
}) })
return true return true
} else { } else {
const query = { ...values, level: sitename } setDelet(values)
const query = { ...values, level: whichofits }
dispatch(putRoadway(query)).then((res) => { dispatch(putRoadway(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
}) })
return true return true
} }
} }
if (rewkeys === 'bridge') { if (rewkeys === 'bridge') {
if (typecard == '111') { if (typecard == '111') {
console.log(values) setDelet(values)
const query = { ...values, roadId: records?.[0]?.value || '' } const query = { ...values, roadId: records?.[0]?.value || '' }
dispatch(putBridge(query)).then((res) => { dispatch(putBridge(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
}) })
return true return true
} else { } else {
setDelet(values)
const query = { ...values } const query = { ...values }
dispatch(putBridge(query)).then((res) => { dispatch(putBridge(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
@ -183,13 +188,14 @@ const UserModal = (props) => {
} }
if (rewkeys === 'weihuo' || rewkeys === 'chuzu') { if (rewkeys === 'weihuo' || rewkeys === 'chuzu') {
if (typecard == '111') { if (typecard == '111') {
console.log(values) setDelet(values)
const query = { ...values, vehicleId: records?.[0]?.value || '', type: rewkeys === 'chuzu' ? '出租车' : '危货' } const query = { ...values, vehicleId: records?.[0]?.value || '', type: rewkeys === 'chuzu' ? '出租车' : '危货' }
dispatch(putSpecificVehicle(query)).then((res) => { dispatch(putSpecificVehicle(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
}) })
return true return true
} else { } else {
setDelet(values)
const query = { ...values, type: rewkeys } const query = { ...values, type: rewkeys }
dispatch(putSpecificVehicle(query)).then((res) => { dispatch(putSpecificVehicle(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
@ -199,13 +205,14 @@ const UserModal = (props) => {
} }
if (rewkeys === 'yehu') { if (rewkeys === 'yehu') {
if (typecard == '111') { if (typecard == '111') {
console.log(values) setDelet(values)
const query = { ...values, businessId: records?.[0]?.value, type: rewkeys == 'chuzu' ? '出租车' : '危货' } const query = { ...values, businessId: records?.[0]?.value, type: rewkeys == 'chuzu' ? '出租车' : '危货' }
dispatch(putHouseholds(query)).then((res) => { dispatch(putHouseholds(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
}) })
return true return true
} else { } else {
setDelet(values)
const query = { ...values, type: rewkeys === 'chuzu' ? '出租车' : '危货' } const query = { ...values, type: rewkeys === 'chuzu' ? '出租车' : '危货' }
dispatch(putHouseholds(query)).then((res) => { dispatch(putHouseholds(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
@ -214,13 +221,14 @@ const UserModal = (props) => {
} }
} if (rewkeys === 'xianlu') { } if (rewkeys === 'xianlu') {
if (typecard == '111') { if (typecard == '111') {
console.log(values) setDelet(values)
const query = { ...values, lineId: records?.[0]?.value || '' } const query = { ...values, lineId: records?.[0]?.value || '' }
dispatch(putCircuit(query)).then((res) => { dispatch(putCircuit(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
}) })
return true return true
} else { } else {
setDelet(values)
const query = { ...values } const query = { ...values }
dispatch(putCircuit(query)).then((res) => { dispatch(putCircuit(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
@ -230,13 +238,14 @@ const UserModal = (props) => {
} }
if (rewkeys === 'cheliang') { if (rewkeys === 'cheliang') {
if (typecard == '111') { if (typecard == '111') {
console.log(values) setDelet(values)
const query = { ...values, carId: records?.[0]?.value || '' } const query = { ...values, carId: records?.[0]?.value || '' }
dispatch(putVehicle(query)).then((res) => { dispatch(putVehicle(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
}) })
return true return true
} else { } else {
setDelet(values)
const query = { ...values } const query = { ...values }
dispatch(putVehicle(query)).then((res) => { dispatch(putVehicle(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
@ -246,7 +255,7 @@ const UserModal = (props) => {
} }
if (rewkeys === 'zhichao') { if (rewkeys === 'zhichao') {
if (typecard == '111') { if (typecard == '111') {
console.log(values) setDelet(values)
const query = { ...values, overspeedId: records?.[0]?.value || '' } const query = { ...values, overspeedId: records?.[0]?.value || '' }
dispatch(putPurchase(query)).then((res) => { dispatch(putPurchase(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
@ -254,6 +263,7 @@ const UserModal = (props) => {
}) })
return true return true
} else { } else {
setDelet(values)
const query = { ...values } const query = { ...values }
dispatch(putPurchase(query)).then((res) => { dispatch(putPurchase(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
@ -274,7 +284,7 @@ const UserModal = (props) => {
name={newlys?.[0]?.type} name={newlys?.[0]?.type}
width="md" width="md"
label={newlys?.[0]?.name} label={newlys?.[0]?.name}
tooltip="最长为 24 位"
placeholder="请输入名称" placeholder="请输入名称"
value={recordsay?.[0]?.value} value={recordsay?.[0]?.value}
// rules={[{ required: true, message: "必填" }]} // rules={[{ required: true, message: "必填" }]}
@ -282,7 +292,7 @@ const UserModal = (props) => {
name={newlys?.[1]?.type} name={newlys?.[1]?.type}
width="md" width="md"
label={newlys?.[1]?.name} label={newlys?.[1]?.name}
tooltip="最长为 24 位"
placeholder="请输入名称" placeholder="请输入名称"
value={recordsay?.[1]?.value} value={recordsay?.[1]?.value}
// rules={[{ required: true, message: "必填" }]} // rules={[{ required: true, message: "必填" }]}
@ -316,7 +326,7 @@ const UserModal = (props) => {
name={newlys?.[0]?.type} name={newlys?.[0]?.type}
width="md" width="md"
label={newlys?.[0]?.name} label={newlys?.[0]?.name}
tooltip="最长为 24 位"
placeholder="请输入名称" placeholder="请输入名称"
// value={recordssy?.[0]?.value} // value={recordssy?.[0]?.value}
// rules={[{ required: true, message: "必填" }]} // rules={[{ required: true, message: "必填" }]}
@ -324,7 +334,7 @@ const UserModal = (props) => {
name={newlys?.[1]?.type} name={newlys?.[1]?.type}
width="md" width="md"
label={newlys?.[1]?.name} label={newlys?.[1]?.name}
tooltip="最长为 24 位"
placeholder="请输入名称" placeholder="请输入名称"
// value={recordssy?.[1]?.value} // value={recordssy?.[1]?.value}
// rules={[{ required: true, message: "必填" }]} // rules={[{ required: true, message: "必填" }]}
@ -348,7 +358,7 @@ const UserModal = (props) => {
{newlysay?.map((item, index) => { {newlysay?.map((item, index) => {
return <ProFormText width="md" return <ProFormText width="md"
name={item?.type} label={newlysay[index]?.name} placeholder="请输入名称" key={index} name={item?.type} label={newlysay[index]?.name} placeholder="请输入名称" key={index}
tooltip="最长为 24 位"
/> />
})} })}

9
web/client/src/sections/fillion/components/inforTable.js

@ -24,7 +24,7 @@ const InForTable = (props) => {
const [overrunRateFloor, setOverrunRateFloor] = useState()//超限率下限 const [overrunRateFloor, setOverrunRateFloor] = useState()//超限率下限
const [testTime, setTestTime] = useState()//超限率下限 const [testTime, setTestTime] = useState()//超限率下限
const ref = useRef() const ref = useRef()
useEffect(() => { ref.current.reload() }, [monitor, delet, modalVisible]) useEffect(() => { ref.current.reload() }, [monitor, delet])
//打开弹窗 //打开弹窗
const openModal = (type, record) => { const openModal = (type, record) => {
setModalVisible(true); setModalVisible(true);
@ -436,7 +436,10 @@ const InForTable = (props) => {
setTestTime('') setTestTime('')
}} }}
request={async (params) => { request={async (params) => {
console.log(params)
const query = { const query = {
limit:params.pageSize,
page:params.current-1,
nameOfInspectionPoint: nameOfInspectionPoint, nameOfInspectionPoint: nameOfInspectionPoint,
licensePlate: licensePlate, licensePlate: licensePlate,
numberOfAxles: numberOfAxles, numberOfAxles: numberOfAxles,
@ -446,7 +449,8 @@ const InForTable = (props) => {
} }
setRowSelected([]); setRowSelected([]);
const res = await dispatch(getPurchase(query)); const res = await dispatch(getPurchase(query));
setCounts(res.payload.data) console.log(res)
setCounts(res.payload.data.rows)
return { return {
...res, ...res,
total: res.payload.data ? res.payload.data.count : 0 total: res.payload.data ? res.payload.data.count : 0
@ -475,6 +479,7 @@ const InForTable = (props) => {
rewkeys={'zhichao'} rewkeys={'zhichao'}
data={data} data={data}
recortd={recortd} recortd={recortd}
setDelet={setDelet}
setMonitor={setMonitor} setMonitor={setMonitor}
// sitename={sitename} // sitename={sitename}
setRecortd={setRecortd} setRecortd={setRecortd}

87
web/client/src/sections/fillion/components/operationalTable.js

@ -11,6 +11,7 @@ import HightModal from './highways/highwaysdata';
const OperaTionalTable = (props) => { const OperaTionalTable = (props) => {
const { dispatch, user, depData, depMessage, depLoading } = props const { dispatch, user, depData, depMessage, depLoading } = props
const [rowSelected, setRowSelected] = useState([]) const [rowSelected, setRowSelected] = useState([])
const [sitename, setSitename] = useState()//场所名称 const [sitename, setSitename] = useState()//场所名称
const [counts, setCounts] = useState()//shuju const [counts, setCounts] = useState()//shuju
const [modalVisible, setModalVisible] = useState(false); const [modalVisible, setModalVisible] = useState(false);
@ -23,7 +24,7 @@ const OperaTionalTable = (props) => {
const [delet, setDelet] = useState() const [delet, setDelet] = useState()
const ref = useRef() const ref = useRef()
useEffect(() => { ref.current.reload() }, [modalVisible, modalVisibleyilan,rewkeys,activeKey,delet]) useEffect(() => { ref.current.reload() }, [rewkeys,activeKey,delet])
//打开弹窗 //打开弹窗
const openModal = (type, record) => { const openModal = (type, record) => {
setModalVisible(true); setModalVisible(true);
@ -150,7 +151,7 @@ const OperaTionalTable = (props) => {
title: '车牌号', title: '车牌号',
search: false, search: false,
dataIndex: 'time2', dataIndex: 'time2',
valueType: 'dateRange', valueType: 'dateRange1',
// align: 'right', // align: 'right',
width: 120, width: 120,
render: (dom, record) => { render: (dom, record) => {
@ -164,7 +165,7 @@ const OperaTionalTable = (props) => {
title: '燃料类型', title: '燃料类型',
search: false, search: false,
dataIndex: 'time3', dataIndex: 'time3',
valueType: 'dateRange', valueType: 'dateRange2',
@ -179,7 +180,7 @@ const OperaTionalTable = (props) => {
title: '住址', title: '住址',
search: false, search: false,
dataIndex: 'time4', dataIndex: 'time4',
valueType: 'dateRange', valueType: 'dateRange3',
width: 120, width: 120,
@ -193,7 +194,7 @@ const OperaTionalTable = (props) => {
title: '经济性质', title: '经济性质',
search: false, search: false,
dataIndex: 'time5', dataIndex: 'time5',
valueType: 'dateRange', valueType: 'dateRange4',
width: 120, width: 120,
@ -207,7 +208,7 @@ const OperaTionalTable = (props) => {
title: '核定载客位数', title: '核定载客位数',
search: false, search: false,
dataIndex: 'time6', dataIndex: 'time6',
valueType: 'dateRange', valueType: 'dateRange5',
width: 120, width: 120,
@ -221,7 +222,7 @@ const OperaTionalTable = (props) => {
title: '核定载质量', title: '核定载质量',
search: false, search: false,
dataIndex: 'time7', dataIndex: 'time7',
valueType: 'dateRange', valueType: 'dateRange6',
width: 120, width: 120,
@ -235,7 +236,7 @@ const OperaTionalTable = (props) => {
title: '车辆车轴数', title: '车辆车轴数',
search: false, search: false,
dataIndex: 'time8', dataIndex: 'time8',
valueType: 'dateRange', valueType: 'dateRange7',
width: 120, width: 120,
@ -249,7 +250,7 @@ const OperaTionalTable = (props) => {
title: '车辆厂牌', title: '车辆厂牌',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time9',
valueType: 'dateRange', valueType: 'dateRange8',
width: 140, width: 140,
@ -263,8 +264,8 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '经营范围', title: '经营范围',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time10',
valueType: 'dateRange', valueType: 'dateRange9',
width: 140, width: 140,
@ -278,8 +279,8 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '车辆营运状态', title: '车辆营运状态',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time11',
valueType: 'dateRange', valueType: 'dateRange10',
width: 140, width: 140,
@ -293,7 +294,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '客车类型与等级', title: '客车类型与等级',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time12',
valueType: 'dateRange', valueType: 'dateRange',
@ -308,7 +309,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '年审结果', title: '年审结果',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time13',
valueType: 'dateRange', valueType: 'dateRange',
@ -323,7 +324,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '本次年审日期', title: '本次年审日期',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time14',
valueType: 'dateRange', valueType: 'dateRange',
@ -338,7 +339,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '下次年审日期', title: '下次年审日期',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time15',
valueType: 'dateRange', valueType: 'dateRange',
@ -353,7 +354,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '注册登记日期', title: '注册登记日期',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time16',
valueType: 'dateRange', valueType: 'dateRange',
@ -368,7 +369,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '运力来源', title: '运力来源',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time17',
valueType: 'dateRange', valueType: 'dateRange',
@ -383,7 +384,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '有效期起', title: '有效期起',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time18',
valueType: 'dateRange', valueType: 'dateRange',
@ -398,7 +399,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '有效期止', title: '有效期止',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time19',
valueType: 'dateRange', valueType: 'dateRange',
@ -413,7 +414,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '发动机排量', title: '发动机排量',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time20',
valueType: 'dateRange', valueType: 'dateRange',
@ -428,7 +429,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '发动机号', title: '发动机号',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time21',
valueType: 'dateRange', valueType: 'dateRange',
@ -443,7 +444,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '车辆发动机功率', title: '车辆发动机功率',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time22',
valueType: 'dateRange', valueType: 'dateRange',
@ -458,7 +459,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '经营许可证号', title: '经营许可证号',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time23',
valueType: 'dateRange', valueType: 'dateRange',
@ -473,7 +474,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '车牌颜色', title: '车牌颜色',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time24',
valueType: 'dateRange', valueType: 'dateRange',
@ -488,7 +489,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '车辆总质量', title: '车辆总质量',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time25',
valueType: 'dateRange', valueType: 'dateRange',
@ -503,7 +504,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '车辆准牵引总质量', title: '车辆准牵引总质量',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time26',
valueType: 'dateRange', valueType: 'dateRange',
@ -518,7 +519,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '道路运输证号', title: '道路运输证号',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time27',
valueType: 'dateRange', valueType: 'dateRange',
@ -533,7 +534,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '车辆车高', title: '车辆车高',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time28',
valueType: 'dateRange', valueType: 'dateRange',
@ -548,7 +549,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '车辆车长', title: '车辆车长',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time29',
valueType: 'dateRange', valueType: 'dateRange',
@ -563,7 +564,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '车辆车宽', title: '车辆车宽',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time30',
valueType: 'dateRange', valueType: 'dateRange',
@ -578,7 +579,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '车辆类型', title: '车辆类型',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time31',
valueType: 'dateRange', valueType: 'dateRange',
@ -593,7 +594,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '行驶证车辆类型', title: '行驶证车辆类型',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time30',
valueType: 'dateRange', valueType: 'dateRange',
@ -608,7 +609,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '车辆轴距', title: '车辆轴距',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time31',
valueType: 'dateRange', valueType: 'dateRange',
@ -623,7 +624,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '等级评定日期', title: '等级评定日期',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time32',
valueType: 'dateRange', valueType: 'dateRange',
@ -638,7 +639,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '技术评定等级', title: '技术评定等级',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time33',
valueType: 'dateRange', valueType: 'dateRange',
@ -653,7 +654,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '下次等级评定日期', title: '下次等级评定日期',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time34',
valueType: 'dateRange', valueType: 'dateRange',
@ -668,7 +669,7 @@ const OperaTionalTable = (props) => {
}, { }, {
title: '创建日期', title: '创建日期',
search: false, search: false,
dataIndex: 'time9', dataIndex: 'time35',
valueType: 'dateRange', valueType: 'dateRange',
@ -683,7 +684,7 @@ const OperaTionalTable = (props) => {
}, },
{ {
title: '操作', title: '操作',
dataIndex: 'creatTime', dataIndex: 'creatTime55',
valueType: 'dateTimeRange', valueType: 'dateTimeRange',
hideInSearch: true, hideInSearch: true,
width: 120, width: 120,
@ -693,6 +694,7 @@ const OperaTionalTable = (props) => {
onClick={() => { onClick={() => {
openModal('edit', record) openModal('edit', record)
setTypecard('111') setTypecard('111')
setRecortd(record)
}} }}
>编辑</Button><Button type="link" >编辑</Button><Button type="link"
onClick={() => { onClick={() => {
@ -1332,6 +1334,7 @@ const OperaTionalTable = (props) => {
onClick={() => { onClick={() => {
openModal('edit', record) openModal('edit', record)
setTypecard('111') setTypecard('111')
setRecortd(record)
}} }}
>编辑</Button><Button type="link" >编辑</Button><Button type="link"
onClick={() => { onClick={() => {
@ -1903,7 +1906,7 @@ const OperaTionalTable = (props) => {
options={false} options={false}
ref={c => { finishedProductTable = c; }} ref={c => { finishedProductTable = c; }}
style={{ width: "100% ", overflow: "auto", height: '760px' }} style={{ width: "100% ", overflow: "auto", height: '760px' }}
rowKey='key' rowKey='id'
rowSelection={{ rowSelection={{
selectedRowKeys: rowSelected, selectedRowKeys: rowSelected,
onChange: (selectedRowKeys) => { onChange: (selectedRowKeys) => {
@ -1987,6 +1990,7 @@ const OperaTionalTable = (props) => {
data={rewkeys==='yehu'?data:date} data={rewkeys==='yehu'?data:date}
recortd={recortd} recortd={recortd}
// sitename={sitename} // sitename={sitename}
setDelet={setDelet}
setRecortd={setRecortd} setRecortd={setRecortd}
/> : ''} /> : ''}
{modalVisibleyilan ? <HightModal {modalVisibleyilan ? <HightModal
@ -1996,6 +2000,7 @@ const OperaTionalTable = (props) => {
typecard={typecard} typecard={typecard}
rewkeys={'passenger'} rewkeys={'passenger'}
recortd={recortd} recortd={recortd}
setDelet={setDelet}
setRecortd={setRecortd} setRecortd={setRecortd}
/> : ''} /> : ''}
</Spin > </Spin >

20
web/client/src/sections/fillion/components/project/project.js

@ -17,7 +17,7 @@ const data = {
"projectProgress": "项目进展情况" "projectProgress": "项目进展情况"
} }
const ProjectModal = (props) => { const ProjectModal = (props) => {
const { visible, onVisibleChange, typecard, rewkeys, recortd, sitename, dispatch, setRecortd, engineering } = props const { visible, onVisibleChange, typecard, rewkeys, recortd, dispatch, setRecortd, setDelet } = props
const [newlys, setNewlys] = useState() //必填数据 const [newlys, setNewlys] = useState() //必填数据
const [newlysay, setNewlysay] = useState() //处理hou const [newlysay, setNewlysay] = useState() //处理hou
const [records, setRecords] = useState()//处理 const [records, setRecords] = useState()//处理
@ -80,13 +80,16 @@ const ProjectModal = (props) => {
onFinish={(values) => { onFinish={(values) => {
if (rewkeys === 'road') { if (rewkeys === 'road') {
if (typecard == '111') { if (typecard == '111') {
console.log(values) setDelet(values)
setDelet(values)
const query = { ...values, type:rewkeys } const query = { ...values, type:rewkeys }
dispatch(putProject(query)).then((res) => { dispatch(putProject(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
}) })
return success return success
} else { } else {
setDelet(values)
const query = { ...values, type:rewkeys } const query = { ...values, type:rewkeys }
dispatch(putProject(query)).then((res) => { dispatch(putProject(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
@ -96,13 +99,14 @@ const ProjectModal = (props) => {
} }
if (rewkeys === 'bridge') { if (rewkeys === 'bridge') {
if (typecard == '111') { if (typecard == '111') {
console.log(values) setDelet(values)
const query = { ...values, type:rewkeys } const query = { ...values, type:rewkeys }
dispatch(putProject(query)).then((res) => { dispatch(putProject(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
}) })
return success return success
} else { } else {
setDelet(values)
const query = { ...values, type:rewkeys } const query = { ...values, type:rewkeys }
dispatch(putProject(query)).then((res) => { dispatch(putProject(query)).then((res) => {
setSuccess(res.success) setSuccess(res.success)
@ -120,7 +124,7 @@ const ProjectModal = (props) => {
name={newlys?.[0]?.type} name={newlys?.[0]?.type}
width="md" width="md"
label={newlys?.[0]?.name} label={newlys?.[0]?.name}
tooltip="最长为 24 位"
placeholder="请输入名称" placeholder="请输入名称"
// value={recordsay?.[0]?.value} // value={recordsay?.[0]?.value}
rules={[{ required: true, message: "必填" }]} rules={[{ required: true, message: "必填" }]}
@ -128,7 +132,7 @@ const ProjectModal = (props) => {
name={newlys?.[1]?.type} name={newlys?.[1]?.type}
width="md" width="md"
label={newlys?.[1]?.name} label={newlys?.[1]?.name}
tooltip="最长为 24 位"
placeholder="请输入名称" placeholder="请输入名称"
// value={recordsay?.[1]?.value} // value={recordsay?.[1]?.value}
rules={[{ required: true, message: "必填" }]} rules={[{ required: true, message: "必填" }]}
@ -160,7 +164,7 @@ const ProjectModal = (props) => {
name={newlys?.[0]?.type} name={newlys?.[0]?.type}
width="md" width="md"
label={newlys?.[0]?.name} label={newlys?.[0]?.name}
tooltip="最长为 24 位"
placeholder="请输入名称" placeholder="请输入名称"
// value={recordssy?.[0]?.value} // value={recordssy?.[0]?.value}
rules={[{ required: true, message: "必填" }]} rules={[{ required: true, message: "必填" }]}
@ -168,7 +172,7 @@ const ProjectModal = (props) => {
name={newlys?.[1]?.type} name={newlys?.[1]?.type}
width="md" width="md"
label={newlys?.[1]?.name} label={newlys?.[1]?.name}
tooltip="最长为 24 位"
placeholder="请输入名称" placeholder="请输入名称"
// value={recordssy?.[1]?.value} // value={recordssy?.[1]?.value}
rules={[{ required: true, message: "必填" }]} rules={[{ required: true, message: "必填" }]}
@ -190,7 +194,7 @@ const ProjectModal = (props) => {
{newlysay?.map((item, index) => { {newlysay?.map((item, index) => {
return <ProFormText width="md" return <ProFormText width="md"
name={item?.type} label={newlysay[index]?.name} placeholder="请输入名称" key={index} name={item?.type} label={newlysay[index]?.name} placeholder="请输入名称" key={index}
tooltip="最长为 24 位"
/> />
})} })}

3
web/client/src/sections/fillion/components/publicTable.js

@ -24,7 +24,7 @@ const PublicTable = (props) => {
const [delet, setDelet] = useState() const [delet, setDelet] = useState()
const ref = useRef() const ref = useRef()
useEffect(() => { ref.current.reload() }, [modalVisible,delet,rewkeys]) useEffect(() => { ref.current.reload() }, [delet,rewkeys])
//xianlu请求 //xianlu请求
const requestxianlu = (name) => { const requestxianlu = (name) => {
const query = name const query = name
@ -1261,6 +1261,7 @@ const requestcheliang = (name) => {
data={rewkeys==='xianlu'?data:date} data={rewkeys==='xianlu'?data:date}
recortd={recortd} recortd={recortd}
// sitename={sitename} // sitename={sitename}
setDelet={setDelet}
setRecortd={setRecortd} setRecortd={setRecortd}
/> : ''} /> : ''}
</Spin > </Spin >

15
web/client/src/sections/fillion/components/transportationTable.js

@ -11,7 +11,7 @@ import ProjectModal from './project/project';
const TransporTationTable = (props) => { const TransporTationTable = (props) => {
const { dispatch, user, depData, depMessage, depLoading } = props const { dispatch, user, depData, depMessage, depLoading } = props
const [rowSelected, setRowSelected] = useState([]) const [rowSelected, setRowSelected] = useState([])
const [sitename, setSitename] = useState()//桥梁名称 const [sitename, setSitename] = useState()//名称
const [counts, setCounts] = useState()//shuju const [counts, setCounts] = useState()//shuju
const [modalVisible, setModalVisible] = useState(false); const [modalVisible, setModalVisible] = useState(false);
const [modalVisibleyilan, setModalVisibleyilan] = useState(false); const [modalVisibleyilan, setModalVisibleyilan] = useState(false);
@ -19,10 +19,10 @@ const TransporTationTable = (props) => {
const [typecard, setTypecard] = useState(); const [typecard, setTypecard] = useState();
const [activeKey, setActiveKey] = useState('tab1'); const [activeKey, setActiveKey] = useState('tab1');
const [recortd, setRecortd] = useState() const [recortd, setRecortd] = useState()
const [whichofits, setWhichofits] = useState('xian') const [whichofits, setWhichofits] = useState('')
const [delet, setDelet] = useState() const [delet, setDelet] = useState()
const ref = useRef() const ref = useRef()
useEffect(() => { ref.current.reload() }, [modalVisible, modalVisibleyilan, whichofits, delet]) useEffect(() => { ref.current.reload() }, [ whichofits, delet])
//打开弹窗 //打开弹窗
const openModal = (type, record) => { const openModal = (type, record) => {
setModalVisible(true); setModalVisible(true);
@ -3787,7 +3787,7 @@ const TransporTationTable = (props) => {
columns={columns[activeKey]} columns={columns[activeKey]}
dataSource={counts || []} dataSource={counts || []}
request={async (params) => { request={async (params) => {
if (whichofits == 'xian') { if (whichofits == '') {
const query = { const query = {
level: '县', level: '县',
road: sitename road: sitename
@ -3801,7 +3801,7 @@ const TransporTationTable = (props) => {
...res, ...res,
total: res.payload.data ? res.payload.data.count : 0 total: res.payload.data ? res.payload.data.count : 0
} }
} if (whichofits == 'xiang') { } if (whichofits == '') {
const query = { const query = {
level: '乡', level: '乡',
road: sitename road: sitename
@ -3813,7 +3813,7 @@ const TransporTationTable = (props) => {
...res, ...res,
total: res.payload.data ? res.payload.data.count : 0 total: res.payload.data ? res.payload.data.count : 0
} }
} if (whichofits == 'cun') { } if (whichofits == '') {
const query = { const query = {
level: '村', level: '村',
road: sitename road: sitename
@ -3863,8 +3863,9 @@ const TransporTationTable = (props) => {
rewkeys={'transportation'} rewkeys={'transportation'}
data={data} data={data}
recortd={recortd} recortd={recortd}
sitename={sitename} whichofits={whichofits}
setRecortd={setRecortd} setRecortd={setRecortd}
setDelet={setDelet}
/> : ''} /> : ''}
{modalVisibleyilan ? <ProjectModal {modalVisibleyilan ? <ProjectModal
visible={modalVisibleyilan} visible={modalVisibleyilan}

5
web/client/src/sections/organization/components/depModal.js

@ -11,7 +11,8 @@ const DepModal = (props) => {
if (depModalType === 'edit') { if (depModalType === 'edit') {
let value = { let value = {
name: values.name, name: values.name,
depId: data.id depId: data.id,
dependence:values.dependence
} }
onConfirm(value) onConfirm(value)
} else { } else {
@ -30,7 +31,7 @@ const DepModal = (props) => {
onFinish={onFinish} onFinish={onFinish}
formRef={formRef} formRef={formRef}
destroyOnClose destroyOnClose
initialValues={data || null} initialValues={depModalType === 'edit' ? data : null}
> >
<ProFormText <ProFormText
name={['name']} name={['name']}

2
web/client/src/sections/organization/components/userModal.js

@ -45,7 +45,7 @@ const UserModal = (props) => {
label="姓名" label="姓名"
required required
placeholder="请输入姓名" placeholder="请输入姓名"
rules={[{ required: true, message: '请输入姓名' },{ max: 10, message: '请输入10个字以内的名称' }]} rules={[{ required: true, message: '请输入姓名' },{ max: 5, message: '请输入5个字以内的名称' }]}
/> />
< ProFormText < ProFormText
name={['contract', 'phone']} name={['contract', 'phone']}

3
web/client/src/sections/organization/containers/user.js

@ -168,7 +168,10 @@ const UserManage = (props) => {
} }
//部门新增及编辑 //部门新增及编辑
const onDepConfirm = (data) => { const onDepConfirm = (data) => {
console.log('depModalType:',depModalType);
console.log('data:',data);
if (depModalType == 'edit') { if (depModalType == 'edit') {
dispatch(updateDep(data)).then(res => { dispatch(updateDep(data)).then(res => {
if (res.success) { if (res.success) {
setDepModalVisible(false); setDepModalVisible(false);

4
web/client/src/sections/quanju/containers/footer/build/Leftbottom.js

@ -24,8 +24,8 @@ function Leftbottom(props) {
const chartTitle = '道路总公里'; const chartTitle = '道路总公里';
const title = '基础设施安全监测版块'; const title = '基础设施安全监测版块';
let name = [], emptyName = [] let name = [], emptyName = []
console.log(data,'传入的值') // console.log(data,'传入的值')
console.log(emptyName,'第二个') // console.log(emptyName,'第二个')
// const name = data?.map(d) // const name = data?.map(d)
data?.forEach(d => { data?.forEach(d => {
name.push(d.name) name.push(d.name)

4
web/client/src/sections/quanju/containers/footer/build/Rightcenter.js

@ -27,7 +27,7 @@ const THIRD = "linear-gradient(360deg, rgba(148, 148, 255, 0.1) 0%, rgba(148, 14
const OTHER = "linear-gradient(360deg, rgba(28, 96, 253, 0) 0%, rgba(28, 96, 253, 0.2) 100%)" const OTHER = "linear-gradient(360deg, rgba(28, 96, 253, 0) 0%, rgba(28, 96, 253, 0.2) 100%)"
let TOTALS = data?.map(({ name, total }, index) => { let TOTALS = data?.map(({ name, total }, index) => {
let max = Math.max(...data.map(item=>item.total)) let max = Math.max(...data.map(item=>item.total))
console.log(data.map(item=>item.total),'好朋友吗') // console.log(data.map(item=>item.total),'好朋友吗')
return { return {
name, name,
value: total, value: total,
@ -38,7 +38,7 @@ let new_TOTALS = TOTALS && TOTALS.length > 10 ? TOTALS.slice(0, 10) : TOTALS
function Cell(props) { function Cell(props) {
const { name, rank, value, percent, style = {},cebg } = props const { name, rank, value, percent, style = {},cebg } = props
let bg = RNAKS[rank] || OTHER let bg = RNAKS[rank] || OTHER
console.log(percent,'百分比') // console.log(percent,'百分比')
return <div style={{ return <div style={{
width: "100%", height: 34, display: "flex", justifyContent: 'center', width: "100%", height: 34, display: "flex", justifyContent: 'center',
alignItems: "center", marginTop: 7, marginBottom: 7, alignItems: "center", marginTop: 7, marginBottom: 7,

2
web/client/src/sections/quanju/containers/footer/build/index.js

@ -49,7 +49,7 @@ const Build = (props) => {
// setdata(alltype.filter(item=>item.name!=='null')) // setdata(alltype.filter(item=>item.name!=='null'))
setxuandata(res.payload.data) setxuandata(res.payload.data)
console.log(res.payload.data,'宣传栏数据') // console.log(res.payload.data,'宣传栏数据')
} }
let t1 = Object.values(buildingnumber?.townRoad || {}) let t1 = Object.values(buildingnumber?.townRoad || {})

3
web/client/src/sections/quanju/containers/footer/conserve/right/right-center.js

@ -14,7 +14,8 @@ const RightCenter = (props) => {
const style = { height: "31%", marginTop: "3%" } const style = { height: "31%", marginTop: "3%" }
const textStyle = { fontSize: 14, color: '#E9F7FF' } const textStyle = { fontSize: 14, color: '#E9F7FF' }
const numStyle = { color: '#fff', fontSize: 21, fontFamily: 'YouSheBiaoTiHei', textShadow: '0px 0px 8px #1C60FE', marginTop: 8 } const numStyle = { color: '#fff', fontSize: 21, fontFamily: 'YouSheBiaoTiHei', textShadow: '0px 0px 8px #1C60FE', marginTop: 8 }
const list = highwaysData?.slice(4, 8).map((h,index)=>{ let list = highwaysData?.sort((a, b) => a.id - b.id)
list = highwaysData?.slice(4, 8).map((h,index)=>{
return { return {
id:h.id, id:h.id,
name:h.name, name:h.name,

13
web/client/src/sections/quanju/containers/footer/conserve/right/right-top.js

@ -16,13 +16,14 @@ const RightTop = (props) => {
const style = { height: "31%", marginTop: "3%" } const style = { height: "31%", marginTop: "3%" }
const textStyle = { fontSize: 14, color: '#E9F7FF' } const textStyle = { fontSize: 14, color: '#E9F7FF' }
const numStyle = { color: '#fff', fontSize: 21, fontFamily: 'YouSheBiaoTiHei', textShadow: '0px 0px 8px #1C60FE', marginTop: 8 } const numStyle = { color: '#fff', fontSize: 21, fontFamily: 'YouSheBiaoTiHei', textShadow: '0px 0px 8px #1C60FE', marginTop: 8 }
const list = highwaysData?.slice(0, 4).map((h,index)=>{ let list = highwaysData?.sort((a, b) => a.id - b.id)
list = highwaysData?.slice(0, 4).map((h, index) => {
return { return {
id:h.id, id: h.id,
name:h.name, name: h.name,
count:h.count, count: h.count,
unit:unit[index], unit: unit[index],
icon:iconSrc[index] icon: iconSrc[index]
} }
}) })

6
web/client/src/sections/quanju/containers/footer/guanli/index.js

@ -39,14 +39,14 @@ const Guanli = (props) => {
return item.processingTime = `${(item.processingTime.match(/^([^.]*)(.[^.]*)/)[0])}.0${parseInt(item.processingTime.match(/([^.]*)$/)[0])}` return item.processingTime = `${(item.processingTime.match(/^([^.]*)(.[^.]*)/)[0])}.0${parseInt(item.processingTime.match(/([^.]*)$/)[0])}`
} }
// console.log(d3,'好评') // console.log(d3,'好评')
console.log(item.processingTime.match(/([^.]*)$/)[0],'kk') // console.log(item.processingTime.match(/([^.]*)$/)[0],'kk')
}) })
d.sort((a, b) => b.processingTime.localeCompare(a.processingTime)) d.sort((a, b) => b.processingTime.localeCompare(a.processingTime))
setrightDatas(res.payload.data) setrightDatas(res.payload.data)
setrightitemlist(d) setrightitemlist(d)
console.log(d,'对比的数据') // console.log(d,'对比的数据')
// console.log(d2,'完美') // console.log(d2,'完美')
console.log(res.payload.data,'嘿嘿嘿') // console.log(res.payload.data,'嘿嘿嘿')
} }
useEffect(()=>{ useEffect(()=>{
requestleftDatas(); requestleftDatas();

2
web/client/src/sections/quanju/containers/heand/index.js

@ -21,7 +21,7 @@ const Header = (props) => {
<div className={tabKey == "build" ? "tabKey-map" : "notabKey"} style={{ backgroundImage: "url(/assets/images/quanju/zuobeijing.png)", backgroundSize: "100% 100%" }} onClick={() => { <div className={tabKey == "build" ? "tabKey-map" : "notabKey"} style={{ backgroundImage: "url(/assets/images/quanju/zuobeijing.png)", backgroundSize: "100% 100%" }} onClick={() => {
onClick("build") onClick("build")
}}><a>建设</a></div> }}><a>建设</a></div>
<div className={tabKey == "guanli" ? "tabKey-map" : "notabKey"} style={{ left: "11.5%", backgroundImage: "url(/assets/images/quanju/youbeijing.png)", backgroundSize: "100% 100%" }} onClick={() => { <div className={tabKey == "guanli" ? "tabKey-map" : "notabKey"} style={{ left: "11.5%", backgroundImage: "url(/assets/images/quanju/zuobeijing.png)", backgroundSize: "100% 100%" }} onClick={() => {
onClick("guanli") onClick("guanli")
}}><a>管理</a></div> }}><a>管理</a></div>
<div className={tabKey == "leadership" ? "tabKey-map" : "notabKey"} style={{ left: "23%", backgroundImage: "url(/assets/images/quanju/zuobeijing.png)", backgroundSize: "100% 100%" }} onClick={() => { <div className={tabKey == "leadership" ? "tabKey-map" : "notabKey"} style={{ left: "23%", backgroundImage: "url(/assets/images/quanju/zuobeijing.png)", backgroundSize: "100% 100%" }} onClick={() => {

8
web/config.js

@ -41,16 +41,16 @@ const product = {
host: 'https://report.amap.com', host: 'https://report.amap.com',
match: /^\/_godTrans\//, match: /^\/_godTrans\//,
} }
}, {
entry: require('./client').entry,// 静态信息
opts: {}
}, { }, {
entry: require('./routes').entry, entry: require('./routes').entry,
opts: { opts: {
apiUrl: FS_UNIAPP_API, apiUrl: FS_UNIAPP_API,
staticRoot: './client', staticRoot: './client',
} }
},], }, {
entry: require('./client').entry,// 静态信息
opts: {}
}],
logger: { logger: {
level: 'debug', level: 'debug',
json: false, json: false,

2
web/package.json

@ -6,7 +6,7 @@
"scripts": { "scripts": {
"test": "mocha", "test": "mocha",
"start": "cross-env NODE_ENV=development npm run start-params", "start": "cross-env NODE_ENV=development npm run start-params",
"start-params": "npm run color && node server -p 5000 -u http://10.8.30.7:14000", "start-params": "node server -p 5000 -u http://10.8.30.7:14000",
"deploy": "export NODE_ENV=production&&npm run color && npm run build && node server", "deploy": "export NODE_ENV=production&&npm run color && npm run build && node server",
"build-dev": "export NODE_ENV=development&&webpack --config webpack.config.js", "build-dev": "export NODE_ENV=development&&webpack --config webpack.config.js",
"build": "export NODE_ENV=production&&webpack --config webpack.config.prod.js", "build": "export NODE_ENV=production&&webpack --config webpack.config.prod.js",

2
web/routes/attachment/index.js

@ -17,10 +17,8 @@ const ext = {
module.exports = { module.exports = {
entry: function (app, router, opts) { entry: function (app, router, opts) {
const getApiRoot = async function (ctx) { const getApiRoot = async function (ctx) {
const { apiUrl } = opts; const { apiUrl } = opts;
ctx.status = 200; ctx.status = 200;
ctx.body = { root: apiUrl }; ctx.body = { root: apiUrl };
}; };

Loading…
Cancel
Save