diff --git a/app/api/controller/InformationController.php b/app/api/controller/InformationController.php index 5733c45d6..da585dba3 100644 --- a/app/api/controller/InformationController.php +++ b/app/api/controller/InformationController.php @@ -4,6 +4,7 @@ namespace app\api\controller; use app\common\model\informationg\UserInformationg; use app\common\logic\BaseLogic; +use app\common\model\user\User; class InformationController extends BaseApiController { @@ -29,8 +30,15 @@ class InformationController extends BaseApiController public function add() { $param = Request()->param(); + $user=User::where('id',$this->userId)->find(); $param['admin_id'] = $this->userId; $param['company_id']=$this->userInfo['company_id']; + $param['province']=$user['province']; + $param['city']=$user['city']; + $param['area']=$user['area']; + $param['street']=$user['street']; + $param['village']=$user['village']; + $param['brigade']=$user['brigade']; $res = UserInformationg::add($param); if ($res != true) { return $this->fail( BaseLogic::getError());