Authored by biao

Merge branch 'release/1.0' of http://git.yoho.cn/fe/yoho-blk into release/1.0

... ... @@ -25,7 +25,8 @@ const _processListData = (list) => {
list = camelCase(list);
let listKey = [];
//console.log(list)
// console.log(list)
_.forEach(list.data.allList, function(value, index) {
... ...
... ... @@ -5,8 +5,8 @@
</div>
<div class="inline-block total-yohocoin">
<div class="current-yohocoin">目前可用YOHO币:<span class="blue">{{num.yohocoin_num}}</span></div>
<div class="left-yohocoin">{{currentYear}}年12月31日即将过期:<span class="blue">{{num.nearExpCoinNum}}</span></div>
<div class="current-yohocoin">目前可用YOHO币:<span class="blue">{{num.yohocoin_num}}</span></div>
<div class="left-yohocoin">{{currentYear}}年12月31日即将过期:<span class="blue">{{num.nearExpCoinNum}}</span></div>
</div>
</div>
{{> currency/nav}}
... ...
... ... @@ -18,7 +18,11 @@
{{!-- 新品banner --}}
{{#if banner.src}}
<div class="banner-img"
style="height: 200px;margin-bottom:30px; background:url({{image banner.src 850 200 2}}) no-repeat top center;"></div>
style="height: 200px;margin-bottom:30px;">
<a href="{{banner.url}}" target="_blank">
<img src="{{image banner.src 850 200 1}}" alt="{{banner.alt}}" width="850" height="200">
</a>
</div>
{{/if}}
{{!-- 已选中条件 --}}
{{#filter}}
... ...
... ... @@ -88,7 +88,7 @@
</div>
<div class="brand-btns">
<span class="btn disable large confirm">确定</span>
<span class="btn large cancel">取消</span>
<span class="btn white large cancel">取消</span>
</div>
</div>
</div>
... ... @@ -180,7 +180,7 @@
</div>
<div class="style-btns">
<span class="btn disable large confirm">确定</span>
<span class="btn large cancel">取消</span>
<span class="btn white large cancel">取消</span>
</div>
</div>
{{/if}}
... ...
... ... @@ -3,7 +3,7 @@
<div class="goods" data-id="{{productId}}" data-url="{{url}}">
<div class="goods-img">
<a href="{{url}}" target="_blank">
<img class="lazy" data-original="{{image defaultImages 263 344}}" width="263" height="344" alt="">
<img class="lazy" data-original="{{image defaultImages 267 354}}" width="267" height="354" alt="">
</a>
</div>
{{#if showBrand}}
... ... @@ -22,7 +22,7 @@
</div>
<div class="goods-list hide">
{{#each goodsList}}
<i data-url="{{url}}">{{image imagesUrl 256 343}}</i>
<i data-url="{{url}}">{{image imagesUrl 267 354}}</i>
{{/each}}
</div>
</div>
... ...
... ... @@ -32,7 +32,7 @@ const online = (req, res, next) => {
_.forEach(promotion, p => {
if (p.promotion === 'YOHO币') {
coin = parseInt(parseFloat(p.promotionAmount.substring(2, p.promotionAmount.length)) * 100);
coin = parseInt(parseFloat(p.promotionAmount.substring(2, p.promotionAmount.length)) * 100, 10);
}
});
... ... @@ -111,7 +111,7 @@ const callback = (req, res) => {
_.forEach(promotion, p => {
if (p.promotion === 'YOHO币') {
coin = _.toNumber(p.promotionAmount.substring(2, p.promotionAmount.length)) * 100;
coin = parseInt(parseFloat(p.promotionAmount.substring(2, p.promotionAmount.length)) * 100, 10);
}
});
... ...
... ... @@ -3,6 +3,6 @@
<div class="tips">
<span class="tip">哎呀,您访问的页面走丢了...</span>
<span class="tips-english">404 File Not Found, Sorry</span>
<span>建议您:<a href="javascript:location.reload()">刷新该网页/ </a><a href="javascript:history.go(-1)">返回上一页/</a> <a href="">去首页看看</a></span>
<span>建议您:<a href="javascript:location.reload()">刷新该网页/ </a><a href="javascript:history.go(-1)">返回上一页/</a> <a href="http://www.yohoblk.com">去首页看看</a></span>
</div>
</div>
\ No newline at end of file
... ...
... ... @@ -3,6 +3,6 @@
<div class="tips">
<span class="tip">哎呀,程序出错了...</span>
<span class="tips-english">500-Server Internal Error</span>
<span>建议您:<a href="javascript:location.reload()">刷新该网页/ </a><a href="javascript:history.go(-1)">返回上一页/</a> <a href="">去首页看看</a></span>
<span>建议您:<a href="javascript:location.reload()">刷新该网页/ </a><a href="javascript:history.go(-1)">返回上一页/</a> <a href="http://www.yohoblk.com">去首页看看</a></span>
</div>
</div>
\ No newline at end of file
... ...
... ... @@ -272,7 +272,11 @@ $applyBtn.click(function() {
var $tip = $applyBtn.siblings('.apply-tip'),
param = packApplyInfo();
if (!param) {
if ($(this).hasClass('disable')) {
return;
}
if (!param || !param.goods) {
$tip.removeClass('hide');
return;
} else {
... ...
... ... @@ -59,6 +59,15 @@ function changeThumb($dom) {
}
}
function chooseDefaultSize() {
var $item = $sizeList.not('.hide').children();
if ($colorItem && $colorItem.length === 1 &&
$item && $item.length === 1) {
$item.trigger('click');
}
}
function getBuyProduct() {
var sku;
... ... @@ -324,3 +333,5 @@ $sizeInfo.on('click', '.show-img', function() {
btns: []
}).show();
});
chooseDefaultSize(); // 如果size只有一个则默认选中
... ...
... ... @@ -324,7 +324,7 @@ var YohoListPage = {
},
openStyleMulit: function() {
$('.style-btns', this.rootDoc).removeClass('hide');
$('.style-btns', this.rootDoc).show();
$('.style-body .input-radio', this.rootDoc).check({
type: 'checkbox'
});
... ... @@ -333,7 +333,7 @@ var YohoListPage = {
},
closeStyleMulit: function() {
$('.style-btns', this.rootDoc).addClass('hide');
$('.style-btns', this.rootDoc).hide();
$('.style-body .input-radio', this.rootDoc).check('unCheckAll');
$('.style-body .input-radio', this.rootDoc).check({
type: 'radio'
... ...
... ... @@ -26,7 +26,7 @@
&:hover {
height: 50px;
> * {
> a {
color: #9a9a9a;
}
... ... @@ -264,6 +264,10 @@
.cur > a {
color: #1b1b1b;
}
li:hover > a {
color: #1b1b1b;
}
}
.main-logo {
... ... @@ -308,7 +312,9 @@
li:hover > a {
display: inline-block;
height: 40px;
border-bottom: 2px solid #fff;
color: #219dd6;
/* border-bottom: 2px solid #fff; */
}
}
... ...
... ... @@ -21,8 +21,6 @@
img {
width: 100%;
height: 100%;
margin-top: -1px;
margin-left: 0.1px;
}
}
... ...
... ... @@ -31,7 +31,7 @@
.nano > .nano-pane {
background: #eee;
position: absolute;
width: 5px;
width: 3px;
right: 0;
top: 0;
bottom: 0;
... ...
.yoho-product-list {
@import "order-area";
font-size: 14px;
.btn {
... ... @@ -10,10 +11,12 @@
.left {
width: 250px;
}
.right {
width: 850px;
}
}
.input-radio {
padding: 10px 1px;
cursor: pointer;
... ... @@ -35,14 +38,16 @@
}
}
}
.input-radio span {
margin-left: 0;
font-size: 14px;
display: inline-block;
}
.input-radio label {
font-size: 14px;
font-weight: 700;
font-weight: normal;
margin-left: 10px;
cursor: pointer;
}
... ... @@ -50,9 +55,11 @@
.input-radio label.round-color {
margin-left: 0;
}
.blank-div {
height: 70px;
}
.title {
font-size: 14px;
font-weight: 700;
... ... @@ -69,6 +76,7 @@
max-height: 240px;
overflow-y: auto;
}
.style-body {
max-height: 240px;
overflow-y: auto;
... ... @@ -90,8 +98,10 @@
color: #111;
}
}
.brand-body {
margin: 5px 0;
.brand-search {
border: 0;
background-color: #eae9e9;
... ... @@ -102,10 +112,12 @@
font-weight: 700;
}
}
.brand-letter-items {
margin: 15px 0;
font-size: 12px;
font-weight: bolder;
span {
padding: 5px 0;
margin: 5px 11px 5px 0;
... ... @@ -123,26 +135,36 @@
cursor: pointer;
}
}
.brand-btns,
.style-btns {
text-align: center;
margin-top: 10px;
display: none;
height: 38px;
.btn {
margin: 0 10px;
width: auto;
padding: 0 42px;
float: left;
}
.btn.cancel {
float: right;
}
}
.btn {
display: inline-block;
}
.btn.large {
height: 38px;
line-height: 38px;
font-size: 14px;
}
.price-btns {
.price-btns {
.price-input {
background-color: #eee;
width: 72px;
... ... @@ -175,6 +197,7 @@
margin-left: 4px;
}
}
.yoho-ui-accordion {
h3 {
font-size: 14px;
... ... @@ -185,12 +208,14 @@
display: block;
cursor: pointer;
position: relative;
.ui-accordion-header-icon {
position: absolute;
right: 0.5em;
top: 50%;
margin-top: -20px;
}
.ui-accordion-header-icon:after {
font-family: "iconfont" !important;
display: inline-block;
... ... @@ -205,6 +230,7 @@
content: "\e617";
}
}
> .body {
padding: 10px 0;
border-bottom: 1px solid #eee;
... ... @@ -224,7 +250,7 @@
label.cancel {
float: right;
color: #878787;
margin: 22px 20px 0 0;
margin: 27px 20px 0 0;
cursor: pointer;
}
... ... @@ -270,12 +296,11 @@
}
.goods-area {
margin: 0 -12px;
position: relative;
.goods {
margin: 10px 0;
margin: 10px 0 26px;
padding: 10px;
float: left;
text-align: center;
... ... @@ -294,8 +319,8 @@
.goods-img {
position: relative;
overflow: hidden;
width: 265px;
height: 344px;
width: 267px;
height: 354px;
img {
margin: 0;
... ... @@ -312,8 +337,9 @@
color: #fff;
}
}
.goods-name {
padding: 10px;
padding: 4px 10px 10px;
width: 265px;
overflow: hidden;
text-overflow: ellipsis;
... ... @@ -350,7 +376,7 @@
}
.goods-img-list {
margin: 2px 13px;
margin: 2px 10px;
float: left;
.goods-img-col {
... ... @@ -363,7 +389,6 @@
margin: 8px 0;
cursor: pointer;
}
}
}
}
... ... @@ -386,7 +411,6 @@
}
.yoho-list-empty {
height: 800px;
.tip-search {
... ...
... ... @@ -38,6 +38,7 @@
.iconfont.up {
top: -2px;
}
.iconfont.down {
top: 8px;
}
... ... @@ -50,9 +51,11 @@
.order-page {
height: 24px;
line-height: 24px;
margin-top: 12px;
margin-top: 14px;
float: right;
label {
line-height: 24px;
color: #1b1b1b;
font-weight: 700;
display: inline-block;
... ... @@ -80,5 +83,13 @@
color: #878787;
border: 2px solid #878787;
}
.page.page-next {
line-height: 20px;
}
.page.page-pre {
line-height: 20px;
}
}
}
... ...