Authored by 周少峰

invoice content default clothes

@@ -698,14 +698,14 @@ class CartModel @@ -698,14 +698,14 @@ class CartModel
698 } 698 }
699 } 699 }
700 700
701 - /* 发票类型 */  
702 - if (!empty($pay['data']['invoices']['invoices_type_list'])) {  
703 - $build = array();  
704 - foreach ($pay['data']['invoices']['invoices_type_list'] as $value) {  
705 - $build['id'] = $value['invoices_type_id'];  
706 - $build['name'] = $value['invoices_type_name'];  
707 - $result['piaoTypes'][] = $build;  
708 - } 701 + /* 发票内容 */
  702 + if (!empty($pay['data']['invoices']['invoiceContentList'])) {
  703 + foreach ($pay['data']['invoices']['invoiceContentList'] as $value) {
  704 + $result['piaoTypes'][$value['invoices_type_id']]['id'] = $value['invoices_type_id'];
  705 + $result['piaoTypes'][$value['invoices_type_id']]['name'] = $value['invoices_type_name'];
  706 + }
  707 + ksort($result['piaoTypes']);
  708 + $result['piaoTypes'] = array_values($result['piaoTypes']);
709 $result['receiverMobile'] = isset($userInfo['data']['mobile']) && $userInfo['data']['mobile'] ? $userInfo['data']['mobile'] : ''; 709 $result['receiverMobile'] = isset($userInfo['data']['mobile']) && $userInfo['data']['mobile'] ? $userInfo['data']['mobile'] : '';
710 } 710 }
711 711