From 7458d2fac56d7d2b2dfb4deedafa799451ae282a Mon Sep 17 00:00:00 2001 From: wyw <571921741@qq.com> Date: Tue, 9 Apr 2024 10:38:02 +0800 Subject: [PATCH] =?UTF-8?q?=E9=9A=90=E6=82=A3=E5=BA=93=E6=B7=BB=E5=8A=A0?= =?UTF-8?q?=E5=BC=B9=E7=AA=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../CustomPages/BS/BS044ShowPrint.js | 9 ++- .../CustomPages/BS/BS064ShowPrint.js | 55 ++++++++++++++++++- 2 files changed, 61 insertions(+), 3 deletions(-) diff --git a/src/components/CustomPages/BS/BS044ShowPrint.js b/src/components/CustomPages/BS/BS044ShowPrint.js index 03cc529..2a53e0d 100644 --- a/src/components/CustomPages/BS/BS044ShowPrint.js +++ b/src/components/CustomPages/BS/BS044ShowPrint.js @@ -32,7 +32,12 @@ class BS044ShowPrint extends React.Component { loadData = () => { let json = initFilter(this.props.login.OrgId); - extendRule(json, 'ID', 1, this.props.data.id); + if (this.props.data.SUBMIT_CONTENT_ID) { + //隐患库 查看整改单 只取 SUBMIT_CONTENT_ID ,ID传值是框架需求所传值无实际意义 + extendRule(json, 'RISK_SUBMIT_CONTENT_ID', 1, this.props.data.SUBMIT_CONTENT_ID); + } else { + extendRule(json, 'ID', 1, this.props.data.id); + } extendInclude(json, 'Nav_UserDeal.Nav_UserSignFiles.Nav_ImgFile.Nav_File'); extendInclude(json, 'Nav_UserCheck.Nav_UserSignFiles.Nav_ImgFile.Nav_File'); @@ -157,7 +162,7 @@ class BS044ShowPrint extends React.Component { } { data.Nav_ApplyDetail == null ? null : - { + { '延期理由:' + data.Nav_ApplyDetail.REASON + ' 原整改期限:' + data.Nav_ApplyDetail.LastDate + (data.Nav_ApplyDetail.TEMPDEMAND != null ? (" 临时整改建议与措施:" + data.Nav_ApplyDetail.TEMPDEMAND) : '') } } diff --git a/src/components/CustomPages/BS/BS064ShowPrint.js b/src/components/CustomPages/BS/BS064ShowPrint.js index 9c547c2..5732279 100644 --- a/src/components/CustomPages/BS/BS064ShowPrint.js +++ b/src/components/CustomPages/BS/BS064ShowPrint.js @@ -1,4 +1,4 @@ -import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd'; +import { Button, Icon,Modal, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd'; import React from 'react'; import { initFilter, extendRule, extendIgnoreDataRule, extendInclude, setDataFieldValue, showApprove, guid, initQueryFilter } from "../../../utils/common"; import ReactToPrint from "react-to-print"; @@ -18,6 +18,13 @@ class BS064ShowPrint extends React.Component { this.state = { data: null, BtnAgreeDisplay: 'none', + //弹窗参数 + detailForm: { + isShow: false, + formCode:"BS044_SHOWPRINT", + title: "隐患整改单", + ID:'' + }, }; }; @@ -62,6 +69,37 @@ class BS064ShowPrint extends React.Component { XLSX.writeFile(wb, "隐患上报表.xlsx") } + + //显示详情弹窗 + showDetailModal = (SUBMIT_CONTENT_ID) => { + const newtmpData = { + data: { + id: SUBMIT_CONTENT_ID,//必须动态参数 这个会影响页面去后台操作数据 '00000000-0000-0000-0000-000000000000' 或者 ''都不行 + SUBMIT_CONTENT_ID: SUBMIT_CONTENT_ID, + }, + formCode: "BS044_SHOWPRINT", + }; + this.setState({ tmpData: newtmpData }, () => { + var detailForm = { + isShow: true, + title: "隐患整改单", + }; + this.setState({ + detailForm: detailForm, + }); + }); + }; + + //详情弹窗关闭(隐藏) + detailFormClose = () => { + var detailForm = { + isShow: false, + }; + this.setState({ + detailForm: detailForm, + }); + }; + render() { const { data } = this.state; return
@@ -90,6 +128,7 @@ class BS064ShowPrint extends React.Component { 隐患地点 整改完成时间(归档时间) 整改人 + 操作 { data?.map((item, i) => { @@ -102,12 +141,26 @@ class BS064ShowPrint extends React.Component { {item.ADDRESS} {item.FINISH_TIME} {item.ACTURE_USERNAME} +
this.showDetailModal(item.SUBMIT_CONTENT_ID)}>
}) }
+
+
+ + + +
}