Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
YOHOBUYPC
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
2
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
Lynnic
9 years ago
Commit
4dcbee3a37d31f5ffa1c467badbcae2ab74b1498
1 parent
d620715b
为您优选未返回数据时外层容器隐藏 --code viewed by bikai
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
36 additions
and
13 deletions
static/js/product/detail/detail.js
static/js/product/recommend-for-you-product-desc.js
static/sass/product/_detail.scss
static/js/product/detail/detail.js
View file @
4dcbee3
...
...
@@ -81,4 +81,8 @@ $.ajax({
}
});
if
(
$
(
'.good-detail-page'
).
length
>
0
)
{
$
(
'#yoho-footer'
).
css
(
'border-top'
,
'1px solid #e0e0e0'
);
}
require
(
'./like'
);
...
...
static/js/product/recommend-for-you-product-desc.js
View file @
4dcbee3
...
...
@@ -14,15 +14,19 @@ var recommendSwiper,
if
(
preferenceUrl
)
{
$
.
get
(
preferenceUrl
).
then
(
function
(
html
)
{
$recommendForYou
.
html
(
html
).
show
();
if
(
$
(
'#swiper-recommend'
).
length
)
{
recommendSwiper
=
new
Swiper
(
'#swiper-recommend'
,
{
slidesPerView
:
'auto'
,
grabCursor
:
true
,
slideElement
:
'a'
,
lazyLoading
:
true
,
watchSlidesVisibility
:
true
});
if
(
html
.
length
<
5
)
{
$recommendForYou
.
css
(
'display'
,
'none'
);
}
else
{
$recommendForYou
.
html
(
html
).
show
();
if
(
$
(
'#swiper-recommend'
).
length
)
{
recommendSwiper
=
new
Swiper
(
'#swiper-recommend'
,
{
slidesPerView
:
'auto'
,
grabCursor
:
true
,
slideElement
:
'a'
,
lazyLoading
:
true
,
watchSlidesVisibility
:
true
});
}
}
}).
fail
(
function
()
{
$recommendForYou
.
hide
();
...
...
static/sass/product/_detail.scss
View file @
4dcbee3
...
...
@@ -46,7 +46,7 @@ $basicBtnC:#eb0313;
.column
{
box-sizing
:
border-box
;
//padding: pxToRem(20px) pxToRem(12px);
padding
:
4%
3%
;
padding
:
pxToRem
(
6px
)
3%
;
width
:
49
.9%
;
border-bottom
:
pxToRem
(
4px
)
solid
#fff
;
border-right
:
pxToRem
(
4px
)
solid
#fff
;
...
...
@@ -64,6 +64,20 @@ $basicBtnC:#eb0313;
flex-basis
:
49
.9%
))
}
.oldbox
{
padding
:
pxToRem
(
6px
)
3%
;
width
:
49
.9%
;
background-color
:
$tableCellC
;
box-sizing
:
border-box
;
border-bottom
:
1px
solid
#fff
;
border-right
:
1px
solid
#fff
;
width
:
49
.9%
;
height
:
100%
;
float
:
left
;
text-overflow
:ellipsis
;
white-space
:nowrap
;
overflow
:hidden
;
}
}
}
}
...
...
@@ -390,6 +404,7 @@ $basicBtnC:#eb0313;
z-index
:
2
;
padding
:
pxToRem
(
20px
)
pxToRem
(
28px
);
text-align
:
center
;
border-top
:
1px
solid
$borderC
;
a
{
display
:
inline-block
;
&
.num-incart
{
...
...
@@ -435,9 +450,9 @@ $basicBtnC:#eb0313;
}
}
}
// .recommend-for-you {
// margin-bottom: pxToRem(30px);
// }
.recommend-for-you
{
border-bottom
:
none
;
}
.yoho-tip
{
top
:
40%
;
}
...
...
Please
register
or
login
to post a comment