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
bf20e3da
Commit
bf20e3da
authored
Apr 03, 2025
by
qiyaxin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
出差申请审批查询
parent
0d27cccb
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
80 additions
and
30 deletions
+80
-30
projectCostRequestApprove.vue
...xamineAndApprove/components/projectCostRequestApprove.vue
+21
-5
tripApplicationApprove.vue
...e/examineAndApprove/components/tripApplicationApprove.vue
+59
-25
No files found.
src/views/costManage/examineAndApprove/components/projectCostRequestApprove.vue
View file @
bf20e3da
...
@@ -182,10 +182,19 @@ const queryParams = reactive({
...
@@ -182,10 +182,19 @@ const queryParams = reactive({
})
})
//一键通过
//一键通过
const
oneClickPass
=
()
=>
{
const
oneClickPass
=
()
=>
{
if
(
!
passObjList
.
length
)
return
ElMessage
({
if
(
!
passObjList
.
length
)
return
ElMessage
({
message
:
'请先选择数据项'
,
message
:
'请先选择数据项'
,
type
:
'error'
type
:
'error'
})
})
// 为每条数据添加通过时间
const
now
=
new
Date
();
const
passTime
=
`
${
now
.
getFullYear
()}
-
${
String
(
now
.
getMonth
()
+
1
).
padStart
(
2
,
'0'
)}
-
${
String
(
now
.
getDate
()).
padStart
(
2
,
'0'
)}
${
String
(
now
.
getHours
()).
padStart
(
2
,
'0'
)}
:
${
String
(
now
.
getMinutes
()).
padStart
(
2
,
'0'
)}
:
${
String
(
now
.
getSeconds
()).
padStart
(
2
,
'0'
)}
`
;
passObjList
.
forEach
(
item
=>
{
item
.
passTime
=
passTime
;
});
projectCostPass
(
passObjList
).
then
(
res
=>
{
projectCostPass
(
passObjList
).
then
(
res
=>
{
if
(
res
.
code
===
200
){
if
(
res
.
code
===
200
){
getList
()
getList
()
...
@@ -333,14 +342,22 @@ const passProjectCost = (row)=>{
...
@@ -333,14 +342,22 @@ const passProjectCost = (row)=>{
//获取currentAuditRoleId的下标
//获取currentAuditRoleId的下标
let
index
=
allList
.
value
.
findIndex
(
item
=>
item
.
nodeId
===
currentAuditRoleId
)
let
index
=
allList
.
value
.
findIndex
(
item
=>
item
.
nodeId
===
currentAuditRoleId
)
// 获取通过时间
const
now
=
new
Date
();
const
passTime
=
`
${
now
.
getFullYear
()}
-
${
String
(
now
.
getMonth
()
+
1
).
padStart
(
2
,
'0'
)}
-
${
String
(
now
.
getDate
()).
padStart
(
2
,
'0'
)}
${
String
(
now
.
getHours
()).
padStart
(
2
,
'0'
)}
:
${
String
(
now
.
getMinutes
()).
padStart
(
2
,
'0'
)}
:
${
String
(
now
.
getSeconds
()).
padStart
(
2
,
'0'
)}
`
;
let
obj
=
{
let
obj
=
{
//项目费用id
//项目费用id
projectCostId
:
row
.
id
,
projectCostId
:
row
.
id
,
//下一个节点nodeId
//下一个节点nodeId
nextNodeId
:
null
,
nextNodeId
:
null
,
//是否终审
//是否终审
isEndApproval
:
false
isEndApproval
:
false
,
// pm通过时间
pmPassTime
:
passTime
}
}
console
.
log
(
55555
,
obj
)
//判断是不是最后一个下标
//判断是不是最后一个下标
if
((
allList
.
value
.
length
-
1
)
===
index
){
if
((
allList
.
value
.
length
-
1
)
===
index
){
//最后一个下标的话
//最后一个下标的话
...
@@ -352,7 +369,6 @@ const passProjectCost = (row)=>{
...
@@ -352,7 +369,6 @@ const passProjectCost = (row)=>{
obj
.
isEndApproval
=
false
obj
.
isEndApproval
=
false
}
}
projectCostPass
([
obj
]).
then
(
res
=>
{
projectCostPass
([
obj
]).
then
(
res
=>
{
console
.
log
(
"响应"
,
res
)
console
.
log
(
"响应"
,
res
)
if
(
res
.
code
===
200
){
if
(
res
.
code
===
200
){
...
...
src/views/costManage/examineAndApprove/components/tripApplicationApprove.vue
View file @
bf20e3da
...
@@ -7,39 +7,44 @@
...
@@ -7,39 +7,44 @@
<el-select
<el-select
v-model=
"queryParams.projectName"
v-model=
"queryParams.projectName"
placeholder=
"请选择项目名称"
placeholder=
"请选择项目名称"
style=
"width: 220px"
clearable
clearable
filterable
style=
"width: 220px"
>
>
<el-option
<el-option
v-for=
"item in projectNameList"
v-for=
"item in projectNameList"
:key=
"item"
:key=
"item"
:label=
"item"
:label=
"item"
:value=
"item"
/>
:value=
"item"
style=
"width: 220px"
/>
</el-select>
</el-select>
</el-form-item>
</el-form-item>
<el-form-item
label=
"项目经理"
prop=
"project
ManagerId
"
>
<el-form-item
label=
"项目经理"
prop=
"project
UserName
"
>
<el-select
<el-select
v-model=
"queryParams.projectUserName"
v-model=
"queryParams.projectUserName"
filterable
placeholder=
"请选择项目经理"
placeholder=
"请选择项目经理"
style=
"width: 220px"
style=
"width: 220px"
clearable
clearable
>
>
<el-option
<el-option
v-for=
"item in project
Manag
erNameList"
v-for=
"item in project
Us
erNameList"
:key=
"item.projectManagerName"
:key=
"item.projectManagerName"
:label=
"item.projectManagerName"
:label=
"item.projectManagerName"
:value=
"item.projectManagerName"
/>
:value=
"item.projectManagerName"
/>
</el-select>
</el-select>
</el-form-item>
</el-form-item>
<el-form-item
label=
"审批状态"
prop=
"
projectS
tatus"
>
<el-form-item
label=
"审批状态"
prop=
"
s
tatus"
>
<el-select
<el-select
v-model=
"queryParams.
projectS
tatus"
v-model=
"queryParams.
s
tatus"
placeholder=
"请选择项目状态"
placeholder=
"请选择项目状态"
style=
"width: 220px"
style=
"width: 220px"
clearable
clearable
>
>
<el-option
<el-option
v-for=
"dict in
project
_status"
v-for=
"dict in
cost_daily
_status"
:key=
"dict.value"
:key=
"dict.value"
:label=
"dict.label"
:label=
"dict.label"
:value=
"dict.value"
:value=
"dict.value"
...
@@ -48,14 +53,14 @@
...
@@ -48,14 +53,14 @@
</el-form-item>
</el-form-item>
<!-- 操作按钮 -->
<!-- 操作按钮 -->
<el-form-item
style=
"padding-left: 5.4%"
>
<el-form-item
style=
"padding-left: 5.4%"
>
<el-button
type=
"default"
class=
"el-button-defalut"
icon=
"Refresh"
@
click=
"rese
t"
>
重置
</el-button>
<el-button
icon=
"Refresh"
@
click=
"resetQuery"
class=
"el-button-defalu
t"
>
重置
</el-button>
<el-button
type=
"primary"
class=
"el-button-primary"
icon=
"Search"
@
click=
"getList
"
>
查询
</el-button>
<el-button
type=
"primary"
icon=
"Search"
@
click=
"handleQuery"
class=
"el-button-primary
"
>
查询
</el-button>
<!--
<el-button
size=
"large"
type=
"text"
@
click=
"toggleSearch"
>
--
>
<el-button
size=
"large"
type=
"text"
@
click=
"toggleSearch"
>
<!--
{{
isExpanded
?
' 收起'
:
' 展开'
}}
-->
{{
isExpanded
?
' 收起'
:
' 展开'
}}
<!--
<el-icon
class=
"el-icon--right"
>
--
>
<el-icon
class=
"el-icon--right"
>
<!--
<arrow-down
/>
--
>
<arrow-down
/
>
<!--
</el-icon>
--
>
</el-icon
>
<!--
</el-button>
--
>
</el-button
>
</el-form-item>
</el-form-item>
<!-- 可折叠的查询条件 -->
<!-- 可折叠的查询条件 -->
<transition>
<transition>
...
@@ -64,7 +69,7 @@
...
@@ -64,7 +69,7 @@
<el-select
<el-select
v-model=
"queryParams.projectType"
v-model=
"queryParams.projectType"
placeholder=
"请选择项目类型"
placeholder=
"请选择项目类型"
style=
"width:
193
px"
style=
"width:
220
px"
clearable
clearable
>
>
<el-option
<el-option
...
@@ -194,13 +199,14 @@ import FlowChart from '@/components/FlowChart/index.vue'
...
@@ -194,13 +199,14 @@ import FlowChart from '@/components/FlowChart/index.vue'
import
{
listTripApplication
,
projectList
}
from
"../../../../api/costManage/cost.js"
;
import
{
listTripApplication
,
projectList
}
from
"../../../../api/costManage/cost.js"
;
import
{
ElMessage
}
from
"element-plus"
;
import
{
ElMessage
}
from
"element-plus"
;
import
{
import
{
getApproveNodeList
,
getApproveNodeList
,
getProjectManagerName
,
getProjectName
,
getProjectName
,
getRoleId
,
getRoleId
,
tripApplicationApproval
,
tripApplicationApproval
,
tripApplicationPassNotPass
tripApplicationPassNotPass
}
from
"../../../../api/examineAndApprove/examineAndApprove.js"
;
}
from
"../../../../api/examineAndApprove/examineAndApprove.js"
;
import
{
useRouter
}
from
"vue-router"
;
import
{
useRouter
}
from
"vue-router"
;
import
{
ArrowDown
}
from
"@element-plus/icons-vue"
;
const
router
=
useRouter
();
const
router
=
useRouter
();
const
{
project_status
,
cost_daily_status
,
project_type
}
=
proxy
.
useDict
(
'project_status'
,
'cost_daily_status'
,
'project_type'
);
const
{
project_status
,
cost_daily_status
,
project_type
}
=
proxy
.
useDict
(
'project_status'
,
'cost_daily_status'
,
'project_type'
);
...
@@ -208,6 +214,13 @@ const list = ref([]) // 流程图内容,只有值
...
@@ -208,6 +214,13 @@ const list = ref([]) // 流程图内容,只有值
const
allList
=
ref
([])
// 流程图内容,值和角色id
const
allList
=
ref
([])
// 流程图内容,值和角色id
const
total
=
ref
(
0
);
const
total
=
ref
(
0
);
const
projectNameList
=
ref
([]);
const
projectNameList
=
ref
([]);
const
projectUserNameList
=
ref
([]);
// 更多搜索框
const
isExpanded
=
ref
(
false
);
// 切换展开/折叠状态
const
toggleSearch
=
()
=>
{
isExpanded
.
value
=
!
isExpanded
.
value
;
}
//当前登录用户角色组
//当前登录用户角色组
const
currentUserRoleInfoList
=
ref
([])
const
currentUserRoleInfoList
=
ref
([])
...
@@ -230,11 +243,14 @@ const dialogFormVisible = ref(false)
...
@@ -230,11 +243,14 @@ const dialogFormVisible = ref(false)
const
changProjectNumber
=
ref
(
''
)
const
changProjectNumber
=
ref
(
''
)
const
stepActive
=
ref
(
1
)
const
stepActive
=
ref
(
1
)
const
queryParams
=
reactive
({
const
queryParams
=
reactive
({
pageNum
:
1
,
pageNum
:
1
,
pageSize
:
10
,
pageSize
:
10
,
projectName
:
null
,
projectNumber
:
null
,
projectType
:
null
,
projectName
:
null
,
status
:
null
projectType
:
null
,
projectUserName
:
null
,
tripStartDate
:
null
,
status
:
null
,
})
})
...
@@ -242,14 +258,32 @@ const queryParams = reactive({
...
@@ -242,14 +258,32 @@ const queryParams = reactive({
const
getAllProjectName
=
()
=>
{
const
getAllProjectName
=
()
=>
{
getProjectName
(
queryParams
).
then
(
response
=>
{
getProjectName
(
queryParams
).
then
(
response
=>
{
projectNameList
.
value
=
response
.
data
;
projectNameList
.
value
=
response
.
data
;
//
console.log("项目名称",projectNameList.value)
console
.
log
(
"项目名称"
,
projectNameList
.
value
)
});
});
}
}
getAllProjectName
()
getAllProjectName
()
// 搜索表单——获取所有项目经理
const
getAllProjectUserName
=
()
=>
{
getProjectManagerName
(
queryParams
).
then
(
response
=>
{
projectUserNameList
.
value
=
response
.
data
;
console
.
log
(
"项目经理"
,
projectUserNameList
.
value
)
});
}
getAllProjectUserName
()
// 搜索按钮
function
handleQuery
()
{
queryParams
.
pageNum
=
1
;
getList
();
}
// 重置表单
// 重置表单
const
reset
=
()
=>
{
const
resetQuery
=
()
=>
{
queryParams
.
projectNumber
=
null
queryParams
.
projectName
=
null
queryParams
.
projectName
=
null
queryParams
.
projectType
=
null
queryParams
.
projectType
=
null
queryParams
.
projectUserName
=
null
queryParams
.
tripStartDate
=
null
queryParams
.
status
=
null
queryParams
.
status
=
null
getList
()
getList
()
}
}
...
...
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