Commit 3e28a55e authored by yf's avatar yf

Merge branch 'develop' of http://git.censoft.com.cn/rongtong/rongtong-app into dev-yf'

parents fa2a3f85 b6065533
...@@ -354,7 +354,7 @@ export default { ...@@ -354,7 +354,7 @@ export default {
created() { created() {
if (this.$route.params.inherentId) { if (this.$route.params.inherentId) {
this.inherentId = this.$route.params.inherentId this.inherentId = this.$route.params.inherentId
this.buildingIds = this.$route.params.buildingIds this.buildingIds = this.$route.params.buildingId
this.postReturnEcho(); this.postReturnEcho();
} }
// this.getList(); // this.getList();
...@@ -458,6 +458,11 @@ export default { ...@@ -458,6 +458,11 @@ export default {
params: { params: {
id: this.inherentId, id: this.inherentId,
// planId:this.planId // planId:this.planId
buildingId:this.buildingId,
planId:this.inherentId,
floorId:this.form.floorId,
roomName:this.form.roomName,
roomId:this.form.roomId,
}, },
}) })
}, },
......
<template> <template>
<div> <div>
<LHeader :text="text"></LHeader> <LHeader :text="text"></LHeader>
<van-form <van-form
@submit="onSubmit" @submit="onSubmit"
:scroll-to-error="true" :scroll-to-error="true"
...@@ -466,11 +465,16 @@ export default { ...@@ -466,11 +465,16 @@ export default {
var userInfo=getUserInfo() var userInfo=getUserInfo()
this.form.buildingIds=this.$route.params.id this.form.buildingIds=this.$route.params.id
this.form.planId=this.$route.params.planId this.form.planId=this.$route.params.planId
this.form.floorId = this.$route.params.floorId
this.form.roomId = this.$route.params.roomId
this.form.inherentId = this.$route.params.id
this.form.roomName = this.$route.params.roomName
this.form.buildingName = '1号楼' this.form.buildingName = '1号楼'
this.form.userId=userInfo.userId this.form.userId=userInfo.userId
this.form.userName=userInfo.userName this.form.userName=userInfo.userName
this.form.deptName=userInfo.dept.deptName this.form.deptName=userInfo.dept.deptName
this.form.projectId='测试项目' this.form.projectId='测试项目'
}, },
methods: { methods: {
seletFloor(name){ seletFloor(name){
...@@ -600,7 +604,8 @@ export default { ...@@ -600,7 +604,8 @@ export default {
onSubmit(values) { onSubmit(values) {
// console.log('%c [ values ]-592', 'font-size:13px; background:pink; color:#bf2c9f;', values) // console.log('%c [ values ]-592', 'font-size:13px; background:pink; color:#bf2c9f;', values)
var formDataJson=this.jsonToFormData(this.form) var formDataJson=this.jsonToFormData(this.form)
let url = "/risk/plan/inherent"; // let url = "/risk/plan/inherent";
let url = "/risk/plan/existing";
values.hdPicture1.forEach((item) => { values.hdPicture1.forEach((item) => {
if (item.file) { if (item.file) {
formDataJson.append("pictureFile[]", item.file); formDataJson.append("pictureFile[]", item.file);
......
...@@ -51,10 +51,10 @@ ...@@ -51,10 +51,10 @@
:value="form.projectName" :value="form.projectName"
label="关联项目" label="关联项目"
placeholder="请选择" placeholder="请选择"
@click="showSource = true" @click="show = true"
:rules="[{ required: true, message: '关联项目不能为空' }]" :rules="[{ required: true, message: '关联项目不能为空' }]"
/> />
<van-popup v-model="showSource" position="bottom"> <!-- <van-popup v-model="showSource" position="bottom">
<van-picker <van-picker
show-toolbar show-toolbar
value-key="name" value-key="name"
...@@ -62,7 +62,7 @@ ...@@ -62,7 +62,7 @@
@confirm="onConSource" @confirm="onConSource"
@cancel="showSource = false" @cancel="showSource = false"
/> />
</van-popup> </van-popup> -->
<van-field <van-field
required required
...@@ -167,7 +167,7 @@ ...@@ -167,7 +167,7 @@
</van-popup> </van-popup>
<van-popup v-model="show" position="bottom" :style="{ height: '100%' }"> <van-popup v-model="show" position="bottom" :style="{ height: '100%' }">
<!-- <selectPeople @onClose="onClose" @onSave="onSave"></selectPeople> --> <selectPeople @onClose="onClose" @onSave="onSave"></selectPeople>
</van-popup> </van-popup>
<van-popup <van-popup
...@@ -196,6 +196,7 @@ ...@@ -196,6 +196,7 @@
<div style="display:flex;margin-top: 44px;"> <div style="display:flex;margin-top: 44px;">
<van-checkbox-group <van-checkbox-group
v-model="riskList" v-model="riskList"
ref="checkboxGroup"
style="width: 100%;font-size: 18px;" style="width: 100%;font-size: 18px;"
> >
<van-checkbox <van-checkbox
...@@ -207,6 +208,10 @@ ...@@ -207,6 +208,10 @@
>{{ item[filedName] }}</van-checkbox >{{ item[filedName] }}</van-checkbox
> >
</van-checkbox-group> </van-checkbox-group>
<div>
<van-button type="primary" @click="checkAll">全选</van-button>
<van-button type="info" @click="toggleAll">反选</van-button>
</div>
</div> </div>
</van-popup> </van-popup>
...@@ -268,7 +273,7 @@ ...@@ -268,7 +273,7 @@
<script> <script>
import LHeader from "@/components/header.vue"; import LHeader from "@/components/header.vue";
import selectDept from "@/components/selectDept/index.vue"; import selectDept from "@/components/selectDept/index.vue";
// import selectPeople from "@/views/riskTask/selectPeople/index.vue"; import selectPeople from "@/views/riskProject/add/projectList.vue";
import { timestampToTime, generateId } from "@/utils/format"; import { timestampToTime, generateId } from "@/utils/format";
import { import {
getUserInfo, getUserInfo,
...@@ -276,19 +281,12 @@ import { ...@@ -276,19 +281,12 @@ import {
setLocalUserInfo setLocalUserInfo
} from "@/utils/userInfo"; } from "@/utils/userInfo";
import { getFun, postFun } from "@/service/table.js"; import { getFun, postFun } from "@/service/table.js";
// import {
// getFormList,
// postHdSource,
// postHdType,
// postHdPeople,
// postReAdd,
// postriskConiCause,
// postRiskShowMeasures,
// } from "@/service/risk";
export default { export default {
name: "risk-add", name: "risk-add",
components: { components: {
LHeader, LHeader,
selectPeople,
selectDept selectDept
}, },
beforeRouteLeave(to, from, next) { beforeRouteLeave(to, from, next) {
...@@ -368,6 +366,12 @@ export default { ...@@ -368,6 +366,12 @@ export default {
// this.getList(); // this.getList();
}, },
methods: { methods: {
checkAll() {
this.$refs.checkboxGroup.toggleAll(true);
},
toggleAll() {
this.$refs.checkboxGroup.toggleAll();
},
// 确定时间的方法 // 确定时间的方法
onConTime(date) { onConTime(date) {
console.log( console.log(
...@@ -400,7 +404,7 @@ export default { ...@@ -400,7 +404,7 @@ export default {
loadingType: "spinner", loadingType: "spinner",
duration: 0 duration: 0
}); });
getFun(`/risk/plan/user/list/${this.form.projectId}`).then(res => { getFun(`/risk/plan/user/list/${this.form.deptId}`).then(res => {
if (res.code == 200) { if (res.code == 200) {
this.columnsTrouble = res.data; this.columnsTrouble = res.data;
// 对数据进行赋值 // 对数据进行赋值
...@@ -460,7 +464,7 @@ export default { ...@@ -460,7 +464,7 @@ export default {
loadingType: "spinner", loadingType: "spinner",
duration: 0 duration: 0
}); });
getFun(`/risk/plan/user/list/${this.form.projectId}`).then(res => { getFun(`/risk/plan/user/list/${this.form.deptId}`).then(res => {
if (res.code == 200) { if (res.code == 200) {
this.riskModelList = res.data; this.riskModelList = res.data;
// 对数据进行赋值 // 对数据进行赋值
...@@ -742,8 +746,8 @@ export default { ...@@ -742,8 +746,8 @@ export default {
this.show = false; this.show = false;
}, },
onSave(e) { onSave(e) {
this.projectDirector = e[0].loginName; this.form.projectId = e.id;
this.projectDirectorName = e[0].userName; this.form.projectName = e.name;
this.show = false; this.show = false;
} }
}, },
......
...@@ -16,7 +16,6 @@ ...@@ -16,7 +16,6 @@
<div style="font-size: 0.45rem;padding: 5px 0;"> <div style="font-size: 0.45rem;padding: 5px 0;">
{{ item.title }} {{ item.title }}
</div> </div>
<van-row gutter=""> <van-row gutter="">
<van-col span="17"> <van-col span="17">
<van-row gutter=""> <van-row gutter="">
...@@ -263,11 +262,16 @@ export default { ...@@ -263,11 +262,16 @@ export default {
}, },
// 详情 // 详情
goDetail(data) { goDetail(data) {
sessionStorage.setItem('buildingId',this.buildingId)
sessionStorage.setItem('planId',this.planId)
sessionStorage.setItem('buildingName',this.buildingName)
this.$router.push({ this.$router.push({
name: "addCurrent", name: "addCurrent",
params: { params: {
inherentId: data.businessId || data.id, inherentId: data.businessId || data.id,
buildingIds: this.active planId: this.planId,
buildingId:this.buildingId,
buildingName:this.buildingName
} }
}); });
this.showIndex = null; this.showIndex = null;
......
<template>
<div>
<!-- 搜索 -->
<div class="content-wrap">
<div class="search-wrap">
<van-search v-model="searchVal" placeholder="搜索" @input="onInput"/>
</div>
</div>
<div style="margin-bottom: 1.4rem;">
<van-radio-group v-model="radio">
<van-list
v-model="loading"
:finished="finished"
finished-text="没有更多了"
@load="getInsideUser()"
>
<van-radio v-for="item in projectList" :name="item.id" :key="item.id" @click="selData(item)">
<van-cell :title="item.name" />
</van-radio>
</van-list>
</van-radio-group>
</div>
<!-- 底部信息 -->
<footer class="footer">
<van-cell-group>
<div class="operate">
<van-button
size="small"
ttype="info"
plain
native-type="button"
style="border-radius: 5px; background-color: #f0f1f5;"
@click.native="cancel"
>取消
</van-button
>
<van-button
size="small"
type="info"
native-type="button"
style="margin:0 10px 0 20px;border-radius: 5px;"
@click.native="save"
>保存
</van-button
>
</div>
</van-cell-group>
</footer>
</div>
</template>
<script>
// import LHeader from "@/components/header.vue";
import {getFun, postFun} from '@/service/table';
import {getUserInfo} from "@/utils/userInfo";
import {debounce} from "@/utils/common.js";
export default {
name: "select-people",
components: {
// LHeader
},
created() {
},
data() {
return {
text: "选择人员",
personName: "",
searchVal: "",
radio: "",
pageSize: 20,
pageNum: 1,
loading: false,
finished: false,
projectList:[],
itemSel:{
}
};
},
methods: {
// 查询内部人员
getInsideUser() {
var obj={
name:this.searchVal,
pageSize:this.pageSize,
pageNum:this.pageNum,
}
getFun("risk/plan/project/list", obj)
.then(res => {
this.projectList.push(...res.rows)
this.loading = false;
if (this.projectList.length >= res.total) {
this.finished = true;
}
if(!(this.pageNum*this.pageSize-this.total>=0)){
this.pageNum++;
}
})
},
// 待搜索框内容发生变化
onInput: debounce(function () {
this.projectList=[]
this.pageNum=1
this.finished = false
this.loading = true
this.getInsideUser();
}, 800),
selData(e){
this.itemSel=e
},
save() {
this.$emit('onSave', this.itemSel)
},
cancel() {
this.$emit('onClose')
}
}
};
</script>
<style lang="less" scoped>
/* @import url(); 引入css类 */
// 搜索
.content-wrap {
padding: 10px;
background-color: #f0f1f5;
}
.search-wrap {
margin: 0.26667rem;
.van-search {
border-radius: 5px;
padding: 5px 12px;
}
.van-search__content {
background-color: #ffffff;
}
}
.upStep {
.van-cell-group {
display: flex;
height: 1.2rem;
align-items: center;
.upStep-btn {
width: 25%;
text-align: center;
display: flex;
span {
width: 1.866667rem;
background-color: #1989fa;
text-align: center;
display: inline-block;
color: white;
height: 0.8rem;
line-height: 0.8rem;
font-size: 0.346667rem;
border-radius: 0.08rem;
}
}
.upStep-content {
width: 75%;
height: 0.8rem;
line-height: 0.8rem;
padding-left: 0.42667rem;
box-sizing: border-box;
font-size: 14px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
}
}
.dept-list-wrap {
margin-top: 0.266667rem;
}
.people-wrap {
margin-top: 0.266667rem;
/deep/ .van-radio__label {
display: flex;
align-items: center;
}
}
.footer {
width: 100%;
height: 1.4rem;
z-index: 9;
position: fixed;
bottom: 0px;
box-shadow: 0px 8px 15px #000;
.van-cell-group {
height: 100%;
.selected {
height: 1.066667rem;
display: flex;
align-items: center;
padding-left: 10px;
border-bottom: 1px solid #cacbcb;
.selected-title {
color: #4187f7;
}
.selected-content {
width: 80%;
padding-left: 10px;
box-sizing: border-box;
}
}
.operate {
height: 1.333333rem;
display: flex;
justify-content: flex-end;
align-items: center;
.van-button {
width: 1.6rem;
}
}
}
}
</style>
\ No newline at end of file
...@@ -33,205 +33,105 @@ ...@@ -33,205 +33,105 @@
</div> </div>
</van-grid-item> </van-grid-item>
</van-grid> </van-grid>
<van-steps <van-steps :active="phase" active-icon="success" active-color="#38f" style="margin: 0.26rem 0;">
:active="phase"
active-icon="success"
active-color="#38f"
style="margin: 0.26rem 0;"
>
<van-step name="1">任务发起</van-step> <van-step name="1">任务发起</van-step>
<van-step name="2">风险评估</van-step> <van-step name="2">风险评估</van-step>
<van-step name="3">评估审核</van-step> <van-step name="3">评估审核</van-step>
<van-step name="4">项目完成</van-step> <van-step name="4">项目完成</van-step>
</van-steps> </van-steps>
<van-tabs <van-tabs v-model="active" color="#2980f7" animated :sticky="true" offset-top="2.93rem">
v-model="active"
color="#2980f7"
animated
:sticky="true"
offset-top="2.93rem"
>
<van-tab title="任务详情"> <van-tab title="任务详情">
<van-form <van-form :scroll-to-error="true" :show-error="false" validate-trigger="onSubmit">
:scroll-to-error="true" <van-field readonly name="createUserName" :value="form.createUserName" label="创建人员" input-align="right"
:show-error="false" :rules="[{ required: true, message: '创建人员不能为空' }]" />
validate-trigger="onSubmit" <van-field readonly name="createDeptName" :value="form.createDeptName" label="创建单位" input-align="right"
> :rules="[{ required: true, message: '创建单位不能为空' }]" />
<van-field <van-field readonly name="projectName" :value="form.projectName" label="任务名称" input-align="right"
readonly :rules="[{ required: true, message: '任务名称不能为空' }]" />
name="createUserName"
:value="form.createUserName"
label="创建人员"
input-align="right"
:rules="[{ required: true, message: '创建人员不能为空' }]"
/>
<van-field
readonly
name="createDeptName"
:value="form.createDeptName"
label="创建单位"
input-align="right"
:rules="[{ required: true, message: '创建单位不能为空' }]"
/>
<van-field
readonly
name="projectName"
:value="form.projectName"
label="任务名称"
input-align="right"
:rules="[{ required: true, message: '任务名称不能为空' }]"
/>
<van-field <van-field readonly name="projectName" :value="form.projectName" label="关联项目" input-align="right"
readonly :rules="[{ required: true, message: '关联项目不能为空' }]" />
name="projectName"
:value="form.projectName"
label="关联项目"
input-align="right"
:rules="[{ required: true, message: '关联项目不能为空' }]"
/>
<van-field <van-field readonly name="buildingNames" :value="form.buildingNames" label="评估楼栋" input-align="right"
readonly :rules="[{ required: true, message: '评估楼栋不能为空' }]" />
name="buildingNames"
:value="form.buildingNames"
label="评估楼栋"
input-align="right"
:rules="[{ required: true, message: '评估楼栋不能为空' }]"
/>
<van-field <van-field readonly name="deptName" :value="form.deptName" label="评估小组选择" input-align="right"
readonly :rules="[{ required: true, message: '评估小组不能为空' }]" />
name="deptName"
:value="form.deptName"
label="评估小组选择"
input-align="right"
:rules="[{ required: true, message: '评估小组不能为空' }]"
/>
<van-field <van-field readonly name="leaderUserName" :value="form.leaderUserName" label="评估小组组长" input-align="right"
readonly :rules="[{ required: true, message: '评估小组组长不能为空' }]" />
name="leaderUserName"
:value="form.leaderUserName"
label="评估小组组长"
input-align="right"
:rules="[{ required: true, message: '评估小组组长不能为空' }]"
/>
<van-field <van-field clickable name="workUserNames" :value="form.workUserNames" label="评估成员" input-align="right"
clickable :rules="[{ required: true, message: '评估成员不能为空' }]" />
name="workUserNames"
:value="form.workUserNames"
label="评估成员"
input-align="right"
:rules="[{ required: true, message: '评估成员不能为空' }]"
/>
<van-field <van-field v-model="form.startTime" readonly name="location" label="任务开始时间" input-align="right" :formatter="() => {
v-model="form.startTime"
readonly
name="location"
label="任务开始时间"
input-align="right"
:formatter="
() => {
return timestampToTimes(form.startTime); return timestampToTimes(form.startTime);
} }
" " :rules="[{ required: true, message: '任务开始时间不能为空' }]" />
:rules="[{ required: true, message: '任务开始时间不能为空' }]"
/>
<van-field <van-field v-model="form.endTime" readonly name="location" label="任务结束时间" :formatter="() => {
v-model="form.endTime"
readonly
name="location"
label="任务结束时间"
:formatter="
() => {
return timestampToTimes(form.endTime); return timestampToTimes(form.endTime);
} }
" " input-align="right" :rules="[{ required: true, message: '任务结束时间不能为空' }]" />
input-align="right"
:rules="[{ required: true, message: '任务结束时间不能为空' }]"
/>
</van-form> </van-form>
</van-tab> </van-tab>
<van-tab title="风险清单"> <van-tab title="风险清单">
<!-- <van-row v-for="item in riskList" :key="item.id"> <van-sticky>
<van-col span="24"> <van-dropdown-menu>
{{ item.name }} <van-dropdown-item v-model="value1" :options="option1" />
<van-dropdown-item v-model="value2" :options="option2" />
<van-dropdown-item v-model="value3" :options="option3" />
</van-dropdown-menu>
</van-sticky>
<div style="overflow-y: auto;">
<van-cell-group inset v-for="(item, index) in riskList" :key="index">
<van-row type="flex" justify="space-between" style="margin-top:10px;">
<van-col span="22" @click="toRiskDetail(item)">
<van-col span="5">
<van-image width="46" height="46" src="https://img01.yzcdn.cn/vant/cat.jpeg" />
</van-col> </van-col>
</van-row> -->
<van-cell-group
inset
v-for="(item, index) in riskList"
:key="index"
>
<div style="font-size: 0.45rem;padding: 5px 0;">
{{ item.title }}
</div>
<van-row gutter="">
<van-col span="17"> <van-col span="17">
<van-row gutter=""> <van-row gutter="">
<van-col span="9">风险名称:</van-col> <van-col span="9">风险名称:</van-col>
<van-col span="15">{{ item.name }}</van-col> <van-col span="15">{{ item.name }}</van-col>
</van-row> </van-row>
</van-col> </van-col>
<van-col span="7">
<van-row
:style="{
color: '#03b615'
}"
>
{{ item.state }}
</van-row>
</van-col> </van-col>
<van-col span="7"> <van-col span="2">
<van-row <van-row :style="{
:style="{
color: '#03b615' color: '#03b615'
}" }">
> <van-icon name="arrow" size="26px" @click="goColorDetail" />
<van-button icon="plus" @click="goColorDetail"></van-button>
</van-row> </van-row>
</van-col> </van-col>
</van-row> </van-row>
</van-cell-group> </van-cell-group>
</div>
</van-tab> </van-tab>
<van-tab title="审核记录"> <van-tab title="审核记录">
<div class="journal-wrap"> <div class="journal-wrap">
<van-cell-group inset> <van-cell-group inset>
<van-steps <van-steps direction="vertical" :active="99999" v-if="riskLogList.length > 0">
direction="vertical"
:active="99999"
v-if="riskLogList.length > 0"
>
<van-step v-for="(item, index) in riskLogList" :key="index"> <van-step v-for="(item, index) in riskLogList" :key="index">
<div class="step-wrap"> <div class="step-wrap">
<van-row> <van-row>
<van-col span="24" <van-col span="24">
><div class="info-title"> <div class="info-title">
{{ timestampToTimes(item.startTime) }} {{ timestampToTimes(item.startTime) }}
</div></van-col </div>
> </van-col>
</van-row> </van-row>
<van-row> <van-row>
<van-col span="7" <van-col span="7"><span class="field-title">操作人:</span></van-col>
><span class="field-title">操作人:</span></van-col
>
<van-col span="17">{{ item.approvalUserName }}</van-col> <van-col span="17">{{ item.approvalUserName }}</van-col>
</van-row> </van-row>
<van-row> <van-row>
<van-col span="7" <van-col span="7"><span class="field-title">审批结果:</span></van-col>
><span class="field-title">审批结果:</span></van-col
>
<van-col span="17">{{ item.taskName }}</van-col> <van-col span="17">{{ item.taskName }}</van-col>
</van-row> </van-row>
<van-row> <van-row>
<van-col span="7" <van-col span="7"><span class="field-title">岗位:</span></van-col>
><span class="field-title">岗位:</span></van-col
>
<van-col span="17">{{ item.taskResult }}</van-col> <van-col span="17">{{ item.taskResult }}</van-col>
</van-row> </van-row>
<!-- <van-row> <!-- <van-row>
...@@ -250,15 +150,13 @@ ...@@ -250,15 +150,13 @@
</div> </div>
</van-tab> </van-tab>
<van-tab title="风险评估报告"> <van-tab title="风险评估报告">
<div <div style="height: 1.5rem;
style="height: 1.5rem;
background-color: #fff; background-color: #fff;
border-bottom: 1px solid #97999a; border-bottom: 1px solid #97999a;
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
line-height: 1.5rem; line-height: 1.5rem;
" ">
>
<div><van-icon name="column" size="26px" /></div> <div><van-icon name="column" size="26px" /></div>
<div style="flex-grow:1;line-height: 0.6rem"> <div style="flex-grow:1;line-height: 0.6rem">
<div>风险评估报告.PDF</div> <div>风险评估报告.PDF</div>
...@@ -268,15 +166,13 @@ ...@@ -268,15 +166,13 @@
<van-icon name="arrow" size="26px" /> <van-icon name="arrow" size="26px" />
</div> </div>
</div> </div>
<div <div style="height: 1.5rem;
style="height: 1.5rem;
background-color: #fff; background-color: #fff;
border-bottom: 1px solid #97999a; border-bottom: 1px solid #97999a;
display: flex; display: flex;
justify-content: space-between; justify-content: space-between;
line-height: 1.5rem; line-height: 1.5rem;
" ">
>
<div><van-icon name="column" size="26px" /></div> <div><van-icon name="column" size="26px" /></div>
<div style="flex-grow:1;line-height: 0.6rem"> <div style="flex-grow:1;line-height: 0.6rem">
<div>风险评估报告.PDF</div> <div>风险评估报告.PDF</div>
...@@ -289,8 +185,7 @@ ...@@ -289,8 +185,7 @@
</van-tab> </van-tab>
</van-tabs> </van-tabs>
</div> </div>
<div <div style="display: flex;
style="display: flex;
justify-content: space-around; justify-content: space-around;
background-color: #fff; background-color: #fff;
border-top: 1px solid #e3e3e3; border-top: 1px solid #e3e3e3;
...@@ -298,12 +193,8 @@ ...@@ -298,12 +193,8 @@
width: 100%; width: 100%;
text-align: center; text-align: center;
position: fixed; position: fixed;
bottom: 0;" bottom: 0;">
> <div @click="performTasks" style="color: #4bced0;font-size: 14px;font-weight: 600;">
<div
@click="performTasks"
style="color: #4bced0;font-size: 14px;font-weight: 600;"
>
<div style="font-size: 22px;"><van-icon name="plus" /></div> <div style="font-size: 22px;"><van-icon name="plus" /></div>
<div>执行任务</div> <div>执行任务</div>
</div> </div>
...@@ -337,7 +228,22 @@ export default { ...@@ -337,7 +228,22 @@ export default {
phase: 1, phase: 1,
form: {}, form: {},
tabs: [], tabs: [],
riskList:[], riskList: [],
value1: 0,
value2: 'a',
value3: '1',
option1: [
{ text: '楼栋', value: 0 },
{ text: '全部', value: 1 },
],
option2: [
{ text: '楼层', value: 'a' },
{ text: '全部', value: 'b' },
],
option3: [
{ text: '房间', value: '1' },
{ text: '全部', value: '2' },
],
}; };
}, },
created() { created() {
...@@ -352,9 +258,9 @@ export default { ...@@ -352,9 +258,9 @@ export default {
return timestampToTime(new Date(time), "DT2", true); return timestampToTime(new Date(time), "DT2", true);
}, },
performTasks() { performTasks() {
sessionStorage.setItem('buildingId',this.messageList.riskBuildingListDtos[0].buildingId) sessionStorage.setItem('buildingId', this.messageList.riskBuildingListDtos[0].buildingId)
sessionStorage.setItem('planId',this.messageList.id) sessionStorage.setItem('planId', this.messageList.id)
sessionStorage.setItem('buildingName',this.messageList.riskBuildingListDtos[0].buildingName) sessionStorage.setItem('buildingName', this.messageList.riskBuildingListDtos[0].buildingName)
this.$router.push({ this.$router.push({
name: "riskInherent", name: "riskInherent",
params: { params: {
...@@ -373,9 +279,9 @@ export default { ...@@ -373,9 +279,9 @@ export default {
}); });
}, },
//风险清单列表 //风险清单列表
getRiskTaskList(planId, buildingId){ getRiskTaskList(planId, buildingId) {
getFun(`/risk/plan/inherent/list/${planId}/${buildingId}`).then(res=>{ getFun(`/risk/plan/inherent/list/${planId}/${buildingId}`).then(res => {
console.log(res.data,'lll') console.log(res.data, 'lll')
this.riskList = res.data this.riskList = res.data
}) })
}, },
...@@ -434,17 +340,27 @@ export default { ...@@ -434,17 +340,27 @@ export default {
this.showIndex = null; this.showIndex = null;
}, },
//固定资产 //固定资产
goColorDetail(){ goColorDetail() {
// 楼层id: floorId // 楼层id: floorId
// 是否查看 : isView: true/false (true:查看,false:添加) // 是否查看 : isView: true/false (true:查看,false:添加)
this.$router.push({ this.$router.push({
name:"riskView", name: "riskView",
params:{ params: {
floorId:18, floorId: 18,
isView:true isView: true
} }
}) })
}, },
//风险清单列表点击
toRiskDetail(item) {
console.log(item,'LLLL')
this.$router.push({
name:"taskDetail",
params:{
id:item.id
}
})
}
} }
}; };
</script> </script>
...@@ -453,9 +369,11 @@ export default { ...@@ -453,9 +369,11 @@ export default {
font-family: ""; font-family: "";
color: #2c3e50; color: #2c3e50;
} }
.cell-wrap { .cell-wrap {
position: relative; position: relative;
} }
p { p {
font-size: 0.4rem; font-size: 0.4rem;
font-weight: none; font-weight: none;
...@@ -463,31 +381,38 @@ p { ...@@ -463,31 +381,38 @@ p {
margin: 0.186667rem 0; margin: 0.186667rem 0;
color: #7f7f7f; color: #7f7f7f;
} }
.van-cell-group--inset { .van-cell-group--inset {
margin: 0; margin: 0;
margin-bottom: 10px; margin-bottom: 10px;
padding: 10px; padding: 10px;
font-size: 13px; font-size: 13px;
position: relative; position: relative;
.van-row { .van-row {
margin-bottom: 0.133333rem; margin-bottom: 0.133333rem;
line-height: 0.64rem; line-height: 0.64rem;
} }
} }
.journal-wrap { .journal-wrap {
position: relative; position: relative;
} }
.supervise-wrap { .supervise-wrap {
position: relative; position: relative;
} }
.info-title { .info-title {
color: #2980f7; color: #2980f7;
font-weight: none; font-weight: none;
} }
.field-title { .field-title {
color: black; color: black;
font-weight: none; font-weight: none;
} }
.more { .more {
position: absolute; position: absolute;
bottom: 0.32rem; bottom: 0.32rem;
......
...@@ -3,33 +3,101 @@ ...@@ -3,33 +3,101 @@
<van-sticky offset-top="0"> <van-sticky offset-top="0">
<LHeader :text="text"></LHeader> <LHeader :text="text"></LHeader>
</van-sticky> </van-sticky>
<div class="section">
<van-tabs v-model="activeName" color="#2980f7" animated >
<van-tab title="固有风险信息" name="a">
</van-tab>
<van-tab title="现状风险" name="b">
<van-cell-group
inset
v-for="(item, index) in quoRiskList"
:key="index"
>
<div style="font-size: 0.45rem;padding: 5px 0;">
{{ item.name }}
</div>
<van-row gutter="">
<van-col span="17">
<van-row gutter="">
<van-col span="9">创建人:</van-col>
<van-col span="15">{{ item.leaderUserName }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="9">发起时间:</van-col>
<van-col span="15">{{
timestampToTimes(item.startTime)
}}</van-col>
</van-row>
</van-col>
<van-col span="7">
<van-row>
{{ item.state }}
</van-row>
<van-row>
<van-button
type="info"
size="mini"
@click="todetail(index, item)"
>{{ active == 2 ? "去处理" : "去审批" }}</van-button
>
</van-row>
</van-col>
</van-row>
</van-cell-group>
</van-tab>
<van-tab title="四色图" name="c">
<drawCanvas/>
</van-tab>
</van-tabs>
</div>
</div> </div>
</template> </template>
<script type="text/ecmascript-6"> <script type="text/ecmascript-6">
import LHeader from "@/components/header.vue"; import LHeader from "@/components/header.vue";
import drawCanvas from '@/views/drawCanvas/riskView.vue'
import { getFun, postFun } from "@/service/table.js";
export default { export default {
name:'taskDetail', name: 'taskDetail',
data() { data() {
return { return {
text: "固有风险列表", text: "固有风险列表",
activeName: 'a',
quoRiskList:[],//现状风险列表
InherentRisk:[],//固有风险
inherentId:''
} }
}, },
components: { components: {
LHeader, LHeader,
drawCanvas
},
created(){
this.inherentId = this.$route.params.id
}, },
mounted() { mounted() {
this.getQuoRiskList(this.$route.params.id)
}, },
methods: { methods: {
getQuoRiskList(inherentId){
getFun(`/risk/plan/existing/list/${inherentId}`).then(res=>{
this.quoRiskList = res.data
})
}
}, },
} }
</script> </script>
<style scoped> <style scoped>
.wrap{ .wrap {
height: 100vh; height: 100vh;
width: 100vw; width: 100vw;
} }
.section {
width: 100%;
height: 100%;
overflow-y: auto;
}
</style> </style>
...@@ -3,13 +3,13 @@ module.exports = { ...@@ -3,13 +3,13 @@ module.exports = {
devServer: { devServer: {
open: true, open: true,
host: 'localhost', host: 'localhost',
port: 8081, port: 8080,
https: false, https: false,
//以上的ip和端口是我们本机的;下面为需要跨域的 //以上的ip和端口是我们本机的;下面为需要跨域的
proxy: { //配置跨域 proxy: { //配置跨域
'/app-api': { '/app-api': {
// target: 'http://192.168.4.232:8080/', //这里是后台的地址 target: 'http://192.168.4.232:8080/', //这里是后台的地址
target: 'http://192.168.15.124:8080/', //这里是杨帆的地址 // target: 'http://192.168.15.124:8080/', //这里是杨帆的地址
// target: 'http://192.168.10.137:8080/', //这里是昊哥的地址 // target: 'http://192.168.10.137:8080/', //这里是昊哥的地址
// target: 'http://localhost:8080/', //这里是后台的地址 // target: 'http://localhost:8080/', //这里是后台的地址
ws: true, ws: true,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment