Browse Source

修改

dev_kxc
xzt 1 year ago
parent
commit
72a1a4b74a
  1. 53
      jwtech-admin-page/src/api/warn/rectification.js
  2. 53
      jwtech-admin-page/src/api/warn/zrdw.js
  3. 45
      jwtech-admin-page/src/views/building/projectInfo/index.vue
  4. 35
      jwtech-admin-page/src/views/building/projectInfo/projectProcess/baseMsg.vue
  5. 482
      jwtech-admin-page/src/views/evaluationEarlyWarning/supervisionInspection/regulatoryInspection/editPart.vue
  6. 435
      jwtech-admin-page/src/views/evaluationEarlyWarning/supervisionInspection/regulatoryInspection/index.vue
  7. 427
      jwtech-admin-page/src/views/evaluationEarlyWarning/supervisionInspection/regulatoryInspection/responsibleUnit.vue

53
jwtech-admin-page/src/api/warn/rectification.js

@ -0,0 +1,53 @@
import request from '@/utils/request'
// 查询整改通知书列表
export function listRectification(query) {
return request({
url: '/warn/rectification/list',
method: 'post',
data: query
})
}
// 查询整改通知书详细
export function getRectification(id) {
return request({
url: '/warn/rectification/' + id,
method: 'get'
})
}
// 新增整改通知书
export function addRectification(data) {
return request({
url: '/warn/rectification',
method: 'post',
data: data
})
}
// 修改整改通知书
export function updateRectification(data) {
return request({
url: '/warn/rectification',
method: 'put',
data: data
})
}
// 删除整改通知书
export function delRectification(id) {
return request({
url: '/warn/rectification/' + id,
method: 'delete'
})
}
// 导出整改通知书
export function exportRectification(query) {
return request({
url: '/warn/rectification/export',
method: 'get',
params: query
})
}

53
jwtech-admin-page/src/api/warn/zrdw.js

@ -0,0 +1,53 @@
import request from '@/utils/request'
// 查询责任单位列表
export function listZrdw(query) {
return request({
url: '/warn/zrdw/list',
method: 'post',
data: query
})
}
// 查询责任单位详细
export function getZrdw(id) {
return request({
url: '/warn/zrdw/' + id,
method: 'get'
})
}
// 新增责任单位
export function addZrdw(data) {
return request({
url: '/warn/zrdw',
method: 'post',
data: data
})
}
// 修改责任单位
export function updateZrdw(data) {
return request({
url: '/warn/zrdw',
method: 'put',
data: data
})
}
// 删除责任单位
export function delZrdw(id) {
return request({
url: '/warn/zrdw/' + id,
method: 'delete'
})
}
// 导出责任单位
export function exportZrdw(query) {
return request({
url: '/warn/zrdw/export',
method: 'get',
params: query
})
}

45
jwtech-admin-page/src/views/building/projectInfo/index.vue

