Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
psa-web
Project
Project
Details
Activity
Releases
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
高滢
psa-web
Commits
fe0e644f
Commit
fe0e644f
authored
Mar 27, 2025
by
Mr.Tang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
人事管理——审批流分页bug修复
parent
54d01e73
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
112 additions
and
110 deletions
+112
-110
index.vue
src/views/staffmanage/confirmationmanage/index.vue
+2
-2
edit.vue
src/views/staffmanage/leavemanage/edit.vue
+2
-2
index.vue
src/views/staffmanage/leavemanage/index.vue
+2
-2
check.vue
src/views/staffmanage/onboardmanage/check.vue
+1
-9
edit.vue
src/views/staffmanage/onboardmanage/edit.vue
+1
-9
index.vue
src/views/staffmanage/onboardmanage/index.vue
+13
-5
confirmationmanageApprove.vue
...e/personalmanage/components/confirmationmanageApprove.vue
+33
-26
leavemanageApprove.vue
...ffmanage/personalmanage/components/leavemanageApprove.vue
+30
-26
onboardmanageApprove.vue
...manage/personalmanage/components/onboardmanageApprove.vue
+28
-29
No files found.
src/views/staffmanage/confirmationmanage/index.vue
View file @
fe0e644f
...
@@ -85,11 +85,11 @@
...
@@ -85,11 +85,11 @@
<span>
{{
parseTime
(
scope
.
row
.
serviceDate
,
'{y
}
-{m
}
-{d
}
'
)
}}
<
/span
>
<span>
{{
parseTime
(
scope
.
row
.
serviceDate
,
'{y
}
-{m
}
-{d
}
'
)
}}
<
/span
>
<
/template
>
<
/template
>
<
/el-table-column
>
<
/el-table-column
>
<
el
-
table
-
column
label
=
"审批状态"
align
=
"center"
width
=
"150"
prop
=
"confirmationApprovalState"
>
<!--
<
el
-
table
-
column
label
=
"审批状态"
align
=
"center"
width
=
"150"
prop
=
"confirmationApprovalState"
>
<
template
#
default
=
"scope"
>
<
template
#
default
=
"scope"
>
<
dict
-
tag
:
options
=
"confirmationmanage_state"
:
value
=
"scope.row.confirmationApprovalState"
/>
<
dict
-
tag
:
options
=
"confirmationmanage_state"
:
value
=
"scope.row.confirmationApprovalState"
/>
<
/template
>
<
/template
>
<
/el-table-column
>
<
/el-table-column>
--
>
<
el
-
table
-
column
label
=
"拟转正日期"
align
=
"center"
prop
=
"proposedDate"
width
=
"140"
>
<
el
-
table
-
column
label
=
"拟转正日期"
align
=
"center"
prop
=
"proposedDate"
width
=
"140"
>
<
template
v
-
slot
:
default
=
"scope"
>
<
template
v
-
slot
:
default
=
"scope"
>
<
span
>
{{
parseTime
(
scope
.
row
.
proposedDate
,
'{y
}
-{m
}
-{d
}
'
)
}}
<
/span
>
<
span
>
{{
parseTime
(
scope
.
row
.
proposedDate
,
'{y
}
-{m
}
-{d
}
'
)
}}
<
/span
>
...
...
src/views/staffmanage/leavemanage/edit.vue
View file @
fe0e644f
...
@@ -169,14 +169,14 @@
...
@@ -169,14 +169,14 @@
</el-date-picker>
</el-date-picker>
</el-form-item>
</el-form-item>
</el-row>
</el-row>
<el-row>
<!--
<el-row>
<el-form-item label="审批" prop="managerOpinion" class="textForInput">
<el-form-item label="审批" prop="managerOpinion" class="textForInput">
<el-radio-group v-model="form.managerOpinion" size="medium">
<el-radio-group v-model="form.managerOpinion" size="medium">
<el-radio v-for="(item, index) in managerOpinions" :key="index" :label="item.value"
<el-radio v-for="(item, index) in managerOpinions" :key="index" :label="item.value"
:disabled="item.disabled">{{item.label}}</el-radio>
:disabled="item.disabled">{{item.label}}</el-radio>
</el-radio-group>
</el-radio-group>
</el-form-item>
</el-form-item>
</el-row>
</el-row>
-->
<el-form-item
class=
"bottom-button"
>
<el-form-item
class=
"bottom-button"
>
<el-button
@
click=
"goBack"
class=
"cancel-button"
>
取 消
</el-button>
<el-button
@
click=
"goBack"
class=
"cancel-button"
>
取 消
</el-button>
<el-button
class=
"savecConfirm-button"
@
click=
"submitForm"
>
确 定
</el-button>
<el-button
class=
"savecConfirm-button"
@
click=
"submitForm"
>
确 定
</el-button>
...
...
src/views/staffmanage/leavemanage/index.vue
View file @
fe0e644f
...
@@ -107,11 +107,11 @@
...
@@ -107,11 +107,11 @@
<
/template
>
<
/template
>
<
/el-table-column
>
<
/el-table-column
>
<
el
-
table
-
column
label
=
"岗位"
width
=
"150"
align
=
"center"
prop
=
"position"
/>
<
el
-
table
-
column
label
=
"岗位"
width
=
"150"
align
=
"center"
prop
=
"position"
/>
<
el
-
table
-
column
label
=
"审批状态"
width
=
"150"
align
=
"center"
prop
=
"leaveApprovalState"
>
<!--
<
el
-
table
-
column
label
=
"审批状态"
width
=
"150"
align
=
"center"
prop
=
"leaveApprovalState"
>
<
template
#
default
=
"scope"
>
<
template
#
default
=
"scope"
>
<
dict
-
tag
:
options
=
"leavemanage_state"
:
value
=
"scope.row.leaveApprovalState"
/>
<
dict
-
tag
:
options
=
"leavemanage_state"
:
value
=
"scope.row.leaveApprovalState"
/>
<
/template
>
<
/template
>
<
/el-table-column
>
<
/el-table-column>
--
>
<
el
-
table
-
column
label
=
"聘用形式"
width
=
"150"
align
=
"center"
prop
=
"employmentForm"
>
<
el
-
table
-
column
label
=
"聘用形式"
width
=
"150"
align
=
"center"
prop
=
"employmentForm"
>
<
template
#
default
=
"scope"
>
<
template
#
default
=
"scope"
>
<
dict
-
tag
:
options
=
"employment_form"
:
value
=
"scope.row.employmentForm"
/>
<
dict
-
tag
:
options
=
"employment_form"
:
value
=
"scope.row.employmentForm"
/>
...
...
src/views/staffmanage/onboardmanage/check.vue
View file @
fe0e644f
...
@@ -305,17 +305,9 @@
...
@@ -305,17 +305,9 @@
</el-select>
</el-select>
</el-form-item>
</el-form-item>
</el-row>
</el-row>
<el-row>
<el-form-item
label=
"审批"
prop=
"managerOpinion"
class=
"textForInput"
>
<el-radio-group
v-model=
"form.managerOpinion"
size=
"medium"
>
<el-radio
v-for=
"(item, index) in managerOpinions"
:key=
"index"
:label=
"item.value"
:disabled=
"item.disabled"
>
{{
item
.
label
}}
</el-radio>
</el-radio-group>
</el-form-item>
</el-row>
<el-form-item
class=
"bottom-button"
>
<el-form-item
class=
"bottom-button"
>
<el-button
@
click=
"cancel"
class=
"cancel-button"
>
取 消
</el-button>
<el-button
@
click=
"cancel"
class=
"cancel-button"
>
取 消
</el-button>
<el-button
class=
"savecConfirm-button"
@
click=
"saveOnDraft"
>
保存
</el-button>
<el-button
class=
"savecConfirm-button"
@
click=
"saveOnDraft"
>
保
存
</el-button>
<el-button
class=
"savecConfirm-button"
@
click=
"submitForm"
>
确 定
</el-button>
<el-button
class=
"savecConfirm-button"
@
click=
"submitForm"
>
确 定
</el-button>
</el-form-item>
</el-form-item>
</el-form>
</el-form>
...
...
src/views/staffmanage/onboardmanage/edit.vue
View file @
fe0e644f
...
@@ -298,17 +298,9 @@
...
@@ -298,17 +298,9 @@
</el-select>
</el-select>
</el-form-item>
</el-form-item>
</el-row>
</el-row>
<el-row>
<el-form-item
label=
"审批"
prop=
"managerOpinion"
class=
"textForInput"
>
<el-radio-group
v-model=
"form.managerOpinion"
size=
"medium"
>
<el-radio
v-for=
"(item, index) in managerOpinions"
:key=
"index"
:label=
"item.value"
:disabled=
"item.disabled"
>
{{
item
.
label
}}
</el-radio>
</el-radio-group>
</el-form-item>
</el-row>
<el-form-item
class=
"bottom-button"
>
<el-form-item
class=
"bottom-button"
>
<el-button
@
click=
"cancel"
class=
"cancel-button"
>
取 消
</el-button>
<el-button
@
click=
"cancel"
class=
"cancel-button"
>
取 消
</el-button>
<el-button
class=
"savecConfirm-button"
@
click=
"saveOnDraft"
>
保存
</el-button>
<el-button
class=
"savecConfirm-button"
@
click=
"saveOnDraft"
>
保
存
</el-button>
<el-button
class=
"savecConfirm-button"
@
click=
"submitForm"
>
确 定
</el-button>
<el-button
class=
"savecConfirm-button"
@
click=
"submitForm"
>
确 定
</el-button>
</el-form-item>
</el-form-item>
</el-form>
</el-form>
...
...
src/views/staffmanage/onboardmanage/index.vue
View file @
fe0e644f
...
@@ -479,16 +479,24 @@ function fieldBeforeUpload(file) {
...
@@ -479,16 +479,24 @@ function fieldBeforeUpload(file) {
/** 查询入职审批列表 */
/** 查询入职审批列表 */
function
getList
()
{
function
getList
()
{
loading
.
value
=
true
;
loading
.
value
=
true
;
listOnBoardManage
(
queryParams
.
value
).
then
(
response
=>
{
/* onboardmanageList.value = response.rows.filter(item=>
// 将筛选条件加入请求参数
item.employmentApprovalState === 0 || 1
const
params
=
{
);*/
...
queryParams
.
value
,
currentNode
:
103
,
// 将筛选条件放到请求参数中
employmentApprovalState
:
2
// 让服务端进行筛选
}
;
listOnBoardManage
(
params
).
then
(
response
=>
{
// 直接使用服务端返回的分页数据(不要在前端二次筛选)
onboardmanageList
.
value
=
response
.
rows
;
onboardmanageList
.
value
=
response
.
rows
;
// 使用服务端返回的真实总数
total
.
value
=
response
.
total
;
total
.
value
=
response
.
total
;
loading
.
value
=
false
;
loading
.
value
=
false
;
}
);
}
);
}
}
/** 搜索按钮操作 */
/** 搜索按钮操作 */
function
handleQuery
()
{
function
handleQuery
()
{
queryParams
.
value
.
pageNum
=
1
;
queryParams
.
value
.
pageNum
=
1
;
...
...
src/views/staffmanage/personalmanage/components/confirmationmanageApprove.vue
View file @
fe0e644f
...
@@ -231,7 +231,9 @@ const data = reactive({
...
@@ -231,7 +231,9 @@ const data = reactive({
isPassPeriod
:
null
,
isPassPeriod
:
null
,
departManagerSignature
:
null
,
departManagerSignature
:
null
,
officialConversionDate
:
null
,
officialConversionDate
:
null
,
managerConfirm
:
null
managerConfirm
:
null
,
currentNode
:
null
,
confirmationApprovalState
:
null
}
,
}
,
rules
:
{
rules
:
{
}
}
...
@@ -337,36 +339,41 @@ function handleSelectionChange1(val) {
...
@@ -337,36 +339,41 @@ function handleSelectionChange1(val) {
this
.
selectedRows
=
val
;
this
.
selectedRows
=
val
;
}
}
/** 查询转正审批列表 */
/** 查询转正审批列表 */
function
getList
()
{
async
function
getList
()
{
loading
.
value
=
true
;
loading
.
value
=
true
;
const
userStore
=
useUserStore
();
const
userStore
=
useUserStore
();
userStore
.
getInfo
();
// 确保用户信息已加载
await
userStore
.
getInfo
();
// 确保用户信息已加载
const
roleKey
=
userStore
.
roles
[
0
];
// 获取当前用户的角色 ID
const
roleKey
=
userStore
.
roles
[
0
];
// 获取当前用户的角色 ID
console
.
log
(
"当前角色ID:"
,
roleKey
);
console
.
log
(
"当前角色id:"
,
roleKey
);
let
filterNode
;
if
(
roleKey
===
"common"
)
{
// 构建动态查询参数
filterNode
=
89
;
// 普通员工
const
params
=
{
}
else
if
(
roleKey
===
"hr"
)
{
...
queryParams
.
value
,
filterNode
=
90
;
// hr
currentNode
:
null
// 初始化参数
}
else
if
(
roleKey
===
"project-manager"
)
{
}
;
filterNode
=
91
;
// 项目经理
}
else
if
(
roleKey
===
"general-manager"
)
{
const
roleNodeMap
=
{
filterNode
=
92
;
// 总经理
'common'
:
89
,
// 普通员工
}
else
{
'hr'
:
90
,
// hr
filterNode
=
null
;
// 如果没有匹配到角色,则不过滤
'project-manager'
:
91
,
// 项目经理
}
'general-manager'
:
92
// 总经理
listConfirmationManage
(
queryParams
.
value
).
then
(
response
=>
{
}
;
// 根据角色过滤数据
let
filteredList
=
response
.
rows
;
if
(
filterNode
!==
null
)
{
filteredList
=
response
.
rows
.
filter
(
item
=>
item
.
currentNode
===
filterNode
);
}
confirmationmanageList
.
value
=
filteredList
;
// 设置过滤后的 total 数量
total
.
value
=
filteredList
.
length
;
if
(
roleNodeMap
[
roleKey
])
{
params
.
currentNode
=
roleNodeMap
[
roleKey
];
console
.
log
(
"当前角色-ID:"
,
params
.
currentNode
);
}
try
{
const
response
=
await
listConfirmationManage
(
params
);
confirmationmanageList
.
value
=
response
.
rows
;
total
.
value
=
response
.
total
;
loading
.
value
=
false
;
loading
.
value
=
false
;
}
);
}
catch
(
error
){
console
.
log
(
error
);
}
finally
{
loading
.
value
=
false
;
}
}
}
/** 搜索按钮操作 */
/** 搜索按钮操作 */
function
handleQuery
()
{
function
handleQuery
()
{
...
...
src/views/staffmanage/personalmanage/components/leavemanageApprove.vue
View file @
fe0e644f
...
@@ -360,37 +360,41 @@ function handleSelectionChange1(val) {
...
@@ -360,37 +360,41 @@ function handleSelectionChange1(val) {
this
.
selectedRows
=
val
;
this
.
selectedRows
=
val
;
}
}
/** 查询转正审批列表 */
/** 查询转正审批列表 */
function
getList
()
{
async
function
getList
()
{
loading
.
value
=
true
;
loading
.
value
=
true
;
const
userStore
=
useUserStore
();
const
userStore
=
useUserStore
();
userStore
.
getInfo
();
// 确保用户信息已加载
await
userStore
.
getInfo
();
// 确保用户信息已加载
const
roleKey
=
userStore
.
roles
[
0
];
// 获取当前用户的角色 ID
const
roleKey
=
userStore
.
roles
[
0
];
// 获取当前用户的角色 ID
console
.
log
(
"当前角色ID:"
,
roleKey
);
console
.
log
(
"当前角色id:"
,
roleKey
);
let
filterNode
;
if
(
roleKey
===
"common"
)
{
filterNode
=
106
;
// 普通员工
}
else
if
(
roleKey
===
"project-manager"
)
{
filterNode
=
107
;
// 项目经理
}
else
if
(
roleKey
===
"work-manage"
)
{
filterNode
=
108
;
// 工作交接人
}
else
if
(
roleKey
===
"hr"
)
{
filterNode
=
109
;
// hr
}
else
{
filterNode
=
null
;
// 如果没有匹配到角色,则不过滤
}
listLeaveManage
(
queryParams
.
value
).
then
(
response
=>
{
// 根据角色过滤数据
let
filteredList
=
response
.
rows
;
if
(
filterNode
!==
null
)
{
filteredList
=
response
.
rows
.
filter
(
item
=>
item
.
currentNode
===
filterNode
);
}
resignationList
.
value
=
filteredList
;
// 设置过滤后的 total 数量
total
.
value
=
filteredList
.
length
;
loading
.
value
=
false
;
// 构建动态查询参数
const
params
=
{
...
queryParams
.
value
,
currentNode
:
null
// 初始化参数
}
;
}
);
const
roleNodeMap
=
{
'common'
:
106
,
// 普通员工
'project-manager'
:
107
,
// 项目经理
'work-manage'
:
108
,
// 项目经理
'hr'
:
109
// hr
}
;
if
(
roleNodeMap
[
roleKey
])
{
params
.
currentNode
=
roleNodeMap
[
roleKey
];
console
.
log
(
"当前角色-ID:"
,
params
.
currentNode
);
}
try
{
const
response
=
await
listLeaveManage
(
params
);
resignationList
.
value
=
response
.
rows
;
total
.
value
=
response
.
total
;
loading
.
value
=
false
;
}
catch
(
error
){
console
.
log
(
error
);
}
finally
{
loading
.
value
=
false
;
}
}
}
/** 搜索按钮操作 */
/** 搜索按钮操作 */
function
handleQuery
()
{
function
handleQuery
()
{
...
...
src/views/staffmanage/personalmanage/components/onboardmanageApprove.vue
View file @
fe0e644f
...
@@ -303,6 +303,7 @@ const data = reactive({
...
@@ -303,6 +303,7 @@ const data = reactive({
educationLevel
:
null
,
educationLevel
:
null
,
employmentForm
:
null
,
employmentForm
:
null
,
employeeState
:
null
,
employeeState
:
null
,
currentNode
:
null
}
,
}
,
rules
:
{
}
rules
:
{
}
}
);
}
);
...
@@ -436,39 +437,41 @@ function fieldBeforeUpload(file) {
...
@@ -436,39 +437,41 @@ function fieldBeforeUpload(file) {
}
}
/** 查询入职审批列表 */
/** 查询入职审批列表 */
function
getList
()
{
async
function
getList
()
{
loading
.
value
=
true
;
loading
.
value
=
true
;
const
userStore
=
useUserStore
();
const
userStore
=
useUserStore
();
userStore
.
getInfo
();
// 确保用户信息已加载
await
userStore
.
getInfo
();
// 确保用户信息已加载
const
roleKey
=
userStore
.
roles
[
0
];
// 获取当前用户的角色 ID
const
roleKey
=
userStore
.
roles
[
0
];
// 获取当前用户的角色 ID
console
.
log
(
"当前角色ID:"
,
roleKey
);
console
.
log
(
"当前角色id:"
,
roleKey
);
let
filterNode
;
if
(
roleKey
===
"project-manager"
)
{
filterNode
=
101
;
// 项目经理
}
else
if
(
roleKey
===
"general-manager"
)
{
filterNode
=
102
;
// 总经理
}
else
if
(
roleKey
===
"hr"
)
{
filterNode
=
103
;
// HR
}
else
{
filterNode
=
null
;
// 如果没有匹配到角色,则不过滤
}
listOnBoardManage
(
queryParams
.
value
).
then
(
response
=>
{
// 根据角色过滤数据
let
filteredList
=
response
.
rows
;
if
(
filterNode
!==
null
)
{
filteredList
=
response
.
rows
.
filter
(
item
=>
item
.
currentNode
===
filterNode
);
}
// 设置过滤后的数据
// 构建动态查询参数
onboardmanageList
.
value
=
filteredList
;
const
params
=
{
...
queryParams
.
value
,
currentNode
:
null
// 初始化参数
}
;
// 设置过滤后的 total 数量
const
roleNodeMap
=
{
total
.
value
=
filteredList
.
length
;
'project-manager'
:
101
,
// 项目经理
'general-manager'
:
102
,
// 总经理
'hr'
:
103
// HR
}
;
if
(
roleNodeMap
[
roleKey
])
{
params
.
currentNode
=
roleNodeMap
[
roleKey
];
console
.
log
(
"当前角色-ID:"
,
params
.
currentNode
);
}
try
{
const
response
=
await
listOnBoardManage
(
params
);
onboardmanageList
.
value
=
response
.
rows
;
total
.
value
=
response
.
total
;
loading
.
value
=
false
;
loading
.
value
=
false
;
}
);
}
catch
(
error
){
console
.
log
(
error
);
}
finally
{
loading
.
value
=
false
;
}
}
}
/** 搜索按钮操作 */
/** 搜索按钮操作 */
function
handleQuery
()
{
function
handleQuery
()
{
queryParams
.
value
.
pageNum
=
1
;
queryParams
.
value
.
pageNum
=
1
;
...
@@ -592,10 +595,6 @@ function handleExport() {
...
@@ -592,10 +595,6 @@ function handleExport() {
onMounted
(()
=>
{
onMounted
(()
=>
{
const
userStore
=
useUserStore
();
const
userStore
=
useUserStore
();
userStore
.
getInfo
();
// 确保用户信息已加载
userStore
.
getInfo
();
// 确保用户信息已加载
const
currentUserId
=
userStore
.
id
;
// 获取当前用户的 id
const
RoleId
=
userStore
.
roles
[
0
];
// 获取当前用户的角色 ID
console
.
log
(
"当前用户 ID:"
,
currentUserId
);
console
.
log
(
"当前角色ID:"
,
RoleId
);
getList
();
getList
();
}
);
}
);
<
/script
>
<
/script
>
...
...
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