Commit 02661f43 authored by 罗新东's avatar 罗新东

修改列表样式,增加了搜索框,增加了全局底部导航栏

parent 0c2ca69e
......@@ -9,83 +9,129 @@
-->
<template>
<div id="app">
<transition :name="transitionName">
<keep-alive :include="cachePage">
<router-view class="router-view" />
</keep-alive>
</transition>
<div id="app" :style="{height:appHeight}">
<transition :name="transitionName">
<keep-alive :include="cachePage">
<router-view class="router-view" />
</keep-alive>
</transition>
<div :style="{height:tabH}"></div>
<tab-bar :index="1" v-if="showTab"></tab-bar>
</div>
</template>
<script>
export default {
data () {
return {
transitionName: 'slide-left',
cachePage:["add-danger","change-info","affirm-danger","risk-affirm","manager-survey","super-survey","major-survey","risk-add","noticeList"]
}
import tabBar from "@/components/TabBar";
export default {
components: {
tabBar,
},
data() {
return {
appHeight: "",
tabH: "",
rempx:0,
headH:'',
screenH: "",
transitionName: "slide-left",
cachePage: [
"add-danger",
"change-info",
"affirm-danger",
"risk-affirm",
"manager-survey",
"super-survey",
"major-survey",
"risk-add",
"noticeList",
],
};
},
mounted() {
let tabH =
document.getElementsByTagName("html")[0].style.fontSize.split("px")[0] *
1.33333;
let sH = window.screen.height;
this.headH=document.getElementsByTagName("html")[0].style.fontSize.split("px")[0] *
1.5;+'px'
this.appHeight = sH - tabH + "px";
this.tabH = tabH + "px";
this.screenH = sH + "px";
},
computed: {
showTab() {
return !["login", "login2"].includes(this.$route.name);
},
watch: {
$route(to, from) {
// 有主级到次级
if (to.meta.index > from.meta.index) {
this.transitionName = 'slide-left' // 向左滑动
} else if (to.meta.index < from.meta.index) {
// 由次级到主级
this.transitionName = 'slide-right'
} else {
this.transitionName = '' //同级无过渡效果
}
},
watch: {
$route(to, from) {
// 有主级到次级
if (to.meta.index > from.meta.index) {
this.transitionName = "slide-left"; // 向左滑动
} else if (to.meta.index < from.meta.index) {
// 由次级到主级
this.transitionName = "slide-right";
} else {
this.transitionName = ""; //同级无过渡效果
}
}
}
},
},
};
</script>
<style lang="less">
// body{
// overflow: hidden;
// }
#app {
font-family: 'Avenir', Helvetica, Arial, sans-serif;
font-family: "Avenir", Helvetica, Arial, sans-serif;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
// text-align: center;
color: #2c3e50;
box-sizing: border-box;
overflow: hidden;
position: relative;
overflow: hidden;
}
.router-view{
width: 100%;
height: auto;
position: absolute;
top: 0;
bottom: 0;
margin: 0 auto;
-webkit-overflow-scrolling: touch;
background-color: #f0f1f5;
.router-view {
width: 100%;
height: auto;
position: absolute;
top: 0;
bottom: 0;
margin: 0 auto;
-webkit-overflow-scrolling: touch;
background-color: #f0f1f5;
overflow: auto;
}
.slide-right-enter-active,
.slide-right-leave-active,
.slide-left-enter-active,
.slide-left-leave-active{
height: 100%;
will-change: transform;
transition: all 500ms;
position: absolute;
backface-visibility: hidden;
.slide-left-leave-active {
height: 100%;
will-change: transform;
transition: all 500ms;
position: absolute;
backface-visibility: hidden;
}
.slide-right-enter{
opacity: 0;
transform: translate3d(-100%, 0, 0);
.slide-right-enter {
opacity: 0;
transform: translate3d(-100%, 0, 0);
}
.slide-right-leave-active{
opacity: 0;
transform: translate3d(100%, 0, 0);
.slide-right-leave-active {
opacity: 0;
transform: translate3d(100%, 0, 0);
}
.slide-left-enter{
opacity: 0;
transform: translate3d(100%, 0, 0);
.slide-left-enter {
opacity: 0;
transform: translate3d(100%, 0, 0);
}
.slide-left-leave-active{
opacity: 0;
transform: translate3d(-100%, 0, 0);
.slide-left-leave-active {
opacity: 0;
transform: translate3d(-100%, 0, 0);
}
</style>
......@@ -49,3 +49,8 @@ body.dialog-open {
-moz-box-sizing: border-box;
box-sizing: border-box;
}
/deep/.con-list .van-cell-group--inset{
font-size: 0.4rem !important;
}
......@@ -24,7 +24,8 @@ Vue.use(vueEsign)
Vue.prototype.util = util
Vue.use(Divider).use(Popup).use(Overlay).use(Loading).use(Dialog).use(Toast).use(ContactCard).use(Form).use(AddressEdit).use(AddressList).use(Field).use(CellGroup).use(Cell).use(SwipeCell).use(Icon).use(Stepper).use(Card).use(Button).use(Swipe).use(SwipeItem).use(PullRefresh).use(List).use(Tab).use(Tabs).use(GoodsAction).use(GoodsActionIcon).use(GoodsActionButton).use(SubmitBar).use(Checkbox).use(CheckboxGroup).use(Search).use(Picker).use(Uploader).use(Notify)
.use(ContactList).use(Calendar).use(Radio).use(RadioGroup).use(Tag).use(Tabbar).use(TabbarItem).use(Sticky)
.use(Grid).use(GridItem).use(Skeleton).use(Col).use(Row).use(VanImage).use(Badge).use(NoticeBar).use(DatetimePicker).use(Step).use(Steps)
.use(Grid).use(GridItem).use(Skeleton).use(Col).use(Row).use(VanImage).use(Badge).use(NoticeBar).use(DatetimePicker)
.use(Step).use(Steps)
Vue.config.productionTip = false
new Vue({
router,
......
......@@ -266,27 +266,27 @@ export function delayEdit(url, data) {
}
// 隐患整改
export function list1(url="/rectification/list1", data) {
export function list1(data) {
return request({
url,
url:"/rectification/list1",
method: 'post',
data
})
}
// 隐患整改已退回
export function list2(url="/rectification/list2", data) {
export function list2(data) {
return request({
url,
url:"/rectification/list2",
method: 'post',
data
})
}
// 我的上报接口
export function myHDList(url="/hdreport/myHDList",data=null){
export function myHDList(data){
return request({
url,
url:'/hdreport/myHDList',
method:'post',
data
})
......
......@@ -272,6 +272,7 @@
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { timestampToTime } from "@/utils/format";
import {
getFormList,
......
......@@ -29,6 +29,7 @@
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { postHdRiskSource } from "@/service/danger";
export default {
components: {
......
......@@ -8,32 +8,32 @@
@click="goDetail(item.taskId)"
>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患级别:</van-col>
<van-col span="19">{{ item.hdLev }}</van-col>
<van-col span="6">隐患级别:</van-col>
<van-col span="18">{{ item.hdLev }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">适用范围:</van-col>
<van-col span="19">{{ item.hdRange }}</van-col>
<van-col span="6">适用范围:</van-col>
<van-col span="18">{{ item.hdRange }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患类型:</van-col>
<van-col span="19">{{ item.hdType }}</van-col>
<van-col span="6">隐患类型:</van-col>
<van-col span="18">{{ item.hdType }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.hdDiscoveryTime }}</van-col>
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.hdDiscoveryTime }}</van-col>
</van-row> -->
<van-row gutter="">
<van-col span="5">超期标识:</van-col>
<van-col span="19">{{ item.dueDate | formatTime }}</van-col>
<van-col span="6">超期标识:</van-col>
<van-col span="18">{{ item.dueDate | formatTime }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">状态:</van-col>
<van-col span="19">{{ item.taskName }}</van-col>
<van-col span="6">状态:</van-col>
<van-col span="18">{{ item.taskName }}</van-col>
</van-row>
<!-- 详情 -->
<div class="detail">详情</div>
......@@ -93,6 +93,7 @@
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { dangerRectReturn, dangerRectAdd } from "@/service/danger";
export default {
name: "change-info",
......
......@@ -52,6 +52,7 @@
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { timestampToTime } from "@/utils/format";
import { delayAdd } from "@/service/danger";
export default {
......
......@@ -3,14 +3,25 @@
<van-sticky>
<LHeader :text="text"></LHeader>
</van-sticky>
<!-- -->
<van-sticky offset-top="1.5rem">
<van-search
v-model="searchValue"
show-action
placeholder="请输入检查名称"
@search="onSearch"
>
<template #action>
<div @click="onSearch">搜索</div>
</template>
</van-search>
</van-sticky>
<!-- tab标签 -->
<van-tabs
@click="onClickTab"
@click="onClickTab($event, searchValue)"
animated
color="#2980F7"
:sticky="true"
offset-top="1.5rem"
offset-top="3rem"
>
<van-tab title="隐患整改">
<!-- 内容列表 -->
......@@ -22,32 +33,32 @@
@click="touchstart(index, item)"
>
<van-row gutter="">
<van-col span="5">隐患编号:</van-col>
<van-col span="19">{{ item.businessId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患级别:</van-col>
<van-col span="19">{{ item.hdLev }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.hdDiscoveryTime }}</van-col>
<van-col span="6">隐患编号:</van-col>
<van-col span="18">{{ item.businessId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="6">隐患级别:</van-col>
<van-col span="18">{{ item.hdLev }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.hdDiscoveryTime }}</van-col>
</van-row> -->
<van-row gutter="">
<van-col span="5">适用范围:</van-col>
<van-col span="19">{{ item.hdRange }}</van-col>
<van-col span="6">适用范围:</van-col>
<van-col span="18">{{ item.hdRange }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患类型:</van-col>
<van-col span="19">{{ item.hdType }}</van-col>
<van-col span="6">隐患类型:</van-col>
<van-col span="18">{{ item.hdType }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">超期标识:</van-col>
<van-col span="19">{{ item.dueDate | formatTime }}</van-col>
<van-col span="6">超期标识:</van-col>
<van-col span="18">{{ item.dueDate | formatTime }}</van-col>
</van-row>
<!-- 长按显示遮罩层 -->
......@@ -62,6 +73,9 @@
<van-button round type="info" @click="goDelay(item)"
>延期</van-button
>
<van-button round type="warning " @click="goClose(item)"
>关闭</van-button
>
</div>
</van-overlay>
</van-cell-group>
......@@ -75,7 +89,7 @@
position: fixed;
top: 30%;
"
v-if="isHaveNews"
v-if="onClickTab.length == 0"
>
暂无数据
</div>
......@@ -90,32 +104,32 @@
@click="touchstart(index, item)"
>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患级别:</van-col>
<van-col span="19">{{ item.hdLev }}</van-col>
<van-col span="6">隐患级别:</van-col>
<van-col span="18">{{ item.hdLev }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">适用范围:</van-col>
<van-col span="19">{{ item.hdRange }}</van-col>
<van-col span="6">适用范围:</van-col>
<van-col span="18">{{ item.hdRange }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患类型:</van-col>
<van-col span="19">{{ item.hdType }}</van-col>
<van-col span="6">隐患类型:</van-col>
<van-col span="18">{{ item.hdType }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.hdDiscoveryTime }}</van-col>
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.hdDiscoveryTime }}</van-col>
</van-row> -->
<van-row gutter="">
<van-col span="5">超期标识:</van-col>
<van-col span="19">{{ item.dueDate | formatTime }}</van-col>
<van-col span="6">超期标识:</van-col>
<van-col span="18">{{ item.dueDate | formatTime }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">状态:</van-col>
<van-col span="19">{{ item.taskName }}</van-col>
<van-col span="6">状态:</van-col>
<van-col span="18">{{ item.taskName }}</van-col>
</van-row>
<!-- 长按显示遮罩层 -->
......@@ -130,6 +144,9 @@
<van-button round type="info" @click="goDelay(item)"
>延期</van-button
>
<van-button round type="warning" @click="goClose(item)"
>关闭</van-button
>
</div>
</van-overlay>
</van-cell-group>
......@@ -143,25 +160,31 @@
position: fixed;
top: 30%;
"
v-if="isHaveNews"
v-if="messageList.length == 0"
>
暂无数据
</div>
</van-tab>
</van-tabs>
<tab-bar :index="1"></tab-bar>
</div>
</template>
<script>
import LHeader from "@/components/header.vue";
import { getFun, postFun } from "@/service/table.js";
import tabBar from "@/components/TabBar";
import { dangerRect, list1, list2 } from "@/service/danger";
import { Dialog } from "vant";
export default {
components: {
LHeader,
tabBar,
},
data() {
return {
text: "隐患整改",
appHeight: "",
searchValue: "",
isHaveNews: false,
messageList: [],
......@@ -172,9 +195,48 @@ export default {
created() {
this.onClickTab(0);
},
methods: {
onSearch(val) {},
onClickTab(val) {
// 关闭
goClose(val) {
// 点击了关闭
Dialog.confirm({
title: "提示",
message: "确定要关闭此条隐患吗?",
})
.then(() => {
this.$toast.loading({
message: "删除中...",
forbidClick: true,
loadingType: "spinner",
duration: 0,
});
postFun(`/rectification/delete/${val.taskId}`)
.then((res) => {
console.log(res,'怎么样')
this.$toast.clear();
this.$toast.success({
message: "关闭成功",
duration: 2000,
});
this.onClickTab(0, this.searchValue)
})
.catch(() => {
this.$toast.clear();
this.$toast.fail("关闭失败,请稍后再试");
});
this.showIndex = null;
})
.catch(() => {
this.$toast.clear();
this.showIndex = null;
});
// console.log(val)
},
onSearch(val) {
this.onClickTab(0, this.searchValue);
},
onClickTab(val, select = "") {
this.showIndex = null;
this.$toast.loading({
message: "加载中...",
......@@ -184,8 +246,10 @@ export default {
});
// 这里根据tab切换调用接口
let formdata = new FormData();
formdata.append("select", select);
[list1, list2]
[val]()
[val](formdata)
.then((res) => {
this.$toast.clear();
this.messageList = res.rows;
......@@ -281,18 +345,27 @@ export default {
</script>
<style lang="less" scoped>
/* @import url(); 引入css类 */
#app {
font-family: "";
color: #2c3e50;
}
.con-list {
padding: 10px 10px 0.533333rem;
padding: 0;
background-color: #f0f1f5;
.van-cell-group--inset {
margin: 0;
margin-bottom: 10px;
padding: 10px;
font-size: 13px;
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 {
margin-bottom: 0.133333rem;
line-height: 0.64rem;
font-size: 0.4rem;
line-height: 0.8rem;
margin-bottom: 0;
}
.van-overlay {
position: absolute;
......
......@@ -8,24 +8,24 @@
@click="goDetail(item.taskId)"
>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患级别:</van-col>
<van-col span="19">{{ item.hdLev }}</van-col>
<van-col span="6">隐患级别:</van-col>
<van-col span="18">{{ item.hdLev }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">适用范围:</van-col>
<van-col span="19">{{ item.hdRange }}</van-col>
<van-col span="6">适用范围:</van-col>
<van-col span="18">{{ item.hdRange }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患类型:</van-col>
<van-col span="19">{{ item.hdType }}</van-col>
<van-col span="6">隐患类型:</van-col>
<van-col span="18">{{ item.hdType }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.hdDiscoveryTime }}</van-col>
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.hdDiscoveryTime }}</van-col>
</van-row> -->
<!-- 详情 -->
<div class="detail">详情</div>
......@@ -151,6 +151,7 @@
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { timestampToTime } from "@/utils/format";
import { getConfirmFormList, dangerConSub } from "@/service/danger";
export default {
......
<template>
<div>
<LHeader :text="text"></LHeader>
<van-sticky offset-top="1.5rem">
<van-search
v-model="searchValue"
show-action
placeholder="请输入检查名称"
@search="onSearch"
>
<template #action>
<div @click="onSearch">搜索</div>
</template>
</van-search>
</van-sticky>
<!-- 内容列表 -->
<div class="con-list" @touchmove="showIndex = null">
<van-cell-group
......@@ -11,28 +22,28 @@
@click="touchstart(index, item)"
>
<van-row gutter="">
<van-col span="5">隐患编号:</van-col>
<van-col span="19">{{ item.businessId }}</van-col>
<van-col span="6">隐患编号:</van-col>
<van-col span="18">{{ item.businessId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患级别:</van-col>
<van-col span="19">{{ item.hdLev }}</van-col>
<van-col span="6">隐患级别:</van-col>
<van-col span="18">{{ item.hdLev }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.hdDiscoveryTime }}</van-col>
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.hdDiscoveryTime }}</van-col>
</van-row> -->
<van-row gutter="">
<van-col span="5">适用范围:</van-col>
<van-col span="19">{{ item.hdRange }}</van-col>
<van-col span="6">适用范围:</van-col>
<van-col span="18">{{ item.hdRange }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患类型:</van-col>
<van-col span="19">{{ item.hdType }}</van-col>
<van-col span="6">隐患类型:</van-col>
<van-col span="18">{{ item.hdType }}</van-col>
</van-row>
<!-- 长按显示遮罩层 -->
<van-overlay :show="showIndex == index">
......@@ -55,15 +66,19 @@
>
暂无数据
</div>
<tab-bar :index="1"></tab-bar>
</div>
</template>
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import tabBar from "@/components/TabBar";
import { dangerConfirm } from "@/service/danger";
export default {
components: {
LHeader
LHeader,
tabBar
},
data() {
return {
......@@ -80,15 +95,18 @@ export default {
},
methods: {
onSearch(val) {
this.postList(this.searchValue)
},
postList() {
postList(select='') {
this.$toast.loading({
message: "加载中...",
forbidClick: true,
loadingType: "spinner",
duration: 0
});
dangerConfirm("/confirm/list")
let formdata=new FormData();
formdata.append('select',select);
dangerConfirm("/confirm/list",formdata)
.then(res => {
this.$toast.clear();
this.messageList = res.rows;
......@@ -136,18 +154,27 @@ export default {
</script>
<style lang="less" scoped>
/* @import url(); 引入css类 */
#app {
font-family: "";
color: #2c3e50;
}
.con-list {
padding: 10px 10px 0.533333rem;
padding: 0;
background-color: #f0f1f5;
.van-cell-group--inset {
margin: 0;
margin-bottom: 10px;
padding: 10px;
font-size: 13px;
position: relative;
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 {
margin-bottom: 0.133333rem;
line-height: 0.64rem;
font-size: 0.4rem;
line-height: 0.8rem;
margin-bottom: 0;
}
.van-overlay {
position: absolute;
......
<template>
<div>
<LHeader :text="text"></LHeader>
<!-- 内容列表 -->
<!-- 接口对接4 START -->
<van-sticky offset-top="1.5rem">
<van-search
v-model="searchValue"
show-action
placeholder="请输入检查名称"
@search="onSearch"
>
<template #action>
<div @click="onSearch">搜索</div>
</template>
</van-search>
</van-sticky>
<!-- 内容列表 -->
<!-- 接口对接4 START -->
<div class="con-list" @touchmove="showIndex = null">
<van-cell-group
inset
......@@ -11,32 +22,31 @@
:key="index"
@click="touchstart(index, item)"
>
<van-row gutter="">
<van-col span="5">隐患编号:</van-col>
<van-col span="19">{{ item.businessId }}</van-col>
<van-col span="6">隐患编号:</van-col>
<van-col span="18">{{ item.businessId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患级别:</van-col>
<van-col span="19">{{ item.hdLev }}</van-col>
<van-col span="6">隐患级别:</van-col>
<van-col span="18">{{ item.hdLev }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.hdDiscoveryTime }}</van-col>
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.hdDiscoveryTime }}</van-col>
</van-row> -->
<!-- *接口对接4 END -->
<!-- *接口对接4 END -->
<!-- 长按显示遮罩层 -->
<van-overlay :show="showIndex == index">
<div class="wrapper" @click.stop ="showIndex = null">
<div class="wrapper" @click.stop="showIndex = null">
<van-button round type="primary" @click="goDetail(item)"
>详情</van-button
>
<van-button round type="info" @click="goConfirm(item)"
<van-button round type="info" @click="goConfirm(item)"
>审批</van-button
>
</div>
......@@ -45,57 +55,65 @@
</div>
<!-- 暂无数据 -->
<div
style="width: 100%;text-align: center; font-size: .48rem;position: fixed; top: 30%;"
style="
width: 100%;
text-align: center;
font-size: 0.48rem;
position: fixed;
top: 30%;
"
v-if="isHaveNews"
>
暂无数据
</div>
<tab-bar :index="1"></tab-bar>
</div>
</template>
<script>
import tabBar from "@/components/TabBar";
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { delayList } from "@/service/danger";
export default {
components: {
LHeader,
tabBar,
},
data() {
return {
text: "延期审批",
searchValue: "",
isHaveNews: false,
messageList: [],
messageList: [],
Loop: "", // 定时器
showIndex: null // 是否显示遮罩层
showIndex: null, // 是否显示遮罩层
};
},
created() {
created() {
this.getList();
},
methods: {
getList() {
getList(select) {
/*接口对接3 START*/
// 例子:
this.$toast.loading({
message: "加载中...",
forbidClick: true,
loadingType: "spinner",
duration: 0
duration: 0,
});
delayList("/delayApply/list")
.then(res => {
let formdata=new FormData();
formdata.append('select',select);
postFun('/delayApply/list',formdata)
.then((res) => {
this.$toast.clear();
this.messageList = res.rows
// 判断有无数据返回
this.messageList = res.rows;
// 判断有无数据返回
if (this.messageList.length == 0) {
this.isHaveNews = true;
}
})
.catch(() => {
this.$toast.clear();
......@@ -103,55 +121,63 @@ export default {
});
/*接口对接3 END*/
},
onSearch(val) {
onSearch() {
this.getList(this.searchValue)
},
touchstart(index, item) {
if (this.showIndex != null) {
this.showIndex = null;
return
return;
}
this.showIndex = index;
},
// 详情
goDetail(data) {
this.$router.push({
name: "risk-big-detail",
params: {
id: data.businessId
}
id: data.businessId,
},
});
this.showIndex = null;
},
// 审批
goConfirm(data) {
this.$router.push({
name:"ratify-info",
params:{
"taskId":data.taskId
}
name: "ratify-info",
params: {
taskId: data.taskId,
},
});
this.showIndex = null;
}
}
},
},
};
</script>
<style lang="less" scoped>
/* @import url(); 引入css类 */
#app {
font-family: "";
color: #2c3e50;
}
.con-list {
padding: 10px 10px .533333rem;
padding: 0;
background-color: #f0f1f5;
.van-cell-group--inset {
margin: 0;
margin-bottom: 10px;
padding: 10px;
font-size: 13px;
margin-bottom: 0.26667rem;
padding: 0.25rem;
font-size: 0.4rem;
position: relative;
.van-row{
margin-bottom: .133333rem;
line-height: .64rem;
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;
......
......@@ -65,6 +65,7 @@
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { delayReturn } from "@/service/danger";
import { delayEdit } from "@/service/danger";
export default {
......
<template>
<div>
<LHeader :text="text"></LHeader>
<!-- -->
<LHeader :text="text"></LHeader>
<!-- <van-sticky offset-top="1.5rem">
<van-search
v-model="value"
show-action
placeholder="请输入检查名称"
@search="onSearch"
>
<template #action>
<div @click="onSearch">搜索</div>
</template>
</van-search>
</van-sticky> -->
<!-- 内容列表 -->
<div class="con-list" @touchmove="showIndex = null">
<van-cell-group
......@@ -12,33 +23,33 @@
@click="touchstart(index, item)"
>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患级别:</van-col>
<van-col span="19">{{ item.hdLev }}</van-col>
<van-col span="6">隐患级别:</van-col>
<van-col span="18">{{ item.hdLev }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">适用范围:</van-col>
<van-col span="19">{{ item.hdRange }}</van-col>
<van-col span="6">适用范围:</van-col>
<van-col span="18">{{ item.hdRange }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患类型:</van-col>
<van-col span="19">{{ item.hdType }}</van-col>
<van-col span="6">隐患类型:</van-col>
<van-col span="18">{{ item.hdType }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.hdDiscoveryTime }}</van-col>
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.hdDiscoveryTime }}</van-col>
</van-row> -->
<!-- <van-row gutter="">
<van-col span="5">状态:</van-col>
<van-col span="19">{{ item.taskName }}</van-col>
<van-col span="6">状态:</van-col>
<van-col span="18">{{ item.taskName }}</van-col>
</van-row> -->
<!-- 长按显示遮罩层 -->
<van-overlay :show="showIndex == index">
<div class="wrapper" @click.stop ="showIndex = null">
<div class="wrapper" @click.stop="showIndex = null">
<van-button round type="primary" @click="goDetail(item)"
>详情</van-button
>
......@@ -48,47 +59,60 @@
</div>
<!-- 暂无数据 -->
<div
style="width: 100%;text-align: center; font-size: .48rem;position: fixed; top: 30%;"
style="
width: 100%;
text-align: center;
font-size: 0.48rem;
position: fixed;
top: 30%;
"
v-if="isHaveNews"
>
暂无数据
</div>
<tab-bar :index="1"></tab-bar>
</div>
</template>
<script>
import tabBar from "@/components/TabBar";
import LHeader from "@/components/header.vue";
import {dangerReturnDel,myHDList} from "@/service/danger";
import {getFun,postFun} from "@/service/table.js";
import { dangerReturnDel, myHDList } from "@/service/danger";
export default {
components: {
LHeader: LHeader
LHeader,
tabBar,
},
data() {
return {
value: "",
text: "我的上报",
searchValue: "",
isHaveNews: false,
messageList: [],
Loop: "", // 定时器
showIndex: null // 是否显示遮罩层
showIndex: null, // 是否显示遮罩层
};
},
created() {
this.postList();
},
methods: {
postList() {
postList(select = '') {
this.$toast.loading({
message: "加载中...",
forbidClick: true,
loadingType: "spinner",
duration: 0
duration: 0,
});
myHDList()
.then(res => {
let formdata=new FormData();
formdata.append('select',select);
postFun('/hdreport/myHDList',formdata)
.then((res) => {
this.$toast.clear();
this.messageList = res.data;
// 判断有无数据返回
// 判断有无数据返回
if (this.messageList.length == 0) {
this.isHaveNews = true;
}
......@@ -99,23 +123,25 @@ export default {
});
},
onSearch(val) {
onSearch() {
// console.log(this.value)
this.postList(this.value);
},
touchstart(index, item) {
if (this.showIndex != null) {
this.showIndex = null;
return
return;
}
this.showIndex = index;
this.showIndex = index;
},
goDetail(data){
goDetail(data) {
this.$router.push({
// name: "insert-danger-detail",
name:"normal-detail",
name: "normal-detail",
params: {
id: data.id,
detailTitle:'上报详情'
}
detailTitle: "上报详情",
},
});
this.showIndex = null;
},
......@@ -125,8 +151,8 @@ export default {
name: "add-danger",
params: {
status: "退回",
taskId: data.taskId
}
taskId: data.taskId,
},
});
this.showIndex = null;
},
......@@ -136,14 +162,14 @@ export default {
message: "删除中...",
forbidClick: true,
loadingType: "spinner",
duration: 0
duration: 0,
});
dangerReturnDel(`/hdreport/delete/${data.taskId}`)
.then(res => {
.then((res) => {
this.$toast.clear();
this.$toast.success({
message: "删除成功",
duration: 2000
duration: 2000,
});
this.postList();
})
......@@ -152,24 +178,33 @@ export default {
this.$toast.fail("删除失败,请稍后再试");
});
this.showIndex = null;
}
}
},
},
};
</script>
<style lang="less" scoped>
/* @import url(); 引入css类 */
#app {
font-family: "";
color: #2c3e50;
}
.con-list {
padding: 10px 10px 0.533333rem;
padding: 0;
background-color: #f0f1f5;
.van-cell-group--inset {
margin: 0;
margin-bottom: 10px;
padding: 10px;
font-size: 13px;
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 {
margin-bottom: 0.133333rem;
line-height: 0.64rem;
font-size: 0.4rem;
line-height: 0.8rem;
margin-bottom: 0;
}
.van-overlay {
position: absolute;
......
<template>
<div>
<LHeader :text="text"></LHeader>
<!-- 内容列表 -->
<!-- 接口对接4 START -->
<!-- <van-sticky offset-top="1.5rem">
<van-search
v-model="searchValue"
show-action
placeholder="请输入检查名称"
@search="onSearch"
>
<template #action>
<div @click="onSearch">搜索</div>
</template>
</van-search>
</van-sticky> -->
<!-- 内容列表 -->
<!-- 接口对接4 START -->
<div class="con-list" @touchmove="showIndex = null">
<van-cell-group
inset
......@@ -11,52 +22,58 @@
:key="index"
@click="touchstart(index, item)"
>
<van-row gutter="">
<van-col span="5">隐患编号:</van-col>
<van-col span="19">{{ item.businessId }}</van-col>
<van-col span="6">隐患编号:</van-col>
<van-col span="18">{{ item.businessId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患级别:</van-col>
<van-col span="19">{{ item.hdLev }}</van-col>
<van-col span="6">隐患级别:</van-col>
<van-col span="18">{{ item.hdLev }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.hdDiscoveryTime }}</van-col>
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.hdDiscoveryTime }}</van-col>
</van-row> -->
<!-- *接口对接4 END -->
<!-- *接口对接4 END -->
<!-- 长按显示遮罩层 -->
<van-overlay :show="showIndex == index">
<div class="wrapper" @click.stop ="showIndex = null">
<div class="wrapper" @click.stop="showIndex = null">
<van-button round type="primary" @click="goDetail(item)"
>详情</van-button
>
<van-button round type="info" @click="goConfirm(item)"
<van-button round type="info" @click="goConfirm(item)"
>审批</van-button
>
</div>
</van-overlay>
</van-cell-group>
</div>
<!-- 暂无数据 -->
<!-- 暂无数据 -->
<div
style="width: 100%;text-align: center; font-size: .48rem;position: fixed; top: 30%;"
style="
width: 100%;
text-align: center;
font-size: 0.48rem;
position: fixed;
top: 30%;
"
v-if="isHaveNews"
>
暂无数据
</div>
<tab-bar :index="1"></tab-bar>
</div>
</template>
<script>
import tabBar from "@/components/TabBar";
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { majorList } from "@/service/danger";
/*接口对接2 START*/
......@@ -77,39 +94,41 @@ import { majorList } from "@/service/danger";
export default {
components: {
LHeader,
tabBar
},
data() {
return {
text: "重大隐患",
searchValue: "",
isHaveNews: false,
messageList: [],
messageList: [],
Loop: "", // 定时器
showIndex: null // 是否显示遮罩层
showIndex: null, // 是否显示遮罩层
};
},
created() {
created() {
this.getList();
},
methods: {
getList() {
getList(select='') {
/*接口对接3 START*/
// 例子:
this.$toast.loading({
message: "加载中...",
forbidClick: true,
loadingType: "spinner",
duration: 0
duration: 0,
});
majorList("/majorapprove/list")
.then(res => {
let formdata=new FormData();
formdata.append('select',select);
majorList("/majorapprove/list",formdata)
.then((res) => {
this.$toast.clear();
this.messageList = res.rows
// 判断有无数据返回
this.messageList = res.rows;
// 判断有无数据返回
if (this.messageList.length == 0) {
this.isHaveNews = true;
}
})
.catch(() => {
this.$toast.clear();
......@@ -118,23 +137,24 @@ export default {
/*接口对接3 END*/
},
onSearch(val) {
this.getList(this.searchValue)
},
touchstart(index, item) {
if (this.showIndex != null) {
this.showIndex = null;
return
return;
}
this.showIndex = index;
},
// 详情
goDetail(data) {
this.$router.push({
name: "normal-detail",
params:{
id: data.taskId
}
this.$router.push({
name: "normal-detail",
params: {
id: data.taskId,
},
});
this.showIndex = null;
},
......@@ -144,27 +164,36 @@ export default {
name: "major-survey",
params: {
data: data,
}
},
});
this.showIndex = null;
}
}
},
},
};
</script>
<style lang="less" scoped>
/* @import url(); 引入css类 */
#app {
font-family: "";
color: #2c3e50;
}
.con-list {
padding: 10px 10px .533333rem;
padding: 0;
background-color: #f0f1f5;
.van-cell-group--inset {
margin: 0;
margin-bottom: 10px;
padding: 10px;
font-size: 13px;
margin-bottom: 0.26667rem;
padding: 0.25rem;
font-size: 0.4rem;
position: relative;
.van-row{
margin-bottom: .133333rem;
line-height: .64rem;
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;
......
......@@ -9,20 +9,20 @@
>
<van-row gutter="">
<van-col span="7">隐患编号:</van-col>
<van-col span="7">隐患编号</van-col>
<van-col span="17">{{ item.businessId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7">隐患项目名称:</van-col>
<van-col span="7">隐患项目名称</van-col>
<van-col span="17">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7">隐患级别:</van-col>
<van-col span="7">隐患级别</van-col>
<van-col span="17">{{ item.hdLev }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="7">发现时间:</van-col>
<van-col span="7">发现时间</van-col>
<van-col span="17">{{ item.startDate }}</van-col>
</van-row> -->
<!-- 详情 -->
......@@ -110,6 +110,7 @@
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { majorAdd } from "@/service/danger";
export default {
name:"major-survey",
......@@ -124,10 +125,10 @@ export default {
text: "重大隐患审批",
agreeOpinion: "",
disagreeOpinion: "",
thinkLevel:'重大隐患', //因为隐患级别
thinkHdLev:'重大隐患',
thinkLevel:'建议为严重隐患', //因为隐患级别
thinkHdLev:'建议为严重隐患',
showThinkLevel: false,
columnsThinkLevel:["重大隐患","一般隐患A","一般隐患B","一般隐患C",]
columnsThinkLevel:["建议为严重隐患","建议为较大隐患","建议为危险隐患",]
};
},
......@@ -161,7 +162,7 @@ export default {
let formdata = new FormData()
formdata.append('isResult', values.isResult)
formdata.append('details', values.details)
formdata.append('thinkHdLev',values.isResult==1?'重大隐患':values.thinkHdLev)
formdata.append('thinkHdLev',values.isResult==1?'建议为严重隐患':values.thinkHdLev)
formdata.append('taskId', this.taskId)
majorAdd(`/majorapprove/add`,formdata)
.then(res => {
......
<template>
<div>
<LHeader :text="text"></LHeader>
<!-- 内容列表 -->
<!-- 接口对接4 START -->
<div class="con-list" @touchmove="showIndex = null">
<van-sticky offset-top="1.5rem">
<van-search
v-model="searchValue"
show-action
placeholder="请输入检查名称"
@search="onSearch"
>
<template #action>
<div @click="onSearch">搜索</div>
</template>
</van-search>
</van-sticky>
<!-- 内容列表 -->
<!-- 接口对接4 START -->
<div class="con-list" @touchmove="showIndex = null">
<van-cell-group
inset
v-for="(item, index) in messageList"
:key="index"
@click="touchstart(index, item)"
>
<van-row gutter="">
<van-col span="5">隐患编号:</van-col>
<van-col span="19">{{ item.pid }}</van-col>
<van-col span="6">隐患编号:</van-col>
<van-col span="18">{{ item.pid }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.projectName }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.projectName }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患级别:</van-col>
<van-col span="19">{{ item.hdLev }}</van-col>
<van-col span="6">隐患级别:</van-col>
<van-col span="18">{{ item.hdLev }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.hdDiscoveryTime }}</van-col>
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.hdDiscoveryTime }}</van-col>
</van-row> -->
<!-- *接口对接4 END -->
<!-- *接口对接4 END -->
<!-- 长按显示遮罩层 -->
<van-overlay :show="showIndex == index">
<div class="wrapper" @click.stop ="showIndex = null">
<div class="wrapper" @click.stop="showIndex = null">
<van-button round type="primary" @click="goDetail(item)"
>详情</van-button
>
......@@ -43,19 +53,27 @@
</van-overlay>
</van-cell-group>
</div>
<!-- 暂无数据 -->
<!-- 暂无数据 -->
<div
style="width: 100%;text-align: center; font-size: .48rem;position: fixed; top: 30%;"
style="
width: 100%;
text-align: center;
font-size: 0.48rem;
position: fixed;
top: 30%;
"
v-if="isHaveNews"
>
暂无数据
</div>
<tab-bar :index="1"></tab-bar>
</div>
</template>
<script>
import tabBar from "@/components/TabBar";
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { superviseList } from "@/service/danger";
/*接口对接2 START*/
......@@ -76,39 +94,41 @@ import { superviseList } from "@/service/danger";
export default {
components: {
LHeader,
tabBar,
},
data() {
return {
text: "项目经理督办",
searchValue: "",
isHaveNews: false,
messageList: [],
messageList: [],
Loop: "", // 定时器
showIndex: null // 是否显示遮罩层
showIndex: null, // 是否显示遮罩层
};
},
created() {
created() {
this.getList();
},
methods: {
getList() {
getList(select='') {
/*接口对接3 START*/
// 例子:
this.$toast.loading({
message: "加载中...",
forbidClick: true,
loadingType: "spinner",
duration: 0
duration: 0,
});
superviseList("/supervise/list")
.then(res => {
let formdata=new FormData();
formdata.append('select',select);
superviseList("/supervise/list",formdata)
.then((res) => {
this.$toast.clear();
this.messageList = res.data
// 判断有无数据返回
this.messageList = res.data;
// 判断有无数据返回
if (this.messageList.length == 0) {
this.isHaveNews = true;
}
})
.catch(() => {
this.$toast.clear();
......@@ -117,24 +137,24 @@ export default {
/*接口对接3 END*/
},
onSearch(val) {
this.getList(this.searchValue)
},
touchstart(index, item) {
if (this.showIndex != null) {
this.showIndex = null;
return
return;
}
this.showIndex = index;
},
// 详情
goDetail(data) {
this.$router.push({
name: "normal-detail",
params:{
id: data.pid
}
this.$router.push({
name: "normal-detail",
params: {
id: data.pid,
},
});
this.showIndex = null;
},
......@@ -144,27 +164,36 @@ export default {
name: "manager-survey",
params: {
data: data,
}
},
});
this.showIndex = null;
}
}
},
},
};
</script>
<style lang="less" scoped>
/* @import url(); 引入css类 */
#app {
font-family: "";
color: #2c3e50;
}
.con-list {
padding: 10px 10px .533333rem;
padding: 0;
background-color: #f0f1f5;
.van-cell-group--inset {
margin: 0;
margin-bottom: 10px;
padding: 10px;
font-size: 13px;
margin-bottom: 0.26667rem;
padding: 0.25rem;
font-size: 0.4rem;
position: relative;
.van-row{
margin-bottom: .133333rem;
line-height: .64rem;
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;
......
......@@ -8,19 +8,19 @@
@click="goDetail(item.pid)"
>
<van-row gutter="">
<van-col span="7">隐患编号:</van-col>
<van-col span="7">隐患编号</van-col>
<van-col span="17">{{ item.hdProjectId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7">隐患项目名称:</van-col>
<van-col span="7">隐患项目名称</van-col>
<van-col span="17">{{ item.projectName }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7">隐患级别:</van-col>
<van-col span="7">隐患级别</van-col>
<van-col span="17">{{ item.hdLev }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="7">隐患发现时间:</van-col>
<van-col span="7">隐患发现时间</van-col>
<van-col span="17">{{ item.createTime }}</van-col>
</van-row> -->
<!-- 详情 -->
......@@ -57,6 +57,7 @@
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { superviseAdd } from "@/service/danger";
export default {
name: "manager-survey",
......
<template>
<div>
<LHeader :text="text"></LHeader>
<van-sticky offset-top="1.5rem">
<van-search
v-model="searchValue"
show-action
placeholder="请输入检查名称"
@search="onSearch"
>
<template #action>
<div @click="onSearch">搜索</div>
</template>
</van-search>
</van-sticky>
<!-- 内容列表 -->
<div class="con-list" @touchmove="showIndex = null">
<van-cell-group
......@@ -10,39 +21,39 @@
:key="index"
@click="touchstart(index, item)"
>
<van-row gutter="">
<van-col span="5">隐患编号:</van-col>
<van-col span="19">{{ item.businessId }}</van-col>
<van-row gutter="">
<van-col span="6">隐患编号:</van-col>
<van-col span="18">{{ item.businessId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患级别:</van-col>
<van-col span="19">{{ item.hdLev }}</van-col>
<van-col span="6">隐患级别:</van-col>
<van-col span="18">{{ item.hdLev }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.hdDiscoveryTime }}</van-col>
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.hdDiscoveryTime }}</van-col>
</van-row> -->
<van-row gutter="">
<van-col span="5">适用范围:</van-col>
<van-col span="19">{{ item.hdRange }}</van-col>
<van-col span="6">适用范围:</van-col>
<van-col span="18">{{ item.hdRange }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患类型:</van-col>
<van-col span="19">{{ item.hdType }}</van-col>
<van-col span="6">隐患类型:</van-col>
<van-col span="18">{{ item.hdType }}</van-col>
</van-row>
<!-- 长按显示遮罩层 -->
<van-overlay :show="showIndex == index">
<div class="wrapper" @click.stop ="showIndex = null">
<div class="wrapper" @click.stop="showIndex = null">
<van-button round type="primary" @click="goSubmit(item)"
>上报</van-button
>
<van-button round type="warning" @click="goDelete(item)"
>删除</van-button
>关闭</van-button
>
</div>
</van-overlay>
......@@ -50,20 +61,30 @@
</div>
<!-- 暂无数据 -->
<div
style="width: 100%;text-align: center; font-size: .48rem;position: fixed; top: 30%;"
style="
width: 100%;
text-align: center;
font-size: 0.48rem;
position: fixed;
top: 30%;
"
v-if="isHaveNews"
>
暂无数据
</div>
<tab-bar :index="1"></tab-bar>
</div>
</template>
<script>
import tabBar from "@/components/TabBar";
import LHeader from "@/components/header.vue";
import { getFun, postFun } from "@/service/table.js";
import { dangerReturn, dangerReturnDel } from "@/service/danger";
export default {
components: {
LHeader: LHeader
LHeader,
tabBar,
},
data() {
return {
......@@ -72,25 +93,27 @@ export default {
isHaveNews: false,
messageList: [],
Loop: "", // 定时器
showIndex: null // 是否显示遮罩层
showIndex: null, // 是否显示遮罩层
};
},
created() {
this.postList();
},
methods: {
postList() {
postList(select = "") {
this.$toast.loading({
message: "加载中...",
forbidClick: true,
loadingType: "spinner",
duration: 0
duration: 0,
});
dangerReturn("/hdreport/list")
.then(res => {
let formdata = new FormData();
formdata.append("select", select);
dangerReturn("/hdreport/list", formdata)
.then((res) => {
this.$toast.clear();
this.messageList = res.rows;
// 判断有无数据返回
// 判断有无数据返回
if (this.messageList.length == 0) {
this.isHaveNews = true;
}
......@@ -102,13 +125,14 @@ export default {
},
onSearch(val) {
this.postList(this.searchValue);
},
touchstart(index, item) {
if (this.showIndex != null) {
this.showIndex = null;
return
return;
}
this.showIndex = index;
this.showIndex = index;
},
// 上报
......@@ -117,53 +141,75 @@ export default {
name: "add-danger",
params: {
status: "退回",
taskId: data.taskId
}
taskId: data.taskId,
},
});
// 存到缓存里 如果路由跳转或者是缓存中有 就是隐患上报退回
localStorage.setItem('dangerAddTaskId',data.taskId)
// 存到缓存里 如果路由跳转或者是缓存中有 就是隐患上报退回
localStorage.setItem("dangerAddTaskId", data.taskId);
this.showIndex = null;
},
// 删除
goDelete(data) {
this.$toast.loading({
message: "删除中...",
forbidClick: true,
loadingType: "spinner",
duration: 0
});
dangerReturnDel(`/hdreport/delete/${data.taskId}`)
.then(res => {
this.$toast.clear();
this.$toast.success({
message: "删除成功",
duration: 2000
this.$dialog
.confirm({
title: "提示",
message: "确认要关闭此条隐患吗?",
})
.then((r) => {
console.log(r, "确定");
this.$toast.loading({
message: "关闭中...",
forbidClick: true,
loadingType: "spinner",
duration: 0,
});
this.postList();
dangerReturnDel(`/hdreport/delete/${data.taskId}`)
.then((res) => {
this.$toast.clear();
this.$toast.success({
message: "关闭成功",
duration: 2000,
});
this.postList();
})
.catch(() => {
this.$toast.clear();
this.$toast.fail("关闭失败,请稍后再试");
});
this.showIndex = null;
})
.catch(() => {
console.log("错了");
this.$toast.clear();
this.$toast.fail("删除失败,请稍后再试");
this.showIndex = null;
});
this.showIndex = null;
}
}
},
},
};
</script>
<style lang="less" scoped>
/* @import url(); 引入css类 */
#app {
font-family: "";
color: #2c3e50;
}
.con-list {
padding: 10px 10px 0.533333rem;
padding: 0;
background-color: #f0f1f5;
.van-cell-group--inset {
margin: 0;
margin-bottom: 10px;
padding: 10px;
font-size: 13px;
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 {
margin-bottom: 0.133333rem;
line-height: 0.64rem;
font-size: 0.4rem;
line-height: 0.8rem;
margin-bottom: 0;
}
.van-overlay {
position: absolute;
......
<template>
<div>
<LHeader :text="text"></LHeader>
<van-sticky offset-top="1.5rem">
<van-search
v-model="searchValue"
show-action
placeholder="请输入检查名称"
@search="onSearch"
>
<template #action>
<div @click="onSearch">搜索</div>
</template>
</van-search>
</van-sticky>
<!-- 内容列表 -->
<div class="con-list" @touchmove="showIndex = null">
<van-cell-group
......@@ -11,32 +22,32 @@
@click="touchstart(index, item)"
>
<van-row gutter="">
<van-col span="5">隐患编号:</van-col>
<van-col span="19">{{ item.businessId }}</van-col>
<van-col span="6">隐患编号:</van-col>
<van-col span="18">{{ item.businessId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患级别:</van-col>
<van-col span="19">{{ item.hdLev }}</van-col>
<van-col span="6">隐患级别:</van-col>
<van-col span="18">{{ item.hdLev }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.hdDiscoveryTime }}</van-col>
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.hdDiscoveryTime }}</van-col>
</van-row> -->
<van-row gutter="">
<van-col span="5">适用范围:</van-col>
<van-col span="19">{{ item.hdRange }}</van-col>
<van-col span="6">适用范围:</van-col>
<van-col span="18">{{ item.hdRange }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患类型:</van-col>
<van-col span="19">{{ item.hdType }}</van-col>
<van-col span="6">隐患类型:</van-col>
<van-col span="18">{{ item.hdType }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">超期标识:</van-col>
<van-col span="19">{{ item | formatTime }}</van-col>
<van-col span="6">超期标识:</van-col>
<van-col span="18">{{ item | formatTime }}</van-col>
</van-row>
<!-- 长按显示遮罩层 -->
......@@ -59,15 +70,19 @@
>
暂无数据
</div>
<tab-bar :index="1"></tab-bar>
</div>
</template>
<script>
import tabBar from "@/components/TabBar";
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { dangerReview } from "@/service/danger";
export default {
components: {
LHeader
LHeader,
tabBar
},
data() {
return {
......@@ -84,16 +99,19 @@ export default {
},
methods: {
onSearch(val) {
this.postList(this.searchValue)
},
postList() {
postList(select='') {
this.$toast.loading({
message: "加载中...",
forbidClick: true,
loadingType: "spinner",
duration: 0
});
dangerReview("/review/list")
let formdata=new FormData();
formdata.append('select',select);
dangerReview("/review/list",formdata)
.then(res => {
this.$toast.clear();
this.messageList = res.rows;
......@@ -158,18 +176,27 @@ export default {
</script>
<style lang="less" scoped>
/* @import url(); 引入css类 */
#app {
font-family: "";
color: #2c3e50;
}
.con-list {
padding: 10px 10px 0.533333rem;
padding: 0;
background-color: #f0f1f5;
.van-cell-group--inset {
margin: 0;
margin-bottom: 10px;
padding: 10px;
font-size: 13px;
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 {
margin-bottom: 0.133333rem;
line-height: 0.64rem;
font-size: 0.4rem;
line-height: 0.8rem;
margin-bottom: 0;
}
.van-overlay {
position: absolute;
......
......@@ -8,32 +8,32 @@
@click="goDetail(item.taskId)"
>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患级别:</van-col>
<van-col span="19">{{ item.hdLev }}</van-col>
<van-col span="6">隐患级别:</van-col>
<van-col span="18">{{ item.hdLev }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">适用范围:</van-col>
<van-col span="19">{{ item.hdRange }}</van-col>
<van-col span="6">适用范围:</van-col>
<van-col span="18">{{ item.hdRange }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患类型:</van-col>
<van-col span="19">{{ item.hdType }}</van-col>
<van-col span="6">隐患类型:</van-col>
<van-col span="18">{{ item.hdType }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.hdDiscoveryTime }}</van-col>
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.hdDiscoveryTime }}</van-col>
</van-row> -->
<van-row gutter="">
<van-col span="5">超期标识:</van-col>
<van-col span="19">{{ item | formatTime }}</van-col>
<van-col span="6">超期标识:</van-col>
<van-col span="18">{{ item | formatTime }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">状态:</van-col>
<van-col span="19">{{ item.taskName }}</van-col>
<van-col span="6">状态:</van-col>
<van-col span="18">{{ item.taskName }}</van-col>
</van-row>
<!-- 详情 -->
<div class="detail">详情</div>
......@@ -108,6 +108,7 @@
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { dangerReviewAdd } from "@/service/danger";
export default {
components: {
......
<template>
<div>
<LHeader :text="text"></LHeader>
<van-sticky offset-top="1.5rem">
<van-search
v-model="searchValue"
show-action
placeholder="请输入检查名称"
@search="onSearch"
>
<template #action>
<div @click="onSearch">搜索</div>
</template>
</van-search>
</van-sticky>
<!-- 内容列表 -->
<div class="con-list" @touchmove="showIndex = null">
<van-cell-group
......@@ -11,32 +22,32 @@
@click="touchstart(index, item)"
>
<van-row gutter="">
<van-col span="5">隐患编号:</van-col>
<van-col span="19">{{ item.businessId }}</van-col>
<van-col span="6">隐患编号:</van-col>
<van-col span="18">{{ item.businessId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患级别:</van-col>
<van-col span="19">{{ item.hdLev }}</van-col>
<van-col span="6">隐患级别:</van-col>
<van-col span="18">{{ item.hdLev }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.hdDiscoveryTime }}</van-col>
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.hdDiscoveryTime }}</van-col>
</van-row> -->
<van-row gutter="">
<van-col span="5">适用范围:</van-col>
<van-col span="19">{{ item.hdRange }}</van-col>
<van-col span="6">适用范围:</van-col>
<van-col span="18">{{ item.hdRange }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患类型:</van-col>
<van-col span="19">{{ item.hdType }}</van-col>
<van-col span="6">隐患类型:</van-col>
<van-col span="18">{{ item.hdType }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">超期标识:</van-col>
<van-col span="19">{{ item | formatTime }}</van-col>
<van-col span="6">超期标识:</van-col>
<van-col span="18">{{ item | formatTime }}</van-col>
</van-row>
......@@ -57,15 +68,19 @@
>
暂无数据
</div>
<tab-bar :index="1"></tab-bar>
</div>
</template>
<script>
import tabBar from "@/components/TabBar";
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { dangerStandBook } from "@/service/danger";
export default {
components: {
LHeader,
tabBar
},
data() {
return {
......@@ -82,16 +97,19 @@ export default {
},
methods: {
onSearch(val) {
this.postList(this.searchValue)
},
postList() {
postList(select='') {
this.$toast.loading({
message: "加载中...",
forbidClick: true,
loadingType: "spinner",
duration: 0
});
dangerStandBook("/hdreport/doneList")
let formdata=new FormData();
formdata.append('select',select);
dangerStandBook("/hdreport/doneList",formdata)
.then(res => {
this.$toast.clear();
this.messageList = res.rows;
......@@ -141,18 +159,27 @@ export default {
</script>
<style lang="less" scoped>
/* @import url(); 引入css类 */
#app {
font-family: "";
color: #2c3e50;
}
.con-list {
padding: 10px 10px .533333rem;
padding: 0;
background-color: #f0f1f5;
.van-cell-group--inset {
margin: 0;
margin-bottom: 10px;
padding: 10px;
font-size: 13px;
position: relative;
.van-row{
margin-bottom: .133333rem;
line-height: .64rem;
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;
......
This diff is collapsed.
<template>
<div>
<LHeader :text="text"></LHeader>
<van-sticky offset-top="1.5rem">
<van-search
v-model="searchValue"
show-action
placeholder="请输入检查名称"
@search="onSearch"
>
<template #action>
<div @click="onSearch">搜索</div>
</template>
</van-search>
</van-sticky>
<!-- 内容列表 -->
<!-- 接口对接4 START -->
<div class="con-list" @touchmove="showIndex = null">
......@@ -12,20 +23,20 @@
@click="touchstart(index, item)"
>
<van-row gutter="">
<van-col span="5">隐患编号:</van-col>
<van-col span="19">{{ item.businessId }}</van-col>
<van-col span="6">隐患编号:</van-col>
<van-col span="18">{{ item.businessId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">隐患级别:</van-col>
<van-col span="19">{{ item.hdLev }}</van-col>
<van-col span="6">隐患级别:</van-col>
<van-col span="18">{{ item.hdLev }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.hdDiscoveryTime }}</van-col>
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.hdDiscoveryTime }}</van-col>
</van-row> -->
<!-- *接口对接4 END -->
......@@ -49,11 +60,14 @@
>
暂无数据
</div>
<tab-bar :index="1"></tab-bar>
</div>
</template>
<script>
import tabBar from "@/components/TabBar";
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { superviseSABlist } from "@/service/danger";
/*接口对接2 START*/
......@@ -73,7 +87,8 @@ import { superviseSABlist } from "@/service/danger";
export default {
components: {
LHeader
LHeader,
tabBar
},
data() {
return {
......@@ -89,14 +104,16 @@ export default {
this.getList();
},
methods: {
getList() {
getList(select='') {
this.$toast.loading({
message: "加载中...",
forbidClick: true,
loadingType: "spinner",
duration: 0
});
superviseSABlist("/supervise/SABlist")
let formdata=new FormData();
formdata.append('select',select);
superviseSABlist("/supervise/SABlist",formdata)
.then(res => {
this.$toast.clear();
this.messageList = res.data
......@@ -113,6 +130,7 @@ export default {
},
onSearch(val) {
this.getList(this.searchValue)
},
touchstart(index, item) {
......@@ -148,18 +166,27 @@ export default {
</script>
<style lang="less" scoped>
/* @import url(); 引入css类 */
#app {
font-family: "";
color: #2c3e50;
}
.con-list {
padding: 10px 10px .533333rem;
padding: 0;
background-color: #f0f1f5;
.van-cell-group--inset {
margin: 0;
margin-bottom: 10px;
padding: 10px;
font-size: 13px;
position: relative;
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 {
margin-bottom: 0.133333rem;
line-height: 0.64rem;
font-size: 0.4rem;
line-height: 0.8rem;
margin-bottom: 0;
}
.van-overlay {
position: absolute;
......
......@@ -8,19 +8,19 @@
@click="goDetail(item.pid)"
>
<van-row gutter="">
<van-col span="7">隐患编号:</van-col>
<van-col span="7">隐患编号</van-col>
<van-col span="17">{{ item.processInstanceId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7">隐患项目名称:</van-col>
<van-col span="7">隐患项目名称</van-col>
<van-col span="17">{{ item.projectName }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7">隐患级别:</van-col>
<van-col span="7">隐患级别</van-col>
<van-col span="17">{{ item.hdLev }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="7">隐患发现时间:</van-col>
<van-col span="7">隐患发现时间</van-col>
<van-col span="17">{{ item.createTime }}</van-col>
</van-row> -->
<!-- *接口对接4 END -->
......@@ -58,6 +58,7 @@
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { superviseAdd } from "@/service/danger";
export default {
name:"super-survey",
......
......@@ -2,9 +2,7 @@
<div>
<!-- 头部标签 -->
<van-sticky>
<header class="header-wrap">
消息中心
</header>
<header class="header-wrap">消息中心</header>
</van-sticky>
<!-- 内容 -->
......@@ -17,9 +15,14 @@
sticky
offset-top="1.333333rem"
>
<van-tab title="消息信息" name="消息信息" :badge="messageNewsNum>0?messageNewsNum : ''">
<van-tab
title="消息信息"
name="消息信息"
:badge="messageNewsNum > 0 ? messageNewsNum : ''"
>
<message-news @messageLength="getMessageLength"></message-news>
</van-tab>
<van-tab title="" name="" disabled badge="">
<wait-event></wait-event>
</van-tab>
......@@ -44,20 +47,24 @@ export default {
messageNews,
waitEvent,
noticeInfo,
tabBar
tabBar,
},
data() {
return {
activeName: "消息信息",
messageNewsNum: ''
messageNewsNum: "",
searchValue:''
};
},
mounted() {},
methods: {
getMessageLength(len){
this.messageNewsNum = len
}
}
onSearch(){
},
getMessageLength(len) {
this.messageNewsNum = len;
},
},
};
</script>
<style lang="less" scoped>
......
......@@ -14,9 +14,19 @@
</div>
<!-- 搜索 -->
<!-- <div class="search-wrap">
<van-search v-model="searchVal" placeholder="搜索" @search="onSearch" />
</div> -->
<div class="search-wrap">
<!-- <van-search
v-model="searchVal"
show-action
placeholder="请输入检查名称"
@search="onSearch"
>
<template #action>
<div @click="onSearch">搜索</div>
</template>
</van-search> -->
<!-- <van-search v-model="searchVal" placeholder="搜索" @search="onSearch" /> -->
</div>
<!-- 内容列表 -->
<div class="con-list" @touchmove="showIndex = null">
<!-- <van-pull-refresh v-model="refreshing" @refresh="onRefresh">
......@@ -32,6 +42,7 @@
:key="index"
@click="touchstart(index, item)"
>
<!--@touchend.prevent="touchend(index)" 长按备份-->
<div class="messgae-title"><span>{{ item.noticeTitle }}</span> <span>{{item.sendTime}}</span> </div>
<div class="message-content">
......@@ -111,7 +122,14 @@ export default {
},
// 搜索事件
onSearch(val) {},
onSearch(val) {
// console.log(this.searchVal);
// if(this.showIndex==2){
// }else{
// }
},
// 封装全部 已读 和 未读的方法
selectCategory(data) {
......
......@@ -18,7 +18,22 @@
<!-- 搜索 -->
<div class="search-wrap">
<van-search v-model="searchVal" placeholder="搜索" @search="onSearch" />
<van-search
v-model="searchVal"
show-action
placeholder="请输入检查名称"
@search="onSearch"
>
<template #action>
<div @click="onSearch">搜索</div>
</template>
</van-search>
<!-- <van-search
v-model="searchVal"
placeholder="搜索"
@search="onSearch"
@confirm="onSearch"
/> -->
</div>
<!-- 内容列表 -->
......@@ -30,13 +45,13 @@
finished-text="没有更多了"
@load="onLoad"
> -->
<!-- <van-cell-group inset>
<!-- <van-cell-group inset>
<div class="messgae-title">隐患确认信息</div>
<div class="message-content">
张大海已确认一般隐患B类,右万宝宝负责整改。
</div>
</van-cell-group> -->
<!-- </van-list>
<!-- </van-list>
</van-pull-refresh> -->
</div>
</div>
......@@ -51,16 +66,16 @@ export default {
messageCategory: [
{
key: "0",
category: "全部"
category: "全部",
},
{
key: "1",
category: "已读"
category: "已读",
},
{
key: "2",
category: "未读"
}
category: "未读",
},
],
activeIndex: 0,
searchVal: "",
......@@ -79,7 +94,7 @@ export default {
// 搜索事件
onSearch(val) {
if (val !== "") {
console.log(val);
console.log(this.searchVal);
}
},
......@@ -112,7 +127,7 @@ export default {
// // }
// }, 5000);
// }
}
},
};
</script>
<style lang="less" scoped>
......
......@@ -18,7 +18,17 @@
<!-- 搜索 -->
<div class="search-wrap">
<van-search v-model="searchVal" placeholder="搜索" @search="onSearch" />
<!-- <van-search
v-model="searchVal"
show-action
placeholder="请输入检查名称"
@search="onSearch"
>
<template #action>
<div @click="onSearch">搜索</div>
</template>
</van-search> -->
<!-- <van-search v-model="searchVal" placeholder="搜索" @search="onSearch" /> -->
</div>
<!-- 内容列表 -->
......@@ -30,13 +40,13 @@
finished-text="没有更多了"
@load="onLoad"
> -->
<!-- <van-cell-group inset>
<!-- <van-cell-group inset>
<div class="messgae-title">隐患确认信息</div>
<div class="message-content">
张大海已确认一般隐患B类,右万宝宝负责整改。
</div>
</van-cell-group> -->
<!-- </van-list>
<!-- </van-list>
</van-pull-refresh> -->
</div>
</div>
......@@ -51,16 +61,16 @@ export default {
messageCategory: [
{
key: "0",
category: "全部"
category: "全部",
},
{
key: "1",
category: "已读"
category: "已读",
},
{
key: "2",
category: "未读"
}
category: "未读",
},
],
activeIndex: 0,
searchVal: "",
......@@ -79,6 +89,7 @@ export default {
// 搜索事件
onSearch(val) {
if (val !== "") {
console.log(this.search)
}
},
......@@ -111,7 +122,7 @@ export default {
// // }
// }, 5000);
// }
}
},
};
</script>
<style lang="less" scoped>
......
<template>
<div>
<LHeader :text="text"></LHeader>
<!-- 内容列表 -->
<!-- 接口对接4 START -->
<!-- <van-sticky offset-top="1.5rem">
<van-search
v-model="searchValue"
show-action
placeholder="请输入检查名称"
@search="onSearch"
>
<template #action>
<div @click="onSearch">搜索</div>
</template>
</van-search>
</van-sticky> -->
<!-- 内容列表 -->
<!-- 接口对接4 START -->
<div class="con-list" @touchmove="showIndex = null">
<van-cell-group
inset
......@@ -11,32 +22,31 @@
:key="index"
@click="touchstart(index, item)"
>
<van-row gutter="">
<van-col span="5">风险编号:</van-col>
<van-col span="19">{{ item.businessId }}</van-col>
<van-col span="6">风险编号:</van-col>
<van-col span="18">{{ item.businessId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">风险级别:</van-col>
<van-col span="19">{{ item.riskLevel }}</van-col>
<van-col span="6">风险级别:</van-col>
<van-col span="18">{{ item.riskLevel }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.startDate }}</van-col>
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.startDate }}</van-col>
</van-row> -->
<van-row gutter="">
<van-col span="5">风险源:</van-col>
<van-col span="19">{{ item.riskSource }}</van-col>
<van-col span="6">风险源:</van-col>
<van-col span="18">{{ item.riskSource }}</van-col>
</van-row>
<!-- *接口对接4 END -->
<!-- *接口对接4 END -->
<!-- 长按显示遮罩层 -->
<van-overlay :show="showIndex == index">
<div class="wrapper" @click.stop ="showIndex = null">
<div class="wrapper" @click.stop="showIndex = null">
<van-button round type="primary" @click="goDetail(item)"
>详情</van-button
>
......@@ -44,19 +54,25 @@
</van-overlay>
</van-cell-group>
</div>
<!-- 暂无数据 -->
<!-- 暂无数据 -->
<div
style="width: 100%;text-align: center; font-size: .48rem;position: fixed; top: 30%;"
style="
width: 100%;
text-align: center;
font-size: 0.48rem;
position: fixed;
top: 30%;
"
v-if="isHaveNews"
>
暂无数据
</div>
</div>
</template>
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { postriskBook } from "@/service/risk";
/*接口对接2 START*/
......@@ -82,13 +98,13 @@ export default {
return {
text: "风险历史台账",
searchValue: "",
messageList: [],
isHaveNews: false,
messageList: [],
isHaveNews: false,
Loop: "", // 定时器
showIndex: null // 是否显示遮罩层
showIndex: null, // 是否显示遮罩层
};
},
created() {
created() {
this.getList();
},
methods: {
......@@ -99,17 +115,16 @@ export default {
message: "加载中...",
forbidClick: true,
loadingType: "spinner",
duration: 0
duration: 0,
});
postriskBook("/riskMain/doneList")
.then(res => {
.then((res) => {
this.$toast.clear();
this.messageList = res.rows
// 判断有无数据返回
this.messageList = res.rows;
// 判断有无数据返回
if (this.messageList.length == 0) {
this.isHaveNews = true;
}
})
.catch(() => {
this.$toast.clear();
......@@ -117,44 +132,52 @@ export default {
});
/*接口对接3 END*/
},
onSearch(val) {
},
onSearch(val) {},
touchstart(index, item) {
if (this.showIndex != null) {
this.showIndex = null;
return
return;
}
this.showIndex = index;
},
// 详情
goDetail(data) {
this.$router.push({
name: "risk-big-detail",
params: {
id: data.businessId
}
id: data.businessId,
},
});
this.showIndex = null;
},
}
},
};
</script>
<style lang="less" scoped>
/* @import url(); 引入css类 */
#app {
font-family: "";
color: #2c3e50;
}
.con-list {
padding: 10px 10px .533333rem;
padding: 0;
background-color: #f0f1f5;
.van-cell-group--inset {
margin: 0;
margin-bottom: 10px;
padding: 10px;
font-size: 13px;
margin-bottom: 0.26667rem;
padding: 0.25rem;
font-size: 0.4rem;
position: relative;
.van-row{
margin-bottom: .133333rem;
line-height: .64rem;
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;
......
......@@ -8,23 +8,23 @@
<van-cell-group inset >
<van-row gutter="">
<van-col span="7"
><span class="field-title">所属项目:</span></van-col
><span class="field-title">所属项目</span></van-col
>
<van-col span="17">{{ riskMain.pId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7"
><span class="field-title">风险因素:</span></van-col
><span class="field-title">风险因素</span></van-col
>
<van-col span="17">{{ riskMain.riskFactor }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7"><span class="field-title">风险源:</span></van-col>
<van-col span="7"><span class="field-title">风险源</span></van-col>
<van-col span="17">{{ riskMain.riskSource }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7"
><span class="field-title">事故类型:</span></van-col
><span class="field-title">事故类型</span></van-col
>
<van-col span="17">{{ riskMain.accidentType }}</van-col>
</van-row>
......@@ -33,43 +33,43 @@
<div v-show="riskOpen">
<van-row gutter="">
<van-col span="7"
><span class="field-title">风险等级:</span></van-col
><span class="field-title">风险等级</span></van-col
>
<van-col span="17">{{ riskMain.riskLevel }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7"
><span class="field-title">风险部位:</span></van-col
><span class="field-title">风险部位</span></van-col
>
<van-col span="17">{{ riskMain.emergencyMeasure }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7"
><span class="field-title">管控层级:</span></van-col
><span class="field-title">管控层级</span></van-col
>
<van-col span="17">{{ riskMain.controlLevel }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7"
><span class="field-title">主责部门:</span></van-col
><span class="field-title">主责部门</span></van-col
>
<van-col span="17">{{ riskMain.responsibilityDept }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7"
><span class="field-title">主责人员:</span></van-col
><span class="field-title">主责人员</span></van-col
>
<van-col span="17">{{ riskMain.responsibilityMember }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7"
><span class="field-title">定级方式:</span></van-col
><span class="field-title">定级方式</span></van-col
>
<van-col span="17">{{ riskMain.gradingMethod }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7"
><span class="field-title">定级方式(附件):</span></van-col
><span class="field-title">定级方式(附件)</span></van-col
>
<van-col span="17">
<div class="enclosure" v-for="(item, index) in riskMain.riskFileList1" :key="index">
......@@ -79,13 +79,13 @@
</van-row>
<van-row gutter="">
<van-col span="7"
><span class="field-title">技术措施:</span></van-col
><span class="field-title">技术措施</span></van-col
>
<van-col span="17">{{ riskMain.technicalMeasures }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7"
><span class="field-title">技术措施(附件):</span></van-col
><span class="field-title">技术措施(附件)</span></van-col
>
<van-col span="17">
<div class="enclosure" v-for="(item, index) in riskMain.riskFileList2" :key="index">
......@@ -95,13 +95,13 @@
</van-row>
<van-row gutter="">
<van-col span="7"
><span class="field-title">管理措施:</span></van-col
><span class="field-title">管理措施</span></van-col
>
<van-col span="17">{{ riskMain.managementMeasures }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7"
><span class="field-title">管理措施(附件):</span></van-col
><span class="field-title">管理措施(附件)</span></van-col
>
<van-col span="17">
<div class="enclosure" v-for="(item, index) in riskMain.riskFileList3" :key="index">
......@@ -111,13 +111,13 @@
</van-row>
<van-row gutter="">
<van-col span="7"
><span class="field-title">应急措施:</span></van-col
><span class="field-title">应急措施</span></van-col
>
<van-col span="17">{{ riskMain.emergencyMeasure }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7"
><span class="field-title">应急措施(附件):</span></van-col
><span class="field-title">应急措施(附件)</span></van-col
>
<van-col span="17">
<div class="enclosure" v-for="(item, index) in riskMain.riskFileList4" :key="index">
......@@ -137,12 +137,12 @@
<p>风险确认</p>
<van-cell-group inset v-for="(item, index) in confirmList" :key="index" >
<van-row gutter="">
<van-col span="7"><span class="field-title">意见:</span></van-col>
<van-col span="7"><span class="field-title">意见</span></van-col>
<van-col span="17">{{ item.confirmOpinion }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="7"
><span class="field-title">隐患确认信息:</span></van-col
><span class="field-title">隐患确认信息</span></van-col
>
<van-col span="17">{{ item.confirmResult == 1? "同意":"退回" }}</van-col>
</van-row>
......@@ -161,28 +161,28 @@
>
</van-row>
<van-row>
<van-col span="5"
<van-col span="6"
><span class="field-title">审批人:</span></van-col
>
<van-col span="19">{{item.userName}}</van-col>
<van-col span="18">{{item.userName}}</van-col>
</van-row>
<van-row>
<van-col span="5"
<van-col span="6"
><span class="field-title">节点:</span></van-col
>
<van-col span="19">{{item.logNode}}</van-col>
<van-col span="18">{{item.logNode}}</van-col>
</van-row>
<van-row>
<van-col span="5"
<van-col span="6"
><span class="field-title">结果:</span></van-col
>
<van-col span="19">{{item.logResult}}</van-col>
<van-col span="18">{{item.logResult}}</van-col>
</van-row>
<van-row>
<van-col span="5"
<van-col span="6"
><span class="field-title">部门:</span></van-col
>
<van-col span="19">{{item.deptName}}</van-col>
<van-col span="18">{{item.deptName}}</van-col>
</van-row>
</div>
......@@ -201,6 +201,7 @@
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { postriskDetail } from "@/service/risk";
export default {
......
......@@ -30,6 +30,7 @@
@click="showProjectName = true"
:rules="[{ required: true, message: '所属项目不能为空' }]"
/>
<!-- {{headH}} -->
<van-popup v-model="showProjectName" position="bottom">
<van-picker
show-toolbar
......@@ -299,6 +300,7 @@
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import {
getFormList,
postHdSource,
......
......@@ -33,6 +33,7 @@
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import Target from "./target.vue";
import Condition from "./condition.vue";
import { postCalRiskLevel } from "@/service/risk";
......
<template>
<div>
<LHeader :text="text"></LHeader>
<van-sticky offset-top="1.5rem">
<van-search
v-model="searchValue"
show-action
placeholder="请输入检查名称"
@search="onSearch"
>
<template #action>
<div @click="onSearch">搜索</div>
</template>
</van-search>
</van-sticky>
<!-- 内容列表 -->
<div class="con-list" @touchmove="showIndex = null">
......@@ -12,44 +23,44 @@
@click="touchstart(index, item)"
>
<van-row gutter="">
<van-col span="5">风险编号:</van-col>
<van-col span="19">{{ item.businessId }}</van-col>
<van-col span="6">风险编号:</van-col>
<van-col span="18">{{ item.businessId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">风险级别:</van-col>
<van-col span="19">{{ item.riskLevel }}</van-col>
<van-col span="6">风险级别:</van-col>
<van-col span="18">{{ item.riskLevel }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.startDate }}</van-col>
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.startDate }}</van-col>
</van-row> -->
<van-row gutter="">
<van-col span="5">风险源:</van-col>
<van-col span="19">{{ item.riskSource }}</van-col>
<van-col span="6">风险源:</van-col>
<van-col span="18">{{ item.riskSource }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">事故类型:</van-col>
<van-col span="19">{{ item.accidentType }}</van-col>
<van-col span="6">事故类型:</van-col>
<van-col span="18">{{ item.accidentType }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">管控层级:</van-col>
<van-col span="19">{{ item.controllevel }}</van-col>
<van-col span="6">管控层级:</van-col>
<van-col span="18">{{ item.controllevel }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">主责部门:</van-col>
<van-col span="19">{{ item.responsibilityDept }}</van-col>
<van-col span="6">主责部门:</van-col>
<van-col span="18">{{ item.responsibilityDept }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">主责人员:</van-col>
<van-col span="19">{{ item.responsibilityMember }}</van-col>
<van-col span="6">主责人员:</van-col>
<van-col span="18">{{ item.responsibilityMember }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">工单状态:</van-col>
<van-col span="19">{{ item.taskName }}</van-col>
<van-col span="6">工单状态:</van-col>
<van-col span="18">{{ item.taskName }}</van-col>
</van-row>
<!-- 长按显示遮罩层 -->
<van-overlay :show="showIndex == index">
......@@ -76,6 +87,7 @@
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { postriskConList } from "@/service/risk";
export default {
components: {
......@@ -96,14 +108,16 @@ export default {
this.postList()
},
methods: {
postList(){
postList(select=''){
this.$toast.loading({
message: "加载中...",
forbidClick: true,
loadingType: "spinner",
duration: 0
});
postriskConList("/riskConfirm/list")
let formdata=new FormData();
formdata.append('select',select)
postFun("/riskConfirm/list",formdata)
.then(res => {
this.$toast.clear();
this.messageList = res.rows
......@@ -118,9 +132,8 @@ export default {
});
},
onSearch(val) {
this.postList(this.searchValue)
},
touchstart(index, item) {
if (this.showIndex != null) {
......
......@@ -9,36 +9,36 @@
@click="goDetail(item.taskId)"
>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">风险等级:</van-col>
<van-col span="19">{{ item.riskLevel }}</van-col>
<van-col span="6">风险等级:</van-col>
<van-col span="18">{{ item.riskLevel }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">风险源:</van-col>
<van-col span="19">{{ item.riskSource }}</van-col>
<van-col span="6">风险源:</van-col>
<van-col span="18">{{ item.riskSource }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">事故类型:</van-col>
<van-col span="19">{{ item.accidentType }}</van-col>
<van-col span="6">事故类型:</van-col>
<van-col span="18">{{ item.accidentType }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">管控层级:</van-col>
<van-col span="19">{{ item.controllevel }}</van-col>
<van-col span="6">管控层级:</van-col>
<van-col span="18">{{ item.controllevel }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">主责部门:</van-col>
<van-col span="19">{{ item.responsibilityDept }}</van-col>
<van-col span="6">主责部门:</van-col>
<van-col span="18">{{ item.responsibilityDept }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">主责人员:</van-col>
<van-col span="19">{{ item.responsibilityMember }}</van-col>
<van-col span="6">主责人员:</van-col>
<van-col span="18">{{ item.responsibilityMember }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">工单状态:</van-col>
<van-col span="19">{{ item.taskName }}</van-col>
<van-col span="6">工单状态:</van-col>
<van-col span="18">{{ item.taskName }}</van-col>
</van-row>
<!-- 详情 -->
<div class="detail">详情</div>
......@@ -105,7 +105,9 @@
<script>
import LHeader from "@/components/header.vue";
import {getFun,postFun} from "@/service/table.js";
import { postriskConAdd } from "@/service/risk";
export default {
name: "risk-affirm",
components: {
......
<template>
<div>
<LHeader :text="text"></LHeader>
<!-- 内容列表 -->
<van-sticky offset-top="1.5rem">
<van-search
v-model="searchValue"
show-action
placeholder="请输入检查名称"
@search="onSearch"
>
<template #action>
<div @click="onSearch">搜索</div>
</template>
</van-search>
</van-sticky>
<!-- 内容列表 -->
<div class="con-list" @touchmove="showIndex = null">
<van-cell-group
inset
......@@ -10,75 +21,80 @@
:key="index"
@click="touchstart(index, item)"
>
<van-row gutter="">
<van-col span="5">风险编号:</van-col>
<van-col span="19">{{ item.businessId }}</van-col>
<van-row gutter="">
<van-col span="6">风险编号:</van-col>
<van-col span="18">{{ item.businessId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">所属项目:</van-col>
<van-col span="19">{{ item.proId }}</van-col>
<van-col span="6">所属项目:</van-col>
<van-col span="18">{{ item.proId }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">风险级别:</van-col>
<van-col span="19">{{ item.riskLevel }}</van-col>
<van-col span="6">风险级别:</van-col>
<van-col span="18">{{ item.riskLevel }}</van-col>
</van-row>
<!-- <van-row gutter="">
<van-col span="5">发现时间:</van-col>
<van-col span="19">{{ item.startDate }}</van-col>
<van-col span="6">发现时间:</van-col>
<van-col span="18">{{ item.startDate }}</van-col>
</van-row> -->
<van-row gutter="">
<van-col span="5">风险源:</van-col>
<van-col span="19">{{ item.riskSource }}</van-col>
<van-col span="6">风险源:</van-col>
<van-col span="18">{{ item.riskSource }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">事故类型:</van-col>
<van-col span="19">{{ item.accidentType }}</van-col>
<van-col span="6">事故类型:</van-col>
<van-col span="18">{{ item.accidentType }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">管控层级:</van-col>
<van-col span="19">{{ item.controllevel }}</van-col>
<van-col span="6">管控层级:</van-col>
<van-col span="18">{{ item.controllevel }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">主责部门:</van-col>
<van-col span="19">{{ item.responsibilityDept }}</van-col>
<van-col span="6">主责部门:</van-col>
<van-col span="18">{{ item.responsibilityDept }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">主责人员:</van-col>
<van-col span="19">{{ item.responsibilityMember }}</van-col>
<van-col span="6">主责人员:</van-col>
<van-col span="18">{{ item.responsibilityMember }}</van-col>
</van-row>
<van-row gutter="">
<van-col span="5">工单状态:</van-col>
<van-col span="19">{{ item.taskName }}</van-col>
<van-col span="6">工单状态:</van-col>
<van-col span="18">{{ item.taskName }}</van-col>
</van-row>
<!-- 长按显示遮罩层 -->
<van-overlay :show="showIndex == index">
<div class="wrapper" @click.stop ="showIndex = null">
<div class="wrapper" @click.stop="showIndex = null">
<van-button round type="primary" @click="goDetail(item)"
>上报</van-button
>
<van-button round type="warning" @click="goDelete(item)"
>删除</van-button
>关闭</van-button
>
</div>
</van-overlay>
</van-cell-group>
</div>
<!-- 暂无数据 -->
<!-- 暂无数据 -->
<div
style="width: 100%;text-align: center; font-size: .48rem;position: fixed; top: 30%;"
style="
width: 100%;
text-align: center;
font-size: 0.48rem;
position: fixed;
top: 30%;
"
v-if="isHaveNews"
>
暂无数据
</div>
</div>
</template>
<script>
import LHeader from "@/components/header.vue";
import { getFun, postFun } from "@/service/table.js";
import { postriskConReturn, postriskConReDel } from "@/service/risk";
export default {
components: {
......@@ -91,25 +107,27 @@ export default {
isHaveNews: false,
messageList: [],
Loop: "", // 定时器
showIndex: null // 是否显示遮罩层
showIndex: null, // 是否显示遮罩层
};
},
created() {
created() {
this.postList();
},
methods: {
postList() {
postList(select = "") {
this.$toast.loading({
message: "加载中...",
forbidClick: true,
loadingType: "spinner",
duration: 0
duration: 0,
});
postriskConReturn("/riskMain/list")
.then(res => {
let formdata = new FormData();
formdata.append("select", select);
postriskConReturn("/riskMain/list", formdata)
.then((res) => {
this.$toast.clear();
this.messageList = res.rows;
// 判断有无数据返回
// 判断有无数据返回
if (this.messageList.length == 0) {
this.isHaveNews = true;
}
......@@ -121,11 +139,12 @@ export default {
},
onSearch(val) {
this.postList(this.searchValue);
},
touchstart(index, item) {
if (this.showIndex != null) {
this.showIndex = null;
return
return;
}
this.showIndex = index;
},
......@@ -133,56 +152,75 @@ export default {
// 重新上报
goDetail(data) {
this.$router.push({
name: 'risk-add',
params: {
status: "退回",
taskId: data.taskId
}
});
// 存到缓存里 如果路由跳转或者是缓存中有 就是隐患上报退回
localStorage.setItem('riskAddTaskId',data.taskId)
name: "risk-add",
params: {
status: "退回",
taskId: data.taskId,
},
});
// 存到缓存里 如果路由跳转或者是缓存中有 就是隐患上报退回
localStorage.setItem("riskAddTaskId", data.taskId);
this.showIndex = null;
},
// 删除
goDelete(data) {
this.$toast.loading({
message: "删除中...",
forbidClick: true,
loadingType: "spinner",
duration: 0
});
postriskConReDel(`/riskMain/delete/${data.taskId}`)
.then(res => {
this.$toast.clear();
this.$toast.success({
message: "删除成功",
duration: 2000
this.$dialog.confirm({
title: "提示",
message: "确认要关闭此条隐患吗?",
})
.then(() => {
this.$toast.loading({
message: "关闭中...",
forbidClick: true,
loadingType: "spinner",
duration: 0,
});
this.postList();
postriskConReDel(`/riskMain/delete/${data.taskId}`)
.then((res) => {
this.$toast.clear();
this.$toast.success({
message: "关闭成功",
duration: 2000,
});
this.postList();
})
.catch(() => {
this.$toast.clear();
this.$toast.fail("关闭失败,请稍后再试");
});
this.showIndex = null;
})
.catch(() => {
.catch((err) => {
this.$toast.clear();
this.$toast.fail("删除失败,请稍后再试");
this.showIndex = null;
});
this.showIndex = null;
}
}
},
},
};
</script>
<style lang="less" scoped>
/* @import url(); 引入css类 */
#app {
font-family: "";
color: #2c3e50;
}
.con-list {
padding: 10px 10px .533333rem;
padding: 0;
background-color: #f0f1f5;
.van-cell-group--inset {
margin: 0;
margin-bottom: 10px;
padding: 10px;
font-size: 13px;
margin-bottom: 0.26667rem;
padding: 0.25rem;
font-size: 0.4rem;
position: relative;
.van-row{
margin-bottom: .133333rem;
line-height: .64rem;
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;
......
......@@ -287,6 +287,7 @@ export default {
},
// 搜索事件
onSearch(val) {
this.postList(this.searchValue)
},
// 请求工作台列表
getWorkList() {
......
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