Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
jinfa-admin
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
linweijiong
jinfa-admin
Commits
b3192ef1
Commit
b3192ef1
authored
Dec 15, 2021
by
前端-钟卫鹏
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'v2' of
http://10.0.0.22:3000/lingxi/lingxi-business-system
into v2
parents
049d4e1f
6ece2210
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
45 additions
and
25 deletions
+45
-25
index.ts
src/global/config/index.ts
+3
-1
index.tsx
...eting/waitAddedMarketing/components/rulesLayout/index.tsx
+1
-1
defaultMenu.ts
src/pages/pageCustomized/mallEdit/defaultMenu.ts
+29
-7
index.tsx
src/pages/pageCustomized/mallEdit/index.tsx
+3
-7
index.tsx
.../settingsPanel/propsSettings/components/MallNav/index.tsx
+3
-3
index.tsx
...ages/pageCustomized/settingsPanel/propsSettings/index.tsx
+0
-2
modal.tsx
...mManage/ruleSettingManage/paySetting/components/modal.tsx
+6
-4
index.tsx
...pages/systemManage/ruleSettingManage/paySetting/index.tsx
+0
-0
No files found.
src/global/config/index.ts
View file @
b3192ef1
...
...
@@ -23,7 +23,7 @@ SELF_CONFIG.ichannelRootRoute = ichannelRootRoute // 渠道自有商城路由根
const
getSrmdMallId
=
()
=>
{
const
shopInfo
=
SELF_CONFIG
.
web
.
shopInfo
const
webMallList
=
shopInfo
.
filter
((
item
:
any
)
=>
item
.
isDefault
===
1
&&
item
.
type
===
6
)
const
webMallList
=
shopInfo
.
filter
((
item
:
any
)
=>
item
.
type
===
6
)
if
(
webMallList
&&
webMallList
.
length
>
0
)
{
const
mallItem
=
webMallList
[
0
]
return
mallItem
.
id
...
...
@@ -31,4 +31,6 @@ const getSrmdMallId = () => {
return
undefined
}
SELF_CONFIG
.
srmMallId
=
getSrmdMallId
()
export
const
GlobalConfig
:
GlobalConfigType
=
SELF_CONFIG
src/pages/marketingManage/marketing/waitAddedMarketing/components/rulesLayout/index.tsx
View file @
b3192ef1
...
...
@@ -526,7 +526,7 @@ const RulesLayout: React.FC<RulesLayoutProps> = (props: any) => {
name=
{
[
'activityDefined'
,
'assembleNum'
]
}
rules=
{
[{
required
:
true
,
validator
:
(
_rule
,
value
)
=>
{
const
pattern
=
/^
\+?[
1-9
]\d
*
$/
;
const
pattern
=
/^
0*
(?:[
2-9
]
|
[
1-9
]\d\d
*
)
$/
;
if
(
!
value
)
{
return
Promise
.
reject
(
new
Error
(
'请输入成团人数'
));
}
...
...
src/pages/pageCustomized/mallEdit/defaultMenu.ts
View file @
b3192ef1
...
...
@@ -15,7 +15,23 @@ export const getTopDomainByHost = (url: string): string => {
export
const
TOP_DOMAIN
=
getTopDomainByHost
(
siteUrl
);
export
const
getMenuData
=
(
shopId
:
number
)
=>
{
export
interface
NavItemType
{
link
:
string
,
name
:
string
,
status
:
boolean
,
type
:
number
,
}
const
getStatusByType
=
(
type
:
number
,
list
:
NavItemType
[]
|
undefined
)
=>
{
if
(
!
list
)
return
true
const
current
=
list
.
filter
((
item
)
=>
item
.
type
===
type
)[
0
]
if
(
current
)
{
return
current
.
status
}
return
true
}
export
const
getMenuData
=
(
shopId
:
number
,
list
?:
NavItemType
[])
=>
{
const
shopInfo
=
GlobalConfig
.
web
.
shopInfo
;
const
webMallList
=
shopInfo
.
filter
((
item
:
{
id
:
number
})
=>
item
.
id
===
shopId
);
...
...
@@ -27,43 +43,49 @@ export const getMenuData = (shopId: number) => {
"id"
:
0
,
"link"
:
`
${
REQUEST_HEADER
}${
SUB_DOMAIN
}
.
${
TOP_DOMAIN
}
`
,
"name"
:
"商城首页"
,
"status"
:
true
,
"status"
:
getStatusByType
(
1
,
list
)
,
"key"
:
"shopHome"
,
type
:
1
,
},
{
"id"
:
1
,
"link"
:
`
${
REQUEST_HEADER
}${
SUB_DOMAIN
}
.
${
TOP_DOMAIN
}
/commodity`
,
"name"
:
"现货商品"
,
"status"
:
true
,
"status"
:
getStatusByType
(
2
,
list
)
,
"key"
:
"shopCommodity"
,
type
:
2
,
},
{
"id"
:
2
,
"link"
:
`
${
REQUEST_HEADER
}${
SUB_DOMAIN
}
.
${
TOP_DOMAIN
}
/inquiry`
,
"name"
:
"询价商品"
,
"status"
:
true
,
"status"
:
getStatusByType
(
3
,
list
)
,
"key"
:
"purchaseOnline"
,
type
:
3
,
},
{
"id"
:
3
,
"link"
:
`
${
REQUEST_HEADER
}${
SUB_DOMAIN
}
.
${
TOP_DOMAIN
}
/stores`
,
"name"
:
"优选店铺"
,
"status"
:
true
,
"status"
:
getStatusByType
(
3
,
list
)
,
"key"
:
"shopPointsMall"
,
type
:
4
,
},
{
"id"
:
4
,
"link"
:
`
${
REQUEST_HEADER
}${
SUB_DOMAIN
}
.
${
TOP_DOMAIN
}
/integral`
,
"name"
:
"积分商城"
,
"key"
:
"shops"
,
"status"
:
true
,
"status"
:
getStatusByType
(
5
,
list
),
type
:
5
,
},
{
"id"
:
5
,
"link"
:
INFO_CENTER_URL
,
"name"
:
"行情资讯"
,
"status"
:
true
,
"status"
:
getStatusByType
(
6
,
list
)
,
"key"
:
"shopInfomation"
,
type
:
6
},
];
}
...
...
src/pages/pageCustomized/mallEdit/index.tsx
View file @
b3192ef1
...
...
@@ -74,7 +74,7 @@ const MallEdit: React.FC<MallEditPropsType> = (props) => {
const
headers
:
any
=
{
shopId
}
getTemplateWebCategoryWebFindAllFirstCategory
({
templateId
:
id
},
{
headers
}).
then
(
res
=>
{
getTemplateWebCategoryWebFindAllFirstCategory
({
templateId
:
String
(
id
)
},
{
headers
}).
then
(
res
=>
{
if
(
res
.
code
===
1000
)
{
resolve
(
res
.
data
);
}
else
{
...
...
@@ -155,12 +155,8 @@ const MallEdit: React.FC<MallEditPropsType> = (props) => {
const
getComponentsConfig
=
async
()
=>
{
// 导航栏
const
navData
=
await
getMallNavData
();
if
(
!
isEmpty
(
navData
))
{
mainNavConfig
[
mainNavConfig
.
key
].
props
.
menuData
=
navData
;
}
else
{
mainNavConfig
[
mainNavConfig
.
key
].
props
.
menuData
=
getMenuData
(
Number
(
shopId
));
}
const
navData
:
any
=
await
getMallNavData
();
mainNavConfig
[
mainNavConfig
.
key
].
props
.
menuData
=
getMenuData
(
Number
(
shopId
),
navData
);
// mainNavConfig[mainNavConfig.key].props.type = LAYOUT_TYPE.mall
// mainNavConfig[mainNavConfig.key].props.categoryList = []
...
...
src/pages/pageCustomized/settingsPanel/propsSettings/components/MallNav/index.tsx
View file @
b3192ef1
...
...
@@ -64,7 +64,8 @@ const MallNav: React.FC<MallNavProps> = (props) => {
return
{
name
:
item
.
name
,
link
:
item
.
link
,
status
:
item
.
status
status
:
item
.
status
,
type
:
item
.
type
};
})
};
...
...
@@ -211,8 +212,7 @@ const MallNav: React.FC<MallNavProps> = (props) => {
</
ul
>
))
}
</
ReactSortable
>
</
ReactSortable
>
</
div
>
</
div
>
</
div
>
...
...
src/pages/pageCustomized/settingsPanel/propsSettings/index.tsx
View file @
b3192ef1
...
...
@@ -41,8 +41,6 @@ const PropsSettings: React.FC<PropsSettingsPropsType> = (props) => {
const
renderDrawerComponent
=
()
=>
{
const
{
props
:
initProps
,
propsConfig
,
selectedKey
}
=
selectedInfo
||
{};
const
componentType
=
propsConfig
?.
componentType
;
console
.
log
(
selectedInfo
,
'selectedInfo'
)
console
.
log
(
pageConfig
,
'pageConfig'
)
if
(
componentType
)
{
switch
(
componentType
.
type
)
{
case
PROPS_SETTING_TYPES
.
goods
:
...
...
src/pages/systemManage/ruleSettingManage/paySetting/components/modal.tsx
View file @
b3192ef1
...
...
@@ -68,10 +68,11 @@ const ModalLayout: React.FC<ModalProps> = ({
if
(
payChannel
)
{
handleChannelFind
();
}
},
[
payChannel
])
},
[
payChannel
,
visible
])
const
handleCancel
=
()
=>
{
onCancel
()
setFiles
({})
form
.
resetFields
()
}
...
...
@@ -81,16 +82,17 @@ const ModalLayout: React.FC<ModalProps> = ({
...
res
,
key
:
channel
.
filter
(
item
=>
item
.
code
===
res
.
code
)[
0
].
key
,
})
setFiles
({})
form
.
resetFields
();
})
}
useEffect
(()
=>
{
if
(
!
isEmpty
(
value
)
)
{
if
(
visible
)
{
form
.
setFieldsValue
({
...
value
})
if
(
value
?.
code
===
14
)
{
if
(
value
?.
code
===
14
||
value
?.
code
===
41
||
value
?.
code
===
42
)
{
setFiles
({
name
:
value
.
remark
,
url
:
value
.
value
...
...
@@ -153,7 +155,7 @@ const ModalLayout: React.FC<ModalProps> = ({
shouldUpdate=
{
(
prevValues
,
curValues
)
=>
prevValues
.
code
!==
curValues
.
code
}
>
{
({
getFieldValue
})
=>
getFieldValue
(
'code'
)
===
14
?
(
(
getFieldValue
(
'code'
)
===
14
||
getFieldValue
(
'code'
)
===
41
||
getFieldValue
(
'code'
)
===
42
)
?
(
<
Form
.
Item
name=
'value'
label=
'退款证书'
rules=
{
[{
required
:
true
,
message
:
'请上传退款证书'
}]
}
>
{
!
isEmpty
(
files
)
&&
(
<
div
className=
{
style
.
upload_fileList
}
>
...
...
src/pages/systemManage/ruleSettingManage/paySetting/index.tsx
View file @
b3192ef1
This diff is collapsed.
Click to expand it.
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