手册和月度

xuhongjie
严飞永 2 months ago
parent 5674ab25f2
commit 38b903493b

@ -227,7 +227,7 @@
ref="projectTable"
:data="projectList"
@row-click="handleRowClick"
height="400"
height="200"
:row-key="(row) => row.id"
v-loading="loading"
@select="handleSelect"
@ -1164,7 +1164,7 @@ export default {
.pagination-box {
display: flex;
justify-content: right;
margin: 16px 0;
// margin: 16px 0;
}
/* 已选项目区域样式 */
@ -1188,7 +1188,7 @@ export default {
display: flex;
flex-direction: column;
gap: 12px;
max-height: 200px;
max-height: 100px;
overflow-y: auto;
padding-right: 10px;
flex: 1;

@ -47,10 +47,10 @@
<span v-else>{{ scope.row.cumulativeArea }}</span>
</template>
</el-table-column>
<el-table-column prop="progressDetails" label='项目进展详情' align="center">
<el-table-column prop="xmjzxq" label='项目进展详情' align="center">
<template slot-scope="scope">
<el-input v-if="scope.row.isEditing" v-model="scope.row.progressDetails" style="width: 100%;"></el-input>
<span v-else>{{ scope.row.progressDetails }}</span>
<el-input v-if="scope.row.isEditing" v-model="scope.row.xmjzxq" style="width: 100%;"></el-input>
<span v-else>{{ scope.row.xmjzxq }}</span>
</template>
</el-table-column>
<el-table-column label="操作" align="center">
@ -76,7 +76,7 @@
<script>
//
// import { getMonthInformationPage } from "@/api/ManageApi/index";
import { getMonthInformationPage } from "@/api/ManageApi/index";
//Apitwo
import { updateProjectProgress, deletemonth } from "@/api/manageApitwo/index";
import { checkPermi, checkRole } from "@/utils/permission";
@ -87,7 +87,7 @@ export default {
type: String,
required: true,
},
zwId: {
xmId: {
type: Number,
required: true,
},
@ -108,7 +108,7 @@ export default {
this.download(
"/gysl/projectProgress/export",
{
zwId: this.zwId
xmId: this.xmId
},
`月度信息${new Date().getTime()}.xlsx`
);
@ -134,7 +134,7 @@ export default {
monthDoneAmount: row.monthDoneAmount,
totalDoneAmount: row.totalDoneAmount,
cumulativeArea: row.cumulativeArea,
progressDetails: row.progressDetails,
xmjzxq: row.xmjzxq,
};
const response = await updateProjectProgress(updateData);
if (response.code === 200) {
@ -145,7 +145,7 @@ export default {
row.isEditing = false;
row.status = "已更新";
// this.getMonthInformationPage();
this.getMonthInformationPage();
} else {
this.$message.error(response.msg || "更新失败");
Object.assign(row, row.originalData);
@ -187,7 +187,7 @@ export default {
//
if (this.tableData.length === 0 && this.current > 1) {
this.current -= 1;
// this.getMonthInformationPage();
this.getMonthInformationPage();
}
} else {
this.$message.error(response.msg || "删除失败");
@ -204,26 +204,26 @@ export default {
});
});
},
// async getMonthInformationPage() {
// try {
// const response = await getMonthInformationPage({ zwId: this.zwId });
async getMonthInformationPage() {
try {
const response = await getMonthInformationPage({ xmId: this.xmId });
// if (Array.isArray(response.data.records) && response.data.records.length > 0) {
// this.tableData = response.data.records;
// this.total = response.data.total || 0;
// } else {
// //
// this.tableData = [];
// this.total = 0;
// }
// } catch (error) {
// console.error(":", error);
// this.$message.error("");
// }
// },
if (Array.isArray(response.data.records) && response.data.records.length > 0) {
this.tableData = response.data.records;
this.total = response.data.total || 0;
} else {
//
this.tableData = [];
this.total = 0;
}
} catch (error) {
console.error("获取月度进展信息失败:", error);
this.$message.error("获取月度进展信息失败");
}
},
},
created() {
// this.getMonthInformationPage();
this.getMonthInformationPage();
},
};
</script>

Loading…
Cancel
Save