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
3102d690
Commit
3102d690
authored
Jun 13, 2023
by
涂伟
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 'mobile功能路径存储逻辑添加'
parent
9b0d4504
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
30 additions
and
12 deletions
+30
-12
editForm.jsx
src/pages/productCenter/mobileConfig/menuconfig/editForm.jsx
+6
-0
miniMenu.jsx
src/pages/productCenter/mobileConfig/menuconfig/miniMenu.jsx
+24
-12
No files found.
src/pages/productCenter/mobileConfig/menuconfig/editForm.jsx
View file @
3102d690
...
...
@@ -9,6 +9,12 @@ import CheckList from './checkBox';
const
{
Item
}
=
Form
;
const
EditForm
=
props
=>
{
const
{
submitCallback
,
nodeType
,
info
,
inf
,
checkList
,
valueCallback
=
()
=>
{}
}
=
props
;
// 处理pageUrl回显
if
(
info
.
product
)
{
info
.
pageUrl
=
'/'
+
info
.
product
+
info
.
pageUrl
;
}
else
{
info
.
pageUrl
=
'/MobileGCK'
+
info
.
pageUrl
;
}
const
[
form
]
=
Form
.
useForm
();
const
[
otherForm
]
=
Form
.
useForm
();
const
[
showParmarModal
,
setShowParmarModal
]
=
useState
(
false
);
...
...
src/pages/productCenter/mobileConfig/menuconfig/miniMenu.jsx
View file @
3102d690
...
...
@@ -415,15 +415,26 @@ const MiniMenu = props => {
setAddTwoVisible
(
true
);
setKeepType
(
'MiniAppMenu'
);
};
// 处理数据
const
getParams
=
prop
=>
{
const
typeArr
=
[
'MobileGCK'
,
'civ_mobile'
,
'Flutter'
];
let
productType
=
prop
.
pageUrl
.
split
(
'/'
)[
1
]
||
''
;
if
(
!
typeArr
.
includes
(
productType
))
{
productType
=
''
}
const
pageUrl
=
productType
?
prop
.
pageUrl
.
replace
(
`/
${
productType
}
`
,
''
)
:
prop
.
pageUrl
;
return
{
productType
,
pageUrl
};
};
// 新增提交的回调
const
submitCallback
=
(
prop
,
item
,
e
)
=>
{
setSubmitLoading
(
true
);
const
productType
=
prop
.
pageUrl
.
split
(
'/'
)[
1
]
===
'civ_mobile'
?
prop
.
pageUrl
.
split
(
'/'
)[
1
]
:
''
;
const
pageUrl
=
prop
.
pageUrl
.
includes
(
'/civ_mobile'
)
?
prop
.
pageUrl
.
replace
(
'/civ_mobile'
,
''
)
:
prop
.
pageUrl
;
let
obj
=
{
...
prop
,
productType
,
pageUrl
};
// const productType =
// prop.pageUrl.split('/')[1] === 'civ_mobile' ? prop.pageUrl.split('/')[1] : '';
// const pageUrl = prop.pageUrl.includes('/civ_mobile')
// ? prop.pageUrl.replace('/civ_mobile', '')
// : prop.pageUrl;
const
params
=
getParams
(
prop
);
let
obj
=
{
...
prop
,
...
params
};
// if (addType === 3 || addType === 4) {
// obj.relatedRoleList = String(roleList) || '';
// }
...
...
@@ -465,14 +476,15 @@ const MiniMenu = props => {
};
// 编辑的回调
const
editSubmitCallback
=
prop
=>
{
const
productType
=
prop
.
pageUrl
.
split
(
'/'
)[
1
]
===
'civ_mobile'
?
prop
.
pageUrl
.
split
(
'/'
)[
1
]
:
''
;
const
pageUrl
=
prop
.
pageUrl
.
includes
(
'/civ_mobile'
)
?
prop
.
pageUrl
.
replace
(
'/civ_mobile'
,
''
)
:
prop
.
pageUrl
;
// const productType =
// prop.pageUrl.split('/')[1] === 'civ_mobile' ? prop.pageUrl.split('/')[1] : '';
// const pageUrl = prop.pageUrl.includes('/civ_mobile')
// ? prop.pageUrl.replace('/civ_mobile', '')
// : prop.pageUrl;
const
params
=
getParams
(
prop
);
setLoading
(
true
);
console
.
log
(
prop
);
let
obj
=
{
...
prop
,
productType
,
pageUrl
};
let
obj
=
{
...
prop
,
...
params
};
// if (nodeType === 3 || nodeType === 4) {
// obj.relatedRoleList = String(roleList) || '';
// }
...
...
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