diff --git a/Application/Admin/Controller/AggregateRelationController.class.php b/Application/Admin/Controller/AggregateRelationController.class.php index d24920d9f..fab41b192 100644 --- a/Application/Admin/Controller/AggregateRelationController.class.php +++ b/Application/Admin/Controller/AggregateRelationController.class.php @@ -589,8 +589,15 @@ class AggregateRelationController extends AdminController $map['id'] = $id; $dbres = $this->DBModel->where($map)->find(); - $this->assign('first_company_info',$this->getCompanyInfo($dbres['first_company_type'],$dbres['first_company_id'])); - $this->assign('second_company_info',$this->getCompanyInfo($dbres['second_company_type'],$dbres['second_company_id'])); + + $first_company_info = $this->getCompanyInfo($dbres['first_company_type'],$dbres['first_company_id']); + $first_company_info['invoice_type'] = $first_company_info['invoice_type'] == "专票" ? 1 : ($first_company_info['invoice_type'] == "普票"?2:''); + + $this->assign('first_company_info',$first_company_info); + + $second_company_info = $this->getCompanyInfo($dbres['second_company_type'],$dbres['second_company_id']); + $second_company_info['invoice_type'] = $second_company_info['invoice_type'] == "专票" ? 1 : ($second_company_info['invoice_type'] == "普票"?2:''); + $this->assign('second_company_info',$second_company_info); $dbres['first_company_type'] =$this->CompanyType[$dbres['first_company_type']]; $dbres['second_company_type'] =$this->CompanyType[$dbres['second_company_type']]; @@ -697,9 +704,9 @@ class AggregateRelationController extends AdminController //己方公司 $companyInfo = M("CompanyInfo","tab_")->field("id,partner company_name,partner,link_man,link_phone,address,company_tax_no,payee_name,bank_account,opening_bank,invoice_item,invoice_type,register_phone,register_address")->where("status='1' AND id='{$id}'")->find(); if (strstr($companyInfo['invoice_type'],'专')) { - $companyInfo['invoice_type'] = "1"; + $companyInfo['invoice_type'] = "专票"; } else if (strstr($companyInfo['invoice_type'],'普')) { - $companyInfo['invoice_type'] = "2"; + $companyInfo['invoice_type'] = "普票"; } } if($type == 1){