| | |
| | | }) |
| | | } |
| | | |
| | | // 提交上报内容 |
| | | export function recordSubmit(data) { |
| | | return request({ |
| | | url: '/api/project-plan-progress-report', |
| | | method: 'post', |
| | | data: data |
| | | }) |
| | | } |
| | | |
| | | |
| | | |
| | |
| | | this.$router.push({ |
| | | path: '/projectManage/planRecord', |
| | | query: { |
| | | data: JSON.stringify(row) |
| | | data: row |
| | | } |
| | | }) |
| | | } |
| | |
| | | <el-card shadow="hover"> |
| | | <el-row :gutter="20"> |
| | | <el-col :span="24" class="mb-4"> |
| | | <el-button type="primary" size="small" @click="handlePlanRecord" style="float: right; margin-bottom: 10px; margin-left: 10px">返回</el-button> |
| | | <el-button type="primary" size="small" @click="handleAdd" style="float: right; margin-bottom: 10px">新增</el-button> |
| | | <el-table :data="tableData" border stripe style="width: 100%; margin-bottom: 20px"> |
| | | <el-table-column prop="index" label="序号" width="50" align="center"> |
| | |
| | | methods: { |
| | | // 页面加载 |
| | | search() { |
| | | this.getPlanInfoData(this.planRecordData.id); |
| | | this.getPlanInfoData(this.planInfoData.id); |
| | | }, |
| | | // 获取传递过来的项目计划详情 |
| | | getPlanRecordData() { |
| | | // 从查询参数中获取数据 |
| | | if (this.$route.query.data) { |
| | | this.planRecordData = JSON.parse(this.$route.query.data) |
| | | } |
| | | this.planInfoData = this.$route.query.planInfoData |
| | | this.planRecordData = this.$route.query.planRecordData |
| | | this.planInfoData = this.$route.query.data |
| | | this.search(); |
| | | }, |
| | | // 获取项目计划项 |
| | |
| | | // 遍历tableData,获得值不为空字符串的行 |
| | | const validList = this.tableData.filter(item => item.title !== '' || item.startTime !== '' || item.endTime !== ''); |
| | | this.addData = { |
| | | projectPlanRecordId: this.planRecordData.id, |
| | | projectPlanRecordId: this.planInfoData.id, |
| | | actualInvest: this.actualInvest, |
| | | addList: validList |
| | | } |
| | | addPlanInfo(this.addData).then(response => { |
| | | this.handlePlanRecord(this.planInfoData) |
| | | this.handlePlanRecord() |
| | | }) |
| | | }, |
| | | // 重置当前行数据 |
| | |
| | | }); |
| | | }, |
| | | /** 返回项目计划记录 */ |
| | | handlePlanRecord(planInfoData) { |
| | | handlePlanRecord() { |
| | | this.$router.push({ |
| | | name: '/projectManage/planRecord', |
| | | path: '/projectManage/planRecord', |
| | | query: { |
| | | data: JSON.stringify(planInfoData) |
| | | data: this.planRecordData |
| | | } |
| | | }) |
| | | } |
| | |
| | | <el-card shadow="hover"> |
| | | <el-row :gutter="20"> |
| | | <el-col :span="24" class="mb-4"> |
| | | <el-button type="primary" size="small" @click="handlePlanRecord" style="float: right; margin-bottom: 10px;">返回</el-button> |
| | | <!--项目计划项--> |
| | | <el-table :data="tableData" border stripe style="width: 100%; margin-bottom: 20px"> |
| | | <el-table-column prop="index" label="序号" width="50" align="center"> |
| | |
| | | // 获取传递过来的项目计划详情 |
| | | getPlanRecordData() { |
| | | // 从查询参数中获取数据 |
| | | if (this.$route.query.data) { |
| | | this.planRecordData = JSON.parse(this.$route.query.data) |
| | | } |
| | | this.planRecordData = this.$route.query.data |
| | | this.planInfoData = this.$route.query.planInfoData |
| | | this.search(); |
| | | }, |
| | |
| | | this.tableData[index].startTime = ''; |
| | | this.tableData[index].endTime = ''; |
| | | }, |
| | | /** 返回项目计划记录页面 */ |
| | | handlePlanRecord(planInfoData) { |
| | | /** 返回项目计划记录 */ |
| | | handlePlanRecord() { |
| | | this.$router.push({ |
| | | name: '/projectManage/planRecord', |
| | | path: '/projectManage/planRecord', |
| | | query: { |
| | | data: JSON.stringify(planInfoData) |
| | | data: this.planRecordData |
| | | } |
| | | }) |
| | | }, |
| | | } |
| | | }, |
| | | created() { |
| | | this.getPlanRecordData(); |
| | |
| | | <template> |
| | | <div class="app-container"> |
| | | <el-container> |
| | | <el-header v-show="planInfoData && planInfoData.projectName" class="header-title">项目名称:{{ planInfoData.projectName }}</el-header> |
| | | <h4 v-show="planInfoData && planInfoData.projectCode" style="text-align: center">项目代码:{{ planInfoData.projectCode }}</h4> |
| | | <el-header v-show="planRecordData && planRecordData.projectName" class="header-title">项目名称:{{ planRecordData.projectName }}</el-header> |
| | | <h4 v-show="planRecordData && planRecordData.projectCode" style="text-align: center">项目代码:{{ planRecordData.projectCode }}</h4> |
| | | <el-main> |
| | | <el-card shadow="hover"> |
| | | <el-row :gutter="20"> |
| | |
| | | data() { |
| | | return { |
| | | // 接收传递过来的项目计划数据 |
| | | planInfoData: {}, |
| | | planRecordData: {}, |
| | | // 月度计划数据 |
| | | monthRecords: [], |
| | | // 季度计划数据 |
| | |
| | | methods: { |
| | | // 页面加载 |
| | | search() { |
| | | this.getPlanRecordData(this.planInfoData.id); |
| | | this.getPlanRecordData(this.planRecordData.id); |
| | | }, |
| | | // 获取传递过来的项目计划详情 |
| | | getPlanInfoData() { |
| | | // 从查询参数中获取数据 |
| | | if (this.$route.query.data) { |
| | | this.planInfoData = JSON.parse(this.$route.query.data); |
| | | this.getPlanRecordData(this.planInfoData.id); |
| | | } |
| | | this.planRecordData = this.$route.query.data |
| | | this.getPlanRecordData(this.planRecordData.id); |
| | | }, |
| | | // 获取项目计划记录数据 |
| | | getPlanRecordData(id) { |
| | |
| | | handleAddMonthPlan() { |
| | | let planRecordData = { |
| | | id: undefined, |
| | | projectInfoId: this.planInfoData.id, |
| | | projectInfoId: this.planRecordData.id, |
| | | planTimeFlag: 0 |
| | | } |
| | | // 判断月度计划是否为空 |
| | |
| | | handleAddSeasonPlan() { |
| | | let planRecordData = { |
| | | id: undefined, |
| | | projectInfoId: this.planInfoData.id, |
| | | projectInfoId: this.planRecordData.id, |
| | | planTimeFlag: 1 |
| | | } |
| | | // 判断季度计划是否为空 |
| | |
| | | handleAddYearPlan() { |
| | | let planRecordData = { |
| | | id: undefined, |
| | | projectInfoId: this.planInfoData.id, |
| | | projectInfoId: this.planRecordData.id, |
| | | planTimeFlag: 2 |
| | | } |
| | | // 判断年度计划是否为空 |
| | |
| | | /** 修改项目计划项 */ |
| | | handlePlanInfo(row) { |
| | | this.$router.push({ |
| | | name: 'PlanInfo', |
| | | path: '/projectManage/planInfo', |
| | | query: { |
| | | data: JSON.stringify(row), |
| | | planInfoData: this.planInfoData |
| | | data: row, |
| | | planRecordData: this.planRecordData |
| | | } |
| | | }) |
| | | }, |
| | |
| | | this.$router.push({ |
| | | path: '/projectManage/planInfoCheck', |
| | | query: { |
| | | data: JSON.stringify(row), |
| | | data: row, |
| | | planRecordData: this.planRecordData |
| | | } |
| | | }) |
| | | } |
| | |
| | | <el-input v-model="progressReportData.actualInvest" type="number" /> |
| | | </el-form-item> |
| | | <el-form-item label="上级审核:" :label-width="formLabelWidth"> |
| | | <el-input :value="progressReportData.departmentExamine === 0 ? '同意' : '驳回'" disabled /> |
| | | <el-input :value="progressReportData.departmentExamine === 0 ? '同意' : progressReportData.departmentExamine === 1 ? '驳回' : '未审核'" disabled /> |
| | | </el-form-item> |
| | | <el-form-item label="上级批复:" :label-width="formLabelWidth"> |
| | | <el-input v-model="progressReportData.departmentApproval" disabled /> |
| | |
| | | <el-input type="textarea" v-model="progressReportData.departmentApprovalReply" placeholder="请输入" rows="3" /> |
| | | </el-form-item> |
| | | <el-form-item label="主管部门审核:" :label-width="formLabelWidth"> |
| | | <el-input :value="progressReportData.manageExamine === 0 ? '同意' : '驳回'" disabled /> |
| | | <el-input :value="progressReportData.manageExamine === 0 ? '同意' : progressReportData.manageExamine === 1 ? '驳回' : '未审核'" disabled /> |
| | | </el-form-item> |
| | | <el-form-item label="主管部门审核批复:" :label-width="formLabelWidth"> |
| | | <el-input v-model="progressReportData.manageApproval" disabled /> |
| | |
| | | </el-form-item> |
| | | </el-form> |
| | | <div slot="footer" class="dialog-footer"> |
| | | <el-button type="primary" @click="dialogFormVisible = false">上 报</el-button> |
| | | <el-button type="primary" @click="handleRecordSubmit">上 报</el-button> |
| | | <el-button @click="dialogFormVisible = false">取 消</el-button> |
| | | </div> |
| | | </el-dialog> |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import { getProgressInfoList, getProgressReport } from "@/api/projectManage/progress/index"; |
| | | import { getProgressInfoList, getProgressReport, recordSubmit } from "@/api/projectManage/progress/index"; |
| | | |
| | | export default { |
| | | name: "progressRecord", |
| | |
| | | this.dialogFormVisible = true; |
| | | getProgressReport(row.id).then(res => { |
| | | this.progressReportData = res.data; |
| | | console.log(this.progressReportData) |
| | | }) |
| | | }, |
| | | // 上报提交 |
| | | handleRecordSubmit() { |
| | | recordSubmit(this.progressReportData).then(res => { |
| | | this.dialogFormVisible = false; |
| | | this.$message.success('上报成功'); |
| | | }) |
| | | } |
| | | }, |