...
|
...
|
@@ -217,6 +217,11 @@ class UserController extends AdminBaseController |
|
|
$this->assign("role_ids", $role_ids);
|
|
|
|
|
|
$user = DB::name('user')->where("id", $id)->find();
|
|
|
|
|
|
//企业
|
|
|
$company_id = $user['company_id'];
|
|
|
$res = DB::name('company')->where('id',$company_id)->field('id,company_name')->find();
|
|
|
$this->assign('company',$res);
|
|
|
$this->assign($user);
|
|
|
return $this->fetch();
|
|
|
}
|
...
|
...
|
@@ -247,6 +252,11 @@ class UserController extends AdminBaseController |
|
|
unset($_POST['role_id']);
|
|
|
$result = $this->validate($this->request->param(), 'User.edit');
|
|
|
|
|
|
//更新乙方企业名称
|
|
|
$companyModel = new CompanyModel();
|
|
|
$companyModel->where('id',$_POST['company_id'])->update(['company_name'=>$_POST['company_name']]);
|
|
|
unset($_POST['company_id']);
|
|
|
unset($_POST['company_name']);
|
|
|
if ($result !== true) {
|
|
|
// 验证失败 输出错误信息
|
|
|
$this->error($result);
|
...
|
...
|
|