Showing
2 changed files
with
3 additions
and
3 deletions
@@ -174,7 +174,8 @@ class BuyNowController { | @@ -174,7 +174,8 @@ class BuyNowController { | ||
174 | }; | 174 | }; |
175 | 175 | ||
176 | // 是否开发票 | 176 | // 是否开发票 |
177 | - if (req.body.invoice) { | 177 | + if (req.body.invoice && req.body.invoice === 'true') { |
178 | + params.invoice = true; | ||
178 | params.invoices_type = req.body.invoices_type; // 发票类型:纸质 1,电子 2 | 179 | params.invoices_type = req.body.invoices_type; // 发票类型:纸质 1,电子 2 |
179 | params.invoices_title = req.body.invoices_title || '个人'; // 发票抬头,个人前端不传此值 | 180 | params.invoices_title = req.body.invoices_title || '个人'; // 发票抬头,个人前端不传此值 |
180 | params.receiverMobile = req.body.receiverMobile; // 接收人电话 | 181 | params.receiverMobile = req.body.receiverMobile; // 接收人电话 |
@@ -2,7 +2,6 @@ | @@ -2,7 +2,6 @@ | ||
2 | * @Author: Targaryen | 2 | * @Author: Targaryen |
3 | * @Date: 2017-06-21 10:15:45 | 3 | * @Date: 2017-06-21 10:15:45 |
4 | * @Last Modified by: Targaryen | 4 | * @Last Modified by: Targaryen |
5 | - * @Last Modified time: 2017-06-23 17:44:33 | ||
6 | */ | 5 | */ |
7 | const api = global.yoho.API; | 6 | const api = global.yoho.API; |
8 | 7 | ||
@@ -130,7 +129,7 @@ class BuyNowModel extends global.yoho.BaseModel { | @@ -130,7 +129,7 @@ class BuyNowModel extends global.yoho.BaseModel { | ||
130 | } | 129 | } |
131 | 130 | ||
132 | // 发票种类写死明细 | 131 | // 发票种类写死明细 |
133 | - if (params.invoices_type_id) { | 132 | + if (params.invoice) { |
134 | finalParams.invoice_content = 12; | 133 | finalParams.invoice_content = 12; |
135 | } | 134 | } |
136 | 135 |
-
Please register or login to post a comment