lion 3 years ago
parent 4b5eda6876
commit 33ae374cbc

@ -302,6 +302,7 @@ font-size: 15px;
margin-bottom:0
}
.el-form-item__error{
display: none;
white-space: nowrap;
word-break: keep-all !important;
top: 100% !important;

@ -4,7 +4,7 @@
:rules="rules" @submit="submit">
<!-- 审核 领导审核 -->
<!-- 退回理由 -->
<template v-slot:backreason v-if="type=='check'||type=='leader'&&showform.status ==8" >
<template v-slot:backreason v-if="(type=='check'||type=='leader')&&showform.status ==8" >
<div class="xy-table-item">
<div class="xy-table-item-label">
<span style="color: red;font-weight: 600;padding-right: 4px;"></span>退回原因
@ -183,7 +183,47 @@
<!-- 提交整改 -->
<template v-slot:fix_status v-if="type=='reform'||type=='confirm'||type=='leaderconfirm'">
<template v-slot:accept_admin_name v-if="type=='reform'||type=='confirm'||type=='leaderconfirm'||type=='show' && showform.status>2 &&showform.status!=6 && showform.status!=8">
<div class="xy-table-item">
<div class="xy-table-item-label">
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>接收方
</div>
<div class="xy-table-item-content">
<div v-if="showform.accept_admin_ids_details&&showform.accept_admin_ids_details.length>0">
<el-tag style='margin-right:10px' v-for='item in showform.accept_admin_ids_details'>
{{item.name}}
</el-tag>
</div>
<div v-if="showform.accept_department_ids_details&&showform.accept_department_ids_details.length>0">
<el-tag v-for='item in showform.accept_department_ids_details'>
{{item.name}}
</el-tag>
</div>
</div>
</div>
</template>
<template v-slot:plan_end_date_name v-if="type=='reform'||type=='confirm'||type=='leaderconfirm'||type=='show' && showform.status>2 &&showform.status!=6 && showform.status!=8">
<div class="xy-table-item">
<div class="xy-table-item-label">
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>计划完成时间
</div>
<div class="xy-table-item-content">
{{showform.plan_end_date?showform.plan_end_date:''}}
</div>
</div>
</template>
<template v-slot:duty_admin_name v-if="type=='reform'||type=='confirm'||type=='leaderconfirm'||type=='show' && showform.status>2 &&showform.status!=6 && showform.status!=8">
<div class="xy-table-item">
<div class="xy-table-item-label">
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>责任人
</div>
<div class="xy-table-item-content">
{{showform.duty_admin?showform.duty_admin.name:''}}
</div>
</div>
</template>
<template v-slot:fix_status v-if="type=='reform'||type=='confirm'||type=='leaderconfirm'||type=='show' && showform.status>2 &&showform.status!=6 && showform.status!=8">
<div class="xy-table-item">
<div class="xy-table-item-label">
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>整改完成情况
@ -199,7 +239,7 @@
</div>
</div>
</template>
<template v-slot:fix_end_date v-if="type=='reform'||type=='confirm'||type=='leaderconfirm'">
<template v-slot:fix_end_date v-if="type=='reform'||type=='confirm'||type=='leaderconfirm'||type=='show' && showform.status>2 &&showform.status!=6 && showform.status!=8">
<div class="xy-table-item">
<div class="xy-table-item-label">
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>整改结束时间
@ -214,7 +254,7 @@
</div>
</div>
</template>
<template v-slot:fix_introduce v-if="type=='reform'||type=='confirm'||type=='leaderconfirm'">
<template v-slot:fix_introduce v-if="type=='reform'||type=='confirm'||type=='leaderconfirm'||type=='show' && showform.status>2 &&showform.status!=6 && showform.status!=8">
<div class="xy-table-item">
<div class="xy-table-item-label">
<span style="color: red;font-weight: 600;padding-right: 4px;">*</span>整改说明
@ -228,7 +268,7 @@
</div>
</div>
</template>
<template v-slot:fix_file_ids v-if="type=='reform'||type=='confirm'||type=='leaderconfirm'">
<template v-slot:fix_file_ids v-if="type=='reform'||type=='confirm'||type=='leaderconfirm'||type=='show' && showform.status>2 &&showform.status!=6 && showform.status!=8">
<div class="xy-table-item">
<div class="xy-table-item-label">
<span style="color: red;font-weight: 600;padding-right: 4px;"></span>整改附件
@ -468,6 +508,10 @@
plan_end_date:'',
duty_admin_id:'',
reason:'',
accept_admin_name:"",
plan_end_date_name:'',
duty_admin_name:'',
fix_status:1,
fix_end_date:'',
fix_introduce:'',
@ -636,7 +680,7 @@
}else{
name7value = 1
}
this.form = {
backreason:'',
//
@ -653,6 +697,10 @@
plan_end_date:res?.plan_end_date,
duty_admin_id:res?.duty_admin_id,
reason:res?.reason,
accept_admin_name:"",
plan_end_date_name:'',
duty_admin_name:'',
fix_status:res.fix_status==1?1:0,
fix_end_date:res?.fix_end_date,
fix_introduce:res?.fix_introduce,
@ -861,6 +909,7 @@
::v-deep .fix_introduce,::v-deep .fix_file_ids,
::v-deep .confirm_status,::v-deep .re_check_leader,::v-deep .re_check_main,
::v-deep .re_leader_status,::v-deep .re_main_status,
::v-deep .plan_end_date_name,::v-deep .duty_admin_name,::v-deep .accept_admin_name,
{
flex-basis: 100%;
}

@ -24,6 +24,7 @@
<template v-slot:btns>
<el-table-column fixed="right" align='left' label="操作" width="260" header-align="center">
<template slot-scope="scope">
<Button type="primary" style='margin-right:5px;margin-bottom:5px;' size="small" @click="showPatrol(scope.row.id,'show')"></Button>
<Button type="primary" style='margin-right:5px;margin-bottom:5px;' size="small" @click="editorPatrol(scope.row.id,'editor')"></Button>
<Button type="primary" style='margin-right:5px;margin-bottom:5px;' size="small" @click="showPatrol(scope.row.id,'check')"></Button>
<Button type="primary" style='margin-right:5px;margin-bottom:5px;' size="small" @click="showPatrol(scope.row.id,'leader')"></Button>
@ -137,7 +138,7 @@
width:180,
},{
label:"地点",
prop:'site_id',
prop:'site.name',
width:180,
},{
label:"问题图片",
@ -213,6 +214,10 @@
}
</div>)
}
},{
label:"上报人",
prop:'admin.name',
width:180,
}],
list:[]
}

