提交 71f4451d authored 作者: chengye's avatar chengye

修改staff接口

上级 59fb8287
...@@ -18,7 +18,7 @@ class Staff ...@@ -18,7 +18,7 @@ class Staff
//如果不是超级管理员 //如果不是超级管理员
if(!$user['is_admin']) { if(!$user['is_admin']) {
$staff = Db::table('staff') $staff = Db::table('staff')
->field('staff.id,name,d_id,iden_id,email,si.title as iden_name') ->field('staff.id,staff.name,staff.d_id,staff.iden_id,staff.email,si.title as iden_name')
->leftJoin(['staff_identity'=>'si'],'si.id = staff.iden_id') ->leftJoin(['staff_identity'=>'si'],'si.id = staff.iden_id')
->where('staff.id','=',$user['user_id']) ->where('staff.id','=',$user['user_id'])
->find(); ->find();
...@@ -43,7 +43,7 @@ class Staff ...@@ -43,7 +43,7 @@ class Staff
//获取员工列表信息 //获取员工列表信息
public function getStaffs(){ public function getStaffs(){
$staffs = Db::table('staff') $staffs = Db::table('staff')
->field('staff.id,name,d_id,iden_id,email,si.title as iden_name') ->field('staff.id,staff.name,staff.d_id,staff.iden_id,staff.email,si.title as iden_name')
->leftJoin(['staff_identity'=>'si'],'si.id = staff.iden_id') ->leftJoin(['staff_identity'=>'si'],'si.id = staff.iden_id')
->select(); ->select();
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论