+
+
所属流域
-
+
工程类型
+
行政区划
+
监督检查任务
@@ -319,54 +310,35 @@ export default {
width: 100%;
min-height: calc(100vh - 56px - 64px);
margin-top: 24px;
- padding: 16px;
background-color: white;
- .title {
- padding-left: 20px;
- position: relative;
- &::before {
- position: absolute;
- left: 0;
- top: 0;
- content: "";
- width: 4px;
- height: 16px;
- background-color: #1890ff;
+ .title-box {
+ padding: 16px;
+ border-bottom: 1px solid #f0f0f0;
+ .title {
+ padding-left: 20px;
+ position: relative;
+ &::before {
+ position: absolute;
+ left: 0;
+ top: 0;
+ content: "";
+ width: 4px;
+ height: 16px;
+ background-color: #1890ff;
+ }
}
}
- .select-box {
- border: 1px solid #d9d9d9;
- border-radius: 4px;
- padding: 8px;
- }
.question-box {
display: flex;
flex-wrap: wrap;
- padding-top: 24px;
- }
- .question-item {
- width: 250px;
- height: 102px;
- border-radius: 8px;
- border: 1px solid #000;
- padding: 10px;
- margin-right: 10px;
- margin-bottom: 12px;
+ padding: 24px;
+ .question-item {
+ flex: 1;
+ min-width: 250px;
+ margin-right: 10px;
+ margin-bottom: 12px;
+ }
}
}
}
-
diff --git a/src/views/dike/runManage/superVisionInspetion/tasksManage/tasksDetails.vue b/src/views/dike/runManage/superVisionInspetion/tasksManage/tasksDetails.vue
index 3f161d0..8a0c3f7 100644
--- a/src/views/dike/runManage/superVisionInspetion/tasksManage/tasksDetails.vue
+++ b/src/views/dike/runManage/superVisionInspetion/tasksManage/tasksDetails.vue
@@ -414,8 +414,9 @@ export default {
.content-box {
width: 100%;
- min-height: calc(100vh - 56px - 64px);
+ height: calc(100vh - 56px - 64px);
margin-top: 24px;
+ overflow: auto;
padding: 16px;
background-color: white;
.title {
diff --git a/src/views/sluice/runManage/supervisionInspetion/projectManage/projectReport.vue b/src/views/sluice/runManage/supervisionInspetion/projectManage/projectReport.vue
index 1a1c670..a753302 100644
--- a/src/views/sluice/runManage/supervisionInspetion/projectManage/projectReport.vue
+++ b/src/views/sluice/runManage/supervisionInspetion/projectManage/projectReport.vue
@@ -41,7 +41,6 @@ export default {
}, 0)
);
}, 0);
- console.log("hasDoneLevel >>>>> ", hasDoneLevel);
return Math.floor((hasDoneLevel / sum) * 100);
} else {
return 0;
@@ -100,10 +99,17 @@ export default {
id: item.id,
projectId: item.projectId,
projectName: item.projectName,
- problemDescribe: "",
- siteSituationRecords: "",
- siteSituationRecordsArr: [],
- children: [{ ...item, level: null }],
+
+ children: [
+ {
+ ...item,
+ projectItemId: item.id,
+ problemDescribe: "",
+ siteSituationRecords: "",
+ siteSituationRecordsArr: [],
+ level: null,
+ },
+ ],
});
} else {
let exitItem = list.find((v) => v.projectId === item.projectId);
@@ -112,14 +118,25 @@ export default {
id: item.id,
projectId: item.projectId,
projectName: item.projectName,
- problemDescribe: "",
- siteSituationRecords: "",
- siteSituationRecordsArr: [],
- children: [{ ...item, level: null }],
+
+ children: [
+ {
+ ...item,
+ projectItemId: item.id,
+ problemDescribe: "",
+ siteSituationRecords: "",
+ siteSituationRecordsArr: [],
+ level: null,
+ },
+ ],
});
} else {
exitItem.children.push({
...item,
+ projectItemId: item.id,
+ problemDescribe: "",
+ siteSituationRecords: "",
+ siteSituationRecordsArr: [],
level: null,
});
}
@@ -137,29 +154,34 @@ export default {
this.formData.taskId = data.taskId;
this.formData.weather = data.weather;
this.formData.problemList = [];
- const { engineeringList, problemList } = data;
+ const { problemList } = data;
list.forEach((item) => {
- let exitItem = engineeringList.find(
+ let exitItem = problemList?.find(
(v) => v.projectId === item.projectId
);
if (exitItem) {
item.newId = item.id === exitItem.id ? null : exitItem.id;
- item.problemDescribe = exitItem.problemDescribe;
- item.siteSituationRecords = exitItem.siteSituationRecords;
- item.siteSituationRecordsArr = exitItem.siteSituationRecords
- ? exitItem.siteSituationRecords.split(",")
- : [];
+
let itemTemp = cloneDeep(item);
itemTemp.children = [];
-
item.children.forEach((item2) => {
let exitItem2 = problemList.find(
(v) => v.projectItemId === item2.id
);
if (exitItem2) {
itemTemp.children.push(exitItem2);
+ item2.projectName = exitItem2.projectName;
item2.level = exitItem2.level;
item2.newId = item2.id === exitItem2.id ? null : exitItem2.id;
+ item2.problemDescribe = exitItem2.problemDescribe;
+ item2.siteSituationRecords = exitItem2.siteSituationRecords;
+ item2.siteSituationRecordsArr = exitItem2.siteSituationRecords
+ ? exitItem2.siteSituationRecords.split(",")
+ : [];
+ exitItem2.siteSituationRecordsArr =
+ exitItem2.siteSituationRecords
+ ? exitItem2.siteSituationRecords.split(",")
+ : [];
}
});
if (data.state === "1") {
@@ -177,7 +199,6 @@ export default {
},
// 上传前
beforeUpload(e) {
- console.log("beforeUpload >>>>> ", e);
if (this.currentItem.siteSituationRecordsArr?.length >= 99) {
this.$message.warning("最多上传99张图片");
return false;
@@ -190,81 +211,36 @@ export default {
fData.append("file", file);
uploadFileData(fData)
.then((res) => {
- this.currentItem.siteSituationRecordsArr.push(res.url);
+ this.currentItem.siteSituationRecordsArr?.push(res.url);
})
.catch((err) => {
console.log("err >>>>> ", err);
});
},
- // 获取启用的方法配置项
- getEnableSuperviseWayData() {
- getEnableSuperviseWayData({ wayId: this.$route.query.wayId }).then(
- (res) => {
- console.log(res);
- let list = [];
- res.data?.itemList?.forEach((item, index) => {
- if (index === 0) {
- list.push({
- projectId: item.projectId,
- projectName: item.projectName,
- problemDescribe: "",
- siteSituationRecords: "",
- siteSituationRecordsArr: [],
- children: [{ ...item, level: null }],
- });
- } else {
- let exitItem = list.find((v) => v.projectId === item.projectId);
- if (!exitItem) {
- list.push({
- projectId: item.projectId,
- projectName: item.projectName,
- problemDescribe: "",
- siteSituationRecords: "",
- siteSituationRecordsArr: [],
- children: [{ ...item, level: null }],
- });
- } else {
- exitItem.children.push({
- ...item,
- level: null,
- });
- }
- }
- });
- this.problemList = list;
- this.activeName = list[0]?.projectId || "";
- }
- );
- },
// 处理提交数据
dealFormData() {
this.formData.taskId = this.$route.query.id;
this.problemList.forEach((item) => {
- let problemItem = {
- id: item.newId || null,
- levelList: [],
- problemDescribe: item.problemDescribe,
- siteSituationRecords: item.siteSituationRecordsArr.join(",") || "",
- projectId: item.projectId,
- };
if (item.children.length) {
item.children.forEach((item2) => {
- problemItem.levelList.push({
+ let problemItem = {
id: item2.newId || null,
level: item2.level,
- projectItemId: item2.id,
- });
+ problemDescribe: item2.problemDescribe,
+ siteSituationRecords:
+ item2.siteSituationRecordsArr?.join(",") || "",
+ projectId: item2.projectId,
+ projectItemId: item2.projectItemId,
+ };
+ this.formData.problemList.push(problemItem);
});
}
- this.formData.problemList.push(problemItem);
});
return cloneDeep(this.formData);
},
handleSave() {
- console.log("保存");
let data = this.dealFormData();
data.state = "0";
- console.log("data >>>>> ", data);
addSuperviseEngineeringReportData(data).then((res) => {
this.$message({
type: "success",
@@ -277,6 +253,10 @@ export default {
this.$message.warning("检查进度未达到100%,请检查");
return;
}
+ if (!this.formData.patrolUid) {
+ this.$message.warning("请选择巡查人员");
+ return;
+ }
// 二次确认提交
this.$confirm("是否确认提交?", "提示", {
confirmButtonText: "确定",
@@ -286,13 +266,13 @@ export default {
.then(() => {
let data = this.dealFormData();
data.state = "1";
- console.log("data >>>>> ", data);
addSuperviseEngineeringReportData(data).then((res) => {
this.$message({
type: "success",
message: "提交成功",
});
this.formData.state = "1";
+ this.$router.go(-1);
});
})
.catch(() => {});
@@ -411,66 +391,72 @@ export default {
>严重