Merge branch 'develop' of http://git.dev.yoho.cn/web/yohobuy into develop
Showing
27 changed files
with
353 additions
and
136 deletions
@@ -46,7 +46,7 @@ class LoginData extends \LibModels\Wap\Passport\LoginData | @@ -46,7 +46,7 @@ class LoginData extends \LibModels\Wap\Passport\LoginData | ||
46 | 46 | ||
47 | $param['client_secret'] = Sign::getSign($param); | 47 | $param['client_secret'] = Sign::getSign($param); |
48 | 48 | ||
49 | - return Yohobuy::get(Yohobuy::API_URL2, $param); | 49 | + return Yohobuy::get(Yohobuy::API_URL, $param); |
50 | } | 50 | } |
51 | 51 | ||
52 | } | 52 | } |
@@ -181,10 +181,10 @@ $yohoPage.on('touchstart', '.color-list .block', function() { | @@ -181,10 +181,10 @@ $yohoPage.on('touchstart', '.color-list .block', function() { | ||
181 | hasChooseColor = false; | 181 | hasChooseColor = false; |
182 | 182 | ||
183 | //当前尺码行隐藏 | 183 | //当前尺码行隐藏 |
184 | - $sizeRowList.eq(curSizeIndex).removeClass('show').addClass('hide'); | 184 | + $sizeRowList.eq(curSizeIndex).addClass('hide'); |
185 | 185 | ||
186 | //目标尺码行显示 | 186 | //目标尺码行显示 |
187 | - $sizeRowList.eq(0).removeClass('hide').addClass('show'); | 187 | + $sizeRowList.eq(0).removeClass('hide'); |
188 | 188 | ||
189 | curSizeIndex = 0; | 189 | curSizeIndex = 0; |
190 | 190 | ||
@@ -202,10 +202,10 @@ $yohoPage.on('touchstart', '.color-list .block', function() { | @@ -202,10 +202,10 @@ $yohoPage.on('touchstart', '.color-list .block', function() { | ||
202 | displayGoodNum(curGoodNum); | 202 | displayGoodNum(curGoodNum); |
203 | 203 | ||
204 | // 尺码行当前行隐藏 | 204 | // 尺码行当前行隐藏 |
205 | - $sizeRowList.eq(curSizeIndex).removeClass('show').addClass('hide'); | 205 | + $sizeRowList.eq(curSizeIndex).addClass('hide'); |
206 | 206 | ||
207 | //尺码对应行显示 | 207 | //尺码对应行显示 |
208 | - $sizeRowList.eq(index + 1).removeClass('hide').addClass('show'); | 208 | + $sizeRowList.eq(index + 1).removeClass('hide'); |
209 | 209 | ||
210 | curSizeIndex = index + 1; | 210 | curSizeIndex = index + 1; |
211 | $curColorBlock = $this; | 211 | $curColorBlock = $this; |
@@ -393,4 +393,4 @@ $yohoPage.on('touchstart', '.btn-minus', function() { | @@ -393,4 +393,4 @@ $yohoPage.on('touchstart', '.btn-minus', function() { | ||
393 | }); | 393 | }); |
394 | 394 | ||
395 | exports.init = init; | 395 | exports.init = init; |
396 | -exports.show = show; | 396 | +exports.show = show; |
@@ -19,17 +19,10 @@ | @@ -19,17 +19,10 @@ | ||
19 | <div class="chose-items"> | 19 | <div class="chose-items"> |
20 | <div class="color-list block-list"> | 20 | <div class="color-list block-list"> |
21 | <span>颜色</span> | 21 | <span>颜色</span> |
22 | - <!--<ul class="clearfix" data-type="color"> | ||
23 | - {{# colors}} | ||
24 | - <li class="block {{#if chosed}}chosed{{/if}} {{#unless colorNum}}zero-stock{{/unless}}" data-num="{{colorNum}}" data-id="{{id}}" data-numstr="{{sizeNumStr}}" data-skcid="{{skcId}}"> | ||
25 | - {{name}} | ||
26 | - </li> | ||
27 | - {{/ colors}} | ||
28 | - </ul>--> | ||
29 | {{# colors}} | 22 | {{# colors}} |
30 | <ul class="size-row clearfix {{#unless @first}}hide{{/if}}"> | 23 | <ul class="size-row clearfix {{#unless @first}}hide{{/if}}"> |
31 | {{# color}} | 24 | {{# color}} |
32 | - <li class="block {{#if chosed}}chosed{{/if}} {{#unless colorNum}}zero-stock{{/unless}}" data-num="{{colorNum}}" data-id="{{id}}" data-numstr="{{sizeNumStr}}" data-skcid="{{skcId}}"> | 25 | + <li class="block {{#if chosed}}chosed{{/if}} {{#unless colorNum}}zero-stock{{/unless}}" data-num="{{colorNum}}"> |
33 | {{name}} | 26 | {{name}} |
34 | </li> | 27 | </li> |
35 | {{/ color}} | 28 | {{/ color}} |
@@ -41,20 +34,12 @@ | @@ -41,20 +34,12 @@ | ||
41 | {{# sizes}} | 34 | {{# sizes}} |
42 | <ul class="size-row clearfix {{#unless @first}}hide{{/if}}"> | 35 | <ul class="size-row clearfix {{#unless @first}}hide{{/if}}"> |
43 | {{# size}} | 36 | {{# size}} |
44 | - <li class="block {{#if chosed}}chosed{{/if}} {{#unless sizeNum}}zero-stock{{/unless}}" data-id="{{id}}" data-colorid="{{colorId}}" data-num="{{sizeNum}}" data-numstr="{{colorNumStr}}" data-skuid="{{skuId}}" data-goodid="{{goodsId}}"> | 37 | + <li class="block {{#if chosed}}chosed{{/if}} {{#unless sizeNum}}zero-stock{{/unless}}" data-num="{{sizeNum}}" data-skuid="{{skuId}}"> |
45 | {{name}} | 38 | {{name}} |
46 | </li> | 39 | </li> |
47 | {{/ size}} | 40 | {{/ size}} |
48 | </ul> | 41 | </ul> |
49 | {{/ sizes}} | 42 | {{/ sizes}} |
50 | - | ||
51 | - <!--{{#if defaultSizes}} | ||
52 | - <ul class="size-row clearfix default-size"> | ||
53 | - {{#each defaultSizes}} | ||
54 | - <li class="block {{#if numZero}}zero-stock{{/if}}" data-numstr="{{numStr}}">{{name}}</li> | ||
55 | - {{/each}} | ||
56 | - </ul> | ||
57 | - {{/if}}--> | ||
58 | </div> | 43 | </div> |
59 | <p> | 44 | <p> |
60 | <div class="num"> | 45 | <div class="num"> |
@@ -2,9 +2,14 @@ | @@ -2,9 +2,14 @@ | ||
2 | <div class="new-sale-page product-page yoho-page"> | 2 | <div class="new-sale-page product-page yoho-page"> |
3 | {{# saleList}} | 3 | {{# saleList}} |
4 | {{# saleBanner}} | 4 | {{# saleBanner}} |
5 | - <div class="banner-img" style="height: {{bannerHeight}}px;background:url({{img}}) no-repeat top center;"></div> | 5 | + <div class="sale-list-banner" style="height: {{bannerHeight}}px;"> |
6 | + <ul style="height: {{bannerHeight}}px;"> | ||
7 | + {{# list}} | ||
8 | + <li class="banner-img" style="background:url({{img}}) no-repeat top center;"></li> | ||
9 | + {{/ list}} | ||
10 | + </ul> | ||
11 | + </div> | ||
6 | {{/ saleBanner}} | 12 | {{/ saleBanner}} |
7 | - | ||
8 | <div class="center-content clearfix"> | 13 | <div class="center-content clearfix"> |
9 | {{# saleTitle}} | 14 | {{# saleTitle}} |
10 | <div class="header-title"> | 15 | <div class="header-title"> |
@@ -144,7 +144,7 @@ | @@ -144,7 +144,7 @@ | ||
144 | {{!-- sale列表 --}} | 144 | {{!-- sale列表 --}} |
145 | {{#if saleListPage}} | 145 | {{#if saleListPage}} |
146 | <script> | 146 | <script> |
147 | - seajs.use(['js/product/list', 'js/product/product'], function (list, product) { | 147 | + seajs.use(['js/product/list', 'js/product/product', 'js/product/banner'], function (list, product) { |
148 | 148 | ||
149 | product.init(4); | 149 | product.init(4); |
150 | window.onresize = function () { | 150 | window.onresize = function () { |
@@ -39,7 +39,7 @@ | @@ -39,7 +39,7 @@ | ||
39 | <span class="title">性别:</span> | 39 | <span class="title">性别:</span> |
40 | 40 | ||
41 | <div class="attr-content clearfix"> | 41 | <div class="attr-content clearfix"> |
42 | - {{#each channel}} | 42 | + {{#each gender}} |
43 | <a class="attr {{#if checked}}checked{{/if}}" href="{{href}}"> | 43 | <a class="attr {{#if checked}}checked{{/if}}" href="{{href}}"> |
44 | {{name}} | 44 | {{name}} |
45 | </a> | 45 | </a> |
@@ -55,7 +55,7 @@ | @@ -55,7 +55,7 @@ | ||
55 | <div class="attr-content"> | 55 | <div class="attr-content"> |
56 | <ul class="sort-pre clearfix"> | 56 | <ul class="sort-pre clearfix"> |
57 | {{#each sort}} | 57 | {{#each sort}} |
58 | - <li> | 58 | + <li data-id="{{id}}"> |
59 | <span class="attr {{#if checked}}checked{{/if}}"> | 59 | <span class="attr {{#if checked}}checked{{/if}}"> |
60 | {{name}} | 60 | {{name}} |
61 | <div class="sort-up-icon"></div> | 61 | <div class="sort-up-icon"></div> |
@@ -92,14 +92,16 @@ | @@ -92,14 +92,16 @@ | ||
92 | {{/ default}} | 92 | {{/ default}} |
93 | </ul> | 93 | </ul> |
94 | 94 | ||
95 | - <div class="brand-opt"> | ||
96 | - <span id="brand-more" class="brand-more"> | ||
97 | - <em>更多</em> | ||
98 | - <i class="iconfont"></i> | ||
99 | - </span> | 95 | + {{#unless hideMore}} |
96 | + <div class="brand-opt"> | ||
97 | + <span id="brand-more" class="brand-more"> | ||
98 | + <em>更多</em> | ||
99 | + <i class="iconfont"></i> | ||
100 | + </span> | ||
100 | 101 | ||
101 | - <span id="brand-multi" class="multi-select">多选 +</span> | ||
102 | - </div> | 102 | + <span id="brand-multi" class="multi-select">多选 +</span> |
103 | + </div> | ||
104 | + {{/unless}} | ||
103 | 105 | ||
104 | <div class="brand-panel hide"> | 106 | <div class="brand-panel hide"> |
105 | <div class="panel-head clearfix"> | 107 | <div class="panel-head clearfix"> |
@@ -177,17 +179,15 @@ | @@ -177,17 +179,15 @@ | ||
177 | </div> | 179 | </div> |
178 | {{/if}} | 180 | {{/if}} |
179 | 181 | ||
180 | - {{#if size}} | ||
181 | - <div class="size section"> | ||
182 | - <span class="title">尺码:</span> | 182 | + <div class="size section hide"> |
183 | + <span class="title">尺码:</span> | ||
183 | 184 | ||
184 | - <div class="attr-content clearfix"> | ||
185 | - {{# size}} | ||
186 | - <a class="attr {{#if checked}}checked{{/if}}" href="{{href}}">{{name}}</a> | ||
187 | - {{/ size}} | ||
188 | - </div> | 185 | + <div class="attr-content clearfix"> |
186 | + {{# size}} | ||
187 | + <a class="attr {{#if checked}}checked{{/if}}" href="{{href}}">{{name}}</a> | ||
188 | + {{/ size}} | ||
189 | </div> | 189 | </div> |
190 | - {{/if}} | 190 | + </div> |
191 | 191 | ||
192 | {{#if seniorChose}} | 192 | {{#if seniorChose}} |
193 | <div class="senior section"> | 193 | <div class="senior section"> |
@@ -25,7 +25,7 @@ | @@ -25,7 +25,7 @@ | ||
25 | {{/ tags}} | 25 | {{/ tags}} |
26 | </div> | 26 | </div> |
27 | <div class="good-detail-img"> | 27 | <div class="good-detail-img"> |
28 | - <a class="good-thumb" href="{{url}}"> | 28 | + <a class="good-thumb" href="{{url}}" target="_blank"> |
29 | <img class="lazy" data-original="{{thumb}}"> | 29 | <img class="lazy" data-original="{{thumb}}"> |
30 | </a> | 30 | </a> |
31 | {{# isFew}} | 31 | {{# isFew}} |
@@ -37,7 +37,7 @@ | @@ -37,7 +37,7 @@ | ||
37 | {{/if}} | 37 | {{/if}} |
38 | </div> | 38 | </div> |
39 | <div class="good-detail-text"> | 39 | <div class="good-detail-text"> |
40 | - <a href="{{url}}">{{name}}</a> | 40 | + <a href="{{url}}" target="_blank">{{name}}</a> |
41 | <p class="price"> | 41 | <p class="price"> |
42 | {{# marketPrice}} | 42 | {{# marketPrice}} |
43 | <span class="market-price">¥{{.}}</span> | 43 | <span class="market-price">¥{{.}}</span> |
web-static/img/product/default-active.png
0 → 100644

1.16 KB
web-static/img/product/default-normal.png
0 → 100644

1.26 KB
@@ -211,13 +211,17 @@ $account.on('keyup', function() { | @@ -211,13 +211,17 @@ $account.on('keyup', function() { | ||
211 | //密码 | 211 | //密码 |
212 | $password.on('blur', function() { | 212 | $password.on('blur', function() { |
213 | validatePassword(); | 213 | validatePassword(); |
214 | + | ||
215 | + if ($capsLock.hasClass('hide')) { | ||
216 | + return; | ||
217 | + } | ||
218 | + | ||
219 | + $capsLock.addClass('hide'); | ||
214 | }).on('keypress', function(e) { | 220 | }).on('keypress', function(e) { |
215 | - var code = e.which, | ||
216 | - isShift = e.shiftKey || (code === 16) || false; | 221 | + var code = e.which; |
217 | 222 | ||
218 | //CapsLock检测 | 223 | //CapsLock检测 |
219 | - if ((!isShift && (code >= 65 && code <= 90)) || | ||
220 | - (isShift && (code >= 97 && code <= 122))) { | 224 | + if (code >= 65 && code <= 90) { |
221 | $capsLock.removeClass('hide'); | 225 | $capsLock.removeClass('hide'); |
222 | return; | 226 | return; |
223 | } | 227 | } |
@@ -276,7 +280,7 @@ $('#login-btn').on('click', function() { | @@ -276,7 +280,7 @@ $('#login-btn').on('click', function() { | ||
276 | if (data.data) { | 280 | if (data.data) { |
277 | 281 | ||
278 | //防止data.data为undefined时下行语句执行出错而导致脚本不能走到complete去处理authing | 282 | //防止data.data为undefined时下行语句执行出错而导致脚本不能走到complete去处理authing |
279 | - location.href = data.data.href; | 283 | + location.href = data.data.session; |
280 | } | 284 | } |
281 | } else { | 285 | } else { |
282 | $passwordTip.removeClass('hide').children('em').text(data.message); | 286 | $passwordTip.removeClass('hide').children('em').text(data.message); |
@@ -417,6 +417,18 @@ function pwdFn($obj) { | @@ -417,6 +417,18 @@ function pwdFn($obj) { | ||
417 | // Tips: 不可以在获得焦点的时候验证,获得焦点和失去焦点的间隔太小,如果中间存在ajax校验的话会出现问题 | 417 | // Tips: 不可以在获得焦点的时候验证,获得焦点和失去焦点的间隔太小,如果中间存在ajax校验的话会出现问题 |
418 | // ( ▼-▼ )注册页和信息完善页面接口不同 | 418 | // ( ▼-▼ )注册页和信息完善页面接口不同 |
419 | exports.init = function(page) { | 419 | exports.init = function(page) { |
420 | + | ||
421 | + $('#agree-terms').click(function() { | ||
422 | + if ($(this).attr('notchecked')) { | ||
423 | + console.log(1); | ||
424 | + $(this).removeAttr('notchecked'); | ||
425 | + } else { | ||
426 | + console.log(2); | ||
427 | + $(this).attr('notchecked', 'true'); | ||
428 | + } | ||
429 | + | ||
430 | + }); | ||
431 | + | ||
420 | $registerPage.find('.va').keyup(function() { | 432 | $registerPage.find('.va').keyup(function() { |
421 | 433 | ||
422 | var j, | 434 | var j, |
@@ -438,7 +450,7 @@ exports.init = function(page) { | @@ -438,7 +450,7 @@ exports.init = function(page) { | ||
438 | 450 | ||
439 | } | 451 | } |
440 | 452 | ||
441 | - if (statusLen === 4 && $('#agree-terms').is(':checked')) { | 453 | + if (statusLen === 4 && !$('#agree-terms').attr('notchecked')) { |
442 | $registerBtn.removeClass('disable').removeAttr('disabled'); | 454 | $registerBtn.removeClass('disable').removeAttr('disabled'); |
443 | } else { | 455 | } else { |
444 | $registerBtn.addClass('disable').attr('disabled', 'true'); | 456 | $registerBtn.addClass('disable').attr('disabled', 'true'); |
@@ -515,18 +527,6 @@ exports.init = function(page) { | @@ -515,18 +527,6 @@ exports.init = function(page) { | ||
515 | }); | 527 | }); |
516 | 528 | ||
517 | // 防止粘贴密码 | 529 | // 防止粘贴密码 |
518 | - /*$('#pwd, #repwd').keydown(function (event) { | ||
519 | - | ||
520 | - console.log(event.ctrlKey); | ||
521 | - console.log(isPwd); | ||
522 | - console.log(event.keyCode); | ||
523 | - | ||
524 | - if (event.ctrlKey && isPwd && event.keyCode === 86) { | ||
525 | - $(this).val(pwdVal); | ||
526 | - } | ||
527 | - | ||
528 | - });*/ | ||
529 | - | ||
530 | $pwd[0].onpaste = function() { | 530 | $pwd[0].onpaste = function() { |
531 | return false; | 531 | return false; |
532 | }; | 532 | }; |
web-static/js/product/banner.js
0 → 100644
1 | +/* | ||
2 | + * author: chenglong | ||
3 | + */ | ||
4 | + | ||
5 | +var Slide = require('../common/yohoui/YH.slide'); | ||
6 | +var $ = require('yoho.jquery'); | ||
7 | + | ||
8 | +var $contain = $('.sale-list-banner'); | ||
9 | +var $item = $contain.find('li'); | ||
10 | +var index = 0; | ||
11 | +var pagationStr = ''; | ||
12 | +var pagationBoxStr = ''; | ||
13 | +var i; | ||
14 | +var current = true; | ||
15 | +var slide; | ||
16 | + | ||
17 | +for (i = 0; i < $item.length; i++) { | ||
18 | + | ||
19 | + if (i === 0) { | ||
20 | + pagationStr += '<span class="active"></span>'; | ||
21 | + } else { | ||
22 | + pagationStr += '<span></span>'; | ||
23 | + } | ||
24 | +} | ||
25 | + | ||
26 | +pagationBoxStr = '<div class="sale-list-pagation"><div>' + pagationStr + '</div></div>'; | ||
27 | + | ||
28 | +$contain.append($(pagationBoxStr)); | ||
29 | + | ||
30 | +slide = new Slide({ | ||
31 | + length: $item.length, | ||
32 | + loop: true, | ||
33 | + auto: true, | ||
34 | + timeout: 2, | ||
35 | + index: 0 | ||
36 | +}); | ||
37 | + | ||
38 | + | ||
39 | +slide.on('change', function(data) { | ||
40 | + if (current) { | ||
41 | + current = false; | ||
42 | + } else { | ||
43 | + return; | ||
44 | + } | ||
45 | + index++; | ||
46 | + | ||
47 | + | ||
48 | + $('.sale-list-pagation').find('span').removeClass('active'); | ||
49 | + $item.eq(data.from).animate({ | ||
50 | + opacity: 0 | ||
51 | + }, 300); | ||
52 | + $item.eq(data.to).css({ | ||
53 | + zIndex: index | ||
54 | + }).animate({ | ||
55 | + opacity: 1 | ||
56 | + }, 300, function() { | ||
57 | + current = true; | ||
58 | + }); | ||
59 | + | ||
60 | + $('.sale-list-pagation').find('span').eq(data.to).addClass('active'); | ||
61 | + | ||
62 | +}); | ||
63 | + | ||
64 | +$contain.hover(function() { | ||
65 | + if (current) { | ||
66 | + slide.pause(); | ||
67 | + } | ||
68 | + | ||
69 | +}, function() { | ||
70 | + slide.resume(); | ||
71 | +}); | ||
72 | + | ||
73 | +$('.sale-list-pagation span').click(function() { | ||
74 | + | ||
75 | + var index = $(this).index(); | ||
76 | + | ||
77 | + if (current) { | ||
78 | + slide.go(index); | ||
79 | + } | ||
80 | +}); | ||
81 | + | ||
82 | +slide.init(); |
@@ -4,7 +4,8 @@ | @@ -4,7 +4,8 @@ | ||
4 | * @date: 2015/12/4 | 4 | * @date: 2015/12/4 |
5 | */ | 5 | */ |
6 | 6 | ||
7 | -var $ = require('yoho.jquery'); | 7 | +var $ = require('yoho.jquery'), |
8 | + Handlebars = require('yoho.handlebars'); | ||
8 | 9 | ||
9 | var checkUnicode = { | 10 | var checkUnicode = { |
10 | unchecked: '', | 11 | unchecked: '', |
@@ -38,6 +39,13 @@ var $seniorSubWrap = $('.senior-sub-wrap'), | @@ -38,6 +39,13 @@ var $seniorSubWrap = $('.senior-sub-wrap'), | ||
38 | 39 | ||
39 | var seniorHoverTime, hoveredIndex; | 40 | var seniorHoverTime, hoveredIndex; |
40 | 41 | ||
42 | +// 尺寸 handlebars 模板 | ||
43 | +var sizeTmpl = '{{# size}}<a class="attr {{#if checked}}checked{{/if}}" href="{{href}}">{{name}}</a>{{/ size}}', | ||
44 | + sizeCache = {}, // 缓存一下尺寸信息 | ||
45 | + $sizeWrap = $('.filter-box .size'); | ||
46 | + | ||
47 | +sizeTmpl = Handlebars.compile(sizeTmpl); | ||
48 | + | ||
41 | //清除checkbox选中状态 | 49 | //清除checkbox选中状态 |
42 | function clearChecked($checkbox) { | 50 | function clearChecked($checkbox) { |
43 | $checkbox.removeClass('checked').html(checkUnicode.unchecked); | 51 | $checkbox.removeClass('checked').html(checkUnicode.unchecked); |
@@ -85,13 +93,45 @@ $('.filter-box').on('selectstart', '.attr, .brands-index span', function() { | @@ -85,13 +93,45 @@ $('.filter-box').on('selectstart', '.attr, .brands-index span', function() { | ||
85 | //【分类】 | 93 | //【分类】 |
86 | $('.sort-pre').on('click', 'li', function() { | 94 | $('.sort-pre').on('click', 'li', function() { |
87 | var $this = $(this), | 95 | var $this = $(this), |
88 | - index = $this.index(); | 96 | + index = $this.index(), |
97 | + id = $this.data('id'); | ||
98 | + | ||
99 | + if ($this.hasClass('active')) { | ||
100 | + | ||
101 | + // 选中时,再次点击取消选中 | ||
102 | + $this.removeClass('active'); | ||
103 | + $sortSub.children(':eq(' + index + ')').addClass('hide'); | ||
104 | + $sizeWrap.addClass('hide'); | ||
105 | + return; | ||
106 | + } | ||
89 | 107 | ||
90 | $this.siblings('.active').removeClass('active'); | 108 | $this.siblings('.active').removeClass('active'); |
91 | $this.addClass('active'); | 109 | $this.addClass('active'); |
92 | 110 | ||
93 | $sortSub.children(':not(.hide)').addClass('hide'); | 111 | $sortSub.children(':not(.hide)').addClass('hide'); |
94 | $sortSub.children(':eq(' + index + ')').removeClass('hide'); | 112 | $sortSub.children(':eq(' + index + ')').removeClass('hide'); |
113 | + | ||
114 | + if (sizeCache[id]) { | ||
115 | + $sizeWrap.find('.attr-content').html(sizeCache[id]); | ||
116 | + $sizeWrap.removeClass('hide'); | ||
117 | + } else { | ||
118 | + $.ajax({ | ||
119 | + url: '/product/search/sortSize', | ||
120 | + data: { | ||
121 | + msort: id | ||
122 | + } | ||
123 | + }).then(function(res) { | ||
124 | + if ($.type(res) === 'array' && res.length) { | ||
125 | + sizeCache[id] = sizeTmpl({ | ||
126 | + size: res | ||
127 | + }); | ||
128 | + $sizeWrap.find('.attr-content').html(sizeCache[id]); | ||
129 | + $sizeWrap.removeClass('hide'); | ||
130 | + } else { | ||
131 | + $sizeWrap.addClass('hide'); | ||
132 | + } | ||
133 | + }); | ||
134 | + } | ||
95 | }); | 135 | }); |
96 | 136 | ||
97 | //【品牌】 | 137 | //【品牌】 |
@@ -132,10 +172,17 @@ $brandMore.click(function() { | @@ -132,10 +172,17 @@ $brandMore.click(function() { | ||
132 | }); | 172 | }); |
133 | 173 | ||
134 | //【品牌】索引 | 174 | //【品牌】索引 |
135 | -$('.brands-index').on('click', 'span', function() { | 175 | +$('.brands-index').on('mouseenter', 'span', function() { |
136 | var $this = $(this), | 176 | var $this = $(this), |
137 | index = $this.data('index'); | 177 | index = $this.data('index'); |
138 | 178 | ||
179 | + if ($this.hasClass('hover')) { | ||
180 | + return; | ||
181 | + } | ||
182 | + | ||
183 | + $this.siblings('span.hover').removeClass('hover'); | ||
184 | + $this.addClass('hover'); | ||
185 | + | ||
139 | if ($this.index() === 0) { | 186 | if ($this.index() === 0) { |
140 | 187 | ||
141 | //全部 | 188 | //全部 |
@@ -121,4 +121,17 @@ $third: sprite-map("passport/third/*.png"); | @@ -121,4 +121,17 @@ $third: sprite-map("passport/third/*.png"); | ||
121 | background: sprite($third, renren) no-repeat; | 121 | background: sprite($third, renren) no-repeat; |
122 | } | 122 | } |
123 | } | 123 | } |
124 | + | ||
125 | + .caps-lock { | ||
126 | + position: absolute; | ||
127 | + color: #666; | ||
128 | + border: #ffe57d; | ||
129 | + background: #fff6d2; | ||
130 | + white-space: nowrap; | ||
131 | + top: 8px; | ||
132 | + left: 278px; | ||
133 | + padding: 0 20px; | ||
134 | + height: 27px; | ||
135 | + line-height: 30px; | ||
136 | + } | ||
124 | } | 137 | } |
@@ -170,15 +170,19 @@ | @@ -170,15 +170,19 @@ | ||
170 | float: left; | 170 | float: left; |
171 | line-height: 30px; | 171 | line-height: 30px; |
172 | margin-right: 5px; | 172 | margin-right: 5px; |
173 | + cursor: pointer; | ||
173 | 174 | ||
174 | span { | 175 | span { |
175 | margin: 0 3px; | 176 | margin: 0 3px; |
176 | - cursor: pointer; | ||
177 | -moz-user-select: none; | 177 | -moz-user-select: none; |
178 | 178 | ||
179 | &:first-child { | 179 | &:first-child { |
180 | margin-left: 10px; | 180 | margin-left: 10px; |
181 | } | 181 | } |
182 | + | ||
183 | + &.hover { | ||
184 | + color: #f00; | ||
185 | + } | ||
182 | } | 186 | } |
183 | } | 187 | } |
184 | 188 | ||
@@ -314,12 +318,13 @@ | @@ -314,12 +318,13 @@ | ||
314 | .senior-sub { | 318 | .senior-sub { |
315 | box-sizing: border-box; | 319 | box-sizing: border-box; |
316 | position: absolute; | 320 | position: absolute; |
317 | - padding: 15px 0; | ||
318 | - left: 0; | ||
319 | - right: 0; | 321 | + padding: 15px 0 15px 91px; |
322 | + left: -91px; | ||
323 | + right: -1px; | ||
320 | top: 39px; | 324 | top: 39px; |
321 | background: #fff; | 325 | background: #fff; |
322 | - border: 1px solid #eaeceb; | 326 | + border: 1px solid #dfdfdf; |
327 | + border-top-color: #eaeceb; | ||
323 | z-index: 2; | 328 | z-index: 2; |
324 | 329 | ||
325 | ul { | 330 | ul { |
1 | .new-sale-page { | 1 | .new-sale-page { |
2 | + | ||
3 | + /*Modify by chenglong.wang at 2016/1/18 | ||
4 | + *sale列表页面轮播图 | ||
5 | + */ | ||
6 | + .sale-list-banner { | ||
7 | + width: 100%; | ||
8 | + position: relative; | ||
9 | + | ||
10 | + ul { | ||
11 | + overflow: hidden; | ||
12 | + width: 100%; | ||
13 | + position: relative; | ||
14 | + z-index: 1; | ||
15 | + | ||
16 | + li { | ||
17 | + width: 100%; | ||
18 | + height: 100%; | ||
19 | + display: block; | ||
20 | + float: left; | ||
21 | + position: absolute; | ||
22 | + top: 0; | ||
23 | + left: 0; | ||
24 | + } | ||
25 | + } | ||
26 | + | ||
27 | + .sale-list-pagation { | ||
28 | + z-index: 2; | ||
29 | + position: absolute; | ||
30 | + left: 0; | ||
31 | + bottom: 50px; | ||
32 | + width: 100%; | ||
33 | + height: 20px; | ||
34 | + text-align: center; | ||
35 | + | ||
36 | + div { | ||
37 | + display: inline-block; | ||
38 | + } | ||
39 | + | ||
40 | + span { | ||
41 | + display: block; | ||
42 | + width: 20px; | ||
43 | + height: 20px; | ||
44 | + background: image_url('product/default-normal.png'); | ||
45 | + float: left; | ||
46 | + margin: 0 10px; | ||
47 | + cursor: pointer; | ||
48 | + | ||
49 | + &.active { | ||
50 | + background: image_url('product/default-active.png'); | ||
51 | + } | ||
52 | + } | ||
53 | + } | ||
54 | + } | ||
55 | + | ||
2 | .header-title { | 56 | .header-title { |
3 | position: relative; | 57 | position: relative; |
4 | width: 100%; | 58 | width: 100%; |
@@ -339,35 +339,34 @@ class HomeModel | @@ -339,35 +339,34 @@ class HomeModel | ||
339 | } | 339 | } |
340 | 340 | ||
341 | $data = IndexData::channelData(); | 341 | $data = IndexData::channelData(); |
342 | - | ||
343 | if (!empty($data['data']['list'])) { | 342 | if (!empty($data['data']['list'])) { |
344 | $build = array(); | 343 | $build = array(); |
345 | foreach ($data['data']['list'] as $value) { | 344 | foreach ($data['data']['list'] as $value) { |
346 | $build = array(); | 345 | $build = array(); |
347 | switch (intval($value['channel_id'])) { | 346 | switch (intval($value['channel_id'])) { |
348 | case 1: | 347 | case 1: |
349 | - $build['href'] = '/boys'; | 348 | + $build['href'] = Helpers::getFilterUrl($value['url']); |
350 | $build['title'] = '男生'; | 349 | $build['title'] = '男生'; |
351 | $build['entitle'] = 'BOYS'; | 350 | $build['entitle'] = 'BOYS'; |
352 | break; | 351 | break; |
353 | case 2: | 352 | case 2: |
354 | - $build['href'] = '/girls'; | 353 | + $build['href'] = Helpers::getFilterUrl($value['url']); |
355 | $build['title'] = '女生'; | 354 | $build['title'] = '女生'; |
356 | $build['entitle'] = 'GIRLS'; | 355 | $build['entitle'] = 'GIRLS'; |
357 | break; | 356 | break; |
358 | case 3: | 357 | case 3: |
359 | - $build['href'] = '/kids'; | 358 | + $build['href'] = Helpers::getFilterUrl($value['url']); |
360 | $build['title'] = '潮童'; | 359 | $build['title'] = '潮童'; |
361 | $build['entitle'] = 'KIDS'; | 360 | $build['entitle'] = 'KIDS'; |
362 | break; | 361 | break; |
363 | case 4: | 362 | case 4: |
364 | - $build['href'] = '/lifestyle'; | 363 | + $build['href'] = Helpers::getFilterUrl($value['url']); |
365 | $build['title'] = '创意生活'; | 364 | $build['title'] = '创意生活'; |
366 | $build['entitle'] = 'LIFESTYLE'; | 365 | $build['entitle'] = 'LIFESTYLE'; |
367 | break; | 366 | break; |
368 | case 5: | 367 | case 5: |
369 | $result['showYohood'] = true; | 368 | $result['showYohood'] = true; |
370 | - $result['yohoodHref'] = 'http://yohood.cn'; | 369 | + $result['yohoodHref'] = Helpers::getFilterUrl($value['url']); |
371 | break; | 370 | break; |
372 | default: | 371 | default: |
373 | continue; | 372 | continue; |
@@ -238,6 +238,7 @@ class DetailModel | @@ -238,6 +238,7 @@ class DetailModel | ||
238 | $colorArr['colorNum'] = isset($colorStorageGroup[ $colorArr['skcId'] ][$sizeName]) ? $colorStorageGroup[ $colorArr['skcId'] ][$sizeName] : 0; | 238 | $colorArr['colorNum'] = isset($colorStorageGroup[ $colorArr['skcId'] ][$sizeName]) ? $colorStorageGroup[ $colorArr['skcId'] ][$sizeName] : 0; |
239 | $colorGroup[$i]['color'][] = $colorArr; | 239 | $colorGroup[$i]['color'][] = $colorArr; |
240 | } | 240 | } |
241 | + $colorGroup[$i]['sizeName'] = $sizeName; | ||
241 | 242 | ||
242 | ++ $i; | 243 | ++ $i; |
243 | } | 244 | } |
@@ -246,6 +247,7 @@ class DetailModel | @@ -246,6 +247,7 @@ class DetailModel | ||
246 | foreach ($colorList as $value) { | 247 | foreach ($colorList as $value) { |
247 | // 各个尺码的颜色,每行显示一个颜色的对应尺码 | 248 | // 各个尺码的颜色,每行显示一个颜色的对应尺码 |
248 | $sizeGroup[$i]['size'] = $sizeList[ $value['skcId'] ]; | 249 | $sizeGroup[$i]['size'] = $sizeList[ $value['skcId'] ]; |
250 | + $sizeGroup[$i]['colorId'] = $value['skcId']; | ||
249 | // 默认颜色 | 251 | // 默认颜色 |
250 | $colorGroup[0]['color'][] = $value; | 252 | $colorGroup[0]['color'][] = $value; |
251 | 253 |
@@ -38,20 +38,14 @@ class BrandsController extends WebAction | @@ -38,20 +38,14 @@ class BrandsController extends WebAction | ||
38 | */ | 38 | */ |
39 | public function brandinfoAction() | 39 | public function brandinfoAction() |
40 | { | 40 | { |
41 | - $result = array(); | ||
42 | - | ||
43 | do { | 41 | do { |
44 | /* 判断是不是AJAX请求 */ | 42 | /* 判断是不是AJAX请求 */ |
45 | if (!$this->isAjax()) { | 43 | if (!$this->isAjax()) { |
46 | break; | 44 | break; |
47 | } | 45 | } |
48 | - $brandId = $this->get('brandId',0); | ||
49 | - $uid=$this->getUid(false); | ||
50 | - $brandId=144; | ||
51 | - BrandsModel::getBrandInfo($brandId, $uid); | ||
52 | - | ||
53 | - | ||
54 | - | 46 | + $brandId = $this->get('brandId', 0); |
47 | + $uid = $this->getUid(false); | ||
48 | + $data = BrandsModel::getBrandInfo($brandId, $uid); | ||
55 | $result = array( | 49 | $result = array( |
56 | 'code' => 200, | 50 | 'code' => 200, |
57 | 'brand' => $data | 51 | 'brand' => $data |
@@ -62,9 +56,10 @@ class BrandsController extends WebAction | @@ -62,9 +56,10 @@ class BrandsController extends WebAction | ||
62 | $this->echoJson($result); | 56 | $this->echoJson($result); |
63 | } | 57 | } |
64 | 58 | ||
65 | - /** | ||
66 | - * 品牌一览 | 59 | + /* |
60 | + * 品牌list | ||
67 | */ | 61 | */ |
62 | + | ||
68 | public function indexAction() | 63 | public function indexAction() |
69 | { | 64 | { |
70 | $headerdata = array( | 65 | $headerdata = array( |
@@ -7,6 +7,7 @@ use Plugin\HelperSearch; | @@ -7,6 +7,7 @@ use Plugin\HelperSearch; | ||
7 | use LibModels\Web\Product\BrandData; | 7 | use LibModels\Web\Product\BrandData; |
8 | use Index\HomeModel; | 8 | use Index\HomeModel; |
9 | use Product\SearchModel; | 9 | use Product\SearchModel; |
10 | +use Plugin\Helpers; | ||
10 | 11 | ||
11 | /** | 12 | /** |
12 | * 品牌首页模板数据模型 | 13 | * 品牌首页模板数据模型 |
@@ -80,7 +81,7 @@ class BrandsModel | @@ -80,7 +81,7 @@ class BrandsModel | ||
80 | $urlList['product'] = HelperSearch::getProductUrl($searchCondition['condition']); | 81 | $urlList['product'] = HelperSearch::getProductUrl($searchCondition['condition']); |
81 | 82 | ||
82 | // 组合搜索分类url | 83 | // 组合搜索分类url |
83 | - $urlList['sort'] = HelperSearch::getClassesUrl($searchCondition['condition']); | 84 | + $urlList['sort'] = HelperSearch::getClassesUrl($searchCondition['sortCondition']); |
84 | 85 | ||
85 | //组合搜索品牌url | 86 | //组合搜索品牌url |
86 | $urlList['brand'] = HelperSearch::getBrandUrl($customOptions); | 87 | $urlList['brand'] = HelperSearch::getBrandUrl($customOptions); |
@@ -108,32 +109,41 @@ class BrandsModel | @@ -108,32 +109,41 @@ class BrandsModel | ||
108 | { | 109 | { |
109 | $switchParams = self::switchBrandParams($channel); | 110 | $switchParams = self::switchBrandParams($channel); |
110 | $brandTop = array(); | 111 | $brandTop = array(); |
111 | - /* | ||
112 | - * $item1 = array( | ||
113 | - 'name' => '所有品牌', | ||
114 | - 'src' => $imgsrc, | ||
115 | - 'url' => '' | ||
116 | - ); | ||
117 | - */ | ||
118 | $brandAds = array(); | 112 | $brandAds = array(); |
119 | $brandList = array(); | 113 | $brandList = array(); |
120 | $res = BrandData::getTopBanner($switchParams['brandCode'], $switchParams['channelType']); | 114 | $res = BrandData::getTopBanner($switchParams['brandCode'], $switchParams['channelType']); |
115 | + //头部10个品牌图块 | ||
116 | + if (isset($res['brandTop'][1]['data']['list']) && $res['brandTop'][1]['data']['list']) { | ||
117 | + foreach ($res['brandTop'][1]['data']['list'] as $tbk => $tbv) { | ||
118 | + $imgUrlTmp = explode("?", $tbv['src']); | ||
119 | + $urlTmp = explode("?", $tbv['url']); | ||
120 | + $topBrandTmp = array( | ||
121 | + 'name' => $tbv['name'], | ||
122 | + 'src' => Helpers::getImageUrl($imgUrlTmp[0], 80, 50, 3), | ||
123 | + 'url' => str_replace('m.', '', $urlTmp[0]), | ||
124 | + ); | ||
125 | + $brandAds[$tbk] = $topBrandTmp; | ||
126 | + } | ||
127 | + } | ||
128 | + //头部品牌图块 | ||
121 | if (isset($res['brandTop'][0]['data']) && $res['brandTop'][0]['data']) { | 129 | if (isset($res['brandTop'][0]['data']) && $res['brandTop'][0]['data']) { |
122 | foreach ($res['brandTop'][0]['data'] as $tk => $tv) { | 130 | foreach ($res['brandTop'][0]['data'] as $tk => $tv) { |
123 | - $imgUrl = explode("?", $tv['src']); | 131 | + $imgUrlTmp = explode("?", $tv['src']); |
132 | + $urlTmp = explode("?", $tv['url']); | ||
124 | $topTmp = array( | 133 | $topTmp = array( |
125 | 'name' => $tv['title'], | 134 | 'name' => $tv['title'], |
126 | - 'src' => $imgUrl[0], | ||
127 | - 'url' => $tv['url'], | ||
128 | - 'items' => array() | 135 | + 'src' => $imgUrlTmp[0], |
136 | + 'url' => $urlTmp[0], | ||
137 | + 'items' => $brandAds | ||
129 | ); | 138 | ); |
130 | $brandTop[$tk] = $topTmp; | 139 | $brandTop[$tk] = $topTmp; |
131 | } | 140 | } |
132 | } | 141 | } |
142 | + //品牌list | ||
133 | if (isset($res['brandList']['brands']) && $res['brandList']['brands']) { | 143 | if (isset($res['brandList']['brands']) && $res['brandList']['brands']) { |
134 | foreach ($res['brandList']['brands'] as $lk => $lv) { | 144 | foreach ($res['brandList']['brands'] as $lk => $lv) { |
145 | + $listTmp = array(); | ||
135 | if (isset($lv) && $lv) { | 146 | if (isset($lv) && $lv) { |
136 | - $listTmp = array(); | ||
137 | foreach ($lv as $ltk => $ltv) { | 147 | foreach ($lv as $ltk => $ltv) { |
138 | $listTmp[$ltk] = array( | 148 | $listTmp[$ltk] = array( |
139 | 'name' => $ltv['brand_name'], | 149 | 'name' => $ltv['brand_name'], |
@@ -158,33 +168,20 @@ class BrandsModel | @@ -158,33 +168,20 @@ class BrandsModel | ||
158 | */ | 168 | */ |
159 | public static function getBrandInfo($brandId, $uid) | 169 | public static function getBrandInfo($brandId, $uid) |
160 | { | 170 | { |
161 | - $imgsrc = 'http://img11.static.yhbimg.com/goodsimg/2015/10/19/10/01b312c3b7a7efebcd671e73495ff3e306.jpg'; | ||
162 | - $data = array( | ||
163 | - 'key' => '1000011', | ||
164 | - 'icon' => $imgsrc, | ||
165 | - 'title' => '优显led触控台灯', | ||
166 | - 'content' => '优显led触控台灯优显led触控台灯优显led触控台灯优显led触控台灯', | ||
167 | - 'subtitle' => 'AAAAAA', | ||
168 | - 'imgs' => array( | ||
169 | - array( | ||
170 | - 'src' => $imgsrc | ||
171 | - ), | ||
172 | - array( | ||
173 | - 'src' => $imgsrc | ||
174 | - ), | ||
175 | - array( | ||
176 | - 'src' => $imgsrc | ||
177 | - ) | ||
178 | - ) | ||
179 | - ); | 171 | + $data = array(); |
180 | $res = BrandData::getBrandIntro($brandId, $uid); | 172 | $res = BrandData::getBrandIntro($brandId, $uid); |
181 | -//if(isset($res['data']) && $res['data']){ | ||
182 | -// $data['key']=$brandId; | ||
183 | -// $data['icon']= | ||
184 | -//} | ||
185 | - var_dump($res); | ||
186 | - die(); | ||
187 | - | 173 | + if (isset($res['data']) && $res['data']) { |
174 | + $icoUrlTmp = explode("?", $res['data']['brand_ico']) ; | ||
175 | + $data = array( | ||
176 | + 'key' => $res['data']['brand_id'], | ||
177 | + 'icon' => $icoUrlTmp[0], | ||
178 | + 'title' => $res['data']['brand_name'], | ||
179 | + 'content' =>$res['data']['brand_intro'], | ||
180 | + 'subtitle' => 'FEATURED ITEMS', | ||
181 | + 'imgs' => array(), | ||
182 | + ); | ||
183 | + } | ||
184 | + return $data; | ||
188 | } | 185 | } |
189 | 186 | ||
190 | /* | 187 | /* |
@@ -18,12 +18,11 @@ class IndexModel | @@ -18,12 +18,11 @@ class IndexModel | ||
18 | { | 18 | { |
19 | $urlList = array(); | 19 | $urlList = array(); |
20 | $searchCondition = SearchModel::searchCondition($customCondition, $customOptions); | 20 | $searchCondition = SearchModel::searchCondition($customCondition, $customOptions); |
21 | - | ||
22 | // 组合搜索商品url | 21 | // 组合搜索商品url |
23 | $urlList['product'] = HelperSearch::getProductUrl($searchCondition['condition']); | 22 | $urlList['product'] = HelperSearch::getProductUrl($searchCondition['condition']); |
24 | 23 | ||
25 | // 组合搜索分类url | 24 | // 组合搜索分类url |
26 | - $urlList['sort'] = HelperSearch::getClassesUrl($searchCondition['condition']); | 25 | + $urlList['sort'] = HelperSearch::getClassesUrl($searchCondition['sortCondition']); |
27 | 26 | ||
28 | //用户浏览记录 | 27 | //用户浏览记录 |
29 | //$urlList['reviewUrl'] = HelperSearch::getReviewUrl($searchCondition['condition']); | 28 | //$urlList['reviewUrl'] = HelperSearch::getReviewUrl($searchCondition['condition']); |
@@ -20,7 +20,7 @@ class NewModel | @@ -20,7 +20,7 @@ class NewModel | ||
20 | // 组合搜索商品url | 20 | // 组合搜索商品url |
21 | $urlList['product'] = HelperSearch::getProductUrl($searchCondition['condition']); | 21 | $urlList['product'] = HelperSearch::getProductUrl($searchCondition['condition']); |
22 | // 组合搜索分类url | 22 | // 组合搜索分类url |
23 | - $urlList['sort'] = HelperSearch::getClassesUrl($searchCondition['condition']); | 23 | + $urlList['sort'] = HelperSearch::getClassesUrl($searchCondition['sortCondition']); |
24 | // 组合搜索最新上架url | 24 | // 组合搜索最新上架url |
25 | $urlList['recent'] = HelperSearch::getRecentShelveUrl($searchCondition['condition']); | 25 | $urlList['recent'] = HelperSearch::getRecentShelveUrl($searchCondition['condition']); |
26 | //用户浏览记录 | 26 | //用户浏览记录 |
@@ -23,7 +23,7 @@ class SaleModel | @@ -23,7 +23,7 @@ class SaleModel | ||
23 | $urlList['product'] = HelperSearch::getProductUrl($searchCondition['condition']); | 23 | $urlList['product'] = HelperSearch::getProductUrl($searchCondition['condition']); |
24 | 24 | ||
25 | // 组合搜索分类url | 25 | // 组合搜索分类url |
26 | - $urlList['sort'] = HelperSearch::getClassesUrl($searchCondition['condition']); | 26 | + $urlList['sort'] = HelperSearch::getClassesUrl($searchCondition['sortCondition']); |
27 | 27 | ||
28 | //组合用户浏览记录url | 28 | //组合用户浏览记录url |
29 | //$urlList['reviewUrl'] = HelperSearch::getReviewUrl($searchCondition['condition']); | 29 | //$urlList['reviewUrl'] = HelperSearch::getReviewUrl($searchCondition['condition']); |
@@ -112,6 +112,7 @@ class LoginController extends WebAction | @@ -112,6 +112,7 @@ class LoginController extends WebAction | ||
112 | /* 设置登录有效时间30分钟, 防机器刷 */ | 112 | /* 设置登录有效时间30分钟, 防机器刷 */ |
113 | $expire = $this->getSession('_LOGIN_EXPIRE'); | 113 | $expire = $this->getSession('_LOGIN_EXPIRE'); |
114 | if (empty($expire) || $expire < time()) { | 114 | if (empty($expire) || $expire < time()) { |
115 | + $data = array('code' => 400, 'message' => '页面停留时间过长,请刷新页面', 'data' => ''); | ||
115 | break; | 116 | break; |
116 | } | 117 | } |
117 | 118 | ||
@@ -135,13 +136,13 @@ class LoginController extends WebAction | @@ -135,13 +136,13 @@ class LoginController extends WebAction | ||
135 | } | 136 | } |
136 | 137 | ||
137 | $refer = $this->getCookie('refer'); | 138 | $refer = $this->getCookie('refer'); |
138 | - if (empty($refer)) { | ||
139 | - $refer = SITE_MAIN . '/?go=1'; | 139 | + if (empty($refer) || strstr($refer, 'signin.html') || strstr($refer, 'passport/login/index')) { |
140 | + $refer = SITE_MAIN; | ||
140 | } | 141 | } |
141 | else { | 142 | else { |
142 | $refer = rawurldecode($refer); | 143 | $refer = rawurldecode($refer); |
143 | } | 144 | } |
144 | - $data['data']['session'] = Helpers::syncUserSession($data['data']['uid']); | 145 | + $data['data']['session'] = Helpers::syncUserSession($data['data']['uid'],$refer); |
145 | $data['data']['href'] = $refer; | 146 | $data['data']['href'] = $refer; |
146 | 147 | ||
147 | $token = Helpers::makeToken($data['data']['uid']); | 148 | $token = Helpers::makeToken($data['data']['uid']); |
@@ -166,7 +166,32 @@ class Sale1Controller extends WebAction | @@ -166,7 +166,32 @@ class Sale1Controller extends WebAction | ||
166 | 'saleList' => array( | 166 | 'saleList' => array( |
167 | 'saleBanner' => array( | 167 | 'saleBanner' => array( |
168 | 'bannerHeight' => 350, | 168 | 'bannerHeight' => 350, |
169 | - 'img' => 'http://img12.static.yhbimg.com/couponImg/2015/12/10/08/02d4c26f19ca2e44359d69d5cff86167fb.jpg' | 169 | + 'list' => array( |
170 | + array( | ||
171 | + 'bannerHeight' => 350, | ||
172 | + 'img' => 'http://img12.static.yhbimg.com/couponImg/2015/12/10/08/02d4c26f19ca2e44359d69d5cff86167fb.jpg' | ||
173 | + ), | ||
174 | + array( | ||
175 | + 'bannerHeight' => 350, | ||
176 | + 'img' => 'http://img12.static.yhbimg.com/yhb-img01/2016/01/06/05/02062366574a01418596caa38a773f6beb.jpg?imageView/1/w/1150/h/450' | ||
177 | + ), | ||
178 | + array( | ||
179 | + 'bannerHeight' => 350, | ||
180 | + 'img' => 'http://img11.static.yhbimg.com/yhb-img01/2016/01/06/05/013341a0632177cc3425c3c6082845be57.jpg?imageView/1/w/1150/h/450' | ||
181 | + ), | ||
182 | + array( | ||
183 | + 'bannerHeight' => 350, | ||
184 | + 'img' => 'http://img12.static.yhbimg.com/couponImg/2015/12/10/08/02d4c26f19ca2e44359d69d5cff86167fb.jpg' | ||
185 | + ), | ||
186 | + array( | ||
187 | + 'bannerHeight' => 350, | ||
188 | + 'img' => 'http://img12.static.yhbimg.com/yhb-img01/2016/01/06/05/02062366574a01418596caa38a773f6beb.jpg?imageView/1/w/1150/h/450' | ||
189 | + ), | ||
190 | + array( | ||
191 | + 'bannerHeight' => 350, | ||
192 | + 'img' => 'http://img11.static.yhbimg.com/yhb-img01/2016/01/06/05/013341a0632177cc3425c3c6082845be57.jpg?imageView/1/w/1150/h/450' | ||
193 | + ) | ||
194 | + ) | ||
170 | ), | 195 | ), |
171 | 'saleTitle' => array( | 196 | 'saleTitle' => array( |
172 | 'name' => '全部商品', | 197 | 'name' => '全部商品', |
-
Please register or login to post a comment