|
@@ -448,6 +448,20 @@ class User extends BaseController{
|
|
|
];
|
|
|
$post['companyArr'][]=$temp;
|
|
|
}
|
|
|
+ }else{
|
|
|
+ if(!empty($post['companyArr'])){
|
|
|
+ foreach ($post['companyArr'] as &$item){
|
|
|
+ $company =Db::name("supplier_info")->where(["code"=>$item['companyCode']])->find();
|
|
|
+ $item['company_type'] = $company["type"]==3?2:1;
|
|
|
+ }
|
|
|
+ }else{
|
|
|
+ $post['companyArr'][]= [
|
|
|
+ "companyCode"=>'',
|
|
|
+ "companyName"=>'',
|
|
|
+ "company_type"=>0,
|
|
|
+ "is_main"=>1,
|
|
|
+ ];
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
|