fix: BUG修改
This commit is contained in:
parent
d20eb904e3
commit
2e792e02fa
@ -290,8 +290,12 @@
|
||||
</el-table-column>
|
||||
<el-table-column prop="question" label="隐患信息">
|
||||
<template #default="{ row }">
|
||||
<el-input v-model="row.question" v-if="row.isEdit" />
|
||||
<span v-else>{{ row.question }}</span>
|
||||
<el-select v-if="row.isEdit" style="width: 100%" v-model="row.question" clearable placeholder="请选择">
|
||||
<el-option label="无隐患" :value="0" />
|
||||
<el-option label="一般隐患" :value="1" />
|
||||
<el-option label="重大隐患" :value="2" />
|
||||
</el-select>
|
||||
<span v-else>{{ row.question == 1 ? "一般隐患" : row.question == 2 ? "重大隐患" : "无隐患" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="solveUser" label="整改人">
|
||||
@ -556,6 +560,10 @@ const confirmAdd = async (row: any, index: any) => {
|
||||
switch (true) {
|
||||
case tabPosition.value < 5 || tabPosition.value == 8:
|
||||
let updateArr = [] as any;
|
||||
if (!requestData.annexName || requestData.fileList.length == 0) {
|
||||
ElMessage.error("请输入名称以及上传附件");
|
||||
break;
|
||||
}
|
||||
requestData.fileList.map(item => {
|
||||
updateArr.push({
|
||||
createTime: item.response.createTime,
|
||||
@ -570,10 +578,10 @@ const confirmAdd = async (row: any, index: any) => {
|
||||
requestData.annexFiles = updateArr;
|
||||
requestData.type = tabPosition.value;
|
||||
delete requestData.fileList;
|
||||
const res = await addOperation[tabPosition.value](requestData);
|
||||
const res = await addOperation[0](requestData);
|
||||
if (res.success) {
|
||||
ElMessage.success("操作成功");
|
||||
listOperation[tabPosition.value]();
|
||||
listOperation[0]();
|
||||
}
|
||||
break;
|
||||
default:
|
||||
@ -600,8 +608,8 @@ const removeEngineeringSingle = async (row: any, index: any) => {
|
||||
if (row.id) {
|
||||
switch (true) {
|
||||
case tabPosition.value < 5 || tabPosition.value == 8:
|
||||
await useHandleData(deleteOperation[tabPosition.value], { id: row.id }, `删除【${row.annexName}】`);
|
||||
listOperation[tabPosition.value]();
|
||||
await useHandleData(deleteOperation[0], { id: row.id }, `删除【${row.annexName}】`);
|
||||
listOperation[0]();
|
||||
break;
|
||||
default:
|
||||
await useHandleData(deleteOperation[tabPosition.value - 4], { id: row.id }, "删除");
|
||||
@ -609,17 +617,17 @@ const removeEngineeringSingle = async (row: any, index: any) => {
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
switch (tabPosition.value) {
|
||||
case 0:
|
||||
switch (true) {
|
||||
case tabPosition.value < 5 || tabPosition.value == 8:
|
||||
arrOne.value.splice(index, 1);
|
||||
break;
|
||||
case 5:
|
||||
case tabPosition.value == 5:
|
||||
arrFive.value.splice(index, 1);
|
||||
break;
|
||||
case 6:
|
||||
case tabPosition.value == 6:
|
||||
arrSeven.value.splice(index, 1);
|
||||
break;
|
||||
case 7:
|
||||
case tabPosition.value == 7:
|
||||
arrEight.value.splice(index, 1);
|
||||
break;
|
||||
default:
|
||||
@ -686,40 +694,64 @@ const addData = () => {
|
||||
console.log(tabPosition.value);
|
||||
switch (true) {
|
||||
case tabPosition.value < 5 || tabPosition.value == 8:
|
||||
arrOne.value.push({
|
||||
annexName: "",
|
||||
fileList: []
|
||||
let findOneItem = arrOne.value.find(item => {
|
||||
return item.insertNew;
|
||||
});
|
||||
if (!findOneItem) {
|
||||
arrOne.value.push({
|
||||
annexName: "",
|
||||
fileList: [],
|
||||
insertNew: true
|
||||
});
|
||||
}
|
||||
break;
|
||||
case tabPosition.value == 5:
|
||||
arrFive.value.push({
|
||||
currentProgress: "",
|
||||
imageUrl: "",
|
||||
// createByName: "",
|
||||
// createTime: "",
|
||||
isEdit: true
|
||||
let findTwoItem = arrFive.value.find(item => {
|
||||
return item.insertNew;
|
||||
});
|
||||
if (!findTwoItem) {
|
||||
arrFive.value.push({
|
||||
currentProgress: "",
|
||||
imageUrl: "",
|
||||
// createByName: "",
|
||||
// createTime: "",
|
||||
isEdit: true,
|
||||
insertNew: true
|
||||
});
|
||||
}
|
||||
break;
|
||||
case tabPosition.value == 6:
|
||||
arrSeven.value.push({
|
||||
inspectResult: "",
|
||||
inspectUser: "",
|
||||
inspectTime: "",
|
||||
question: "",
|
||||
solveUser: "",
|
||||
questionDesc: "",
|
||||
isEdit: true
|
||||
let findThreeItem = arrSeven.value.find(item => {
|
||||
return item.insertNew;
|
||||
});
|
||||
if (!findThreeItem) {
|
||||
arrSeven.value.push({
|
||||
inspectResult: "",
|
||||
inspectUser: "",
|
||||
inspectTime: "",
|
||||
question: "",
|
||||
solveUser: "",
|
||||
questionDesc: "",
|
||||
isEdit: true,
|
||||
insertNew: true
|
||||
});
|
||||
}
|
||||
break;
|
||||
case tabPosition.value == 7:
|
||||
arrEight.value.push({
|
||||
type: null,
|
||||
result: null,
|
||||
state: null,
|
||||
imageUrl: "",
|
||||
acceptTime: "",
|
||||
isEdit: true
|
||||
let findFourItem = arrEight.value.find(item => {
|
||||
return item.insertNew;
|
||||
});
|
||||
if (!findFourItem) {
|
||||
arrEight.value.push({
|
||||
type: null,
|
||||
result: null,
|
||||
state: null,
|
||||
imageUrl: "",
|
||||
acceptTime: "",
|
||||
isEdit: true,
|
||||
insertNew: true
|
||||
});
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
||||
@ -693,6 +693,11 @@ const submitForm = async (formEl: FormInstance | undefined) => {
|
||||
const closeMain = () => {
|
||||
visible.value = false;
|
||||
};
|
||||
const getAnnexDicMainList = async () => {
|
||||
// 起重机械设备附件字典
|
||||
const res = await getDicList({ dictType: "equip_attachment_name" });
|
||||
documentData.value = res.result.map(item => ({ ...item, fileList: [] }));
|
||||
};
|
||||
// 监听父组件的visible,用来简介控制el-dialog的弹框开关,一般是用于开
|
||||
watch(
|
||||
() => props.addDialog,
|
||||
@ -731,6 +736,7 @@ watch(
|
||||
towerPermanentStandard: ""
|
||||
};
|
||||
activeName.value = "first";
|
||||
getAnnexDicMainList();
|
||||
}
|
||||
}
|
||||
);
|
||||
@ -741,9 +747,7 @@ watch(visible, (n, o) => {
|
||||
|
||||
onMounted(async () => {
|
||||
await getTypeDicMainList();
|
||||
// 起重机械设备附件字典
|
||||
const res = await getDicList({ dictType: "equip_attachment_name" });
|
||||
documentData.value = res.result.map(item => ({ ...item, fileList: [] }));
|
||||
await getAnnexDicMainList();
|
||||
});
|
||||
</script>
|
||||
<style scoped lang="scss">
|
||||
|
||||
@ -14,7 +14,12 @@
|
||||
<div class="title">建设监理工作月报</div>
|
||||
<div class="sub-title">
|
||||
<span>第</span>
|
||||
<el-input v-model.number="formData.stage" style="width: 60px; margin: 0 5px" @blur="e => validatorNumber(e, 'stage')" />
|
||||
<el-input
|
||||
maxlength="4"
|
||||
v-model.number="formData.stage"
|
||||
style="width: 60px; margin: 0 5px"
|
||||
@blur="e => validatorNumber(e, 'stage')"
|
||||
/>
|
||||
<span>期</span>
|
||||
</div>
|
||||
<div class="sub-title">{{ engineerData.supervisorEnt }}</div>
|
||||
@ -23,7 +28,7 @@
|
||||
<div class="report-content-part1">
|
||||
<div>
|
||||
<span>致: </span>
|
||||
<el-input v-model="formData.chiefInspectorName" style="width: 150px; margin: 0 5px" />
|
||||
<el-input v-model="formData.chiefInspectorName" maxlength="10" style="width: 150px; margin: 0 5px" />
|
||||
<span>监理工程师</span>
|
||||
</div>
|
||||
<div>
|
||||
@ -51,6 +56,7 @@
|
||||
<span>月份《监理月报》第</span>
|
||||
<el-input
|
||||
v-model.number="formData.stage"
|
||||
maxlength="4"
|
||||
style="width: 60px; margin: 0 5px"
|
||||
@blur="e => validatorNumber(e, 'stage')"
|
||||
/>
|
||||
@ -63,6 +69,7 @@
|
||||
<span>土建专业监理工程师:</span>
|
||||
<el-input
|
||||
class="input-style"
|
||||
maxlength="10"
|
||||
v-model="formData.civilEngineeringPersons"
|
||||
style="width: 500px; margin: 0 5px; border-bottom: 1px solid #ccc"
|
||||
/>
|
||||
@ -71,6 +78,7 @@
|
||||
<span>水暖专业监理工程师:</span>
|
||||
<el-input
|
||||
class="input-style"
|
||||
maxlength="10"
|
||||
v-model="formData.plumbingPersons"
|
||||
style="width: 500px; margin: 0 5px; border-bottom: 1px solid #ccc"
|
||||
/>
|
||||
@ -79,6 +87,7 @@
|
||||
<span>电气专业监理工程师:</span>
|
||||
<el-input
|
||||
class="input-style"
|
||||
maxlength="10"
|
||||
v-model="formData.electricalPersons"
|
||||
style="width: 500px; margin: 0 5px; border-bottom: 1px solid #ccc"
|
||||
/>
|
||||
|
||||
@ -460,16 +460,15 @@ onMounted(() => {});
|
||||
}
|
||||
}
|
||||
&-part4 {
|
||||
@include flex;
|
||||
display: flex;
|
||||
border: 1px solid #dedede;
|
||||
border-top: 0;
|
||||
height: 200px;
|
||||
// height: 200px;
|
||||
> div:nth-child(1) {
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
width: 3%;
|
||||
height: 200px;
|
||||
// height: 200px;
|
||||
border-right: 1px solid #dedede;
|
||||
> span {
|
||||
display: inline-block;
|
||||
@ -479,37 +478,52 @@ onMounted(() => {});
|
||||
}
|
||||
> div:nth-child(2) {
|
||||
width: 97%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
> div {
|
||||
height: 100px;
|
||||
@include flex;
|
||||
display: flex;
|
||||
flex: 1;
|
||||
// height: 100px;
|
||||
// @include flex;
|
||||
> div:nth-child(1) {
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
width: calc(12% + 3px);
|
||||
height: 100%;
|
||||
// height: 100%;
|
||||
border-right: 1px solid #dedede;
|
||||
}
|
||||
> div:nth-child(2) {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
flex: 1;
|
||||
// height: 100%;
|
||||
// border-bottom: 1px solid #dedede;
|
||||
span {
|
||||
word-break: break-all;
|
||||
}
|
||||
}
|
||||
}
|
||||
> div:not(:last-child) {
|
||||
> div:nth-child(1) {
|
||||
border-bottom: 1px solid #dedede;
|
||||
}
|
||||
> div:nth-child(2) {
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
flex: 1;
|
||||
height: 100%;
|
||||
border-bottom: 1px solid #dedede;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
&-part5 {
|
||||
@include flex;
|
||||
display: flex;
|
||||
border: 1px solid #dedede;
|
||||
border-top: 0;
|
||||
height: 500px;
|
||||
// height: 500px;
|
||||
> div:nth-child(1) {
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
width: 3%;
|
||||
height: 100%;
|
||||
// height: 100%;
|
||||
border-right: 1px solid #dedede;
|
||||
> span {
|
||||
display: inline-block;
|
||||
@ -519,15 +533,14 @@ onMounted(() => {});
|
||||
}
|
||||
> div:nth-child(2) {
|
||||
width: 97%;
|
||||
height: 100%;
|
||||
// height: 100%;
|
||||
> div {
|
||||
height: 100px;
|
||||
@include flex;
|
||||
display: flex;
|
||||
> div:nth-child(2n-1) {
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
width: calc(12% + 3px);
|
||||
height: 100%;
|
||||
// height: 100%;
|
||||
border-right: 1px solid #dedede;
|
||||
border-bottom: 1px solid #dedede;
|
||||
> span {
|
||||
@ -540,13 +553,25 @@ onMounted(() => {});
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
flex: 1;
|
||||
height: 100%;
|
||||
// height: 100%;
|
||||
border-bottom: 1px solid #dedede;
|
||||
span {
|
||||
word-break: break-all;
|
||||
}
|
||||
}
|
||||
> div:nth-child(3) {
|
||||
border-left: 1px solid #dedede;
|
||||
}
|
||||
}
|
||||
> div:last-child {
|
||||
display: flex;
|
||||
> div:nth-child(2n-1) {
|
||||
border-bottom: 0;
|
||||
}
|
||||
> div:nth-child(2n) {
|
||||
border-bottom: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
&-step {
|
||||
|
||||
@ -11,6 +11,9 @@
|
||||
.el-progress__text {
|
||||
display: none;
|
||||
}
|
||||
.el-input__inner {
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
:deep() {
|
||||
.tabs-option {
|
||||
|
||||
@ -14,7 +14,7 @@
|
||||
:onReset="true"
|
||||
>
|
||||
<template #formButton="scope">
|
||||
<el-button class="addButtonStyle" @click="handleAddItem">新增</el-button>
|
||||
<el-button class="addButtonStyle" :disabled="!searchSn" @click="handleAddItem">新增</el-button>
|
||||
</template>
|
||||
<template #annexFile="{ row }">
|
||||
<span>{{ row.annexFile ? JSON.parse(row.annexFile).name : "" }}</span>
|
||||
@ -23,6 +23,10 @@
|
||||
</el-button> -->
|
||||
</template>
|
||||
<template #operation="{ row }">
|
||||
<el-button type="primary" link @click="handleLookItem(row)">
|
||||
<img src="@/assets/images/tableIcon/look.png" alt="" class="configureIcon" />
|
||||
<span>查看</span>
|
||||
</el-button>
|
||||
<el-button type="primary" link @click="handleDownItem(row)" v-if="row.annexFile">
|
||||
<img src="@/assets/images/tableIcon/下载附件.png" alt="" class="configureIcon" />
|
||||
<span>下载附件</span>
|
||||
@ -31,10 +35,6 @@
|
||||
<img src="@/assets/images/tableIcon/上传附件.png" alt="" class="configureIcon" />
|
||||
<span>上传附件</span>
|
||||
</el-button>
|
||||
<el-button type="primary" link @click="handleLookItem(row)">
|
||||
<img src="@/assets/images/tableIcon/look.png" alt="" class="configureIcon" />
|
||||
<span>查看</span>
|
||||
</el-button>
|
||||
</template>
|
||||
</ProTable>
|
||||
<el-dialog title="上传附件" show-close v-model="uploadDialog" style="width: 600px">
|
||||
@ -168,7 +168,7 @@ const columns: ColumnProps[] = [
|
||||
}
|
||||
}
|
||||
},
|
||||
{ prop: "operation", label: "操作", fixed: "right", width: 260 }
|
||||
{ prop: "operation", align: "left", label: "操作", fixed: "right", width: 260 }
|
||||
];
|
||||
const submitForm = async (formEl: FormInstance | undefined, form: any) => {
|
||||
// 标记表单校验
|
||||
|
||||
@ -70,6 +70,12 @@
|
||||
> span {
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
span:nth-child(1) {
|
||||
width: 280px;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap; //单行
|
||||
}
|
||||
}
|
||||
img {
|
||||
width: 688px;
|
||||
|
||||
@ -14,7 +14,7 @@
|
||||
<span class="property-two">臂长: {{ equipInfo.forearmLength ? equipInfo.forearmLength : 0 }}m</span>
|
||||
<span class="property-three">塔身高: {{ equipInfo.towerHeight ? equipInfo.towerHeight : 0 }}m</span>
|
||||
<div class="other-info">
|
||||
<span>设备编号: {{ equipInfo.devNumber ? equipInfo.devNumber : "" }}</span>
|
||||
<span :title="equipInfo.devNumber">设备编号: {{ equipInfo.devNumber ? equipInfo.devNumber : "" }}</span>
|
||||
<span>安装日期: {{ equipInfo.installTime ? equipInfo.installTime : "" }}</span>
|
||||
<!-- <span>终端编号: TD2374693</span> -->
|
||||
<span>更新时间: {{ equipInfo.realTime ? equipInfo.realTime : "" }}</span>
|
||||
|
||||
@ -460,16 +460,15 @@ onMounted(() => {});
|
||||
}
|
||||
}
|
||||
&-part4 {
|
||||
@include flex;
|
||||
display: flex;
|
||||
border: 1px solid #dedede;
|
||||
border-top: 0;
|
||||
height: 200px;
|
||||
// height: 200px;
|
||||
> div:nth-child(1) {
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
width: 3%;
|
||||
height: 200px;
|
||||
// height: 200px;
|
||||
border-right: 1px solid #dedede;
|
||||
> span {
|
||||
display: inline-block;
|
||||
@ -479,37 +478,52 @@ onMounted(() => {});
|
||||
}
|
||||
> div:nth-child(2) {
|
||||
width: 97%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
> div {
|
||||
height: 100px;
|
||||
@include flex;
|
||||
display: flex;
|
||||
flex: 1;
|
||||
// height: 100px;
|
||||
// @include flex;
|
||||
> div:nth-child(1) {
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
width: calc(12% + 3px);
|
||||
height: 100%;
|
||||
// height: 100%;
|
||||
border-right: 1px solid #dedede;
|
||||
}
|
||||
> div:nth-child(2) {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
flex: 1;
|
||||
// height: 100%;
|
||||
// border-bottom: 1px solid #dedede;
|
||||
span {
|
||||
word-break: break-all;
|
||||
}
|
||||
}
|
||||
}
|
||||
> div:not(:last-child) {
|
||||
> div:nth-child(1) {
|
||||
border-bottom: 1px solid #dedede;
|
||||
}
|
||||
> div:nth-child(2) {
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
flex: 1;
|
||||
height: 100%;
|
||||
border-bottom: 1px solid #dedede;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
&-part5 {
|
||||
@include flex;
|
||||
display: flex;
|
||||
border: 1px solid #dedede;
|
||||
border-top: 0;
|
||||
height: 500px;
|
||||
// height: 500px;
|
||||
> div:nth-child(1) {
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
width: 3%;
|
||||
height: 100%;
|
||||
// height: 100%;
|
||||
border-right: 1px solid #dedede;
|
||||
> span {
|
||||
display: inline-block;
|
||||
@ -519,15 +533,14 @@ onMounted(() => {});
|
||||
}
|
||||
> div:nth-child(2) {
|
||||
width: 97%;
|
||||
height: 100%;
|
||||
// height: 100%;
|
||||
> div {
|
||||
height: 100px;
|
||||
@include flex;
|
||||
display: flex;
|
||||
> div:nth-child(2n-1) {
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
width: calc(12% + 3px);
|
||||
height: 100%;
|
||||
// height: 100%;
|
||||
border-right: 1px solid #dedede;
|
||||
border-bottom: 1px solid #dedede;
|
||||
> span {
|
||||
@ -540,13 +553,25 @@ onMounted(() => {});
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
flex: 1;
|
||||
height: 100%;
|
||||
// height: 100%;
|
||||
border-bottom: 1px solid #dedede;
|
||||
span {
|
||||
word-break: break-all;
|
||||
}
|
||||
}
|
||||
> div:nth-child(3) {
|
||||
border-left: 1px solid #dedede;
|
||||
}
|
||||
}
|
||||
> div:last-child {
|
||||
display: flex;
|
||||
> div:nth-child(2n-1) {
|
||||
border-bottom: 0;
|
||||
}
|
||||
> div:nth-child(2n) {
|
||||
border-bottom: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
&-step {
|
||||
|
||||
@ -47,14 +47,14 @@
|
||||
</el-button> -->
|
||||
</template>
|
||||
<template #operation="{ row }">
|
||||
<el-button type="primary" link @click="handleDownItem(row)" v-if="row.annexFile">
|
||||
<img src="@/assets/images/tableIcon/下载附件.png" alt="" class="configureIcon" />
|
||||
<span>下载附件</span>
|
||||
</el-button>
|
||||
<el-button type="primary" link @click="handleLookItem(row)">
|
||||
<img src="@/assets/images/tableIcon/look.png" alt="" class="configureIcon" />
|
||||
<span>查看</span>
|
||||
</el-button>
|
||||
<el-button type="primary" link @click="handleDownItem(row)" v-if="row.annexFile">
|
||||
<img src="@/assets/images/tableIcon/下载附件.png" alt="" class="configureIcon" />
|
||||
<span>下载附件</span>
|
||||
</el-button>
|
||||
</template>
|
||||
</ProTable>
|
||||
</div>
|
||||
@ -135,7 +135,7 @@ const columns: ColumnProps[] = [
|
||||
}
|
||||
}
|
||||
},
|
||||
{ prop: "operation", label: "操作", fixed: "right", width: 260 }
|
||||
{ prop: "operation", align: "left", label: "操作", fixed: "right", width: 260 }
|
||||
];
|
||||
|
||||
// 获取项目名称分页
|
||||
|
||||
@ -129,6 +129,12 @@
|
||||
> span {
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
span:nth-child(1) {
|
||||
width: 280px;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap; //单行
|
||||
}
|
||||
}
|
||||
img {
|
||||
width: 688px;
|
||||
|
||||
@ -56,7 +56,7 @@
|
||||
<span class="property-two">臂长: {{ equipInfo.forearmLength ? equipInfo.forearmLength : 0 }}m</span>
|
||||
<span class="property-three">塔身高: {{ equipInfo.towerHeight ? equipInfo.towerHeight : 0 }}m</span>
|
||||
<div class="other-info">
|
||||
<span>设备编号: {{ equipInfo.devNumber ? equipInfo.devNumber : "" }}</span>
|
||||
<span :title="equipInfo.devNumber">设备编号: {{ equipInfo.devNumber ? equipInfo.devNumber : "" }}</span>
|
||||
<span>安装日期: {{ equipInfo.installTime ? equipInfo.installTime : "" }}</span>
|
||||
<!-- <span>终端编号: TD2374693</span> -->
|
||||
<span>更新时间: {{ equipInfo.realTime ? equipInfo.realTime : "" }}</span>
|
||||
|
||||
@ -290,8 +290,12 @@
|
||||
</el-table-column>
|
||||
<el-table-column prop="question" label="隐患信息">
|
||||
<template #default="{ row }">
|
||||
<el-input v-model="row.question" v-if="row.isEdit" />
|
||||
<span v-else>{{ row.question }}</span>
|
||||
<el-select v-if="row.isEdit" style="width: 100%" v-model="row.question" clearable placeholder="请选择">
|
||||
<el-option label="无隐患" :value="0" />
|
||||
<el-option label="一般隐患" :value="1" />
|
||||
<el-option label="重大隐患" :value="2" />
|
||||
</el-select>
|
||||
<span v-else>{{ row.question == 1 ? "一般隐患" : row.question == 2 ? "重大隐患" : "无隐患" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="solveUser" label="整改人">
|
||||
@ -556,6 +560,10 @@ const confirmAdd = async (row: any, index: any) => {
|
||||
switch (true) {
|
||||
case tabPosition.value < 5 || tabPosition.value == 8:
|
||||
let updateArr = [] as any;
|
||||
if (!requestData.annexName || requestData.fileList.length == 0) {
|
||||
ElMessage.error("请输入名称以及上传附件");
|
||||
break;
|
||||
}
|
||||
requestData.fileList.map(item => {
|
||||
updateArr.push({
|
||||
createTime: item.response.createTime,
|
||||
@ -570,10 +578,10 @@ const confirmAdd = async (row: any, index: any) => {
|
||||
requestData.annexFiles = updateArr;
|
||||
requestData.type = tabPosition.value;
|
||||
delete requestData.fileList;
|
||||
const res = await addOperation[tabPosition.value](requestData);
|
||||
const res = await addOperation[0](requestData);
|
||||
if (res.success) {
|
||||
ElMessage.success("操作成功");
|
||||
listOperation[tabPosition.value]();
|
||||
listOperation[0]();
|
||||
}
|
||||
break;
|
||||
default:
|
||||
@ -600,8 +608,8 @@ const removeEngineeringSingle = async (row: any, index: any) => {
|
||||
if (row.id) {
|
||||
switch (true) {
|
||||
case tabPosition.value < 5 || tabPosition.value == 8:
|
||||
await useHandleData(deleteOperation[tabPosition.value], { id: row.id }, `删除【${row.annexName}】`);
|
||||
listOperation[tabPosition.value]();
|
||||
await useHandleData(deleteOperation[0], { id: row.id }, `删除【${row.annexName}】`);
|
||||
listOperation[0]();
|
||||
break;
|
||||
default:
|
||||
await useHandleData(deleteOperation[tabPosition.value - 4], { id: row.id }, "删除");
|
||||
@ -609,17 +617,17 @@ const removeEngineeringSingle = async (row: any, index: any) => {
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
switch (tabPosition.value) {
|
||||
case 0:
|
||||
switch (true) {
|
||||
case tabPosition.value < 5 || tabPosition.value == 8:
|
||||
arrOne.value.splice(index, 1);
|
||||
break;
|
||||
case 5:
|
||||
case tabPosition.value == 5:
|
||||
arrFive.value.splice(index, 1);
|
||||
break;
|
||||
case 6:
|
||||
case tabPosition.value == 6:
|
||||
arrSeven.value.splice(index, 1);
|
||||
break;
|
||||
case 7:
|
||||
case tabPosition.value == 7:
|
||||
arrEight.value.splice(index, 1);
|
||||
break;
|
||||
default:
|
||||
@ -686,40 +694,64 @@ const addData = () => {
|
||||
console.log(tabPosition.value);
|
||||
switch (true) {
|
||||
case tabPosition.value < 5 || tabPosition.value == 8:
|
||||
arrOne.value.push({
|
||||
annexName: "",
|
||||
fileList: []
|
||||
let findOneItem = arrOne.value.find(item => {
|
||||
return item.insertNew;
|
||||
});
|
||||
if (!findOneItem) {
|
||||
arrOne.value.push({
|
||||
annexName: "",
|
||||
fileList: [],
|
||||
insertNew: true
|
||||
});
|
||||
}
|
||||
break;
|
||||
case tabPosition.value == 5:
|
||||
arrFive.value.push({
|
||||
currentProgress: "",
|
||||
imageUrl: "",
|
||||
// createByName: "",
|
||||
// createTime: "",
|
||||
isEdit: true
|
||||
let findTwoItem = arrFive.value.find(item => {
|
||||
return item.insertNew;
|
||||
});
|
||||
if (!findTwoItem) {
|
||||
arrFive.value.push({
|
||||
currentProgress: "",
|
||||
imageUrl: "",
|
||||
// createByName: "",
|
||||
// createTime: "",
|
||||
isEdit: true,
|
||||
insertNew: true
|
||||
});
|
||||
}
|
||||
break;
|
||||
case tabPosition.value == 6:
|
||||
arrSeven.value.push({
|
||||
inspectResult: "",
|
||||
inspectUser: "",
|
||||
inspectTime: "",
|
||||
question: "",
|
||||
solveUser: "",
|
||||
questionDesc: "",
|
||||
isEdit: true
|
||||
let findThreeItem = arrSeven.value.find(item => {
|
||||
return item.insertNew;
|
||||
});
|
||||
if (!findThreeItem) {
|
||||
arrSeven.value.push({
|
||||
inspectResult: "",
|
||||
inspectUser: "",
|
||||
inspectTime: "",
|
||||
question: "",
|
||||
solveUser: "",
|
||||
questionDesc: "",
|
||||
isEdit: true,
|
||||
insertNew: true
|
||||
});
|
||||
}
|
||||
break;
|
||||
case tabPosition.value == 7:
|
||||
arrEight.value.push({
|
||||
type: null,
|
||||
result: null,
|
||||
state: null,
|
||||
imageUrl: "",
|
||||
acceptTime: "",
|
||||
isEdit: true
|
||||
let findFourItem = arrEight.value.find(item => {
|
||||
return item.insertNew;
|
||||
});
|
||||
if (!findFourItem) {
|
||||
arrEight.value.push({
|
||||
type: null,
|
||||
result: null,
|
||||
state: null,
|
||||
imageUrl: "",
|
||||
acceptTime: "",
|
||||
isEdit: true,
|
||||
insertNew: true
|
||||
});
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
||||
@ -14,7 +14,12 @@
|
||||
<div class="title">建设监理工作月报</div>
|
||||
<div class="sub-title">
|
||||
<span>第</span>
|
||||
<el-input v-model.number="formData.stage" style="width: 60px; margin: 0 5px" @blur="e => validatorNumber(e, 'stage')" />
|
||||
<el-input
|
||||
v-model.number="formData.stage"
|
||||
maxlength="4"
|
||||
style="width: 60px; margin: 0 5px"
|
||||
@blur="e => validatorNumber(e, 'stage')"
|
||||
/>
|
||||
<span>期</span>
|
||||
</div>
|
||||
<div class="sub-title">{{ engineerData.supervisorEnt }}</div>
|
||||
@ -23,7 +28,7 @@
|
||||
<div class="report-content-part1">
|
||||
<div>
|
||||
<span>致: </span>
|
||||
<el-input v-model="formData.chiefInspectorName" style="width: 150px; margin: 0 5px" />
|
||||
<el-input v-model="formData.chiefInspectorName" maxlength="10" style="width: 150px; margin: 0 5px" />
|
||||
<span>监理工程师</span>
|
||||
</div>
|
||||
<div>
|
||||
@ -51,6 +56,7 @@
|
||||
<span>月份《监理月报》第</span>
|
||||
<el-input
|
||||
v-model.number="formData.stage"
|
||||
maxlength="4"
|
||||
style="width: 60px; margin: 0 5px"
|
||||
@blur="e => validatorNumber(e, 'stage')"
|
||||
/>
|
||||
@ -63,6 +69,7 @@
|
||||
<span>土建专业监理工程师:</span>
|
||||
<el-input
|
||||
class="input-style"
|
||||
maxlength="10"
|
||||
v-model="formData.civilEngineeringPersons"
|
||||
style="width: 500px; margin: 0 5px; border-bottom: 1px solid #ccc"
|
||||
/>
|
||||
@ -71,6 +78,7 @@
|
||||
<span>水暖专业监理工程师:</span>
|
||||
<el-input
|
||||
class="input-style"
|
||||
maxlength="10"
|
||||
v-model="formData.plumbingPersons"
|
||||
style="width: 500px; margin: 0 5px; border-bottom: 1px solid #ccc"
|
||||
/>
|
||||
@ -79,6 +87,7 @@
|
||||
<span>电气专业监理工程师:</span>
|
||||
<el-input
|
||||
class="input-style"
|
||||
maxlength="10"
|
||||
v-model="formData.electricalPersons"
|
||||
style="width: 500px; margin: 0 5px; border-bottom: 1px solid #ccc"
|
||||
/>
|
||||
@ -420,7 +429,7 @@ const submitReport = async () => {
|
||||
ElMessage.error("请输入月报月份");
|
||||
return;
|
||||
}
|
||||
requestData.completeTime = requestData.completeYear + '-' + requestData.completeMonth + '-' + requestData.completeDay
|
||||
requestData.completeTime = requestData.completeYear + "-" + requestData.completeMonth + "-" + requestData.completeDay;
|
||||
if (props.activeValue == "eng") {
|
||||
requestData.engineeringSn = props.searchSn;
|
||||
} else {
|
||||
|
||||
@ -462,16 +462,15 @@ onMounted(() => {});
|
||||
}
|
||||
}
|
||||
&-part4 {
|
||||
@include flex;
|
||||
display: flex;
|
||||
border: 1px solid #dedede;
|
||||
border-top: 0;
|
||||
height: 200px;
|
||||
// height: 200px;
|
||||
> div:nth-child(1) {
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
width: 3%;
|
||||
height: 200px;
|
||||
// height: 200px;
|
||||
border-right: 1px solid #dedede;
|
||||
> span {
|
||||
display: inline-block;
|
||||
@ -481,37 +480,52 @@ onMounted(() => {});
|
||||
}
|
||||
> div:nth-child(2) {
|
||||
width: 97%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
> div {
|
||||
height: 100px;
|
||||
@include flex;
|
||||
display: flex;
|
||||
flex: 1;
|
||||
// height: 100px;
|
||||
// @include flex;
|
||||
> div:nth-child(1) {
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
width: calc(12% + 3px);
|
||||
height: 100%;
|
||||
// height: 100%;
|
||||
border-right: 1px solid #dedede;
|
||||
}
|
||||
> div:nth-child(2) {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
flex: 1;
|
||||
// height: 100%;
|
||||
// border-bottom: 1px solid #dedede;
|
||||
span {
|
||||
word-break: break-all;
|
||||
}
|
||||
}
|
||||
}
|
||||
> div:not(:last-child) {
|
||||
> div:nth-child(1) {
|
||||
border-bottom: 1px solid #dedede;
|
||||
}
|
||||
> div:nth-child(2) {
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
flex: 1;
|
||||
height: 100%;
|
||||
border-bottom: 1px solid #dedede;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
&-part5 {
|
||||
@include flex;
|
||||
display: flex;
|
||||
border: 1px solid #dedede;
|
||||
border-top: 0;
|
||||
height: 500px;
|
||||
// height: 500px;
|
||||
> div:nth-child(1) {
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
width: 3%;
|
||||
height: 100%;
|
||||
// height: 100%;
|
||||
border-right: 1px solid #dedede;
|
||||
> span {
|
||||
display: inline-block;
|
||||
@ -521,15 +535,14 @@ onMounted(() => {});
|
||||
}
|
||||
> div:nth-child(2) {
|
||||
width: 97%;
|
||||
height: 100%;
|
||||
// height: 100%;
|
||||
> div {
|
||||
height: 100px;
|
||||
@include flex;
|
||||
display: flex;
|
||||
> div:nth-child(2n-1) {
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
width: calc(12% + 3px);
|
||||
height: 100%;
|
||||
// height: 100%;
|
||||
border-right: 1px solid #dedede;
|
||||
border-bottom: 1px solid #dedede;
|
||||
> span {
|
||||
@ -542,13 +555,25 @@ onMounted(() => {});
|
||||
@include flex;
|
||||
justify-content: center;
|
||||
flex: 1;
|
||||
height: 100%;
|
||||
// height: 100%;
|
||||
border-bottom: 1px solid #dedede;
|
||||
span {
|
||||
word-break: break-all;
|
||||
}
|
||||
}
|
||||
> div:nth-child(3) {
|
||||
border-left: 1px solid #dedede;
|
||||
}
|
||||
}
|
||||
> div:last-child {
|
||||
display: flex;
|
||||
> div:nth-child(2n-1) {
|
||||
border-bottom: 0;
|
||||
}
|
||||
> div:nth-child(2n) {
|
||||
border-bottom: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
&-step {
|
||||
|
||||
@ -11,4 +11,7 @@
|
||||
.el-progress__text {
|
||||
display: none;
|
||||
}
|
||||
.el-input__inner {
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
|
||||
@ -14,7 +14,7 @@
|
||||
:onReset="true"
|
||||
>
|
||||
<template #formButton="scope">
|
||||
<el-button class="addButtonStyle" @click="handleAddItem">新增</el-button>
|
||||
<el-button class="addButtonStyle" :disabled="!searchSn" @click="handleAddItem">新增</el-button>
|
||||
</template>
|
||||
<template #annexFile="{ row }">
|
||||
<span>{{ row.annexFile ? JSON.parse(row.annexFile).name : "" }}</span>
|
||||
@ -23,6 +23,10 @@
|
||||
</el-button> -->
|
||||
</template>
|
||||
<template #operation="{ row }">
|
||||
<el-button type="primary" link @click="handleLookItem(row)">
|
||||
<img src="@/assets/images/tableIcon/look.png" alt="" class="configureIcon" />
|
||||
<span>查看</span>
|
||||
</el-button>
|
||||
<el-button type="primary" link @click="handleDownItem(row)" v-if="row.annexFile">
|
||||
<img src="@/assets/images/tableIcon/下载附件.png" alt="" class="configureIcon" />
|
||||
<span>下载附件</span>
|
||||
@ -31,10 +35,6 @@
|
||||
<img src="@/assets/images/tableIcon/上传附件.png" alt="" class="configureIcon" />
|
||||
<span>上传附件</span>
|
||||
</el-button>
|
||||
<el-button type="primary" link @click="handleLookItem(row)">
|
||||
<img src="@/assets/images/tableIcon/look.png" alt="" class="configureIcon" />
|
||||
<span>查看</span>
|
||||
</el-button>
|
||||
</template>
|
||||
</ProTable>
|
||||
<el-dialog title="上传附件" show-close v-model="uploadDialog" style="width: 600px">
|
||||
@ -170,7 +170,7 @@ const columns: ColumnProps[] = [
|
||||
}
|
||||
}
|
||||
},
|
||||
{ prop: "operation", label: "操作", fixed: "right", width: 260 }
|
||||
{ prop: "operation", align: "left", label: "操作", fixed: "right", width: 260 }
|
||||
];
|
||||
const submitForm = async (formEl: FormInstance | undefined, form: any) => {
|
||||
// 标记表单校验
|
||||
|
||||
@ -70,6 +70,12 @@
|
||||
> span {
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
span:nth-child(1) {
|
||||
width: 280px;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap; //单行
|
||||
}
|
||||
}
|
||||
img {
|
||||
width: 688px;
|
||||
|
||||
@ -14,7 +14,7 @@
|
||||
<span class="property-two">臂长: {{ equipInfo.forearmLength ? equipInfo.forearmLength : 0 }}m</span>
|
||||
<span class="property-three">塔身高: {{ equipInfo.towerHeight ? equipInfo.towerHeight : 0 }}m</span>
|
||||
<div class="other-info">
|
||||
<span>设备编号: {{ equipInfo.devNumber ? equipInfo.devNumber : "" }}</span>
|
||||
<span :title="equipInfo.devNumber">设备编号: {{ equipInfo.devNumber ? equipInfo.devNumber : "" }}</span>
|
||||
<span>安装日期: {{ equipInfo.installTime ? equipInfo.installTime : "" }}</span>
|
||||
<!-- <span>终端编号: TD2374693</span> -->
|
||||
<span>更新时间: {{ equipInfo.realTime ? equipInfo.realTime : "" }}</span>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user