Showing
4 changed files
with
30 additions
and
12 deletions
@@ -17,13 +17,13 @@ module.exports = { | @@ -17,13 +17,13 @@ module.exports = { | ||
17 | assetUrl: '//127.0.0.1:5001', | 17 | assetUrl: '//127.0.0.1:5001', |
18 | testCode: 'yoho4946abcdef#$%&!@', | 18 | testCode: 'yoho4946abcdef#$%&!@', |
19 | domains: { | 19 | domains: { |
20 | - api: 'http://api-test2.yohops.com:9999/', | ||
21 | - service: 'http://service-test2.yohops.com:9999/', | 20 | + api: 'http://api-test3.yohops.com:9999/', |
21 | + service: 'http://service-test3.yohops.com:9999/', | ||
22 | liveApi: 'http://testapi.live.yohops.com:9999/', | 22 | liveApi: 'http://testapi.live.yohops.com:9999/', |
23 | - singleApi: 'http://api-test2.yohops.com:9999/' | ||
24 | - // imSocket: 'ws://im.yohobuy.com:10240', | ||
25 | - // imCs: 'http://im.yohobuy.com/api', | ||
26 | - // imServer: 'http://im.yohobuy.com/server' | 23 | + singleApi: 'http://api-test3.yohops.com:9999/', |
24 | + imSocket: 'ws://im.yohobuy.com:10240', | ||
25 | + imCs: 'http://im.yohobuy.com/api', | ||
26 | + imServer: 'http://im.yohobuy.com/server' | ||
27 | 27 | ||
28 | // api: 'http://api.yoho.cn/', | 28 | // api: 'http://api.yoho.cn/', |
29 | // service: 'http://service.yoho.cn/', | 29 | // service: 'http://service.yoho.cn/', |
1 | {{# cartInfo}} | 1 | {{# cartInfo}} |
2 | <div class="chose-panel"> | 2 | <div class="chose-panel"> |
3 | <div class="main"> | 3 | <div class="main"> |
4 | - <div class="close">X</div> | 4 | + <div class="close iconfont"></div> |
5 | <div class="infos {{#if @root.tickets}} tickets-info {{/if}}"> | 5 | <div class="infos {{#if @root.tickets}} tickets-info {{/if}}"> |
6 | <div class="basic-info" > | 6 | <div class="basic-info" > |
7 | {{#each thumbs}} | 7 | {{#each thumbs}} |
@@ -64,7 +64,7 @@ var discountNum = $('#mnum').val() - 0, | @@ -64,7 +64,7 @@ var discountNum = $('#mnum').val() - 0, | ||
64 | 64 | ||
65 | var C_ID; | 65 | var C_ID; |
66 | 66 | ||
67 | -var sizeInfo = $('.size-info'); | 67 | +var sizeInfo; |
68 | 68 | ||
69 | require('../common'); | 69 | require('../common'); |
70 | 70 | ||
@@ -97,6 +97,7 @@ function init() { | @@ -97,6 +97,7 @@ function init() { | ||
97 | curColorIndex = 0; | 97 | curColorIndex = 0; |
98 | curSizeIndex = 0; | 98 | curSizeIndex = 0; |
99 | isEdit = 0; | 99 | isEdit = 0; |
100 | + sizeInfo = $('.size-info'); | ||
100 | } | 101 | } |
101 | 102 | ||
102 | /* | 103 | /* |
@@ -372,7 +373,9 @@ function chosedLength() { | @@ -372,7 +373,9 @@ function chosedLength() { | ||
372 | var $chosedL = $('.block-list li.chosed'), | 373 | var $chosedL = $('.block-list li.chosed'), |
373 | infoHtml, | 374 | infoHtml, |
374 | choosedInfo = $('.choosed-info'), | 375 | choosedInfo = $('.choosed-info'), |
375 | - notChoose = $('.not-choose'); | 376 | + notChoose = $('.not-choose'), |
377 | + chosedStr = $chosedL.eq(0).html(), | ||
378 | + strlen = 0; | ||
376 | 379 | ||
377 | choosedInfo.removeClass('hide'); | 380 | choosedInfo.removeClass('hide'); |
378 | 381 | ||
@@ -380,13 +383,26 @@ function chosedLength() { | @@ -380,13 +383,26 @@ function chosedLength() { | ||
380 | notChoose.addClass('hide'); | 383 | notChoose.addClass('hide'); |
381 | } | 384 | } |
382 | 385 | ||
386 | + for (var i = 0; i < chosedStr.length; i++) { | ||
387 | + if (chosedStr.charCodeAt(i) > 255) { | ||
388 | + strlen += 2; | ||
389 | + } else { | ||
390 | + strlen ++; | ||
391 | + } | ||
392 | + | ||
393 | + if (strlen >= 18) { | ||
394 | + chosedStr = chosedStr.substring(0, i) + '...'; | ||
395 | + break; | ||
396 | + } | ||
397 | + } | ||
398 | + | ||
383 | if ($chosedL.length === 2) { | 399 | if ($chosedL.length === 2) { |
384 | $chosedL.each(function(val) { | 400 | $chosedL.each(function(val) { |
385 | 401 | ||
386 | - infoHtml = '已选:' + $chosedL.eq(0).html() + '、' + $chosedL.eq(1).html(); | 402 | + infoHtml = '已选:' + chosedStr + '、' + $chosedL.eq(1).html(); |
387 | }); | 403 | }); |
388 | } else if ($chosedL.length === 1) { | 404 | } else if ($chosedL.length === 1) { |
389 | - infoHtml = '已选:' + $chosedL.eq(0).html(); | 405 | + infoHtml = '已选:' + chosedStr; |
390 | } else { | 406 | } else { |
391 | choosedInfo.addClass('hide'); | 407 | choosedInfo.addClass('hide'); |
392 | notChoose.removeClass('hide'); | 408 | notChoose.removeClass('hide'); |
@@ -23,8 +23,9 @@ | @@ -23,8 +23,9 @@ | ||
23 | font-size: 80%; | 23 | font-size: 80%; |
24 | width: 30px; | 24 | width: 30px; |
25 | height: 30px; | 25 | height: 30px; |
26 | - margin-right: 6px; | 26 | + margin: 16px 16px 0 0; |
27 | text-align: right; | 27 | text-align: right; |
28 | + color: #b1b1b1; | ||
28 | } | 29 | } |
29 | 30 | ||
30 | .infos { | 31 | .infos { |
@@ -45,6 +46,7 @@ | @@ -45,6 +46,7 @@ | ||
45 | 46 | ||
46 | .thumb { | 47 | .thumb { |
47 | width: 164px; | 48 | width: 164px; |
49 | + min-height: 220px; | ||
48 | position: absolute; | 50 | position: absolute; |
49 | top: -60px; | 51 | top: -60px; |
50 | border: 1px solid #e6e6e6; | 52 | border: 1px solid #e6e6e6; |
-
Please register or login to post a comment