Authored by whb

pc的购物车代码

Showing 100 changed files with 1008 additions and 971 deletions

Too many changes to show.

To preserve performance only 100 of 100+ files are displayed.

1 -<?php  
2 -  
3 -namespace LibModels\Web\Home;  
4 -  
5 -use Api\Sign;  
6 -use Api\Yohobuy;  
7 -use LibModels\Web\Product\SearchData;  
8 -  
9 -/**  
10 - * 购物车的数据模型  
11 - *  
12 - * @name CartData  
13 - * @package LibModels/Web/Home  
14 - * @copyright yoho.inc  
15 - * @version 1.0 (2016-02-17 14:12:32)  
16 - * @author fei.hong <fei.hong@yoho.cn>  
17 - */  
18 -class CartData  
19 -{  
20 -  
21 - /**  
22 - * 加入购物车接口  
23 - *  
24 - * @param int $productSku 商品SKU  
25 - * @param int $buyNumber 购买数量  
26 - * @param int $goodsType 商品类型,0表示普通商品,1表示加价购商品  
27 - * @param int $isEdit 是否是编辑商品SKU,0表示不是编辑  
28 - * @param null|int $promotionId 促销id,默认null(加价购有关)  
29 - * @param null|int $uid 用户UID,可以不传  
30 - * @param string $shoppingKey 未登录用户唯一识别码,可以不传  
31 - * @return array 加入购物车接口返回的数据  
32 - */  
33 - public static function addToCart($productSku, $buyNumber, $goodsType, $isEdit = 0, $promotionId = null, $uid = null, $shoppingKey = null)  
34 - {  
35 - $param = Yohobuy::param();  
36 - $param['method'] = 'app.Shopping.add';  
37 - $param['product_sku'] = $productSku;  
38 - $param['buy_number'] = intval($buyNumber);  
39 - $param['goods_type'] = $goodsType;  
40 - $param['edit_product_sku'] = $isEdit;  
41 - $param['selected'] = 'Y';  
42 - $param['promotion_id'] = $promotionId;  
43 - if (!empty($uid)) {  
44 - $param['uid'] = $uid;  
45 - }  
46 - if (!empty($shoppingKey)) {  
47 - $param['shopping_key'] = $shoppingKey;  
48 - }  
49 - $param['client_secret'] = Sign::getSign($param);  
50 -  
51 - return Yohobuy::get(Yohobuy::API_URL, $param);  
52 - }  
53 -  
54 - /**  
55 - * 购物车商品选择与取消接口  
56 - *  
57 - * @param int $uid 用户ID  
58 - * @param string $sku 商品sku列表  
59 - * @param string $shoppingKey 未登录用户唯一识别码  
60 - * @return array 购物车接口返回的数据  
61 - */  
62 - public static function selectGoods($uid, $sku, $shoppingKey)  
63 - {  
64 - $param = Yohobuy::param();  
65 - $param['method'] = 'app.Shopping.selected';  
66 - $param['product_sku_list'] = $sku;  
67 - if (!empty($uid)) {  
68 - $param['uid'] = $uid;  
69 - }  
70 - if (!empty($shoppingKey)) {  
71 - $param['shopping_key'] = $shoppingKey;  
72 - }  
73 - $param['client_secret'] = Sign::getSign($param);  
74 -  
75 - return Yohobuy::get(Yohobuy::API_URL, $param);  
76 - }  
77 -  
78 - /**  
79 - * 购物车数据  
80 - *  
81 - * @param int $uid 用户ID  
82 - * @param string $shoppingKey 未登录用户唯一识别码  
83 - * @return array 购物车接口返回的数据  
84 - */  
85 - public static function cartData($uid, $shoppingKey)  
86 - {  
87 - $param = Yohobuy::param();  
88 - $param['method'] = 'app.Shopping.cart';  
89 - if (!empty($uid)) {  
90 - $param['uid'] = $uid;  
91 - }  
92 - if (!empty($shoppingKey)) {  
93 - $param['shopping_key'] = $shoppingKey;  
94 - }  
95 - $param['client_secret'] = Sign::getSign($param);  
96 -  
97 - return Yohobuy::get(Yohobuy::API_URL, $param);  
98 - }  
99 -  
100 - /**  
101 - * 移出购物车  
102 - *  
103 - * @param int $uid 用户ID  
104 - * @param string $sku 商品sku列表  
105 - * @param string $shoppingKey 未登录用户唯一识别码  
106 - * @return array 接口返回的数据  
107 - */  
108 - public static function removeFromCart($uid, $sku, $shoppingKey)  
109 - {  
110 - $param = Yohobuy::param();  
111 - $param['method'] = 'app.Shopping.remove';  
112 - $param['product_sku_list'] = $sku;  
113 - if (!empty($uid)) {  
114 - $param['uid'] = $uid;  
115 - }  
116 - if (!empty($shoppingKey)) {  
117 - $param['shopping_key'] = $shoppingKey;  
118 - }  
119 - $param['client_secret'] = Sign::getSign($param);  
120 -  
121 - return Yohobuy::get(Yohobuy::API_URL, $param);  
122 - }  
123 -  
124 - /**  
125 - * 移入收藏夹  
126 - *  
127 - * @param int $uid 用户ID  
128 - * @param string $sku 商品sku列表  
129 - * @return array 接口返回的数据  
130 - */  
131 - public static function addToFav($uid, $sku)  
132 - {  
133 - $param = Yohobuy::param();  
134 - $param['method'] = 'app.Shopping.addfavorite';  
135 - $param['product_sku_list'] = $sku;  
136 - $param['uid'] = $uid;  
137 - $param['client_secret'] = Sign::getSign($param);  
138 -  
139 - return Yohobuy::get(Yohobuy::API_URL, $param);  
140 - }  
141 -  
142 - /**  
143 - * 获取购物车商品详情数据  
144 - *  
145 - * @param int $uid 用户ID  
146 - * @param int $skn 商品skn  
147 - * @return array 接口返回的数据  
148 - */  
149 - public static function cartProductData($uid, $skn)  
150 - {  
151 - $param = Yohobuy::param();  
152 - $param['method'] = 'app.product.data';  
153 - $param['product_skn'] = $skn;  
154 - $param['showcomment'] = 'N';  
155 - $param['uid'] = $uid;  
156 - $param['client_secret'] = Sign::getSign($param);  
157 -  
158 - return Yohobuy::get(Yohobuy::API_URL, $param);  
159 - }  
160 -  
161 - /**  
162 - * 获取加价购商品详情数据  
163 - *  
164 - * @param int $skn 商品skn  
165 - * @param int $promotionId 加价购商品促销ID  
166 - * @return array 接口返回的数据  
167 - */  
168 - public static function giftProductData($skn, $promotionId)  
169 - {  
170 - $param = Yohobuy::param();  
171 - $param['method'] = 'app.product.gift';  
172 - $param['product_skn'] = $skn;  
173 - $param['promotion_id'] = $promotionId;  
174 - $param['client_secret'] = Sign::getSign($param);  
175 -  
176 - return Yohobuy::get(Yohobuy::API_URL, $param);  
177 - }  
178 -  
179 - /**  
180 - * 增减购物车商品数量  
181 - *  
182 - * @param int $uid 用户ID  
183 - * @param string $sku 商品SKU  
184 - * @param int $increaseNum 增加的数目  
185 - * @param int $decreaseNum 减少的数目  
186 - * @param string $shoppingKey 未登录用户唯一识别码  
187 - * @return array 接口返回的数据  
188 - */  
189 - public static function modifyProductNum($uid, $sku, $increaseNum, $decreaseNum, $shoppingKey)  
190 - {  
191 - $param = Yohobuy::param();  
192 - $param['product_sku'] = $sku;  
193 - // 增加  
194 - if (!empty($increaseNum)) {  
195 - $param['method'] = 'app.Shopping.increase';  
196 - $param['increase_number'] = intval($increaseNum);  
197 - }  
198 - // 减少  
199 - if (!empty($decreaseNum)) {  
200 - $param['method'] = 'app.Shopping.decrease';  
201 - $param['decrease_number'] = intval($decreaseNum);  
202 - }  
203 - if (!empty($uid)) {  
204 - $param['uid'] = $uid;  
205 - }  
206 - if (!empty($shoppingKey)) {  
207 - $param['shopping_key'] = $shoppingKey;  
208 - }  
209 - $param['client_secret'] = Sign::getSign($param);  
210 -  
211 - return Yohobuy::get(Yohobuy::API_URL, $param);  
212 - }  
213 -  
214 - /**  
215 - * 修改购物车商品数据  
216 - *  
217 - * @param int $uid 用户ID  
218 - * @param string $swapData 商品数据  
219 - * @param string $shoppingKey 未登录用户唯一识别码  
220 - * @return array 接口返回的数据  
221 - */  
222 - public static function modifyCartProduct($uid, $swapData, $shoppingKey)  
223 - {  
224 - $param = Yohobuy::param();  
225 - $param['method'] = 'app.Shopping.swap';  
226 - $param['swap_data'] = $swapData;  
227 - if (!empty($uid)) {  
228 - $param['uid'] = $uid;  
229 - }  
230 - if (!empty($shoppingKey)) {  
231 - $param['shopping_key'] = $shoppingKey;  
232 - }  
233 - $param['client_secret'] = Sign::getSign($param);  
234 -  
235 - return Yohobuy::get(Yohobuy::API_URL, $param);  
236 - }  
237 -  
238 - /**  
239 - * 购物车结算  
240 - *  
241 - * @param int $uid 用户ID  
242 - * @param string $cartType 购物车类型,ordinary表示普通购物车  
243 - * @param int $isUseYohoCoin 是否使用有货币,默认0不使用, 1使用  
244 - * @return array 接口返回的数据  
245 - */  
246 - public static function cartPay($uid, $cartType, $isUseYohoCoin = 0)  
247 - {  
248 - $param = Yohobuy::param();  
249 - $param['method'] = 'app.Shopping.payment';  
250 - $param['cart_type'] = $cartType;  
251 - $param['yoho_coin_mode'] = $isUseYohoCoin;  
252 - $param['uid'] = $uid;  
253 - $param['client_secret'] = Sign::getSign($param);  
254 -  
255 - return Yohobuy::get(Yohobuy::API_URL, $param);  
256 - }  
257 -  
258 - /**  
259 - * 购物车结算--支付方式和配送方式选择  
260 - *  
261 - * @param int $uid 用户ID  
262 - * @param string $cartType 购物车类型,ordinary表示普通购物车  
263 - * @param int $deliveryWay 配送方式,1表示普通快递,2表示顺丰速运  
264 - * @param int $paymentType 支付方式,1表示在线支付,2表示货到付款  
265 - * @param string $couponCode 优惠券码  
266 - * @param mixed $yohoCoin 使用的YOHO币数量  
267 - * @param int $redEnvelopes 红包  
268 - * @return array 接口返回的数据  
269 - */  
270 - public static function orderCompute($uid, $cartType, $deliveryWay, $paymentType, $couponCode, $yohoCoin, $redEnvelopes)  
271 - {  
272 - $param = Yohobuy::param();  
273 - $param['method'] = 'app.Shopping.compute';  
274 - $param['cart_type'] = $cartType;  
275 - $param['delivery_way'] = $deliveryWay;  
276 - $param['payment_type'] = $paymentType;  
277 - if (!empty($couponCode)) {  
278 - $param['coupon_code'] = $couponCode;  
279 - }  
280 - if (!empty($yohoCoin)) {  
281 - $param['use_yoho_coin'] = $yohoCoin;  
282 - }  
283 - if (!empty($redEnvelopes)) {  
284 - $param['use_red_envelopes'] = $redEnvelopes;  
285 - }  
286 - $param['uid'] = $uid;  
287 - $param['client_secret'] = Sign::getSign($param);  
288 -  
289 - return Yohobuy::get(Yohobuy::API_URL, $param);  
290 - }  
291 -  
292 - /**  
293 - * 购物车结算--使用优惠券  
294 - *  
295 - * @param int $uid 用户ID  
296 - * @param string $couponCode 优惠券代码  
297 - * @return array 接口返回的数据  
298 - */  
299 - public static function searchCoupon($uid, $couponCode)  
300 - {  
301 - $param = Yohobuy::param();  
302 - $param['method'] = 'app.Shopping.useCoupon';  
303 - $param['coupon_code'] = $couponCode;  
304 - $param['uid'] = $uid;  
305 - $param['client_secret'] = Sign::getSign($param);  
306 -  
307 - return Yohobuy::get(Yohobuy::API_URL, $param);  
308 - }  
309 -  
310 - /**  
311 - * 购物车结算--获取优惠券列表  
312 - *  
313 - * @param int $uid 用户ID  
314 - * @return array 接口返回的数据  
315 - */  
316 - public static function getCouponList($uid, $limit = 10)  
317 - {  
318 - $param = Yohobuy::param();  
319 - $param['method'] = 'app.coupons.lists';  
320 - $param['type'] = 'notuse';  
321 - $param['page'] = 1;  
322 - $param['limit'] = $limit;  
323 - $param['uid'] = $uid;  
324 - $param['client_secret'] = Sign::getSign($param);  
325 -  
326 - return Yohobuy::get(Yohobuy::API_URL, $param);  
327 - }  
328 -  
329 - /**  
330 - * 购物车结算--提交结算信息  
331 - *  
332 - * @param int $uid 用户ID  
333 - * @param int $addressId 地址ID  
334 - * @param string $cartType 购物车类型  
335 - * @param int $deliveryTime 寄送时间ID  
336 - * @param int $deliveryWay 寄送方式ID  
337 - * @param string $invoiceTitle 发票说明  
338 - * @param int $invoiceId 发票类型ID  
339 - * @param int $paymentId 支付方式ID  
340 - * @param int $paymentType 支付类型ID  
341 - * @param string $remark 留言  
342 - * @param string $couponCode 优惠券码  
343 - * @param mixed $yohoCoin 使用的YOHO币数量或为空  
344 - * @param int $isPreContact 送货前是否联系  
345 - * @param int $isPrintPrice 是否打印价格  
346 - * @param string|null $userAgent 联盟过来用户下单时需要的User-Agent信息  
347 - * @param int $redEnvelopes 红包  
348 - * @return array 接口返回的数据  
349 - */  
350 - public static function orderSub($uid, $addressId, $cartType, $deliveryTime, $deliveryWay, $invoiceTitle, $invoiceId,  
351 - $paymentId, $paymentType, $remark, $couponCode, $yohoCoin, $isPreContact, $isPrintPrice, $userAgent, $redEnvelopes)  
352 - {  
353 - $param = Yohobuy::param();  
354 - $param['debug'] = 'Y';  
355 - $param['client_type'] = 'web'; // 需要ERP统计PC的下单量  
356 - $param['private_key'] = Yohobuy::$privateKeyList['web']; // PC默认使用Android的私钥  
357 - $param['method'] = 'app.Shopping.submit';  
358 - $param['address_id'] = $addressId;  
359 - $param['cart_type'] = $cartType;  
360 - $param['delivery_time'] = $deliveryTime;  
361 - $param['delivery_way'] = $deliveryWay;  
362 - $param['uid'] = $uid;  
363 - if (!empty($invoiceTitle)) {  
364 - $param['invoices_title'] = $invoiceTitle;  
365 - }  
366 - if (!empty($invoiceId)) {  
367 - $param['invoices_type_id'] = $invoiceId;  
368 - }  
369 - if (!empty($redEnvelopes)) {  
370 - $param['use_red_envelopes'] = $redEnvelopes;  
371 - }  
372 - $param['payment_id'] = $paymentId;  
373 - $param['payment_type'] = $paymentType;  
374 - if (!empty($couponCode)) {  
375 - $param['coupon_code'] = $couponCode;  
376 - }  
377 - if (!empty($yohoCoin)) {  
378 - $param['use_yoho_coin'] = $yohoCoin;  
379 - }  
380 - if (!empty($isPreContact)) {  
381 - $param['is_pre_contact'] = 'Y';  
382 - }  
383 - if (!empty($isPrintPrice)) {  
384 - $param['is_print_price'] = 'Y';  
385 - }  
386 - $param['remark'] = $remark;  
387 - $param['client_secret'] = Sign::getSign($param);  
388 -  
389 - return Yohobuy::get(Yohobuy::API_URL, $param, false, false, 10, $userAgent);  
390 - }  
391 -  
392 - /**  
393 - * 购物车数量  
394 - *  
395 - * @param int $uid 用户ID  
396 - * @param string $shoppingKey 未登录用户唯一识别码  
397 - * @return array 购物车接口返回的数据  
398 - */  
399 - public static function cartCount($uid, $shoppingKey)  
400 - {  
401 - $param = Yohobuy::param();  
402 - $param['method'] = 'app.Shopping.count';  
403 - if (!empty($uid)) {  
404 - $param['uid'] = $uid;  
405 - }  
406 - if (!empty($shoppingKey)) {  
407 - $param['shopping_key'] = $shoppingKey;  
408 - }  
409 - $param['client_secret'] = Sign::getSign($param);  
410 -  
411 - return Yohobuy::get(Yohobuy::API_URL, $param);  
412 - }  
413 -  
414 - /**  
415 - * 凑单商品  
416 - *  
417 - * @param int $page 分页页码  
418 - * @return array  
419 - */  
420 - public static function togetherProduct($page)  
421 - {  
422 - $param = Yohobuy::param();  
423 - $param['method'] = 'web.product.together';  
424 - $param['client_type'] = 'web';  
425 - $param['private_key'] = Yohobuy::$privateKeyList['web'];  
426 - $param['page'] = $page;  
427 - $param['client_secret'] = Sign::getSign($param);  
428 -  
429 - return Yohobuy::get(Yohobuy::API_URL, $param);  
430 - }  
431 -  
432 - /**  
433 - * 浏览记录数据  
434 - *  
435 - * @param int $uid 用户ID  
436 - * @param int $udid 客户端唯一标识  
437 - * @param int $page 第几页,默认为1  
438 - * @param int $limit 限制多少条,默认100  
439 - * @return array 接口返回的数据  
440 - */  
441 - public static function browseRecord($uid, $udid, $page = 1, $limit = 10)  
442 - {  
443 - $param = Yohobuy::param();  
444 - $param['method'] = 'app.browse.product';  
445 - $param['uid'] = $uid;  
446 - $param['udid'] = $udid;  
447 - $param['page'] = $page;  
448 - $param['limit'] = $limit;  
449 - $param['client_secret'] = Sign::getSign($param);  
450 -  
451 - return Yohobuy::get(Yohobuy::API_URL, $param);  
452 - }  
453 -  
454 - /**  
455 - * 通过搜索查询商品信息  
456 - *  
457 - * 备注:因默认的搜索方法会有过滤, 浏览记录不需要过滤  
458 - *  
459 - * @param string $query 查询的条件  
460 - * @param int $limit 查询的限制数  
461 - * @return array  
462 - */  
463 - public static function browseRecordFromSearch($query, $limit = 10)  
464 - {  
465 - $param = array();  
466 - $param['order'] = 'shelve_time:desc';  
467 - $param['page'] = 1;  
468 - $param['viewNum'] = $limit;  
469 - $param['query'] = $query;  
470 -  
471 - return Yohobuy::get(SearchData::getUrl('search'), $param);  
472 - }  
473 -  
474 -} 1 +<?php
  2 +
  3 +namespace LibModels\Web\Home;
  4 +
  5 +use Api\Sign;
  6 +use Api\Yohobuy;
  7 +use LibModels\Web\Product\SearchData;
  8 +
  9 +/**
  10 + * 购物车的数据模型
  11 + *
  12 + * @name CartData
  13 + * @package LibModels/Web/Home
  14 + * @copyright yoho.inc
  15 + * @version 1.0 (2016-02-17 14:12:32)
  16 + * @author fei.hong <fei.hong@yoho.cn>
  17 + */
  18 +class CartData
  19 +{
  20 +
  21 + /**
  22 + * 加入购物车接口
  23 + *
  24 + * @param int $productSku 商品SKU
  25 + * @param int $buyNumber 购买数量
  26 + * @param int $goodsType 商品类型,0表示普通商品,1表示加价购商品
  27 + * @param int $isEdit 是否是编辑商品SKU,0表示不是编辑
  28 + * @param null|int $promotionId 促销id,默认null(加价购有关)
  29 + * @param null|int $uid 用户UID,可以不传
  30 + * @param string $shoppingKey 未登录用户唯一识别码,可以不传
  31 + * @return array 加入购物车接口返回的数据
  32 + */
  33 + public static function addToCart($productSku, $buyNumber, $goodsType, $isEdit = 0, $promotionId = null, $uid = null, $shoppingKey = null)
  34 + {
  35 + $param = Yohobuy::param();
  36 + $param['method'] = 'app.Shopping.add';
  37 + $param['product_sku'] = $productSku;
  38 + $param['buy_number'] = intval($buyNumber);
  39 + $param['goods_type'] = $goodsType;
  40 + $param['edit_product_sku'] = $isEdit;
  41 + $param['selected'] = 'Y';
  42 + $param['promotion_id'] = $promotionId;
  43 + if (!empty($uid)) {
  44 + $param['uid'] = $uid;
  45 + }
  46 + if (!empty($shoppingKey)) {
  47 + $param['shopping_key'] = $shoppingKey;
  48 + }
  49 + $param['client_secret'] = Sign::getSign($param);
  50 +
  51 + return Yohobuy::get(Yohobuy::API_URL, $param);
  52 + }
  53 +
  54 + /**
  55 + * 购物车商品选择与取消接口
  56 + *
  57 + * @param int $uid 用户ID
  58 + * @param string $sku 商品sku列表
  59 + * @param string $shoppingKey 未登录用户唯一识别码
  60 + * @param bool $hasPromotion 是否有促销ID
  61 + * @return array 购物车接口返回的数据
  62 + */
  63 + public static function selectGoods($uid, $sku, $shoppingKey, $hasPromotion = false)
  64 + {
  65 + $param = Yohobuy::param();
  66 + $param['method'] = $hasPromotion ? 'app.Shopping.selectedAndCart' : 'app.Shopping.selected';
  67 + $param['product_sku_list'] = $sku;
  68 + if (!empty($uid)) {
  69 + $param['uid'] = $uid;
  70 + }
  71 + if (!empty($shoppingKey)) {
  72 + $param['shopping_key'] = $shoppingKey;
  73 + }
  74 + $param['client_secret'] = Sign::getSign($param);
  75 +
  76 + return Yohobuy::get(Yohobuy::API_URL, $param);
  77 + }
  78 +
  79 + /**
  80 + * 购物车数据
  81 + *
  82 + * @param int $uid 用户ID
  83 + * @param string $shoppingKey 未登录用户唯一识别码
  84 + * @return array 购物车接口返回的数据
  85 + */
  86 + public static function cartData($uid, $shoppingKey)
  87 + {
  88 + $param = Yohobuy::param();
  89 + $param['method'] = 'app.Shopping.cart';
  90 + if (!empty($uid)) {
  91 + $param['uid'] = $uid;
  92 + }
  93 + if (!empty($shoppingKey)) {
  94 + $param['shopping_key'] = $shoppingKey;
  95 + }
  96 + $param['client_secret'] = Sign::getSign($param);
  97 +
  98 + return Yohobuy::get(Yohobuy::API_URL, $param);
  99 + }
  100 +
  101 + /**
  102 + * 移出购物车
  103 + *
  104 + * @param int $uid 用户ID
  105 + * @param string $sku 商品sku列表
  106 + * @param string $shoppingKey 未登录用户唯一识别码
  107 + * @param bool $hasPromotion 是否有促销ID
  108 + * @return array 接口返回的数据
  109 + */
  110 + public static function removeFromCart($uid, $sku, $shoppingKey, $hasPromotion = false)
  111 + {
  112 + $param = Yohobuy::param();
  113 + $param['method'] = $hasPromotion ? 'app.Shopping.removeAndCart' : 'app.Shopping.remove';
  114 + $param['product_sku_list'] = $sku;
  115 + if (!empty($uid)) {
  116 + $param['uid'] = $uid;
  117 + }
  118 + if (!empty($shoppingKey)) {
  119 + $param['shopping_key'] = $shoppingKey;
  120 + }
  121 + $param['client_secret'] = Sign::getSign($param);
  122 +
  123 + return Yohobuy::get(Yohobuy::API_URL, $param);
  124 + }
  125 +
  126 + /**
  127 + * 移入收藏夹
  128 + *
  129 + * @param int $uid 用户ID
  130 + * @param string $sku 商品sku列表
  131 + * @param bool $hasPromotion 是否有促销ID
  132 + * @return array 接口返回的数据
  133 + */
  134 + public static function addToFav($uid, $sku, $hasPromotion = false)
  135 + {
  136 + $param = Yohobuy::param();
  137 + $param['method'] = $hasPromotion ? 'app.Shopping.addfavoriteAndCart' : 'app.Shopping.addfavorite';
  138 + $param['product_sku_list'] = $sku;
  139 + $param['uid'] = $uid;
  140 + $param['client_secret'] = Sign::getSign($param);
  141 +
  142 + return Yohobuy::get(Yohobuy::API_URL, $param);
  143 + }
  144 +
  145 + /**
  146 + * 获取购物车商品详情数据
  147 + *
  148 + * @param int $uid 用户ID
  149 + * @param int $skn 商品skn
  150 + * @return array 接口返回的数据
  151 + */
  152 + public static function cartProductData($uid, $skn)
  153 + {
  154 + $param = Yohobuy::param();
  155 + $param['method'] = 'app.product.data';
  156 + $param['product_skn'] = $skn;
  157 + $param['showcomment'] = 'N';
  158 + $param['uid'] = $uid;
  159 + $param['client_secret'] = Sign::getSign($param);
  160 +
  161 + return Yohobuy::get(Yohobuy::API_URL, $param);
  162 + }
  163 +
  164 + /**
  165 + * 获取加价购商品详情数据
  166 + *
  167 + * @param int $skn 商品skn
  168 + * @param int $promotionId 加价购商品促销ID
  169 + * @return array 接口返回的数据
  170 + */
  171 + public static function giftProductData($skn, $promotionId)
  172 + {
  173 + $param = Yohobuy::param();
  174 + $param['method'] = 'app.product.gift';
  175 + $param['product_skn'] = $skn;
  176 + $param['promotion_id'] = $promotionId;
  177 + $param['client_secret'] = Sign::getSign($param);
  178 +
  179 + return Yohobuy::get(Yohobuy::API_URL, $param);
  180 + }
  181 +
  182 + /**
  183 + * 增减购物车商品数量
  184 + *
  185 + * @param int $uid 用户ID
  186 + * @param string $sku 商品SKU
  187 + * @param int $increaseNum 增加的数目
  188 + * @param int $decreaseNum 减少的数目
  189 + * @param string $shoppingKey 未登录用户唯一识别码
  190 + * @return array 接口返回的数据
  191 + */
  192 + public static function modifyProductNum($uid, $sku, $increaseNum, $decreaseNum, $shoppingKey)
  193 + {
  194 + $param = Yohobuy::param();
  195 + $param['product_sku'] = $sku;
  196 + // 增加
  197 + if (!empty($increaseNum)) {
  198 + $param['method'] = 'app.Shopping.increase';
  199 + $param['increase_number'] = intval($increaseNum);
  200 + }
  201 + // 减少
  202 + if (!empty($decreaseNum)) {
  203 + $param['method'] = 'app.Shopping.decrease';
  204 + $param['decrease_number'] = intval($decreaseNum);
  205 + }
  206 + if (!empty($uid)) {
  207 + $param['uid'] = $uid;
  208 + }
  209 + if (!empty($shoppingKey)) {
  210 + $param['shopping_key'] = $shoppingKey;
  211 + }
  212 + $param['client_secret'] = Sign::getSign($param);
  213 +
  214 + return Yohobuy::get(Yohobuy::API_URL, $param);
  215 + }
  216 +
  217 + /**
  218 + * 修改购物车商品数据
  219 + *
  220 + * @param int $uid 用户ID
  221 + * @param string $swapData 商品数据
  222 + * @param string $shoppingKey 未登录用户唯一识别码
  223 + * @return array 接口返回的数据
  224 + */
  225 + public static function modifyCartProduct($uid, $swapData, $shoppingKey)
  226 + {
  227 + $param = Yohobuy::param();
  228 + $param['method'] = 'app.Shopping.swap';
  229 + $param['swap_data'] = $swapData;
  230 + if (!empty($uid)) {
  231 + $param['uid'] = $uid;
  232 + }
  233 + if (!empty($shoppingKey)) {
  234 + $param['shopping_key'] = $shoppingKey;
  235 + }
  236 + $param['client_secret'] = Sign::getSign($param);
  237 +
  238 + return Yohobuy::get(Yohobuy::API_URL, $param);
  239 + }
  240 +
  241 + /**
  242 + * 购物车结算
  243 + *
  244 + * @param int $uid 用户ID
  245 + * @param string $cartType 购物车类型,ordinary表示普通购物车
  246 + * @param int $isUseYohoCoin 是否使用有货币,默认0不使用, 1使用
  247 + * @return array 接口返回的数据
  248 + */
  249 + public static function cartPay($uid, $cartType, $isUseYohoCoin = 0)
  250 + {
  251 + $param = Yohobuy::param();
  252 + $param['method'] = 'app.Shopping.payment';
  253 + $param['cart_type'] = $cartType;
  254 + $param['yoho_coin_mode'] = $isUseYohoCoin;
  255 + $param['uid'] = $uid;
  256 + $param['client_secret'] = Sign::getSign($param);
  257 +
  258 + return Yohobuy::get(Yohobuy::API_URL, $param);
  259 + }
  260 +
  261 + /**
  262 + * 购物车结算--支付方式和配送方式选择
  263 + *
  264 + * @param int $uid 用户ID
  265 + * @param string $cartType 购物车类型,ordinary表示普通购物车
  266 + * @param int $deliveryWay 配送方式,1表示普通快递,2表示顺丰速运
  267 + * @param int $paymentType 支付方式,1表示在线支付,2表示货到付款
  268 + * @param string $couponCode 优惠券码
  269 + * @param mixed $yohoCoin 使用的YOHO币数量
  270 + * @param int $redEnvelopes 红包
  271 + * @return array 接口返回的数据
  272 + */
  273 + public static function orderCompute($uid, $cartType, $deliveryWay, $paymentType, $couponCode, $yohoCoin, $redEnvelopes)
  274 + {
  275 + $param = Yohobuy::param();
  276 + $param['method'] = 'app.Shopping.compute';
  277 + $param['cart_type'] = $cartType;
  278 + $param['delivery_way'] = $deliveryWay;
  279 + $param['payment_type'] = $paymentType;
  280 + if (!empty($couponCode)) {
  281 + $param['coupon_code'] = $couponCode;
  282 + }
  283 + if (!empty($yohoCoin)) {
  284 + $param['use_yoho_coin'] = $yohoCoin;
  285 + }
  286 + if (!empty($redEnvelopes)) {
  287 + $param['use_red_envelopes'] = $redEnvelopes;
  288 + }
  289 + // 控制是否判断YOHO币超出订单金额
  290 + $param['check_yohocoin_amount'] = 'Y';
  291 + $param['uid'] = $uid;
  292 + $param['client_secret'] = Sign::getSign($param);
  293 +
  294 + return Yohobuy::get(Yohobuy::API_URL, $param);
  295 + }
  296 +
  297 + /**
  298 + * 购物车结算--使用优惠券
  299 + *
  300 + * @param int $uid 用户ID
  301 + * @param string $couponCode 优惠券代码
  302 + * @return array 接口返回的数据
  303 + */
  304 + public static function searchCoupon($uid, $couponCode)
  305 + {
  306 + $param = Yohobuy::param();
  307 + $param['method'] = 'app.Shopping.useCoupon';
  308 + $param['coupon_code'] = $couponCode;
  309 + $param['uid'] = $uid;
  310 + $param['client_secret'] = Sign::getSign($param);
  311 +
  312 + return Yohobuy::get(Yohobuy::API_URL, $param);
  313 + }
  314 +
  315 + /**
  316 + * 购物车结算--获取优惠券列表
  317 + *
  318 + * @param int $uid 用户ID
  319 + * @return array 接口返回的数据
  320 + */
  321 + public static function getCouponList($uid, $limit = 10)
  322 + {
  323 + $param = Yohobuy::param();
  324 + $param['method'] = 'app.coupons.lists';
  325 + $param['type'] = 'notuse';
  326 + $param['page'] = 1;
  327 + $param['limit'] = $limit;
  328 + $param['uid'] = $uid;
  329 + $param['client_secret'] = Sign::getSign($param);
  330 +
  331 + return Yohobuy::get(Yohobuy::API_URL, $param);
  332 + }
  333 +
  334 + /**
  335 + * 购物车结算--提交结算信息
  336 + *
  337 + * @param int $uid 用户ID
  338 + * @param int $addressId 地址ID
  339 + * @param string $cartType 购物车类型
  340 + * @param int $deliveryTime 寄送时间ID
  341 + * @param int $deliveryWay 寄送方式ID
  342 + * @param string $invoiceTitle 发票说明
  343 + * @param int $invoiceId 发票类型ID
  344 + * @param int $paymentId 支付方式ID
  345 + * @param int $paymentType 支付类型ID
  346 + * @param string $remark 留言
  347 + * @param string $couponCode 优惠券码
  348 + * @param mixed $yohoCoin 使用的YOHO币数量或为空
  349 + * @param int $isPreContact 送货前是否联系
  350 + * @param int $isPrintPrice 是否打印价格
  351 + * @param string|null $userAgent 联盟过来用户下单时需要的User-Agent信息
  352 + * @param int $redEnvelopes 红包
  353 + * @return array 接口返回的数据
  354 + */
  355 + public static function orderSub($uid, $addressId, $cartType, $deliveryTime, $deliveryWay, $invoiceTitle, $invoiceId,
  356 + $paymentId, $paymentType, $remark, $couponCode, $yohoCoin, $isPreContact, $isPrintPrice, $userAgent, $redEnvelopes)
  357 + {
  358 + $param = Yohobuy::param();
  359 + $param['debug'] = 'Y';
  360 + $param['client_type'] = 'web'; // 需要ERP统计PC的下单量
  361 + $param['private_key'] = Yohobuy::$privateKeyList['web']; // PC默认使用Android的私钥
  362 + $param['method'] = 'app.Shopping.submit';
  363 + $param['address_id'] = $addressId;
  364 + $param['cart_type'] = $cartType;
  365 + $param['delivery_time'] = $deliveryTime;
  366 + $param['delivery_way'] = $deliveryWay;
  367 + $param['uid'] = $uid;
  368 + if (!empty($invoiceTitle)) {
  369 + $param['invoices_title'] = $invoiceTitle;
  370 + }
  371 + if (!empty($invoiceId)) {
  372 + $param['invoices_type_id'] = $invoiceId;
  373 + }
  374 + if (!empty($redEnvelopes)) {
  375 + $param['use_red_envelopes'] = $redEnvelopes;
  376 + }
  377 + $param['payment_id'] = $paymentId;
  378 + $param['payment_type'] = $paymentType;
  379 + if (!empty($couponCode)) {
  380 + $param['coupon_code'] = $couponCode;
  381 + }
  382 + if (!empty($yohoCoin)) {
  383 + $param['use_yoho_coin'] = $yohoCoin;
  384 + }
  385 + if (!empty($isPreContact) && $isPreContact == 'true') {
  386 + $param['is_pre_contact'] = 'Y';
  387 + }
  388 + if (!empty($isPrintPrice) && $isPrintPrice == 'true') {
  389 + $param['is_print_price'] = 'Y';
  390 + }
  391 + $param['remark'] = $remark;
  392 + $param['client_secret'] = Sign::getSign($param);
  393 +
  394 + return Yohobuy::get(Yohobuy::API_URL, $param, false, false, 10, $userAgent);
  395 + }
  396 +
  397 + /**
  398 + * 购物车数量
  399 + *
  400 + * @param int $uid 用户ID
  401 + * @param string $shoppingKey 未登录用户唯一识别码
  402 + * @return array 购物车接口返回的数据
  403 + */
  404 + public static function cartCount($uid, $shoppingKey)
  405 + {
  406 + $param = Yohobuy::param();
  407 + $param['method'] = 'app.Shopping.count';
  408 + if (!empty($uid)) {
  409 + $param['uid'] = $uid;
  410 + }
  411 + if (!empty($shoppingKey)) {
  412 + $param['shopping_key'] = $shoppingKey;
  413 + }
  414 + $param['client_secret'] = Sign::getSign($param);
  415 +
  416 + return Yohobuy::get(Yohobuy::API_URL, $param);
  417 + }
  418 +
  419 + /**
  420 + * 凑单商品
  421 + *
  422 + * @param int $page 分页页码
  423 + * @return array
  424 + */
  425 + public static function togetherProduct($page)
  426 + {
  427 + $param = Yohobuy::param();
  428 + $param['method'] = 'web.product.together';
  429 + $param['client_type'] = 'web';
  430 + $param['private_key'] = Yohobuy::$privateKeyList['web'];
  431 + $param['page'] = $page;
  432 + $param['client_secret'] = Sign::getSign($param);
  433 +
  434 + return Yohobuy::get(Yohobuy::API_URL, $param);
  435 + }
  436 +
  437 + /**
  438 + * 浏览记录数据
  439 + *
  440 + * @param int $uid 用户ID
  441 + * @param int $udid 客户端唯一标识
  442 + * @param int $page 第几页,默认为1
  443 + * @param int $limit 限制多少条,默认100
  444 + * @return array 接口返回的数据
  445 + */
  446 + public static function browseRecord($uid, $udid, $page = 1, $limit = 10)
  447 + {
  448 + $param = Yohobuy::param();
  449 + $param['method'] = 'app.browse.product';
  450 + $param['uid'] = $uid;
  451 + $param['udid'] = $udid;
  452 + $param['page'] = $page;
  453 + $param['limit'] = $limit;
  454 + $param['client_secret'] = Sign::getSign($param);
  455 +
  456 + return Yohobuy::get(Yohobuy::API_URL, $param);
  457 + }
  458 +
  459 + /**
  460 + * 通过搜索查询商品信息
  461 + *
  462 + * 备注:因默认的搜索方法会有过滤, 浏览记录不需要过滤
  463 + *
  464 + * @param string $query 查询的条件
  465 + * @param int $limit 查询的限制数
  466 + * @return array
  467 + */
  468 + public static function browseRecordFromSearch($query, $limit = 10)
  469 + {
  470 + $param = array();
  471 + $param['order'] = 'shelve_time:desc';
  472 + $param['page'] = 1;
  473 + $param['viewNum'] = $limit;
  474 + $param['query'] = $query;
  475 +
  476 + return Yohobuy::get(SearchData::getUrl('search'), $param);
  477 + }
  478 +
  479 +}
