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
1a60acfd
Commit
1a60acfd
authored
Nov 22, 2022
by
皮倩雯
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 'web搭建新增地图遮罩配置'
parent
bd345940
Pipeline
#64284
passed with stages
Changes
1
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
25 additions
and
22 deletions
+25
-22
siteConfigDrawer.js
...es/productCenter/webConfig/components/siteConfigDrawer.js
+25
-22
No files found.
src/pages/productCenter/webConfig/components/siteConfigDrawer.js
View file @
1a60acfd
...
...
@@ -70,18 +70,16 @@ export default props => {
const
[
keepText
,
setKeepText
]
=
useState
([]);
const
[
keepValue
,
setKeepValue
]
=
useState
([]);
const
[
visibleChecked
,
setVisibleChecked
]
=
useState
(
''
);
const
[
visibleChecked1
,
setVisibleChecked1
]
=
useState
(
''
);
const
[
visibleChecked2
,
setVisibleChecked2
]
=
useState
(
''
);
const
[
visibleChecked3
,
setVisibleChecked3
]
=
useState
(
''
);
const
[
visibleChecked4
,
setVisibleChecked4
]
=
useState
(
''
);
const
[
visibleChecked5
,
setVisibleChecked5
]
=
useState
(
''
);
const
[
visibleChecked
,
setVisibleChecked
]
=
useState
(
''
);
// 菜单开关
const
[
visibleChecked1
,
setVisibleChecked1
]
=
useState
(
''
);
// SaaS样式开关
const
[
visibleChecked2
,
setVisibleChecked2
]
=
useState
(
''
);
// Web4地图开关
const
[
visibleChecked3
,
setVisibleChecked3
]
=
useState
(
''
);
// 消息标记开关
const
[
visibleChecked4
,
setVisibleChecked4
]
=
useState
(
''
);
// 语音播报开关
const
[
visibleChecked5
,
setVisibleChecked5
]
=
useState
(
''
);
// 菜单样式开关
const
[
visibleChecked7
,
setVisibleChecked7
]
=
useState
(
''
);
// 地图遮罩开关
useEffect
(()
=>
{
console
.
log
(
webs
);
onGetLoginPages
();
console
.
log
(
productList
);
console
.
log
(
isEdit
);
let
text
=
[];
let
value
=
[];
webs
.
map
(
i
=>
{
...
...
@@ -91,9 +89,7 @@ export default props => {
setKeepText
(
text
);
setKeepValue
(
value
);
if
(
isEdit
)
{
console
.
log
(
config
);
if
(
config
!=
null
&&
config
.
topMenu
)
{
console
.
log
(
config
);
setCheckedList
(
config
.
topMenu
.
split
(
','
));
if
(
config
.
topMenu
.
split
(
','
).
length
==
1
&&
config
.
topMenu
.
split
(
','
)[
0
]
==
''
)
{
setIndeterminate
(
false
);
...
...
@@ -144,10 +140,11 @@ export default props => {
config
.
menuState
==
false
;
setVisibleChecked5
(
false
);
}
console
.
log
(
config
);
setVisibleChecked
(
config
.
navTheme
==
'light'
);
setVisibleChecked2
(
config
.
hideMap
);
setVisibleChecked4
(
config
.
messageVoice
);
setVisibleChecked7
(
config
.
useCoverMap
==
'true'
);
form
.
setFieldsValue
({
...
config
,
primaryColor
:
config
.
primaryColor
?
config
.
primaryColor
:
'#0087F7'
,
...
...
@@ -157,6 +154,7 @@ export default props => {
hideMap
:
config
.
hideMap
,
messageVoice
:
config
.
messageVoice
,
menuState
:
config
.
menuState
,
useCoverMap
:
config
.
useCoverMap
==
'true'
,
headerPrimaryColor
:
config
.
headerPrimaryColor
?
config
.
headerPrimaryColor
:
'linear-gradient(0deg, #0066D6 0%, #39A9FF 100%)'
,
...
...
@@ -174,6 +172,7 @@ export default props => {
setVisibleChecked3
(
true
);
setVisibleChecked4
(
true
);
setVisibleChecked5
(
true
);
setVisibleChecked7
(
true
);
form
.
setFieldsValue
({
shortcutIcon
:
'assets
\\
images
\\
icon
\\
熊猫-蓝色.png'
,
logo
:
'assets
\\
images
\\
logo
\\
熊猫-蓝绿色.svg'
,
...
...
@@ -187,6 +186,7 @@ export default props => {
primaryColor
:
'#0087F7'
,
navTheme
:
false
,
CloudStyle
:
true
,
useCoverMap
:
true
,
headerPrimaryColor
:
'linear-gradient(0deg, #0066D6 0%, #39A9FF 100%)'
,
});
}
...
...
@@ -258,6 +258,7 @@ export default props => {
validate
.
CloudStyle
=
visibleChecked1
?
'是'
:
'否'
;
validate
.
messageMarking
=
visibleChecked3
?
'All'
:
'One'
;
validate
.
menuState
=
visibleChecked5
?
'open'
:
'close'
;
console
.
log
(
validate
);
if
(
validate
)
{
const
colorIndex
=
colorList
.
findIndex
(
item
=>
item
.
color
===
validate
.
primaryColor
);
onOk
({
...
...
@@ -277,20 +278,16 @@ export default props => {
};
const
onChange
=
list
=>
{
console
.
log
(
checkedList
);
console
.
log
(
list
);
setCheckedList
(
list
);
setIndeterminate
(
!!
list
.
length
&&
list
.
length
<
plainOptions
.
length
);
setCheckAll
(
list
.
length
===
plainOptions
.
length
);
};
const
colorChange
=
value
=>
{
console
.
log
(
value
,
'value'
);
setColor
(
value
);
form
.
setFieldsValue
({
headerPrimaryColor
:
value
});
};
const
addParama
=
()
=>
{
console
.
log
(
form
.
getFieldValue
(
'loginTemplate'
));
if
(
!
form
.
getFieldValue
(
'loginTemplate'
))
{
notification
.
error
({
message
:
'提示'
,
duration
:
3
,
description
:
'请先选择登录模板'
});
return
;
...
...
@@ -299,33 +296,31 @@ export default props => {
};
const
change
=
e
=>
{
console
.
log
(
e
);
setVisibleChecked
(
e
);
};
const
change1
=
e
=>
{
console
.
log
(
e
);
setVisibleChecked1
(
e
);
};
const
change2
=
e
=>
{
console
.
log
(
e
);
setVisibleChecked2
(
e
);
};
const
change3
=
e
=>
{
console
.
log
(
e
);
setVisibleChecked3
(
e
);
};
const
change4
=
e
=>
{
console
.
log
(
e
);
setVisibleChecked4
(
e
);
};
const
change5
=
e
=>
{
console
.
log
(
e
);
setVisibleChecked5
(
e
);
};
const
change7
=
e
=>
{
setVisibleChecked7
(
e
);
};
return
(
<
Drawer
title
=
{
isEdit
?
'查看/编辑网站配置'
:
'新增网站'
}
...
...
@@ -588,6 +583,14 @@ export default props => {
onChange
=
{
change2
}
/
>
<
/Form.Item
>
<
Form
.
Item
label
=
"地图遮罩"
name
=
"useCoverMap"
>
<
Switch
checkedChildren
=
"开启"
unCheckedChildren
=
"关闭"
checked
=
{
visibleChecked7
}
onChange
=
{
change7
}
/
>
<
/Form.Item
>
<
Form
.
Item
label
=
{
<
div
className
=
{
styles
.
formData_label
}
>
...
...
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