Commit b1a877cd authored by 王李辉's avatar 王李辉

Merge branch 'develop' of http://git.censoft.com.cn/BCDH-HSE/bcdh-app into develop

parents 12f84d52 9095144c
......@@ -49,7 +49,6 @@ service.interceptors.response.use(response => {
});
}
}else{
// Notify({ type: 'danger', message: '失败' });
Promise.reject(new Error('Error'))
}
},err=>{
......
......@@ -63,17 +63,8 @@ export default {
},
cardLocation(item){
console.log(item)
this.$router.push({
name:'problem',
query:{
checkitemId:item.id,
name:item.name,
type:item.type,
planStartTime:item.planStartTime,
planEndTime:item.planEndTime,
address:item.address,
}
})
sessionStorage.setItem('id',item.id)
this.$router.push('/problem')
}
}
}
......
......@@ -12,11 +12,11 @@
<div>
<LHeader v-bind:text="text"></LHeader>
<div class="card">
<div>检查名称:{{itemlist.name}}</div>
<div>检查类型:{{itemlist.type}}</div>
<div>检查开始时间:{{itemlist.planStartTime}}</div>
<div>检查结束时间:{{itemlist.planEndTime}}</div>
<div>检查地点:{{itemlist.address}}</div>
<div>检查名称:{{nums.name}}</div>
<div>检查类型:{{nums.type}}</div>
<div>检查开始时间:{{nums.planStartTime}}</div>
<div>检查结束时间:{{nums.planEndTime}}</div>
<div>检查地点:{{nums.address}}</div>
</div>
<div class="button-more">
<van-button type="primary" round size="large" @click="problem">检查问题上报{{nums.TroubleNumber}}</van-button>
......@@ -38,27 +38,17 @@ export default {
data() {
return {
nums:{},
itemlist:{},
text:'问题上报'
}
},
mounted() {
if(this.$route.query.checkitemId){
this.itemlist={
id:this.$route.query.checkitemId,
name:this.$route.query.name,
type:this.$route.query.type,
planStartTime:this.$route.query.planStartTime,
planEndTime:this.$route.query.planEndTime,
address:this.$route.query.address,
}
}
this.init()
},
methods: {
init(){
var id=sessionStorage.getItem('id')
this.nums=[];
getFun('check/carry/count').then((Response)=>{
getFun('check/carry/count',{planId:id}).then((Response)=>{
this.nums=Response.data
})
},
......@@ -74,7 +64,12 @@ export default {
this.$router.push('/list')
},
note(){
this.$router.push('/note')
this.$router.push({
name:'note',
query:{
id:this.nums.id
}
})
},
formwork(){
this.$router.push('/formwork')
......
......@@ -13,24 +13,12 @@
<LHeader v-bind:text="text"></LHeader>
<van-checkbox-group v-model="result" @change="checkedEvent" ref="checkboxGroup">
<div class="card" v-for="(item,index) in list" :key="index" >
<van-checkbox :name="item.planItemId" :disabled="item.planItemId==1?true:false">问题{{item.id}}</van-checkbox>
<van-checkbox :name="item.id" :disabled="item.checkSubmitId?true:false">问题{{item.id}}</van-checkbox>
<div>问题名称:{{item.title}}</div>
<div>问题位置:{{item.address}}</div>
<div>问题内容:{{item.context}}</div>
<div>发现时间:{{item.checkTime}}</div>
</div>
<!-- <div class="card">
<van-checkbox name="b">问题二</van-checkbox>
<div>问题描述:未编制专项试工方案或未进行设计计算</div>
<div>具体位置:项目内页管理</div>
<div>发现时间:2021-12-15</div>
</div>
<div class="card">
<van-checkbox name="c">问题三</van-checkbox>
<div>问题描述:未编制专项试工方案或未进行设计计算</div>
<div>具体位置:项目内页管理</div>
<div>发现时间:2021-12-15</div>
</div> -->
</van-checkbox-group>
<div class="page-footer">
<van-checkbox v-model="checkedAll" @change="checkedAllEvent" @click="checkedAllClick">全选</van-checkbox>
......@@ -55,16 +43,25 @@ export default {
text:'问题记录',
checkedAll:false,
result: [],
list:[]
list:[],
id:'',
}
},
mounted() {
if(this.$route.query.id){
this.id=this.$route.query.id
}
this.init()
},
methods: {
init(){
getFun('check/carry/trouble/list').then((Response)=>{
getFun('check/carry/trouble/list',).then((Response)=>{
this.list=Response.data
this.list.forEach((item)=>{
if(item.checkSubmitId){
this.result.push(parseInt(item.checkSubmitId))
}
})
})
},
//全选点击事件---只让全选框的触发全不选事件
......@@ -72,13 +69,18 @@ export default {
if(this.checkedAll){
this.$refs.checkboxGroup.toggleAll(true);
}else{
this.$refs.checkboxGroup.toggleAll(false);
/* 全不选只可以控制未禁用状态下的复选框 */
for(var key of this.$refs.checkboxGroup.$children){
if(!key.$el._prevClass.includes('disabled')){
key.toggle(false)
}
}
}
},
checkedEvent(list){
if(list.length==3){
checkedEvent(){
if(this.result.length==this.list.length){
this.checkedAll=true
}else if(list.length<3){
}else if(this.result.length<this.list.length){
this.checkedAll=false
}
},
......@@ -91,9 +93,18 @@ export default {
this.$toast.success('取消')
},
commit(){
var checkedList=[]
/* 禁用状态下的(已选过)问题不进行提交,进行清空处理 */
this.result.forEach((it)=>{
this.list.forEach((item)=>{
if(it==item.id&&!item.checkSubmitId){
checkedList.push(it)
}
})
})
var obj={
planId:1,
troubleIds:this.result
planId:this.id,
troubleIds:checkedList
}
this.$dialog.confirm({
title: '提示',
......
......@@ -11,17 +11,21 @@
<template>
<div>
<LHeader v-bind:text="text"></LHeader>
<div class="card" @click="cardLocation">
<div>检查名称:昌平区回迁房改造项目安全检查</div>
<div>检查名称:专项检查</div>
<div>检查名称:2021-12-15</div>
<div>检查名称:昌平区回迁房改造工程</div>
<div class="card" v-for="(item,index) in noticeList" :key="index" @click="cardLocation(item)">
<div>负责人姓名:{{item.realName}}</div>
<div>检查名称:{{item.name}}</div>
<div>检查类型:{{item.type}}</div>
<div>检查开始时间:{{item.planStartTime}}</div>
<div>检查结束时间:{{item.planEndTime}}</div>
<div>检查地点:{{item.address}}</div>
<div>是否完成检查:{{item.finish?'':''}}</div>
</div>
</div>
</template>
<script>
import LHeader from '@/components/header.vue'
import { getFun,postFun } from '@/service/table'
export default {
name: 'notice',
components: {
......@@ -29,17 +33,28 @@ export default {
},
data() {
return {
noticeList:[],
value:'',
text:'整改通知管理'
}
},
mounted() {
this.init()
},
methods: {
cardLocation(){
console.log(123)
this.$router.push('/noticeList')
init(){
this.noticeList=[]
getFun('check/notify/list').then((Response)=>{
this.noticeList=Response.data
})
},
cardLocation(item){
this.$router.push({
name:'noticeList',
query:{
id:item.id
}
})
}
}
}
......
......@@ -19,39 +19,29 @@
<tr>
<th>序号</th>
<th>姓名</th>
<th>性别</th>
<th>年龄</th>
<th>状态</th>
<th>问题数量</th>
</tr>
</thead>
<tbody>
<tr v-for="(user,index) in user" :key="index">
<tr v-for="(user,index) in noticeTableList" :key="index">
<td align="center" v-text="index+1"></td>
<td align="center" v-text="user.name"></td>
<td align="center" v-text="user.gender"></td>
<td align="center" v-text="user.age"></td>
<td align="center" v-text="user.realName"></td>
<td align="center" >{{user.submit?'已提交':'未提交'}}</td>
<td align="center" v-text="user.troubleNumber"></td>
</tr>
</tbody>
</table>
</van-tab>
<van-tab title="问题记录">
<van-checkbox-group v-model="result" @change="checkedEvent" ref="checkboxGroup">
<div class="card">
<van-checkbox name="a">问题一</van-checkbox>
<div>问题描述:未编制专项试工方案或未进行设计计算</div>
<div>具体位置:项目内页管理</div>
<div>发现时间:2021-12-15</div>
</div>
<div class="card">
<van-checkbox name="b">问题二</van-checkbox>
<div>问题描述:未编制专项试工方案或未进行设计计算</div>
<div>具体位置:项目内页管理</div>
<div>发现时间:2021-12-15</div>
</div>
<div class="card">
<van-checkbox name="c">问题三</van-checkbox>
<div>问题描述:未编制专项试工方案或未进行设计计算</div>
<div>具体位置:项目内页管理</div>
<div>发现时间:2021-12-15</div>
<div class="card" v-for="(item,index) in noticeQuestionList" :key="index" >
<van-checkbox :name="item.id" :disabled="item.checkSubmitId?true:false">问题{{item.id}}</van-checkbox>
<div>负责人姓名:{{item.realName}}</div>
<div>问题名称:{{item.title}}</div>
<div>问题位置:{{item.address}}</div>
<div>问题内容:{{item.context}}</div>
<div>发现时间:{{item.checkTime}}</div>
</div>
</van-checkbox-group>
<div class="page-footer">
......@@ -79,6 +69,7 @@
<script>
import LHeader from '@/components/header.vue'
import { getFun,postFun } from '@/service/table'
export default {
name: 'notice',
components: {
......@@ -86,38 +77,57 @@ export default {
},
data() {
return {
noticeQuestionList:[],//整改通知问题记录列表
active: 0,
checkedAll:false,
result: [],
valuetext:'',
user:[
{name:"杨过",gender:"",age:"30"},
{name:"小龙女",gender:"",age:"35"},
{name:"郭靖",gender:"",age:"36"},
{name:"黄蓉",gender:"",age:"36"},
{name:"郭襄",gender:"",age:"18"},
],
noticeTableList:[],
text:'整改通知管理列表',
value: '',
id:'',
showCalendar: false,
}
},
mounted() {
if(this.$route.query.id){
this.id=this.$route.query.id
}
this.init()
this.problem()
},
methods: {
//全选点击事件---只让全选框的触发全不选事件
/* 上报状态列表 */
init(){
this.noticeTableList=[]
getFun('check/notify/user/list',{planId:this.id}).then((Response)=>{
this.noticeTableList=Response.data
})
},
/* 问题记录列表 */
problem(){
this.noticeQuestionList=[]
getFun('check/notify/trouble/list',{planId:this.id}).then((Response)=>{
this.noticeQuestionList=Response.data
})
},
/* 全选点击事件---只让全选框的触发全不选事件 */
checkedAllClick(){
if(this.checkedAll){
this.$refs.checkboxGroup.toggleAll(true);
}else{
this.$refs.checkboxGroup.toggleAll(false);
/* 全不选只可以控制未禁用状态下的复选框 */
for(var key of this.$refs.checkboxGroup.$children){
if(!key.$el._prevClass.includes('disabled')){
key.toggle(false)
}
}
}
},
checkedEvent(list){
if(list.length==3){
if(this.result.length==this.list.length){
this.checkedAll=true
}else if(list.length<3){
}else if(this.result.length<this.list.length){
this.checkedAll=false
}
},
......
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