切换导航条
此项目
正在载入...
登录
郭盛
/
enterprise
·
提交
转到一个项目
GitLab
转到仪表盘
项目
活动
文件
提交
管道
0
构建
0
图表
里程碑
问题
0
合并请求
0
成员
标记
维基
派生
网络
创建新的问题
下载为
差异文件
浏览文件
作者
何书鹏
4 years ago
提交
96e3a85317b2209674b01eb5381d445c63ba6161
2 个父辈
7daf4506
877e3e5a
1 个管道 的构建
通过
耗费 3 秒
合并分支 'heshupeng' 到 'master'
能力筛选 查看合并请求
!175
变更
2
构建
2
隐藏空白字符变更
内嵌
并排对比
正在显示
2 个修改的文件
包含
40 行增加
和
2 行删除
application/mobile/controller/CompanyJob.php
public/mobile.html
application/mobile/controller/CompanyJob.php
查看文件 @
96e3a85
...
...
@@ -14,7 +14,7 @@ use app\mobile\model\UserJobDownload;
*/
class
CompanyJob
extends
Api
{
protected
$noNeedLogin
=
[
'
*
'
];
protected
$noNeedLogin
=
[
'
userJobAbility
'
];
protected
$noNeedRight
=
[
'*'
];
protected
$model
=
null
;
protected
$company_id
=
0
;
...
...
@@ -111,7 +111,45 @@ class CompanyJob extends Api
}
/**
* @ApiWeigh (99)
* @ApiWeigh (98)
* @ApiTitle (能力筛选)
* @ApiSummary (能力筛选)
* @ApiMethod (POST)
*
* @ApiReturn({
"code": 1,
"msg": "成功",
"time": "1599018234",
"data": [{
"id": 1, //一级ID
"pid": 0,
"name": "建筑工程", //一级名称
"children": [{ //二级
"id": 3, //二级ID
"pid": 1, //父ID
"name": "一级建造师", //二级名称
}]
}]
})
*/
public
function
userJobAbility
()
{
$list
=
UserJobAbility
::
where
(
'pid'
,
0
)
->
field
(
'id,pid,name'
)
->
select
();
$new_list
=
[
0
=>
[
'id'
=>
0
,
'name'
=>
'全部'
,
'pid'
=>
0
]];
foreach
(
$list
as
$v
){
$children
=
UserJobAbility
::
where
(
'pid'
,
$v
[
'id'
])
->
field
(
'id,pid,name'
)
->
select
();;
$new_children
=
[
0
=>
[
'id'
=>
0
,
'name'
=>
'全部'
,
'pid'
=>
$v
[
'id'
]]];
foreach
(
$children
as
$val
){
$new_children
[
$val
[
'id'
]]
=
$val
;
}
$v
[
'children'
]
=
$new_children
;
$new_list
[
$v
[
'id'
]]
=
$v
;
}
$this
->
success
(
'成功'
,
$new_list
);
}
/**
* @ApiWeigh (97)
* @ApiTitle (求职-详情)
* @ApiSummary (求职-详情)
* @ApiMethod (POST)
...
...
public/mobile.html
查看文件 @
96e3a85
此 diff 太大无法显示。
请
注册
或
登录
后发表评论