切换导航条
此项目
正在载入...
登录
何书鹏
/
recruit
·
提交
转到一个项目
GitLab
转到仪表盘
项目
活动
文件
提交
管道
0
构建
0
图表
里程碑
问题
0
合并请求
0
成员
标记
维基
派生
网络
创建新的问题
下载为
邮件补丁
差异文件
浏览文件
作者
郭静帆
4 years ago
提交
f3f0dc51e4cf239bc817b1ad239c0ff8b9adcd33
1 个父辈
10a2ab07
1 个管道 的构建
通过
耗费 5 秒
本月额外收入
变更
1
构建
2
隐藏空白字符变更
内嵌
并排对比
正在显示
1 个修改的文件
包含
14 行增加
和
10 行删除
application/api/controller/User.php
application/api/controller/User.php
查看文件 @
f3f0dc5
...
...
@@ -1597,18 +1597,22 @@ class User extends Api
$page_num
=
$this
->
request
->
param
(
'page_num'
,
10
,
'intval'
);
$is_work
=
$this
->
request
->
param
(
'is_work'
);
//是否在职:0=否,1=是
$keyword
=
$this
->
request
->
param
(
'keyword'
);
// $where['pid'] = $user['id']; //下一级
// 下二级
$xia_ids
=
$this
->
model
->
where
(
'pid'
,
$user
[
'id'
])
->
column
(
'id'
);
if
(
!
empty
(
$xia_ids
)){
$xia_xia_ids
=
$this
->
model
->
where
(
'pid'
,
'in'
,
$xia_ids
)
if
(
$user
[
'lower_num'
]
==
1
){
$where
[
'pid'
]
=
$user
[
'id'
];
//下一级
}
if
(
$user
[
'lower_num'
]
==
2
){
// 下二级
$xia_ids
=
$this
->
model
->
where
(
'pid'
,
$user
[
'id'
])
->
column
(
'id'
);
$xia_ids
=
$xia_xia_ids
?
array_merge
(
$xia_ids
,
$xia_xia_ids
)
:
$xia_ids
;
if
(
!
empty
(
$xia_ids
)){
$xia_xia_ids
=
$this
->
model
->
where
(
'pid'
,
'in'
,
$xia_ids
)
->
column
(
'id'
);
$xia_ids
=
$xia_xia_ids
?
array_merge
(
$xia_ids
,
$xia_xia_ids
)
:
$xia_ids
;
}
$where
[
'id'
]
=
$xia_ids
?
[
'in'
,
$xia_ids
]
:
0
;
}
$where
[
'id'
]
=
$xia_ids
?
[
'in'
,
$xia_ids
]
:
0
;
if
(
$is_work
!=
''
){
$where
[
'is_work'
]
=
$is_work
;
}
...
...
请
注册
或
登录
后发表评论