Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
J
jinfa-platform
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
shenshaokai
jinfa-platform
Commits
a2437cf4
Commit
a2437cf4
authored
Mar 17, 2021
by
GuanHua
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 渠道能力添加推荐页图片添加,商城首页禁用去求购链接
parent
833bf985
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
54 additions
and
5 deletions
+54
-5
index.tsx
src/pages/channel/channelInfo/index.tsx
+38
-0
index.less
src/pages/lxMall/components/QuickNav/index.less
+9
-0
index.tsx
src/pages/lxMall/components/QuickNav/index.tsx
+7
-5
No files found.
src/pages/channel/channelInfo/index.tsx
View file @
a2437cf4
...
...
@@ -37,6 +37,7 @@ const ChannelInfo: React.FC<ShopInfoPropsType> = (props) => {
const
[
workshopPics
,
setWorkshopPics
]
=
useState
([])
// 厂房照片
const
[
honorPics
,
setHonorPics
]
=
useState
([])
// 资质荣誉
const
[
logo
,
setLogo
]
=
useState
<
string
>
(
""
)
const
[
promotionPic
,
setPromotionPic
]
=
useState
<
string
>
(
''
)
const
[
shopInfo
,
setShopInfo
]
=
useState
<
GetTemplateWebMemberChannelWebFindCurrMemberChannelResponse
>
()
const
[
shopId
,
setShopId
]
=
useState
<
number
>
()
...
...
@@ -76,6 +77,7 @@ const ChannelInfo: React.FC<ShopInfoPropsType> = (props) => {
setWorkshopPics
(
data
.
workshopPics
||
[])
setHonorPics
(
data
.
honorPics
||
[])
setStoreUrl
(
""
)
setPromotionPic
(
data
.
promotionPic
||
""
)
form
.
setFieldsValue
({
describe
:
data
.
describe
,
customerUrl
:
data
.
customerUrl
,
...
...
@@ -220,6 +222,17 @@ const ChannelInfo: React.FC<ShopInfoPropsType> = (props) => {
})
}
/**
* 添加推广页
* @param url
*/
const
handleAddPromotionPic
=
(
url
:
string
)
=>
{
setPromotionPic
(
url
)
form
.
setFieldsValue
({
promotionPic
:
url
})
}
const
handleMallSelectChange
=
(
mallId
:
number
)
=>
{
setShopId
(
mallId
)
if
(
!
shopInfo
)
{
...
...
@@ -405,6 +418,31 @@ const ChannelInfo: React.FC<ShopInfoPropsType> = (props) => {
</
Form
.
Item
>
<
Form
.
Item
labelAlign=
"left"
name=
"promotionPic"
label=
{
<
RequireItem
label=
"推广页"
/>
}
>
<
div
className=
{
styles
.
form_item_wrap
}
>
<
div
className=
{
styles
.
img_list
}
>
{
promotionPic
&&
(
<
div
className=
{
cx
(
styles
.
upload_btn
,
styles
.
large
,
styles
.
upload
)
}
>
<
div
className=
{
styles
.
delete_btn
}
onClick=
{
()
=>
setPromotionPic
(
""
)
}
><
DeleteOutlined
/></
div
>
<
img
className=
{
styles
.
upload_img
}
src=
{
promotionPic
}
/>
</
div
>
)
}
<
UploadImage
imgUrl=
{
""
}
large=
{
true
}
fileMaxSize=
{
1024
}
size=
"106x107"
onChange=
{
(
url
)
=>
handleAddPromotionPic
(
url
)
}
/>
</
div
>
</
div
>
</
Form
.
Item
>
<
Form
.
Item
labelAlign=
"left"
name=
"customerUrl"
label=
{
<
RequireItem
label=
"客服链接"
/>
}
rules=
{
[{
pattern
:
/
(
http|ftp|https
)
:
\/\/[\w\-
_
]
+
(\.[\w\-
_
]
+
)
+
([\w\-
.,@?^=%&:
/
~+#
]
*
[\w\-
@?^=%&
/
~+#
])?
/
,
message
:
'请输入正确的客服链接'
}]
}
...
...
src/pages/lxMall/components/QuickNav/index.less
View file @
a2437cf4
...
...
@@ -189,6 +189,11 @@
&:hover {
.quick_nav_list_item_text {
color: var(--mall_main_color);
&.disabled {
color: #999;
}
}
}
...
...
@@ -207,6 +212,10 @@
line-height: 12px;
margin-top: 14px;
color: #303133;
&.disabled {
color: #999;
}
}
}
}
...
...
src/pages/lxMall/components/QuickNav/index.tsx
View file @
a2437cf4
...
...
@@ -70,6 +70,7 @@ const QuickNav: React.FC<QuickNavPropsType> = (props) => {
{
path
:
'/memberCenter/tranactionAbility/enquirySubmit/toAddSubmitList/add'
,
title
:
'我要求购'
,
disabled
:
true
,
icon
:
require
(
'@/assets/mallHomeIcon/buy_icon.png'
)
},
{
...
...
@@ -98,6 +99,7 @@ const QuickNav: React.FC<QuickNavPropsType> = (props) => {
},
{
path
:
'/purchaseOnline'
,
disabled
:
true
,
title
:
'去求购'
,
icon
:
require
(
'@/assets/mallHomeIcon/tobuy_icon.png'
)
},
...
...
@@ -230,20 +232,20 @@ const QuickNav: React.FC<QuickNavPropsType> = (props) => {
tabType
===
1
?
sell_quick_nav_list
.
map
((
item
,
index
)
=>
(
<
a
href=
{
goToLink
(
item
.
path
)
}
className=
{
cx
(
styles
.
quick_nav_list_item
,
styles
.
bb
)
}
key=
{
`sell_quick_nav_list_item-${index}`
}
>
<
img
className=
{
styles
.
quick_nav_list_item_icon
}
src=
{
item
.
icon
}
/>
<
span
className=
{
styles
.
quick_nav_list_item_text
}
>
{
item
.
title
}
</
span
>
<
span
className=
{
cx
(
styles
.
quick_nav_list_item_text
)
}
>
{
item
.
title
}
</
span
>
</
a
>
))
:
buy_quick_nav_list
.
map
((
item
,
index
)
=>
(
<
a
href=
{
goToLink
(
item
.
path
)
}
className=
{
cx
(
styles
.
quick_nav_list_item
,
styles
.
bb
)
}
key=
{
`buy_quick_nav_list_item-${index}`
}
>
<
a
href=
{
item
.
disabled
?
'javascript:;'
:
goToLink
(
item
.
path
)
}
className=
{
cx
(
styles
.
quick_nav_list_item
,
styles
.
bb
)
}
key=
{
`buy_quick_nav_list_item-${index}`
}
>
<
img
className=
{
styles
.
quick_nav_list_item_icon
}
src=
{
item
.
icon
}
/>
<
span
className=
{
styles
.
quick_nav_list_item_text
}
>
{
item
.
title
}
</
span
>
<
span
className=
{
cx
(
styles
.
quick_nav_list_item_text
,
item
.
disabled
?
styles
.
disabled
:
""
)
}
>
{
item
.
title
}
</
span
>
</
a
>
))
}
{
quick_nav_list
.
map
((
item
,
index
)
=>
(
<
a
href=
{
goToLink
(
item
.
path
)
}
className=
{
styles
.
quick_nav_list_item
}
key=
{
`quick_nav_list_item-${index}`
}
>
<
a
href=
{
item
.
disabled
?
'javascript:;'
:
goToLink
(
item
.
path
)
}
className=
{
styles
.
quick_nav_list_item
}
key=
{
`quick_nav_list_item-${index}`
}
>
<
img
className=
{
styles
.
quick_nav_list_item_icon
}
src=
{
item
.
icon
}
/>
<
span
className=
{
styles
.
quick_nav_list_item_text
}
>
{
item
.
title
}
</
span
>
<
span
className=
{
cx
(
styles
.
quick_nav_list_item_text
,
item
.
disabled
?
styles
.
disabled
:
""
)
}
>
{
item
.
title
}
</
span
>
</
a
>
))
}
...
...
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