| | |
| | | method: 'get', |
| | | }) |
| | | } |
| | | |
| | | |
| | | |
| | | export function geDepartmentUserPage(data) { |
| | | return request({ |
| | | headers: { |
| | | 'Authorization': getToken() |
| | | }, |
| | | url: process.env.BASE_API + '/department-userList', |
| | | method: 'post', |
| | | data |
| | | }) |
| | | } |
| | |
| | | }); |
| | | } |
| | | |
| | | |
| | | export function hiddenDangerRectify(data) { |
| | | return request({ |
| | | headers:{ |
| | | 'Authorization': getToken() |
| | | }, |
| | | url: process.env.BASE_API+'/hiddenDanger/rectify', |
| | | method: 'post', |
| | | data |
| | | }); |
| | | } |
| | | |
| | | export function hiddenDangerConfirm(data) { |
| | | return request({ |
| | | headers:{ |
| | |
| | | }); |
| | | } |
| | | |
| | | export function hiddenDangerAccept(data) { |
| | | return request({ |
| | | headers:{ |
| | | 'Authorization': getToken() |
| | | }, |
| | | url: process.env.BASE_API+'/hiddenDanger/accept', |
| | | method: 'post', |
| | | data |
| | | }); |
| | | } |
| | | |
| | | |
| | | export function hiddenDangerReject(data) { |
| | | return request({ |
| | | headers:{ |
| | | 'Authorization': getToken() |
| | | }, |
| | | url: process.env.BASE_API+'/hiddenDanger/reject', |
| | | method: 'post', |
| | | data |
| | | }); |
| | | } |
| | | |
| | | export function hiddenDangerReportList(data) { |
| | | return request({ |
| | |
| | | } |
| | | |
| | | |
| | | export function hiddenDangerConfirmList(data) { |
| | | export function hiddenDangerAcceptList(data) { |
| | | return request({ |
| | | headers:{ |
| | | 'Authorization': getToken() |
| | | }, |
| | | url: process.env.BASE_API+'/hiddenDanger/confirmPage', |
| | | url: process.env.BASE_API+'/hiddenDanger/acceptPage', |
| | | method: 'post', |
| | | data |
| | | }); |
| | | } |
| | | |
| | | |
| | | export function hiddenDangerRectifyList(data) { |
| | | return request({ |
| | | headers:{ |
| | | 'Authorization': getToken() |
| | | }, |
| | | url: process.env.BASE_API+'/hiddenDanger/rectifyPage', |
| | | method: 'post', |
| | | data |
| | | }); |
对比新文件 |
| | |
| | | <template> |
| | | <div class="app-container"> |
| | | <div style="margin: 15px"> |
| | | <span class="span-filter-label">单号</span> |
| | | <el-input style="width: 140px" v-model="filter.filter.code" ></el-input> |
| | | <span class="span-filter-label">隐患等级</span> |
| | | <el-select v-model="filter.filter.level" clearable @clear="clearLevel" placeholder="请选择"> |
| | | <el-option |
| | | v-for="item in levels" |
| | | :key="item.key" |
| | | :label="item.value" |
| | | :value="item.key"> |
| | | </el-option> |
| | | </el-select> |
| | | <span class="span-filter-label">整改人</span> |
| | | <el-input style="width: 160px" v-model="filter.filter.rectifierName"></el-input> |
| | | <el-button class="filter-item" style="margin-left: 10px;" type="primary" icon="el-icon-search" |
| | | @click="queryHandle"/> |
| | | </div> |
| | | <div class="table_content"> |
| | | <el-table |
| | | v-loading="listLoading" |
| | | :key="tableKey" |
| | | :data="tableData" |
| | | border |
| | | fit |
| | | highlight-current-row |
| | | style="width: 100%;" |
| | | > |
| | | <el-table-column type="index" label="序号" align="center" width="80"/> |
| | | <el-table-column label="单号" prop="code" align="center" /> |
| | | <el-table-column label="状态" prop="status" align="center" > |
| | | <template slot-scope="scope"> |
| | | <span >{{scope.row.status}}</span> |
| | | <span v-if="new Date(scope.row.rectifydeadline) < new Date() && scope.row.status !== '已完成'" class="overdue-img">逾期</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="隐患等级" prop="level" align="center" > |
| | | <template slot-scope="scope"> |
| | | <el-tag :type="scope.row.level == '紧急'?'danger':'warning'">{{scope.row.level}}</el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="上报人" prop="requestor" align="center" /> |
| | | <el-table-column label="上报时间" prop="createtime" align="center" /> |
| | | <el-table-column label="整改人" prop="rectifier" align="center" /> |
| | | <el-table-column label="整改期限" prop="rectifydeadline" align="center" > |
| | | <template slot-scope="scope"> |
| | | <span v-bind:class="{'overdue':new Date(scope.row.rectifydeadline) < new Date() && scope.row.status !== '已完成'}">{{scope.row.rectifydeadline}} |
| | | </span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="整改时间" prop="rectifytime" align="center" /> |
| | | |
| | | |
| | | <el-table-column label="操作" align="center" width="240" class-name="small-padding fixed-width"> |
| | | <template slot-scope="scope"> |
| | | <el-button type="text" @click="viewHandle(scope.row)">查看</el-button> |
| | | <el-button type="text" @click="acceptHandle(scope.row)" v-if="scope.row.status === '整改待验收'">验收</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <br> |
| | | <el-pagination |
| | | v-show="recordTotal>0" |
| | | :current-page="filter.pageIndex" |
| | | :page-sizes="[10, 20, 30, 50]" |
| | | :page-size="filter.pageSize" |
| | | :total="recordTotal" |
| | | layout="total, sizes, prev, pager, next, jumper" |
| | | background |
| | | style="float:right;" |
| | | @size-change="handleSizeChange" |
| | | @current-change="handleCurrentChange" |
| | | /> |
| | | </div> |
| | | |
| | | <report-view ref="reportView"></report-view> |
| | | <accept-dialog ref="acceptDialog" @refresh="hiddenDangerList"></accept-dialog> |
| | | |
| | | |
| | | <div style="clear: both;"></div> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import { checkBtnPermission} from "@/utils/permission"; |
| | | import { hiddenDangerAcceptList} from '@/api/hiddenDanger'; |
| | | import reportView from "./reportView/reportView"; |
| | | import acceptDialog from "./acceptDialog/acceptDialog"; |
| | | |
| | | export default { |
| | | name: "confirm", |
| | | components: { |
| | | reportView, |
| | | acceptDialog, |
| | | }, |
| | | data() { |
| | | return { |
| | | recordTotal: 0, |
| | | tableKey: 0, |
| | | tableData:[], |
| | | listLoading: true, |
| | | levels:[ |
| | | {"key":"URGENT","value":"紧急"}, |
| | | {"key":"COMMON","value":"一般"}, |
| | | ], |
| | | dataForm: { |
| | | id:'', |
| | | note: '', |
| | | level:'', |
| | | rejectnote:'', |
| | | }, |
| | | filter:{ |
| | | pageIndex:1, |
| | | pageSize:10, |
| | | filter:{ |
| | | code:'', |
| | | level:null, |
| | | rectifierName:'', |
| | | } |
| | | } |
| | | } |
| | | }, |
| | | created() { |
| | | this.hiddenDangerList(); |
| | | }, |
| | | |
| | | methods: { |
| | | queryHandle: function () { |
| | | this.filter.pageIndex = 1 |
| | | this.hiddenDangerList() |
| | | }, |
| | | |
| | | |
| | | viewHandle: function (row) { |
| | | this.$refs.reportView.showDialog("查看",row) |
| | | }, |
| | | |
| | | acceptHandle(row){ |
| | | this.$refs.acceptDialog.showDialog(row) |
| | | } , |
| | | |
| | | handleSizeChange: function (val) { |
| | | this.filter.pageSize = val |
| | | this.filter.pageIndex = 1 |
| | | this.hiddenDangerList() |
| | | }, |
| | | handleCurrentChange: function (val) { |
| | | this.filter.pageIndex = val |
| | | this.hiddenDangerList() |
| | | }, |
| | | getBtnPermission(btnType) { |
| | | return checkBtnPermission(this.userType, btnType) |
| | | }, |
| | | |
| | | downloadHandle(fileurl){ |
| | | window.open(fileurl, '_blank'); |
| | | }, |
| | | |
| | | |
| | | handleChange(file, fileList) { |
| | | this.fileList = fileList |
| | | }, |
| | | |
| | | hiddenDangerList(){ |
| | | this.listLoading = true |
| | | hiddenDangerAcceptList(this.filter) |
| | | .then(res=>{ |
| | | if (res.data.code === '200') { |
| | | this.tableData = res.data.result.records |
| | | this.recordTotal = res.data.result.total |
| | | } |
| | | else{ |
| | | this.$message({message: res.data.message, type: 'warning'}); |
| | | } |
| | | }) |
| | | .catch(err=>{ |
| | | console.log(err) |
| | | this.$message({message: '接口错误', type: 'warning'}); |
| | | }) |
| | | .finally(()=>{ |
| | | this.listLoading = false |
| | | }) |
| | | }, |
| | | clearLevel(){ |
| | | this.filter.filter.level = null |
| | | } |
| | | |
| | | |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .overdue{ |
| | | color: red; |
| | | } |
| | | .overdue-img{ |
| | | position: fixed; |
| | | background-color: #f56c6c; |
| | | border-radius: 4px; |
| | | color: #fff; |
| | | display: inline-block; |
| | | font-size: 12px; |
| | | height: 21px; |
| | | line-height: 18px; |
| | | text-align: center; |
| | | white-space: nowrap; |
| | | border: 1px solid #fff; |
| | | transform: scale(0.8); |
| | | padding: 1px 3px 0 3px; |
| | | |
| | | } |
| | | |
| | | </style> |
对比新文件 |
| | |
| | | <template> |
| | | <el-dialog title="验收" :visible.sync="dialogFormVisible" |
| | | :modal-append-to-body="false" :close-on-click-modal="false" width="800px"> |
| | | <el-form ref="dataForm" :rules="dataFormRules" :model="dataForm" label-position="right" label-width="140px" |
| | | style="" element-loading-text="保存中..."> |
| | | |
| | | |
| | | <el-form-item label="隐患级别:"> |
| | | <el-select v-model="dataForm.level" :disabled="isView"> |
| | | <el-option |
| | | v-for="item in levels" |
| | | :key="item.key" |
| | | :label="item.value" |
| | | :value="item.key"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="整改措施:" > |
| | | <el-input |
| | | style="width: 400px" |
| | | type="textarea" |
| | | :rows="3" |
| | | :disabled="isView" |
| | | v-model="dataForm.rectifymeasure"> |
| | | </el-input> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="整改期限:" > |
| | | <el-date-picker |
| | | v-model="dataForm.rectifydeadline" |
| | | type="datetime" |
| | | :disabled="isView" |
| | | format="yyyy-MM-dd HH:mm" |
| | | value-format="yyyy-MM-dd HH:mm" |
| | | > |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="上报说明:" > |
| | | <el-input |
| | | style="width: 400px" |
| | | type="textarea" |
| | | :rows="3" |
| | | :disabled="isView" |
| | | v-model="dataForm.createnote"> |
| | | </el-input> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="上报图片:" v-if="!isView"> |
| | | <el-upload |
| | | ref="upload" |
| | | :action="baseUrl" |
| | | :auto-upload="false" |
| | | :headers="headers" |
| | | :on-change="handleChange" |
| | | name="file" |
| | | :file-list="fileList" |
| | | list-type="picture-card" |
| | | multiple |
| | | > |
| | | <i class="el-icon-plus"></i> |
| | | </el-upload> |
| | | |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="上报图片:" v-if="isView && imgUrls.length > 0" > |
| | | <el-image |
| | | class="upload-img" |
| | | v-for='item in imgUrls' |
| | | :key='item.id' |
| | | :src="item.url" |
| | | :preview-src-list="imgPreviewUrls" |
| | | style="width:100px;height: 100px;margin: 10px;" |
| | | > |
| | | </el-image> |
| | | </el-form-item> |
| | | |
| | | |
| | | <el-form-item label="整改说明:" v-if="isView"> |
| | | <el-input |
| | | style="width: 400px" |
| | | type="textarea" |
| | | :rows="3" |
| | | :disabled="isView" |
| | | v-model="dataForm.rectifynote"> |
| | | </el-input> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="整改图片:" v-if="isView && imgUrls2.length> 0"> |
| | | <el-image |
| | | class="upload-img" |
| | | v-for='item in imgUrls2' |
| | | :key='item.id' |
| | | :src="item.url" |
| | | :preview-src-list="imgPreviewUrls2" |
| | | style="width:100px;height: 100px;margin: 10px;" |
| | | > |
| | | </el-image> |
| | | |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="选择:" > |
| | | <el-radio-group v-model="isReject" > |
| | | <el-radio :label="false" border>验收</el-radio> |
| | | <el-radio :label="true" border>驳回</el-radio> |
| | | </el-radio-group> |
| | | </el-form-item> |
| | | |
| | | |
| | | <el-form-item label="驳回理由:" v-if="isReject"> |
| | | <el-input |
| | | style="width: 400px" |
| | | type="textarea" |
| | | :rows="3" |
| | | v-model="dataForm.rejectnote"> |
| | | </el-input> |
| | | </el-form-item> |
| | | |
| | | </el-form> |
| | | |
| | | <div style="margin-top: 30px;margin-left: 140px;" class="dialog-footer" > |
| | | <el-button @click="dialogFormVisible = false">取消</el-button> |
| | | <el-button type="primary" @click="acceptSubmit()" v-if="!isReject" :disabled="submiting">验收</el-button> |
| | | <el-button type="primary" class="el-button el-button--danger" @click="rejectSubmit()" v-if="isReject" :disabled="submiting">驳回</el-button> |
| | | |
| | | </div> |
| | | |
| | | </el-dialog> |
| | | </template> |
| | | |
| | | |
| | | <script> |
| | | import { hiddenDangerAccept,hiddenDangerReject} from '@/api/hiddenDanger'; |
| | | import { getToken} from "@/utils/auth"; |
| | | |
| | | export default { |
| | | name: "acceptDialog", |
| | | data(){ |
| | | return { |
| | | headers: { |
| | | 'Authorization': getToken() |
| | | }, |
| | | baseUrl: process.env.BASE_API + 'hiddenDanger/report', |
| | | imgUrls:[], |
| | | imgUrls2:[], |
| | | fileList:[], |
| | | imgPreviewUrls:[], |
| | | imgPreviewUrls2:[], |
| | | isView:false, |
| | | isReject:false, |
| | | submiting:false, |
| | | levels:[ |
| | | {"key":"URGENT","value":"紧急"}, |
| | | {"key":"COMMON","value":"一般"}, |
| | | ], |
| | | dataForm: { |
| | | id:'', |
| | | note: '', |
| | | level:'', |
| | | rejectnote:'', |
| | | }, |
| | | dialogFormVisible: false, |
| | | dialogStatus:'', |
| | | dataFormRules: {}, |
| | | } |
| | | }, |
| | | methods:{ |
| | | showDialog(row){ |
| | | this.isView = true |
| | | this.dataForm.id = row.id |
| | | this.dataForm.level = row.level; |
| | | this.dataForm.createnote = row.createnote; |
| | | this.dataForm.rectifydeadline = row.rectifydeadline; |
| | | this.dataForm.rectifymeasure = row.rectifymeasure; |
| | | this.dataForm.rectifynote = row.rectifynote; |
| | | this.imgUrls = row.reportResources.map(item=>{return {url:process.env.IMG_API+item.url,name:item.id}}) |
| | | this.imgUrls2 = row.rectifyResources.map(item=>{return {url:process.env.IMG_API+item.url,name:item.id}}) |
| | | this.imgPreviewUrls = row.reportResources.map(item=>{ return process.env.IMG_API + item.url }) |
| | | this.imgPreviewUrls2 = row.rectifyResources.map(item=>{ return process.env.IMG_API + item.url }) |
| | | this.dialogFormVisible = true; |
| | | }, |
| | | acceptSubmit(){ |
| | | let params = {} |
| | | params['id'] = this.dataForm.id |
| | | this.submit(params,hiddenDangerAccept) |
| | | |
| | | }, |
| | | |
| | | rejectSubmit(){ |
| | | let params = {} |
| | | params['id'] = this.dataForm.id |
| | | params['rejectnote'] = this.dataForm.rectifynote |
| | | this.submit(params,hiddenDangerReject) |
| | | }, |
| | | |
| | | submit(params,func){ |
| | | this.submiting = true |
| | | func(params) |
| | | .then(res=>{ |
| | | if (res.data.code === '200') { |
| | | this.dialogFormVisible = false |
| | | this.$message({message: '操作成功', type: 'success'}); |
| | | this.$emit("refresh") |
| | | }else{ |
| | | this.$message({message: res.data.message, type: 'success'}); |
| | | } |
| | | this.fileList = [] |
| | | }) |
| | | .catch(err=>{ |
| | | console.log(err); |
| | | this.$message({message: '接口错误', type: 'warning'}); |
| | | }) |
| | | .finally(()=>{ |
| | | this.submiting = false |
| | | }) |
| | | }, |
| | | handleChange(file, fileList) { |
| | | this.fileList = fileList |
| | | }, |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style scoped> |
| | | |
| | | </style> |
对比新文件 |
| | |
| | | <template> |
| | | <el-dialog |
| | | :visible.sync="dialogVisible" |
| | | append-to-body |
| | | :close-on-click-modal="false" |
| | | width="75%" |
| | | > |
| | | <div class="app-container"> |
| | | <div class="filter-container"> |
| | | <div style="display: block;padding-top: 10px;padding-bottom: 10px"> |
| | | <div class="basic_search" > |
| | | <el-select v-model="filter.filter.department" |
| | | filterable |
| | | clearable |
| | | @change="getPersonList" |
| | | placeholder="请选择"> |
| | | <el-option |
| | | v-for="item in options" |
| | | :key="item.value" |
| | | :label="item.label" |
| | | :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | </div> |
| | | <el-button type="primary" icon="el-icon-search" @click="queryHandle" style="margin-left: 20px"/> |
| | | </div> |
| | | </div> |
| | | <div class="table_content"> |
| | | <el-table |
| | | v-loading="listLoading" |
| | | :key="tableKey" |
| | | :data="tableData" |
| | | border |
| | | fit |
| | | highlight-current-row |
| | | style="width: 100%;" |
| | | > |
| | | <el-table-column label="序号" type="index" align="center" width="60"/> |
| | | <el-table-column label="所属部门" align="center"> |
| | | <template slot-scope="scope"> |
| | | <span>{{ scope.row.department}}</span> |
| | | </template> |
| | | </el-table-column> |
| | | |
| | | <el-table-column label="姓名" align="center"> |
| | | <template slot-scope="scope"> |
| | | <span>{{ scope.row.realname }}</span> |
| | | </template> |
| | | </el-table-column> |
| | | |
| | | <el-table-column label="操作" align="center" width="180" class-name="small-padding fixed-width"> |
| | | <template slot-scope="scope"> |
| | | <el-button type="text" @click="selectOne(scope.row)">选择</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <br> |
| | | <el-pagination |
| | | v-show="recordTotal>0" |
| | | :current-page="filter.pageIndex" |
| | | :page-sizes="[10, 20, 30, 50]" |
| | | :page-size="filter.pageSize" |
| | | :total="recordTotal" |
| | | layout="total, sizes, prev, pager, next, jumper" |
| | | background |
| | | style="float:right;" |
| | | @size-change="handleSizeChange" |
| | | @current-change="handleCurrentChange" |
| | | /> |
| | | </div> |
| | | </div> |
| | | </el-dialog> |
| | | </template> |
| | | |
| | | <script> |
| | | import { geDepartmentUserPage ,getAllDepartment} from '@/api/departmentManage'; |
| | | export default { |
| | | name: "taskSelect", |
| | | data(){ |
| | | return{ |
| | | tableKey:0, |
| | | listLoading:false, |
| | | recordTotal: 0, |
| | | options:[], |
| | | filter: { |
| | | pageIndex:1, |
| | | pageSize:10, |
| | | filter: { |
| | | department: '' |
| | | }, |
| | | }, |
| | | dialogVisible:false, |
| | | tableData:[], |
| | | } |
| | | }, |
| | | created(){ |
| | | |
| | | }, |
| | | methods:{ |
| | | queryHandle(){ |
| | | this.filter.pageIndex = 1 |
| | | this.getPersonList() |
| | | }, |
| | | handleSizeChange(val) { |
| | | this.filter.pageSize = val |
| | | this.filter.pageIndex = 1 |
| | | this.getTaskData() |
| | | }, |
| | | handleCurrentChange(val) { |
| | | this.filter.pageIndex = val |
| | | this.getPersonList() |
| | | }, |
| | | show(){ |
| | | this.dialogVisible = true |
| | | this.getDepartmentList() |
| | | }, |
| | | selectOne(value){ |
| | | this.$emit('setPerson',value) |
| | | this.dialogVisible = false |
| | | }, |
| | | async getDepartmentList(){ |
| | | let res = await getAllDepartment() |
| | | if(res.data.code === '200'){ |
| | | this.options = res.data.result.map(item=>{return {value:item.department,label:item.department}}) |
| | | }else{ |
| | | this.$message({ |
| | | message:res.data.message, |
| | | type:'warning' |
| | | }) |
| | | } |
| | | }, |
| | | async getPersonList(){ |
| | | this.listLoading = true |
| | | geDepartmentUserPage(this.filter) |
| | | .then(res => { |
| | | if (res.data.code === '200') { |
| | | this.tableData = res.data.result.records |
| | | this.recordTotal = res.data.result.total |
| | | }else{ |
| | | this.$message({ |
| | | message:res.data.message, |
| | | type:'warning' |
| | | }) |
| | | } |
| | | }) |
| | | .catch(err=>{ |
| | | console.log(err) |
| | | this.$message({ |
| | | message:'接口错误', |
| | | type:'warning' |
| | | }) |
| | | }) |
| | | .finally(()=>{ |
| | | this.listLoading = false |
| | | }) |
| | | } |
| | | |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .basic_search{ |
| | | display:inline-block; |
| | | } |
| | | </style> |
对比新文件 |
| | |
| | | <template> |
| | | <div class="app-container"> |
| | | <div style="margin: 15px"> |
| | | |
| | | <span class="span-filter-label">单号</span> |
| | | <el-input style="width: 140px" v-model="filter.filter.code" ></el-input> |
| | | |
| | | <span class="span-filter-label">隐患等级</span> |
| | | <el-select v-model="filter.filter.level" clearable @clear="clearLevel" placeholder="请选择"> |
| | | <el-option |
| | | v-for="item in levels" |
| | | :key="item.key" |
| | | :label="item.value" |
| | | :value="item.key"> |
| | | </el-option> |
| | | </el-select> |
| | | |
| | | <span class="span-filter-label">上报人</span> |
| | | <el-input style="width: 160px" v-model="filter.filter.requestorName"></el-input> |
| | | <el-button class="filter-item" style="margin-left: 10px;" type="primary" icon="el-icon-search" |
| | | @click="queryHandle"/> |
| | | </div> |
| | | <div class="table_content"> |
| | | <el-table |
| | | v-loading="listLoading" |
| | | :key="tableKey" |
| | | :data="tableData" |
| | | border |
| | | fit |
| | | highlight-current-row |
| | | style="width: 100%;" |
| | | > |
| | | <el-table-column type="index" label="序号" align="center" width="80"/> |
| | | <el-table-column label="单号" prop="code" align="center" /> |
| | | <el-table-column label="状态" prop="status" align="center" > |
| | | <template slot-scope="scope"> |
| | | <span >{{scope.row.status}}</span> |
| | | <span v-if="new Date(scope.row.rectifydeadline) < new Date() && scope.row.status !== '已完成'" class="overdue-img">逾期</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="隐患等级" prop="level" align="center" > |
| | | <template slot-scope="scope"> |
| | | <el-tag :type="scope.row.level == '紧急'?'danger':'warning'">{{scope.row.level}}</el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="上报人" prop="requestor" align="center" /> |
| | | <el-table-column label="整改人" prop="rectifier" align="center" /> |
| | | <el-table-column label="整改期限" prop="rectifydeadline" align="center" > |
| | | <template slot-scope="scope"> |
| | | <span v-bind:class="{'overdue':new Date(scope.row.rectifydeadline) < new Date() && scope.row.status !== '已完成'}">{{scope.row.rectifydeadline}} |
| | | </span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="创建时间" prop="createtime" align="center" /> |
| | | <el-table-column label="操作" align="center" width="240" class-name="small-padding fixed-width"> |
| | | <template slot-scope="scope"> |
| | | <el-button type="text" @click="viewHandle(scope.row)">查看</el-button> |
| | | <el-button type="text" @click="rectifyHandle(scope.row)" v-if="scope.row.status === '待整改' || scope.row.status === '驳回待整改'">整改</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <br> |
| | | <el-pagination |
| | | v-show="recordTotal>0" |
| | | :current-page="filter.pageIndex" |
| | | :page-sizes="[10, 20, 30, 50]" |
| | | :page-size="filter.pageSize" |
| | | :total="recordTotal" |
| | | layout="total, sizes, prev, pager, next, jumper" |
| | | background |
| | | style="float:right;" |
| | | @size-change="handleSizeChange" |
| | | @current-change="handleCurrentChange" |
| | | /> |
| | | </div> |
| | | |
| | | <report-view ref="reportView"></report-view> |
| | | <rectify-dialog ref="rectifyDialog" @refresh = "hiddenDangerList"></rectify-dialog> |
| | | |
| | | <div style="clear: both;"></div> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import { checkBtnPermission} from "@/utils/permission"; |
| | | import { hiddenDangerRectifyList } from '@/api/hiddenDanger'; |
| | | import reportView from "./reportView/reportView"; |
| | | import rectifyDialog from "./rectifyDialog/rectifyDialog"; |
| | | |
| | | export default { |
| | | name: "rectify", |
| | | components: { |
| | | reportView, |
| | | rectifyDialog, |
| | | }, |
| | | data() { |
| | | return { |
| | | recordTotal: 0, |
| | | tableKey: 0, |
| | | tableData:[], |
| | | listLoading: false, |
| | | levels:[ |
| | | {"key":"URGENT","value":"紧急"}, |
| | | {"key":"COMMON","value":"一般"}, |
| | | ], |
| | | dataForm: { |
| | | id:'', |
| | | note: '', |
| | | level:'', |
| | | rectifynote:'', |
| | | rectifydeadline:'', |
| | | rectifymeasure:'' |
| | | }, |
| | | filter:{ |
| | | pageIndex:1, |
| | | pageSize:10, |
| | | filter:{ |
| | | code:'', |
| | | requestorName:'', |
| | | level:null, |
| | | } |
| | | } |
| | | } |
| | | }, |
| | | created() { |
| | | this.hiddenDangerList(); |
| | | |
| | | }, |
| | | methods: { |
| | | queryHandle: function () { |
| | | this.filter.pageIndex = 1 |
| | | this.hiddenDangerList() |
| | | }, |
| | | viewHandle (row) { |
| | | this.$refs.reportView.showDialog("查看",row) |
| | | }, |
| | | rectifyHandle(row){ |
| | | this.$refs.rectifyDialog.show(row) |
| | | }, |
| | | |
| | | handleSizeChange: function (val) { |
| | | this.filter.pageSize = val |
| | | this.filter.pageIndex = 1 |
| | | this.hiddenDangerList() |
| | | }, |
| | | handleCurrentChange: function (val) { |
| | | this.filter.pageIndex = val |
| | | this.hiddenDangerList() |
| | | }, |
| | | getBtnPermission(btnType) { |
| | | return checkBtnPermission(this.userType, btnType) |
| | | }, |
| | | |
| | | |
| | | downloadHandle(fileurl){ |
| | | window.open(fileurl, '_blank'); |
| | | }, |
| | | |
| | | |
| | | |
| | | hiddenDangerList(){ |
| | | this.listLoading = true |
| | | hiddenDangerRectifyList(this.filter) |
| | | .then(res=>{ |
| | | if (res.data.code === '200') { |
| | | this.tableData = res.data.result.records |
| | | this.recordTotal = res.data.result.total |
| | | } |
| | | else{ |
| | | this.$message({message: res.data.message, type: 'warning'}); |
| | | } |
| | | |
| | | }) |
| | | .catch(err=>{ |
| | | console.log(err) |
| | | this.$message({message: '接口错误', type: 'warning'}); |
| | | |
| | | }) |
| | | .finally(()=>{ |
| | | this.listLoading = false |
| | | }) |
| | | }, |
| | | clearLevel(){ |
| | | this.filter.filter.level = null |
| | | } |
| | | |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style scoped> |
| | | |
| | | .overdue{ |
| | | color: red; |
| | | } |
| | | .overdue-img{ |
| | | position: fixed; |
| | | background-color: #f56c6c; |
| | | border-radius: 4px; |
| | | color: #fff; |
| | | display: inline-block; |
| | | font-size: 12px; |
| | | height: 21px; |
| | | line-height: 18px; |
| | | text-align: center; |
| | | white-space: nowrap; |
| | | border: 1px solid #fff; |
| | | transform: scale(0.8); |
| | | padding: 1px 3px 0 3px; |
| | | |
| | | } |
| | | </style> |
对比新文件 |
| | |
| | | <template> |
| | | <el-dialog title="整改" :visible.sync="dialogFormVisible" |
| | | :modal-append-to-body="false" :close-on-click-modal="false" width="800px"> |
| | | <el-form ref="dataForm" :rules="dataFormRules" :model="dataForm" label-position="right" label-width="140px" |
| | | style="" element-loading-text="保存中..."> |
| | | |
| | | |
| | | <el-form-item label="隐患级别:"> |
| | | <el-select v-model="dataForm.level" placeholder="请选择" :disabled="isView"> |
| | | <el-option |
| | | v-for="item in levels" |
| | | :key="item.key" |
| | | :label="item.value" |
| | | :value="item.key"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="整改措施:" > |
| | | <el-input |
| | | style="width: 400px" |
| | | type="textarea" |
| | | :rows="3" |
| | | :disabled="isView" |
| | | placeholder="请输入内容" |
| | | v-model="dataForm.rectifymeasure"> |
| | | </el-input> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="整改期限:" > |
| | | <el-date-picker |
| | | v-model="dataForm.rectifydeadline" |
| | | type="datetime" |
| | | :disabled="isView" |
| | | format="yyyy-MM-dd HH:mm" |
| | | value-format="yyyy-MM-dd HH:mm" |
| | | placeholder="选择日期时间"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="上报说明:" > |
| | | <el-input |
| | | style="width: 400px" |
| | | type="textarea" |
| | | :rows="3" |
| | | :disabled="isView" |
| | | placeholder="请输入内容" |
| | | v-model="dataForm.createnote"> |
| | | </el-input> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="上报图片:" v-if="!isView"> |
| | | <el-upload |
| | | ref="upload" |
| | | :action="baseUrl" |
| | | :auto-upload="false" |
| | | :headers="headers" |
| | | :on-change="handleChange" |
| | | name="file" |
| | | :file-list="fileList" |
| | | list-type="picture-card" |
| | | multiple |
| | | > |
| | | <i class="el-icon-plus"></i> |
| | | </el-upload> |
| | | |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="上报图片:" v-if="isView && imgUrls.length > 0" > |
| | | <el-image |
| | | class="upload-img" |
| | | v-for='item in imgUrls' |
| | | :key='item.id' |
| | | :src="item.url" |
| | | :preview-src-list="imgPreviewUrls" |
| | | style="width:100px;height: 100px;margin: 10px 10px 10px 2px;border-radius: 3px" |
| | | > |
| | | </el-image> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="驳回整改说明:" v-if="dataForm.status === '驳回待整改'"> |
| | | <el-input |
| | | style="width: 400px" |
| | | type="textarea" |
| | | :rows="3" |
| | | placeholder="请输入内容" |
| | | :disabled="isView" |
| | | v-model="dataForm.rectifynote"> |
| | | </el-input> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="驳回整改图片:" v-if="dataForm.status === '驳回待整改'"> |
| | | <el-image |
| | | class="upload-img" |
| | | v-for='item in imgUrls2' |
| | | :key='item.id' |
| | | :src="item.url" |
| | | :disabled="isView" |
| | | :preview-src-list="imgPreviewUrls2" |
| | | style="width:100px;height: 100px;margin: 10px 15px 10px 2px;border-radius: 3px" |
| | | > |
| | | </el-image> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="驳回原因:" v-if="dataForm.status === '驳回待整改'"> |
| | | <el-input |
| | | style="width: 400px" |
| | | type="textarea" |
| | | :rows="3" |
| | | placeholder="请输入内容" |
| | | :disabled="isView" |
| | | v-model="dataForm.rejectnote"> |
| | | </el-input> |
| | | </el-form-item> |
| | | |
| | | |
| | | |
| | | <el-form-item label="整改说明:" > |
| | | <el-input |
| | | style="width: 400px" |
| | | type="textarea" |
| | | :rows="3" |
| | | placeholder="请输入内容" |
| | | v-model="dataForm.note"> |
| | | </el-input> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="整改图片:" > |
| | | <el-upload |
| | | ref="upload" |
| | | :action="baseUrl" |
| | | :auto-upload="false" |
| | | :headers="headers" |
| | | :on-change="handleChange" |
| | | name="file" |
| | | :file-list="fileList" |
| | | list-type="picture-card" |
| | | multiple |
| | | > |
| | | <i class="el-icon-plus"></i> |
| | | </el-upload> |
| | | |
| | | </el-form-item> |
| | | |
| | | </el-form> |
| | | |
| | | <div style="margin-top: 20px;margin-left: 140px;" class="dialog-footer" > |
| | | <el-button @click="dialogFormVisible = false">取消</el-button> |
| | | <el-button type="primary" @click="trigger2Submit()" :disabled="submiting">整改提交</el-button> |
| | | </div> |
| | | |
| | | </el-dialog> |
| | | </template> |
| | | |
| | | <script> |
| | | import { hiddenDangerRectify } from '@/api/hiddenDanger'; |
| | | import { getToken} from "@/utils/auth"; |
| | | |
| | | export default { |
| | | name: "rectifyDialog", |
| | | data(){ |
| | | return { |
| | | dialogFormVisible:false, |
| | | baseUrl: process.env.BASE_API + 'hiddenDanger/report', |
| | | headers: { |
| | | 'Authorization': getToken() |
| | | }, |
| | | imgUrls:[], |
| | | imgUrls2:[], |
| | | imgPreviewUrls:[], |
| | | imgPreviewUrls2:[], |
| | | fileList:[], |
| | | isView:false, |
| | | submiting:false, |
| | | dataFormRules:{}, |
| | | levels:[ |
| | | {"key":"URGENT","value":"紧急"}, |
| | | {"key":"COMMON","value":"一般"}, |
| | | ], |
| | | dataForm: { |
| | | id:'', |
| | | note: '', |
| | | level:'', |
| | | rectifynote:'', |
| | | rectifydeadline:'', |
| | | rectifymeasure:'', |
| | | createnote: '', |
| | | rejectnote:'', |
| | | }, |
| | | } |
| | | }, |
| | | methods:{ |
| | | resetDataForm(){ |
| | | this.dataForm= { |
| | | id:'', |
| | | createnote: '', |
| | | note:'', |
| | | level:'', |
| | | rectifynote:'', |
| | | rectifydeadline:'', |
| | | rectifymeasure:'', |
| | | rejectnote:'', |
| | | }, |
| | | this.imgUrls =[] |
| | | this.imgPreviewUrls = [] |
| | | }, |
| | | show(row){ |
| | | this.resetDataForm(); |
| | | this.isView = true |
| | | this.dataForm.id = row.id |
| | | this.dataForm.level = row.level |
| | | this.dataForm.status = row.status |
| | | this.dataForm.createnote = row.createnote |
| | | this.dataForm.rectifydeadline = row.rectifydeadline |
| | | this.dataForm.rectifymeasure = row.rectifymeasure |
| | | this.dataForm.rectifynote = row.rectifynote |
| | | this.dataForm. rejectnote = row.rejectnote |
| | | this.imgUrls = row.reportResources.map(item=>{return {url:process.env.IMG_API+item.url,name:item.id}}) |
| | | this.imgUrls2 = row.rectifyResources.map(item=>{return {url:process.env.IMG_API+item.url,name:item.id}}) |
| | | this.imgPreviewUrls = row.reportResources.map(item=>{ return process.env.IMG_API + item.url }) |
| | | this.imgPreviewUrls2 = row.rectifyResources.map(item=>{ return process.env.IMG_API + item.url }) |
| | | this.dialogFormVisible = true |
| | | }, |
| | | trigger2Submit(){ |
| | | let formData = new FormData(); |
| | | formData.append('id',this.dataForm.id) |
| | | formData.append('note',this.dataForm.note) |
| | | this.fileList.forEach(file=>{ |
| | | formData.append("files",file.raw) |
| | | }) |
| | | this.submiting = true |
| | | hiddenDangerRectify(formData) |
| | | .then(res=>{ |
| | | if (res.data.code === '200') { |
| | | this.dialogFormVisible = false |
| | | this.$message({message: '操作成功', type: 'success'}); |
| | | this.$emit("refresh") |
| | | }else{ |
| | | this.$message({message: res.data.message, type: 'success'}); |
| | | } |
| | | this.fileList = [] |
| | | } |
| | | ) |
| | | .catch(err=>{ |
| | | console.log(err) |
| | | this.$message({message: '接口错误', type: 'warning'}); |
| | | }) |
| | | .finally(()=>{ |
| | | this.submiting = false |
| | | }) |
| | | }, |
| | | handleChange(file, fileList) { |
| | | this.fileList = fileList |
| | | }, |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style scoped> |
| | | |
| | | </style> |
| | |
| | | <template> |
| | | <div class="app-container"> |
| | | <div style="margin: 10px"> |
| | | <span class="span-filter-label" style="margin-left: unset">作业编号</span> |
| | | <el-input style="width: 160px" v-model="filter.filter.taskcode"></el-input> |
| | | <span class="span-filter-label">单号</span> |
| | | <el-input style="width: 140px" v-model="filter.filter.code" ></el-input> |
| | | <span class="span-filter-label">状态</span> |
| | | <el-select |
| | | v-model="filter.filter.status" |
| | | class="filter-item" |
| | | clearable |
| | | @clear="clearStatus" |
| | | style="width:150px;margin-bottom: 10px"> |
| | | <el-option |
| | | v-for="item in reportStatus" |
| | |
| | | </el-option> |
| | | </el-select> |
| | | <span class="span-filter-label">隐患等级</span> |
| | | <el-select v-model="filter.filter.level" placeholder="请选择"> |
| | | <el-select v-model="filter.filter.level" |
| | | clearable |
| | | @clear="clearLevel" |
| | | placeholder="请选择"> |
| | | <el-option |
| | | v-for="item in levels" |
| | | :key="item.key" |
| | |
| | | </el-option> |
| | | </el-select> |
| | | |
| | | <span class="span-filter-label">负责人</span> |
| | | <el-input style="width: 160px" v-model="filter.filter.principal"></el-input> |
| | | <span class="span-filter-label">整改人</span> |
| | | <el-input style="width: 160px" v-model="filter.filter.supervisor"></el-input> |
| | | <el-input style="width: 160px" v-model="filter.filter.rectifierName"></el-input> |
| | | |
| | | |
| | | <el-button class="filter-item" style="margin-left: 10px;" type="primary" |
| | | icon="el-icon-plus" @click="showCreateHandle">新增 |
| | |
| | | style="width: 100%;" |
| | | > |
| | | <el-table-column type="index" label="序号" align="center" width="80"/> |
| | | <el-table-column label="状态" prop="status" align="center" /> |
| | | <el-table-column label="作业编号" prop="taskcode" align="center" /> |
| | | <el-table-column label="单号" prop="code" align="center" /> |
| | | <el-table-column label="状态" prop="status" align="center" > |
| | | <template slot-scope="scope"> |
| | | <span >{{scope.row.status}}</span> |
| | | <span v-if="new Date(scope.row.rectifydeadline) < new Date() && scope.row.status !== '已完成'" class="overdue-img">逾期</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="隐患等级" prop="level" align="center" > |
| | | <template slot-scope="scope"> |
| | | <el-tag :type="scope.row.level == '紧急'?'danger':'warning'">{{scope.row.level}}</el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="上报人" prop="requestor" align="center" /> |
| | | <el-table-column label="负责人" prop="principal" align="center" /> |
| | | <el-table-column label="整改人" prop="supervisor" align="center" /> |
| | | <el-table-column label="上报时间" prop="createtime" align="center" /> |
| | | <el-table-column label="整改人" prop="rectifier" align="center" /> |
| | | |
| | | <el-table-column label="创建时间" prop="createtime" align="center" /> |
| | | <el-table-column label="整改期限" prop="rectifydeadline" align="center" > |
| | | <template slot-scope="scope"> |
| | | <span v-bind:class="{'overdue':new Date(scope.row.rectifydeadline) < new Date() && scope.row.status !== '已完成'}">{{scope.row.rectifydeadline}} |
| | | </span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="整改时间" prop="rectifytime" align="center" > |
| | | </el-table-column> |
| | | <el-table-column label="验收时间" prop="accepttime" align="center" > |
| | | </el-table-column> |
| | | <el-table-column label="操作" align="center" width="240" class-name="small-padding fixed-width"> |
| | | <template slot-scope="scope"> |
| | | <el-button type="text" @click="viewHandle(scope.row)">查看</el-button> |
| | |
| | | <br> |
| | | <el-pagination |
| | | v-show="recordTotal>0" |
| | | :current-page="currentPage" |
| | | :current-page="filter.pageIndex" |
| | | :page-sizes="[10, 20, 30, 50]" |
| | | :page-size="pageSize" |
| | | :page-size="filter.pageSize" |
| | | :total="recordTotal" |
| | | layout="total, sizes, prev, pager, next, jumper" |
| | | background |
| | |
| | | @current-change="handleCurrentChange" |
| | | /> |
| | | </div> |
| | | <el-dialog :title="dialogStatus==='create'?'新增':'查看'" :visible.sync="dialogFormVisible" |
| | | :modal-append-to-body="false" :close-on-click-modal="false" width="800px"> |
| | | <el-form ref="dataForm" :rules="dataFormRules" :model="dataForm" label-position="right" label-width="140px" |
| | | style="" element-loading-text="保存中..."> |
| | | |
| | | <el-form-item label="作业编号:"> |
| | | <el-input v-model="dataForm.taskCode" readonly style="width: 205px" placeholder="请选择" > |
| | | |
| | | </el-input> |
| | | <el-button style="margin-left: 10px;" type="primary" |
| | | @click="showTask">选择 |
| | | </el-button> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="隐患级别:"> |
| | | <el-select v-model="dataForm.level" placeholder="请选择" :disabled="isView"> |
| | | <el-option |
| | | v-for="item in levels" |
| | | :key="item.key" |
| | | :label="item.value" |
| | | :value="item.key"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="上报说明:" > |
| | | <el-input |
| | | style="width: 400px" |
| | | type="textarea" |
| | | :rows="3" |
| | | :disabled="isView" |
| | | placeholder="请输入内容" |
| | | v-model="dataForm.note"> |
| | | </el-input> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="上报图片:" v-if="!isView"> |
| | | <el-upload |
| | | ref="upload" |
| | | :action="baseUrl" |
| | | :auto-upload="false" |
| | | :headers="headers" |
| | | :on-change="handleChange" |
| | | name="file" |
| | | :file-list="fileList" |
| | | list-type="picture-card" |
| | | multiple |
| | | > |
| | | <i class="el-icon-plus"></i> |
| | | </el-upload> |
| | | |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="上报图片:" v-if="isView" > |
| | | <el-image |
| | | class="upload-img" |
| | | v-for='item in imgUrls' |
| | | :key='item.id' |
| | | :src="item.url" |
| | | :preview-src-list="imgPreviewUrls" |
| | | style="width:200px;height: 200px;margin: 10px;" |
| | | > |
| | | </el-image> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="确认说明:" :disabled="!isView" v-if="isConfirm"> |
| | | <el-input |
| | | style="width: 400px" |
| | | type="textarea" |
| | | :rows="3" |
| | | placeholder="请输入内容" |
| | | v-model="dataForm.note"> |
| | | </el-input> |
| | | </el-form-item> |
| | | |
| | | </el-form> |
| | | |
| | | <div style="margin-top: 20px;margin-left: 140px;" class="dialog-footer" v-if="!isView"> |
| | | <el-button @click="dialogFormVisible = false">取消</el-button> |
| | | <el-button type="primary" @click="trigger2Submit" :disabled="submiting">上报</el-button> |
| | | </div> |
| | | </el-dialog> |
| | | <div style="clear: both;"></div> |
| | | <task-select ref="selectTask" @getInfo="selectSetValue" ></task-select> |
| | | <report-view ref="reportView" ></report-view> |
| | | <report-dialog ref="reportDialog" @refresh="hiddenDangerList"></report-dialog> |
| | | |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import Cookies from 'js-cookie' |
| | | import { checkBtnPermission} from "@/utils/permission"; |
| | | import { parseError} from "@/utils/messageDialog"; |
| | | import { computePageCount} from "@/utils"; |
| | | import { mapGetters} from "vuex"; |
| | | import { dictionaryAllItems } from '@/api/dictionary'; |
| | | import { getSelectTask,hiddenDangerReport ,hiddenDangerReportList} from '@/api/hiddenDanger'; |
| | | import taskSelect from './taskSelect/taskSelect'; |
| | | import {hiddenDangerReportList} from '@/api/hiddenDanger'; |
| | | import reportView from './reportView/reportView' |
| | | import { Message, MessageBox } from 'element-ui' |
| | | import {addHelpDoc, delHelpDoc, editHelpDoc, helpDocList} from "@/api/helpDoc"; |
| | | import {getToken} from "@/utils/auth"; |
| | | import reportDialog from './reportDialog/reportDialog' |
| | | |
| | | export default { |
| | | name: "helpDoc", |
| | | name: "report", |
| | | components: { |
| | | taskSelect, |
| | | reportView |
| | | reportView, |
| | | reportDialog, |
| | | }, |
| | | data() { |
| | | return { |
| | | baseUrl: process.env.BASE_API + 'hiddenDanger/report', |
| | | headers: { |
| | | 'Authorization': getToken() |
| | | }, |
| | | tasksInfo: [], |
| | | imgUrls:[], |
| | | imgPreviewUrls:[], |
| | | isView:false, |
| | | isConfirm:false, |
| | | isRectify:false, |
| | | fileList: [], |
| | | pageSize: 10, |
| | | recordTotal: 0, |
| | | currentPage: 1, |
| | | pageTotal: 0, |
| | | tableKey: 0, |
| | | tableData:[], |
| | | helpDocData: null, |
| | | listLoading: true, |
| | | submiting:false, |
| | | levels:[ |
| | | {"key":"URGENT","value":"紧急"}, |
| | | {"key":"COMMON","value":"一般"}, |
| | | ], |
| | | reportStatus:[ |
| | | {"key":"UNCONFIRMED","value":"未确认"}, |
| | | {"key":"CONFIRMED","value":"确认未整改"}, |
| | | {"key":"REJECT","value":"已驳回"}, |
| | | {"key":"RECTIFIED","value":"已整改"}, |
| | | {"key":"TORECTIFY","value":"待整改"}, |
| | | {"key":"TOACCEPT","value":"整改待验收"}, |
| | | {"key":"REJECTED","value":"驳回待整改"}, |
| | | {"key":"COMPLETED","value":"已完成"}, |
| | | ], |
| | | dataForm: { |
| | | taskCode:'', |
| | | taskid: '', |
| | | rectifydeadline:'', |
| | | rectifymeasure:'', |
| | | rectifier:'', |
| | | rectifierid:'', |
| | | note: '', |
| | | level:'' |
| | | }, |
| | | queryForm: { |
| | | name: '' |
| | | }, |
| | | dialogFormVisible: false, |
| | | dialogStatus: '', |
| | | dataFormRules: {}, |
| | | fileType: [], |
| | | productVoList: [], |
| | | productVoDialogVisible: false, |
| | | productDialogFormVisible: false, |
| | | productData: [], |
| | | pageSizeProduct: 10, |
| | | currentPageProduct: 1, |
| | | recordTotalProduct: 0, |
| | | pageTotalProduct: 0, |
| | | queryProductForm: { |
| | | name: '', |
| | | manufacturer: '', |
| | | directionCode: '', |
| | | type: '' |
| | | }, |
| | | isSupervision: '', |
| | | |
| | | manufacturer: '', |
| | | enterpriseList: [], |
| | | enterpriseDialogFormVisible: false, |
| | | pageSizeEnterpise: 10, |
| | | currentPageEnterpise: 1, |
| | | recordTotalEnterpise: 0, |
| | | pageTotalEnterpise: 0, |
| | | filter:{ |
| | | pageIndex:1, |
| | | pageSize:10, |
| | | filter:{ |
| | | taskcode:'', |
| | | status:"UNCONFIRMED", |
| | | requestor:"", |
| | | principal:"", |
| | | supervisor:"", |
| | | level:"" |
| | | code:'', |
| | | status:null, |
| | | level:null, |
| | | rectifierName:'', |
| | | } |
| | | } |
| | | }, |
| | | |
| | | } |
| | | }, |
| | | created() { |
| | | this.hiddenDangerList(); |
| | | }, |
| | | methods: { |
| | | |
| | | refreshHandle: function () { |
| | | this.hiddenDangerList() |
| | | }, |
| | | queryHandle: function () { |
| | | this.currentPage = 1 |
| | | this.filter.pageIndex = 1 |
| | | this.hiddenDangerList() |
| | | }, |
| | | resetDataForm() { |
| | | this.dataForm = { |
| | | taskid: '', |
| | | taskCode:'', |
| | | rectifydeadline:'', |
| | | rectifymeasure:'', |
| | | rectifier:'', |
| | | rectifierid:'', |
| | | note: '', |
| | | level:'' |
| | | } |
| | | }, |
| | | showCreateHandle() { |
| | | this.getSelectTasks() |
| | | this.dialogFormVisible = true |
| | | this.dialogStatus = 'create' |
| | | this.isView = false |
| | | this.resetDataForm() |
| | | this.$refs.reportDialog.show() |
| | | }, |
| | | viewHandle: function (row) { |
| | | |
| | | this.$refs.reportView.showDialog("查看",row) |
| | | |
| | | }, |
| | | handleSizeChange: function (val) { |
| | | this.pageSize = val |
| | | this.currentPage = 1 |
| | | this.filter.pageIndex = 1 |
| | | this.filter.pageSize = val |
| | | this.hiddenDangerList() |
| | | }, |
| | | handleCurrentChange: function (val) { |
| | | this.currentPage = val |
| | | this.filter.pageIndex = val |
| | | this.hiddenDangerList() |
| | | }, |
| | | getBtnPermission(btnType) { |
| | | return checkBtnPermission(this.userType, btnType) |
| | | }, |
| | | |
| | | showProductHandle(){ |
| | | this.productDialogFormVisible = true; |
| | | }, |
| | | showEnterprise(){ |
| | | this.enterpriseDialogFormVisible = true; |
| | | }, |
| | | |
| | | downloadHandle(fileurl){ |
| | | window.open(fileurl, '_blank') |
| | | ; |
| | | }, |
| | | selectSetValue(row){ |
| | | this.dataForm.taskCode = row.code |
| | | this.dataForm.taskid = row.id |
| | | |
| | | }, |
| | | |
| | | |
| | | getSelectTasks(){ |
| | | getSelectTask() |
| | | .then(res=>{ |
| | | if (res.status !== 200) |
| | | this.$message({ |
| | | message: '接口错误', |
| | | type: 'success' |
| | | }); |
| | | else{ |
| | | this.tasksInfo = res.data.result.map(item=>{return {"id":item.id,"code":item.code}}) |
| | | } |
| | | }) |
| | | |
| | | .catch(res=>{ |
| | | console.log(res) |
| | | }) |
| | | }, |
| | | |
| | | handleChange(file, fileList) { |
| | | this.fileList = fileList |
| | | }, |
| | | |
| | | trigger2Submit(){ |
| | | this.submiting = true |
| | | let formData = new FormData() |
| | | formData.append('taskid', this.dataForm.taskid) |
| | | formData.append("note",this.dataForm.note) |
| | | formData.append("level",this.dataForm.level) |
| | | this.fileList.forEach(file=>{ |
| | | formData.append("files",file.raw) |
| | | }) |
| | | |
| | | hiddenDangerReport(formData).then(res=>{ |
| | | this.submiting = false |
| | | if (res.status === 200) { |
| | | if (res.data.code === '200') { |
| | | this.dialogFormVisible = false |
| | | this.$message({ |
| | | message: '创建成功', |
| | | type: 'success' |
| | | }); |
| | | this.hiddenDangerList() |
| | | }else{ |
| | | this.$message({ |
| | | message: res.data.message, |
| | | type: 'success' |
| | | }); |
| | | } |
| | | this.fileList = [] |
| | | |
| | | } |
| | | else{ |
| | | this.$message({ |
| | | message: '接口错误', |
| | | type: 'warning' |
| | | }); |
| | | } |
| | | } |
| | | ) |
| | | |
| | | }, |
| | | |
| | | hiddenDangerList(){ |
| | | hiddenDangerReportList(this.filter).then(res=>{ |
| | | this.listLoading = false |
| | | if (res.status === 200) { |
| | | this.listLoading = true |
| | | hiddenDangerReportList(this.filter) |
| | | .then(res=>{ |
| | | if (res.data.code === '200') { |
| | | this.tableData = res.data.result.records |
| | | this.recordTotal = res.data.result.total |
| | | } |
| | | }else{ |
| | | this.$message({ |
| | | message: '接口错误', |
| | | type: 'warning' |
| | | }); |
| | | |
| | | else{ |
| | | this.$message({message: res.data.message, type: 'warning'}); |
| | | } |
| | | }) |
| | | .catch(err=>{ |
| | | console.log(err) |
| | | this.$message({message: '接口错误', type: 'warning'}); |
| | | }) |
| | | .finally(()=>{ |
| | | this.listLoading = false |
| | | }) |
| | | |
| | | }, |
| | | showTask(){ |
| | | this.$refs.selectTask.showTask() |
| | | |
| | | |
| | | clearStatus(){ |
| | | this.filter.filter.status = null |
| | | }, |
| | | clearLevel(){ |
| | | this.filter.filter.level = null |
| | | } |
| | | |
| | | } |
| | |
| | | margin-right: 4px; |
| | | margin-left: 7px; |
| | | } |
| | | .overdue{ |
| | | color: red; |
| | | } |
| | | .overdue-img{ |
| | | position: fixed; |
| | | background-color: #f56c6c; |
| | | border-radius: 4px; |
| | | color: #fff; |
| | | display: inline-block; |
| | | font-size: 12px; |
| | | height: 21px; |
| | | line-height: 18px; |
| | | text-align: center; |
| | | white-space: nowrap; |
| | | border: 1px solid #fff; |
| | | transform: scale(0.8); |
| | | padding: 1px 3px 0 3px; |
| | | |
| | | } |
| | | </style> |
对比新文件 |
| | |
| | | <template> |
| | | <el-dialog title="新增" :visible.sync="dialogFormVisible" |
| | | :modal-append-to-body="false" :close-on-click-modal="false" width="800px"> |
| | | <el-form ref="dataForm" :rules="dataFormRules" :model="dataForm" label-position="right" label-width="140px" |
| | | style="" element-loading-text="保存中..."> |
| | | |
| | | |
| | | <el-form-item label="隐患级别:"> |
| | | <el-select v-model="dataForm.level" placeholder="请选择" :disabled="isView"> |
| | | <el-option |
| | | v-for="item in levels" |
| | | :key="item.key" |
| | | :label="item.value" |
| | | :value="item.key"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="选择整改人:"> |
| | | <el-input v-model="dataForm.rectifier" readonly style="width: 205px" placeholder="请选择" > |
| | | |
| | | </el-input> |
| | | <el-button style="margin-left: 10px;" type="primary" |
| | | @click="showPersonSelect">选择 |
| | | </el-button> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="整改措施:" > |
| | | <el-input |
| | | style="width: 400px" |
| | | type="textarea" |
| | | :rows="3" |
| | | :disabled="isView" |
| | | placeholder="请输入内容" |
| | | v-model="dataForm.rectifymeasure"> |
| | | </el-input> |
| | | </el-form-item> |
| | | <el-form-item label="整改期限 :" > |
| | | <el-date-picker |
| | | v-model="dataForm.rectifydeadline" |
| | | type="datetime" |
| | | format="yyyy-MM-dd HH:mm" |
| | | :picker-options="pickerOptions" |
| | | value-format="yyyy-MM-dd HH:mm" |
| | | placeholder="选择日期时间"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | <el-form-item label="上报说明:" > |
| | | <el-input |
| | | style="width: 400px" |
| | | type="textarea" |
| | | :rows="3" |
| | | :disabled="isView" |
| | | placeholder="请输入内容" |
| | | v-model="dataForm.note"> |
| | | </el-input> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="上报图片:" v-if="!isView"> |
| | | <el-upload |
| | | ref="upload" |
| | | :action="baseUrl" |
| | | :auto-upload="false" |
| | | :headers="headers" |
| | | :on-change="handleChange" |
| | | name="file" |
| | | :file-list="fileList" |
| | | list-type="picture-card" |
| | | multiple |
| | | > |
| | | <i class="el-icon-plus"></i> |
| | | </el-upload> |
| | | |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="上报图片:" v-if="isView" > |
| | | <el-image |
| | | class="upload-img" |
| | | v-for='item in imgUrls' |
| | | :key='item.id' |
| | | :src="item.url" |
| | | :preview-src-list="imgPreviewUrls" |
| | | style="width:100px;height: 100px;margin: 10px;" |
| | | > |
| | | </el-image> |
| | | </el-form-item> |
| | | |
| | | |
| | | |
| | | </el-form> |
| | | |
| | | <div style="margin-top: 20px;margin-left: 140px;" class="dialog-footer" v-if="!isView"> |
| | | <el-button @click="dialogFormVisible = false">取消</el-button> |
| | | <el-button type="primary" @click="trigger2Submit" :disabled="submiting">上报</el-button> |
| | | </div> |
| | | <person-select ref="selectPerson" @setPerson="selectSetValue" ></person-select> |
| | | </el-dialog> |
| | | </template> |
| | | |
| | | <script> |
| | | import personSelect from '../personSelect/personSelect' |
| | | import { hiddenDangerReport } from '@/api/hiddenDanger'; |
| | | import {getToken} from "@/utils/auth"; |
| | | export default { |
| | | name: "reportDialog", |
| | | data(){ |
| | | return { |
| | | baseUrl: process.env.BASE_API + 'hiddenDanger/report', |
| | | headers: { |
| | | 'Authorization': getToken() |
| | | }, |
| | | submiting:false, |
| | | levels:[ |
| | | {"key":"URGENT","value":"紧急"}, |
| | | {"key":"COMMON","value":"一般"}, |
| | | ], |
| | | pickerOptions:{ |
| | | disabledDate(now){ |
| | | return now.getTime() < new Date(new Date().toLocaleDateString()).getTime() |
| | | } |
| | | }, |
| | | fileList: [], |
| | | dataForm: { |
| | | rectifydeadline:'', |
| | | rectifymeasure:'', |
| | | rectifier:'', |
| | | rectifierid:'', |
| | | note: '', |
| | | level:'' |
| | | }, |
| | | dialogFormVisible: false, |
| | | dataFormRules: {}, |
| | | isView:false, |
| | | } |
| | | }, |
| | | components:{ |
| | | personSelect, |
| | | }, |
| | | methods:{ |
| | | resetDataForm(){ |
| | | this.dataForm = { |
| | | rectifydeadline:'', |
| | | rectifymeasure:'', |
| | | rectifier:'', |
| | | rectifierid:'', |
| | | note: '', |
| | | level:'' |
| | | } |
| | | }, |
| | | show(){ |
| | | this.dialogFormVisible = true |
| | | this.isView = false |
| | | this.resetDataForm() |
| | | }, |
| | | trigger2Submit(){ |
| | | this.submiting = true |
| | | let formData = new FormData() |
| | | formData.append('rectifier', this.dataForm.rectifier) |
| | | formData.append("rectifierid",this.dataForm.rectifierid) |
| | | formData.append("level",this.dataForm.level) |
| | | formData.append("rectifymeasure",this.dataForm.rectifymeasure) |
| | | formData.append("rectifydeadline",this.dataForm.rectifydeadline) |
| | | formData.append("note",this.dataForm.note) |
| | | this.fileList.forEach(file=>{ |
| | | formData.append("files",file.raw) |
| | | }) |
| | | |
| | | hiddenDangerReport(formData) |
| | | .then(res=>{ |
| | | if (res.data.code === '200') { |
| | | this.dialogFormVisible = false |
| | | this.$message({ |
| | | message: '创建成功', |
| | | type: 'success' |
| | | }); |
| | | this.$emit("refresh") |
| | | }else{ |
| | | this.$message({ |
| | | message: res.data.message, |
| | | type: 'warning' |
| | | }); |
| | | } |
| | | this.fileList = [] |
| | | } |
| | | ) |
| | | .catch(err=>{ |
| | | console.log(err) |
| | | this.$message({ |
| | | message: "接口错误,请联系管理员", |
| | | type: 'warning' |
| | | }); |
| | | }) |
| | | .finally(()=>{ |
| | | this.submiting = false |
| | | }) |
| | | |
| | | }, |
| | | showPersonSelect(){ |
| | | this.$refs.selectPerson.show(); |
| | | }, |
| | | selectSetValue(row){ |
| | | this.dataForm.rectifier = row.realname |
| | | this.dataForm.rectifierid = row.id |
| | | }, |
| | | |
| | | |
| | | handleChange(file, fileList) { |
| | | this.fileList = fileList |
| | | }, |
| | | |
| | | |
| | | } |
| | | } |
| | | </script> |
| | | |
| | | <style scoped> |
| | | |
| | | .el-picker-panel__footer .el-button--text.el-picker-panel__link-btn { |
| | | display: none; |
| | | } |
| | | </style> |
| | |
| | | <el-form ref="dataForm" :model="dataForm" label-position="right" label-width="140px" |
| | | element-loading-text="保存中..."> |
| | | |
| | | <el-form-item label="作业编号:"> |
| | | <el-input v-model="dataForm.taskCode" style="width: 205px" :readonly="true" /> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="隐患级别:"> |
| | | <el-input v-model="dataForm.level" style="width: 205px" placeholder="请选择" :readonly="true"/> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="整改人:"> |
| | | <el-input v-model="dataForm.rectifier" style="width: 205px" placeholder="请选择" :readonly="true"/> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="整改期限:"> |
| | | <el-date-picker |
| | | v-model="dataForm.rectifydeadline" |
| | | type="datetime" |
| | | :readonly="true" |
| | | format="yyyy-MM-dd HH:mm" |
| | | value-format="yyyy-MM-dd HH:mm" |
| | | > |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="整改措施:" > |
| | | <el-input |
| | | style="width: 400px" |
| | | type="textarea" |
| | | :rows="3" |
| | | :readonly="true" |
| | | v-model="dataForm.rectifymeasure"> |
| | | </el-input> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="上报说明:" > |
| | |
| | | </el-image> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="隐患确认:" v-if="this.dataForm.status !== '未确认'"> |
| | | <el-radio v-model="dataForm.ishiddendanger" v-if="dataForm.ishiddendanger" :label="true" border >是隐患</el-radio> |
| | | <el-radio v-model="dataForm.ishiddendanger" v-if="!dataForm.ishiddendanger" :label="false" border >非隐患</el-radio> |
| | | </el-form-item> |
| | | |
| | | <el-form-item :label="this.dataForm.status === '已驳回'?'驳回说明:':'确认说明:'" v-if="this.dataForm.status !== '未确认'"> |
| | | <el-form-item label="整改说明:" v-if="this.dataForm.status !== '待整改'"> |
| | | <el-input |
| | | style="width: 400px" |
| | | type="textarea" |
| | | :rows="3" |
| | | :readonly="true" |
| | | v-model="dataForm.confirmnote"> |
| | | v-model="dataForm.rectifynote"> |
| | | </el-input> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="整改图片:" v-if="this.dataForm.status === '已整改' && imgUrls2.length > 0"> |
| | | |
| | | <el-form-item label="整改图片:" v-if="this.dataForm.status !== '待整改' && imgUrls2.length > 0"> |
| | | <el-image |
| | | class="upload-img img-wrapper" |
| | | v-for='item in imgUrls2' |
| | |
| | | |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="整改说明:" v-if="this.dataForm.status === '已整改'"> |
| | | |
| | | <el-form-item label="驳回原因:" v-if="this.dataForm.status === '驳回待整改'"> |
| | | <el-input |
| | | style="width: 400px" |
| | | type="textarea" |
| | | :rows="3" |
| | | :readonly="true" |
| | | v-model="dataForm.rectifynote"> |
| | | v-model="dataForm.rejectnote"> |
| | | </el-input> |
| | | </el-form-item> |
| | | |
| | |
| | | showDialog(title,row){ |
| | | this.title = title; |
| | | this.dataForm.status = row.status |
| | | this.dataForm.taskCode = row.taskcode |
| | | this.dataForm.level = row.level |
| | | this.imgUrls = row.reportResources.map(item=>{return {url:process.env.IMG_API+item.url,name:item.id}}) |
| | | this.imgPreviewUrls = row.reportResources.map(item=>{ return process.env.IMG_API + item.url }) |
| | | this.imgUrls2 = row.rectifyResources.map(item=>{return {url:process.env.IMG_API+item.url,name:item.id}}) |
| | | this.imgPreviewUrls2 = row.rectifyResources.map(item=>{ return process.env.IMG_API + item.url }) |
| | | this.dataForm.ishiddendanger = row.ishiddendanger |
| | | this.dataForm.rectifynote = row.rectifynote |
| | | this.dataForm.confirmnote = row.confirmnote |
| | | this.dataForm.createnote = row.createnote; |
| | | this.dataForm.rectifymeasure = row.rectifymeasure; |
| | | this.dataForm.rectifydeadline = row.rectifydeadline; |
| | | this.dataForm.rejectnote = row.rejectnote; |
| | | this.dataForm.rectifier= row.rectifier; |
| | | this.dialogFormVisible = true; |
| | | }, |
| | | |
| | |
| | | <template> |
| | | <div class="app-container"> |
| | | <div style="margin: 10px"> |
| | | <span class="span-filter-label">作业编号</span> |
| | | <el-input style="width: 160px" v-model="filter.filter.taskcode"></el-input> |
| | | |
| | | <span class="span-filter-label">单号</span> |
| | | <el-input style="width: 140px" v-model="filter.filter.code" ></el-input> |
| | | <span class="span-filter-label">状态</span> |
| | | <el-select |
| | | v-model="filter.filter.status" |
| | | clearable @clear="clearStatus" |
| | | class="filter-item" |
| | | style="width:120px;margin-bottom: 10px"> |
| | | <el-option |
| | |
| | | </el-select> |
| | | <span class="span-filter-label">隐患等级</span> |
| | | <el-select v-model="filter.filter.level" |
| | | clearable @clear="clearLevel" |
| | | style="width: 100px" |
| | | placeholder="请选择"> |
| | | > |
| | | <el-option |
| | | v-for="item in levels" |
| | | :key="item.key" |
| | |
| | | </el-select> |
| | | |
| | | <span class="span-filter-label">上报人</span> |
| | | <el-input style="width: 140px" v-model="filter.filter.requestor" ></el-input> |
| | | <span class="span-filter-label">负责人</span> |
| | | <el-input style="width: 140px" v-model="filter.filter.principal"></el-input> |
| | | <el-input style="width: 140px" v-model="filter.filter.requestorName" ></el-input> |
| | | <span class="span-filter-label">整改人</span> |
| | | <el-input style="width: 140px" v-model="filter.filter.supervisor"></el-input> |
| | | |
| | | <el-input style="width: 140px" v-model="filter.filter.rectifierName"></el-input> |
| | | <el-button class="filter-item" style="margin-left: 10px;" type="primary" icon="el-icon-search" |
| | | @click="queryHandle"/> |
| | | </div> |
| | |
| | | style="width: 100%;position: relative;top: -7px" |
| | | > |
| | | <el-table-column label="待整改数" prop="2rectifynum" align="center" /> |
| | | <el-table-column label="整改数量" prop="rectifynum" align="center"/> |
| | | <el-table-column label="完成数量" prop="completednum" align="center"/> |
| | | <el-table-column label="驳回总数" prop="rejectnum" align="center" /> |
| | | <el-table-column label="上报总数" prop="reportnum" align="center" /> |
| | | <el-table-column label="待验收数" prop="2acceptnum" align="center" /> |
| | | </el-table> |
| | | <el-table |
| | | :key="tableKey" |
| | |
| | | style="width: 100%;" |
| | | > |
| | | <el-table-column type="index" label="序号" align="center" width="80"/> |
| | | <el-table-column label="状态" prop="status" align="center" /> |
| | | <el-table-column label="作业编号" prop="taskcode" align="center" /> |
| | | <el-table-column label="单号" prop="code" align="center" /> |
| | | <el-table-column label="状态" prop="status" align="center" > |
| | | <template slot-scope="scope"> |
| | | <span >{{scope.row.status}}</span> |
| | | <span v-if="new Date(scope.row.rectifydeadline) < new Date() && scope.row.status !== '已完成'" class="overdue-img">逾期</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="隐患等级" prop="level" align="center" > |
| | | <template slot-scope="scope"> |
| | | <el-tag :type="scope.row.level == '紧急'?'danger':'warning'">{{scope.row.level}}</el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="上报人" prop="requestor" align="center" /> |
| | | <el-table-column label="负责人" prop="principal" align="center" /> |
| | | <el-table-column label="整改人" prop="supervisor" align="center" /> |
| | | <el-table-column label="上报时间" prop="createtime" align="center" /> |
| | | <el-table-column label="整改人" prop="rectifier" align="center" /> |
| | | <el-table-column label="整改期限" prop="rectifydeadline" align="center" > |
| | | <template slot-scope="scope"> |
| | | <span v-bind:class="{'overdue':new Date(scope.row.rectifydeadline) < new Date() && scope.row.status !== '已完成'}">{{scope.row.rectifydeadline}} |
| | | </span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="整改时间" prop="rectifytime" align="center" /> |
| | | <el-table-column label="验收时间" prop="accepttime" align="center" /> |
| | | |
| | | <el-table-column label="创建时间" prop="createtime" align="center" /> |
| | | |
| | | <el-table-column label="操作" align="center" width="240" class-name="small-padding fixed-width"> |
| | | <template slot-scope="scope"> |
| | | <el-button type="text" @click="viewHandle(scope.row)">查看</el-button> |
| | |
| | | |
| | | <el-pagination |
| | | v-show="recordTotal>0" |
| | | :current-page="currentPage" |
| | | :current-page="filter.pageIndex" |
| | | :page-sizes="[10, 20, 30, 50]" |
| | | :page-size="pageSize" |
| | | :page-size="filter.pageSize" |
| | | :total="recordTotal" |
| | | layout="total, sizes, prev, pager, next, jumper" |
| | | background |
| | |
| | | {"key":"COMMON","value":"一般"}, |
| | | ], |
| | | reportStatus:[ |
| | | {"key":"","value":"全部"}, |
| | | {"key":"UNCONFIRMED","value":"未确认"}, |
| | | {"key":"CONFIRMED","value":"确认未整改"}, |
| | | {"key":"REJECT","value":"已驳回"}, |
| | | {"key":"RECTIFIED","value":"已整改"}, |
| | | {"key":"TORECTIFY","value":"待整改"}, |
| | | {"key":"TOACCEPT","value":"整改待验收"}, |
| | | {"key":"REJECTED","value":"驳回待整改"}, |
| | | {"key":"COMPLETED","value":"已完成"}, |
| | | ], |
| | | pageSize:6, |
| | | currentPage:1, |
| | | recordTotal:0, |
| | | filter:{ |
| | | pageIndex:1, |
| | | pageSize:6, |
| | | pageSize:10, |
| | | filter:{ |
| | | taskcode:'', |
| | | status:"", |
| | | requestor:"", |
| | | principal:"", |
| | | supervisor:"", |
| | | level:"" |
| | | code:'', |
| | | status:null, |
| | | level:null, |
| | | requestorName:'', |
| | | rectifierName:'', |
| | | } |
| | | } |
| | | |
| | |
| | | }, |
| | | methods:{ |
| | | handleSizeChange: function (val) { |
| | | this.pageSize = val |
| | | this.filter.pageSize = val |
| | | this.filter.pageIndex = 1 |
| | | this.hiddenDangerStatisticsList() |
| | | }, |
| | | handleCurrentChange: function (val) { |
| | | this.currentPage = val |
| | | this.filter.pageIndex = val |
| | | this.hiddenDangerStatisticsList() |
| | | }, |
| | | queryHandle(){ |
| | | this.filter.pageIndex = 1 |
| | | this.hiddenDangerStatisticsList() |
| | | }, |
| | | viewHandle(row){ |
| | |
| | | |
| | | hiddenDangerStatisticsList() { |
| | | this.listLoading = true |
| | | hiddenDangerStatisticsList(this.filter).then(res=>{ |
| | | this.listLoading = false |
| | | if (res.status === 200) { |
| | | hiddenDangerStatisticsList(this.filter) |
| | | .then(res=>{ |
| | | if (res.data.code === '200') { |
| | | this.tableData = res.data.result.records |
| | | this.pageSize = res.data.result.size |
| | | this.currentPage = res.data.result.current |
| | | this.recordTotal = res.data.result.total |
| | | this.showData = [(res.data.result.extension)] |
| | | |
| | | } |
| | | }else{ |
| | | this.$message({ |
| | | message: '接口错误', |
| | | type: 'warning' |
| | | }); |
| | | |
| | | else{ |
| | | this.$message({ message: res.data.message, type: 'warning'}); |
| | | } |
| | | |
| | | }) |
| | | .catch(err=>{ |
| | | console.log(err) |
| | | this.$message({ message: '接口错误', type: 'warning'}); |
| | | }) |
| | | .finally(()=>{ |
| | | this.listLoading = false |
| | | }) |
| | | }, |
| | | clearLevel(){ |
| | | this.filter.filter.level = null |
| | | }, |
| | | clearStatus(){ |
| | | this.filter.filter.status = null |
| | | } |
| | | |
| | | |
| | | } |
| | | } |
| | |
| | | |
| | | <style scoped> |
| | | |
| | | .overdue{ |
| | | color: red; |
| | | } |
| | | .overdue-img{ |
| | | position: fixed; |
| | | background-color: #f56c6c; |
| | | border-radius: 4px; |
| | | color: #fff; |
| | | display: inline-block; |
| | | font-size: 12px; |
| | | height: 21px; |
| | | line-height: 18px; |
| | | text-align: center; |
| | | white-space: nowrap; |
| | | border: 1px solid #fff; |
| | | transform: scale(0.8); |
| | | padding: 1px 3px 0 3px; |
| | | |
| | | } |
| | | |
| | | </style> |