| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193 |
- <template>
- <el-container class="corrective_feedback">
- <el-main>
- <el-card class="box-card" :style="{'height': cardHeight + 'px','overflow-y':'auto'}">
- <!--20191226bytanghy-->
- <el-row :gutter="20" type="flex" justify="start" class="notice_title">
- <el-col :span="16">
- <el-form :inline="true" size="mini" class="demo-form-inline" label-width="80px">
- <el-form-item label="年度">
- <el-select
- v-model="addForm.year"
- clearable
- collapse-tags>
- <el-option
- v-for="item in yearList"
- :key="item.id"
- :label="item.year"
- :value="item.year">
- </el-option>
- </el-select>
- </el-form-item>
- <!--<el-form-item label="接收单位" prop="rectOrgId">-->
- <!--<!–<el-select v-model="addForm.rectOrgId" placeholder="请选择接收单位">–>-->
- <!--<!–<el-option–>-->
- <!--<!–v-for="item in pidList"–>-->
- <!--<!–:key="item.orgId"–>-->
- <!--<!–:label="item.orgNm"–>-->
- <!--<!–:value="item.orgId">–>-->
- <!--<!–</el-option>–>-->
- <!--<!–</el-select>–>-->
- <!--<!–<el-form-item label="行政区域" required>–>-->
- <!--<div>-->
- <!--<el-select v-model="cityName" placeholder="选择市" @change="cityChange" clearable filterable>-->
- <!--<el-option-->
- <!--v-for="item in cityList"-->
- <!--:key="item.orgId"-->
- <!--:label="item.orgNm"-->
- <!--:value="item.orgId">-->
- <!--</el-option>-->
- <!--</el-select>-->
- <!--<el-select v-model="countryName" placeholder="选择县" @change="countryChange" filterable>-->
- <!--<el-option-->
- <!--v-for="item in countryList"-->
- <!--:key="item.orgId"-->
- <!--:label="item.orgNm"-->
- <!--:value="item.orgId">-->
- <!--</el-option>-->
- <!--</el-select>-->
- <!--</div>-->
- <!--<!–</el-form-item>–>-->
- <!--</el-form-item>-->
- <el-form-item label="督查类型">
- <el-select
- v-model="addForm.sndType "
- clearable
- collapse-tags>
- <el-option
- v-for="item in typesList"
- :key="item.code"
- :label="item.name"
- :value="item.code">
- </el-option>
- </el-select>
- </el-form-item>
- <el-form-item label="下发状态">
- <el-select
- v-model="addForm.state"
- clearable
- collapse-tags>
- <!--<el-option label="未下发" value="0"></el-option>-->
- <el-option label="已下发" value="1"></el-option>
- <el-option label="已反馈" value="2"></el-option>
- <el-option label="审核通过" value="3"></el-option>
- <el-option label="驳回" value="4"></el-option>
- </el-select>
- </el-form-item>
- </el-form>
- </el-col>
- <el-col :span="8" style="text-align: end;">
- <el-button type="primary" @click="searchNotice">查询</el-button>
- </el-col>
- </el-row>
- <div>
- <el-table
- border
- ref="multipleTable"
- :height="tableHeight"
- :data="tableData"
- tooltip-effect="dark"
- style="width: 100%"
- v-loading="loading"
- >
- <el-table-column align="center" type="index" label="序号" min-width="25">
- <template slot-scope="scope">{{ (pageNum - 1) * pageSize + (scope.$index + 1) }}</template>
- </el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="150"
- prop="sndTitle"
- label="通知标题"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="150"
- prop="sndType"
- label="督查类型"
- show-overflow-tooltip
- >
- <template slot-scope="scope">
- {{typesListFy(scope.row.sndType)}}
- </template>
- </el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="200"
- prop="sndNub"
- label="文号"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="100"
- prop="sndOrgName"
- label="下发单位"
- show-overflow-tooltip
- ></el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="100"
- prop="crrtTm"
- label="整改截止时间"
- show-overflow-tooltip
- >
- <template slot-scope="scope">
- <span>{{formatDate(scope.row.crrtTm)}}</span>
- </template>
- </el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="100"
- prop="note"
- label="备注"
- ></el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="160"
- prop="fileName"
- label="附件"
- show-overflow-tooltip
- >
- <template slot-scope="scope">
- <el-button type="text" size="mini" @click="previewAttachment(scope.row)">{{scope.row.fileName}}</el-button>
- </template>
- </el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="100"
- prop="pjctSize"
- label="工程"
- ></el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="100"
- prop="pblmSize"
- label="问题数"
- ></el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="100"
- prop="rectTm"
- label="下发时间"
- show-overflow-tooltip
- >
- <template slot-scope="scope">
- <span v-if="scope.row.rectTm">{{formatDate(scope.row.rectTm)}}</span>
- </template>
- </el-table-column>
- <el-table-column
- header-align="center"
- align="center"
- min-width="100"
- prop="state"
- label="状态"
- show-overflow-tooltip
- >
- <template slot-scope="scope">
- <p class="state_style">
- <span v-if="scope.row.state == 0" @click="stateClick(scope.row)">未下发</span>
- <span v-if="scope.row.state == 1" @click="stateClick(scope.row)">已下发</span>
- <span v-if="scope.row.state == 2" @click="stateClick(scope.row)">已反馈</span>
- <span v-if="scope.row.state == 3" @click="stateClick(scope.row)">审核通过</span>
- <span v-if="scope.row.state == 4" @click="stateClick(scope.row)">驳回</span>
- </p>
- </template>
- </el-table-column>
- <el-table-column
- align="center"
- min-width="300"
- label="操作"
- fixed="right"
- >
- <template slot-scope="scope">
- <!--// 状态 0 未下发 1 已下发 2 已反馈 3审核通过 4 驳回-->
- <span v-if="scope.row.state == '1' || scope.row.state == '4'">
- <el-button type="success" size="mini" @click.stop="lookOver(scope.row)">查看</el-button>
- <el-button type="primary" size="mini" @click.stop="submitRow(scope.row)">提交</el-button>
- </span>
- <span v-else>
- <el-button type="success" size="mini" @click.stop="lookOver(scope.row)">查看</el-button>
- <el-button type="primary" size="mini" @click.stop="addPblmRow(scope.row)">问题分发</el-button>
- </span>
- </template>
- </el-table-column>
- </el-table>
- <!--<el-pagination-->
- <!--style="margin: 10px auto"-->
- <!--background-->
- <!--:pager-count="5"-->
- <!--:current-page="pageNum"-->
- <!--:page-size="pageSize"-->
- <!--:page-sizes="[10, 20, 30, 40, 50, 100]"-->
- <!--layout="sizes, total, prev, pager, next"-->
- <!--:total="tableData.length"-->
- <!--@current-change="handleCurrentChange"-->
- <!--@size-change="handleSizeChange"-->
- <!--></el-pagination>-->
- </div>
- </el-card>
- <el-dialog :title="titleText + '整改通知'" :visible.sync="dialogFormEditorVisible" :close-on-click-modal="false" width="50%" @close="closeDialog">
- <el-form :model="tongZhiForm" ref="tongZhiForm" :label-width="formLabelWidth">
- <el-row :gutter="20" type="flex" justify="start">
- <el-col :span="12">
- <el-form-item label="督查类型">
- <el-select v-model="tongZhiForm.sndType" placeholder="请选择督查类型"
- :disabled="zgButton" clearable>
- <el-option
- v-for="item in typesList"
- :key="item.code"
- :label="item.name"
- :value="item.code">
- </el-option>
- </el-select>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20" type="flex" justify="start">
- <el-col :span="12">
- <el-form-item label="通知标题">
- <el-input v-model="tongZhiForm.sndTitle" placeholder="请输入通知标题"
- :disabled="zgButton"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="12">
- <el-form-item label="整改截止时间" prop="planYr">
- <el-date-picker
- v-model="tongZhiForm.crrtTm"
- type="date"
- value-format="yyyy-MM-dd"
- placeholder="选择整改截止时间" :disabled="zgButton">
- </el-date-picker>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20" type="flex" justify="start">
- <el-col :span="12">
- <el-form-item label="文号">
- <el-input v-model="tongZhiForm.sndNub" placeholder="请输入文号"
- :disabled="zgButton"></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="12">
- <el-form-item label="接收单位">
- <el-select
- v-model="tongZhiForm.rectOrgName" placeholder="请选择接收单位"
- :disabled="zgButton">
- <el-option
- v-for="item in pidList"
- :key="item.orgId"
- :label="item.orgNm"
- :value="item.orgId">
- </el-option>
- </el-select>
- </el-form-item>
- </el-col>
- </el-row>
- <el-form-item label="备注">
- <el-input type="textarea" rows="6" v-model="tongZhiForm.note" clearable
- placeholder="请输入备注" :disabled="zgButton"></el-input>
- </el-form-item>
- <el-form-item label="附件">
- <div v-show="ifFileList">
- <upload
- ref="uploadFile"
- :url="`/pdcApi/file/insert?bizId=`"
- accept=".doc,.docx,.pdf"
- @uploadOver="removeNewSupervision"
- ></upload>
- </div>
- <div v-show="!ifFileList">
- <el-table
- :data="fileListPiCi"
- style="width: 100%">
- <el-table-column
- prop="name"
- label="附件名称"
- min-width="200">
- </el-table-column>
- <el-table-column
- label="操作"
- min-width="150">
- <template slot-scope="scope">
- <el-button @click="deleteFiles(scope.row)" type="text" size="small" :disabled="zgButton">删除
- </el-button>
- <el-button type="text" size="small" @click="toPreview(scope.row)">预览</el-button>
- </template>
- </el-table-column>
- </el-table>
- </div>
- </el-form-item>
- </el-form>
- <div v-if="titleText =='查看'">
- <el-divider></el-divider>
- <el-row :gutter="20" type="flex" style="margin-bottom: 10px;">
- <el-col :span="20">
- <el-form :inline="true" size="mini" class="demo-form-inline">
- <el-form-item label="工程">
- <el-input v-model="editorForm.name" clearable placeholder="请输入工程" style="width: 5vw"></el-input>
- </el-form-item>
- <el-form-item label="问题类别">
- <el-input v-model="editorForm.inspPblmType" clearable placeholder="请输入问题类别" style="width: 5vw"></el-input>
- </el-form-item>
- <el-form-item label="严重程度">
- <el-select v-model="editorForm.inspPblmCate" clearable placeholder="请选择" style="width: 5vw">
- <el-option
- v-for="item in supervisionState"
- :key="item.value"
- :label="item.label"
- :value="item.value"
- ></el-option>
- </el-select>
- </el-form-item>
- <el-form-item label="整改情况">
- <el-select v-model="editorForm.rectConc" clearable placeholder="请选择" style="width: 5vw">
- <el-option
- v-for="item in rectConc"
- :key="item.value"
- :label="item.label"
- :value="item.value"
- ></el-option>
- </el-select>
- </el-form-item>
- <!--<el-form-item label="是否典型">-->
- <!--<el-select v-model="editorForm.state" clearable style="width: 8vw">-->
- <!--<el-option label="未下发" value="0"></el-option>-->
- <!--<el-option label="已下发" value="1"></el-option>-->
- <!--<el-option label="已反馈" value="2"></el-option>-->
- <!--</el-select>-->
- <!--</el-form-item>-->
- </el-form>
- </el-col>
- <el-col :span="2" :offset=2 style="text-align: end;">
- <el-button @click="searchClick" type="success">查询</el-button>
- </el-col>
- </el-row>
- <div>
- <el-table
- :data="PblmList"
- :height="tableHeight1"
- style="width: 100%"
- border
- tooltip-effect="dark">
- <el-table-column
- prop="name"
- label="工程名称"
- min-width="50"
- show-overflow-tooltip>
- </el-table-column>
- <el-table-column
- prop="inspPblmType"
- label="问题类别"
- min-width="50"
- show-overflow-tooltip>
- </el-table-column>
- <el-table-column
- prop="inspPblmDesc"
- label="问题描述"
- min-width="50"
- show-overflow-tooltip>
- </el-table-column>
- <el-table-column
- label="严重程度"
- min-width="50">
- <template slot-scope="scope">
- <p v-if="scope.row.inspPblmCate == 0"><span class="inspPblmCate" style="background: #27C19F;">一般</span></p>
- <p v-if="scope.row.inspPblmCate == 1"><span class="inspPblmCate" style="background: #E6A23C;" >较重</span></p>
- <p v-if="scope.row.inspPblmCate == 2"><span class="inspPblmCate" style="background: #F56C6C;" >严重</span></p>
- <p v-if="scope.row.inspPblmCate == 3"><span class="inspPblmCate" style="background: #795548;">特别严重</span></p>
- </template>
- </el-table-column>
- <!--<el-table-column-->
- <!--prop="pblmSize"-->
- <!--label="是否典型"-->
- <!--min-width="50">-->
- <!--</el-table-column>-->
- <el-table-column
- prop="state"
- label="上报时间"
- min-width="50"
- show-overflow-tooltip>
- <template slot-scope="scope">
- <span v-if="scope.row.inspPblmTm">{{formatDate(scope.row.inspPblmTm)}}</span>
- </template>
- </el-table-column>
- <el-table-column
- prop="rectConc"
- label="整改情况"
- min-width="50"
- show-overflow-tooltip>
- <template slot-scope="scope">
- <span v-if="scope.row.rectConc == '1'">未整改</span>
- <span v-if="scope.row.rectConc == '2'">整改中</span>
- <span v-if="scope.row.rectConc == '3'">已整改</span>
- <span v-if="scope.row.rectConc == '4'">不具备整改条件</span>
- </template>
- </el-table-column>
- <el-table-column
- label="操作"
- min-width="100">
- <template slot-scope="scope">
- <el-button type="text" size="small" @click="toViewRow(scope.row)">查看</el-button>
- </template>
- </el-table-column>
- </el-table>
- </div>
- </div>
- </el-dialog>
- </el-main>
- <addPblm v-if="addPblmDialog" @closeDialog="closeDialogAddPblm" :RowId="RowId" :supervisionState="supervisionState" :objType="objType" :rectId="rectId" ifShiJi="1"></addPblm>
- <!-- 详情弹框 -->
- <el-dialog
- class="outerDialog custom_dialog"
- title="问题详情"
- width="60%"
- :visible.sync="supervisionDetailsVisible"
- v-if="supervisionDetailsVisible"
- >
- <el-tabs v-model="activeName" type="card">
- <el-tab-pane label="问题详情" name="first">
- <supervisionDetailsXiangQing :problemId="rowPblId" :objType="objType"></supervisionDetailsXiangQing>
- </el-tab-pane>
- <el-tab-pane label="整改反馈" name="second">
- <supervision-details :listId="rowPblId" :rowId="rowId" :objType="objType"></supervision-details>
- </el-tab-pane>
- </el-tabs>
- <!--<supervision-details ref="xianqing" :problemId="currentProblemId" :objType="objType"></supervision-details>-->
- <span slot="footer">
- <el-button style="margin-top:5px;" @click="supervisionDetailsVisible = false">返回</el-button>
- </span>
- </el-dialog>
- <!--通知状态步骤条-->
- <el-dialog
- title="通知状态"
- width="30%"
- :visible.sync="stateVisible"
- :close-on-click-modal="false">
- <steps :stateLogList="stateLogList"></steps>
- <span slot="footer">
- <el-button style="margin-top:5px;" @click="stateVisible = false">返回</el-button>
- </span>
- </el-dialog>
- </el-container>
- </template>
- <script>
- import request from '@util/gw_ajax_request'
- import {dateFormat} from '@util/gw_date';
- import {hostUrl} from '@util/global_variable.js'
- import addPblm from './addPblm'
- import steps from './steps'
- export default {
- name: "correctiveFeedback",
- props: [],
- data() {
- return {
- cardHeight: window.innerHeight - 120,
- currentPage: 1,
- tableData: [],
- tableHeight: window.innerHeight - 300,
- tableHeight1: window.innerHeight * .2,
- loading: false,
- pageSize: 20,
- pageNum: 1,
- dialogFaTitle: "",
- formLabelWidth: '120px',
- tongZhiForm:{
- "sndType": "",//发文类型 '1','小型水库', '2','人饮工程', '3','水毁工程', '4','工程建设', '5','地下水', '7','运行管理', '6','水闸', '9','特定飞检', '10','其他填报', '11','淤地坝', '12','取水口','13','重要水源地', '14','分水及管控', '15','节水管理与评价', '16','用水单位抽查'
- "sndTitle": "",//通知标题
- "sndNub": "", //通知文号
- "rectOrgId": "",//接收单位ID
- "rectOrgName": "",//接收单位名称
- "crrtTm": "",//整改截止时间
- "note": "",//备注
- "persId": "" //插入人ID
- },
- curStatus: '编辑',
- zgButton: false,
- zgfkDialog: false,
- ifMinistriesAgencies: false,
- groupId: '',
- addvcd: '',
- treeDataLists: [],
- defaultExpanded: [],
- defaultProps: {
- children: 'children',
- label: 'pnm'
- },
- distributeState: false, //false 未下发 true 已下发
- dialogFormVisible: false, //上传文件弹窗
- dialogFormEditorVisible: false,
- gwComFileList: [],
- PblmList:[],
- year: '',
- province: '',
- addForm: {
- "state":"",// 状态 0 未下发 1 已下发 2 已反馈 3审核通过 4 驳回 ,
- "rectOrgId": localStorage.getItem('currentOrgId'),// 单位 必须
- "year":"",//年度
- "sndType": ""
- },
- editorForm: {
- "rectId":null,
- "name": null,
- "inspPblmType": null,//问题类别
- "inspPblmCate": null,//严重程度
- "rectConc": null//整改状态
- },
- yearList: [],
- pidList: [],
- sfType: [
- {
- label: '是',
- value: "1"
- },
- {
- label: '否',
- value: "2"
- }
- ],
- titleText: '新建',
- header: {
- 'persId': localStorage.getItem('userid'),
- 'accessToken': localStorage.getItem('accessToken')
- },
- fileList: [],
- provincesList: [],
- url: null,
- yiShengyiDanRowId: null,
- yearBatchSelect: false,
- ifFileList: true,
- fileListPiCi:[],
- PcData: null,
- typesList: [],
- tongZhiRowId: null,
- supervisionState: [
- {
- value: "0",
- label: "一般"
- },
- {
- value: "1",
- label: "较重"
- },
- {
- value: "2",
- label: "严重"
- },
- {
- value: "3",
- label: "特别严重"
- }
- ],
- supervision: [
- {
- value: "1",
- label: "是"
- },
- {
- value: "0",
- label: "否"
- }
- ],
- rectConc:[
- {
- value: "1",
- label: "未整改"
- },
- {
- value: "2",
- label: "整改中"
- },
- {
- value: "3",
- label: "已整改"
- },
- {
- value: "4",
- label: "不具备整改条件"
- }
- ],
- addPblmDialog: false,
- RowId: null,
- rectId: null,
- objType: null,
- supervisionDetailsVisible: false,
- activeName: 'first',
- rowId: null,
- rowPblId: null,
- stateVisible: false,
- stateLogList: [],
- provList: [],
- cityList: [],
- countryList: [],
- provName: '',
- cityName: '',
- countryName: '',
- curSelectItem: 2
- }
- },
- components: {
- upload: resolve => {
- require(["@widget/uploadFile.vue"], resolve);
- },
- addPblm,
- //详情页
- supervisionDetails: resolve => {
- require(["./supervisionDetails_zgwt.vue"], resolve);
- },
- supervisionDetailsXiangQing: resolve => {
- require(["./supervisionDetails.vue"], resolve);
- },
- steps
- },
- computed: {
- persId() {
- return localStorage.getItem("userid")
- ? localStorage.getItem("userid")
- : "1098101939614724096";
- }
- },
- mounted() {
- this.$nextTick(() => {
- this.getYear();
- this.getByPid();
- this.getTypes();
- this.getNoticeList();
- })
- },
- methods: {
- getYear(){
- request.get(`/tac/pblm/rect/getYear/${this.persId}`)
- .then(res =>{
- if(res.success){
- this.yearList = res.data;
- }
- })
- .catch(err =>{
- console.log(err);
- })
- },
- getByPid(){
- let val = localStorage.getItem("currentOrgId");
- request.get(`/dc/bis/insp/org/getByPid?pid=${val}`)
- .then(res =>{
- if(res.success){
- if(this.curSelectItem == 2){
- this.cityList = res.data
- }else{
- this.countryList = res.data
- }
- this.pidList = res.data;
- }
- })
- .catch(err =>{
- console.log(err);
- })
- },
- getTypes(){
- request.post(`/att/insp/type/getTypes`,{})
- .then(res =>{
- if(res.success){
- this.typesList = res.data;
- }
- })
- },
- //-----------------------------------
- formatDate(timestamp) {
- return timestamp ? dateFormat(timestamp, 'yyyy-MM-dd') : "";
- },
- changeYear(item) {
- let _self = this;
- request.get(`tac/pblm/rect/getBatchByYearPersId/${_self.persId}/${item}`)
- .then(res =>{
- _self.pcList = res.data;
- })
- .catch(err =>{
- console.log(err);
- })
- if (item == "" || item == undefined) {
- _self.pcList = null;
- _self.addForm.batch = "";
- }
- },
- lookOver(row) {
- this.titleText = "查看";
- this.ifFileList = false;
- this.RowId = row.id;
- this.objType = row.sndType;
- this.getPblmList();
- request.get(`/bis/insp/rect/${row.id}`)
- .then(res => {
- if (res.success) {
- this.tongZhiForm = res.data;
- this.tongZhiForm.crrtTm = dateFormat(res.data.crrtTm, "yyyy-MM-dd");
- this.dialogFormEditorVisible = true;
- if(res.data.fileName && res.data.filePath && res.data.id){
- this.ifFileList = false;
- this.fileListPiCi = [];
- this.fileListPiCi.push(
- Object.assign({},
- {'name':res.data.fileName},
- {'url':res.data.filePath},
- {'id':res.data.id},
- {'fileId':res.data.fileId}
- )
- );
- }
- this.zgButton = true;
- } else {
- this.$message.warning(res.message);
- }
- })
- .catch(err => {
- console.log(err);
- })
- },
- uploadAfter(data){
- let obj = {
- "id": this.tongZhiRowId,//数据ID
- "fileId": data.id,//附件ID
- "fileName": data.fileName,//附件名称
- "filePath": data.filePath
- }
- request.post(`/bis/insp/rect/update`,obj)
- .then(res =>{
- if(res.success){
- this.dialogFormVisible = false;
- this.$message.success('上传成功');
- this.getNoticeList();
- }
- })
- .catch(err =>{
- })
- },
- //获取当前督查对象下问题List
- getPblmList() {
- let obj = {
- "rectId":this.RowId,//通知ID 必须
- "name":this.editorForm.name,//工程名称 非必传
- "inspPblmCate":this.editorForm.inspPblmCate,
- "inspPblmType": this.editorForm.inspPblmType
- }
- request.post(`/bis/insp/rect/pblm/findList`, obj)
- .then(res => {
- if (res.success) {
- this.$nextTick(() => {
- this.PblmList = res.data;
- this.provincesList = res.data;
- })
- } else {
- this.$message.warning(res.message);
- }
- })
- .catch(err => {
- console.log(err);
- })
- },
- addZgTz() {
- this.titleText = '新建';
- this.zgButton = false;
- this.yearBatchSelect = false;
- this.dialogFormEditorVisible = true;
- this.fileListPiCi = [];
- this.ifFileList = true;
- for (let obj in this.editorForm) {
- this.editorForm[obj] = '';
- }
- for (let obj in this.tongZhiForm) {
- this.tongZhiForm[obj] = '';
- }
- },
- //提交
- submitRow(row) {
- let obj = {
- "id": row.id,
- "rectTm": row.rectTm ? this.formatDate(row.rectTm) : '',//反馈时间 一般指前操作时间
- "rectNub": row.sndNub, //反馈文号
- "rectPersId": this.persId,//反馈人员ID
- "state":"2"//状态 0 未下发 1 已下发 2 已反馈 3审核通过 4 驳回
- };
- this.$confirm('(有问题未填写反馈)确定提交吗?', '提示', {
- confirmButtonText: '确定',
- cancelButtonText: '取消',
- type: 'warning'
- }).then(() => {
- request.post(`/bis/insp/rect/update`,obj)
- .then(res => {
- if (res.success) {
- this.$message.success("操作成功");
- this.getNoticeList();
- } else {
- this.$message.warning(res.message);
- }
- })
- .catch(err => {
- console.log(err);
- })
- }).catch(() => {
- this.$message({
- type: 'info',
- message: '已取消'
- });
- });
- },
- //问题查看
- toViewRow(row){
- this.rowId = row.id;
- this.rowPblId = row.pblmId;
- this.currentProblemId = row.pblmId;
- this.supervisionDetailsVisible = true;
- },
- //添加问题
- addPblmRow(row){
- this.RowId = row.id;
- this.rectId = row.rectOrgId;
- this.objType = row.sndType;
- this.addPblmDialog = true;
- },
- deleteRow(row) {
- this.$confirm('确定要删除该数据, 是否继续?', '提示', {
- confirmButtonText: '确定',
- cancelButtonText: '取消',
- type: 'warning'
- }).then(() => {
- request.post(`/bis/insp/rect/delete/${row.id}`)
- .then(res => {
- if (res.success) {
- this.$message.success("删除成功");
- this.getNoticeList();
- } else {
- this.$message.warning(res.message);
- }
- })
- .catch(err => {
- console.log(err);
- })
- }).catch(() => {
- this.$message({
- type: 'info',
- message: '已取消删除'
- });
- });
- },
- xiaFaClick(row) {
- this.$confirm('下发后通知内容无法更改?', '提示', {
- confirmButtonText: '确定',
- cancelButtonText: '取消',
- type: 'warning'
- }).then(() => {
- let obj = {
- "id": row.id,
- "persId": this.persId,
- "state": "1"
- }
- request.post(`/bis/insp/rect/update`, obj)
- .then(res => {
- if (res.success) {
- this.$message.success("下发成功");
- this.getNoticeList();
- } else {
- this.$message.warning(res.message);
- }
- })
- }).catch(() => {
- this.$message({
- type: 'info',
- message: '已取消下发'
- });
- });
- },
- //通知List
- getNoticeList() {
- this.loading = true;
- let obj = Object.assign({},this.addForm);
- let str = this.addForm.state;
- obj.state = [...str].length === 1 ? str : "1,2,3,4";
- request.post(`/bis/insp/rect/province/findList`, obj)
- .then(res => {
- if (res.success) {
- this.loading = false;
- this.tableData = res.data;
- }
- })
- .catch(err => {
- console.log(err);
- })
- },
- // 通知保存
- tongZhiSave(formName) {
- if (this.titleText == '新建') {
- this.$refs[formName].validate((valid) => {
- if (valid) {
- let obj = this.tongZhiForm;
- obj.persId = localStorage.getItem("userid");
- request.post('/bis/insp/rect/add', obj).then((res) => {
- if (res.success) {
- this.tongZhiRowId = res.data.id;
- this.$nextTick(function () {
- if (this.$refs.uploadFile.submitUpload(res.data.id)) {
- this.removeNewSupervision();
- this.$message.success('新建通知成功');
- }
- })
- } else {
- this.$message.warning(res.message);
- }
- })
- } else {
- console.log('error submit!!');
- return false;
- }
- });
- } else if (this.titleText == '编辑') {
- this.$refs[formName].validate((valid) => {
- if (valid) {
- let obj = this.tongZhiForm;
- obj.persId = localStorage.getItem("userid");
- request.post('/bis/insp/rect/update', obj).then((res) => {
- if (res.success) {
- this.tongZhiRowId = res.data.id;
- this.$nextTick(() => {
- if (this.$refs.uploadFile.submitUpload(res.data.id)) {
- this.removeNewSupervision();
- this.$message.success('编辑通知成功');
- }
- })
- } else {
- this.$message.warning(res.message);
- }
- })
- } else {
- console.log('error submit!!');
- return false;
- }
- });
- }
- },
- searchClick() {
- this.$nextTick(() => {
- this.getPblmList();
- })
- },
- // dialog通知弹窗关闭
- closeDialog(){
- this.getNoticeList();
- },
- //一省一单上传
- shengRowUpload(row) {
- this.yiShengyiDanRowId = row.id;
- this.dialogFormVisible = true;
- },
- // addFileSave(){
- // this.gwComFileList = [];
- // if (this.$refs.uploadFileRow.submitUpload(this.yiShengyiDanRowId)) {
- // this.removeNewSupervision();
- // this.$message.success('保存成功');
- // this.getYiShengYiDanList();
- // }
- // },
- removeNewSupervision(arg) {
- if(arg){
- console.log(arg);
- let data = arg[arg.length - 1];
- this.uploadAfter(data);
- }
- },
- // 文件预览
- rowPreview(row){
- window.open(`${hostUrl}${row.filePath}`, "_blank");
- },
- //批次预览
- toPreview(row) {
- window.open(`${hostUrl}${row.url}`, "_blank");
- },
- //删除批次附件
- deleteFiles(row) {
- this.$confirm('确定删除该附件吗?', '提示', {
- confirmButtonText: '确定',
- cancelButtonText: '取消',
- type: 'warning'
- }).then(() => {
- request.post(`/bis/insp/rect/setFileNull/${row.fileId}`).then(res => {
- if (res.success) {
- this.fileListPiCi = [];
- this.ifFileList = true;
- this.$message.success('附件删除成功');
- }
- })
- }).catch(() => {
- })
- },
- //删除下发附件
- // deleteFile(rowId){
- // request.post(`/tac/pblm/rect/org/setFileNull/${rowId}`)
- // .then(res =>{
- // if(res.success){
- // this.$message({
- // type: 'success',
- // message: '删除成功'
- // })
- // this.getYiShengYiDanList();
- // }else{
- // this.$message.warning(res.message);
- // }
- // })
- // },
- //文件删除
- rowDelete(row){
- return this.$confirm(`确定移除 ${row.fileName}?`).then(() => {
- if(row.fileId){
- request.post(`/file/${row.fileId}`).then((res) => {
- if (res.success) {
- this.deleteFile(row.id);
- } else {
- this.$alert("删除失败!", '提示', {
- confirmButtonText: '确定',
- type: 'warning'
- })
- }
- })
- }else{
- this.$message.warning('fileId不能为空');
- }
- }).catch(() => {
- this.$message({
- type: 'info',
- message: '已取消删除'
- });
- });
- }
- ,
- //通知查询
- searchNotice(){
- this.getNoticeList();
- },
- select_handler_province() {
- this.$nextTick(() => {
- this.tongZhiForm.rectOrgName = this.$refs.selectProvince.selectedLabel;
- });
- },
- typesListFy(row){
- if(row){
- this.typesList.forEach(ele => {
- if (ele.code == row) {
- row = ele.name;
- }
- });
- return row;
- }else{
- return '';
- }
- },
- // 通知表格里附件预览
- previewAttachment(row){
- window.open(`${hostUrl}${row.filePath}`, "_blank");
- },
- closeDialogAddPblm(){
- this.addPblmDialog = false;
- },
- stateClick(row){
- if(row.bisInspRectLogList.length){
- this.stateVisible = true;
- this.stateLogList = row.bisInspRectLogList;
- }else{
- this.$message.warning('暂无通知状态信息');
- }
- },
- cityChange(val){
- if(val && val != ''){
- this.curSelectItem = 3
- this.addForm.rectOrgId = val
- this.countryName = ''
- this.getByPid(val);
- }
- },
- countryChange(val){
- if(val && val != ''){
- this.addForm.rectOrgId = val
- }
- }
- },
- watch: {
- // 'addForm': {
- // deep: true,
- // handler: function () {
- // this.getNoticeList();
- // }
- // }
- cityName(n,o){
- if(!n){
- this.cityName = "";
- this.countryName = "";
- this.addForm.rectOrgId = "";
- }
- }
- }
- }
- </script>
- <style lang="scss">
- .corrective_feedback{
- .inspPblmCate{
- padding: 2px 10px;
- color: #fff;
- -webkit-border-radius: 10px;
- -moz-border-radius: 10px;
- border-radius: 10px;
- }
- .notice_title{
- .el-input--mini .el-input__inner,.el-select-dropdown__list{
- width: 8vw;
- }
- }
- .rowClassP{
- span {
- color: #3399ff;
- margin-left: 15px;
- cursor: pointer;
- }
- span:first-child{
- cursor: default;
- margin-left: 0;
- color: rgb(51, 51, 51);
- }
- span:last-child{
- color: red;
- }
- }
- .state_style{
- span{
- color: blue;
- cursor: pointer;
- &:hover{
- border-bottom: 1px solid blue;
- }
- }
- }
- }
- </style>
|