检查汇总表
This commit is contained in:
parent
39133b3adc
commit
817b8b6de3
533
src/components/CustomPages/SK/SK027ShowPrintNew.js
Normal file
533
src/components/CustomPages/SK/SK027ShowPrintNew.js
Normal file
@ -0,0 +1,533 @@
|
|||||||
|
import { Button, Descriptions, Modal } from 'antd';
|
||||||
|
import React from 'react';
|
||||||
|
import { initFilter, extendRule, GetFileModel, guid, showFiles, showApprove, showUsersSign, showUserSign,showFileImg,extendIgnoreDataRule } from '../../../utils/common';
|
||||||
|
import ReactToPrint from 'react-to-print';
|
||||||
|
import { ExportToExcel } from '@woowalker/feui'
|
||||||
|
import XLSX from 'xlsx';
|
||||||
|
import { connect } from 'dva';
|
||||||
|
import stylesStep from '../../../components/CustomPages/HI/StepForm.css';
|
||||||
|
import config from '../../../config.js';
|
||||||
|
import FormPage from '../../FormPage'
|
||||||
|
import moment from 'moment';
|
||||||
|
class SK027ShowPrintNew extends React.Component {
|
||||||
|
constructor(props) {
|
||||||
|
super(props);
|
||||||
|
this.state = {
|
||||||
|
tmpData: {},
|
||||||
|
data1: null,
|
||||||
|
data2: null,
|
||||||
|
data3: null,
|
||||||
|
data4: null,
|
||||||
|
detailUsers:[],
|
||||||
|
fileData: [],
|
||||||
|
fileForm: {
|
||||||
|
title: "",
|
||||||
|
visible: false,
|
||||||
|
},
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
componentDidMount() {
|
||||||
|
if (this.props.data?.id)
|
||||||
|
this.loadData(this.props.data?.id);
|
||||||
|
}
|
||||||
|
|
||||||
|
componentWillReceiveProps(NextProps) {
|
||||||
|
if (NextProps.data?.id && this.props.data?.id != NextProps.data?.id) {
|
||||||
|
this.loadData(NextProps.data?.id);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
onTableBtnExport() {
|
||||||
|
let TableWrap = document.getElementById('table1');
|
||||||
|
let Table = TableWrap.getElementsByTagName('table1')[0];
|
||||||
|
const wb = XLSX.utils.table_to_book(Table);
|
||||||
|
XLSX.writeFile(wb, this.props.record.Nav_Department.NAME + '.xlsx')
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
loadData = (id) => {
|
||||||
|
// id= CHECKID +'_'+SUBMITID CHECKID\SUBMITID 可能只有其一 但是一定会有_
|
||||||
|
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||||
|
let json = initFilter(orgId);
|
||||||
|
extendRule(json, 'ID', 1, id);
|
||||||
|
extendIgnoreDataRule(json)
|
||||||
|
this.props.dispatch({
|
||||||
|
type: 'app/getDataByPost',
|
||||||
|
payload: json,
|
||||||
|
url: 'SK/SKSecurityInspectionRecordSummary/SKGetAll',
|
||||||
|
onComplete: (ret) => {
|
||||||
|
if (ret) {
|
||||||
|
let users=[]
|
||||||
|
let uniqueUsers =[]
|
||||||
|
if(ret.data1.Nav_CheckRecordDetails)
|
||||||
|
{
|
||||||
|
ret.data1.Nav_CheckRecordDetails.forEach(item => {
|
||||||
|
item.Nav_CheckRecordDetailUsers.forEach(item2=>{
|
||||||
|
users.push(item2)
|
||||||
|
})
|
||||||
|
})
|
||||||
|
}
|
||||||
|
if(users)
|
||||||
|
{
|
||||||
|
uniqueUsers= users.reduce((acc, user) => {
|
||||||
|
// 如果累积数组中还没有这个 user_id,则添加
|
||||||
|
if (!acc.some(item => item.USER_ID === user.USER_ID)) {
|
||||||
|
acc.push(user);
|
||||||
|
}
|
||||||
|
return acc;
|
||||||
|
}, []);
|
||||||
|
}
|
||||||
|
this.setState({ detailUsers:uniqueUsers,data1: ret.data1,
|
||||||
|
data2: ret.data2,data3: ret.data3, data4: ret.data4})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
render() {
|
||||||
|
const { data1,data2,data3,data4,detailUsers } = this.state;
|
||||||
|
const enums = this.props.data.enums ? this.props.data.enums : this.props.app.enums;
|
||||||
|
return <div>
|
||||||
|
<div style={{ padding: '10px' }}>
|
||||||
|
<table>
|
||||||
|
<tr>
|
||||||
|
{/* <td><Button style={{ margin: "0 0 0 10px" }} icon={'export'} onClick={() => this.OperateLogShow(true)} >履职记录</Button></td> */}
|
||||||
|
{/* onClick={() => this.CheckerCheckToActual(10)} */}
|
||||||
|
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} /></td>
|
||||||
|
<td><ExportToExcel fileName='安全检查汇总' tableId={'tableId' + this.props.data.id} /></td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||||
|
<h1 style={{ textAlign: 'center', margin: '15px' }}>安全检查记录汇总表</h1>
|
||||||
|
{
|
||||||
|
data1 ?
|
||||||
|
<div>
|
||||||
|
<Descriptions size="middle" bordered className={stylesStep.description}>
|
||||||
|
<Descriptions.Item label="发起时间">{moment(data1.CREATE_TIME).format('YYYY-MM-DD')}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="发起部门">{data1.Nav_ApplyDepartment ? data1.Nav_ApplyDepartment.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="发起人">{data1.Nav_ApplyUser ? data1.Nav_ApplyUser.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="生产单元">{data1.Nav_ProductionUnit? data1.Nav_ProductionUnit.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查类型">{data1.Nav_CheckType ? data1.Nav_CheckType.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查周期">{enums.SKPLANCHECKFREQUENCYEnum.enums[data1.PLANCHECKFREQUENCY]}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查层级">{enums.SKDepartmentTypeEnum.enums[data1.DEPARTMENT_TYPE]}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查时间">{moment(data1.CHECK_TIME).format('YYYY-MM-DD HH:mm:ss')}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查人员">{data1.CHECK_PERSON}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查附件">{
|
||||||
|
showFiles(data1?.Nav_CheckRecordFiles, config.picServerHost, this)
|
||||||
|
}</Descriptions.Item>
|
||||||
|
</Descriptions>
|
||||||
|
</div> : null
|
||||||
|
}
|
||||||
|
<table style={{ tableLayout: 'fixed', width: '100%' }} className={stylesStep.PrintForm1}>
|
||||||
|
<tr>
|
||||||
|
<td style={{ width: "150px" }} className={stylesStep.fontBold}>序号</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>检查区域</td>
|
||||||
|
<td className={stylesStep.fontBold}>检查内容</td>
|
||||||
|
{/* <td width='10%' className={stylesStep.fontBold}>检查依据</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>判定标准</td> */}
|
||||||
|
<td className={stylesStep.fontBold}>检查人员</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>检查情况</td>
|
||||||
|
<td className={stylesStep.fontBold}>隐患描述</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>隐患等级</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>整改措施</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>隐患地点</td>
|
||||||
|
<td className={stylesStep.fontBold}>隐患照片</td>
|
||||||
|
</tr>
|
||||||
|
{
|
||||||
|
data1?.Nav_CheckRecordDetails && data1.Nav_CheckRecordDetails?.sort((x, y) => (x.RISK_AREA_ID > y.RISK_AREA_ID) ? 1 : -1).map((item, i) => {
|
||||||
|
return <tr>
|
||||||
|
<td>
|
||||||
|
{i + 1}
|
||||||
|
{/* {item.MARK !== 0 ? <a style={{ color: "red" }}>*</a> : i + 1} */}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.Nav_RiskArea?.NAME
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.Nav_Contents?.CHECKCONTENT
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
{/* <td>
|
||||||
|
{
|
||||||
|
item?.Nav_CheckRecordDetailBasics && item?.Nav_CheckRecordDetailBasics.map((item2, i) => {
|
||||||
|
|
||||||
|
return <a>{(i > 0 ? "," : "") + item2.Nav_Law.NAME}</a>
|
||||||
|
|
||||||
|
// return <tr><label> {item2.Nav_User?.NAME}</label></tr>
|
||||||
|
})
|
||||||
|
}
|
||||||
|
</td> */}
|
||||||
|
{/* <td>
|
||||||
|
{
|
||||||
|
item.CHECKSTANDARD
|
||||||
|
}
|
||||||
|
</td> */}
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item?.Nav_CheckRecordDetailUsers && item?.Nav_CheckRecordDetailUsers.map((item2, i) => {
|
||||||
|
if (item2.ISCHECK) {
|
||||||
|
return <a style={{ color: "rgba(0, 0, 0, 0.65)" }}>{(i > 0 ? "," : "") + item2.Nav_User.NAME}</a>
|
||||||
|
} else {
|
||||||
|
return <a style={{ color: "red" }}>{(i > 0 ? "," : "") + item2.Nav_User.NAME}</a>
|
||||||
|
}
|
||||||
|
//return <tr><label> {item2.Nav_User?.NAME}</label></tr>
|
||||||
|
})
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.CHECK_RESULT == null? "无隐患" :enums.SKCheckResultEnum.enums[item.CHECK_RESULT]
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.Nav_Question?.DESCREPTION
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
enums.SKHiddenLevel.enums[item.HIDDEN_LEVEL]
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.RECTIFICATION_MEASURES
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.HIDDEN_PLACE
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
showFiles(item?.Nav_CheckRecordDetailFiles, config.picServerHost, this)
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
})
|
||||||
|
}
|
||||||
|
</table>
|
||||||
|
{
|
||||||
|
this.state.detailUsers ?
|
||||||
|
<div>
|
||||||
|
<Descriptions size="middle" bordered>
|
||||||
|
<Descriptions.Item label="检查人签名">{
|
||||||
|
this.state.detailUsers?.filter(it => it.ISCHECK).map((item, i) => {
|
||||||
|
return showUserSign(item.Nav_User, config.picServerHost)
|
||||||
|
})
|
||||||
|
}</Descriptions.Item>
|
||||||
|
</Descriptions>
|
||||||
|
</div>:null
|
||||||
|
}
|
||||||
|
<h1 style={{ textAlign: 'center', margin: '15px' }}>{data2 && data2 != [] ?"隐患上报表":null}</h1>
|
||||||
|
|
||||||
|
{
|
||||||
|
data2 ?
|
||||||
|
<div>
|
||||||
|
<Descriptions size="middle" bordered className={stylesStep.description}>
|
||||||
|
<Descriptions.Item label="发起时间">{moment(data2.CREATE_TIME).format('YYYY-MM-DD')}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="发起部门">{data2.Nav_ApplyDepartment ? data2.Nav_ApplyDepartment.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="发起人">{data2.Nav_ApplyUser ? data2.Nav_ApplyUser.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="生产单元">{data2.Nav_ProductionUnit? data2.Nav_ProductionUnit.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查类型">{data2.Nav_CheckType ? data2.Nav_CheckType.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查周期">{enums.SKPLANCHECKFREQUENCYEnum.enums[data2.PLANCHECKFREQUENCY]}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查层级">{enums.SKDepartmentTypeEnum.enums[data2.DEPARTMENT_TYPE]}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查时间">{moment(data2.CHECK_TIME).format('YYYY-MM-DD HH:mm:ss')}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查人员">{data2.CHECK_PERSON}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="附件">{
|
||||||
|
showFiles(data2?.Nav_ReportFiles, config.picServerHost, this)
|
||||||
|
}</Descriptions.Item>
|
||||||
|
</Descriptions>
|
||||||
|
</div> : null
|
||||||
|
}
|
||||||
|
{ data2 && data2.Nav_ReportDetails ?
|
||||||
|
<table style={{ tableLayout: 'fixed', width: '100%' }} className={stylesStep.PrintForm1}>
|
||||||
|
<tr>
|
||||||
|
<td style={{ width: "150px" }} className={stylesStep.fontBold}>序号</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>检查区域</td>
|
||||||
|
<td className={stylesStep.fontBold}>检查内容</td>
|
||||||
|
<td className={stylesStep.fontBold}>隐患描述</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>隐患等级</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>整改措施</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>隐患地点</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>整改责任人</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>整改期限</td>
|
||||||
|
<td className={stylesStep.fontBold}>隐患照片</td>
|
||||||
|
</tr>
|
||||||
|
{
|
||||||
|
data2?.Nav_ReportDetails && data2.Nav_ReportDetails?.map((item, i) => {
|
||||||
|
return <tr>
|
||||||
|
<td>
|
||||||
|
{i + 1}
|
||||||
|
{/* {item.MARK !== 0 ? <a style={{ color: "red" }}>*</a> : i + 1} */}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.Nav_RiskArea?.NAME
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.Nav_Contents?.CHECKCONTENT
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.Nav_Question?.DESCREPTION
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
enums.SKHiddenLevel.enums[item.HIDDEN_LEVEL]
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.RECTIFICATION_MEASURES
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.HIDDEN_PLACE
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.ISCHECK? <a style={{ color: "rgba(0, 0, 0, 0.65)" }}>{item.Nav_RecitifyUser?.NAME}</a>:
|
||||||
|
<a style={{ color: "red" }}>{item.Nav_RecitifyUser?.NAME}</a>
|
||||||
|
}
|
||||||
|
{/* {
|
||||||
|
item.Nav_RecitifyUser?.NAME
|
||||||
|
} */}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
moment(item.RECITIFY_TIME).format('YYYY-MM-DD')
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
showFiles(item?.Nav_ReportDetailFiles, config.picServerHost, this)
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
})
|
||||||
|
}
|
||||||
|
</table> :null
|
||||||
|
}
|
||||||
|
|
||||||
|
{
|
||||||
|
data2 && data2.Nav_ReportDetails ?
|
||||||
|
<div>
|
||||||
|
<Descriptions size="middle" bordered>
|
||||||
|
<Descriptions.Item label="整改责任人签名">{
|
||||||
|
data2.Nav_ReportDetails?.map((item, i) => {
|
||||||
|
if (item && item.ISCHECK ) {
|
||||||
|
showUserSign(item.Nav_RecitifyUser, config.picServerHost)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}</Descriptions.Item>
|
||||||
|
</Descriptions>
|
||||||
|
</div>:null
|
||||||
|
}
|
||||||
|
|
||||||
|
{
|
||||||
|
data3 && data3 != []?
|
||||||
|
<table className={stylesStep.PrintFormLight}>
|
||||||
|
<tbody>
|
||||||
|
<tr>
|
||||||
|
{data3 && data3 != [] ? <td style={{ textAlign: "center", fontSize: '20px' }} >隐患整改通知</td>:null}
|
||||||
|
</tr>
|
||||||
|
{
|
||||||
|
data3?.map(head => {
|
||||||
|
return <tr>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
head ?
|
||||||
|
<div>
|
||||||
|
<Descriptions size="middle" bordered className={stylesStep.description}>
|
||||||
|
<Descriptions.Item label="发起时间">{moment(head.CREATE_TIME).format('YYYY-MM-DD')}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="发起部门">{head.Nav_ApplyDepartment ? head.Nav_ApplyDepartment.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="发起人">{head.Nav_ApplyUser ? head.Nav_ApplyUser.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="生产单元">{head.Nav_ProductionUnit? head.Nav_ProductionUnit.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查类型">{head.Nav_CheckType ? head.Nav_CheckType.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查周期">{enums.SKPLANCHECKFREQUENCYEnum.enums[head.PLANCHECKFREQUENCY]}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查层级">{enums.SKDepartmentTypeEnum.enums[head.DEPARTMENT_TYPE]}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查时间">{head.CHECK_TIME ? moment(head.CHECK_TIME).format('YYYY-MM-DD HH:mm:ss') : null}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查人员">{head.CHECK_PERSON}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="附件">{
|
||||||
|
showFiles(head?.Nav_RectifyFiles, config.picServerHost, this)
|
||||||
|
}</Descriptions.Item>
|
||||||
|
</Descriptions>
|
||||||
|
</div> : null
|
||||||
|
}
|
||||||
|
<table style={{ tableLayout: 'fixed', width: '100%' }} className={stylesStep.PrintForm1}>
|
||||||
|
<tr>
|
||||||
|
<td style={{ width: "150px" }} className={stylesStep.fontBold}>序号</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>检查区域</td>
|
||||||
|
{/* <td className={stylesStep.fontBold}>检查内容</td> */}
|
||||||
|
<td className={stylesStep.fontBold}>隐患描述</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>隐患等级</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>隐患地点</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>整改措施</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>整改期限</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>整改落实人</td>
|
||||||
|
<td width='10%' className={stylesStep.fontBold}>验收人</td>
|
||||||
|
<td className={stylesStep.fontBold}>隐患照片</td>
|
||||||
|
</tr>
|
||||||
|
{
|
||||||
|
head?.Nav_RectifyDetails && head.Nav_RectifyDetails?.map((item, i) => {
|
||||||
|
return <tr>
|
||||||
|
<td>
|
||||||
|
{i + 1}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.Nav_RiskArea?.NAME
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
{/* <td>
|
||||||
|
{
|
||||||
|
item.Nav_Contents?.CHECKCONTENT
|
||||||
|
}
|
||||||
|
</td> */}
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.Nav_Question?.DESCREPTION?item.Nav_Question.DESCREPTION:item.HIDDEN_DESCRIPTION
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
enums.SKHiddenLevel.enums[item.HIDDEN_LEVEL]
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.HIDDEN_PLACE
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.RECTIFICATION_MEASURES
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.RECITIFY_TIME ? moment(item.RECITIFY_TIME).format('YYYY-MM-DD') : null
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.Nav_ImplementUser?.NAME
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
item.Nav_AcceptUser?.NAME
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
showFiles(item?.Nav_RectifyDetailFiles, config.picServerHost, this)
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
})
|
||||||
|
}
|
||||||
|
</table>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
})
|
||||||
|
}
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
: null
|
||||||
|
}
|
||||||
|
|
||||||
|
{
|
||||||
|
data4 && data4 != []?
|
||||||
|
<table className={stylesStep.PrintFormLight}>
|
||||||
|
<tbody>
|
||||||
|
<tr>
|
||||||
|
{data4 && data4 != [] ? <td style={{ textAlign: "center", fontSize: '20px' }} >隐患整改记录</td>:null}
|
||||||
|
</tr>
|
||||||
|
{
|
||||||
|
data4?.map(head => {
|
||||||
|
return <tr>
|
||||||
|
<td>
|
||||||
|
{
|
||||||
|
head ?
|
||||||
|
<div>
|
||||||
|
<Descriptions size="middle" bordered className={stylesStep.description}>
|
||||||
|
<Descriptions.Item label="表单编号">{head.CODE}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="发起时间">{moment(head.CREATE_TIME).format('YYYY-MM-DD')}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="发起部门">{head.Nav_ApplyDepartment ? head.Nav_ApplyDepartment.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="发起人">{head.Nav_ApplyUser ? head.Nav_ApplyUser.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="生产单元">{head.Nav_ProductionUnit? head.Nav_ProductionUnit.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查区域">{head.Nav_RiskArea ? head.Nav_RiskArea.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="检查内容">{head.Nav_Contents ? head.Nav_Contents.CHECKCONTENT : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="隐患地点">{head.HIDDEN_PLACE}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="隐患描述">{head.Nav_Question?.DESCREPTION?head.Nav_Question.DESCREPTION:head.HIDDEN_DESCRIPTION}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="隐患等级">{enums.SKHiddenLevel.enums[head.HIDDEN_LEVEL]}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="整改措施">{head.RECTIFICATION_MEASURES}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="整改期限">{moment(head.RECITIFY_TIME).format('YYYY-MM-DD')}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="整改部门">{head.Nav_RecitifyUser && head.Nav_RecitifyUser.Nav_Department ? head.Nav_RecitifyUser.Nav_Department.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="整改责任人">{head.Nav_RecitifyUser ? head.Nav_RecitifyUser.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="整改资金(元)">{head.RECTIFICATION_MONEY}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="预案或方案">{
|
||||||
|
showFiles(head?.Nav_RectifyFiles, config.picServerHost, this)
|
||||||
|
}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="整改落实人">{head.Nav_ImplementUser ? head.Nav_ImplementUser.NAME : ''}</Descriptions.Item>
|
||||||
|
|
||||||
|
<Descriptions.Item label="整改情况描述">{head.RECTIFICATION_DESCRIPTION}</Descriptions.Item>
|
||||||
|
|
||||||
|
<Descriptions.Item label="整改完成时间">{head.COMPLETE_DATE?moment(head.COMPLETE_DATE).format('YYYY-MM-DD'):null}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="整改前照片">{
|
||||||
|
showFileImg(head?.Nav_RectifyPhotoas, config.picServerHost, this)
|
||||||
|
}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="整改后照片">{
|
||||||
|
showFileImg(head?.Nav_RectifyPhotobs, config.picServerHost, this)
|
||||||
|
}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="验收人">{head.Nav_AcceptUser ? head.Nav_AcceptUser.NAME : ''}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="验收时间">{head.ACCEPT_DATE?moment(head.ACCEPT_DATE).format('YYYY-MM-DD'):null}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="验收结论">{enums.SKAcceptResultEnum.enums[head.ACCEPT_RESULTE]}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="验收意见">{head.ACCEPT_OPINION}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="整改责任人签名">{
|
||||||
|
head.Nav_RecitifyUser && head.Nav_RecitifyUser.FILE_PATH ?
|
||||||
|
showUserSign(head.Nav_RecitifyUser, config.picServerHost)
|
||||||
|
: head.Nav_RecitifyUser ? head.Nav_RecitifyUser.NAME : ''
|
||||||
|
}</Descriptions.Item>
|
||||||
|
<Descriptions.Item label="验收人签名">{
|
||||||
|
(head.STATUS == 20 ||head.STATUS == 30) && head.Nav_AcceptUser && head.Nav_AcceptUser.FILE_PATH ?
|
||||||
|
showUserSign(head.Nav_AcceptUser, config.picServerHost)
|
||||||
|
: head.Nav_AcceptUser ? head.Nav_AcceptUser.NAME : ''
|
||||||
|
}</Descriptions.Item>
|
||||||
|
</Descriptions>
|
||||||
|
</div> : null
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
})
|
||||||
|
}
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
: null
|
||||||
|
}
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<FormPage {...this.state.tmpData} />
|
||||||
|
{
|
||||||
|
GetFileModel(Modal, FormPage, this, this.state.fileForm.visible)
|
||||||
|
}
|
||||||
|
</div>
|
||||||
|
}
|
||||||
|
}
|
||||||
|
export default connect(({ login, app }) => ({ login, app }))(SK027ShowPrintNew)
|
||||||
@ -253,6 +253,7 @@ const SK022ShowPrint = createLoadableComponent(() => import('../components/Custo
|
|||||||
const SK024ShowPrint = createLoadableComponent(() => import('../components/CustomPages/SK/SK024ShowPrint'));
|
const SK024ShowPrint = createLoadableComponent(() => import('../components/CustomPages/SK/SK024ShowPrint'));
|
||||||
const SK026ShowPrint = createLoadableComponent(() => import('../components/CustomPages/SK/SK026ShowPrint'));
|
const SK026ShowPrint = createLoadableComponent(() => import('../components/CustomPages/SK/SK026ShowPrint'));
|
||||||
const SK027ShowPrint = createLoadableComponent(() => import('../components/CustomPages/SK/SK027ShowPrint'));
|
const SK027ShowPrint = createLoadableComponent(() => import('../components/CustomPages/SK/SK027ShowPrint'));
|
||||||
|
const SK027ShowPrintNew = createLoadableComponent(() => import('../components/CustomPages/SK/SK027ShowPrintNew'));
|
||||||
const SK031ShowPrint = createLoadableComponent(() => import('../components/CustomPages/SK/SK031ShowPrint'));
|
const SK031ShowPrint = createLoadableComponent(() => import('../components/CustomPages/SK/SK031ShowPrint'));
|
||||||
const SK033ShowPrint = createLoadableComponent(() => import('../components/CustomPages/SK/SK033ShowPrint'));
|
const SK033ShowPrint = createLoadableComponent(() => import('../components/CustomPages/SK/SK033ShowPrint'));
|
||||||
// 该组件已在上方声明,此处去除重复定义
|
// 该组件已在上方声明,此处去除重复定义
|
||||||
@ -502,6 +503,7 @@ export default function (componentName, formId, formParam, data, formCode, formD
|
|||||||
SK024ShowPrint: <SK024ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
SK024ShowPrint: <SK024ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||||
SK026ShowPrint: <SK026ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
SK026ShowPrint: <SK026ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||||
SK027ShowPrint: <SK027ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
SK027ShowPrint: <SK027ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||||
|
SK027ShowPrintNew: <SK027ShowPrintNew formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||||
SK031ShowPrint: <SK031ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
SK031ShowPrint: <SK031ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||||
SK033ShowPrint: <SK033ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
SK033ShowPrint: <SK033ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||||
SK035ShowPrint: <SK035ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
SK035ShowPrint: <SK035ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user