Showing
1 changed file
with
14 additions
and
5 deletions
@@ -42,6 +42,15 @@ require('../common'); | @@ -42,6 +42,15 @@ require('../common'); | ||
42 | 42 | ||
43 | lazyLoad(); | 43 | lazyLoad(); |
44 | 44 | ||
45 | +// 初始化发票信息 | ||
46 | +function invoiceInit() { | ||
47 | + if (orderCont.invoiceType) { | ||
48 | + $('.invoice-type').text(invoiceCont[orderCont.invoiceType] + '(' + invoicesType[orderCont.invoicesType] + ')'); | ||
49 | + } else { | ||
50 | + $('.invoice-type').text('服装(电子)'); | ||
51 | + } | ||
52 | +} | ||
53 | + | ||
45 | function getQueryParam() { | 54 | function getQueryParam() { |
46 | var queryArray = location.search.substr(1).split('&'), | 55 | var queryArray = location.search.substr(1).split('&'), |
47 | i, | 56 | i, |
@@ -136,6 +145,9 @@ $invoice.on('touchend', '.checkbox', function() { | @@ -136,6 +145,9 @@ $invoice.on('touchend', '.checkbox', function() { | ||
136 | orderInfo('invoicesType', null); | 145 | orderInfo('invoicesType', null); |
137 | orderInfo('invoiceTitle', null); | 146 | orderInfo('invoiceTitle', null); |
138 | } | 147 | } |
148 | + | ||
149 | + orderCont = window.cookie('order-info') && JSON.parse(window.cookie('order-info')); | ||
150 | + invoiceInit(); | ||
139 | }); | 151 | }); |
140 | 152 | ||
141 | 153 | ||
@@ -401,8 +413,5 @@ if (orderInfo('address') && orderInfo('address').is_support === 'N') { | @@ -401,8 +413,5 @@ if (orderInfo('address') && orderInfo('address').is_support === 'N') { | ||
401 | orderCompute(); | 413 | orderCompute(); |
402 | } | 414 | } |
403 | 415 | ||
404 | -if (orderCont.invoiceType) { | ||
405 | - $('.invoice-type').text(invoiceCont[orderCont.invoiceType] + '(' + invoicesType[orderCont.invoicesType] + ')'); | ||
406 | -} else { | ||
407 | - $('.invoice-type').text('服装(电子)'); | ||
408 | -} | ||
416 | +// 初始化发票信息内容 | ||
417 | +invoiceInit(); |
-
Please register or login to post a comment