@ -930,15 +930,8 @@ import {
updateInfo, updateInfo,
exportInfo, exportInfo,
} from "@/api/build/projectInfo"; } from "@/api/build/projectInfo";
import { // import {listProposal,getProposal,delProposal,addProposal,updateProposal,exportProposal,getProjectCode } from "@/api/earlyStage/proposal";
listProposal, import { listProDesign, getProDesign } from "@/api/earlyStage/preDesign";
getProposal,
delProposal,
addProposal,
updateProposal,
exportProposal,
getProjectCode,
} from "@/api/earlyStage/proposal";
import { getAreasData } from "@/api/areas/index"; import { getAreasData } from "@/api/areas/index";
import { regionData, codeToText, TextToCode } from "element-china-area-data"; import { regionData, codeToText, TextToCode } from "element-china-area-data";
export default { export default {
@ -1020,6 +1013,36 @@ export default {
sortBy: "desc", sortBy: "desc",
}, },
}, },
proQueryParams: {
pageNum: 1,
pageSize: 10,
ids: null,
data: {
projectName: null,
constructionNature: null,
constructionLocation: null,
projectUnitName: null,
briefIntroduction: null,
projectLandSituation: null,
designEstimateReport: null,
relatedAttachment: null,
projectCode: null,
proNo: null,
createUid: null,
createTime: null,
updateUid: null,
updateTime: null,
owerDept: null,
},
cv: {},
//
params: {
//
orderBy: "create_time",
// descasc
sortBy: "desc",
},
},
// //
form: {}, form: {},
adcdArr: [], adcdArr: [],
@ -1380,7 +1403,7 @@ export default {
}, },
getId(res) { getId(res) {
// console.log(res) // console.log(res)
getProposal(res.id).then((response) => { getProDesign(res.id).then((response) => {
// console.log(response.data) // console.log(response.data)
this.proNo = response.data.proNo; this.proNo = response.data.proNo;
this.proCode = response.data.projectCode; this.proCode = response.data.projectCode;
@ -1539,7 +1562,7 @@ export default {
/** 新增按钮操作 */ /** 新增按钮操作 */
handleAdd() { handleAdd() {
this.reset(); this.reset();
listProposal(this.queryParams).then((response) => { listProDesign(this.proQueryParams).then((response) => {
this.projectNameOptions = response.records; this.projectNameOptions = response.records;
}); });
this.radio = "zd"; this.radio = "zd";

35
jwtech-admin-page/src/views/building/projectInfo/projectProcess/baseMsg.vue

@ -647,6 +647,7 @@ import {
exportProposal, exportProposal,
getProjectCode, getProjectCode,
} from "@/api/earlyStage/proposal"; } from "@/api/earlyStage/proposal";
import { listProDesign, getProDesign } from "@/api/earlyStage/preDesign";
import { getAreasData } from "@/api/areas/index"; import { getAreasData } from "@/api/areas/index";
import { regionData, codeToText, TextToCode } from "element-china-area-data"; import { regionData, codeToText, TextToCode } from "element-china-area-data";
@ -733,6 +734,36 @@ export default {
sort: "desc", sort: "desc",
}, },
}, },
proQueryParams: {
pageNum: 1,
pageSize: 10,
ids: null,
data: {
projectName: null,
constructionNature: null,
constructionLocation: null,
projectUnitName: null,
briefIntroduction: null,
projectLandSituation: null,
designEstimateReport: null,
relatedAttachment: null,
projectCode: null,
proNo: null,
createUid: null,
createTime: null,
updateUid: null,
updateTime: null,
owerDept: null,
},
cv: {},
//
params: {
//
orderBy: "create_time",
// descasc
sortBy: "desc",
},
},
// //
form: {}, form: {},
copyForm: {}, copyForm: {},
@ -1067,7 +1098,7 @@ export default {
}, },
getId(res) { getId(res) {
// console.log(res) // console.log(res)
getProposal(res.id).then((response) => { getProDesign(res.id).then((response) => {
// console.log(response.data) // console.log(response.data)
this.proNo = response.data.proNo; this.proNo = response.data.proNo;
this.proCode = response.data.projectCode; this.proCode = response.data.projectCode;
@ -1146,7 +1177,7 @@ export default {
this.reset(); this.reset();
this.form = { ...this.proMsg }; this.form = { ...this.proMsg };
if (this.form) { if (this.form) {
listProposal(this.queryParams).then((response) => { listProDesign(this.proQueryParams).then((response) => {
this.projectNameOptions = response.records; this.projectNameOptions = response.records;
}); });
} }

482
jwtech-admin-page/src/views/evaluationEarlyWarning/supervisionInspection/regulatoryInspection/editPart.vue

@ -0,0 +1,482 @@
<template>
<div>
<div style="text-align: right; margin-bottom: 10px">
<el-button
type="primary"
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['warn:rectification:add']"
>新增整改通知书</el-button
>
</div>
<el-table v-loading="loading" border :data="rectificationList">
<el-table-column
label="序号"
type="index"
width="50"
align="center"
fixed
/>
<!-- <el-table-column
label="监管id"
align="center"
prop="inspectionId"
min-width="120"
/> -->
<el-table-column
label="发文单位"
align="center"
prop="issuingUnit"
min-width="120"
/>
<el-table-column
label="文号"
align="center"
prop="documentNumber"
min-width="120"
/>
<el-table-column
label="通知生效时间"
align="center"
prop="noticeBegainTime"
min-width="120"
>
<template slot-scope="scope">
<span>{{
parseTime(scope.row.noticeBegainTime, "{y}-{m}-{d}")
}}</span>
</template>
</el-table-column>
<el-table-column
label="整改通知书"
align="center"
prop="rectificationAttachment"
min-width="120"
>
<template slot-scope="scope">
<div
v-for="(item, index) in JSON.parse(
scope.row.rectificationAttachment
)"
:key="item + index"
>
<i class="el-icon-document"></i>
{{ item.name }}
<i
class="el-icon-download"
@click="downloadFile(scope.row.rectificationAttachment, index)"
style="cursor: pointer"
></i>
</div>
</template>
</el-table-column>
<el-table-column
label="责任单位"
align="center"
prop="aa"
min-width="120"
/>
<el-table-column
label="整改完成情况"
align="center"
prop="bbb"
min-width="120"
/>
<el-table-column
label="整改相关附件"
align="center"
prop="ccc"
min-width="120"
/>
<el-table-column
label="信用修复状态"
align="center"
prop="dddd"
min-width="120"
/>
<el-table-column
label="操作"
align="center"
class-name="small-padding fixed-width"
width="180"
fixed="right"
>
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['warn:rectification:edit']"
>修改</el-button
>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['warn:rectification:remove']"
>删除</el-button
>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total > 0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改整改通知书对话框 -->
<el-dialog
:title="title"
:visible.sync="open"
width="1200px"
append-to-body
:close-on-click-modal="false"
>
<el-form ref="form" :model="form" :rules="rules" label-width="110px">
<!-- <el-form-item label="监管id" prop="inspectionId">
<el-input v-model="form.inspectionId" placeholder="请输入监管id" />
</el-form-item> -->
<el-form-item label="发文单位" prop="issuingUnit">
<el-input v-model="form.issuingUnit" placeholder="请输入发文单位" />
</el-form-item>
<el-form-item label="文号" prop="documentNumber">
<el-input v-model="form.documentNumber" placeholder="请输入文号" />
</el-form-item>
<el-form-item label="通知生效时间" prop="noticeBegainTime">
<el-date-picker
clearable
size="small"
style="width: 100%"
v-model="form.noticeBegainTime"
type="date"
value-format="yyyy-MM-dd"
placeholder="选择通知生效时间"
>
</el-date-picker>
</el-form-item>
<el-form-item label="整改通知书" prop="rectificationAttachment">
<!-- <el-input v-model="form.rectificationAttachment" placeholder="请输入整改通知书" /> -->
<el-upload
class="upload-demo"
action="thinking/common/upload"
:headers="headers"
:on-preview="handlePreview"
:on-remove="(file) => handleOpinionRemove(file, 'fileList1')"
:before-remove="beforeRemove"
multiple
:on-exceed="handleExceed"
:on-success="
(_, fileList) => submitOpinionUpload(fileList, 'fileList1')
"
:file-list="fileList1"
>
<el-button size="small" type="primary" plain>
<i class="el-icon-upload el-icon--right"></i>
点击上传
</el-button>
<div slot="tip" class="el-upload__tip">
支持jpg/png/pdf/word/excel文件等不超过100M
</div>
</el-upload>
</el-form-item>
</el-form>
<responsibleUnit />
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import {
listRectification,
getRectification,
delRectification,
addRectification,
updateRectification,
exportRectification,
} from "@/api/warn/rectification";
import { getToken } from "@/utils/auth";
import { getFileStream } from "@/api/system/upload";
import responsibleUnit from "./responsibleUnit.vue";
export default {
name: "Rectification",
props: ["inspectionId"],
components: {
responsibleUnit,
},
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
rectificationList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
ids: null,
data: {
inspectionId: null,
issuingUnit: null,
documentNumber: null,
noticeBegainTime: null,
rectificationAttachment: null,
createUid: null,
updateUid: null,
owerDept: null,
},
//
params: {
//
orderBy: "create_time",
// descasc
sortBy: "desc",
},
},
//
form: {},
//
rules: {},
//
headers: {
jianwei: "jwtech " + getToken(),
},
fileList1: [],
};
},
created() {
this.getList();
},
methods: {
/** 查询整改通知书列表 */
getList() {
this.loading = true;
listRectification(this.queryParams).then((response) => {
this.rectificationList = response.records;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: null,
inspectionId: null,
issuingUnit: null,
documentNumber: null,
noticeBegainTime: null,
rectificationAttachment: null,
createTime: null,
createUid: null,
updateUid: null,
updateTime: null,
owerDept: null,
remark: null,
};
this.resetForm("form");
},
//
resetQueryForm() {
this.queryParams = {
pageNum: 1,
pageSize: 10,
data: {
id: null,
inspectionId: null,
issuingUnit: null,
documentNumber: null,
noticeBegainTime: null,
rectificationAttachment: null,
createTime: null,
createUid: null,
updateUid: null,
updateTime: null,
owerDept: null,
remark: null,
},
//
params: {
//
orderBy: "create_time",
// descasc
sortBy: "desc",
},
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetQueryForm();
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map((item) => item.id);
this.single = selection.length !== 1;
this.multiple = !selection.length;
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加整改通知书";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const id = row.id || this.ids;
getRectification(id).then((response) => {
this.form = response.data;
if (this.form.rectificationAttachment) {
this.fileList1 = JSON.parse(this.form.rectificationAttachment);
}
this.open = true;
this.title = "修改整改通知书";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate((valid) => {
if (valid) {
this.form.rectificationAttachment = JSON.stringify(this.fileList1);
if (this.form.id != null) {
updateRectification(this.form).then((response) => {
if (response.code === 200) {
this.msgSuccess("修改成功");
this.open = false;
this.getList();
}
});
} else {
this.form.inspectionId = this.inspectionId;
addRectification(this.form).then((response) => {
if (response.code === 200) {
this.msgSuccess("新增成功");
this.open = false;
this.getList();
}
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
if (ids) {
this.$confirm("是否删除选中的数据?", "警告", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(function () {
return delRectification(ids);
})
.then(() => {
this.getList();
this.msgSuccess("删除成功");
})
.catch(function () {});
} else {
this.$message.warning("请选择要删除的数据!!");
}
},
//
submitOpinionUpload(fileList, name) {
console.log(name, fileList);
this[name].push({
name: fileList.name,
fileName: fileList.response.fileName,
url: fileList.response.url,
uid: fileList.uid,
});
console.log(name, this[name]);
},
handleOpinionRemove(file, name) {
// console.log(file, fileList1);
let index = this[name].findIndex((item) => item.uid === file.uid);
//
this[name].splice(index, 1);
},
//
downloadFile(fileList, index) {
console.log(fileList);
let file = JSON.parse(fileList)[index];
this.handlePreview(file);
},
//
handlePreview(file) {
// console.log(file);
getFileStream({ fileName: file.fileName }).then((res) => {
const blob = new Blob([res], {
// type
// application/xlsx application/zip
type: "application/xlsx",
}); //excel,pdf
const href = URL.createObjectURL(blob); //URLblob
const a = document.createElement("a"); //a
a.style.display = "none";
a.href = href; //
a.download = file.name; //
a.click(); //
URL.revokeObjectURL(a.href); //URL
});
},
handleExceed(files, fileList) {
this.$message.warning(
`当前限制选择 3 个文件,本次选择了 ${files.length} 个文件,共选择了 ${
files.length + fileList.length
} 个文件`
);
},
beforeRemove(file, fileList) {
return this.$confirm(`确定移除 ${file.name}`);
},
},
};
</script>
<style lang="scss" scoped>
@import "@/assets/css/dialog.scss";
//::v-deep {
// .el-dialog {
// margin-top: 10vh !important;
// }
//}
</style>

435
jwtech-admin-page/src/views/evaluationEarlyWarning/supervisionInspection/regulatoryInspection/index.vue

@ -1,5 +1,14 @@
<template> <template>
<div class="app-container"> <div class="app-container">
<!-- 面包屑 -->
<el-breadcrumb separator="/" style="margin-bottom: 20px">
<el-breadcrumb-item
v-for="(item, index) in routeList"
:key="item + index"
:to="{ path: item.path }"
>{{ item.routeName }}</el-breadcrumb-item
>
</el-breadcrumb>
<el-form <el-form
:model="queryParams" :model="queryParams"
ref="queryForm" ref="queryForm"
@ -7,6 +16,23 @@
v-show="showSearch" v-show="showSearch"
label-width="68px" label-width="68px"
> >
<el-form-item label="项目名称" prop="projectName">
<el-input
v-model="queryParams.data.projectName"
placeholder="请输入项目名称"
clearable
size="small"
@keyup.enter.native="handleQuery"
>
<el-button
type="primary"
slot="append"
icon="el-icon-search"
size="small"
@click="handleQuery"
></el-button>
</el-input>
</el-form-item>
<el-form-item <el-form-item
label="监督检查类型" label="监督检查类型"
prop="inspectionTypes" prop="inspectionTypes"
@ -27,19 +53,6 @@
/> />
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="检查时间" prop="inspectionTime">
<el-date-picker
clearable
size="small"
style="width: 200px"
v-model="queryParams.inspectionTime"
type="date"
value-format="yyyy-MM-dd"
placeholder="选择检查时间"
@change="handleQuery"
>
</el-date-picker>
</el-form-item>
<el-form-item> <el-form-item>
<!-- <el-button <!-- <el-button
@ -108,7 +121,12 @@
align="center" align="center"
fixed fixed
/> />
<el-table-column
label="项目名称"
align="center"
prop="projectName"
min-width="120"
/>
<el-table-column <el-table-column
label="监督检查类型" label="监督检查类型"
align="center" align="center"
@ -132,24 +150,70 @@
prop="inspectionPerson" prop="inspectionPerson"
min-width="120" min-width="120"
/> />
<el-table-column <el-table-column
label="通知文件" label="通知文件"
align="center" align="center"
prop="noticeAttachment" prop="noticeAttachment"
min-width="120" min-width="120"
/> >
<template slot-scope="scope">
<div
v-for="(item, index) in JSON.parse(scope.row.noticeAttachment)"
:key="item + index"
>
<i class="el-icon-document"></i>
{{ item.name }}
<i
class="el-icon-download"
@click="downloadFile(scope.row.noticeAttachment, index)"
style="cursor: pointer"
></i>
</div>
</template>
</el-table-column>
<el-table-column <el-table-column
label="检查表" label="检查表"
align="center" align="center"
prop="checklist" prop="checklist"
min-width="120" min-width="120"
/> >
<template slot-scope="scope">
<div
v-for="(item, index) in JSON.parse(scope.row.checklist)"
:key="item + index"
>
<i class="el-icon-document"></i>
{{ item.name }}
<i
class="el-icon-download"
@click="downloadFile(scope.row.checklist, index)"
style="cursor: pointer"
></i>
</div>
</template>
</el-table-column>
<el-table-column <el-table-column
label="整改报告" label="整改报告"
align="center" align="center"
prop="rectificationReport" prop="rectificationReport"
min-width="120" min-width="120"
/> >
<template slot-scope="scope">
<div
v-for="(item, index) in JSON.parse(scope.row.rectificationReport)"
:key="item + index"
>
<i class="el-icon-document"></i>
{{ item.name }}
<i
class="el-icon-download"
@click="downloadFile(scope.row.rectificationReport, index)"
style="cursor: pointer"
></i>
</div>
</template>
</el-table-column>
<el-table-column <el-table-column
label="操作" label="操作"
align="center" align="center"
@ -190,11 +254,33 @@
<el-dialog <el-dialog
:title="title" :title="title"
:visible.sync="open" :visible.sync="open"
width="1200px" width="1400px"
append-to-body append-to-body
:close-on-click-modal="false" :close-on-click-modal="false"
> >
<div class="listTitle" style="margin-top: 0">
<span>监管检查信息</span>
</div>
<el-form ref="form" :model="form" :rules="rules" label-width="110px"> <el-form ref="form" :model="form" :rules="rules" label-width="110px">
<el-form-item label="项目名称" prop="proNo">
<el-select
v-model="form.projectName"
placeholder="请输入项目名称"
filterable
clearable
size="small"
style="width: 100%"
>
<el-option
v-for="dict in projectNameOptions"
:key="dict.projectName + dict.id"
:label="dict.projectName + '[' + dict.proCode + ']'"
:value="dict.projectName + '[' + dict.proCode + ']'"
@click.native="getId(dict)"
/>
</el-select>
</el-form-item>
<el-form-item label="监督检查类型" prop="inspectionTypes"> <el-form-item label="监督检查类型" prop="inspectionTypes">
<el-select <el-select
v-model="form.inspectionTypes" v-model="form.inspectionTypes"
@ -221,28 +307,109 @@
> >
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
<el-form-item label="检查人" prop="inspectionPerson"> <el-form-item label="检查人" prop="inspectionPerson">
<el-input <el-input
v-model="form.inspectionPerson" v-model="form.inspectionPerson"
placeholder="请输入检查人" placeholder="请输入检查人"
/> />
</el-form-item> </el-form-item>
<el-form-item label="通知文件" prop="noticeAttachment"> <el-row>
<el-input <el-col :span="8">
<el-form-item label="通知文件" prop="noticeAttachment">
<!-- <el-input
v-model="form.noticeAttachment" v-model="form.noticeAttachment"
placeholder="请输入通知文件" placeholder="请输入通知文件"
/> /> -->
</el-form-item> <el-upload
<el-form-item label="检查表" prop="checklist"> class="upload-demo"
<el-input v-model="form.checklist" placeholder="请输入检查表" /> action="thinking/common/upload"
</el-form-item> :headers="headers"
<el-form-item label="整改报告" prop="rectificationReport"> :on-preview="handlePreview"
<el-input :on-remove="(file) => handleOpinionRemove(file, 'fileList1')"
:before-remove="beforeRemove"
multiple
:on-exceed="handleExceed"
:on-success="
(_, fileList) => submitOpinionUpload(fileList, 'fileList1')
"
:file-list="fileList1"
>
<el-button size="small" type="primary" plain>
<i class="el-icon-upload el-icon--right"></i>
点击上传
</el-button>
<div slot="tip" class="el-upload__tip">
支持jpg/png/pdf/word/excel文件等不超过100M
</div>
</el-upload>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="检查表" prop="checklist">
<!-- <el-input v-model="form.checklist" placeholder="请输入检查表" /> -->
<el-upload
class="upload-demo"
action="thinking/common/upload"
:headers="headers"
:on-preview="handlePreview"
:on-remove="(file) => handleOpinionRemove(file, 'fileList2')"
:before-remove="beforeRemove"
multiple
:on-exceed="handleExceed"
:on-success="
(_, fileList) => submitOpinionUpload(fileList, 'fileList2')
"
:file-list="fileList2"
>
<el-button size="small" type="primary" plain>
<i class="el-icon-upload el-icon--right"></i>
点击上传
</el-button>
<div slot="tip" class="el-upload__tip">
支持jpg/png/pdf/word/excel文件等不超过100M
</div>
</el-upload>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="整改报告" prop="rectificationReport">
<!-- <el-input
v-model="form.rectificationReport" v-model="form.rectificationReport"
placeholder="请输入整改报告" placeholder="请输入整改报告"
/> /> -->
</el-form-item> <el-upload
class="upload-demo"
action="thinking/common/upload"
:headers="headers"
:on-preview="handlePreview"
:on-remove="(file) => handleOpinionRemove(file, 'fileList3')"
:before-remove="beforeRemove"
multiple
:on-exceed="handleExceed"
:on-success="
(_, fileList) => submitOpinionUpload(fileList, 'fileList3')
"
:file-list="fileList3"
>
<el-button size="small" type="primary" plain>
<i class="el-icon-upload el-icon--right"></i>
点击上传
</el-button>
<div slot="tip" class="el-upload__tip">
支持jpg/png/pdf/word/excel文件等不超过100M
</div>
</el-upload>
</el-form-item>
</el-col>
</el-row>
</el-form> </el-form>
<div v-if="form.id">
<div class="listTitle" style="margin-top: 0">
<span>责令限期整改通知书列表</span>
</div>
<editPart :inspectionId="form.id" />
</div>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button> <el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button> <el-button @click="cancel"> </el-button>
@ -260,9 +427,16 @@ import {
updateInspections, updateInspections,
exportInspections, exportInspections,
} from "@/api/warn/inspections"; } from "@/api/warn/inspections";
import { listInfo, getInfo } from "@/api/build/projectInfo";
import { getToken } from "@/utils/auth";
import { getFileStream } from "@/api/system/upload";
import editPart from "./editPart.vue";
export default { export default {
name: "Inspections", name: "Inspections",
components: {
editPart,
},
data() { data() {
return { return {
// //
@ -285,6 +459,7 @@ export default {
open: false, open: false,
// //
inspectionTypesOptions: [], inspectionTypesOptions: [],
// //
queryParams: { queryParams: {
pageNum: 1, pageNum: 1,
@ -311,10 +486,80 @@ export default {
sortBy: "desc", sortBy: "desc",
}, },
}, },
//
othersParams: {
pageNum: 1,
pageSize: 10,
ids: null,
data: {
isMajor: null,
projectName: null,
unitLeader: null,
projectLegalPerson: null,
projectLegalUnit: null,
projectLegalPhone: null,
engineeringGrade: null,
engineeringPurposes: null,
workCategory: null,
constructionAddress: null,
constructionMode: null,
constructionNature: null,
constructionContent: null,
adcd: null,
basin: null,
projectType: null,
centralArrangedFunds: null,
centralArrangedFundsRate: null,
provincialFunding: null,
provincialFundingRate: null,
cityLevelFunds: null,
cityLevelFundsRate: null,
countyLevelFunds: null,
countyLevelFundsRate: null,
townshipInvestments: null,
townshipInvestmentsRate: null,
isMajorProject: null,
investmentSubject: null,
constructionPhase: null,
fundingNumber: null,
proCode: null,
proNo: null,
createUid: null,
createTime: null,
updateUid: null,
updateTime: null,
owerDept: null,
},
//
params: {
//
orderBy: "create_time",
// descasc
sortBy: "desc",
},
},
// //
form: {}, form: {},
// //
rules: {}, rules: {},
//
projectNameOptions: [],
proCode: "",
proNo: "",
//
routeList: [
{
path: "/evaluationEarlyWarning/supervisionInspection/regulatoryInspection",
routeName: "项目监管检查与评价",
},
],
//
headers: {
jianwei: "jwtech " + getToken(),
},
fileList1: [],
fileList2: [],
fileList3: [],
}; };
}, },
created() { created() {
@ -322,8 +567,20 @@ export default {
this.getDicts("supervisory_inspection_type").then((response) => { this.getDicts("supervisory_inspection_type").then((response) => {
this.inspectionTypesOptions = response.data; this.inspectionTypesOptions = response.data;
}); });
listInfo(this.othersParams).then((response) => {
this.projectNameOptions = response.records;
});
}, },
methods: { methods: {
getId(res) {
// console.log(res)
getInfo(res.id).then((response) => {
console.log(response.data);
this.proNo = response.data.proNo;
this.proCode = response.data.proCode;
});
},
/** 查询监管检查列表 */ /** 查询监管检查列表 */
getList() { getList() {
this.loading = true; this.loading = true;
@ -426,6 +683,17 @@ export default {
const id = row.id || this.ids; const id = row.id || this.ids;
getInspections(id).then((response) => { getInspections(id).then((response) => {
this.form = response.data; this.form = response.data;
this.form.projectName =
this.form.projectName + "[" + this.form.proCode + "]";
if (this.form.noticeAttachment) {
this.fileList1 = JSON.parse(this.form.noticeAttachment);
}
if (this.form.checklist) {
this.fileList2 = JSON.parse(this.form.checklist);
}
if (this.form.rectificationReport) {
this.fileList3 = JSON.parse(this.form.rectificationReport);
}
this.open = true; this.open = true;
this.title = "修改监管检查"; this.title = "修改监管检查";
}); });
@ -434,6 +702,15 @@ export default {
submitForm() { submitForm() {
this.$refs["form"].validate((valid) => { this.$refs["form"].validate((valid) => {
if (valid) { if (valid) {
if (this.proNo) {
this.form.proNo = this.proNo;
}
if (this.proCode) {
this.form.proCode = this.proCode;
}
this.form.noticeAttachment = JSON.stringify(this.fileList1);
this.form.checklist = JSON.stringify(this.fileList2);
this.form.rectificationReport = JSON.stringify(this.fileList3);
if (this.form.id != null) { if (this.form.id != null) {
updateInspections(this.form).then((response) => { updateInspections(this.form).then((response) => {
if (response.code === 200) { if (response.code === 200) {
@ -475,27 +752,56 @@ export default {
this.$message.warning("请选择要删除的数据!!"); this.$message.warning("请选择要删除的数据!!");
} }
}, },
/** 导出按钮操作 */ //
handleExport() { submitOpinionUpload(fileList, name) {
const queryParams = this.queryParams; console.log(name, fileList);
let message = "是否确认导出所有的数据项?"; this[name].push({
if (this.ids) { name: fileList.name,
message = "是否确认导出选中的数据项?"; fileName: fileList.response.fileName,
queryParams.ids = this.ids; url: fileList.response.url,
} uid: fileList.uid,
this.$confirm(message, "警告", { });
confirmButtonText: "确定", console.log(name, this[name]);
cancelButtonText: "取消", },
type: "warning", handleOpinionRemove(file, name) {
}) // console.log(file, fileList1);
.then(function () { let index = this[name].findIndex((item) => item.uid === file.uid);
return exportInspections(queryParams); //
}) this[name].splice(index, 1);
.then((response) => { },
this.downloadFile(response, true, response.msg); //
// this.download(response.msg); downloadFile(fileList, index) {
}) console.log(fileList);
.catch(function () {}); let file = JSON.parse(fileList)[index];
this.handlePreview(file);
},
//
handlePreview(file) {
// console.log(file);
getFileStream({ fileName: file.fileName }).then((res) => {
const blob = new Blob([res], {
// type
// application/xlsx application/zip
type: "application/xlsx",
}); //excel,pdf
const href = URL.createObjectURL(blob); //URLblob
const a = document.createElement("a"); //a
a.style.display = "none";
a.href = href; //
a.download = file.name; //
a.click(); //
URL.revokeObjectURL(a.href); //URL
});
},
handleExceed(files, fileList) {
this.$message.warning(
`当前限制选择 3 个文件,本次选择了 ${files.length} 个文件,共选择了 ${
files.length + fileList.length
} 个文件`
);
},
beforeRemove(file, fileList) {
return this.$confirm(`确定移除 ${file.name}`);
}, },
}, },
}; };
@ -503,9 +809,28 @@ export default {
<style lang="scss" scoped> <style lang="scss" scoped>
@import "@/assets/css/dialog.scss"; @import "@/assets/css/dialog.scss";
//::v-deep { ::v-deep {
// .el-dialog { .el-dialog {
// margin-top: 10vh !important; margin-top: 10vh !important;
// } }
//} }
.listTitle {
font-size: 14px;
padding-left: 10px;
padding-right: 30px;
margin: 20px 0;
border-left: 2px solid #36b29e;
display: flex;
justify-content: space-between;
span:nth-child(1) {
font-weight: bold;
}
.addBtn {
color: #36b29e;
cursor: pointer;
}
.addBtn:hover {
color: #31a08e;
}
}
</style> </style>

427
jwtech-admin-page/src/views/evaluationEarlyWarning/supervisionInspection/regulatoryInspection/responsibleUnit.vue

@ -0,0 +1,427 @@
<template>
<div class="app-container">
<!-- <el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="primary"
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['warn:zrdw:add']"
>新增</el-button
>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
icon="el-icon-edit"
size="mini"
:disabled="single"
@click="handleUpdate"
v-hasPermi="['warn:zrdw:edit']"
>修改</el-button
>
</el-col>
<el-col :span="1.5">
<el-button
type="danger"
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleDelete"
v-hasPermi="['warn:zrdw:remove']"
>删除</el-button
>
</el-col>
<el-col :span="1.5">
<el-button
type="warning"
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['warn:zrdw:export']"
>导出</el-button
>
</el-col>
<right-toolbar
:showSearch.sync="showSearch"
@queryTable="getList"
></right-toolbar>
</el-row> -->
<el-table
v-loading="loading"
:data="zrdwList"
@selection-change="handleSelectionChange"
>
<el-table-column type="selection" width="55" align="center" fixed />
<el-table-column
label="序号"
type="index"
width="50"
align="center"
fixed
/>
<el-table-column
label="监管id"
align="center"
prop="inspectionId"
min-width="120"
/>
<el-table-column
label="单位id"
align="center"
prop="unitId"
min-width="120"
/>
<el-table-column
label="整改情况"
align="center"
prop="rectificationSituation"
min-width="120"
/>
<el-table-column
label="附件"
align="center"
prop="attachment"
min-width="120"
/>
<el-table-column
label="附件"
align="center"
prop="createUid"
min-width="120"
/>
<el-table-column
label="附件"
align="center"
prop="updateUid"
min-width="120"
/>
<el-table-column
label="附件"
align="center"
prop="owerDept"
min-width="120"
/>
<el-table-column
label="附件"
align="center"
prop="remark"
min-width="120"
/>
<el-table-column
label="操作"
align="center"
class-name="small-padding fixed-width"
width="180"
fixed="right"
>
<template slot-scope="scope">
<el-button
size="mini"
type="text"
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['warn:zrdw:edit']"
>修改</el-button
>
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['warn:zrdw:remove']"
>删除</el-button
>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total > 0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
<!-- 添加或修改责任单位对话框 -->
<el-dialog
:title="title"
:visible.sync="open"
width="1200px"
append-to-body
:close-on-click-modal="false"
>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="监管id" prop="inspectionId">
<el-input v-model="form.inspectionId" placeholder="请输入监管id" />
</el-form-item>
<el-form-item label="单位id" prop="unitId">
<el-input v-model="form.unitId" placeholder="请输入单位id" />
</el-form-item>
<el-form-item label="整改情况" prop="rectificationSituation">
<el-input
v-model="form.rectificationSituation"
placeholder="请输入整改情况"
/>
</el-form-item>
<el-form-item label="附件" prop="attachment">
<el-input v-model="form.attachment" placeholder="请输入附件" />
</el-form-item>
<el-form-item label="附件" prop="createUid">
<el-input v-model="form.createUid" placeholder="请输入附件" />
</el-form-item>
<el-form-item label="附件" prop="updateUid">
<el-input v-model="form.updateUid" placeholder="请输入附件" />
</el-form-item>
<el-form-item label="附件" prop="owerDept">
<el-input v-model="form.owerDept" placeholder="请输入附件" />
</el-form-item>
<el-form-item label="附件" prop="remark">
<el-input v-model="form.remark" placeholder="请输入附件" />
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm"> </el-button>
<el-button @click="cancel"> </el-button>
</div>
</el-dialog>
</div>
</template>
<script>
import {
listZrdw,
getZrdw,
delZrdw,
addZrdw,
updateZrdw,
exportZrdw,
} from "@/api/warn/zrdw";
export default {
name: "Zrdw",
data() {
return {
//
loading: true,
//
ids: [],
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
zrdwList: [],
//
title: "",
//
open: false,
//
queryParams: {
pageNum: 1,
pageSize: 10,
ids: null,
data: {
inspectionId: null,
unitId: null,
rectificationSituation: null,
attachment: null,
createUid: null,
updateUid: null,
owerDept: null,
},
//
params: {
//
orderBy: "create_time",
// descasc
sortBy: "desc",
},
},
//
form: {},
//
rules: {},
};
},
created() {
this.getList();
},
methods: {
/** 查询责任单位列表 */
getList() {
this.loading = true;
listZrdw(this.queryParams).then((response) => {
this.zrdwList = response.records;
this.total = response.total;
this.loading = false;
});
},
//
cancel() {
this.open = false;
this.reset();
},
//
reset() {
this.form = {
id: null,
inspectionId: null,
unitId: null,
rectificationSituation: null,
attachment: null,
createUid: null,
updateUid: null,
createTime: null,
updateTime: null,
owerDept: null,
remark: null,
};
this.resetForm("form");
},
//
resetQueryForm() {
this.queryParams = {
pageNum: 1,
pageSize: 10,
data: {
id: null,
inspectionId: null,
unitId: null,
rectificationSituation: null,
attachment: null,
createUid: null,
updateUid: null,
createTime: null,
updateTime: null,
owerDept: null,
remark: null,
},
//
params: {
//
orderBy: "create_time",
// descasc
sortBy: "desc",
},
};
this.resetForm("form");
},
/** 搜索按钮操作 */
handleQuery() {
this.queryParams.pageNum = 1;
this.getList();
},
/** 重置按钮操作 */
resetQuery() {
this.resetQueryForm();
this.handleQuery();
},
//
handleSelectionChange(selection) {
this.ids = selection.map((item) => item.id);
this.single = selection.length !== 1;
this.multiple = !selection.length;
},
/** 新增按钮操作 */
handleAdd() {
this.reset();
this.open = true;
this.title = "添加责任单位";
},
/** 修改按钮操作 */
handleUpdate(row) {
this.reset();
const id = row.id || this.ids;
getZrdw(id).then((response) => {
this.form = response.data;
this.open = true;
this.title = "修改责任单位";
});
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate((valid) => {
if (valid) {
if (this.form.id != null) {
updateZrdw(this.form).then((response) => {
if (response.code === 200) {
this.msgSuccess("修改成功");
this.open = false;
this.getList();
}
});
} else {
addZrdw(this.form).then((response) => {
if (response.code === 200) {
this.msgSuccess("新增成功");
this.open = false;
this.getList();
}
});
}
}
});
},
/** 删除按钮操作 */
handleDelete(row) {
const ids = row.id || this.ids;
if (ids) {
this.$confirm("是否删除选中的数据?", "警告", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(function () {
return delZrdw(ids);
})
.then(() => {
this.getList();
this.msgSuccess("删除成功");
})
.catch(function () {});
} else {
this.$message.warning("请选择要删除的数据!!");
}
},
/** 导出按钮操作 */
handleExport() {
const queryParams = this.queryParams;
let message = "是否确认导出所有的数据项?";
if (this.ids) {
message = "是否确认导出选中的数据项?";
queryParams.ids = this.ids;
}
this.$confirm(message, "警告", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
})
.then(function () {
return exportZrdw(queryParams);
})
.then((response) => {
this.downloadFile(response, true, response.msg);
// this.download(response.msg);
})
.catch(function () {});
},
},
};
</script>
<style lang="scss" scoped>
@import "@/assets/css/dialog.scss";
//::v-deep {
// .el-dialog {
// margin-top: 10vh !important;
// }
//}
</style>
Loading…
Cancel
Save