Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
R
rongtong-app
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
融通安全管理系统
rongtong-app
Commits
1ef2a6d0
Commit
1ef2a6d0
authored
Jun 29, 2023
by
胡占生
🇨🇳
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 创建任务,任务管理,接口联调对接修复
parent
f1c1237c
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
418 additions
and
205 deletions
+418
-205
src/views/riskProject/add/addInherent.vue
src/views/riskProject/add/addInherent.vue
+110
-1
src/views/riskProject/add/index.vue
src/views/riskProject/add/index.vue
+241
-132
src/views/riskProject/add/taskList.vue
src/views/riskProject/add/taskList.vue
+54
-56
src/views/riskProject/manage/index.vue
src/views/riskProject/manage/index.vue
+13
-16
No files found.
src/views/riskProject/add/addInherent.vue
View file @
1ef2a6d0
<
template
>
<div>
<LHeader
:text=
"text"
></LHeader>
<van-tabs
v-model=
"active"
color=
"#2980f7"
animated
>
<van-tab
title=
"固有风险信息"
>
<van-form
@
submit=
"onSubmit"
:scroll-to-error=
"true"
...
...
@@ -364,6 +368,69 @@
>
取消
</van-button
>
</div>
</van-tab>
<van-tab
title=
"现状风险"
>
<div
class=
"con-list"
@
touchmove=
"showIndex = null"
>
<van-cell-group
inset
v-for=
"(item, index) in messageList"
:key=
"index"
>
<div
style=
"font-size: 0.45rem;padding: 5px 0;"
>
{{item.title}}
</div>
<van-row
gutter=
""
>
<van-col
span=
"17"
>
<van-row
gutter=
""
>
<van-col
span=
"9"
>
风险系数:
</van-col>
<van-col
span=
"15"
>
{{ item.time}}
</van-col>
</van-row>
<van-row
gutter=
""
>
<van-col
span=
"9"
>
创建时间:
</van-col>
<van-col
span=
"15"
>
{{ item.name }}
</van-col>
</van-row>
<van-row
gutter=
""
>
<van-col
span=
"9"
>
风险描述:
</van-col>
<van-col
span=
"15"
>
{{ item.name }}
</van-col>
</van-row>
</van-col>
<van-col
span=
"7"
:style=
"{'color':item.state == 1 ? '#0069e5':'#03b615'}"
>
{{ '●待审批'}}
</van-col>
</van-row>
</van-cell-group>
<div
style=
"
width: 100%;
text-align: center;
font-size: 0.48rem;
position: fixed;
top: 30%;
"
v-if=
"messageList['length']==0"
>
暂无数据
</div>
</div>
</van-tab>
</van-tabs>
<div
style=
"display: flex;
justify-content: space-around;
background-color: #fff;
border-top: 1px solid #e3e3e3;
height: 1.5rem;
width: 100%;
text-align: center;
position: fixed;
bottom: 0;"
>
<div
@
click=
"performTasks"
style=
"color: #4bced0;font-size: 14px;font-weight: 600;"
>
<div
style=
"font-size: 22px;"
><van-icon
name=
"plus"
/></div>
<div>
新增现状风险
</div>
</div>
</div>
</div>
</template>
...
...
@@ -419,6 +486,7 @@ export default {
text
:
"
添加固有风险
"
,
id
:
""
,
isTimely
:
1
,
active
:
0
,
form
:{
},
...
...
@@ -432,6 +500,14 @@ export default {
factor
:
""
,
//风险因素
showFactor
:
false
,
columnsFactor
:
[],
messageList
:
[
{
title
:
'
回显风险源名称
'
,
time
:
'
2022-12-12
'
,
name
:
'
Mr.周
'
,
state
:
1
}
],
source
:
""
,
//风险源
showSource
:
false
,
columnsSource
:
[],
...
...
@@ -480,6 +556,9 @@ export default {
// this.getList();
},
methods
:
{
performTasks
(){
console
.
log
(
'
1233213 :>>
'
,
1233213
);
},
// 点击预览图
clickPre
(
e
)
{
console
.
log
(
e
);
...
...
@@ -703,6 +782,36 @@ export default {
},
};
</
script
>
<
style
scoped
>
<
style
lang=
"less"
scoped
>
/* @import url(); 引入css类 */
.con-list {
margin-bottom: 1.5rem;
padding: 0;
background-color: #f0f1f5;
.van-cell-group--inset {
margin: 0;
margin-bottom: 0.26667rem;
padding: 0.25rem;
font-size: 0.4rem;
position: relative;
border-radius: 4%;
box-shadow: 0px 0px 10px 2px #f3f3f3;
width: 90%;
margin: 0.4rem auto;
.van-row {
font-size: 0.4rem;
line-height: 0.8rem;
margin-bottom: 0;
}
.van-overlay {
position: absolute;
.wrapper {
display: flex;
align-items: center;
justify-content: space-evenly;
height: 100%;
}
}
}
}
</
style
>
src/views/riskProject/add/index.vue
View file @
1ef2a6d0
This diff is collapsed.
Click to expand it.
src/views/riskProject/add/taskList.vue
View file @
1ef2a6d0
...
...
@@ -6,9 +6,25 @@
</van-sticky>
<div
style=
"margin-bottom: 1.5rem;"
>
<van-grid
:column-num=
"3"
style=
"background-color: #fff;"
>
<van-grid-item
v-for=
"value in 5"
:key=
"value"
>
<van-grid-item
>
<div>
发起人员:
</div>
<div>
李小明
</div>
<div>
{{
messageList
.
createUserName
}}
</div>
</van-grid-item>
<van-grid-item
>
<div>
项目负责人:
</div>
<div>
{{
messageList
.
leaderUserName
}}
</div>
</van-grid-item>
<van-grid-item
>
<div>
任务状态:
</div>
<div>
{{
messageList
.
status
}}
</div>
</van-grid-item>
<van-grid-item
>
<div>
开始时间:
</div>
<div>
{{
timestampToTimes
(
messageList
.
startTime
)
||
messageList
.
startTime
}}
</div>
</van-grid-item>
<van-grid-item
>
<div>
结束时间:
</div>
<div>
{{
timestampToTimes
(
messageList
.
endTime
)
||
messageList
.
endTime
}}
</div>
</van-grid-item>
</van-grid>
<van-steps
:active=
"active"
active-icon=
"success"
active-color=
"#38f"
style=
"margin: 0.26rem 0;"
>
...
...
@@ -29,47 +45,53 @@
>
<van-field
readonly
name=
"creat
By
"
:value=
"form.creat
By
"
name=
"creat
eUserName
"
:value=
"form.creat
eUserName
"
label=
"创建人员"
input-align=
"right"
:rules=
"[
{ required: true, message: '创建人员不能为空' }]"
/>
<van-field
readonly
name=
"creat
Unit
"
:value=
"form.creat
Unit
"
name=
"creat
eDeptName
"
:value=
"form.creat
eDeptName
"
label=
"创建单位"
input-align=
"right"
:rules=
"[
{ required: true, message: '创建单位不能为空' }]"
/>
<van-field
readonly
name=
"
task
Name"
:value=
"form.
task
Name"
name=
"
project
Name"
:value=
"form.
project
Name"
label=
"任务名称"
input-align=
"right"
:rules=
"[
{ required: true, message: '任务名称不能为空' }]"
/>
<van-field
readonly
name=
"
sourc
e"
:value=
"form.
sourc
e"
name=
"
projectNam
e"
:value=
"form.
projectNam
e"
label=
"关联项目"
input-align=
"right"
:rules=
"[
{ required: true, message: '关联项目不能为空' }]"
/>
<van-field
readonly
name=
"
taskName
"
:value=
"form.
taskName
"
name=
"
buildingNames
"
:value=
"form.
buildingNames
"
label=
"评估楼栋"
input-align=
"right"
:rules=
"[
{ required: true, message: '评估楼栋不能为空' }]"
/>
<van-field
readonly
name=
"
troubl
e"
:value=
"form.
troubl
e"
name=
"
leaderUserNam
e"
:value=
"form.
leaderUserNam
e"
label=
"项目负责人"
input-align=
"right"
:rules=
"[
{ required: true, message: '事故类型不能为空' }]"
/>
...
...
@@ -79,10 +101,7 @@
readonly
name=
"location"
label=
"任务开始时间"
type=
"textarea"
maxlength=
"255"
rows=
"1"
autosize
input-align=
"right"
:rules=
"[
{ required: true, message: '任务开始时间不能为空' }]"
/>
...
...
@@ -91,19 +110,16 @@
readonly
name=
"location"
label=
"任务结束时间"
type=
"textarea"
maxlength=
"255"
rows=
"1"
autosize
input-align=
"right"
:rules=
"[
{ required: true, message: '任务结束时间不能为空' }]"
/>
<van-field
clickable
required
name=
"control"
:value=
"form.control"
name=
"workUserNames"
:value=
"form.workUserNames"
label=
"执行人员"
input-align=
"right"
:rules=
"[
{ required: true, message: '执行人员不能为空' }]"
/>
</van-form>
...
...
@@ -213,6 +229,7 @@
<
script
>
import
LHeader
from
"
@/components/header.vue
"
;
import
{
timestampToTime
,
generateId
}
from
"
@/utils/format
"
;
import
{
getFun
,
postFun
}
from
"
@/service/table.js
"
;
export
default
{
name
:
'
risk-confirme
'
,
...
...
@@ -224,28 +241,8 @@
text
:
"
任务单
"
,
searchValue
:
""
,
isHaveNews
:
false
,
messageList
:
[
{
title
:
'
XX项目评估任务单
'
,
time
:
'
2022-12-12
'
,
name
:
'
Mr.周
'
,
state
:
1
}
],
riskLogList
:[
{
completedTime
:
'
审批通过
'
,
startTime
:
'
2022-12-12
'
,
approvalUserName
:
'
Mr.周
'
,
taskName
:
'
审批负责人
'
},
{
completedTime
:
'
审批通过
'
,
startTime
:
'
2022-12-12
'
,
approvalUserName
:
'
Mr.周
'
,
taskName
:
'
审批负责人
'
},
],
messageList
:
[],
riskLogList
:[],
Loop
:
""
,
// 定时器
showIndex
:
null
,
// 是否显示遮罩层,
active
:
0
,
...
...
@@ -257,9 +254,13 @@
};
},
created
()
{
// this.postList();s
var
planId
=
this
.
$route
.
params
.
id
this
.
postList
(
planId
);
},
methods
:
{
timestampToTimes
(
time
){
return
timestampToTime
(
new
Date
(
time
),
"
DT2
"
,
true
)
},
performTasks
(){
this
.
$router
.
push
({
name
:
"
riskInherent
"
,
...
...
@@ -276,23 +277,20 @@
},
})
},
postList
(
select
=
""
)
{
postList
(
id
)
{
this
.
$toast
.
loading
({
message
:
"
加载中...
"
,
forbidClick
:
true
,
loadingType
:
"
spinner
"
,
duration
:
0
,
});
let
formdata
=
new
FormData
();
formdata
.
append
(
"
select
"
,
select
);
postFun
(
this
.
tabs
[
this
.
active
][
'
api
'
],
formdata
)
getFun
(
`/risk/plan/details/
${
id
}
`
)
.
then
((
res
)
=>
{
console
.
log
(
'
%c [ res ]-309
'
,
'
font-size:13px; background:pink; color:#bf2c9f;
'
,
res
)
this
.
$toast
.
clear
();
this
.
messageList
=
res
.
data
||
res
.
rows
;
// 判断有无数据返回
if
(
this
.
messageList
.
length
==
0
)
{
this
.
isHaveNews
=
true
;
}
this
.
form
=
this
.
messageList
.
detailsDto
console
.
log
(
'
%c [ messageList ]-292
'
,
'
font-size:13px; background:pink; color:#bf2c9f;
'
,
this
.
messageList
)
})
.
catch
(()
=>
{
this
.
$toast
.
clear
();
...
...
src/views/riskProject/manage/index.vue
View file @
1ef2a6d0
...
...
@@ -40,17 +40,17 @@
:key=
"index"
@
click=
"touchstart(index, item)"
>
<div
style=
"font-size: 0.45rem;padding: 5px 0;"
>
{{item.
titl
e}}
</div>
<div
style=
"font-size: 0.45rem;padding: 5px 0;"
>
{{item.
nam
e}}
</div>
<van-row
gutter=
""
>
<van-col
span=
"17"
>
<van-row
gutter=
""
>
<van-col
span=
"9"
>
发起时间:
</van-col>
<van-col
span=
"15"
>
{{
item.time
}}
</van-col>
<van-col
span=
"15"
>
{{
timestampToTimes(item.startTime)||item.startTime
}}
</van-col>
</van-row>
<van-row
gutter=
""
>
<van-col
span=
"9"
>
处理人员:
</van-col>
<van-col
span=
"15"
>
{{ item.
n
ame }}
</van-col>
<van-col
span=
"15"
>
{{ item.
leaderUserN
ame }}
</van-col>
</van-row>
</van-col>
<van-col
span=
"7"
:style=
"{'color':item.state == 1 ? '#0069e5':'#03b615'}"
>
...
...
@@ -102,6 +102,7 @@
<
script
>
import
LHeader
from
"
@/components/header.vue
"
;
import
{
timestampToTime
,
generateId
}
from
"
@/utils/format
"
;
import
{
getFun
,
postFun
}
from
"
@/service/table.js
"
;
// import { postriskConList } from "@/service/risk";
export
default
{
...
...
@@ -115,13 +116,6 @@
searchValue
:
""
,
isHaveNews
:
false
,
messageList
:
[
{
title
:
'
XX项目评估任务单
'
,
time
:
'
2022-12-12
'
,
name
:
'
Mr.周
'
,
state
:
1
,
id
:
12
}
],
Loop
:
""
,
// 定时器
showIndex
:
null
,
// 是否显示遮罩层,
...
...
@@ -129,19 +123,22 @@
tabs
:
[
{
title
:
"
未执行
"
,
api
:
"
/risk
Confirm/list
"
,
api
:
"
/risk
/plan/create/list?status=finish
"
,
},
{
title
:
"
已执行
"
,
api
:
"
/risk
Confirm/finishList
"
,
api
:
"
/risk
/plan/create/list?status=running
"
,
},
],
};
},
created
()
{
// this.postList();s
this
.
postList
();
},
methods
:
{
timestampToTimes
(
time
){
return
timestampToTime
(
new
Date
(
time
),
"
DT1
"
,
true
)
},
handadd
(){
this
.
$router
.
push
({
name
:
"
riskAdd
"
,
...
...
@@ -157,9 +154,9 @@
loadingType
:
"
spinner
"
,
duration
:
0
,
});
let
formdata
=
new
FormData
();
formdata
.
append
(
"
select
"
,
select
);
postFun
(
this
.
tabs
[
this
.
active
][
'
api
'
],
formdata
)
//
let formdata = new FormData();
//
formdata.append("select", select);
getFun
(
this
.
tabs
[
this
.
active
][
'
api
'
]
)
.
then
((
res
)
=>
{
this
.
$toast
.
clear
();
this
.
messageList
=
res
.
data
||
res
.
rows
;
...
...
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