Authored by 梁志锋

Merge branch 'develop' of http://git.dev.yoho.cn/web/yohobuy into develop

@@ -309,13 +309,7 @@ @@ -309,13 +309,7 @@
309 { 309 {
310 infos: 310 infos:
311 [ 311 [
312 - {  
313 - show: true,  
314 - info: [  
315 - {...}, //标签  
316 - ...  
317 - ]  
318 - }, 312 + {...}, //标签
319 ... 313 ...
320 ] 314 ]
321 } 315 }
@@ -945,14 +939,27 @@ @@ -945,14 +939,27 @@
945 ### 我的订单 939 ### 我的订单
946 { 940 {
947 order: { 941 order: {
948 - orders: [ 942 + navs: [
  943 + {
  944 + name: '',
  945 + active: true,
  946 + typeId: 1
  947 + },
949 ... 948 ...
950 - ],  
951 - //没有订单的情况不传orders  
952 - walkWayUrl: '' //随便逛逛url 949 + ]
953 } 950 }
954 } 951 }
955 952
  953 + //订单列表
  954 + {
  955 + orders: [
  956 + {
  957 + ...//订单
  958 + }
  959 + ]
  960 + //当无订单时,不传order,返回walkwayUrl
  961 + walkWayUrl: ''
  962 + }
956 963
957 //订单 964 //订单
958 { 965 {
@@ -1030,4 +1037,13 @@ @@ -1030,4 +1037,13 @@
1030 yohoCoin: { 1037 yohoCoin: {
1031 coinNum: 10 1038 coinNum: 10
1032 } 1039 }
  1040 + }
  1041 +
  1042 +### 我的逛
  1043 +
  1044 + {
  1045 + myGuang: [
  1046 + {...} //逛资讯
  1047 + ..
  1048 + ]
1033 } 1049 }
  1 +commit 7229af7cecf40861c6fb3987c1f38ac3da2faef9
  2 +Author: Lynnic <gunix@foxmail.com>
  3 +Date: Fri Nov 13 17:45:31 2015 +0800
  4 +
  5 + update
  6 +
  7 +commit 2c21a46be447a1bc1982d8ad3cad7f8c00a63a0f
  8 +Author: xuqi <xuqi9010@gmail.com>
  9 +Date: Fri Nov 13 17:27:02 2015 +0800
  10 +
  11 + rm temp file
  12 +
  13 +commit 34763241edf84698b24ecb2aa2f2bfa1e37afc32
  14 +Author: liangzhifeng <zhifeng.liang@yoho.cn>
  15 +Date: Fri Nov 13 16:58:28 2015 +0800
  16 +
  17 + update yas version
  18 +
  19 +commit 3b4a6cd6177ec9cef8ab953b165da1d222974382
  20 +Merge: c1b68bb 7ccb30d
  21 +Author: liangzhifeng <zhifeng.liang@yoho.cn>
  22 +Date: Fri Nov 13 16:39:59 2015 +0800
  23 +
  24 + Merge branch 'develop' of git.dev.yoho.cn:web/yohobuy into develop
  25 +
  26 +commit c1b68bb739bb2535d9d8a205aa198ccc1844752d
  27 +Author: liangzhifeng <zhifeng.liang@yoho.cn>
  28 +Date: Fri Nov 13 16:39:26 2015 +0800
  29 +
  30 + update yas version
  31 +
  32 +commit 7ccb30d2ca3d45bf82638f63c8ae0e0db27b3a5f
  33 +Author: Lynnic <gunix@foxmail.com>
  34 +Date: Fri Nov 13 15:37:18 2015 +0800
  35 +
  36 + changed the name of conflicted function
  37 +
  38 +commit e5569a46931588f42607e84bec1db64a8cf46bcd
  39 +Merge: a7552b8 b4b964e
  40 +Author: Lynnic <gunix@foxmail.com>
  41 +Date: Fri Nov 13 14:50:09 2015 +0800
  42 +
  43 + Merge branch 'develop' of http://git.dev.yoho.cn/web/yohobuy into develop
  44 +
  45 +commit b4b964e589b88c0821e1138e46d56dca3f139bcd
  46 +Merge: 6f68082 7a6895e
  47 +Author: ccbikai <ccbikai@qq.com>
  48 +Date: Fri Nov 13 14:35:33 2015 +0800
  49 +
  50 + Merge branch 'develop' of http://git.dev.yoho.cn/web/yohobuy into develop
  51 +
  52 +commit 6f6808272a6a6e40e425bc3df69eff26512e5c80
  53 +Author: ccbikai <ccbikai@qq.com>
  54 +Date: Fri Nov 13 14:35:28 2015 +0800
  55 +
  56 + 修改地址页面样式
  57 +
  58 +commit 7a6895ebfa302d46b791f78196614b9a6d9404ce
  59 +Merge: 8413e20 0ff1e35
  60 +Author: uedxwg <xieweiguang11@163.com>
  61 +Date: Fri Nov 13 14:23:11 2015 +0800
  62 +
  63 + Merge branch 'develop' of http://git.dev.yoho.cn/web/yohobuy into develop
  64 +
  65 +commit 8413e2059464cec3c386bbcb25cd5f7f9bc3e2da
  66 +Author: uedxwg <xieweiguang11@163.com>
  67 +Date: Fri Nov 13 14:22:31 2015 +0800
  68 +
  69 + 'hotrank'
  70 +
  71 +commit a7552b8af3de3fba625736b885aac3d6aeb57b0a
  72 +Author: lynnic <gunix@foxmail.com>
  73 +Date: Fri Nov 13 13:40:22 2015 +0800
  74 +
  75 + update
  76 +
  77 +commit 9ce2bf2913bc9909a5fac0fa4a30777ba4db23c3
  78 +Author: ccbikai <ccbikai@qq.com>
  79 +Date: Fri Nov 13 13:35:07 2015 +0800
  80 +
  81 +
  82 +
  83 +commit 0ff1e35337c656c288243a40602bd0cb7a85fdb4
  84 +Merge: 88ef01d cdba827
  85 +Author: ccbikai <ccbikai@qq.com>
  86 +Date: Fri Nov 13 13:30:37 2015 +0800
  87 +
  88 + merge code
  89 +
  90 +commit 88ef01d3931dc8b61657019bde2e02186c0222e3
  91 +Author: ccbikai <ccbikai@qq.com>
  92 +Date: Fri Nov 13 13:29:45 2015 +0800
  93 +
  94 + 地址模板修改
  95 +
  96 +commit 072785ab101cff6bcd3f5548165cad6d18c79aa1
  97 +Merge: 5e3e194 cdba827
  98 +Author: liangzhifeng <zhifeng.liang@yoho.cn>
  99 +Date: Fri Nov 13 13:25:15 2015 +0800
  100 +
  101 + Merge branch 'develop' of git.dev.yoho.cn:web/yohobuy into develop
  102 +
  103 +commit cdba82787e574d2274025227bdcfd97553fbe30e
  104 +Merge: 91cebbc 35dbe8b
  105 +Author: hf <fei.hong@yoho.cn>
  106 +Date: Fri Nov 13 13:24:46 2015 +0800
  107 +
  108 + merge master css js code
  109 +
  110 +commit 91cebbc682532eab919ea903c7668f3ff9fb01a1
  111 +Author: hf <fei.hong@yoho.cn>
  112 +Date: Fri Nov 13 13:24:01 2015 +0800
  113 +
  114 + merge master css js code
  115 +
  116 +commit 5e3e194ef858a371f65b0a6e2965f79ec65fdb49
  117 +Merge: 9cb6944 35dbe8b
  118 +Author: liangzhifeng <zhifeng.liang@yoho.cn>
  119 +Date: Fri Nov 13 13:23:02 2015 +0800
  120 +
  121 + Merge branch 'develop' of git.dev.yoho.cn:web/yohobuy into develop
  122 +
  123 +commit 35dbe8bc57c1accce337e199df6d323d4e7b7ead
  124 +Author: ccbikai <ccbikai@qq.com>
  125 +Date: Fri Nov 13 13:22:34 2015 +0800
  126 +
  127 + 地址管理增加数据
  128 +
  129 +commit 9cb6944ea59db8f2958f10de518db079aa0bc3ad
  130 +Merge: 09500b4 bfaf6f7
  131 +Author: liangzhifeng <zhifeng.liang@yoho.cn>
  132 +Date: Fri Nov 13 13:22:11 2015 +0800
  133 +
  134 + Merge branch 'develop' of git.dev.yoho.cn:web/yohobuy into develop
  135 +
  136 +commit f735917c59165291cfb3fcb064e06bb424e64b40
  137 +Author: lynnic <gunix@foxmail.com>
  138 +Date: Fri Nov 13 13:19:56 2015 +0800
  139 +
  140 + product detail
  141 +
  142 +commit bfaf6f7da9e7b3f15ca3e2223af4b04e890f7181
  143 +Merge: ddb8634 da2dd89
  144 +Author: ccbikai <ccbikai@qq.com>
  145 +Date: Fri Nov 13 11:47:23 2015 +0800
  146 +
  147 + Merge branch 'develop' of http://git.dev.yoho.cn/web/yohobuy into develop
  148 +
  149 +commit ddb8634a6229dafd38b4380cdb4861d768cb207c
  150 +Author: ccbikai <ccbikai@qq.com>
  151 +Date: Fri Nov 13 11:47:18 2015 +0800
  152 +
  153 + 地址管理页面样式
  154 +
  155 +commit 09500b4de29d35d7edb9526feaef5cfda53bc48b
  156 +Merge: b3d45dc da2dd89
  157 +Author: liangzhifeng <zhifeng.liang@yoho.cn>
  158 +Date: Fri Nov 13 11:18:17 2015 +0800
  159 +
  160 + Merge branch 'develop' of git.dev.yoho.cn:web/yohobuy into develop
  161 +
  162 +commit b3d45dcfe30770f888ccde298a1aa65c7b06c829
  163 +Author: liangzhifeng <zhifeng.liang@yoho.cn>
  164 +Date: Fri Nov 13 11:17:43 2015 +0800
  165 +
  166 + update the version of yas
  167 +
  168 +commit da2dd89e32be5bb319141af09fe5b8f1404e192d
  169 +Author: hf <fei.hong@yoho.cn>
  170 +Date: Fri Nov 13 11:15:06 2015 +0800
  171 +
  172 + merge master css js code
  173 +
  174 +commit e677bad09bfc0959d667a29a035375cf9feba5d2
  175 +Merge: cef0926 f1ec957
  176 +Author: hf <fei.hong@yoho.cn>
  177 +Date: Fri Nov 13 10:52:10 2015 +0800
  178 +
  179 + merge master css js code
  180 +
  181 +commit cef09262f23a1ba1fadef9c56fb2088cfd75cde5
  182 +Merge: d927c9f 1483b13
  183 +Author: hf <fei.hong@yoho.cn>
  184 +Date: Fri Nov 13 10:51:02 2015 +0800
  185 +
  186 + do merge master code
  187 +
  188 +commit 1483b137ec3273153d3dfa8f47aadd6b4b88fb9c
  189 +Author: ccbikai <ccbikai@qq.com>
  190 +Date: Fri Nov 13 10:18:43 2015 +0800
  191 +
  192 + 个人中心首页完善
  193 +
  194 +commit 2b3507b2e6319697d96723e7ca3d72fcdce8bedc
  195 +Merge: a772911 67b011f
  196 +Author: ccbikai <ccbikai@qq.com>
  197 +Date: Fri Nov 13 09:39:53 2015 +0800
  198 +
  199 + Merge branch 'develop' of http://git.dev.yoho.cn/web/yohobuy into develop
  200 +
  201 +commit 67b011f1647426d9d4e59daf67cd75e2e29d1acb
  202 +Merge: 9c12951 a7a3613
  203 +Author: uedxwg <xieweiguang11@163.com>
  204 +Date: Thu Nov 12 18:40:33 2015 +0800
  205 +
  206 + Merge branch 'develop' of http://git.dev.yoho.cn/web/yohobuy into develop
  207 +
  208 +commit 9c12951e3d4aaa06cc99b8d76da2d8aa1b3bfcc1
  209 +Author: uedxwg <xieweiguang11@163.com>
  210 +Date: Thu Nov 12 18:39:49 2015 +0800
  211 +
  212 + 'hotrank'
  213 +
  214 +commit a7a36134fbca6e9d5f4cb60e40fb9a9a83cb2c1a
  215 +Merge: d336ffb 47f54e6
  216 +Author: Rock Zhang <iamgtskk@gmail.com>
  217 +Date: Thu Nov 12 18:30:47 2015 +0800
  218 +
  219 + Merge branch 'develop' of git.dev.yoho.cn:web/yohobuy into develop
  220 +
  221 + Conflicts:
  222 + framework
  223 +
  224 +commit d336ffb79bb7ead39b230b751f6a7a296cec4b78
  225 +Author: Rock Zhang <iamgtskk@gmail.com>
  226 +Date: Thu Nov 12 18:30:23 2015 +0800
  227 +
  228 + 完成个人中心部分功能
  229 +
  230 +commit f1ec957452269f97436356c5e718460847d32b52
  231 +Author: hf <fei.hong@yoho.cn>
  232 +Date: Thu Nov 12 18:18:41 2015 +0800
  233 +
  234 + modify to search goods list style
  235 +
  236 +commit 47f54e6c63dbfdf87d125c17c7538cfd73c9fab9
  237 +Merge: 1ba211d a72e1a2
  238 +Author: lore-w <metro-cpu@hotmail.com>
  239 +Date: Thu Nov 12 18:16:56 2015 +0800
  240 +
  241 + Merge branch 'develop' of git.dev.yoho.cn:web/yohobuy into develop
  242 +
  243 + Conflicts:
  244 + static/js/me/entry.js
  245 + static/sass/me/_index.scss
  246 + template/m.yohobuy.com/partials/layout/use.phtml
  247 +
  248 +commit afe58b17129e155698bf1114ef95ea25e867f43b
  249 +Author: hf <fei.hong@yoho.cn>
  250 +Date: Thu Nov 12 18:12:58 2015 +0800
  251 +
  252 + modify to search goods list style
  253 +
  254 +commit 32827f6aa9b9c3fe39a213e3c4001399868a10f0
  255 +Merge: 76c5106 80adb41
  256 +Author: hf <fei.hong@yoho.cn>
  257 +Date: Thu Nov 12 18:12:27 2015 +0800
  258 +
  259 + Merge remote-tracking branch 'origin/hotfix'
  260 +
  261 +commit 1ba211d6670de1f88538065b9276bdd63be55aef
  262 +Author: lore-w <metro-cpu@hotmail.com>
  263 +Date: Thu Nov 12 18:11:25 2015 +0800
  264 +
  265 + 收藏、意见反馈
  266 +
  267 +commit 80adb4135a73c332ce435693a83fd5610c20721e
  268 +Author: ccbikai <ccbikai@qq.com>
  269 +Date: Thu Nov 12 18:09:40 2015 +0800
  270 +
  271 + 取消搜索不 focus
  272 +
  273 +commit 76c51067fd3afdb2e04ece7f3cf21c7a3d98fb8d
  274 +Author: hf <fei.hong@yoho.cn>
  275 +Date: Thu Nov 12 18:01:57 2015 +0800
  276 +
  277 + modify to search goods list style
  278 +
  279 +commit ebf90d5f499facf9b0b38d3afe3a421273e319f7
  280 +Author: hf <fei.hong@yoho.cn>
  281 +Date: Thu Nov 12 18:01:37 2015 +0800
  282 +
  283 + modify to search goods list style
  284 +
  285 +commit 74c6939a6c0af5dea824447eedd57b40d5d36e8e
  286 +Merge: d874739 4be2273
  287 +Author: hf <fei.hong@yoho.cn>
  288 +Date: Thu Nov 12 18:
framework @ 75bbc3b0
1 -Subproject commit 119c247f5cf929aa1e059e40609bb16dd6b58f05 1 +Subproject commit 75bbc3b075de19f239532f60c5995d06c5f814e2
@@ -70,7 +70,7 @@ class NewSaleProcess @@ -70,7 +70,7 @@ class NewSaleProcess
70 $tabItem = array(); 70 $tabItem = array();
71 $tabItem['title'] = $one; 71 $tabItem['title'] = $one;
72 $tabItem['dataId'] = $key; 72 $tabItem['dataId'] = $key;
73 - if ($key === 1) { 73 + if ($key === 0) {
74 $tabItem['focus'] = true; 74 $tabItem['focus'] = true;
75 } 75 }
76 $result['tabs'][] = $tabItem; 76 $result['tabs'][] = $tabItem;
@@ -11,12 +11,79 @@ var $ = require('jquery'), @@ -11,12 +11,79 @@ var $ = require('jquery'),
11 var $navLi = $('#order-nav > li'), 11 var $navLi = $('#order-nav > li'),
12 $orderContainer = $('#order-container'); 12 $orderContainer = $('#order-container');
13 13
14 -var $curContainer = $orderContainer.children('.orders').first();//保存当前显示的order-container 14 +var $curContainer = $orderContainer.children('.orders:not(.hide)');//保存当前显示的order-container
  15 +
  16 +var winH = $(window).height();
  17 +
  18 +var activeType = $navLi.filter('.active').data('type'); //当前active的项的index
  19 +
  20 +var orderPage = {};
  21 +
  22 +var inAjax = false;
  23 +
  24 +var loading = require('../plugin/loading');
15 25
16 var navHammer, orderHammer; 26 var navHammer, orderHammer;
17 27
  28 +//加载订单
  29 +function getOrders() {
  30 + var opt = {
  31 + type: activeType,
  32 + page: orderPage[activeType] ? (orderPage[activeType] + 1) : 1
  33 + };
  34 +
  35 + if (inAjax) {
  36 + return;
  37 + }
  38 +
  39 + inAjax = true;
  40 + loading.showLoadingMask();
  41 +
  42 + $.ajax({
  43 + type: 'GET',
  44 + url: '/home/getOrders',
  45 + data: opt,
  46 + success: function(data) {
  47 + var num;
  48 +
  49 + if (data.code === 200) {
  50 + orderPage[opt.type] = opt.page;
  51 +
  52 + if (opt.page === 1) {
  53 + $curContainer.html(data.data);
  54 + lazyLoad($curContainer.find('.lazy'));
  55 + } else {
  56 + num = $curContainer.children('.order').length;
  57 + $curContainer.append(data.data);
  58 +
  59 + //lazyload
  60 + lazyLoad($curContainer.children('.order:gt(' + (num - 1) + ') .lazy'));
  61 + }
  62 + }
  63 +
  64 + inAjax = false;
  65 + loading.hideLoadingMask();
  66 + }
  67 + });
  68 +}
  69 +
18 lazyLoad(); 70 lazyLoad();
19 71
  72 +//初始化导航
  73 +(function() {
  74 + var liCount = $navLi.length;
  75 +
  76 + //默认4个导航项
  77 + if (liCount === 4) {
  78 + return;
  79 + }
  80 +
  81 + $navLi.width(100 / liCount + '%');
  82 +}());
  83 +
  84 +loading.init();
  85 +
  86 +//导航切换
20 navHammer = new Hammer(document.getElementById('order-nav')); 87 navHammer = new Hammer(document.getElementById('order-nav'));
21 navHammer.on('tap', function(e) { 88 navHammer.on('tap', function(e) {
22 var $cur = $(e.target).closest('li'), 89 var $cur = $(e.target).closest('li'),
@@ -33,12 +100,22 @@ navHammer.on('tap', function(e) { @@ -33,12 +100,22 @@ navHammer.on('tap', function(e) {
33 100
34 $curContainer.addClass('hide'); 101 $curContainer.addClass('hide');
35 $curContainer = $orderContainer.children(':eq(' + index + ')').removeClass('hide'); 102 $curContainer = $orderContainer.children(':eq(' + index + ')').removeClass('hide');
  103 +
  104 + activeType = $cur.data('type');
  105 +
  106 + if (orderPage[activeType]) {
  107 + return;
  108 + } else {
  109 + getOrders();
  110 + }
36 }); 111 });
37 112
  113 +//点击订单区域跳转订单详情页
38 orderHammer = new Hammer(document.getElementById('order-container')); 114 orderHammer = new Hammer(document.getElementById('order-container'));
39 orderHammer.on('tap', function(e) { 115 orderHammer.on('tap', function(e) {
40 var $cur = $(e.target), 116 var $cur = $(e.target),
41 $order, 117 $order,
  118 + id,
42 url; 119 url;
43 120
44 if ($cur.closest('.locHref').length > 0) { 121 if ($cur.closest('.locHref').length > 0) {
@@ -46,7 +123,56 @@ orderHammer.on('tap', function(e) { @@ -46,7 +123,56 @@ orderHammer.on('tap', function(e) {
46 } 123 }
47 124
48 $order = $cur.closest('.order'); 125 $order = $cur.closest('.order');
49 - url = $order.data('href'); 126 + id = $order.data('id');
  127 +
  128 + if ($cur.closest('.del').length > 0) {
  129 +
  130 + //Order delete
  131 + $.ajax({
  132 + type: 'GET',
  133 + url: '/home/delOrder',
  134 + data: {
  135 + id: id
  136 + },
  137 + success: function(data) {
  138 + if (data.code === 200) {
  139 +
  140 + //删除订单页面刷新
  141 + location.href = location.href;
  142 + }
  143 + }
  144 + });
  145 + } else if ($cur.closest('.cancel').length > 0) {
  146 +
  147 + //Order cancel
  148 + $.ajax({
  149 + type: 'GET',
  150 + url: '/home/cancelOrder',
  151 + data: {
  152 + id: id
  153 + },
  154 + success: function(data) {
  155 + if (data.code === 200) {
  156 +
  157 + //取消订单
  158 + alert('order cancel');
  159 + }
  160 + }
  161 + });
  162 + } else {
  163 +
  164 + //Location to order detail
  165 + url = $order.data('href');
  166 + location.href = url;
  167 + }
  168 +});
  169 +
  170 +$(window).scroll(function() {
  171 + if ($(window).scrollTop() + winH >
  172 + $(document).height() - 0.25 * $orderContainer.height()) {
  173 + getOrders();
  174 + }
  175 +});
50 176
51 - location.href = url;  
52 -});  
  177 +//初始化请求第一页数据
  178 +getOrders();
@@ -6,9 +6,11 @@ @@ -6,9 +6,11 @@
6 var $ = require('jquery'), 6 var $ = require('jquery'),
7 Swiper = require('yoho.iswiper'), 7 Swiper = require('yoho.iswiper'),
8 lazyLoad = require('yoho.lazyload'), 8 lazyLoad = require('yoho.lazyload'),
  9 + Handlebars = require('yoho.handlebars'),
9 goodsSwiper, 10 goodsSwiper,
10 sizeSwiper, 11 sizeSwiper,
11 - refSwiper; 12 + refSwiper,
  13 + handleHelper;
12 14
13 15
14 lazyLoad($('img.lazy')); 16 lazyLoad($('img.lazy'));
@@ -50,6 +52,11 @@ refSwiper = new Swiper('#reference-swiper-container',{ @@ -50,6 +52,11 @@ refSwiper = new Swiper('#reference-swiper-container',{
50 slidesPerView: 'auto' 52 slidesPerView: 'auto'
51 }); 53 });
52 54
  55 +
  56 +handleHelper = Handlebars.registerHelper('addOne', function(index) {
  57 + return index + 1;
  58 +});
  59 +
53 // $('#iframe').load(function() { 60 // $('#iframe').load(function() {
54 // var mainheight = $(this).contents().find('body').height() + 30; 61 // var mainheight = $(this).contents().find('body').height() + 30;
55 // $(this).height(mainheight); 62 // $(this).height(mainheight);
1 var $ = require('jquery'), 1 var $ = require('jquery'),
2 Hammer = require('yoho.hammer'), 2 Hammer = require('yoho.hammer'),
3 Swiper = require('yoho.iswiper'), 3 Swiper = require('yoho.iswiper'),
4 - lazyLoad = require('yoho.lazyload'); 4 + lazyLoad = require('yoho.lazyload')
  5 +
  6 +loading = require('../../plugin/loading');;
5 7
6 var page = 1, 8 var page = 1,
7 winH, 9 winH,
@@ -13,6 +15,7 @@ var page = 1, @@ -13,6 +15,7 @@ var page = 1,
13 id = ''; 15 id = '';
14 16
15 function hotrank(page, sort, tabId, notab) { 17 function hotrank(page, sort, tabId, notab) {
  18 + loading.showLoadingMask();
16 $.ajax({ 19 $.ajax({
17 type: 'GET', 20 type: 'GET',
18 url: '/product/newsale/selectHotrank?' + sort, 21 url: '/product/newsale/selectHotrank?' + sort,
@@ -28,28 +31,20 @@ function hotrank(page, sort, tabId, notab) { @@ -28,28 +31,20 @@ function hotrank(page, sort, tabId, notab) {
28 } 31 }
29 $('#hotRank').append(data); 32 $('#hotRank').append(data);
30 lazyLoad($('img.lazy')); 33 lazyLoad($('img.lazy'));
31 - $('#yoho-footer').css('position', 'static');  
32 $('.rank-main ul li:gt(2)').find('.item-content i').removeClass('top'); 34 $('.rank-main ul li:gt(2)').find('.item-content i').removeClass('top');
  35 + winH = $(window).height();
  36 + if ($('.rank-main').length !== 0) {
  37 + $('#yoho-footer').css('position', 'static');
  38 + listTop = $('.rank-main').find('ul').offset().top;
  39 + } else {
  40 + $('#yoho-footer').css('position', 'fixed');
  41 + }
33 navSwiper = new Swiper('.s-goods-nav', { 42 navSwiper = new Swiper('.s-goods-nav', {
34 grabCursor: true, 43 grabCursor: true,
35 slidesPerView: 'auto', 44 slidesPerView: 'auto',
36 slideElement: 'li' 45 slideElement: 'li'
37 }); 46 });
38 -  
39 - winH = $(window).height();  
40 - listTop = $('.rank-main').find('ul').offset().top;  
41 - $('.s-goods-nav .nav-item').each(function(index) {  
42 - hotnav = new Hammer($('.s-goods-nav .nav-item')[index]);  
43 - hotnav.on('tap', function(e) {  
44 - var navItme = $('.s-goods-nav .nav-item').eq(index);  
45 -  
46 - id = navItme.data('id') ? navItme.data('id') : '';  
47 - sort = navItme.data('sort') ? navItme.data('sort') : '';  
48 - page = 1;  
49 - notab = 1;  
50 - hotrank(page, sort, id, notab);  
51 - });  
52 - }); 47 + loading.hideLoadingMask();
53 } 48 }
54 }); 49 });
55 } 50 }
@@ -67,3 +62,18 @@ $(window).scroll(function () { @@ -67,3 +62,18 @@ $(window).scroll(function () {
67 62
68 }); 63 });
69 hotrank(page, sort, id, notab); 64 hotrank(page, sort, id, notab);
  65 +hotnav = new Hammer(document.getElementById('hotRank'));
  66 +hotnav.on('tap', function (e) {
  67 + var ev = ev || window.event;
  68 + var target = ev.target || ev.srcElement;
  69 +
  70 + if (target.nodeName.toLowerCase() === 'span') {
  71 + $('.s-goods-nav .nav-item').removeClass('active');
  72 + target.parentNode.className = 'active ' + target.parentNode.className;
  73 + id = target.getAttribute('data-id') ? target.getAttribute('data-id') : '';
  74 + sort = target.getAttribute('data-sort') ? target.getAttribute('data-sort') : '';
  75 + page = 1;
  76 + notab = 1;
  77 + hotrank(page, sort, id, notab);
  78 + }
  79 +});
1 -$vip: sprite-map("me/vip/*.png");  
2 .my-page { 1 .my-page {
3 background: #f0f0f0; 2 background: #f0f0f0;
4 3
@@ -27,8 +26,8 @@ $vip: sprite-map("me/vip/*.png"); @@ -27,8 +26,8 @@ $vip: sprite-map("me/vip/*.png");
27 26
28 .vip-icon { 27 .vip-icon {
29 display: inline-block; 28 display: inline-block;
30 - width: pxToRem(70px);  
31 - height: pxToRem(30px); 29 + width: pxToRem(72px);
  30 + height: pxToRem(32px);
32 vertical-align: middle; 31 vertical-align: middle;
33 } 32 }
34 33
  1 +$vip: sprite-map("me/vip/*.png", $spacing: 10px);
  2 +
1 @import "home", "vip-grade", "order", "order-detail", "coupons", "personal-details", "yoho-coin", "fav", "suggest", "address", "online-service"; 3 @import "home", "vip-grade", "order", "order-detail", "coupons", "personal-details", "yoho-coin", "fav", "suggest", "address", "online-service";
2 4
@@ -2,6 +2,7 @@ @@ -2,6 +2,7 @@
2 background: #f0f0f0; 2 background: #f0f0f0;
3 3
4 .order { 4 .order {
  5 + position: relative;
5 display: block; 6 display: block;
6 background: #fff; 7 background: #fff;
7 margin: 30rem / $pxConvertRem 0; 8 margin: 30rem / $pxConvertRem 0;
@@ -64,17 +65,38 @@ @@ -64,17 +65,38 @@
64 } 65 }
65 66
66 .no-order { 67 .no-order {
  68 + position: absolute;
  69 + background: #fff;
67 text-align: center; 70 text-align: center;
68 - color: #f0f0f0; 71 + top: 50%;
  72 + margin-top: -220rem / $pxConvertRem;
  73 + width: 100%;
69 74
70 - .iconfont {  
71 - font-size: 50px; 75 + .icon {
  76 + width: 153rem / $pxConvertRem;
  77 + height: 196rem / $pxConvertRem;
  78 + background: image-url('me/no-order.png') no-repeat;
  79 + background-size: 100%;
  80 + margin: 0 auto;
  81 + }
  82 +
  83 + span {
  84 + display: block;
  85 + color: #b0b0b0;
  86 + font-size: 24rem / $pxConvertRem;
  87 + margin: 30rem / $pxConvertRem 0 110rem / $pxConvertRem;
72 } 88 }
73 89
74 .walk-way { 90 .walk-way {
75 display: block; 91 display: block;
  92 + height: 80rem / pxConvertRem;
  93 + line-height: 80rem / $pxConvertRem;
  94 + width: 70%;
  95 + margin: 0 auto;
  96 + text-align: center;
  97 + font-size: 30rem / $pxConvertRem;
76 color: #fff; 98 color: #fff;
77 - background: #fff; 99 + background: #444;
78 @include border-radius(5px); 100 @include border-radius(5px);
79 } 101 }
80 } 102 }
1 -$vip: sprite-map("me/vip/*.png", $spacing: 10px);  
2 -  
3 .vip-grade-page { 1 .vip-grade-page {
4 background: #f0f0f0; 2 background: #f0f0f0;
5 padding-bottom: 30rem / $pxConvertRem; 3 padding-bottom: 30rem / $pxConvertRem;
1 $mainFontC:#444444; 1 $mainFontC:#444444;
2 $subFontC:#b0b0b0; 2 $subFontC:#b0b0b0;
3 -$borderC:#b0b0b0; 3 +$borderC:#e0e0e0;
4 $tableCellC:#eee; 4 $tableCellC:#eee;
  5 +$basicBtnC:#eb0313;
5 6
6 .good-detail-page { 7 .good-detail-page {
7 8
@@ -10,41 +11,41 @@ $tableCellC:#eee; @@ -10,41 +11,41 @@ $tableCellC:#eee;
10 box-sizing:border-box; 11 box-sizing:border-box;
11 width: 100%; 12 width: 100%;
12 border-bottom: 2px solid $borderC; 13 border-bottom: 2px solid $borderC;
13 - border-top: 2px solid $borderC; 14 + border-top: 1px solid $borderC;
14 padding: 0 pxToRem(28px); 15 padding: 0 pxToRem(28px);
15 - .title{ 16 + >.title{
16 min-height: pxToRem(88px); 17 min-height: pxToRem(88px);
17 line-height: pxToRem(88px); 18 line-height: pxToRem(88px);
18 color: $mainFontC; 19 color: $mainFontC;
19 font-size : pxToRem(28px); 20 font-size : pxToRem(28px);
20 - border-bottom: 2px solid $borderC; 21 + border-bottom: 1px solid $borderC;
21 22
22 span{ 23 span{
23 - color:#a0a0a0;  
24 - font-size:pxToRem(18px); 24 + color:#a0a0a0;
  25 + font-size:pxToRem(18px);
25 // vertical-align: baseline; 26 // vertical-align: baseline;
26 } 27 }
27 - }  
28 - .detail{  
29 - margin-top: pxToRem(20px);  
30 - margin-bottom: pxToRem(20px);  
31 - font-size: pxToRem(24px);  
32 - line-height: pxToRem(36px);  
33 -  
34 - &.table{  
35 - display: table;  
36 - width: 100%;  
37 - .row{  
38 - display: table-row;  
39 - .column{  
40 - display: table-cell;  
41 - padding: 0.4em 0.8em;  
42 - border:2px solid white;  
43 - font-size: pxToRem(24px);  
44 - background-color: $tableCellC;  
45 - }  
46 - }  
47 } 28 }
  29 + .detail{
  30 + margin-top: pxToRem(20px);
  31 + margin-bottom: pxToRem(20px);
  32 + font-size: pxToRem(24px);
  33 + line-height: pxToRem(36px);
  34 +
  35 + &.table{
  36 + display: table;
  37 + width: 100%;
  38 + .row{
  39 + display: table-row;
  40 + .column{
  41 + display: table-cell;
  42 + padding: 0.4em 0.8em;
  43 + border:1px solid white;
  44 + font-size: pxToRem(24px);
  45 + background-color: $tableCellC;
  46 + }
  47 + }
  48 + }
48 49
49 // table { 50 // table {
50 // width: 100%; 51 // width: 100%;
@@ -133,7 +134,7 @@ $tableCellC:#eee; @@ -133,7 +134,7 @@ $tableCellC:#eee;
133 color:$subFontC; 134 color:$subFontC;
134 padding-left:pxToRem(28px); 135 padding-left:pxToRem(28px);
135 padding-right:pxToRem(28px); 136 padding-right:pxToRem(28px);
136 - border-bottom: 2px solid $borderC; 137 + border-bottom:1px solid $borderC;
137 background-color: #f4f4f4; 138 background-color: #f4f4f4;
138 } 139 }
139 140
@@ -143,7 +144,7 @@ $tableCellC:#eee; @@ -143,7 +144,7 @@ $tableCellC:#eee;
143 min-height: pxToRem(88px); 144 min-height: pxToRem(88px);
144 padding-left:pxToRem(28px); 145 padding-left:pxToRem(28px);
145 padding-right:pxToRem(28px); 146 padding-right:pxToRem(28px);
146 - border-bottom: 2px solid $borderC; 147 + border-bottom: 1px solid $borderC;
147 } 148 }
148 .goodsPrice{ 149 .goodsPrice{
149 float: left; 150 float: left;
@@ -161,9 +162,9 @@ $tableCellC:#eee; @@ -161,9 +162,9 @@ $tableCellC:#eee;
161 } 162 }
162 } 163 }
163 .periodOfMarket{ 164 .periodOfMarket{
164 - font-size: pxToRem(24px);  
165 - float: right;  
166 - h1{ 165 + font-size: pxToRem(24px);
  166 + float: right;
  167 + h1{
167 display: inline-block; 168 display: inline-block;
168 line-height: pxToRem(88px); 169 line-height: pxToRem(88px);
169 } 170 }
@@ -173,11 +174,11 @@ $tableCellC:#eee; @@ -173,11 +174,11 @@ $tableCellC:#eee;
173 // width: 100%; 174 // width: 100%;
174 display:table; 175 display:table;
175 span{ 176 span{
176 - display: table-cell;  
177 - vertical-align: middle;  
178 - }  
179 - }  
180 - .vipLevel { 177 + display: table-cell;
  178 + vertical-align: middle;
  179 + }
  180 + }
  181 + .vipLevel {
181 display: table; 182 display: table;
182 min-height: pxToRem(88px); 183 min-height: pxToRem(88px);
183 padding-left:pxToRem(28px); 184 padding-left:pxToRem(28px);
@@ -185,7 +186,7 @@ $tableCellC:#eee; @@ -185,7 +186,7 @@ $tableCellC:#eee;
185 font-size: pxToRem(22px); 186 font-size: pxToRem(22px);
186 color: #999999; 187 color: #999999;
187 188
188 - border-bottom: 2px solid $borderC; 189 + border-bottom: 1px solid $borderC;
189 span{ 190 span{
190 display: table-cell; 191 display: table-cell;
191 vertical-align: middle; 192 vertical-align: middle;
@@ -211,6 +212,7 @@ $tableCellC:#eee; @@ -211,6 +212,7 @@ $tableCellC:#eee;
211 font-size: pxToRem(28px); 212 font-size: pxToRem(28px);
212 color: $mainFontC; 213 color: $mainFontC;
213 line-height: pxToRem(88px); 214 line-height: pxToRem(88px);
  215 +
214 border-bottom: 2px solid $borderC; 216 border-bottom: 2px solid $borderC;
215 217
216 .iconfont{ 218 .iconfont{
@@ -234,8 +236,8 @@ $tableCellC:#eee; @@ -234,8 +236,8 @@ $tableCellC:#eee;
234 height: pxToRem(60px); 236 height: pxToRem(60px);
235 padding: pxToRem(10px) 0; 237 padding: pxToRem(10px) 0;
236 background-color: #fff; 238 background-color: #fff;
237 - border-top: 2px solid $borderC;  
238 - border-bottom: 2px solid $borderC; 239 + border-top: 1px solid $borderC;
  240 + border-bottom: 1px solid $borderC;
239 } 241 }
240 242
241 .comment-nav, .consult-nav { 243 .comment-nav, .consult-nav {
@@ -254,13 +256,13 @@ $tableCellC:#eee; @@ -254,13 +256,13 @@ $tableCellC:#eee;
254 } 256 }
255 257
256 .comment-nav { 258 .comment-nav {
257 - border-right: 2px solid #ccc; 259 + border-right: 1px solid #ccc;
258 } 260 }
259 261
260 .comment-content{ 262 .comment-content{
261 - .comment-content-main{ 263 + .comment-content-main{
262 background-color: #fff; 264 background-color: #fff;
263 - border-bottom: 2px solid $borderC; 265 + border-bottom: 1px solid $borderC;
264 .user-name{ 266 .user-name{
265 font-size: px2rem(24); 267 font-size: px2rem(24);
266 line-height: px2rem(62); 268 line-height: px2rem(62);
@@ -315,6 +317,7 @@ $tableCellC:#eee; @@ -315,6 +317,7 @@ $tableCellC:#eee;
315 } 317 }
316 318
317 .comment-content-footer{ 319 .comment-content-footer{
  320 +
318 min-height: pxToRem(88px); 321 min-height: pxToRem(88px);
319 text-align: center; 322 text-align: center;
320 background-color: #fff; 323 background-color: #fff;
@@ -331,6 +334,7 @@ $tableCellC:#eee; @@ -331,6 +334,7 @@ $tableCellC:#eee;
331 } 334 }
332 } 335 }
333 336
  337 +
334 } 338 }
335 339
336 .content.hide { 340 .content.hide {
@@ -357,39 +361,49 @@ $tableCellC:#eee; @@ -357,39 +361,49 @@ $tableCellC:#eee;
357 margin-right: pxToRem(-25px); 361 margin-right: pxToRem(-25px);
358 } 362 }
359 } 363 }
360 - .store-name{  
361 - font-size: pxToRem(34px);  
362 - color:$mainFontC; 364 +.store-name{
  365 + font-size: pxToRem(34px);
  366 + color:$mainFontC;
  367 +}
  368 +.store-link{
  369 + font-size:pxToRem(28px) ;
  370 + color:$subFontC;
  371 + text-align: right;
  372 + span{
  373 + font-size: inherit;
363 } 374 }
364 - .store-link{  
365 - font-size:pxToRem(28px) ;  
366 - color:$subFontC;  
367 - text-align: right;  
368 - span{  
369 - font-size: inherit; 375 +}
  376 +}
  377 + .goods-desc{
  378 + .service{
  379 + margin-top: pxToRem(22px);
370 } 380 }
371 } 381 }
372 -}  
373 - // .goods-desc{  
374 - // table{  
375 -  
376 - // }  
377 - // } 382 + .tips{
  383 + color:$subFontC;
  384 + font-size: pxToRem(18px);
  385 + margin-top: pxToRem(20px);
  386 + }
378 .materials{ 387 .materials{
379 .detail{ 388 .detail{
380 img{ 389 img{
381 - display: block;  
382 - overflow: hidden;  
383 - width: pxToRem(90px);  
384 - height: pxToRem(120px);  
385 - padding-right: pxToRem(20px);  
386 - float: left;  
387 - } 390 + display: block;
  391 + overflow: hidden;
  392 + width: pxToRem(90px);
  393 + height: pxToRem(120px);
  394 + padding-right: pxToRem(20px);
  395 + float: left;
  396 + }
388 .material-desc{ 397 .material-desc{
389 // float: left; 398 // float: left;
390 font-size: pxToRem(24px); 399 font-size: pxToRem(24px);
  400 +
391 } 401 }
392 } 402 }
  403 + .material-type{
  404 + border-top: 1px solid $borderC;
  405 + padding: pxToRem(17px) 0;
  406 + }
393 } 407 }
394 408
395 .product-detail{ 409 .product-detail{
@@ -400,6 +414,7 @@ $tableCellC:#eee; @@ -400,6 +414,7 @@ $tableCellC:#eee;
400 height: pxToRem(772px); 414 height: pxToRem(772px);
401 } 415 }
402 } 416 }
  417 + margin-bottom: pxToRem(120px);
403 } 418 }
404 419
405 .detail-swiper{ 420 .detail-swiper{
@@ -408,13 +423,126 @@ $tableCellC:#eee; @@ -408,13 +423,126 @@ $tableCellC:#eee;
408 width: pxToRem(114px); 423 width: pxToRem(114px);
409 div{ 424 div{
410 text-align: center; 425 text-align: center;
  426 + &.cell{
  427 + font-size: pxToRem(24px);
  428 + background-color: $tableCellC;
  429 + padding:pxToRem(15px) 0;
  430 + border: 1px solid #fff;
  431 + }
411 } 432 }
412 - div.cell{  
413 - background-color: $tableCellC;  
414 - padding:pxToRem(15px) 0;  
415 - border: 1px solid #fff; 433 + }
  434 + }
  435 + }
  436 +
  437 + #reference-swiper-container{
  438 + .first-group{
  439 + width: pxToRem(58px);
  440 + >div{
  441 + height: pxToRem(67px);
  442 + }
  443 + }
  444 + }
  445 +
  446 + .measurement-method{
  447 + .detail{
  448 + width: 100%;
  449 + height: pxToRem(300px);
  450 + img{
  451 + float:left;
  452 + width: pxToRem(270px);
  453 + height: pxToRem(239px);
  454 + margin-top: pxToRem(18px);
  455 + margin-right: pxToRem(28px);
  456 + }
  457 + .right-part{
  458 + float:left;
  459 + .title{
  460 + >h1{
  461 + margin-top: pxToRem(10px);
  462 + display: inline-block;
  463 + padding-right: pxToRem(10px);
  464 + border-right: 1px solid $borderC;
  465 + line-height: 100%;
  466 + }
  467 + >span{
  468 + font-size: pxToRem(12px);
  469 + }
  470 + }
  471 + ul.items{
  472 + margin-top: pxToRem(20px);
  473 + padding: 0;
  474 + line-height: pxToRem(30px);
  475 + font-size: pxToRem(13px);
  476 + li{
  477 + span{
  478 + display: inline-block;
  479 + width: pxToRem(15px);
  480 + height: pxToRem(15px);
  481 + background-color: $basicBtnC;
  482 + border-radius: 50%;
  483 + color:white;
  484 + text-align: center;
  485 + line-height: pxToRem(15px);
  486 + font-size: pxToRem(13px);
  487 + margin-right: pxToRem(12px);
  488 + vertical-align: text-bottom;
  489 + }
  490 + }
416 } 491 }
417 } 492 }
  493 + clear:both;
418 } 494 }
419 } 495 }
  496 + .cart-bar{
  497 + position: relative;
  498 + box-sizing:border-box;
  499 + width: 100%;
  500 + height: pxToRem(120px);
  501 + position:fixed;
  502 + bottom: 0;
  503 + background-color: white;
  504 + z-index: 64;
  505 + padding:pxToRem(20px) pxToRem(28px);
  506 + text-align: center;
  507 +
  508 +
  509 + a{
  510 + display: inline-block;
  511 + &.num-incart{
  512 + width: pxToRem(45px);
  513 + height: pxToRem(45px);
  514 + background: url(../img/product/cart.png) no-repeat;
  515 + }
  516 + &.favorite{
  517 + width: pxToRem(34px);
  518 + height: pxToRem(32px);
  519 + background:url(../img/product/favorite.png) no-repeat;
  520 + }
  521 + &.addto-cart{
  522 + height: pxToRem(80px);
  523 + width: pxToRem(260px);
  524 + margin:0 pxToRem(100px) 0 pxToRem(128px);
  525 + color: #fff;
  526 + background-color: $basicBtnC;
  527 + font-size: pxToRem(40px);
  528 + line-height: pxToRem(80px);
  529 + text-align: center;
  530 + }
  531 + }
  532 + .num-tag{
  533 + position: absolute;
  534 + left:pxToRem(66px);
  535 + height: pxToRem(20px);
  536 + display: block;
  537 + width: pxToRem(36px);
  538 + height: pxToRem(36px);
  539 + background-color: $basicBtnC;
  540 + border-radius: 50%;
  541 + color:white;
  542 + font-size: pxToRem(24px);
  543 + }
  544 +
  545 + }
  546 +
  547 +
