Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
R
recruit-sys
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
李文光
recruit-sys
Commits
f42e88bd
Commit
f42e88bd
authored
Sep 09, 2026
by
李文光
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
refactor: 简化岗位列表新建入口
parent
0c4c8cd3
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
108 deletions
+13
-108
JobList.vue
vue-app/src/components/jobs/JobList.vue
+13
-108
No files found.
vue-app/src/components/jobs/JobList.vue
View file @
f42e88bd
...
@@ -71,10 +71,6 @@ const pendingJd = computed(
...
@@ -71,10 +71,6 @@ const pendingJd = computed(
const
totalHeadcount
=
computed
(()
=>
jobs
.
value
.
reduce
((
sum
,
job
)
=>
sum
+
Number
(
job
.
headcount
||
0
),
0
))
const
totalHeadcount
=
computed
(()
=>
jobs
.
value
.
reduce
((
sum
,
job
)
=>
sum
+
Number
(
job
.
headcount
||
0
),
0
))
const
totalHired
=
computed
(()
=>
jobs
.
value
.
reduce
((
sum
,
job
)
=>
sum
+
Number
(
job
.
hired
||
0
),
0
))
const
totalHired
=
computed
(()
=>
jobs
.
value
.
reduce
((
sum
,
job
)
=>
sum
+
Number
(
job
.
hired
||
0
),
0
))
const
highPriority
=
computed
(()
=>
jobs
.
value
.
filter
((
job
)
=>
job
.
priority
===
'高'
).
length
)
const
highPriority
=
computed
(()
=>
jobs
.
value
.
filter
((
job
)
=>
job
.
priority
===
'高'
).
length
)
const
openings
=
computed
(()
=>
jobs
.
value
.
reduce
((
sum
,
job
)
=>
sum
+
Math
.
max
(
0
,
Number
(
job
.
headcount
||
0
)
-
Number
(
job
.
hired
||
0
)),
0
)
)
const
attentionJobs
=
computed
(()
=>
jobs
.
value
.
filter
(
jobNeedsAttention
).
length
)
// 关联候选人:统计真正关联到任一岗位的候选人(按候选人去重),而非全库人数
// 关联候选人:统计真正关联到任一岗位的候选人(按候选人去重),而非全库人数
const
linkedCandidates
=
computed
(()
=>
{
const
linkedCandidates
=
computed
(()
=>
{
const
ids
=
new
Set
()
const
ids
=
new
Set
()
...
@@ -137,18 +133,7 @@ const newJob = () => {
...
@@ -137,18 +133,7 @@ const newJob = () => {
router
.
push
(
'/jobs/new'
)
router
.
push
(
'/jobs/new'
)
}
}
// 新建岗位入口:在列表页选择创建方式,由 JobEdit 根据 query 自动打开对应导入弹窗
const
pasteJob
=
()
=>
router
.
push
({
path
:
'/jobs/new'
,
query
:
{
import
:
'paste'
}
})
const
onCreateCommand
=
(
command
)
=>
{
if
(
command
===
'paste'
)
{
router
.
push
({
path
:
'/jobs/new'
,
query
:
{
import
:
'paste'
}
})
return
}
if
(
command
===
'template'
)
{
router
.
push
({
path
:
'/jobs/new'
,
query
:
{
import
:
'template'
}
})
return
}
router
.
push
(
'/jobs/new'
)
}
const
clearFilter
=
()
=>
{
const
clearFilter
=
()
=>
{
store
.
jobFilters
=
{
q
:
''
,
department
:
'全部部门'
,
status
:
'全部状态'
,
scope
:
'all'
}
store
.
jobFilters
=
{
q
:
''
,
department
:
'全部部门'
,
status
:
'全部状态'
,
scope
:
'all'
}
...
@@ -214,49 +199,6 @@ const deleteJob = async (job) => {
...
@@ -214,49 +199,6 @@ const deleteJob = async (job) => {
<
template
>
<
template
>
<div
class=
"job-workbench"
>
<div
class=
"job-workbench"
>
<section
class=
"job-command-hero"
>
<div
class=
"job-command-copy"
>
<span
class=
"page-eyebrow"
>
岗位管理 · 招聘工作台
</span>
<h2>
每个岗位,下一步都清清楚楚
</h2>
<p>
从这里查看招聘缺口、处理 JD 与发布事项,再进入具体岗位。
</p>
</div>
<div
class=
"job-command-summary"
>
<div>
<strong>
{{
activeJobs
}}
</strong
><span>
招聘中
</span>
</div>
<div>
<strong>
{{
openings
}}
</strong
><span>
待补人数
</span>
</div>
<div>
<strong>
{{
attentionJobs
}}
</strong
><span>
需要处理
</span>
</div>
</div>
<div
class=
"job-command-actions"
>
<el-dropdown
split-button
type=
"primary"
trigger=
"click"
@
click=
"newJob"
@
command=
"onCreateCommand"
>
新建岗位
<template
#
dropdown
>
<el-dropdown-menu>
<el-dropdown-item
command=
"paste"
>
<el-icon><MagicStick
/></el-icon>
粘贴 JD / 需求自动创建
</el-dropdown-item>
<el-dropdown-item
command=
"template"
>
<el-icon><Document
/></el-icon>
生成需求模板给用人部门
</el-dropdown-item>
<el-dropdown-item
command=
"blank"
divided
>
<el-icon><EditPen
/></el-icon>
空白表单手动填写
</el-dropdown-item>
</el-dropdown-menu>
</
template
>
</el-dropdown>
</div>
</section>
<div
class=
"job-metrics grid-4"
>
<div
class=
"job-metrics grid-4"
>
<article
v-for=
"m in metrics"
:key=
"m.label"
class=
"metric"
:style=
"
{ '--accent': m.color }">
<article
v-for=
"m in metrics"
:key=
"m.label"
class=
"metric"
:style=
"
{ '--accent': m.color }">
<span>
{{
m
.
label
}}
</span>
<span>
{{
m
.
label
}}
</span>
...
@@ -265,6 +207,17 @@ const deleteJob = async (job) => {
...
@@ -265,6 +207,17 @@ const deleteJob = async (job) => {
</article>
</article>
</div>
</div>
<div
class=
"job-create-actions"
>
<el-button
type=
"primary"
@
click=
"newJob"
>
<el-icon><EditPen
/></el-icon>
手动创建 JD
</el-button>
<el-button
@
click=
"pasteJob"
>
<el-icon><Document
/></el-icon>
粘贴已有 JD
</el-button>
</div>
<section
v-if=
"actionQueue.length"
class=
"job-action-queue"
>
<section
v-if=
"actionQueue.length"
class=
"job-action-queue"
>
<div
class=
"job-action-queue-head"
>
<div
class=
"job-action-queue-head"
>
<div>
<div>
...
@@ -404,54 +357,6 @@ const deleteJob = async (job) => {
...
@@ -404,54 +357,6 @@ const deleteJob = async (job) => {
gap
:
16
px
;
gap
:
16
px
;
}
}
.job-command-hero
{
display
:
flex
;
align-items
:
center
;
justify-content
:
space-between
;
gap
:
20px
;
background
:
linear-gradient
(
120deg
,
var
(
--
blue
)
,
var
(
--
violet
));
color
:
#fff
;
padding
:
24px
26px
;
border-radius
:
12px
;
.job-command-copy
{
.page-eyebrow
{
font-size
:
12px
;
opacity
:
0
.85
;
}
h2
{
margin
:
6px
0
;
font-size
:
22px
;
}
p
{
margin
:
0
;
opacity
:
0
.9
;
font-size
:
14px
;
}
}
.job-command-summary
{
display
:
flex
;
gap
:
24px
;
div
{
text-align
:
center
;
strong
{
display
:
block
;
font-size
:
26px
;
}
span
{
font-size
:
12px
;
opacity
:
0
.85
;
}
}
}
}
.
grid
-
4
{
.
grid
-
4
{
display
:
grid
;
display
:
grid
;
grid
-
template
-
columns
:
repeat
(
4
,
minmax
(
0
,
1
fr
));
grid
-
template
-
columns
:
repeat
(
4
,
minmax
(
0
,
1
fr
));
...
@@ -763,7 +668,7 @@ const deleteJob = async (job) => {
...
@@ -763,7 +668,7 @@ const deleteJob = async (job) => {
}
}
}
}
.job-c
ommand-hero
.job-command
-actions
{
.
job
-
c
reate
-
actions
{
display
:
flex
;
display
:
flex
;
gap
:
8
px
;
gap
:
8
px
;
flex
-
shrink
:
0
;
flex
-
shrink
:
0
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment