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
8e05c038
Commit
8e05c038
authored
Jul 06, 2022
by
皮倩雯
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: '集成登录'
parent
cf73b19f
Pipeline
#54679
failed with stages
Changes
5
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
58 additions
and
26 deletions
+58
-26
AddModal.jsx
src/pages/platformCenter/integratedLogin/AddModal.jsx
+24
-13
Integrate.jsx
src/pages/platformCenter/integratedLogin/Integrate.jsx
+20
-2
PreviewModal.jsx
src/pages/platformCenter/integratedLogin/PreviewModal.jsx
+2
-2
integrate.less
src/pages/platformCenter/integratedLogin/integrate.less
+7
-4
config.js
src/routes/config.js
+5
-5
No files found.
src/pages/platformCenter/integratedLogin/AddModal.jsx
View file @
8e05c038
/* eslint-disable prefer-template */
/* eslint-disable react/jsx-boolean-value */
import
React
,
{
useState
,
useEffect
}
from
'react'
;
import
{
Form
,
Modal
,
Input
,
notification
,
Radio
,
Button
,
message
,
Upload
,
Row
,
Col
}
from
'antd'
;
import
{
Form
,
Modal
,
Input
,
notification
,
Radio
,
Button
,
message
,
Upload
,
Row
,
Col
,
Image
,
}
from
'antd'
;
import
{
AddIntegratedLogin
,
EditIntegratedLogin
}
from
'@/services/integratedLogin/api'
;
import
{
PlusOutlined
,
LoadingOutlined
}
from
'@ant-design/icons'
;
import
{
get
,
PUBLISH_SERVICE
}
from
'@/services'
;
...
...
@@ -26,6 +38,7 @@ const AddModal = props => {
form
.
setFieldsValue
({
accountParam
:
pickItem
.
AccountParam
,
internetAddress
:
pickItem
.
InternetAddress
,
intranetAddress
:
pickItem
.
IntranetAddress
,
systemClient
:
pickItem
.
SystemClient
,
systemName
:
pickItem
.
SystemName
,
iconUrl
:
pickItem
.
iconUrl
,
...
...
@@ -62,6 +75,7 @@ const AddModal = props => {
if
(
validate
)
{
setLoading
(
true
);
let
obj
=
form
.
getFieldsValue
();
console
.
log
(
obj
);
if
(
obj
.
iconUrl
.
file
)
{
obj
.
iconUrl
=
obj
.
iconUrl
.
file
.
response
.
data
;
}
...
...
@@ -221,24 +235,17 @@ const AddModal = props => {
getContainer=
{
false
}
>
<
Form
form=
{
form
}
{
...
layout
}
>
<
Item
label=
"
名称
"
name=
"systemName"
rules=
{
[{
required
:
true
,
message
:
'请输入名称'
}]
}
>
<
Item
label=
"
标题
"
name=
"systemName"
rules=
{
[{
required
:
true
,
message
:
'请输入名称'
}]
}
>
<
Input
allowClear
style=
{
{
width
:
'100%'
}
}
placeholder=
"请输入名称"
/>
</
Item
>
<
Item
label=
"标识"
name=
"systemClient"
rules=
{
[{
required
:
true
,
message
:
'请输入标识'
}]
}
>
<
Input
allowClear
placeholder=
"请输入标识"
/>
</
Item
>
<
Item
label=
"副标题"
name=
"subtitle"
rules=
{
[{
required
:
true
,
message
:
'请输入副标题'
}]
}
>
<
Input
allowClear
placeholder=
"建议使用英文"
/>
</
Item
>
{
/* <Item
label="内网地址"
name="intranetAddress"
rules={[{ required: true, message: '请输入内网地址' }]}
>
<Input allowClear />
</Item> */
}
<
Item
label=
"标识"
name=
"systemClient"
rules=
{
[{
required
:
true
,
message
:
'请输入标识'
}]
}
>
<
Input
allowClear
placeholder=
"请输入标识"
/>
</
Item
>
<
Item
label=
"
访问
地址"
label=
"
外网
地址"
name=
"internetAddress"
rules=
{
[{
required
:
true
,
message
:
'请输入外网地址'
}]
}
>
...
...
@@ -247,6 +254,9 @@ const AddModal = props => {
placeholder=
"示例:http://192.168.12.116:8500/civbase/user/noscret?client=city"
/>
</
Item
>
<
Item
label=
"内网地址"
name=
"intranetAddress"
>
<
Input
allowClear
/>
</
Item
>
{
/* <Item label="请求方式" name="method">
<Radio.Group onChange={onChange2} value={radio2}>
<Radio value="Get">Get</Radio>
...
...
@@ -278,6 +288,7 @@ const AddModal = props => {
},
]
}
>
{
/* <Image width="90%" src={imageUrl} /> */
}
<
Upload
name=
"singleFile"
listType=
"picture-card"
...
...
src/pages/platformCenter/integratedLogin/Integrate.jsx
View file @
8e05c038
/* eslint-disable import/no-unresolved */
/* eslint-disable prefer-template */
/* eslint-disable no-undef */
import
React
,
{
useState
,
useEffect
}
from
'react'
;
...
...
@@ -18,6 +19,7 @@ import { EditTwoTone, DeleteOutlined, PlusOutlined, SyncOutlined } from '@ant-de
import
styles
from
'./integrate.less'
;
import
AddModal
from
'./AddModal'
;
import
Master
from
'./Master'
;
import
Pdf
from
'./Pdf'
;
const
Integrate
=
()
=>
{
const
[
loading
,
setLoading
]
=
useState
(
false
);
...
...
@@ -29,6 +31,7 @@ const Integrate = () => {
const
[
pickItem
,
setPickItem
]
=
useState
(
''
);
const
[
type
,
setType
]
=
useState
(
''
);
const
[
masterVisible
,
setMasterVisible
]
=
useState
(
false
);
const
[
pdfVisible
,
setPdfVisible
]
=
useState
(
false
);
const
{
Search
}
=
Input
;
...
...
@@ -123,7 +126,6 @@ const Integrate = () => {
align
:
'center'
,
width
:
200
,
render
:
(
text
,
record
)
=>
{
console
.
log
(
text
);
if
(
text
)
{
// if (text.startsWith('CityTemp') || text.startsWith('civ_integratedlogin')) {
// return <Image src={`http://192.168.12.116:8017/${text}`} height="50px" />;
...
...
@@ -209,11 +211,13 @@ const Integrate = () => {
};
const
dele
=
e
=>
{
console
.
log
(
e
,
'aaaaaaaaaa'
);
setPickItem
(
e
);
setLoading
(
true
);
DelIntegratedLogin
({
ID
:
e
.
ID
,
client
:
e
.
SystemClient
,
}).
then
(
res
=>
{
console
.
log
(
'11111111111ss'
);
if
(
res
.
code
===
0
)
{
setFlag
(
flag
+
1
);
notification
.
success
({
...
...
@@ -275,6 +279,10 @@ const Integrate = () => {
setMasterVisible
(
true
);
};
const
openPdf
=
()
=>
{
setPdfVisible
(
true
);
};
return
(
<
div
className=
{
styles
.
Integrate
}
>
<
div
className=
{
styles
.
head
}
>
...
...
@@ -302,6 +310,15 @@ const Integrate = () => {
新增
</
Button
>
</
div
>
{
/* <Button
onClick={openPdf}
style={{
float: 'right',
verticalAlign: 'middle',
}}
>
查看说明文档
</Button> */
}
<
Button
type=
"primary"
onClick=
{
masterStation
}
...
...
@@ -340,6 +357,7 @@ const Integrate = () => {
callBackSubmit=
{
onSubmit
}
/>
<
Master
visible=
{
masterVisible
}
onCancel=
{
()
=>
setMasterVisible
(
false
)
}
/>
<
Pdf
visible=
{
pdfVisible
}
onCancel=
{
()
=>
setPdfVisible
(
false
)
}
/>
</
div
>
);
};
...
...
src/pages/platformCenter/integratedLogin/PreviewModal.jsx
View file @
8e05c038
...
...
@@ -123,12 +123,12 @@ const PreviewModal = props => {
// height="100px"
// />
<
div
className=
{
styles
.
divItem
}
key=
{
index
}
>
<
CheckCircleTwoTone
{
/*
<CheckCircleTwoTone
className={classnames({
[styles.iconHidden]: index !== pickItem || i.groupName !== keepItem,
[styles.iconItem]: index === pickItem && i.groupName === keepItem,
})}
/>
/>
*/
}
<
img
src=
{
window
.
location
.
origin
+
`/${k.path}`
}
className=
{
classnames
({
...
...
src/pages/platformCenter/integratedLogin/integrate.less
View file @
8e05c038
...
...
@@ -24,6 +24,7 @@
box-sizing: border-box;
border-radius: 5px;
display: inline-block;
z-index: -1;
}
.imgHidden {
border: none;
...
...
@@ -37,19 +38,21 @@
}
.iconItem {
position: absolute;
margin-left: 70px;
//
position: absolute;
//
margin-left: 70px;
margin-top: -3px;
font-size: 17px;
float: right;
margin-left: -10px;
}
.iconHidden {
display: none;
}
.iconHidden:hover {
position: absolute;
margin-left: 70px;
margin-top: -3px;
font-size: 17px;
float: right;
margin-left: -10px;
}
.table {
...
...
src/routes/config.js
View file @
8e05c038
...
...
@@ -331,11 +331,11 @@ export default {
url
:
'/web4/?widget=product/oms/MqttConfig/MqttConfig.js|hideMap=true'
,
component
:
HostManager
,
},
//
{
//
path: '/platform/integrate',
//
name: '集成登录',
//
component: IntegratedLogin,
//
},
{
path
:
'/platform/integrate'
,
name
:
'集成登录'
,
component
:
IntegratedLogin
,
},
],
},
{
...
...
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