|
@@ -35,34 +35,10 @@ let $invoice = $('.invoice'), |
|
@@ -35,34 +35,10 @@ let $invoice = $('.invoice'), |
35
|
$message = $('#msg'),
|
35
|
$message = $('#msg'),
|
36
|
$noPrintPrice = $('.no-print-price');
|
36
|
$noPrintPrice = $('.no-print-price');
|
37
|
|
37
|
|
38
|
-let orderCont = cookie.get('order-info') && JSON.parse(cookie.get('order-info'));
|
|
|
39
|
-let invoiceCont = {
|
|
|
40
|
- 7: '服装',
|
|
|
41
|
- 1: '图书',
|
|
|
42
|
- 9: '配件',
|
|
|
43
|
- 11: '日用品',
|
|
|
44
|
- 3: '办公用品',
|
|
|
45
|
- 6: '体育用品',
|
|
|
46
|
- 10: '数码产品'
|
|
|
47
|
- },
|
|
|
48
|
- invoicesType = {
|
|
|
49
|
- 1: '纸质',
|
|
|
50
|
- 2: '电子'
|
|
|
51
|
- };
|
|
|
52
|
-
|
|
|
53
|
require('common');
|
38
|
require('common');
|
54
|
|
39
|
|
55
|
lazyLoad();
|
40
|
lazyLoad();
|
56
|
|
41
|
|
57
|
-// 初始化发票信息
|
|
|
58
|
-function invoiceInit() {
|
|
|
59
|
- if (orderCont.invoiceType) {
|
|
|
60
|
- $('.invoice-type').text(invoiceCont[orderCont.invoiceType] + '(' + invoicesType[orderCont.invoicesType] + ')');
|
|
|
61
|
- } else {
|
|
|
62
|
- $('.invoice-type').text('服装(电子)');
|
|
|
63
|
- }
|
|
|
64
|
-}
|
|
|
65
|
-
|
|
|
66
|
function getQueryParam() {
|
42
|
function getQueryParam() {
|
67
|
let queryArray = location.search.substr(1).split('&'),
|
43
|
let queryArray = location.search.substr(1).split('&'),
|
68
|
i,
|
44
|
i,
|
|
@@ -115,17 +91,6 @@ if (queryString.cartType || queryString.carttype || !orderInfo('cartType')) { |
|
@@ -115,17 +91,6 @@ if (queryString.cartType || queryString.carttype || !orderInfo('cartType')) { |
115
|
orderInfo('cartType', queryString.cartType || queryString.carttype || 'ordinary');
|
91
|
orderInfo('cartType', queryString.cartType || queryString.carttype || 'ordinary');
|
116
|
}
|
92
|
}
|
117
|
|
93
|
|
118
|
-// function dispacthTapEvt(e) {
|
|
|
119
|
-// let $cur = $(e.target).closest('li');
|
|
|
120
|
-
|
|
|
121
|
-// if ($cur.length === 0 || $cur.hasClass('chosed')) {
|
|
|
122
|
-// return;
|
|
|
123
|
-// }
|
|
|
124
|
-
|
|
|
125
|
-// $cur.siblings('li.chosed').removeClass('chosed');
|
|
|
126
|
-// $cur.addClass('chosed');
|
|
|
127
|
-// }
|
|
|
128
|
-
|
|
|
129
|
$('.checkbox').on('touchstart', function(e) {
|
94
|
$('.checkbox').on('touchstart', function(e) {
|
130
|
let $this = $(this);
|
95
|
let $this = $(this);
|
131
|
|
96
|
|
|
@@ -162,9 +127,6 @@ $invoice.on('touchend', '.checkbox', function() { |
|
@@ -162,9 +127,6 @@ $invoice.on('touchend', '.checkbox', function() { |
162
|
orderInfo('invoicesType', null);
|
127
|
orderInfo('invoicesType', null);
|
163
|
orderInfo('invoiceTitle', null);
|
128
|
orderInfo('invoiceTitle', null);
|
164
|
}
|
129
|
}
|
165
|
-
|
|
|
166
|
- orderCont = cookie.get('order-info') && JSON.parse(cookie.get('order-info'));
|
|
|
167
|
- invoiceInit();
|
|
|
168
|
});
|
130
|
});
|
169
|
|
131
|
|
170
|
|
132
|
|
|
@@ -258,17 +220,6 @@ function submitOrder() { |
|
@@ -258,17 +220,6 @@ function submitOrder() { |
258
|
return false;
|
220
|
return false;
|
259
|
}
|
221
|
}
|
260
|
|
222
|
|
261
|
- // if (orderInfo('invoice')) {
|
|
|
262
|
- // if (!invoiceText) {
|
|
|
263
|
- // tip.show('请输入发票抬头');
|
|
|
264
|
- // return;
|
|
|
265
|
- // }
|
|
|
266
|
- // if (invoiceText.length > 30) {
|
|
|
267
|
- // tip.show('发票抬头不得超过30个汉字');
|
|
|
268
|
- // return;
|
|
|
269
|
- // }
|
|
|
270
|
- // }
|
|
|
271
|
-
|
|
|
272
|
if (msg) {
|
223
|
if (msg) {
|
273
|
if (msg.length > 40) {
|
224
|
if (msg.length > 40) {
|
274
|
tip.show('留言不得超过40个汉字');
|
225
|
tip.show('留言不得超过40个汉字');
|
|
@@ -566,9 +517,6 @@ $ticketsMobile.blur(function() { |
|
@@ -566,9 +517,6 @@ $ticketsMobile.blur(function() { |
566
|
}
|
517
|
}
|
567
|
});
|
518
|
});
|
568
|
|
519
|
|
569
|
-// 初始化发票信息内容
|
|
|
570
|
-invoiceInit();
|
|
|
571
|
-
|
|
|
572
|
// 留言点击滚动屏幕
|
520
|
// 留言点击滚动屏幕
|
573
|
$message.on('click', function() {
|
521
|
$message.on('click', function() {
|
574
|
$('html,body').animate({
|
522
|
$('html,body').animate({
|