420 } 548 }
@@ -74,7 +74,7 @@ @@ -74,7 +74,7 @@
74 overflow: hidden; 74 overflow: hidden;
75 white-space: nowrap; 75 white-space: nowrap;
76 76
77 - span { 77 + b {
78 text-decoration: line-through; 78 text-decoration: line-through;
79 color: #b0b0b0; 79 color: #b0b0b0;
80 margin-left: 10rem / $pxConvertRem; 80 margin-left: 10rem / $pxConvertRem;
@@ -125,12 +125,20 @@ @@ -125,12 +125,20 @@
125 } 125 }
126 126
127 .s-goods-nav { 127 .s-goods-nav {
  128 + box-sizing:border-box;
  129 + -moz-box-sizing:border-box;
  130 + -webkit-box-sizing:border-box;
128 overflow: hidden; 131 overflow: hidden;
129 132
130 li { 133 li {
131 margin: 0 0 0 (50rem / $pxConvertRem); 134 margin: 0 0 0 (50rem / $pxConvertRem);
132 width: auto; 135 width: auto;
133 - 136 + height: 95%;
  137 + color: #999;
  138 + &.active{
  139 + color: #000;
  140 + border-bottom:2px solid #000;
  141 + }
134 a { 142 a {
135 padding: 0; 143 padding: 0;
136 } 144 }
@@ -2,27 +2,17 @@ @@ -2,27 +2,17 @@
2 <div class="order-page yoho-page"> 2 <div class="order-page yoho-page">
3 {{# order}} 3 {{# order}}
4 <ul id="order-nav" class="order-nav clearfix"> 4 <ul id="order-nav" class="order-nav clearfix">
5 - <li class="active">  
6 - 全部  
7 - </li>  
8 - <li>  
9 - 待付款  
10 - </li>  
11 - <li>  
12 - 待发货  
13 - </li>  
14 - <li>  
15 - 待收货  
16 - </li> 5 + {{#each navs}}
  6 + <li {{#if active}}class="active"{{/if}} data-type="{{typeId}}">
  7 + {{name}}
  8 + </li>
  9 + {{/each}}
17 </ul> 10 </ul>
18 11
19 <div id="order-container" class="order-container"> 12 <div id="order-container" class="order-container">
20 - <div class="all orders">  
21 - {{> me/order/orders}}  
22 - </div>  
23 - <div class="unpaid orders hide"></div>  
24 - <div class="unshipped orders hide"></div>  
25 - <div class="unreceived orders hide"></div> 13 + {{#each navs}}
  14 + <div class="orders{{#unless active}} hide{{/unless}}"></div>
  15 + {{/each}}
26 </div> 16 </div>
27 {{/ order}} 17 {{/ order}}
28 </div> 18 </div>
@@ -121,6 +121,7 @@ @@ -121,6 +121,7 @@
121 121
122 {{#goodsDescription}} 122 {{#goodsDescription}}
123 <div class="goods-desc page-block"> 123 <div class="goods-desc page-block">
  124 + <img class="service" src="http://static.dev.yohobuy.com/img/product/service.png" alt="">
124 <h1 class="title"> 125 <h1 class="title">
125 {{title}} 126 {{title}}
126 <span class="en-title">{{enTitle}}</span> 127 <span class="en-title">{{enTitle}}</span>
@@ -169,6 +170,7 @@ @@ -169,6 +170,7 @@
169 {{/list}} 170 {{/list}}
170 </div> 171 </div>
171 </div> 172 </div>
  173 + <p class="tips">提示:左滑查看完整表格信息</p>
172 </div> 174 </div>
173 {{/detail}} 175 {{/detail}}
174 </div> 176 </div>
@@ -176,15 +178,32 @@ @@ -176,15 +178,32 @@
176 178
177 <div class="gap-block"></div> 179 <div class="gap-block"></div>
178 180
179 - <div class="size-info page-block"> 181 + {{#measurementMethod}}
  182 + <div class="measurement-method page-block">
180 <h1 class="title"> 183 <h1 class="title">
181 - 测量方式  
182 - <span class="en-title">SIZE INFO</span> 184 + {{title}}
  185 + <span class="en-title">{{enTitle}}</span>
183 </h1> 186 </h1>
184 - <div class="detail">  
185 - 187 + {{#detail}}
  188 + <div class="detail" style="width:100%">
  189 + <img src="{{img}}" alt="">
  190 + <div class="right-part">
  191 + <div class="title">
  192 + <h1 >{{sort}}</h1>
  193 + <span>{{enSort}}</span>
  194 + </div>
  195 + <ul class="items">
  196 + {{#each items}}
  197 + <li>
  198 + <span>{{@index}}</span>
  199 + {{this}}</li>
  200 + {{/items}}
  201 + </ul>
  202 + </div>
186 </div> 203 </div>
  204 + {{/detail}}
187 </div> 205 </div>
  206 + {{/measurementMethod}}
188 207
189 <div class="gap-block"></div> 208 <div class="gap-block"></div>
190 209
@@ -199,14 +218,27 @@ @@ -199,14 +218,27 @@
199 <div class="swiper-container detail-swiper" id="reference-swiper-container"> 218 <div class="swiper-container detail-swiper" id="reference-swiper-container">
200 <div class="swiper-wrapper"> 219 <div class="swiper-wrapper">
201 {{#list}} 220 {{#list}}
202 - <div class="swiper-slide blue-slide" >  
203 - <div class="model-name cell">{{name}}</div> 221 + {{#if @first}}
  222 + <div class="swiper-slide first-group" >
  223 + <div class="model-field" >{{fieldName}}</div>
  224 + <div class="first-model">
  225 + <img src="{{firstModel}}" alt="">
  226 + </div>
  227 + <div class="second-model">
  228 + <img src="{{secondModel}}" alt="">
  229 + </div>
  230 + </div>
  231 + {{^}}
  232 + <div class="swiper-slide" >
  233 + <div class="model-field cell">{{fieldName}}</div>
204 <div class="first-model cell">{{firstModel}}</div> 234 <div class="first-model cell">{{firstModel}}</div>
205 <div class="second-model cell">{{secondModel}}</div> 235 <div class="second-model cell">{{secondModel}}</div>
206 </div> 236 </div>
  237 + {{/if}}
207 {{/list}} 238 {{/list}}
208 </div> 239 </div>
209 </div> 240 </div>
  241 + <p class="tips">提示:左滑查看完整表格信息</p>
210 </div> 242 </div>
211 {{/detail}} 243 {{/detail}}
212 </div> 244 </div>
@@ -226,7 +258,9 @@ @@ -226,7 +258,9 @@
226 258
227 {{desc}} 259 {{desc}}
228 </p> 260 </p>
  261 +
229 </div> 262 </div>
  263 + <img src="{{materialType}}" alt="" class="material-type">
230 </div> 264 </div>
231 {{/materials}} 265 {{/materials}}
232 266
@@ -244,6 +278,15 @@ @@ -244,6 +278,15 @@
244 </div> 278 </div>
245 </div> 279 </div>
246 {{/productDetail}} 280 {{/productDetail}}
  281 +
247 282
  283 + {{#cartInfo}}
  284 + <div class="cart-bar">
  285 + <span class="num-tag">{{numInCart}}</span>
  286 + <a href="" class="num-incart"></a>
  287 + <a href="" class="addto-cart">加入购物车</a>
  288 + <a href="" class="favorite"></a>
  289 + </div>
  290 + {{/cartInfo}}
248 </div> 291 </div>
249 {{> layout/footer}} 292 {{> layout/footer}}
@@ -3,8 +3,8 @@ @@ -3,8 +3,8 @@
3 <ul class="swiper-wrapper clearfix"> 3 <ul class="swiper-wrapper clearfix">
4 {{# tabs}} 4 {{# tabs}}
5 {{# title}} 5 {{# title}}
6 - <li class="swiper-slide nav-item" data-sort="{{ params}}" data-id="{{ id}}">  
7 - <span>{{ name}}</span> 6 + <li class="swiper-slide nav-item">
  7 + <span data-sort="{{ params}}" data-id="{{ id}}" >{{ name}}</span>
8 </li> 8 </li>
9 {{/ title}} 9 {{/ title}}
10 {{/ tabs}} 10 {{/ tabs}}
@@ -25,7 +25,7 @@ @@ -25,7 +25,7 @@
25 {{# active}} 25 {{# active}}
26 <p>{{.}}</p> 26 <p>{{.}}</p>
27 {{/ active}} 27 {{/ active}}
28 - <p>{{salePrice}}<span>{{price}}</span></p> 28 + <p>{{salePrice}}<b>{{price}}</b></p>
29 </div> 29 </div>
30 </a> 30 </a>
31 </li> 31 </li>
1 {{#if walkwayUrl}} 1 {{#if walkwayUrl}}
2 <div class="no-order"> 2 <div class="no-order">
3 - <span class="iconfont">&#xe632;</span> 3 + <div class="icon"></div>
4 <span>你还没有订单</span> 4 <span>你还没有订单</span>
5 <a class="walk-way" href="{{walkwayUrl}}">随便逛逛</a> 5 <a class="walk-way" href="{{walkwayUrl}}">随便逛逛</a>
6 </div> 6 </div>
@@ -528,26 +528,48 @@ class HomeController extends AbstractAction @@ -528,26 +528,48 @@ class HomeController extends AbstractAction
528 $yh_channel = $this->get('yh_channel', 1); 528 $yh_channel = $this->get('yh_channel', 1);
529 $uid = $this->getUid(); 529 $uid = $this->getUid();
530 $uid = '7566245'; //测试用 530 $uid = '7566245'; //测试用
  531 + $this -> setTitle('我的订单');
  532 + $this -> setNavHeader('我的订单');
531 //调用模型层getOrder方法获得并处理数据 533 //调用模型层getOrder方法获得并处理数据
532 $data = OrderModel::getOrder($type, $page, $limit, $gender, $yh_channel, $uid); 534 $data = OrderModel::getOrder($type, $page, $limit, $gender, $yh_channel, $uid);
533 //如果没有订单数据,就给一个随便逛逛链接 535 //如果没有订单数据,就给一个随便逛逛链接
534 $order = array(); 536 $order = array();
535 - if (!empty($data)) {  
536 - $order['orders'] = $data;  
537 - } else {  
538 - $order['walkwayUrl'] = 'http://www.baidu.com';  
539 - } 537 + // if (!empty($data)) {
  538 + // $order['orders'] = $data;
  539 + // } else {
  540 + // $order['walkwayUrl'] = 'http://www.baidu.com';
  541 + // }
  542 + $order['navs'] = array(
  543 + array(
  544 + 'name' => '全部',
  545 + 'active' => true,
  546 + 'typeId' => '1'
  547 + ),
  548 + array(
  549 + 'name' => '待付款',
  550 + 'typeId' => '2'
  551 + ),
  552 + array(
  553 + 'name' => '待发货',
  554 + 'typeId' => '3'
  555 + ),
  556 + array(
  557 + 'name' => '待收货',
  558 + 'typeId' => '4'
  559 + )
  560 + );
540 //渲染模板 561 //渲染模板
541 $this->_view->display('order', array( 562 $this->_view->display('order', array(
542 'order' => $order, 563 'order' => $order,
543 - 'orderPage' => true 564 + 'orderPage' => true,
  565 + 'pageFooter' => true
544 )); 566 ));
545 } 567 }
546 568
547 /* 569 /*
548 * 我的订单-处理ajax请求页面(切换订单状态) 570 * 我的订单-处理ajax请求页面(切换订单状态)
549 */ 571 */
550 - public function orderAjaxAction() { 572 + public function getOrdersAction() {
551 573
552 //判断是不是ajax请求 574 //判断是不是ajax请求
553 if (!$this->isAjax()) { 575 if (!$this->isAjax()) {
@@ -556,4 +578,47 @@ class HomeController extends AbstractAction @@ -556,4 +578,47 @@ class HomeController extends AbstractAction
556 self::orderAction(); 578 self::orderAction();
557 } 579 }
558 580
  581 + public function orderDetailAction()
  582 + {
  583 + $data = array(
  584 + 'name' => '毛毛莉Lydia',
  585 + 'phoneNum' => '18600001133',
  586 + 'address' => '南京市建邺区嘉陵江东街18号国家广告产业园5栋17楼',
  587 + 'orderStatus' => '订单取消',
  588 + 'orderNum' => '418358063',
  589 + 'orderTime' => '2014-03-10 17:25:10',
  590 +
  591 + 'orderCancel' => true,
  592 +
  593 + 'goods' => array(
  594 + array(
  595 + 'id' => 1,
  596 + 'thumb' => 'http://img11.static.yhbimg.com/goodsimg/2015/11/04/05/01ce2aff32fc3c90584f516167cd526d91.jpg?imageMogr2/thumbnail/235x314/extent/235x314/background/d2hpdGU=/position/center/quality/90',
  597 + 'name' => 'Adidas Originals ZX FLUXM22508',
  598 + 'color' => '黄',
  599 + 'size' => '43',
  600 + 'price' => '699.00',
  601 + 'count' => '2'
  602 + ),
  603 + array(
  604 + 'id' => 1,
  605 + 'thumb' => 'http://img10.static.yhbimg.com/goodsimg/2015/11/04/05/0188f1aca49ac478a565ec029b5d2d4a6c.jpg?imageMogr2/thumbnail/235x314/extent/235x314/background/d2hpdGU=/position/center/quality/90',
  606 + 'name' => 'B.Duck浴室玩伴mini浮水鸭',
  607 + 'gift' => true,
  608 + 'color' => '黄',
  609 + 'size' => '43',
  610 + 'price' => '0.00',
  611 + 'count' => '1'
  612 + )
  613 + ),
  614 +
  615 + 'sumPrice' => 799,
  616 + 'salePrice' => 80,
  617 + 'freight' => 5,
  618 + 'coupon' => 0,
  619 + 'yohoCoin' => 5,
  620 + 'price' => 719
  621 + );
  622 + $this->_view->display('order-detail', array('orderDetail' => $data, 'orderDetailPage' => true));
  623 + }
559 } 624 }
@@ -57,9 +57,13 @@ class OrderModel @@ -57,9 +57,13 @@ class OrderModel
57 case 0: 57 case 0:
58 $result[$key]['unpaid'] = true; 58 $result[$key]['unpaid'] = true;
59 break; 59 break;
60 - case 1 || 2 || 3 || 4 || 5: 60 + case 1:
  61 + case 2:
  62 + case 3:
  63 + case 4:
  64 + case 5:
61 $result[$key]['unreceived'] = true; 65 $result[$key]['unreceived'] = true;
62 - $resault[$key]['logisticsUrl'] = "暂无logisticsUrl数据"; 66 + $result[$key]['logisticsUrl'] = "暂无logisticsUrl数据";
63 break; 67 break;
64 case 6: 68 case 6:
65 $result[$key]['completed'] = true; 69 $result[$key]['completed'] = true;
@@ -145,13 +145,20 @@ SHOE BQT KEN BLOCK', @@ -145,13 +145,20 @@ SHOE BQT KEN BLOCK',
145 145
146 'measurementMethod'=>array( 146 'measurementMethod'=>array(
147 'title' => '测量方式', 147 'title' => '测量方式',
148 - 'enTitle' =>'SIZE INFO', 148 + 'enTitle' =>'MEASUREMENT METHOD',
149 149
150 'detail'=>array( 150 'detail'=>array(
151 - 'kind' =>'上衣' ,  
152 - 'enKind'=>'TOPS',  
153 -  
154 - 'img' =>'' 151 + 'sort' =>'上衣' ,
  152 + 'enSort'=>'TOPS',
  153 + 'img' =>'http://static.dev.yohobuy.com/img/product/tops.png',
  154 + 'items'=>array(
  155 + '肩宽(两端肩线间的直线长度)',
  156 + '胸围(两端肩线间的直线长度)',
  157 + '肩宽(两端肩线间的直线长度)',
  158 + '肩宽(两端肩线间的直线长度)',
  159 + '肩宽(两端肩线间的直线长度)',
  160 + '肩宽(两端肩线间的直线长度)'
  161 + )
155 ) 162 )
156 ), 163 ),
157 164
@@ -162,32 +169,32 @@ SHOE BQT KEN BLOCK', @@ -162,32 +169,32 @@ SHOE BQT KEN BLOCK',
162 'detail' =>array( 169 'detail' =>array(
163 'list'=>array( 170 'list'=>array(
164 array( 171 array(
165 - 'name'=>'头像',  
166 - 'firstModel'=>'',  
167 - 'secondModel' =>'' 172 + 'fieldName'=>' ',
  173 + 'firstModel'=>'http://static.dev.yohobuy.com/img/product/avatar1.png',
  174 + 'secondModel' =>'http://static.dev.yohobuy.com/img/product/avatar2.png'
168 ), 175 ),
169 array( 176 array(
170 - 'name'=>'模特', 177 + 'fieldName'=>'模特',
171 'firstModel'=>'Oliver', 178 'firstModel'=>'Oliver',
172 'secondModel' =>'Jvly' 179 'secondModel' =>'Jvly'
173 ), 180 ),
174 array( 181 array(
175 - 'name'=>'身高', 182 + 'fieldName'=>'身高',
176 'firstModel'=>'175', 183 'firstModel'=>'175',
177 'secondModel' =>'170' 184 'secondModel' =>'170'
178 ), 185 ),
179 array( 186 array(
180 - 'name'=>'体重', 187 + 'fieldName'=>'体重',
181 'firstModel'=>'53', 188 'firstModel'=>'53',
182 'secondModel' =>'59' 189 'secondModel' =>'59'
183 ), 190 ),
184 array( 191 array(
185 - 'name'=>'三围', 192 + 'fieldName'=>'三围',
186 'firstModel'=>'78/70/87', 193 'firstModel'=>'78/70/87',
187 'secondModel' =>'78/70/87' 194 'secondModel' =>'78/70/87'
188 ), 195 ),
189 array( 196 array(
190 - 'name'=>'吊牌尺', 197 + 'fieldName'=>'吊牌尺',
191 'firstModel'=>'S', 198 'firstModel'=>'S',
192 'secondModel' =>'L' 199 'secondModel' =>'L'
193 ) 200 )
@@ -199,7 +206,8 @@ SHOE BQT KEN BLOCK', @@ -199,7 +206,8 @@ SHOE BQT KEN BLOCK',
199 'title' => '商品材质', 206 'title' => '商品材质',
200 'enTitle' =>'MATERIALS', 207 'enTitle' =>'MATERIALS',
201 'img' => 'http://static.dev.yohobuy.com/img/product/material.png', 208 'img' => 'http://static.dev.yohobuy.com/img/product/material.png',
202 - 'desc' =>'用各种洗涤剂,可手洗机洗,但不宜氯漂,宜阴干,避免曝晒,以免深色衣物褪色,在日光下晾晒时,将里面朝外。浸泡时间不能太长,避免褪色,深色与浅色衣服最好请分开洗涤,避免染色。' 209 + 'desc' =>'用各种洗涤剂,可手洗机洗,但不宜氯漂,宜阴干,避免曝晒,以免深色衣物褪色,在日光下晾晒时,将里面朝外。浸泡时间不能太长,避免褪色,深色与浅色衣服最好请分开洗涤,避免染色。',
  210 + 'materialType'=>'http://static.dev.yohobuy.com/img/product/material-type.png'
203 ), 211 ),
204 212
205 'productDetail' =>array( 213 'productDetail' =>array(
@@ -207,7 +215,11 @@ SHOE BQT KEN BLOCK', @@ -207,7 +215,11 @@ SHOE BQT KEN BLOCK',
207 'enTitle' =>'DETAILS', 215 'enTitle' =>'DETAILS',
208 'desc' => 'Married to the MOB是由Leah McSweeney创立的女装品牌,一向标榜不羁、大胆的女性streetwear设计。喜欢恶搞的女生们,赶紧入手吧。', 216 'desc' => 'Married to the MOB是由Leah McSweeney创立的女装品牌,一向标榜不羁、大胆的女性streetwear设计。喜欢恶搞的女生们,赶紧入手吧。',
209 'img' =>'http://static.dev.yohobuy.com/img/product/product.png' 217 'img' =>'http://static.dev.yohobuy.com/img/product/product.png'
210 - ) 218 + ),
  219 +
  220 + 'cartInfo' =>array(
  221 + 'numInCart' => 3
  222 + )
211 223
212 ); 224 );
213 225