正在显示
1 个修改的文件
包含
16 行增加
和
16 行删除
@@ -1598,22 +1598,22 @@ class User extends Api | @@ -1598,22 +1598,22 @@ class User extends Api | ||
1598 | $is_work = $this->request->param('is_work'); //是否在职:0=否,1=是 | 1598 | $is_work = $this->request->param('is_work'); //是否在职:0=否,1=是 |
1599 | $keyword = $this->request->param('keyword'); | 1599 | $keyword = $this->request->param('keyword'); |
1600 | $where['pid'] = $user['id']; //下一级 | 1600 | $where['pid'] = $user['id']; //下一级 |
1601 | -// if ($user['lower_num'] == 1){ | ||
1602 | -// $where['pid'] = $user['id']; //下一级 | ||
1603 | -// } | ||
1604 | -// if ($user['lower_num'] == 2){ | ||
1605 | -// // 下二级 | ||
1606 | -// $xia_ids = $this->model | ||
1607 | -// ->where('pid',$user['id']) | ||
1608 | -// ->column('id'); | ||
1609 | -// if(!empty($xia_ids)){ | ||
1610 | -// $xia_xia_ids = $this->model | ||
1611 | -// ->where('pid','in',$xia_ids) | ||
1612 | -// ->column('id'); | ||
1613 | -// $xia_ids = $xia_xia_ids ? array_merge($xia_ids,$xia_xia_ids) : $xia_ids; | ||
1614 | -// } | ||
1615 | -// $where['id'] = $xia_ids ? ['in',$xia_ids] : 0; | ||
1616 | -// } | 1601 | + if ($user['lower_num'] == 1){ |
1602 | + $where['pid'] = $user['id']; //下一级 | ||
1603 | + } | ||
1604 | + if ($user['lower_num'] == 2){ | ||
1605 | + // 下二级 | ||
1606 | + $xia_ids = $this->model | ||
1607 | + ->where('pid',$user['id']) | ||
1608 | + ->column('id'); | ||
1609 | + if(!empty($xia_ids)){ | ||
1610 | + $xia_xia_ids = $this->model | ||
1611 | + ->where('pid','in',$xia_ids) | ||
1612 | + ->column('id'); | ||
1613 | + $xia_ids = $xia_xia_ids ? array_merge($xia_ids,$xia_xia_ids) : $xia_ids; | ||
1614 | + } | ||
1615 | + $where['id'] = $xia_ids ? ['in',$xia_ids] : 0; | ||
1616 | + } | ||
1617 | 1617 | ||
1618 | if($is_work != ''){ | 1618 | if($is_work != ''){ |
1619 | $where['is_work'] = $is_work; | 1619 | $where['is_work'] = $is_work; |
-
请 注册 或 登录 后发表评论