Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
CivManage
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ReactWeb5
CivManage
Commits
e3c863de
Commit
e3c863de
authored
4 years ago
by
张烨
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
https://g.civnet.cn:8443/test/maintenance
parents
a7a26393
9bf4df9c
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
262 additions
and
6 deletions
+262
-6
BasicLayout.js
src/layouts/BasicLayout.js
+2
-2
InitDataBase.jsx
src/pages/database/InitDataBase.jsx
+1
-0
ManagementDataBase.jsx
src/pages/database/ManagementDataBase.jsx
+10
-1
DefaultComponent.jsx
src/pages/orgnazation/DefaultComponent.jsx
+24
-0
ListCard.jsx
src/pages/orgnazation/ListCard.jsx
+8
-2
SiteManage.jsx
src/pages/userCenter/siteManage/SiteManage.jsx
+64
-0
SiteManage.less
src/pages/userCenter/siteManage/SiteManage.less
+4
-0
config.js
src/routes/config.js
+1
-1
menuConfig.js
src/routes/menuConfig.js
+137
-0
api.js
src/services/database/api.js
+0
-0
api.js
src/services/userCenter/siteManage/api.js
+11
-0
No files found.
src/layouts/BasicLayout.js
View file @
e3c863de
...
...
@@ -48,9 +48,9 @@ const BasicLayout = props => {
style
=
{{
height
:
'100vh'
}}
onCollapse
=
{
handleMenuCollapse
}
onMenuHeaderClick
=
{()
=>
{}}
footerRender
=
{()
=>
defaultFooterDom
}
//
footerRender={() => defaultFooterDom}
rightContentRender
=
{()
=>
<
RightContent
/>
}
title
=
"熊猫运维
系统
"
title
=
"熊猫运维
平台
"
route
=
{
{
// routes: config.routes,
...
...
This diff is collapsed.
Click to expand it.
src/pages/database/InitDataBase.jsx
View file @
e3c863de
...
...
@@ -196,6 +196,7 @@ const InitDataBase = props => {
};
// 点击表格回显到表单
const
tableClick
=
item
=>
{
console
.
log
(
item
)
let
obj
=
{
...
dbForm
};
Object
.
keys
(
obj
).
forEach
(
k
=>
{
obj
[
k
]
=
item
[
k
];
...
...
This diff is collapsed.
Click to expand it.
src/pages/database/ManagementDataBase.jsx
View file @
e3c863de
...
...
@@ -77,6 +77,11 @@ const ManagementDataBase = () => {
console
.
log
(
'updatedb'
);
};
const
handleLog
=
text
=>
{
let
arr
=
[]
arr
.
push
(
text
.
split
(
/
[
(
\r\n
)
\r\n]
+/
).
map
(
item
=>
{
return
(<
p
>
$
{
item
}
</
p
>)
}))
setModalVisible
(
true
);
setContent
(
text
);
};
...
...
@@ -155,6 +160,7 @@ const ManagementDataBase = () => {
key
:
'content'
,
ellipsis
:
true
,
render
:
text
=>
{
return
(
<
Button
size=
'small'
...
...
@@ -226,8 +232,11 @@ const ManagementDataBase = () => {
onCancel=
{
()
=>
setModalVisible
(
false
)
}
width=
"1000px"
bodyStyle=
{
{
minHeight
:
'100px'
minHeight
:
'100px'
,
maxHeight
:
'600px'
,
overflowY
:
'scroll'
}
}
style=
{
{
top
:
"40px"
}
}
footer=
{
[
<
Button
type=
'primary'
onClick=
{
()
=>
setModalVisible
(
false
)
}
>
关闭窗口
</
Button
>,
]
}
...
...
This diff is collapsed.
Click to expand it.
src/pages/orgnazation/DefaultComponent.jsx
View file @
e3c863de
...
...
@@ -182,6 +182,11 @@ const DefaultComponent = ()=> {
const
btnLable
=
[
{
label
:
'查找用户'
,
handle
:
handleSearch
,
config
:{
type
:
'primary'
,
danger
:
true
}
},
{
label
:
'用户导入'
,
handle
:
handleImport
,
config
:{
type
:
'info'
,}},
<
<<<<<<
Updated
upstream
=======
{
label
:'新建用户',
handle
:'
newHandle
'},
{
label
:'批量关联',
handle
:'
relHandle
'}
>
>>>>>>
Stashed changes
]
return (
...
...
@@ -189,7 +194,11 @@ const DefaultComponent = ()=> {
<
PageContainer
>
<
Card
>
<
Row
>
<
<<<<<<
Updated
upstream
<
Col
span
={1}
>
=======
<
Col
span
={2}
>
>>>>>>>
Stashed changes
<
div
style=
{
{
height
:
"30px"
,
lineHeight
:
"30px"
}
}
>
机构选择
</
div
>
...
...
@@ -211,6 +220,7 @@ const DefaultComponent = ()=> {
/> */
}
</
Col
>
</
Row
>
<
<<<<<<
Updated
upstream
<
div
style=
{
{
marginTop
:
'20px'
,
textAlign
:
'center'
}
}
>
<
Space
>
{
...
...
@@ -223,6 +233,20 @@ const DefaultComponent = ()=> {
}
</
Space
>
</
div
>
=======
</
Card
>
<
Card
>
<
Space
>
{
btnLable
&&
btnLable
.
map
(
(
item
,
index
)
=>
{
const
{
config
}
=
item
return
(
<
Button
key=
{
index
}
{
...
config
}
onClick
={
()=
>
{
item
.
handle
&&
typeof
item
.
handle
===
'function'
&&
item
.
handle
()
}
}
>
{
item
.
label
}
</
Button
>
)
})
}
</
Space
>
>>>>>>>
Stashed changes
<
TestModal
title=
'用户选择'
visible
=
{
modalVisible
}
...
...
This diff is collapsed.
Click to expand it.
src/pages/orgnazation/ListCard.jsx
View file @
e3c863de
...
...
@@ -3,6 +3,8 @@ import ListCardItem from './listCardItem'
import
{
get
,
post
}
from
'../../services'
;
import
{
orgTest
}
from
'../../services/orgnazation/api'
const
ListCard
=
(
props
)
=>
{
const
{
ouid
}
=
props
console
.
log
(
ouid
)
const
[
valueList
,
setValueList
]
=
useState
([])
const
[
testList
,
setTestList
]
=
useState
([])
const
{
optionsList
}
=
props
...
...
@@ -19,7 +21,11 @@ const ListCard = (props) =>{
title
:
'默认组'
,
id
:
''
,
}
get
(
"/Cityinterface/rest/services/OMS.svc/U_GetUserListForBatchOper?OUID=24&_version=9999&_dc=1603781551787"
).
then
(
res
=>
{
get
(
"/Cityinterface/rest/services/OMS.svc/U_GetUserListForBatchOper"
,{
OUID
:
ouid
||
''
,
_version
:
9999
,
_dc
:
new
Date
().
getTime
()
}).
then
(
res
=>
{
const
list
=
[]
res
&&
res
.
map
(
item
=>
{
list
.
push
({...
defaultConfig
,...
item
})
...
...
@@ -30,7 +36,7 @@ const ListCard = (props) =>{
orgTest
().
then
(
res
=>
{
console
.
log
(
res
,
'res'
)
})
},[])
},[
ouid
])
return
(
<>
{
...
...
This diff is collapsed.
Click to expand it.
src/pages/userCenter/siteManage/SiteManage.jsx
0 → 100644
View file @
e3c863de
import
React
,
{
useState
,
useEffect
}
from
'react'
;
import
{
Row
,
Col
,
Tree
,
Card
}
from
'antd'
;
import
{
DownOutlined
}
from
'@ant-design/icons'
;
import
{
PageContainer
,
GridContent
}
from
'@ant-design/pro-layout'
;
import
{
getOUTree
}
from
'@/services/userCenter/siteManage/api'
;
import
ListCard
from
'@/pages/orgnazation/ListCard'
;
import
styles
from
'@/pages/userCenter/siteManage/SiteManage.less'
const
SiteManage
=
()
=>
{
const
[
treeData
,
setTreeData
]
=
useState
([])
const
[
ouid
,
setOuid
]
=
useState
(
''
)
//点击树的回调
const
handleTreeSelect
=
(
e
)
=>
{
console
.
log
(
e
)
let
id
=
e
[
0
]
setOuid
(
id
)
}
useEffect
(()
=>
{
getOUTree
().
then
(
res
=>
{
let
arr
=
transTree
(
res
)
setTreeData
(
arr
)
})
},[])
const
transTree
=
(
val
)
=>
{
let
arr
=
val
return
arr
.
map
(
item
=>
{
item
.
title
=
item
.
text
item
.
key
=
item
.
id
let
obj
=
{}
if
(
Array
.
isArray
(
item
.
children
)
&&
item
.
children
.
length
>
0
){
transTree
(
item
.
children
)
return
obj
=
item
}
else
{
return
item
}
})
}
return
(
<
PageContainer
>
<
GridContent
>
<
Row
gutter=
{
12
}
>
<
Col
lg=
{
6
}
md=
{
24
}
>
<
Card
className=
{
styles
.
cardBox
}
>
<
Tree
showLine
showIcon=
{
<
DownOutlined
/>
}
onSelect=
{
(
e
)
=>
handleTreeSelect
(
e
)
}
treeData=
{
treeData
}
/>
</
Card
>
</
Col
>
<
Col
lg=
{
18
}
md=
{
24
}
>
<
Card
className=
{
styles
.
cardBox
}
>
<
ListCard
ouid=
{
ouid
}
></
ListCard
>
</
Card
>
</
Col
>
</
Row
>
</
GridContent
>
</
PageContainer
>
)
}
export
default
SiteManage
This diff is collapsed.
Click to expand it.
src/pages/userCenter/siteManage/SiteManage.less
0 → 100644
View file @
e3c863de
.cardBox{
min-height: calc(100vh - 200px);
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
src/routes/config.js
View file @
e3c863de
...
...
@@ -19,7 +19,7 @@ import InitDataBase from '../pages/database/InitDataBase';
import
ManagementDataBase
from
'../pages/database/ManagementDataBase'
;
import
UserManage
from
'../pages/userCenter/UserManage'
;
import
RoleManage
from
'../pages/userCenter/RoleManage'
;
import
SiteManage
from
'../pages/userCenter/SiteManage'
;
import
SiteManage
from
'../pages/userCenter/
siteManage/
SiteManage'
;
// import DefaultComponent from '../pages/orgnazation/DefaultComponent';
import
TestTable
from
'../pages/orgnazation/TestTable'
;
import
{
USER_MODE
}
from
'@/utils/constants'
;
...
...
This diff is collapsed.
Click to expand it.
src/routes/menuConfig.js
0 → 100644
View file @
e3c863de
import
React
from
'react'
;
import
{
DatabaseOutlined
,
UsergroupAddOutlined
,
SettingOutlined
,
HomeOutlined
,
// AndroidOutlined,
// CommentOutlined,
CopyOutlined
,
}
from
'@ant-design/icons'
;
const
iconStyle
=
{
verticalAlign
:
'0.125em'
};
const
menuConfig
=
[
{
path
:
'/dbm'
,
component
:
'BasicLayout'
,
name
:
'数据库管理'
,
icon
:
<
DatabaseOutlined
style
=
{
iconStyle
}
/>
,
routes
:
[
{
path
:
'/dbm/dbInit'
,
name
:
'数据库初始化'
,
},
{
path
:
'/dbm/dbsm'
,
name
:
'数据库标准化管理'
,
},
],
},
{
path
:
'/userCenter'
,
component
:
'BasicLayout'
,
name
:
'用户中心'
,
icon
:
<
UsergroupAddOutlined
style
=
{
iconStyle
}
/>
,
routes
:
[
{
path
:
'/userCenter/UserManage'
,
name
:
'用户管理'
,
},
{
path
:
'/userCenter/RoleManage'
,
name
:
'角色管理'
,
},
{
path
:
'/userCenter/SiteManage'
,
name
:
'站点管理'
,
},
{
path
:
'/userCenter/testTable'
,
name
:
'测试表格'
,
},
],
},
{
path
:
'/platformCenter'
,
component
:
'BasicLayout'
,
name
:
'平台中心'
,
icon
:
<
SettingOutlined
style
=
{
iconStyle
}
/>
,
routes
:
[
{
path
:
'/platformCenter/gis'
,
name
:
'GIS平台'
,
},
{
path
:
'/platformCenter/order'
,
name
:
'工单平台'
,
},
{
path
:
'/platformCenter/notify'
,
name
:
'消息平台'
,
},
{
path
:
'/platformCenter/iot'
,
name
:
'物联平台'
,
},
{
path
:
'/platformCenter/vedio'
,
name
:
'视频管理'
,
},
{
path
:
'/platformCenter/emq'
,
name
:
'宿主管理'
,
},
{
path
:
'/platformCenter/dictionary'
,
name
:
'数据字典'
,
},
],
},
{
path
:
'/productCenter'
,
component
:
'BasicLayout'
,
name
:
'产品中心'
,
icon
:
<
HomeOutlined
style
=
{
iconStyle
}
/>
,
routes
:
[
{
path
:
'/productCenter/web'
,
name
:
'web配置'
,
},
{
path
:
'/productCenter/app'
,
name
:
'app配置'
,
},
{
path
:
'/productCenter/miniProgram'
,
name
:
'小程序配置'
,
},
],
},
{
path
:
'/log'
,
component
:
'BasicLayout'
,
name
:
'日志管理'
,
icon
:
<
CopyOutlined
style
=
{
iconStyle
}
/>
,
routes
:
[
{
path
:
'/log/service'
,
name
:
'服务日志'
,
},
{
path
:
'/log/login'
,
name
:
'登录日志'
,
},
{
path
:
'/log/omsOperation'
,
name
:
'运维操作日志'
,
},
{
path
:
'/log/omsError'
,
name
:
'运维错误日志'
,
},
],
},
];
export
default
menuConfig
;
This diff is collapsed.
Click to expand it.
src/services/database/api.js
0 → 100644
View file @
e3c863de
This diff is collapsed.
Click to expand it.
src/services/userCenter/siteManage/api.js
0 → 100644
View file @
e3c863de
import
{
get
,
post
}
from
'@/services/index'
;
/*
** params
*/
// 获取机构树
export
const
getOUTree
=
params
=>
get
(
'/Cityinterface/rest/services/OMS.svc/U_GetOUTree?_version=9999&node=-1'
,
params
,
);
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment