Authored by 毕凯

SALE 增加折扣专场模块

... ... @@ -5,5 +5,6 @@
{{/topBanner}}
{{> sale/activity-entry}}
{{> sale/brand-sale}}
</div>
{{> layout/footer}}
... ...
<div class="activity-entry clearfix">
{{#activityEnter}}
<a class="entry-item pull-left {{#if @first}}first{{/if}} {{#if @last}}last{{/if}}" href="link">
<a class="entry-item pull-left {{#if @first}}first{{/if}} {{#if @last}}last{{/if}}" href="{{link}}">
<img class="icon pull-left" src="{{icon}}">
<div class="entry-text">
<span class="title">{{title}}</span>
... ...
<div class="brand-sale">
<div class="floor-title">
折扣专场 SALE
</div>
<div class="sale-group-big clearfix">
{{#brandSale}}
{{#big}}
<a class="item pull-left {{#if @first}}first{{/if}} {{#if @last}}last{{/if}}" href="{{link}}">
<div class="pic">
<img class="" src="{{img}}">
<div class="time">{{time}}</div>
</div>
<div class="detail">
<img class="brand pull-left" src="{{brand}}">
<div class="text">
<div class="discount">
<span class="num">{{discount}}</span> Off
</div>
<div class="title">
{{title}}
</div>
</div>
</div>
</a>
{{/big}}
{{/brandSale}}
</div>
<div class="sale-group">
</div>
</div>
... ...
... ... @@ -44,4 +44,75 @@
line-height: 48px;
}
}
.floor-title {
margin: 80px auto 40px;
width: 300px;
font-size: 16px;
line-height: 30px;
text-align: center;
border: 1px solid #000;
}
.brand-sale {
.sale-group-big {
.item {
width: 377px;
margin-right: 10px;
&.first,
&.last {
width: 376px;
}
&.last {
margin-right: 0;
}
}
.pic {
position: relative;
height: 400px;
}
.time {
@include box-sizing(border-box);
position: absolute;
left: 0;
bottom: 0;
width: 100%;
padding: 0 10px;
font-size: 16px;
line-height: 30px;
text-align: right;
color: #fff;
background: #4e4e4e;
}
.detail {
background: #f5f5f5;
}
.brand {
margin: 24px 10px;
}
.text {
padding: 24px 10px 24px 0;
font-size: 14px;
color: #fd5659;
}
.discount {
font-size: 28px;
font-weight: bold;
.num {
font-size: 40px;
}
}
}
}
}
... ...
... ... @@ -50,6 +50,35 @@ class Sale1Controller extends WebAction
'desc' => 'Off Price',
'link' => 'http://www.yohobuy.com'
)
),
'brandSale' => array(
'big' => array(
array(
'img' => 'http://img13.static.yhbimg.com/goodsimg/2015/03/31/07/02c9f302b6a633d7fac1a08655633a45d3.jpg?imageView/1/w/376/h/400',
'link' => 'http://www.yohobuy.com',
'time' => '低于1小时',
'brand' => 'http://img11.static.yhbimg.com/yhb-img01/2015/12/22/09/0168ae2421d5283414ff5b873fa4a1c16a.jpg?imageView/1/w/185/h/62',
'title' => '2015春夏海量大促!',
'discount' => '70%',
),
array(
'img' => 'http://img13.static.yhbimg.com/goodsimg/2015/03/31/07/02c9f302b6a633d7fac1a08655633a45d3.jpg?imageView/1/w/376/h/400',
'link' => 'http://www.yohobuy.com',
'time' => '低于1小时',
'brand' => 'http://img11.static.yhbimg.com/yhb-img01/2015/12/22/09/0168ae2421d5283414ff5b873fa4a1c16a.jpg?imageView/1/w/185/h/62',
'title' => '2015春夏海量大促!',
'discount' => '70%',
),
array(
'img' => 'http://img13.static.yhbimg.com/goodsimg/2015/03/31/07/02c9f302b6a633d7fac1a08655633a45d3.jpg?imageView/1/w/376/h/400',
'link' => 'http://www.yohobuy.com',
'time' => '低于1小时',
'brand' => 'http://img11.static.yhbimg.com/yhb-img01/2015/12/22/09/0168ae2421d5283414ff5b873fa4a1c16a.jpg?imageView/1/w/185/h/62',
'title' => '2015春夏海量大促!',
'discount' => '70%',
)
),
'normal' => array()
)
);
$this->setWebNavHeader();
... ...