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
f4910450
Commit
f4910450
authored
Sep 20, 2022
by
皮倩雯
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: '集成登录新增配置站点的停用启用'
parent
caac64e8
Pipeline
#60580
passed with stages
Changes
2
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
101 additions
and
4 deletions
+101
-4
AddModal.jsx
src/pages/platformCenter/integratedLogin/AddModal.jsx
+2
-0
Integrate.jsx
src/pages/platformCenter/integratedLogin/Integrate.jsx
+99
-4
No files found.
src/pages/platformCenter/integratedLogin/AddModal.jsx
View file @
f4910450
...
...
@@ -271,6 +271,7 @@ const AddModal = props => {
accountParam
:
bb
,
iconUrl
:
obj
.
iconUrl
,
accountType
:
'Panda'
,
isHide
:
false
,
target
:
obj
.
target
,
isMaster
:
obj
.
isMaster
,
images
:
dataList
,
...
...
@@ -313,6 +314,7 @@ const AddModal = props => {
isMaster
:
obj
.
isMaster
,
images
:
dataList
,
clients
:
pickItem
.
clients
,
isHide
:
pickItem
.
isHide
,
mapSetting
:
obj
.
mapSetting
,
coordinate
:
data
,
siteDescription
:
obj
.
siteDescription
,
...
...
src/pages/platformCenter/integratedLogin/Integrate.jsx
View file @
f4910450
...
...
@@ -10,11 +10,13 @@ import {
Table
,
notification
,
Image
,
Tag
,
}
from
'antd'
;
import
{
GetIntegratedLogin
,
DelIntegratedLogin
,
SetIntegratedloginSettingSort
,
EditIntegratedLogin
,
}
from
'@/services/integratedLogin/api'
;
import
{
EditTwoTone
,
...
...
@@ -23,6 +25,8 @@ import {
SyncOutlined
,
FilePdfOutlined
,
OrderedListOutlined
,
LockOutlined
,
UnlockOutlined
,
}
from
'@ant-design/icons'
;
import
styles
from
'./integrate.less'
;
import
AddModal
from
'./AddModal'
;
...
...
@@ -74,7 +78,7 @@ const Integrate = () => {
if
(
text
)
{
return
(
<
Image
src=
{
window
.
location
.
origin
+
`
/${text}`
}
src=
{
`${window.location.origin}
/${text}`
}
height=
"50px"
style=
{
{
backgroundColor
:
'#2881a1'
}
}
/>
...
...
@@ -167,6 +171,18 @@ const Integrate = () => {
return
<
span
>
熊猫token
</
span
>;
},
},
{
title
:
'特殊站点'
,
dataIndex
:
'isMaster'
,
key
:
'isMaster'
,
align
:
'center'
,
render
:
record
=>
{
if
(
record
)
{
return
<
Tag
color=
"success"
>
是
</
Tag
>;
}
return
<
Tag
color=
"processing"
>
否
</
Tag
>;
},
},
{
title
:
'操作'
,
key
:
'action'
,
...
...
@@ -177,6 +193,42 @@ const Integrate = () => {
<
Tooltip
title=
"编辑"
>
<
EditTwoTone
onClick=
{
()
=>
edit
(
record
)
}
style=
{
{
fontSize
:
'16px'
}
}
/>
</
Tooltip
>
{
record
.
isHide
?
(
<
Tooltip
title=
"启用"
>
<
Popconfirm
placement=
"left"
title=
{
<
p
>
启用站点
<
span
className=
{
styles
.
redText
}
>
{
record
.
SystemName
}
</
span
>
</
p
>
}
okText=
"确认"
cancelText=
"取消"
onConfirm=
{
()
=>
startUser
(
record
)
}
>
<
UnlockOutlined
style=
{
{
fontSize
:
'16px'
,
color
:
'#1890ff'
}
}
/>
</
Popconfirm
>
</
Tooltip
>
)
:
(
<
Tooltip
title=
"停用"
>
<
Popconfirm
placement=
"left"
title=
{
<
p
>
停用站点
<
span
className=
{
styles
.
redText
}
>
{
record
.
SystemName
}
</
span
>
</
p
>
}
okText=
"确认"
cancelText=
"取消"
onConfirm=
{
()
=>
freezeUser
(
record
)
}
>
<
LockOutlined
style=
{
{
fontSize
:
'16px'
,
color
:
'#e86060'
}
}
/>
</
Popconfirm
>
</
Tooltip
>
)
}
<
Tooltip
title=
"删除"
>
<
Popconfirm
placement=
"bottomRight"
...
...
@@ -198,6 +250,49 @@ const Integrate = () => {
},
];
// 停用
const
freezeUser
=
e
=>
{
let
aa
=
e
;
aa
.
isHide
=
true
;
console
.
log
(
e
);
EditIntegratedLogin
(
aa
).
then
(
res
=>
{
if
(
res
.
code
==
0
)
{
setFlag
(
flag
+
1
);
notification
.
success
({
message
:
'设置成功'
,
description
:
res
.
msg
,
});
}
else
{
notification
.
error
({
message
:
'设置失败'
,
description
:
res
.
msg
,
});
}
});
};
// 启用
const
startUser
=
e
=>
{
console
.
log
(
e
);
let
aa
=
e
;
aa
.
isHide
=
false
;
console
.
log
(
e
);
EditIntegratedLogin
(
aa
).
then
(
res
=>
{
if
(
res
.
code
==
0
)
{
setFlag
(
flag
+
1
);
notification
.
success
({
message
:
'设置成功'
,
description
:
res
.
msg
,
});
}
else
{
notification
.
error
({
message
:
'设置失败'
,
description
:
res
.
msg
,
});
}
});
};
// 模糊查询匹配的样式
const
searchStyle
=
val
=>
{
let
n
;
...
...
@@ -211,7 +306,7 @@ const Integrate = () => {
const
getData
=
()
=>
{
setLoading
(
true
);
GetIntegratedLogin
().
then
(
resnew
=>
{
GetIntegratedLogin
(
{
isHide
:
false
}
).
then
(
resnew
=>
{
if
(
resnew
.
code
===
0
)
{
console
.
log
(
resnew
.
data
);
let
aa
=
[];
...
...
@@ -272,7 +367,7 @@ const Integrate = () => {
const
submitSearch
=
()
=>
{
setLoading
(
true
);
GetIntegratedLogin
({
searchKey
:
searchWord
}).
then
(
resnew
=>
{
GetIntegratedLogin
({
searchKey
:
searchWord
,
isHide
:
false
}).
then
(
resnew
=>
{
if
(
resnew
.
code
===
0
)
{
setTableData
(
resnew
.
data
);
setShowSearchStyle
(
true
);
...
...
@@ -290,7 +385,7 @@ const Integrate = () => {
setSearchWord
(
''
);
setShowSearchStyle
(
false
);
setLoading
(
true
);
GetIntegratedLogin
({
searchKey
:
''
}).
then
(
resnew
=>
{
GetIntegratedLogin
({
searchKey
:
''
,
isHide
:
false
}).
then
(
resnew
=>
{
if
(
resnew
.
code
===
0
)
{
setTableData
(
resnew
.
data
);
}
else
{
...
...
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