| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612 |
- <template>
- <el-container class="monthReport">
- <el-card class="box-card">
- <h3 class="title_monthReport" style="font-size: 20px !important;font-weight: bold !important;color: black !important;">
- <el-date-picker
- v-model="year"
- type="monthrange"
- value-format="yyyy-MM"
- range-separator="至"
- start-placeholder="开始月份"
- end-placeholder="结束月份">
- </el-date-picker>
- 督查计划执行情况
- </h3>
- <el-form :inline="true" size="mini" class="demo-form-inline" label-width="120px">
- <el-form-item label="监督事项名称">
- <el-select v-model="objTypes" multiple collapse-tags placeholder="监督事项名称" clearable>
- <el-option
- v-for="item in dcTypeList"
- :key="item.code"
- :label="item.inspName"
- :value="item.inspType">
- </el-option>
- </el-select>
- </el-form-item>
- <el-form-item label="检查组次名称">
- <el-input v-model="searchForm.groupName" placeholder="检查组次名称" clearable></el-input>
- </el-form-item>
- <el-form-item label="检查区域">
- <el-input v-model="searchForm.chkArea" placeholder="检查区域" clearable></el-input>
- </el-form-item>
- <el-form-item label="检查项目">
- <el-input v-model="searchForm.objName" placeholder="检查项目" clearable></el-input>
- </el-form-item>
- <el-form-item>
- <el-button type="primary" size="mini" @click="searchBtn">督查计划执行情况查询</el-button>
- <!-- <el-button type="primary" size="mini" @click="chkMul" style="background:#2711ff;">查重</el-button>-->
- <el-button type="warning" size="mini" @click="oneDel">一键处理</el-button>
- <el-button type="warning" size="mini" @click="exportExcel">导出</el-button>
- </el-form-item>
- </el-form>
- <div>
- <el-table
- border
- ref="multipleTable"
- :height="tableHeight"
- :data="tableData"
- :row-style="rowClass"
- tooltip-effect="dark"
- style="width: 100%"
- v-loading="loading"
- @selection-change="handleSelectionSend">
- <el-table-column
- type="selection"
- width="55">
- </el-table-column>
- <el-table-column align="center" type="index" label="序号" min-width="50">
- <template slot-scope="scope">{{ (pageNum - 1) * pageSize + (scope.$index + 1) }}</template>
- </el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="200"
- prop="GROUPNAME"
- label="检查组次名称"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="200"
- prop="OBJNAME"
- label="检查内容"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="200"
- prop=""
- label="检查时间"
- show-overflow-tooltip
- >
- <template slot-scope="scope">
- <span v-if="scope.row.STTM && scope.row.ENTM">{{scope.row.STTM+"~"+scope.row.ENTM}}</span>
- </template>
- </el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="200"
- prop="CHKAREA"
- label="检查区域"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="200"
- prop="COUNT"
- label="项目数量"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="200"
- prop="CHKFORM"
- label="检查形式"
- :formatter="chkFormFormat"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="200"
- prop="LEADDEP"
- label="牵头单位"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="200"
- prop="PERSNAME"
- label="联络人"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="200"
- prop="MOBILENUMB"
- label="联系方式"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="200"
- prop="OBJNAMES"
- label="检查项目"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- v-if="isOne"
- min-width="200"
- prop="isR"
- label="是否重复"
- show-overflow-tooltip
- >
- <template slot-scope="scope">
- <span v-if="scope.row.isR" style="color:red;">是</span>
- <span v-else style="color:#4d9bff;">否</span>
- </template>
- </el-table-column>
- <!-- <el-table-column-->
- <!-- header-align="center"-->
- <!-- align="center"-->
- <!-- min-width="200"-->
- <!-- prop="isR"-->
- <!-- v-if="isOne"-->
- <!-- label="上报状态"-->
- <!-- show-overflow-tooltip-->
- <!-- >-->
- <!-- <template slot-scope="scope">-->
- <!-- <span v-if="scope.row.isR" style="color:red;">审核不通过</span>-->
- <!-- <span v-else style="color:#4d9bff;">审核通过</span>-->
- <!-- </template>-->
- <!-- </el-table-column>-->
- </el-table>
- </div>
- </el-card>
- </el-container>
- </template>
- <script>
- import {exportModel} from "@util/gw_exportModel";
- import request from '@util/gw_ajax_request'
- import receiver from "./receiver"
- export default {
- name: "",
- props: ["rowData"],
- data() {
- return {
- mulSelectionSend:[],
- curList:[],
- year:[new Date().getFullYear()+"-01",new Date().getFullYear()+"-"+((new Date().getMonth()+1)>9?(new Date().getMonth()+1):"0"+(new Date().getMonth()+1))],
- month:new Date().getMonth()+1,
- isOne:false,
- years:[new Date().getFullYear()-1,new Date().getFullYear(),new Date().getFullYear()+1],
- months:[1,2,3,4,5,6,7,8,9,10,11,12],
- dcTypeList:[],
- ptypeArr:[{label:'暗访',value:"0"},{label:'明查',value:"1"}],
- dialogT:"",
- monthDialogVisible:true,
- addDialogVisible:false,
- tableHeight:window.innerHeight-260,
- tableData:[],
- loading:false,
- pageNum:1,
- pageSize:10,
- total:0,
- objTypes:[],
- searchForm:{
- groupName:"",
- chkArea:"",
- objName:""
- },
- YM:"",
- orgIdDefault:"",
- addForm:{
- chkYearId:"",
- unitName:"",
- year:"",
- mnth:"",
- idx:"",
- pname:"",
- ptype:"",
- tm:"",
- prjSize:"",
- depSize:"",
- chkSize:"",
- leadSize:"",
- chkDaySize:"",
- feedBackSize:"",
- pblmSize:"",
- mendSize:"",
- mendCmpSize:"",
- mendCmpTatSize:"",
- mendCmpRatio:"",
- accuntDep:"",
- accuntText:"",
- acuntTm:"",
- accuntNote:""
- }
- }
- },
- components: {
- receiver
- },
- computed: {
- persId() {
- return localStorage.getItem("userid")
- ? localStorage.getItem("userid")
- : "1098101939614724096";
- },
- orgId() {
- return localStorage.getItem('currentOrgId') ? localStorage.getItem("currentOrgId") : "";
- },
- organCode() {
- return localStorage.getItem('currentRlcode') ? localStorage.getItem('currentRlcode') : ''
- },
- },
- created(){
- this.getTypes();
- },
- mounted() {
- this.initTableData();
- },
- methods: {
- isRe(arr,arr1){
- var flag = false;
- if(arr.CHKAREA && arr1.CHKAREA){
- var list = arr1.CHKAREA.split(",");
- for(var j = 0;j<list.length;j++){
- if (arr.CHKAREA.indexOf(list[j])>-1){
- flag = true;
- }
- }
- }
- return flag;
- },
- handleSelectionSend(val){
- this.mulSelectionSend = val;
- },
- rowClass({row, index}) {
- if(row.isR) {
- return { "background-color": "#ffb2df" }
- }
- },
- chkFormFormat(row, column, cellValue, index){
- return row.CHKFORM=="1"?"暗访":row.CHKFORM=="2"?"明察":row.CHKFORM=="3"?"书面":row.CHKFORM=="4"?"四不两直":"";
- },
- getTypes() {
- var _self = this;
- request.get(`/bis/insp/rel/org/insp/type/getInspTypeByOrgId/${this.orgId}`)
- .then(res => {
- if (res.success) {
- _self.dcTypeList = res.data;
- }
- })
- },
- closeDialog(){
- this.$emit('closeDialogMonth')
- },
- objFormat(row, column, cellValue, index){
- var name = "";
- this.dcTypeList.forEach((item)=>{
- if(parseInt(item.inspType)==row.OBJTYPE){
- name = item.inspName;
- }
- })
- return name;
- },
- formatDate(row, column, cellValue, index){
- var dateF = row[column.property];
- if(dateF){
- var date = new Date(dateF);
- return date.getFullYear()+"-"+((date.getMonth()+1)>9?(date.getMonth()+1):'0'+(date.getMonth()+1))+"-"+date.getDate();
- }
- return "";
- },
- async exportExcel() {
- this.searchForm.sttm = "";
- this.searchForm.entm = "";
- this.searchForm.persId = this.persId;
- this.searchForm.objTypes = this.objTypes.join(",");
- if(this.year && this.year.length>0){
- this.searchForm.sttm = this.year[0];
- this.searchForm.entm = this.year[1];
- }
- let url = "/pdcApi/bis/insp/mtprggd/export";
- let type = "POST";
- let exportName = "月计划统筹.xls"
- let result = await exportModel(type, url, exportName,JSON.stringify(this.searchForm));
- },
- deleteData(id){
- var _self = this;
- this.$confirm('确定删除该条数据吗, 是否继续?', '提示', {
- confirmButtonText: '确定',
- cancelButtonText: '取消',
- type: 'warning'
- }).then(() => {
- request.post('/bis/insp/mtprggd/delete/'+id).then(res=>{
- if(res.success){
- _self.initTableData();
- }else{
- _self.$message.warning(res.message);
- }
- })
- }).catch(() => {
- this.$message({
- type: 'info',
- message: '已取消删除'
- });
- });
- },
- edit(row){
- var obj = JSON.stringify(row);
- this.addDialogVisible = true;
- this.addForm = JSON.parse(obj);
- this.ym = this.addForm.year+"-"+this.addForm.mnth;
- this.dialogT = "编辑";
- },
- addSubmit(){
- if(!this.addForm.idx){
- this.$message.warning("请输入计划编号");
- return;
- }
- if(!this.addForm.unitName){
- this.$message.warning("请输入填报处室");
- return;
- }
- if(!this.ym){
- this.$message.warning("请选择年月");
- return;
- }
- if(!this.addForm.pname){
- this.$message.warning("请输入监督事项名称");
- return;
- }
- if(!this.addForm.ptype){
- this.$message.warning("请选择检查形式");
- return;
- }
- if(!this.addForm.tm){
- this.$message.warning("请选择开展时间");
- return;
- }
- if(!this.addForm.prjSize){
- this.$message.warning("请输入工程数量");
- return;
- }
- if(!this.addForm.depSize){
- this.$message.warning("请输入业务主体单位数量");
- return;
- }
- if(!this.addForm.chkSize){
- this.$message.warning("请输入检查组次");
- return;
- }
- if(!this.addForm.leadSize){
- this.$message.warning("请输入有厅领导带队的次数");
- return;
- }
- if(!this.addForm.chkDaySize){
- this.$message.warning("请输入监督检查工日");
- return;
- }
- if(!this.addForm.feedBackSize){
- this.$message.warning("请输入书面反馈意见份数");
- return;
- }
- if(!this.addForm.pblmSize){
- this.$message.warning("请输入发现问题数量");
- return;
- }
- if(!this.addForm.mendSize){
- this.$message.warning("请输入整改问题数量");
- return;
- }
- if(!this.addForm.mendCmpSize){
- this.$message.warning("请输入本月完成整改问题数量");
- return;
- }
- if(!this.addForm.mendCmpTatSize){
- this.$message.warning("请输入累计完成整改问题数量");
- return;
- }
- if(!this.addForm.mendCmpRatio){
- this.$message.warning("请输入问题累计整改率");
- return;
- }
- if(!this.addForm.accuntDep){
- this.$message.warning("请输入被追责单位/主体");
- return;
- }
- if(!this.addForm.accuntText){
- this.$message.warning("请输入追责事由");
- return;
- }
- if(!this.addForm.acuntTm){
- this.$message.warning("请选择追责时间");
- return;
- }
- if(!this.addForm.accuntNote){
- this.$message.warning("请输入追责情况");
- return;
- }
- this.addForm.chkYearId = this.rowData.id;
- this.ym = this.formatDate({ym:this.ym},{property:"ym"},null,null)
- this.addForm.year = this.ym.split("-")[0];
- this.addForm.mnth = this.ym.split("-")[1];
- var _self = this;
- request.post('/bis/insp/mtprggd/',this.addForm).then(res=>{
- if(res.success){
- _self.$message.success("保存成功");
- _self.addDialogVisible = false;
- _self.addForm = {};
- _self.ym = "";
- _self.initTableData();
- }else{
- _self.$message.warning(res.message);
- }
- })
- },
- selectOrgChange(data){
- this.addForm.unitName = data.name;
- },
- clearRecv(){
- this.addForm.unitName = "";
- },
- closeAddDialog(){
- this.addDialogVisible = false;
- },
- chkMul(){
- this.curList = [];
- if(this.mulSelectionSend && this.mulSelectionSend.length>0){
- this.loading = true;
- for(var i = 0;i<this.mulSelectionSend.length;i++){
- this.curList.push(this.mulSelectionSend[i].ID);
- }
- this.isOne = true;
- this.initTableData();
- this.loading = false;
- }else{
- this.$message.warning("请选择数据");
- }
- },
- initTableData(){
- this.searchForm.sttm = "";
- this.searchForm.entm = "";
- this.searchForm.persId = this.persId;
- this.searchForm.objTypes = this.objTypes.join(",");
- if(this.year && this.year.length>0){
- this.searchForm.sttm = this.year[0];
- this.searchForm.entm = this.year[1];
- }
- this.loading = true;
- var _self = this;
- request.post('/bis/insp/mtprggd/getMonthRefrom',this.searchForm).then(res=>{
- if(res.success){
- var list = res.data;
- if(_self.isOne){
- for(var i = 0;i<list.length;i++){
- if(_self.mulSelectionSend && _self.mulSelectionSend.length>0){
- if(_self.curList.indexOf(list[i].ID)>-1){
- var flag = false;
- for(var j = 0;j<_self.mulSelectionSend.length;j++){
- if((_self.isRe(list[i],_self.mulSelectionSend[j]) || _self.isRe(_self.mulSelectionSend[j],list[i])) &&
- list[i].ID!=_self.mulSelectionSend[j].ID && list[i].STTM && list[i].ENTM && _self.mulSelectionSend[j].STTM && _self.mulSelectionSend[j].ENTM &&
- ((list[i].STTM<=_self.mulSelectionSend[j].STTM && list[i].ENTM>=_self.mulSelectionSend[j].ENTM) || (list[i].STTM>=_self.mulSelectionSend[j].STTM && list[i].ENTM<=_self.mulSelectionSend[j].ENTM)
- || (list[i].STTM<=_self.mulSelectionSend[j].STTM && _self.mulSelectionSend[j].STTM<=list[i].ENTM)
- || (list[i].STTM<=_self.mulSelectionSend[j].ENTM && _self.mulSelectionSend[j].ENTM<=list[i].ENTM)
- || (list[i].STTM>=_self.mulSelectionSend[j].STTM && _self.mulSelectionSend[j].ENTM>=list[i].STTM)
- || (list[i].ENTM>=_self.mulSelectionSend[j].STTM && _self.mulSelectionSend[j].ENTM>=list[i].ENTM))){
- flag = true;
- }
- }
- if(flag){
- list[i].isR = true
- }else{
- list[i].isR = false
- }
- }
- }else{
- var flag = false;
- for(var j = 0;j<list.length;j++){
- if((this.isRe(list[i],list[j]) || this.isRe(list[j],list[i])) && list[i].ID!=list[j].ID &&
- list[i].STTM && list[i].ENTM && list[j].STTM && list[j].ENTM &&
- ((list[i].STTM<=list[j].STTM && list[i].ENTM>=list[j].ENTM) || (list[i].STTM>=list[j].STTM && list[i].ENTM<=list[j].ENTM)
- || (list[i].STTM<=list[j].STTM && list[j].STTM<=list[i].ENTM)
- || (list[i].STTM<=list[j].ENTM && list[j].ENTM<=list[i].ENTM)
- || (list[i].STTM>=list[j].STTM && list[j].ENTM>=list[i].STTM)
- || (list[i].ENTM>=list[j].STTM && list[j].ENTM>=list[i].ENTM))){
- flag = true;
- }
- }
- if(flag){
- list[i].isR = true
- }else{
- list[i].isR = false
- }
- }
- }
- }
- this.tableData = list;
- _self.loading = false;
- }else{
- _self.$message.warning(res.message)
- }
- })
- },
- handleCurrentChange(val){
- this.pageNum = val;
- this.initTableData();
- },
- searchBtn(){
- this.isOne = false;
- this.initTableData();
- },
- oneDel(){
- this.isOne = true;
- this.initTableData();
- },
- addBtn(){
- this.addForm = {};
- this.addDialogVisible = true;
- this.dialogT = "添加"
- }
- }
- }
- </script>
- <style lang="scss" scoped>
- .title_monthReport /deep/ .el-input__inner{
- border:0px;
- font-size: 20px !important;
- color:black;
- }
- .monthReport{
- width: 100%;
- height:100%;
- margin: 0;
- padding: 0;
- }
- .box-card{
- width: calc(100% - 60px);
- height:calc(100% - 20px);
- margin: 0 auto;
- margin-top: 10px;
- }
- .title_monthReport{
- text-align: center;
- padding: 10px;
- }
- .note_monthReport{
- width: 100%;
- background-color: rgba(255, 251, 230, 1);
- box-sizing: border-box;
- border-width: 1px;
- border-style: solid;
- border-color: rgba(255, 229, 143, 1);
- color: rgba(0, 0, 0, 0.447058823529412);
- font-size: 14px;
- padding: 10px;
- }
- .note_monthReport p:first-child{
- font-size: 16px !important;
- }
- .monthReport{
- .demo-form-inline{
- .el-form-item{
- margin-bottom: 5px;
- margin-top: 8px;
- }
- }
- }
- </style>
|