@ -5,17 +5,108 @@
<slot>
<div style="display: flex;justify-content: flex-start;flex-wrap: wrap;">
<Input v-model="select.keyword" style="width: 200px;margin-right: 10px;" placeholder="关键字搜索" />
<Select multiple filterable clearable style='width:200px;margin-right: 10px;' v-model="select.unit_type" placeholder="任务类型">
<!-- <Select multiple filterable clearable style='width:200px;margin-right: 10px;' v-model="select.unit_type" placeholder="任务类型">
<Option v-for="item in unitTypeList" :value="item.id">{{item.value}}</Option>
</Select>
</Select> -->
<Button type="primary" @click="getList"></Button>
<Button icon="ios-add" type="primary" style="margin-left: 10px;" @click="$refs['addUnit'].isShow=true,$refs['addUnit'].type='add'"></Button>
</div>
</slot>
</lx-header>
</div>
<xy-table
<el-table
:data="list"
style="width: 100%"
class='v-table'
border
:height='tableHeight'>
<el-table-column type="index" align="center" fixed="left"></el-table-column>
<el-table-column type="expand">
<template slot-scope="props">
<div v-if="props.row.inspection.length>0">
<div align="left" v-for='(item,index) in props.row.inspection' class="expenditem">
<!-- <div> -->
<Button type="primary" style='margin-right:10px;' size="small" @click="showPatrol(item.id,'show')"></Button>
<!-- </div> -->
{{index+1}}
<div v-for="(k,label) of inspectionTable">
<span class='label'>
{{label}}
</span>
<span v-if="k=='status'">
<template v-for='s in statusList'>
<span v-if="s.id==item[k]">
{{s.value}}
</span>
</template>
</span>
<span v-else>
{{(k.indexOf(".")>-1?item[k.split(".")[0]][k.split(".")[1]]:item[k])}}
</span>
</div>
</div>
</div>
<div v-else class="expenditem">
暂无巡查上报
</div>
</template>
</el-table-column>
<el-table-column
v-for="item in table"
:label="item.label"
:fixed='item.fixed'
:align='item.align'
:width='item.width'
:prop="item.prop">
<template slot-scope="scope">
<span v-if="item.formatter">
{{item.formatter(scope.row,scope.row,scope.row[item.prop])}}
</span>
<div v-else-if='item.customFn'>
<div style = "white-space: normal;text-align: left;">
<div v-if="scope.row.accept_department.length>0">
<el-tag v-for="department in scope.row.accept_department" style="margin-right: 5px;margin-bottom: 2px;">{{department.name}}</el-tag>
</div>
<div v-if="scope.row.accept_admin.length>0">
<el-tag v-for="admin in scope.row.accept_admin" style="margin-right: 5px;margin-bottom: 2px;">{{admin.name}}</el-tag>
</div>
</div>
</div>
<span v-else>
{{(item.prop.indexOf(".")>-1?scope.row[item.prop.split(".")[0]][item.prop.split(".")[1]]:scope.row[item.prop])}}
</span>
</template>
</el-table-column>
<el-table-column fixed="right" label="操作" width="220" header-align="center">
<template slot-scope="scope">
<Button type="primary" size="small" @click="editorUnit(scope.row.id,'editor')"></Button>
<Poptip
transfer
confirm
title="确认要删除吗?"
@on-ok="deleteList(scope.row.id)">
<Button type="primary" style="margin-left: 10px;" size="small" ghost>删除</Button>
</Poptip>
</template>
</el-table-column>
</el-table>
<Page :total="total"
show-elevator
show-sizer
show-total
:page-size='select.page_size'
size='small'
@on-change='changePage'
@on-page-size-change='changePageSize'/>
<!-- <xy-table
:list="list"
:total="total"
@pageSizeChange="e => {select.page_size = e,getList()}"
@ -36,17 +127,21 @@
</el-table-column>
</template>
</xy-table>
</xy-table> -->
<addUnit ref='addUnit' @refresh='getList'></addUnit>
<showPatrol ref='showPatrol'></showPatrol>
</div>
</template>
<script>
import addUnit from '../list/components/addUnit.vue'
import showPatrol from '../list/components/showPatrol.vue'
import {listunit,del} from '@/api/task/unit.js'
export default{
components:{
addUnit
addUnit,
showPatrol
},
data(){
return{
@ -64,6 +159,7 @@
name:'科室任务'
}],
type_name:'',
tableHeight:0,
select:{
keyword:'',
page:1,
@ -88,7 +184,7 @@
label:"标题",
prop:'name',
align:'left',
fixed:'left',
// fixed:'left',
width:240
},{
label:"开始日期",
@ -141,13 +237,52 @@
}):'')
}
</div>)
}
}],
inspectionTable:{
'上报日期':'date',
'状态':'status',
'问题类型':'ask.value',
'地点':'site.name',
},
statusList:[{
id:0,
value:'待审核'
},{
id:1,
value:'待领导确认'
},{
id:2,
value:'已分发,待接收'
},{
id:3,
value:'已接收'
},{
id:4,
value:'提交整改'
},{
id:5,
value:'已整改'
},{
id:6,
value:'不通过'
},{
id:7,
value:'整改不通过,重新整改'
},{
id:8,
value:'部门退回'
},{
id:9,
value:'待领导确认整改'
}],
list:[]
}
},
created(){
this.initHeight()
if(this.$route.path){
let path = this.$route.path.split("_")
this.select.type = path[1]
@ -161,13 +296,35 @@
},
watch:{},
methods:{
async getList(){
initHeight(){
var that = this;
var clientHeight = document.documentElement.clientHeight
var lxHeader_height = 96.5; //
var paginationHeight = 37; //
var topHeight = 50; //
let tableHeight = clientHeight - lxHeader_height - topHeight - paginationHeight - 20;
that.tableHeight = tableHeight;
},
showPatrol(id,type){
this.$refs.showPatrol.id= id
this.$refs.showPatrol.type= type
this.$refs.showPatrol.isShow = true
},
async getList(){
const res = await listunit({...this.select})
this.list = res.data
this.total = res.total
},
pageChange(){},
changePage(e){
this.select.page = e
this.getList()
},
changePageSize(e){
this.select.page_size = e
this.getList()
},
editorUnit(id,type){
this.$refs.addUnit.id= id
this.$refs.addUnit.type= type
@ -201,4 +358,27 @@
/deep/ .el-icon-circle-close{
color:#fff
}
.expenditem{
display: flex;
font-size: 14px;
padding: 10px;
border-bottom: 1px solid #EBEEF5;
padding-left: 110px;
font-size: 16px;
}
.expenditem>div{
margin-right:15px;
min-width: 200px;
}
.expenditem>div span.label{
color:#97a8be
}
/deep/ .el-table__expanded-cell .expenditem:last-child{
border-bottom: none;
}
/deep/ .ivu-page{
text-align: right;
padding: 15px;
}
</style>

Loading…
Cancel
Save