@@ -92,16 +92,16 @@ @@ -92,16 +92,16 @@
92 </td> 92 </td>
93 </tr> 93 </tr>
94 {{# productItem}} 94 {{# productItem}}
95 - <tr class="pre-sell-box" {{#if pid}}data-pid="{{pid}}"{{/if}} {{#if id}}data-id="{{id}}"{{/if}} {{#if skn}}data-skn="{{skn}}"{{/if}} {{#if sku}}data-sku="{{sku}}"{{/if}} {{#if productNum}}data-productnum="{{productNum}}"{{/if}}> 95 + <tr class="pre-sell-box" {{#if pid}}data-pid="{{pid}}"{{/if}} {{#if id}}data-id="{{id}}"{{/if}} {{#if skn}}data-skn="{{skn}}"{{/if}} {{#if sku}}data-sku="{{sku}}"{{/if}} {{#if productNum}}data-productnum="{{productNum}}"{{/if}} {{#if goodsType}}data-goodstype="{{goodsType}}"{{/if}}>
96 <td> 96 <td>
97 <div class="pay-pro"> 97 <div class="pay-pro">
98 - <input class="cart-item-check" type="checkbox" name="" id="" {{#if isChecked}}checked{{/if}}/>  
99 - <a class="pay-pro-icon" href="{{link}}"> 98 + <input class="cart-item-check" type="checkbox" name="" id="" data-goodstype="{{goodsType}}" {{#if isChecked}}checked{{/if}}/>
  99 + <a class="pay-pro-icon" href="{{link}}" target="_blank">
100 <img src="{{imgCover}}"> 100 <img src="{{imgCover}}">
101 <span class="incentive">预售</span> 101 <span class="incentive">预售</span>
102 </a> 102 </a>
103 <p class="pay-pro-info"> 103 <p class="pay-pro-info">
104 - <a href="{{link}}">{{productTitle}}</a> 104 + <a href="{{link}}" target="_blank">{{productTitle}}</a>
105 <span>颜色:{{productColor}} 尺码:{{productSize}}</span> 105 <span>颜色:{{productColor}} 尺码:{{productSize}}</span>
106 <span class="presell">上市期:{{preSellDate}}</span> 106 <span class="presell">上市期:{{preSellDate}}</span>
107 </p> 107 </p>
@@ -110,9 +110,18 @@ @@ -110,9 +110,18 @@
110 <td class="productPrice">¥{{productPrice}}</td> 110 <td class="productPrice">¥{{productPrice}}</td>
111 <td>{{yohoIcon}}</td> 111 <td>{{yohoIcon}}</td>
112 <td class="adjust-cart-num"> 112 <td class="adjust-cart-num">
113 - <span class="minus"></span>  
114 - <input type="text" value="{{productNum}}" readonly="readonly"/>  
115 - <span class="plus"></span> 113 + {{#if isGift}}
  114 + <div>{{productNum}}</div>
  115 + {{^}}
  116 + {{#if isPriceGift}}
  117 + <div>{{productNum}}</div>
  118 + {{^}}
  119 + <span class="minus"></span>
  120 + <input type="text" value="{{productNum}}" readonly="readonly"/>
  121 + <span class="plus"></span>
  122 + <p class="tip-message {{#isTipNoStore}}tipNoStore{{/isTipNoStore}}">{{tipMessage}}</p>
  123 + {{/if}}
  124 + {{/if}}
116 </td> 125 </td>
117 <td class="sub-total">¥{{productSubtotal}}</td> 126 <td class="sub-total">¥{{productSubtotal}}</td>
118 <td class="cart-operation"> 127 <td class="cart-operation">
@@ -130,12 +139,10 @@ @@ -130,12 +139,10 @@
130 </td> 139 </td>
131 </tr> 140 </tr>
132 {{# productItem}} 141 {{# productItem}}
133 - <tr class="common-sell-box" {{#if pid}}data-pid="{{pid}}"{{/if}} {{#if id}}data-id="{{id}}"{{/if}} {{#if skn}}data-skn="{{skn}}"{{/if}} {{#if sku}}data-sku="{{sku}}"{{/if}} {{#if productNum}}data-productnum="{{productNum}}"{{/if}}> 142 + <tr class="common-sell-box" {{#if pid}}data-pid="{{pid}}"{{/if}} {{#if id}}data-id="{{id}}"{{/if}} {{#if skn}}data-skn="{{skn}}"{{/if}} {{#if sku}}data-sku="{{sku}}"{{/if}} {{#if productNum}}data-productnum="{{productNum}}"{{/if}} {{#if promotionId}}data-promotionid="{{promotionId}}"{{/if}} {{#if goodsType}}data-goodstype="{{goodsType}}"{{/if}}>
134 <td> 143 <td>
135 <div class="pay-pro"> 144 <div class="pay-pro">
136 - {{#unless isGift}}  
137 - <input class="cart-item-check" data-goodstype="{{goodsType}}" type="checkbox" name="" id="" {{#if isChecked}}checked{{/if}}/>  
138 - {{/unless}} 145 + <input class="cart-item-check {{#if isGift}}none{{/if}}" type="checkbox" name="" id="" {{#if isChecked}}checked{{/if}}/>
139 <a class="pay-pro-icon {{#if isGift}}giftInfo{{/if}}" href="{{link}}" target="_blank"> 146 <a class="pay-pro-icon {{#if isGift}}giftInfo{{/if}}" href="{{link}}" target="_blank">
140 <img src="{{imgCover}}"> 147 <img src="{{imgCover}}">
141 {{#isPriceGift}} 148 {{#isPriceGift}}
@@ -248,10 +255,13 @@ @@ -248,10 +255,13 @@
248 </p> 255 </p>
249 </div> 256 </div>
250 </td> 257 </td>
251 - <td style="width:13%;"><del style="margin-right: 5px;">{{marketPrice}}</del><span>¥{{subjoinPrice}}</span></td> 258 + <td style="width:13%;">
  259 + <del class="wapper-price" style="margin-right: 5px;"{{marketPrice}}</del>
  260 + <span class="subjoin-price"{{subjoinPrice}}</span>
  261 + </td>
252 <td style="width:7%;">{{yohoIcon}}</td> 262 <td style="width:7%;">{{yohoIcon}}</td>
253 <td style="width:10%;">1</td> 263 <td style="width:10%;">1</td>
254 - <td class="subjoin-price" style="width:10%;">¥{{subjoinPrice}}</td> 264 + <td style="width:10%;">¥{{subjoinPrice}}</td>
255 <td style="width:20%; border-right: none;"> 265 <td style="width:20%; border-right: none;">
256 {{#isPriceGift}} 266 {{#isPriceGift}}
257 <a href="javascript:void(0);" data-id="{{id}}" class="cart-add-btn order"><span></span></a> 267 <a href="javascript:void(0);" data-id="{{id}}" class="cart-add-btn order"><span></span></a>
@@ -271,7 +281,7 @@ @@ -271,7 +281,7 @@
271 <div class="dev-revocation {{#unless deleteShop}}none{{/unless}}"> 281 <div class="dev-revocation {{#unless deleteShop}}none{{/unless}}">
272 <table> 282 <table>
273 {{#deleteShop}} 283 {{#deleteShop}}
274 - <tr data-productnum="{{productNum}}" data-productsku="{{productSku}}"> 284 + <tr data-productnum="{{productNum}}" data-productsku="{{productSku}}" data-promotionid="{{promotionId}}">
275 <td style="width:40%; text-align: left;">成功删除<a class="title" href="{{link}}" target="_blank">{{productTitle}}</a></td> 285 <td style="width:40%; text-align: left;">成功删除<a class="title" href="{{link}}" target="_blank">{{productTitle}}</a></td>
276 <td style="width:10%;"><span class="productPrice">{{productPrice}}</span></td> 286 <td style="width:10%;"><span class="productPrice">{{productPrice}}</span></td>
277 <td style="width:10%;"></td> 287 <td style="width:10%;"></td>
1 -<div class="detail-header">  
2 - <span class="colse">X关闭</span>  
3 - </div>  
4 - <div class="detail-body">  
5 - <span class="magnify"></span>  
6 - {{#colors}}  
7 - <div class="detail-bigpic {{#unless focus}}none{{/unless}}">  
8 - {{#thumbs}}  
9 - <div class="bigpic">  
10 - <img src="{{shower}}">  
11 - </div>  
12 - {{/thumbs}}  
13 - <div class="piclist">  
14 - <span class="pre"></span>  
15 - <div class="con">  
16 - <ul>  
17 - {{#thumbs}}  
18 - <li><img src="{{img}}"></li>  
19 - {{/thumbs}}  
20 - </ul>  
21 - </div>  
22 - <span class="next"></span>  
23 - </div>  
24 - </div>  
25 - {{/colors}}  
26 - <div class="detail-info">  
27 - <div class="title">  
28 - <h2>{{name}}</h2>  
29 - </div>  
30 - <div class="type">  
31 - <span class="type-s">新品</span>  
32 - </div>  
33 - <div class="price">  
34 - {{#if salePrice}}  
35 - <span class="oldprice">原价:<del>{{marketPrice}}</del></span>  
36 - <span class="newprice">现价:<b class="promotion-price">{{salePrice}}</b></span>  
37 - {{^}}  
38 - <span class="newprice">原价:<b class="promotion-price">{{marketPrice}}</b></span>  
39 - {{/if}}  
40 - </div>  
41 - <div class="order">  
42 - <dl>  
43 - <dd class="colorBox">选颜色:</dd>  
44 - <dt>  
45 - <div class="colorBox">  
46 - <ul>  
47 - {{#colors}}  
48 - <li class="color">  
49 - <p class="{{#if focus}}atcive{{/if}}"><span></span><img src="{{src}}"></p>  
50 - <span>{{name}}</span>  
51 - </li>  
52 - {{/colors}}  
53 - </ul>  
54 - </div>  
55 - </dt>  
56 - <dd class="">选尺码:</dd>  
57 - <dt>  
58 - {{#colors}}  
59 - <div class="showSizeBox {{#unless focus}}none{{/unless}}">  
60 - {{#size}}  
61 - <span data-sku="{{sku}}" data-num="{{num}}">{{name}}</span>  
62 - {{/size}}  
63 - </div>  
64 - {{/colors}}  
65 - </dt>  
66 - <dd>选件数:</dd>  
67 - <dt>  
68 - <div class="amount_wrapper">  
69 - <i class="amount cut"></i>  
70 - <input type="text" id="mnum" class="mnum" value="1" readonly="readonly">  
71 - <i class="amount add"></i>  
72 -  
73 - </div>  
74 - </dt>  
75 - </dl>  
76 - </div>  
77 - <div class="submit">  
78 - <input class="addcart" type="button">  
79 - <input class="btn_pre_sale none" type="button">  
80 - <input class="btn_sellout none" type="button">  
81 - <input class="fav_count" type="button">  
82 - </div>  
83 - </div>  
84 -  
85 - <div class="detail-size">  
86 - <h3>尺码信息<span>(单位:厘米)</span></h3>  
87 - {{# size}}  
88 - <table>  
89 - <thead>  
90 - <tr>  
91 - {{# thead}}  
92 - <td width="{{width}}">{{name}}</td>  
93 - {{/ thead}}  
94 - </tr>  
95 - </thead>  
96 - <tbody>  
97 - {{# tbody}}  
98 - <tr>  
99 - {{#each .}}  
100 - <td>{{.}}</td>  
101 - {{/each}}  
102 - </tr>  
103 - {{/ tbody}}  
104 - </tbody>  
105 - </table>  
106 - {{/ size}}  
107 - <div class="size-info">  
108 - ※ 以上尺寸为实物实际测量,因测量方式不同会有略微误差,相关数据仅作参考,以收到实物为准。  
109 - </div>  
110 - </div>  
111 - </div>  
  1 +<div class="detail-header">
  2 + <span class="colse">X关闭</span>
  3 + </div>
  4 + <div class="detail-body">
  5 + <span class="magnify"></span>
  6 + {{#colors}}
  7 + <div class="detail-bigpic {{#unless focus}}none{{/unless}}">
  8 + {{#thumbs}}
  9 + <div class="bigpic">
  10 + <img src="{{shower}}">
  11 + </div>
  12 + {{/thumbs}}
  13 + <div class="piclist">
  14 + <span class="pre"></span>
  15 + <div class="con">
  16 + <ul>
  17 + {{#thumbs}}
  18 + <li><img src="{{img}}"></li>
  19 + {{/thumbs}}
  20 + </ul>
  21 + </div>
  22 + <span class="next"></span>
  23 + </div>
  24 + </div>
  25 + {{/colors}}
  26 + <div class="detail-info">
  27 + <div class="title">
  28 + <h2>{{name}}</h2>
  29 + </div>
  30 + <div class="type">
  31 + <span class="type-s">新品</span>
  32 + </div>
  33 + <div class="price">
  34 +
  35 + {{#if salePrice}}
  36 + <span class="oldprice">原价:<del>¥{{marketPrice}}</del></span>
  37 + <span class="newprice">现价:<b class="promotion-price">¥{{salePrice}}</b></span>
  38 + {{^}}
  39 + <span class="newprice {{#presalePrice}}none{{/presalePrice}}">原价:<b class="promotion-price">¥{{marketPrice}}</b></span>
  40 + {{/if}}
  41 +
  42 + {{#if presalePrice}}
  43 + <span class="oldprice">原价:<del>¥{{marketPrice}}</del></span>
  44 + <span class="newprice">预售价:<b class="promotion-price">¥{{presalePrice}}</b></span>
  45 + {{/if}}
  46 + {{#arrivalDate}}
  47 + <span class="arrivalDate">上市期:{{arrivalDate}}</span>
  48 + {{/arrivalDate}}
  49 + </div>
  50 + <div class="order">
  51 + <dl>
  52 + <dd class="colorBox">选颜色:</dd>
  53 + <dt>
  54 + <div class="colorBox">
  55 + <ul>
  56 + {{#colors}}
  57 + <li class="color">
  58 + <p class="{{#if focus}}atcive{{/if}}"><span></span><img src="{{src}}"></p>
  59 + <span>{{name}}</span>
  60 + </li>
  61 + {{/colors}}
  62 + </ul>
  63 + </div>
  64 + </dt>
  65 + <dd class="">选尺码:</dd>
  66 + <dt>
  67 + {{#colors}}
  68 + <div class="showSizeBox {{#unless focus}}none{{/unless}}">
  69 + {{#size}}
  70 + <span data-sku="{{sku}}" data-num="{{num}}">{{name}}</span>
  71 + {{/size}}
  72 + </div>
  73 + {{/colors}}
  74 + </dt>
  75 + <dd>选件数:</dd>
  76 + <dt>
  77 + <div class="amount_wrapper">
  78 + <i class="amount cut"></i>
  79 + <input type="text" id="mnum" class="mnum" value="1" readonly="readonly">
  80 + <i class="amount add"></i>
  81 +
  82 + </div>
  83 + </dt>
  84 + </dl>
  85 + </div>
  86 + <div class="submit">
  87 + <input class="addcart" type="button">
  88 + <input class="btn_pre_sale none" type="button">
  89 + <input class="btn_sellout none" type="button">
  90 + <input class="fav_count" type="button">
  91 + </div>
  92 + </div>
  93 +
  94 + <div class="detail-size">
  95 + <h3>尺码信息<span>(单位:厘米)</span></h3>
  96 + {{# size}}
  97 + <table>
  98 + <thead>
  99 + <tr>
  100 + {{# thead}}
  101 + <td width="{{width}}">{{name}}</td>
  102 + {{/ thead}}
  103 + </tr>
  104 + </thead>
  105 + <tbody>
  106 + {{# tbody}}
  107 + <tr>
  108 + {{#each .}}
  109 + <td>{{.}}</td>
  110 + {{/each}}
  111 + </tr>
  112 + {{/ tbody}}
  113 + </tbody>
  114 + </table>
  115 + {{/ size}}
  116 + <div class="size-info">
  117 + ※ 以上尺寸为实物实际测量,因测量方式不同会有略微误差,相关数据仅作参考,以收到实物为准。
  118 + </div>
  119 + </div>
  120 + </div>
  121 + <input value="{{addToCart}}" id="addToCart" type="hidden" />
1 -{{> layout/header}}  
2 -<div class="order-ensure-page yoho-page clearfix">  
3 -{{# orderEnsure}}  
4 - <div class="order-edit">  
5 - <div class="order-title">  
6 - <ul>  
7 - <li class="first">查看购物车</li>  
8 - <li class="active">填写订单</li>  
9 - <li class="end">付款,完成购买</li>  
10 - </ul>  
11 - </div>  
12 -  
13 - <div class="order-edit-main" id="order-edit-main" cartType="{{cartType}}">  
14 - <h2 class="title">请填写并核对以下信息  
15 - <a href="{{cartUrl}}" class="btn_backcart"></a>  
16 - </h2>  
17 - <div class="order-content">  
18 - <div class="order-selection address-list">  
19 - <h2>收货地址:<span>[修改]</span></h2>  
20 - <div class="address-list-inner">  
21 - <ul class="exist-address-list">  
22 - {{#each hasAddress}}  
23 - <li class="has-exist-address">  
24 - <input class="radio" type="radio" name="exist-address" id="{{id}}" {{#if checked}}checked{{/if}}/>  
25 - <label for="{{id}}">  
26 - <strong>{{user}}</strong>  
27 - <span>{{address}}</span>  
28 - <b class="default-address">设为默认地址</b>  
29 - <div class="order-modify-btn">  
30 - <span class="address-modify">[修改]</span>  
31 - <span class="address-del">[删除]</span>  
32 - </div>  
33 - </label>  
34 - </li>  
35 - {{/each}}  
36 -  
37 - <li class="use-new-address hide">  
38 - <input class="radio add-address" type="radio" name="address" id=""/>  
39 - <label for="">使用新地址</label>  
40 - </li>  
41 - </ul>  
42 -  
43 - <div class="address-manage hide" cart-type="{{cartType}}">  
44 - <ul>  
45 - <li>  
46 - <span class="address-legend"><i>*</i>收货人姓名:</span>  
47 - <input type="text" name="name" class="name text-input"/>  
48 - <span>请填写您的真实姓名,最多5个汉字</span>  
49 - </li>  
50 - <li>  
51 - <span class="address-legend"><i>*</i>省市:</span>  
52 - <select name="province" id="" class="text-input">  
53 - </select>  
54 - <select name="city" id="" class="text-input">  
55 - </select>  
56 - <select name="county" id="" class="text-input">  
57 - </select>  
58 - <input type="text" name="address" class="text-input"/>  
59 - <span>标'*'的为支持加急送的地区,请输入收货的详细地址</span>  
60 - </li>  
61 - <li>  
62 - <span class="address-legend"><i>*</i>手机号码:</span>  
63 - <input type="text" name="phone" class="text-input"/>  
64 - <span>填写正确手机号便于接收发货和收货通知</span>  
65 - </li>  
66 - <li>  
67 - <span class="address-legend">固定电话:</span>  
68 - <div class="address-tel-input">  
69 - <input type="text" name="tel-code" class="tel-lengend text-input"/>  
70 - <input type="text" name="tel" class="text-input"/>  
71 -  
72 - </div>  
73 - <span>如:010-12345678,固话和手机号至少填一项</span>  
74 - </li>  
75 - <li>  
76 - <span class="address-legend">电子邮件:</span>  
77 - <input type="text" name="mail" class="text-input"/>  
78 - <span>用来接收订单提醒邮件,便于您及时了解订单状态</span>  
79 - </li>  
80 - <li>  
81 - <span class="address-legend">邮编:</span>  
82 - <input type="text" name="code" class="text-input"/>  
83 - <span>请填写准确的邮编,以确保商品尽快送达</span>  
84 - </li>  
85 - </ul>  
86 - </div>  
87 - <span class="save-btn hide">保存并送到这个地址</span>  
88 - </div>  
89 - </div>  
90 -  
91 - <div class="order-selection pay-time">  
92 - <h2>支付及送货时间:<span class="switch-pay-modify">[修改]</span></h2>  
93 - <ul class="modity-pay-info">  
94 - <li>付款方式:<span>{{defaultPayWay}}</span></li>  
95 - {{#if isPreSell}}  
96 - <li class="prev-sell-item">发货时间:商品到货后立即发货</li>  
97 - {{/if}}  
98 - <li>送货时间:<span>{{defaultDelivery}}</span></li>  
99 - <li>送货前联系我:<span>否</span></li>  
100 - </ul>  
101 -  
102 - <div class="pay-time-modify hide">  
103 - <h3 class="pay-time-title">支付方式</h3>  
104 - <ul>  
105 - <li class="pay-dashed-hr pay-recommend">  
106 - <div class="pay-type-legend">  
107 - <input value="1" {{#if onlinePay.checked}} checked{{/if}} class="radio {{#if onlinePay.checked}}checked{{/if}}" name="pay-type" type="radio" id="" data-pay="{{onlinePay.paymentId}}"/>  
108 - <label for="">在线支付(推荐)</label>  
109 - </div>  
110 - <span class="pay-type-legend">查看支持在线支付的银行和平台</span>  
111 - <div class="support-type hide">  
112 - <h4>支持以下支付平台在线支付:</h4>  
113 - <ul>  
114 - {{#each supportLine}}  
115 - <li><img src="{{src}}" alt=""/></li>  
116 - {{/each}}  
117 - </ul>  
118 - <h4>支持以下银行在线支付:</h4>  
119 - <ul>  
120 - {{#each supportBank}}  
121 - <li><img src="{{src}}" alt=""/></li>  
122 - {{/each}}  
123 - </ul>  
124 - </div>  
125 - </li>  
126 -  
127 - <li>  
128 - {{#if supportDeliveryPay}}  
129 - <input value="2" {{#if deliveryPay.checked}}checked{{/if}} class="radio {{#if deliveryPay.checked}}checked{{/if}}" name="pay-type" type="radio" id="" data-pay="{{deliveryPay.paymentId}}"/>  
130 - {{/if}}  
131 - <label for="">货到付款</label>  
132 - <span class="pay-type-tips">注:订单中有限量商品、预售商品、化妆品或者订单金额超过10000元不可以选择货到付款。</span>  
133 - </li>  
134 - </ul>  
135 -  
136 - <h3>送货时间</h3>  
137 - <ul>  
138 - {{#each delivery}}  
139 - <li>  
140 - <input {{#if checked}}checked{{/if}} value={{id}} class="radio" name="pay-time-radio" type="radio" id="{{id}}"/>  
141 - <label for="">{{desc}}</label>  
142 - </li>  
143 - {{/each}}  
144 -  
145 - <li class="pay-dashed-hr pay-type-tips">声明:我们会努力按照您指定的时间配送,但因为天气、交通等各类因素影响,您的订单有可能会有延误现象,敬请谅解!</li>  
146 -  
147 - <li>  
148 - <span>送货前是否联系:</span>  
149 - <input value="Y" class="radio" name="call-me" type="radio" id=""/>  
150 - <label for="">是</label>  
151 - <input value="N" checked class="radio" name="call-me" type="radio" id=""/>  
152 - <label for="">否</label>  
153 - </li>  
154 - </ul>  
155 -  
156 - <span class="pay-btn">确定</span>  
157 - </div>  
158 - </div>  
159 -  
160 - <div class="order-selection select-express">  
161 - <h2>选择快递:</h2>  
162 - {{#each carriageList}}  
163 - <div class="express-list">  
164 - <input {{# checked}}checked{{/ checked}} class="radio" type="radio" name="carriagegroup" id="common-{{id}}" value="{{id}}"/>  
165 - <label for="common-express">{{name}}:&nbsp;&nbsp;运费 {{value}} {{desc}}</label>  
166 - </div>  
167 - {{/each}}  
168 - <div class="express-list express-tips">注:配送会由于天气,交通等不可抗拒的客观因素造成您收货时间延迟,请您知悉。  
169 - </div>  
170 - <div class="express-list hide is-sup"><a class="sf" target="_blank" href="sfUrl">您所选择的区域暂不在顺风派送范围内</a>,点击查看详情</div>  
171 - <div class="express-list sf hide">如您购买的商品为航空禁运品顺丰会用陆运的方式给你派送,预计3-5天送达,请您见谅</div>  
172 - </div>  
173 - </div>  
174 - </div>  
175 - </div>  
176 - <div class="order-pay">  
177 - <div class="pay-wapper">  
178 - <table>  
179 - <thead>  
180 - <tr>  
181 - <th style="width:40%;">  
182 - 商品信息  
183 - </th>  
184 - <th style="width:10%;">单价(元)</th>  
185 - <th style="width:10%;">返YOHO币</th>  
186 - <th style="width:10%;">数量</th>  
187 - <th style="width:10%;">小计(元)</th>  
188 - <th style="width:20%;">商品金额(元)</th>  
189 - </tr>  
190 - </thead>  
191 - <tbody>  
192 - {{#each orderProducts}}  
193 - <tr>  
194 - <td>  
195 - <div class="pay-pro">  
196 - <a class="pay-pro-icon" href="{{link}}"><img src="{{imgCover}}" /></a>  
197 - <p class="pay-pro-info">  
198 - <a href="{{link}}" target="_blank">{{productTitle}}</a>  
199 - <span>颜色:{{productColor}} 尺码:{{productSize}}</span>  
200 - </p>  
201 - </div>  
202 - </td>  
203 - <td>  
204 - {{productPrice}}  
205 - {{#isVipPrice}}  
206 - <span class="vipPrice">(VIP)</span>  
207 - {{/isVipPrice}}  
208 - </td>  
209 - <td>{{yohoIcon}}</td>  
210 - <td>{{productNum}}</td>  
211 - <td class="cart-sub-total {{#xForOne}}xforone{{/xForOne}}">  
212 - {{#if xForOne}}  
213 - <del>{{productSubtotal}}</del>  
214 - <span class="free"></span>  
215 - {{^}}  
216 - {{productSubtotal}}  
217 - {{/if}}  
218 - </td>  
219 - <td class="cart-sub-total-all">{{productSubtotal}}</td>  
220 - </tr>  
221 - {{/each}}  
222 - </tbody>  
223 - </table>  
224 - <!--YOHO-->  
225 - <div class="play-content clearfix">  
226 - <div class="play-left">  
227 - <dl class="play-piao-pan pan">  
228 - <dt>索要发票</dt>  
229 - <dd>  
230 - <div class="play-pan">  
231 - <ul>  
232 - <li><label>发票抬头 :</label><input type="text" class="textbox" id="piaodesc" /></li>  
233 - <li><label>发票类型 :</label> <select class="dropdown" id="piaotype">  
234 - <option value="0">请选择</option>  
235 - {{#each piaoTypes}}  
236 - <option value="{{id}}">{{name}}</option>  
237 - {{/each}}  
238 - </select> </li>  
239 - </ul>  
240 - </div>  
241 - </dd>  
242 - </dl>  
243 - <dl class="play-remark-pan pan">  
244 - <dt>添加备注信息</dt>  
245 - <dd>  
246 - <div class="play-pan">  
247 - <textarea class="textbox" id="notedesc"></textarea>  
248 - <p class="note">声明:备注中有关收货人信息、支付方式、配送方式、发票信息等购买要求一律以上面的选择为准,备注无效。</p>  
249 - <p>是否打印价格:  
250 - <input name="isPP" id="isPPY" type="radio" value="Y" checked="">  
251 - <label for="isPPY">是</label>  
252 - <input name="isPP" id="isPPN" type="radio" value="N">  
253 - <label for="isPPN">否</label>  
254 - (如:送朋友的商品可不打印价格哦!)  
255 - </p>  
256 - </div>  
257 - </dd>  
258 - </dl>  
259 - </div>  
260 - <div class="play-right">  
261 - <ul class="play-total">  
262 - {{#each promotionFormulaList}}  
263 - <li class="{{#if isExpress}}total-express-w{{/if}}">  
264 - <label>{{promotion}}</label><em>{{promotionAmount}}</em>  
265 - </li>  
266 - {{/each}}  
267 - </ul>  
268 -  
269 - {{#if showCouponPay}}  
270 - <dl class="play-juan-pan pan">  
271 - <dt>使用优惠卷支付</dt>  
272 - <dd>  
273 - <div class="play-pan">  
274 - <p class="strong">请选择您要使用的优惠券: </p>  
275 - <p class="strong orange">(OUTLET商品除免邮券外不可使用优惠券)</p>  
276 - <p class="strong orange">(订单中使用优惠券将不赠送商品返还的YOHO币)</p>  
277 - <div class="play-juan">  
278 - <ul>  
279 - <li>  
280 - <input checked name="juangroup" type="radio" value="">  
281 - <label>直接输入优惠码: </label>  
282 - <input type="text" class="textbox" id="juancode" />  
283 - </li>  
284 - </ul>  
285 - </div>  
286 -  
287 - <p class="errtip red"></p>  
288 - <div class="btn-group clearfix">  
289 - <input type="button" class="ok" value="确定" id="juansubmit"/>  
290 - <input type="button" class="cancel cancel-code" value="取消"/>  
291 - </div>  
292 - </div>  
293 - </dd>  
294 - </dl>  
295 - {{/if}}  
296 - <dl class="play-bi-pan pan">  
297 - <dt>使用YOHO币支付</dt>  
298 - <dd>  
299 - <div class="play-pan">  
300 - <div class="strong">  
301 - 使用YOHO币:  
302 - <input type="text" class="textbox" id="biprice" data-bi="{{ownYohoCoin}}" value="0" />  
303 - </div>  
304 - <p >  
305 - 您目前有YOHO币 <em class="strong">{{ownYohoCoin}}</em>  
306 - </p>  
307 - <p class="errbitip red"></p>  
308 - <div class="btn-group clearfix">  
309 - <input type="button" class="ok" value="确定" id="bisubmit"/>  
310 - <input type="button" class="cancel cancel-bi" value="取消"/>  
311 - </div>  
312 - </div>  
313 - </dd>  
314 - </dl>  
315 -  
316 - {{# redEnvelopes}}  
317 - <div class="red-envelopes active">  
318 - <div class="use-envelopes">  
319 - <input checked value="0" data-use="{{.}}" type="checkbox" />使用现金红包支付:<span>-¥{{.}}</span>  
320 - </div>  
321 - <div class="has-envelopes">您的现金红包余额:<span>0.00</span></div>  
322 - </div>  
323 - {{/ redEnvelopes}}  
324 - </div>  
325 - </div>  
326 - </div>  
327 -  
328 - <div class="to-play">  
329 - <p>您需要实际支付金额:<em>{{lastOrderAmount}}</em>元</p>  
330 - <div class="btn-group clearfix">  
331 - <input type="button" class="submit" value="去付款"/>  
332 - </div>  
333 - </div>  
334 - </div>  
335 -{{/ orderEnsure}}  
336 -<div class="loading"><span></span>请稍后...</div>  
337 -</div> 1 +{{> layout/header}}
  2 +<div class="order-ensure-page yoho-page clearfix">
  3 +{{# orderEnsure}}
  4 + <div class="order-edit">
  5 + <div class="order-title">
  6 + <ul>
  7 + <li class="first">查看购物车</li>
  8 + <li class="active">填写订单</li>
  9 + <li class="end">付款,完成购买</li>
  10 + </ul>
  11 + </div>
  12 +
  13 + <div class="order-edit-main" id="order-edit-main" {{#isNewUser}}data-new="new"{{/isNewUser}} cartType="{{cartType}}">
  14 + <h2 class="title">请填写并核对以下信息
  15 + <a href="{{cartUrl}}" class="btn_backcart"></a>
  16 + </h2>
  17 + <div class="order-content">
  18 + <div class="order-selection address-list">
  19 + <h2>收货地址:<span>[修改]</span></h2>
  20 + <div class="address-list-inner">
  21 + <ul class="exist-address-list">
  22 + {{#each hasAddress}}
  23 + <li class="has-exist-address">
  24 + <input class="radio" type="radio" name="exist-address" id="{{id}}" {{#if checked}}checked{{/if}}/>
  25 + <label for="{{id}}">
  26 + <strong>{{user}}</strong>
  27 + <span>{{address}}</span>
  28 + <b class="default-address">设为默认地址</b>
  29 + <div class="order-modify-btn">
  30 + <span class="address-modify">[修改]</span>
  31 + <span class="address-del">[删除]</span>
  32 + </div>
  33 + </label>
  34 + </li>
  35 + {{/each}}
  36 +
  37 + <li class="use-new-address hide">
  38 + <input class="radio add-address" type="radio" name="address" id=""/>
  39 + <label for="">使用新地址</label>
  40 + </li>
  41 + </ul>
  42 +
  43 + <div class="address-manage hide" cart-type="{{cartType}}">
  44 + <ul>
  45 + <li>
  46 + <span class="address-legend"><i>*</i>收货人姓名:</span>
  47 + <input type="text" name="name" class="name text-input"/>
  48 + <span>请填写您的真实姓名,最多5个汉字</span>
  49 + </li>
  50 + <li>
  51 + <span class="address-legend"><i>*</i>省市:</span>
  52 + <select name="province" id="" class="text-input">
  53 + </select>
  54 + <select name="city" id="" class="text-input">
  55 + </select>
  56 + <select name="county" id="" class="text-input">
  57 + </select>
  58 + <input type="text" name="address" class="text-input"/>
  59 + <span>标'*'的为支持加急送的地区,请输入收货的详细地址</span>
  60 + </li>
  61 + <li>
  62 + <span class="address-legend"><i>*</i>手机号码:</span>
  63 + <input type="text" name="phone" class="text-input"/>
  64 + <span>填写正确手机号便于接收发货和收货通知</span>
  65 + </li>
  66 + <li>
  67 + <span class="address-legend">固定电话:</span>
  68 + <div class="address-tel-input">
  69 + <input type="text" name="tel-code" class="tel-lengend text-input"/>
  70 + <input type="text" name="tel" class="text-input"/>
  71 +
  72 + </div>
  73 + <span>如:010-12345678,固话和手机号至少填一项</span>
  74 + </li>
  75 + <li>
  76 + <span class="address-legend">电子邮件:</span>
  77 + <input type="text" name="mail" class="text-input"/>
  78 + <span>用来接收订单提醒邮件,便于您及时了解订单状态</span>
  79 + </li>
  80 + <li>
  81 + <span class="address-legend">邮编:</span>
  82 + <input type="text" name="code" class="text-input"/>
  83 + <span>请填写准确的邮编,以确保商品尽快送达</span>
  84 + </li>
  85 + </ul>
  86 + </div>
  87 + <span class="save-btn hide">保存并送到这个地址</span>
  88 + </div>
  89 + </div>
  90 +
  91 + <div class="order-selection pay-time">
  92 + <h2>支付及送货时间:<span class="switch-pay-modify">[修改]</span></h2>
  93 + <ul class="modity-pay-info">
  94 + <li>付款方式:<span>{{defaultPayWay}}</span></li>
  95 + {{#if isPreSell}}
  96 + <li class="prev-sell-item">发货时间:商品到货后立即发货</li>
  97 + {{/if}}
  98 + <li>送货时间:<span>{{defaultDelivery}}</span></li>
  99 + <li>送货前联系我:<span>否</span></li>
  100 + </ul>
  101 +
  102 + <div class="pay-time-modify hide">
  103 + <h3 class="pay-time-title">支付方式</h3>
  104 + <ul>
  105 + <li class="pay-dashed-hr pay-recommend">
  106 + <div class="pay-type-legend">
  107 + <input value="1" {{#if onlinePay.checked}} checked{{/if}} class="radio {{#if onlinePay.checked}}checked{{/if}}" name="pay-type" type="radio" id="" data-pay="{{onlinePay.paymentId}}"/>
  108 + <label for="">在线支付(推荐)</label>
  109 + </div>
  110 + <span class="pay-type-legend">查看支持在线支付的银行和平台</span>
  111 + <div class="support-type hide">
  112 + <h4>支持以下支付平台在线支付:</h4>
  113 + <ul>
  114 + {{#each supportLine}}
  115 + <li><img src="{{src}}" alt=""/></li>
  116 + {{/each}}
  117 + </ul>
  118 + <h4>支持以下银行在线支付:</h4>
  119 + <ul>
  120 + {{#each supportBank}}
  121 + <li><img src="{{src}}" alt=""/></li>
  122 + {{/each}}
  123 + </ul>
  124 + </div>
  125 + </li>
  126 +
  127 + <li>
  128 + {{#if supportDeliveryPay}}
  129 + <input value="2" {{#if deliveryPay.checked}}checked{{/if}} class="radio {{#if deliveryPay.checked}}checked{{/if}}" name="pay-type" type="radio" id="" data-pay="{{deliveryPay.paymentId}}"/>
  130 + {{/if}}
  131 + <label for="">货到付款</label>
  132 + <span class="pay-type-tips">注:订单中有限量商品、预售商品、化妆品或者订单金额超过10000元不可以选择货到付款。</span>
  133 + </li>
  134 + </ul>
  135 +
  136 + <h3>送货时间</h3>
  137 + <ul>
  138 + {{#each delivery}}
  139 + <li>
  140 + <input {{#if checked}}checked{{/if}} value={{id}} class="radio" name="pay-time-radio" type="radio" id="{{id}}"/>
  141 + <label for="">{{desc}}</label>
  142 + </li>
  143 + {{/each}}
  144 +
  145 + <li class="pay-dashed-hr pay-type-tips">声明:我们会努力按照您指定的时间配送,但因为天气、交通等各类因素影响,您的订单有可能会有延误现象,敬请谅解!</li>
  146 +
  147 + <li>
  148 + <span>送货前是否联系:</span>
  149 + <input value="Y" class="radio" name="call-me" type="radio" id=""/>
  150 + <label for="">是</label>
  151 + <input value="N" checked class="radio" name="call-me" type="radio" id=""/>
  152 + <label for="">否</label>
  153 + </li>
  154 + </ul>
  155 +
  156 + <span class="pay-btn">确定</span>
  157 + </div>
  158 + </div>
  159 +
  160 + <div class="order-selection select-express">
  161 + <h2>选择快递:</h2>
  162 + {{#each carriageList}}
  163 + <div class="express-list">
  164 + <input {{# checked}}checked{{/ checked}} class="radio" type="radio" name="carriagegroup" id="common-{{id}}" value="{{id}}"/>
  165 + <label for="common-express">{{name}}:&nbsp;&nbsp;运费 {{value}} {{desc}}</label>
  166 + </div>
  167 + {{/each}}
  168 + <div class="express-list express-tips">注:配送会由于天气,交通等不可抗拒的客观因素造成您收货时间延迟,请您知悉。
  169 + </div>
  170 + <div class="express-list hide is-sup"><span class="sf">您所选择的区域暂不在顺风派送范围内,</span><a style="text-decoration: none;" target="_blank" href="{{sfUrl}}">点击查看详情</a></div>
  171 + <div class="express-list sf hide">如您购买的商品为航空禁运品顺丰会用陆运的方式给你派送,预计3-5天送达,请您见谅</div>
  172 + </div>
  173 + </div>
  174 + </div>
  175 + </div>
  176 + <div class="order-pay">
  177 + <div class="pay-wapper">
  178 + <table>
  179 + <thead>
  180 + <tr>
  181 + <th style="width:40%;">
  182 + 商品信息
  183 + </th>
  184 + <th style="width:10%;">单价(元)</th>
  185 + <th style="width:10%;">返YOHO币</th>
  186 + <th style="width:10%;">数量</th>
  187 + <th style="width:10%;">小计(元)</th>
  188 + <th style="width:20%;">商品金额(元)</th>
  189 + </tr>
  190 + </thead>
  191 + <tbody>
  192 + {{#each orderProducts}}
  193 + <tr>
  194 + <td>
  195 + <div class="pay-pro">
  196 + <a class="pay-pro-icon" href="{{link}}">
  197 + <img src="{{imgCover}}" />
  198 + {{#isPriceGift}}
  199 + <span class="incentive">加价购</span>
  200 + {{/isPriceGift}}
  201 + {{#isGift}}
  202 + <span class="gift">赠品</span>
  203 + {{/isGift}}
  204 + </a>
  205 + <p class="pay-pro-info">
  206 + <a href="{{link}}" target="_blank">{{productTitle}}</a>
  207 + <span>颜色:{{productColor}} 尺码:{{productSize}}</span>
  208 + </p>
  209 + </div>
  210 + </td>
  211 + <td>
  212 + {{productPrice}}
  213 + {{#isVipPrice}}
  214 + <span class="vipPrice">(VIP)</span>
  215 + {{/isVipPrice}}
  216 + </td>
  217 + <td>{{yohoIcon}}</td>
  218 + <td>{{productNum}}</td>
  219 + <td class="cart-sub-total {{#xForOne}}xforone{{/xForOne}}">
  220 + {{#if xForOne}}
  221 + <del>{{productSubtotal}}</del>
  222 + <span class="free"></span>
  223 + {{^}}
  224 + {{productSubtotal}}
  225 + {{/if}}
  226 + </td>
  227 + <td class="cart-sub-total-all">{{productSubtotal}}</td>
  228 + </tr>
  229 + {{/each}}
  230 + </tbody>
  231 + </table>
  232 + <!--YOHO-->
  233 + <div class="play-content clearfix">
  234 + <div class="play-left">
  235 + <dl class="play-piao-pan pan">
  236 + <dt>索要发票</dt>
  237 + <dd>
  238 + <div class="play-pan">
  239 + <ul>
  240 + <li><label>发票抬头 :</label><input type="text" class="textbox" id="piaodesc" /></li>
  241 + <li><label>发票类型 :</label> <select class="dropdown" id="piaotype">
  242 + <option value="0">请选择</option>
  243 + {{#each piaoTypes}}
  244 + <option value="{{id}}">{{name}}</option>
  245 + {{/each}}
  246 + </select> </li>
  247 + </ul>
  248 + </div>
  249 + </dd>
  250 + </dl>
  251 + <dl class="play-remark-pan pan">
  252 + <dt>添加备注信息</dt>
  253 + <dd>
  254 + <div class="play-pan">
  255 + <textarea class="textbox" id="notedesc"></textarea>
  256 + <p class="note">声明:备注中有关收货人信息、支付方式、配送方式、发票信息等购买要求一律以上面的选择为准,备注无效。</p>
  257 + <p>是否打印价格:
  258 + <input name="isPP" id="isPPY" type="radio" value="Y" checked="">
  259 + <label for="isPPY">是</label>
  260 + <input name="isPP" id="isPPN" type="radio" value="N">
  261 + <label for="isPPN">否</label>
  262 + (如:送朋友的商品可不打印价格哦!)
  263 + </p>
  264 + </div>
  265 + </dd>
  266 + </dl>
  267 + </div>
  268 + <div class="play-right">
  269 + <ul class="play-total">
  270 + {{#each promotionFormulaList}}
  271 + <li class="{{#if isExpress}}total-express-w{{/if}}">
  272 + <label>{{promotion}}</label><em>{{promotionAmount}}</em>
  273 + </li>
  274 + {{/each}}
  275 + </ul>
  276 +
  277 + {{#if showCouponPay}}
  278 + <dl class="play-juan-pan pan">
  279 + <dt>使用优惠券支付</dt>
  280 + <dd>
  281 + <div class="play-pan">
  282 + <p class="strong">请选择您要使用的优惠券: </p>
  283 + <p class="strong orange">(OUTLET商品除免邮券外不可使用优惠券)</p>
  284 + <p class="strong orange">(订单中使用优惠券将不赠送商品返还的YOHO币)</p>
  285 + <div class="play-juan">
  286 + <ul>
  287 + <li>
  288 + <input checked name="juangroup" type="radio" value="">
  289 + <label>直接输入优惠码: </label>
  290 + <input type="text" class="textbox" id="juancode" />
  291 + </li>
  292 + </ul>
  293 + </div>
  294 +
  295 + <p class="errtip red"></p>
  296 + <div class="btn-group clearfix">
  297 + <input type="button" class="ok" value="确定" id="juansubmit"/>
  298 + <input type="button" class="cancel cancel-code" value="取消"/>
  299 + </div>
  300 + </div>
  301 + </dd>
  302 + </dl>
  303 + {{/if}}
  304 + <dl class="play-bi-pan pan">
  305 + <dt>使用YOHO币支付</dt>
  306 + <dd>
  307 + <div class="play-pan">
  308 + <div class="strong">
  309 + 使用YOHO币:
  310 + <input type="text" class="textbox" id="biprice" data-bi="{{ownYohoCoin}}" value="0" />
  311 + </div>
  312 + <p >
  313 + 您目前有YOHO币 <em class="strong">{{ownYohoCoin}}</em>
  314 + </p>
  315 + <p class="errbitip red"></p>
  316 + <div class="btn-group clearfix">
  317 + <input type="button" class="ok" value="确定" id="bisubmit"/>
  318 + <input type="button" class="cancel cancel-bi" value="取消"/>
  319 + </div>
  320 + </div>
  321 + </dd>
  322 + </dl>
  323 +
  324 + {{#if redEnvelopes}}
  325 + <div class="red-envelopes active">
  326 + <div class="use-envelopes">
  327 + <input checked value="0" data-all="{{redEnvelopes}}" data-use="{{useRedEnvelopes}}" type="checkbox" />使用现金红包支付:<span>-¥{{useRedEnvelopes}}</span>
  328 + </div>
  329 + <div class="has-envelopes">您的现金红包余额:<span></span></div>
  330 + </div>
  331 + {{/if}}
  332 + </div>
  333 + </div>
  334 + </div>
  335 +
  336 + <div class="to-play">
  337 + <p>您需要实际支付金额:<em>{{lastOrderAmount}}</em>元</p>
  338 + <div class="btn-group clearfix">
  339 + <input type="button" class="submit" value="去付款"/>
  340 + </div>
  341 + </div>
  342 + </div>
  343 +{{/ orderEnsure}}
  344 +<div class="loading"><span></span>请稍后...</div>
  345 +</div>
338 {{> layout/footer}} 346 {{> layout/footer}}
1 -*.iml  
2 -.idea/  
3 -.ipr  
4 -.iws  
5 -*~  
6 -~*  
7 -*.diff  
8 -*.patch  
9 -*.bak  
10 -.DS_Store  
11 -Thumbs.db  
12 -.project  
13 -.*proj  
14 -.svn/  
15 -*.swp  
16 -*.swo  
17 -*.pyc  
18 -*.pyo  
19 -.build  
20 -node_modules  
21 -_site  
22 -sea-modules  
23 -spm_modules  
24 -.cache  
25 -dist  
26 -coverage  
27 -css/  
28 -.sass-cache/  
29 -script/nginx/logs/  
30 -*.DS_Store  
  1 +*.iml
  2 +.idea/
  3 +.ipr
  4 +.iws
  5 +*~
  6 +~*
  7 +*.diff
  8 +*.patch
  9 +*.bak
  10 +.DS_Store
  11 +Thumbs.db
  12 +.project
  13 +.*proj
  14 +.svn/
  15 +*.swp
  16 +*.swo
  17 +*.pyc
  18 +*.pyo
  19 +.build
  20 +node_modules
  21 +_site
  22 +sea-modules
  23 +spm_modules
  24 +.cache
  25 +dist
  26 +coverage
  27 +# 只忽略当前目录下的css目录,子目录的不忽略
  28 +css/*
  29 +.sass-cache/
  30 +script/nginx/logs/
  31 +*.DS_Store
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
@@ -2,7 +2,7 @@ @@ -2,7 +2,7 @@
2 <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" > 2 <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" >
3 <svg xmlns="http://www.w3.org/2000/svg"> 3 <svg xmlns="http://www.w3.org/2000/svg">
4 <metadata> 4 <metadata>
5 -Created by FontForge 20120731 at Wed Mar 2 13:38:33 2016 5 +Created by FontForge 20120731 at Wed Mar 9 20:06:33 2016
6 By Ads 6 By Ads
7 </metadata> 7 </metadata>
8 <defs> 8 <defs>
@@ -161,10 +161,9 @@ l-531 -530l-70 70zM748 686z" /> @@ -161,10 +161,9 @@ l-531 -530l-70 70zM748 686z" />
161 <glyph glyph-name="uniE62E" unicode="&#xe62e;" horiz-adv-x="1025" 161 <glyph glyph-name="uniE62E" unicode="&#xe62e;" horiz-adv-x="1025"
162 d="M491 6q9 -10 21.5 -10t21.5 10l357 407q4 5 5.5 9.5t0 8t-6 5.5t-11.5 2h-133q-14 0 -23.5 9.5t-9.5 22.5v261q0 9 -4.5 16.5t-12.5 11.5t-17 4h-333q-14 0 -24 -9.5t-10 -22.5v-261q0 -13 -9.5 -22.5t-23.5 -9.5h-133q-14 0 -17.5 -7.5t5.5 -17.5z" /> 162 d="M491 6q9 -10 21.5 -10t21.5 10l357 407q4 5 5.5 9.5t0 8t-6 5.5t-11.5 2h-133q-14 0 -23.5 9.5t-9.5 22.5v261q0 9 -4.5 16.5t-12.5 11.5t-17 4h-333q-14 0 -24 -9.5t-10 -22.5v-261q0 -13 -9.5 -22.5t-23.5 -9.5h-133q-14 0 -17.5 -7.5t5.5 -17.5z" />
163 <glyph glyph-name="uniE62F" unicode="&#xe62f;" 163 <glyph glyph-name="uniE62F" unicode="&#xe62f;"
164 -d="M512 832v-1v1q-51 0 -99 -11t-92.5 -33.5t-71 -38.5t-67.5 -45v-396q0 -50 17 -97t42.5 -82t60.5 -66.5t66.5 -52.5t64.5 -38t50.5 -24.5t28.5 -11.5q7 3 17 7t29 12.5t39 19.5t44.5 26t47.5 33.5t46 40t42 47.5t34 54.5t23 62t8 69.5v396q-23 16 -36.5 25t-38.5 24.5  
165 -t-43.5 24.5t-46 20.5t-51.5 18t-54 11t-60 4.5zM772 308q0 -128 -130 -223q-65 -47 -130 -72q-65 25 -130 72q-44 32 -72.5 66.5t-43 73.5t-14.5 83v371q76 46 128.5 65t131.5 20q79 -1 131.5 -20t128.5 -65v-371zM512 710q-59 0 -99 -11t-105 -43v-351q0 -28 8 -53.5  
166 -t22.5 -46t30 -37.5t36.5 -31t36 -23.5t33.5 -18t24.5 -11t13 -4.5q9 3 16.5 6t30 14t40.5 22.5t41 31t38.5 40.5t26.5 50.5t11 60.5v351q-27 13 -46 21.5t-38 15.5t-37 10.5t-38 5t-45 1.5v0zM648 573v-42h-92v-58h81v-54h-81v-67h102v-50h-292v50h37v147h57v-147h39v179  
167 -h-121v54h270v-12z" /> 164 +d="M512 809v0q-58 0 -112.5 -12t-105.5 -38t-80.5 -44t-77.5 -51v-450q0 -57 19.5 -110.5t49 -93.5t69 -76t75.5 -59.5t73.5 -43t57 -28t32.5 -12.5q13 4 32.5 12.5t57 28t73.5 43t75.5 59.5t69 76t49 93.5t19.5 110.5v450q-48 33 -77.5 51t-80.5 44t-105.5 38t-112.5 12z
  165 +M808 214q0 -76 -36.5 -138t-112.5 -117q-39 -28 -78.5 -49.5t-68.5 -32.5q-74 29 -147 82q-76 55 -112.5 117t-36.5 138v421q87 53 146.5 75t149.5 23q90 -1 149.5 -23t146.5 -75v-421zM512 671q-46 0 -81.5 -6t-67.5 -18.5t-83 -37.5v-399q0 -35 12.5 -68.5t30 -57.5
  166 +t44 -46t47 -35.5t46 -26t34 -16t18.5 -6.5q10 3 18.5 6.5t34 16t46 26t47 35.5t44 46t30 57.5t12.5 68.5v399q-74 37 -119.5 49.5t-112.5 12.5v0zM667 515v-47h-105v-67h92v-61h-92v-77h116v-57h-332v57h42v168h64v-168h46v205h-138v61h307v-14z" />
168 <glyph glyph-name="uniE630" unicode="&#xe630;" horiz-adv-x="1163" 167 <glyph glyph-name="uniE630" unicode="&#xe630;" horiz-adv-x="1163"
169 d="M295 196q67 0 114 -47t47 -113.5t-47 -114t-114 -47.5t-114 47.5t-47 113.5q0 44 21.5 81t58.5 58.5t81 21.5zM917 196q67 0 114 -47t47 -114q0 -32 -12.5 -62t-34 -51.5t-51.5 -34.5t-63 -13q-66 0 -113.5 47.5t-47.5 113.5q0 79 62 127q44 34 99 34zM400 894v-99h-210 168 d="M295 196q67 0 114 -47t47 -113.5t-47 -114t-114 -47.5t-114 47.5t-47 113.5q0 44 21.5 81t58.5 58.5t81 21.5zM917 196q67 0 114 -47t47 -114q0 -32 -12.5 -62t-34 -51.5t-51.5 -34.5t-63 -13q-66 0 -113.5 47.5t-47.5 113.5q0 79 62 127q44 34 99 34zM400 894v-99h-210
170 v0l-187 -294v-372h95q27 56 80 90.5t117 34.5q43 0 82 -16t68.5 -44t46.5 -65h228q27 56 80 90.5t117 34.5q22 0 43 -4.5t39.5 -12t36 -18.5t32 -25t26.5 -30.5t20 -34.5h46v765h-760zM400 452h-283l159 250l124 1v-251v0zM893 701l-131 -276l-63 31l101 206h-105v68h198 169 v0l-187 -294v-372h95q27 56 80 90.5t117 34.5q43 0 82 -16t68.5 -44t46.5 -65h228q27 56 80 90.5t117 34.5q22 0 43 -4.5t39.5 -12t36 -18.5t32 -25t26.5 -30.5t20 -34.5h46v765h-760zM400 452h-283l159 250l124 1v-251v0zM893 701l-131 -276l-63 31l101 206h-105v68h198
@@ -178,6 +177,10 @@ d="M1020 810q0 34 -24 58t-59 24h-851q-34 0 -58.5 -24t-24.5 -58v-852q0 -34 24.5 - @@ -178,6 +177,10 @@ d="M1020 810q0 34 -24 58t-59 24h-851q-34 0 -58.5 -24t-24.5 -58v-852q0 -34 24.5 -
178 q16 16 38.5 16t38.5 -16l153 -152l264 264q16 16 39 16t39 -16t16 -38.5t-16 -38.5z" /> 177 q16 16 38.5 16t38.5 -16l153 -152l264 264q16 16 39 16t39 -16t16 -38.5t-16 -38.5z" />
179 <glyph glyph-name="uniE634" unicode="&#xe634;" 178 <glyph glyph-name="uniE634" unicode="&#xe634;"
180 d="M637 610l-45 46l-272 -272l272 -272l45 46l-226 226z" /> 179 d="M637 610l-45 46l-272 -272l272 -272l45 46l-226 226z" />
  180 + <glyph glyph-name="uniE635" unicode="&#xe635;"
  181 +d="M0 896h1024v-1024h-1024v1024zM85 -43h854v854h-854v-854z" />
  182 + <glyph glyph-name="uniE636" unicode="&#xe636;"
  183 +d="M1024 -128h-1024v1024h1024v-1024zM947 674l-34 34q-13 13 -30 13t-30 -13l-486 -495l-196 205q-13 13 -30 13t-30 -13l-34 -34q-5 -5 -8.5 -11t-4 -12.5t0 -13t4 -12.5t8.5 -11l256 -256q23 -22 51 -8l6 2l3 6l546 546q18 13 20 30.5t-12 29.5z" />
181 <glyph glyph-name="uniE637" unicode="&#xe637;" 184 <glyph glyph-name="uniE637" unicode="&#xe637;"
182 d="M0 812v-1024h1024v1024h-1024zM983 -171h-942v942h942v-942zM288 280h448q6 0 10.5 2.5t7.5 7t3 10.5q0 8 -6 14t-15 6h-448q-9 0 -15 -6t-6 -14t6 -14t15 -6z" /> 185 d="M0 812v-1024h1024v1024h-1024zM983 -171h-942v942h942v-942zM288 280h448q6 0 10.5 2.5t7.5 7t3 10.5q0 8 -6 14t-15 6h-448q-9 0 -15 -6t-6 -14t6 -14t15 -6z" />
183 <glyph glyph-name="uniE638" unicode="&#xe638;" 186 <glyph glyph-name="uniE638" unicode="&#xe638;"