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
9cd4e60d
Commit
9cd4e60d
authored
Dec 24, 2020
by
Maofei94
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
perf: 移动应用配置布局修改
parent
64fbe5a4
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
56 additions
and
34 deletions
+56
-34
index.js
src/pages/mobileConfig/index.js
+2
-2
addForm.less
src/pages/mobileConfig/menuconfig/addForm.less
+13
-1
checkBox.less
src/pages/mobileConfig/menuconfig/checkBox.less
+3
-3
editForm.jsx
src/pages/mobileConfig/menuconfig/editForm.jsx
+12
-5
miniMenu.jsx
src/pages/mobileConfig/menuconfig/miniMenu.jsx
+24
-21
miniMenu.less
src/pages/mobileConfig/menuconfig/miniMenu.less
+2
-2
No files found.
src/pages/mobileConfig/index.js
View file @
9cd4e60d
...
...
@@ -26,7 +26,7 @@ import { appConnector } from '@/containers/App/store';
const
{
TabPane
}
=
Tabs
;
const
MobileConfigPage
=
props
=>
{
const
{
userMode
}
=
props
;
const
[
activeKey
,
setActiveKey
]
=
useState
(
'
0
'
);
// tabs活动页
const
[
activeKey
,
setActiveKey
]
=
useState
(
'
1
'
);
// tabs活动页
const
[
miniTitle
,
setMiniTitle
]
=
useState
(
''
);
// 应用名称
const
[
flag
,
setFlag
]
=
useState
(
1
);
// 刷新标志
const
[
showConfig
,
setShowConfig
]
=
useState
(
true
);
...
...
@@ -201,7 +201,7 @@ const MobileConfigPage = props => {
);
const
tabArr
=
[
{
title
:
'
网站
配置'
,
title
:
'
应用
配置'
,
key
:
'0'
,
component
:
(
<
SiteConfig
...
...
src/pages/mobileConfig/menuconfig/addForm.less
View file @
9cd4e60d
.formStyle{
margin-bottom: 40px;
margin-bottom: 20px;
// height: 100%;
// overflow-y: scroll;
}
.formbtn{
position: fixed;
bottom: 40px;
right:40%
}
.divbox{
height: 100%;
overflow: hidden;
}
\ No newline at end of file
src/pages/mobileConfig/menuconfig/checkBox.less
View file @
9cd4e60d
.box{
display: flex;
padding: 10px;
margin
-top: 1
0px;
padding: 10px
10px 10px 20px
;
margin
: 2
0px;
flex-wrap: wrap;
// border: 1px solid gray
;
border: 1px solid #eee
;
}
.check{
flex-shrink: 0;
...
...
src/pages/mobileConfig/menuconfig/editForm.jsx
View file @
9cd4e60d
import
React
,
{
useState
,
useEffect
}
from
'react'
;
import
{
Form
,
Input
,
Button
,
Row
,
Col
}
from
'antd'
;
import
classnames
from
'classnames'
;
import
styles
from
'./addForm.less'
;
import
PicturesWall
from
'@/components/Upload/index'
;
import
CheckList
from
'./checkBox'
;
const
{
Item
}
=
Form
;
const
EditForm
=
props
=>
{
const
{
submitCallback
,
nodeType
,
info
}
=
props
;
const
{
submitCallback
,
nodeType
,
info
,
valueCallback
=
()
=>
{}
}
=
props
;
const
[
form
]
=
Form
.
useForm
();
const
[
otherForm
]
=
Form
.
useForm
();
const
layout
=
{
layout
:
'horizontal'
,
labelCol
:
{
span
:
4
,
offset
:
1
},
wrapperCol
:
{
span
:
16
},
labelCol
:
{
span
:
2
,
offset
:
0
},
wrapperCol
:
{
span
:
20
},
};
// 回显表单
useEffect
(()
=>
{
...
...
@@ -53,7 +55,7 @@ const EditForm = props => {
submit
();
};
return
(
<
div
style=
{
{
marginTop
:
'10px'
}
}
>
<
div
className=
{
classnames
({
[
styles
.
divbox
]:
true
})
}
>
{
(
nodeType
===
1
||
nodeType
===
2
)
&&
(
<
Form
form=
{
form
}
...
...
@@ -211,7 +213,12 @@ const EditForm = props => {
<
Item
label=
"功能参数"
name=
"funParam"
>
<
Input
/>
</
Item
>
<
Item
wrapperCol=
{
{
offset
:
10
}
}
style=
{
{
marginTop
:
'40px'
}
}
>
<
CheckList
info=
{
info
}
nodeType=
{
nodeType
}
valueCallback=
{
valueCallback
}
/>
<
Item
wrapperCol=
{
{
offset
:
10
}
}
>
<
Button
type=
"primary"
htmlType=
"submit"
>
提交
</
Button
>
...
...
src/pages/mobileConfig/menuconfig/miniMenu.jsx
View file @
9cd4e60d
...
...
@@ -146,10 +146,10 @@ const MiniMenu = props => {
icon
:
obj
.
menuType
!==
'MiniAppMenuThree'
&&
obj
.
menuType
!==
'MiniAppMenu'
?
(
<
FolderFilled
/>
)
:
(
<
FileOutlined
/>
),
<
FolderFilled
/>
)
:
(
<
FileOutlined
/>
),
menuType
:
obj
.
menuType
,
children
:
hasChild
?
obj
.
children
.
map
(
i
=>
mapTree
(
i
))
:
[],
};
...
...
@@ -600,11 +600,26 @@ const MiniMenu = props => {
>
菜单配置
{
nodeType
?
(
<
EditForm
nodeType=
{
nodeType
}
info=
{
info
}
submitCallback=
{
editSubmitCallback
}
/>
<
div
style=
{
{
marginTop
:
'10px'
}
}
>
<
EditForm
nodeType=
{
nodeType
}
info=
{
info
}
submitCallback=
{
editSubmitCallback
}
valueCallback=
{
valueCallback
}
/>
{
/* <div
className={classnames({
[styles.rightBox]: true,
})}
>
关联角色
<CheckList
info={info}
nodeType={nodeType}
valueCallback={valueCallback}
/>
</div> */
}
</
div
>
)
:
(
<
Empty
image=
{
Empty
.
PRESENTED_IMAGE_SIMPLE
}
...
...
@@ -612,18 +627,6 @@ const MiniMenu = props => {
/>
)
}
</
div
>
<
div
className=
{
classnames
({
[
styles
.
rightBox
]:
true
,
})
}
>
关联角色
<
CheckList
info=
{
info
}
nodeType=
{
nodeType
}
valueCallback=
{
valueCallback
}
/>
</
div
>
</
div
>
</
Spin
>
);
...
...
src/pages/mobileConfig/menuconfig/miniMenu.less
View file @
9cd4e60d
...
...
@@ -43,11 +43,11 @@
}
.middle{
min-width: 500px;
width:
500px
;
width:
100%
;
min-height: 100%;
border: 1px solid #eee;
padding: 10px;
margin: 0 10px;
margin: 0
0 0
10px;
}
.title{
display: flex;
...
...
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