Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
YOHO-ACTIVITY-PHP
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
王水玲
9 years ago
Commit
750504c723b2d8c5b2f83d2c56c6a9270ad9a83b
1 parent
fd6ea86b
新人专享添加
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
47 additions
and
10 deletions
docs/data-structure.md
static/js/home/home.js
static/sass/home/_fresh-only.css
template/m.yohobuy.com/actions/product/freshonly/fresh_list.phtml
template/m.yohobuy.com/partials/home/fresh_only.phtml
docs/data-structure.md
View file @
750504c
...
...
@@ -243,6 +243,26 @@
{...}, //商品信息
...
]
},
//新人专享
freshOnly: {
title: {
title: '新人专享',
'more_url': '/boys/freshList'
},
big_image: {
url: '',
img: ''
},
list: [
{
url: '',
img: '',
title: ''
salePrice: '',
price: ''
}
]
}
]
}
...
...
@@ -1473,3 +1493,11 @@
'yohoodHref' : '/yohood'
}
### 新人专享列表页
{
goods:
[
{...}, //商品信息
...
]
}
...
...
static/js/home/home.js
View file @
750504c
...
...
@@ -153,7 +153,8 @@ if ($('.fresh-list-swiper').find('li').size() > 1) {
lazyLoadingInPrevNext
:
true
,
grabCursor
:
true
,
slidesPerView
:
'auto'
,
slideElement
:
'li'
slideElement
:
'li'
,
watchSlidesVisibility
:
true
});
}
...
...
static/sass/home/_fresh-only.css
View file @
750504c
...
...
@@ -39,6 +39,8 @@
.fresh-list-swiper
{
overflow
:
hidden
;
padding-bottom
:
15px
;
background-color
:
#fff
;
ul
{
box-sizing
:
border-box
;
...
...
@@ -112,6 +114,5 @@
.fresh-list
{
position
:
relative
;
min-height
:
440px
;
padding-left
:
14px
;
padding
:
15px
0
0
15px
;
}
\ No newline at end of file
...
...
template/m.yohobuy.com/actions/product/freshonly/fresh_list.phtml
0 → 100644
View file @
750504c
{
{>
layout/header
}
}
<div
class=
"fresh-list"
>
{
{#
freshList
}
}
{
{>
good
}
}
{
{/freshList
}
}
</ul>
{
{>
layout/footer
}
}
\ No newline at end of file
...
...
template/m.yohobuy.com/partials/home/fresh_only.phtml
View file @
750504c
...
...
@@ -3,7 +3,7 @@
{
{#
big_image
}
}
<div
class=
"fresh-swiper"
>
<a
href=
"{{url}}"
>
<img
class=
"lazy"
data-original=
"{{img}}"
alt=
"{{title}}"
>
<img
class=
"lazy"
data-original=
"{{img}}"
>
</a>
</div>
{
{/
big_image
}
}
...
...
@@ -13,17 +13,17 @@
<li
class=
"swiper-slide"
>
<div
class=
"img-box"
>
<a
href=
"{{url}}"
>
<img
class=
"
"
src=
"{{img}}"
alt=
""
>
<img
class=
"
swiper-lazy"
data-
src=
"{{img}}"
alt=
""
>
</a>
<
!--
<div
class=
"swiper-lazy-preloader"
></div>
--
>
<
div
class=
"swiper-lazy-preloader"
></div
>
</div>
<div
class=
"fresh-info"
>
<p
class=
"fresh-name"
><a
href=
"{{url}}"
>
{
{title
}
}</a></p>
<p
class=
"price"
>
<span
class=
"cur-price"
>¥
{
{curPrice
}
}</span>
{
{#
oldPrice
}
}
<span
class=
"old-price"
>¥
{
{oldPrice
}
}<span>
{
{/oldPrice
}
}
<span
class=
"cur-price"
>¥
{
{salePrice
}
}</span>
{
{#
price
}
}
<span
class=
"old-price"
>¥
{
{.
}
}<span>
{
{/price
}
}
</p>
<span
class=
"fresh-icon"
>新人价</span>
</div>
...
...
Please
register
or
login
to post a comment