调整代码格式及使用常量去替换常用值

This commit is contained in:
柳清爽
2025-05-08 10:39:53 +08:00
parent b5939b36b3
commit 0426485177
31 changed files with 230 additions and 191 deletions

View File

@@ -21,10 +21,16 @@ class GetCompanySubusersForProfileController extends Controller
{
$where = [
'companyId' => $this->request->param('companyId/d', 0),
'isAdmin' => 0
'isAdmin' => UserModel::ADMIN_OTP
];
return UserModel::field('id,account,phone,username,avatar,status,createTime,typeId')->where($where)->select()->toArray();
return UserModel::alias('u')
->field([
'u.id', 'u.account', 'u.phone', 'u.username', 'u.avatar', 'u.status', 'u.createTime', 'u.typeId'
])
->where($where)
->select()
->toArray();
}
/**