diff --git a/src/api/modules/common.ts b/src/api/modules/common.ts index 08df82a..e6ac93d 100644 --- a/src/api/modules/common.ts +++ b/src/api/modules/common.ts @@ -94,3 +94,7 @@ export const noticeDetailMyPost = (params: { noticeId: string }) => { export const noticeReadMyPost = (params: { noticeId: string }) => { return http.post(BASEURL + `/xmgl/notice/read`, params); }; +// 查询工程的单体工程信息 +export const singleEngineer = (params: any) => { + return http.post(BASEURL + `/project/engineering/querySingle`, params); +}; diff --git a/src/api/modules/project.ts b/src/api/modules/project.ts index 736d9f2..b943d87 100644 --- a/src/api/modules/project.ts +++ b/src/api/modules/project.ts @@ -517,3 +517,26 @@ export const applyTimeAdd = (params: any) => { export const subItemDetailAdd = (params: any) => { return http.post(BASEURL + `/project/investmentPaymentDetail/add`, params); }; + +// 工程验收 +// 验收计划分页列表 +export const acceptancePlanPage = (params: any) => { + return http.post(BASEURL + `/project/checkAcceptPlan/page`, params); +}; +// 验收计划新增 +export const acceptancePlanAdd = (params: any) => { + return http.post(BASEURL + `/project/checkAcceptPlan/add`, params); +}; +// 验收计划编辑 +export const acceptancePlanEdit = (params: any) => { + return http.post(BASEURL + `/project/checkAcceptPlan/edit`, params); +}; +// 验收计划删除 +export const acceptancePlanDelete = (params: any) => { + return http.post(BASEURL + `/project/checkAcceptPlan/delete`, params); +}; + +// 验收申请分页列表 +export const acceptanceApplyPage = (params: any) => { + return http.post(BASEURL + `/project/checkAcceptApply/page`, params); +}; diff --git a/src/stores/index.ts b/src/stores/index.ts index 1980bb0..9d198cf 100644 --- a/src/stores/index.ts +++ b/src/stores/index.ts @@ -29,6 +29,8 @@ export const GlobalStore = defineStore({ // language language: "", path: null, + // 工程Sn + engineeringSn: "", // themeConfig themeConfig: { // 当前页面是否全屏 diff --git a/src/stores/interface/index.ts b/src/stores/interface/index.ts index 6b9152d..f093313 100644 --- a/src/stores/interface/index.ts +++ b/src/stores/interface/index.ts @@ -15,6 +15,7 @@ export interface GlobalState { openDropdown: boolean | null; path: string | null; isManager: string | null; + engineeringSn: string; } /* themeConfigProp */ diff --git a/src/views/enterprise/progressManagement/subItemManagement/index.vue b/src/views/enterprise/progressManagement/subItemManagement/index.vue index 0af9f42..cae4359 100644 --- a/src/views/enterprise/progressManagement/subItemManagement/index.vue +++ b/src/views/enterprise/progressManagement/subItemManagement/index.vue @@ -406,6 +406,8 @@ const childrenConfirm = async (formEl: FormInstance | undefined, form: any) => { return; } } + form.overdueIssueFile = JSON.stringify(form.overdueIssueFile); + form.annexFile = JSON.stringify(form.annexFile); if (form.id) { if (newTitle.value == "编辑子项") { form.parentId = parentObj.value.parentId; @@ -441,13 +443,13 @@ const uploadFileSuccess = (response: any) => { }; const uploadSuccess1 = (response: any) => { ElMessage.success("上传成功"); - childrenFormData.value.overdueIssueFile = response.result.url; - fileList1.value = [{ name: response.result.originalFilename, url: response.result.downloadPath }]; + childrenFormData.value.overdueIssueFile = { name: response.result.originalFilename, url: response.result.url }; + fileList1.value = [{ name: response.result.originalFilename, url: response.result.url }]; }; const uploadSuccess = (response: any) => { ElMessage.success("上传成功"); - childrenFormData.value.annexFile = response.result.url; - fileList.value = [{ name: response.result.originalFilename, url: response.result.downloadPath }]; + childrenFormData.value.annexFile = { name: response.result.originalFilename, url: response.result.url }; + fileList.value = [{ name: response.result.originalFilename, url: response.result.url }]; }; const onRemove1: UploadProps["onRemove"] = (file, uploadFiles) => { childrenFormData.value.overdueIssueFile = ""; @@ -516,8 +518,8 @@ const handleEditItem = async (row: any) => { newTitle.value = "编辑"; } childrenFormData.value = { ...row }; - fileList.value = row.annexFile ? [{ name: "文件", url: row.annexFile }] : []; - fileList1.value = row.overdueIssueFile ? [{ name: "文件", url: row.overdueIssueFile }] : []; + fileList.value = row.annexFile ? [{ ...JSON.parse(row.annexFile) }] : []; + fileList1.value = row.overdueIssueFile ? [{ ...JSON.parse(row.overdueIssueFile) }] : []; childrenVisible.value = true; }; onMounted(() => { diff --git a/src/views/goverment/progressManagement/divisionsAndISubItems/index.vue b/src/views/goverment/progressManagement/divisionsAndISubItems/index.vue index acdabcc..8dd4a30 100644 --- a/src/views/goverment/progressManagement/divisionsAndISubItems/index.vue +++ b/src/views/goverment/progressManagement/divisionsAndISubItems/index.vue @@ -297,9 +297,7 @@ const searchForm = ref({ }); const onDowmload = (key: string) => { if (childrenFormData.value[key]) { - ElMessageBox.confirm("确认下载数据?", "温馨提示", { type: "warning" }).then(() => - useDownload(exportApp, "附件文件", { fileUrl: childrenFormData.value[key] }) - ); + window.open(baseUrl + "/xmgl/file/preview?fileUrl=" + JSON.parse(childrenFormData.value[key]).url); } else { ElMessage.error("暂无可下载文件"); } @@ -316,7 +314,7 @@ const handleCurrentChange = (val: any) => { const uploadSuccess = (response: any) => { ElMessage.success("上传成功"); childrenFormData.value.annexFile = response.result.url; - fileList.value = [{ name: response.result.originalFilename, url: response.result.downloadPath }]; + fileList.value = [{ name: response.result.originalFilename, url: response.result.url }]; }; const onRemove: UploadProps["onRemove"] = (file, uploadFiles) => { childrenFormData.value.annexFile = ""; @@ -329,10 +327,10 @@ const handleEditItem = async (row: any) => { newTitle.value = "查看"; childrenFormData.value = { ...row }; if (row.annexFile) { - fileList.value = [{ name: "文件", url: row.annexFile }]; + fileList.value = [{ ...JSON.parse(row.annexFile) }]; } if (row.overdueIssueFile) { - fileList1.value = [{ name: "文件", url: row.overdueIssueFile }]; + fileList1.value = [{ ...JSON.parse(row.overdueIssueFile) }]; } childrenVisible.value = true; }; diff --git a/src/views/project/engineeringAcceptance/acceptanceApply/components/detailsDialog.vue b/src/views/project/engineeringAcceptance/acceptanceApply/components/detailsDialog.vue index 58e662c..10f61da 100644 --- a/src/views/project/engineeringAcceptance/acceptanceApply/components/detailsDialog.vue +++ b/src/views/project/engineeringAcceptance/acceptanceApply/components/detailsDialog.vue @@ -9,27 +9,43 @@ +
+ 验收阶段 + + 类型 + + + + 备注 + +
+
-
验收计划
+
验收内容
新增
- + - + @@ -47,42 +63,61 @@ {{ row.type3 }} - + - + - + - + - + - + + + + +
+ +
+
资料附件
+
+ + + + + + + + + + + + + + + +
+ +
+ +
+
驳回原因
+
+ +
+
+ +
+
现场检查
+
+ + + + + + + + + + + + + + +
+
+ + diff --git a/src/views/project/engineeringAcceptance/acceptanceApply/index.vue b/src/views/project/engineeringAcceptance/acceptanceApply/index.vue index 8445cd5..f98f789 100644 --- a/src/views/project/engineeringAcceptance/acceptanceApply/index.vue +++ b/src/views/project/engineeringAcceptance/acceptanceApply/index.vue @@ -31,7 +31,7 @@ {{ row.examineState === 1 ? "待审核" : row.examineState === 2 ? "审核驳回" : "审核通过" }} @@ -54,11 +54,13 @@ import { ref, reactive, onMounted } from "vue"; import { ElMessage } from "element-plus"; import { ColumnProps } from "@/components/ProTable/interface"; import ProTable from "@/components/ProTable/index.vue"; -import { getDustManagementPage } from "@/api/modules/enterpriseApi"; +import { acceptanceApplyPage } from "@/api/modules/project"; import { getRelevanceList } from "@/api/modules/common"; import engineeringEngDrawer from "@/components/engineeringEngDrawer/index.vue"; import allEngineering from "@/components/allEngineering/index.vue"; import detailsDialog from "./components/detailsDialog.vue"; +import { GlobalStore } from "@/stores"; +const globalStore = GlobalStore(); const newTitle = ref("新增"); const relativeId = ref(); const dialogVisible = ref(false); @@ -73,13 +75,13 @@ const columns: ColumnProps[] = [ { type: "index", label: "序号", width: 80 }, // 多级 prop - { prop: "engineeringName", label: "验收阶段", search: { el: "input" } }, + { prop: "stage", label: "验收阶段", search: { el: "input" } }, { prop: "name", label: "工程名称" }, - { prop: "state", label: "单体工程" }, + { prop: "code", label: "单体工程" }, { prop: "code", label: "类型" }, { prop: "code", label: "备注" }, - { prop: "code", label: "状态" }, + { prop: "state", label: "状态" }, { prop: "operation", label: "操作", fixed: "right" } ]; @@ -112,7 +114,7 @@ const getTableList = (params: any) => { } else { return { result: { current: "1", pages: "1", records: [], size: "10", total: "0" } }; } - return getDustManagementPage(newParams); + return acceptanceApplyPage(newParams); }; // 新增按钮 const handleAddItem = () => { @@ -127,12 +129,14 @@ const getengineering = async () => { engList.value = res.result; if (res.result && res.result.length > 0) { initParam.engineeringSn = res.result[0].engineeringSn; + globalStore.engineeringSn = res.result[0].engineeringSn; } console.log(res); }; // 点击抽屉的工程名称更新页面 const onUpdate = async row => { initParam.engineeringSn = row.engineeringSn; + globalStore.engineeringSn = row.engineeringSn; ElMessage.success("页面已更新"); }; diff --git a/src/views/project/engineeringAcceptance/acceptancePlan/index.vue b/src/views/project/engineeringAcceptance/acceptancePlan/index.vue index e309216..07e8910 100644 --- a/src/views/project/engineeringAcceptance/acceptancePlan/index.vue +++ b/src/views/project/engineeringAcceptance/acceptancePlan/index.vue @@ -17,7 +17,7 @@ 新增 - - - + + + - - - - - - + + + - + + + + + + - - + + - - + + - - + + - - + + - - + + 已验收 - 未验收 + 未验收 - + - + - 点击上传 + 点击上传 - - + +