Toggle navigation
Toggle navigation
This project
Loading...
Sign in
wangshusheng
/
YOHOBUYPC
·
Commits
Go to a project
GitLab
Go to dashboard
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
xuqi
9 years ago
Commit
a01e4c8b1a82822b3f3bbb366e563a804e657946
1 parent
3c3610f8
brand intro
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
89 additions
and
4 deletions
static/js/product/list.js
static/sass/product/_list.scss
template/m.yohobuy.com/actions/product/list/index.phtml
yohobuy/m.yohobuy.com/application/modules/Product/controllers/List.php
static/js/product/list.js
View file @
a01e4c8
...
...
@@ -7,6 +7,10 @@
var
$
=
require
(
'yoho.zepto'
),
lazyLoad
=
require
(
'yoho.zeptolazyload'
);
//品牌页参数
var
$brandHeader
=
$
(
'#brand-header'
),
$introBox
=
$
(
'#intro-box'
);
var
filter
=
require
(
'../plugin/filter'
);
var
$goodsContainer
=
$
(
'#goods-container'
),
...
...
@@ -276,4 +280,22 @@ $(window).scroll(function() {
$
(
document
).
height
()
-
0.25
*
$goodsContainer
.
height
())
{
search
();
}
});
//品牌介绍
$brandHeader
.
children
(
'.btn-intro'
).
bind
(
'touchstart'
,
function
()
{
$introBox
.
removeClass
(
'hide'
);
});
$
(
'.close-intro, .brand-intro-box'
).
click
(
function
()
{
$introBox
.
addClass
(
'hide'
);
});
$
(
'#brand-intro'
).
click
(
function
(
e
)
{
e
.
stopPropagation
();
});
//品牌收藏
$brandHeader
.
children
(
'.btn-col'
).
bind
(
'touchstart'
,
function
()
{
$
(
this
).
toggleClass
(
'coled'
);
});
\ No newline at end of file
...
...
static/sass/product/_list.scss
View file @
a01e4c8
...
...
@@ -96,10 +96,59 @@
.btn-col
{
right
:
15px
;
.iconfont
{
font-size
:
12px
;
}
}
.brand-intro-box
{
display
:
none
;
position
:
absolute
;
top
:
0
;
left
:
0
;
right
:
0
;
bottom
:
0
;
background
:
rgba
(
0
,
0
,
0
,.
3
);
padding
:
44px
0
;
z-index
:
1
;
overflow
:
auto
;
.brand-intro
{
position
:
relative
;
box-sizing
:
border-box
;
width
:
85%
;
margin
:
0
7
.5%
;
background
:
#fff
;
padding
:
10px
8%
;
}
h2
{
text-align
:
center
;
font-size
:
17px
;
line-height
:
40px
;
}
.con
{
font-size
:
12px
;
line-height
:
16px
;
padding
:
20px
0
;
border-top
:
1px
solid
#e6e6e6
;
border-bottom
:
1px
solid
#e6e6e6
;
overflow-x
:
hidden
;
}
.fo
{
font-size
:
18px
;
height
:
40px
;
line-height
:
40px
;
text-align
:
center
;
}
.close-intro
{
position
:
absolute
;
top
:
6px
;
right
:
6px
;
}
}
.list-nav
{
...
...
template/m.yohobuy.com/actions/product/list/index.phtml
View file @
a01e4c8
...
...
@@ -24,7 +24,7 @@
{
{/
brandWay
}
}
{
{#
brand
}
}
<div
class=
"brand-header"
data-id=
{
{id
}
}>
<div
id=
"brand-header"
class=
"brand-header"
data-id=
{
{id
}
}>
<img
class=
"lazy"
data-original=
{
{banner
}
}>
<a
class=
"btn-intro"
href=
"javascript:void(0);"
>
品牌介绍
...
...
@@ -34,8 +34,18 @@
收藏
</a>
</div>
<div
class=
"brand-intro-box"
>
<div
id=
"brand-intro"
class=
"brand-intro"
>
{
{intro
}
}</div>
<div
id=
"intro-box"
class=
"brand-intro-box hide"
>
<div
id=
"brand-intro"
class=
"brand-intro"
>
<h
2
>品牌介绍</h
2
>
<div
class=
"con"
>
{
{{intro
}
}}
</div>
<p
class=
"fo"
>
<span></span>
100
%品牌授权正品
</p>
<span
class=
"iconfont close-intro"
>
623
;</span>
</div>
</div>
{
{/
brand
}
}
...
...
yohobuy/m.yohobuy.com/application/modules/Product/controllers/List.php
View file @
a01e4c8
...
...
@@ -19,6 +19,10 @@ class ListController extends AbstractAction
'name'
=>
'Aape'
,
'thumb'
=>
'http://img13.static.yhbimg.com/brandLogo/2015/08/26/15/02261f64c198cb4b181c5ef9e61f38f4b9.jpg?imageMogr2/thumbnail/150x70/extent/150x70/background/d2hpdGU=/position/center/quality/90'
),
'brand'
=>
array
(
'id'
=>
1
,
'banner'
=>
'http://img10.static.yhbimg.com/brandBanner/2015/08/26/07/015af5d6ee626cb132cd9c436e896fae26.jpg?imageMogr2/crop/640x'
),
'new'
=>
array
(
array
(
'id'
=>
1
,
...
...
Please
register
or
login
to post a comment