文件删除
This commit is contained in:
parent
71440b6a7e
commit
ae14aded35
@ -1,150 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, extendIgnoreDataRule, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class AE006ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
item: null,
|
||||
btndisplay: 'none',
|
||||
ALLTOTAL: 0,
|
||||
ALLUSE: 0,
|
||||
ALLLEFT: 0
|
||||
}
|
||||
}
|
||||
|
||||
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' + this.props.record.ID);
|
||||
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")
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: "PF123",
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
|
||||
//审批意见 改变
|
||||
NOTJOINREASONCHANGE = (val) => {
|
||||
this.state.NOTJOINREASON = val
|
||||
}
|
||||
|
||||
|
||||
//加载数据(传过来的参数都在props里面,包括登录信息)
|
||||
loadData = (id) => {
|
||||
var orgId = this.props.login ? this.props.login.OrgId : ''; //登录后有存储登录信息
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id); //ID=‘’,字段,等于,条件值, 1代表=,2代表不等于,3小于,4小于等于,5大于,6大于等于,7以开始的Like,8以结束的Like,9包含
|
||||
extendInclude(json, 'Nav_User');
|
||||
extendInclude(json, 'Nav_ListAccidentListKind.Nav_AccidentKind');
|
||||
extendInclude(json, 'Nav_AccidentType');
|
||||
extendInclude(json, 'Nav_Department');
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File');
|
||||
extendInclude(json, 'Nav_Approve.Nav_ApproveDetails.Nav_ApproveUser.Nav_UserSignFiles.Nav_ImgFile.Nav_File');
|
||||
extendIgnoreDataRule(json)
|
||||
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'AE/AccidentEventReport/Get',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data, ALLTOTAL, ALLUSE, ALLLEFT } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon="export">审批详情</Button></td>
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='事故事件上报' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<FormPage {...this.state.tmpData} />
|
||||
{/* 安全检查 */}
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>事故事件上报</h1>
|
||||
{
|
||||
data ? <div>
|
||||
<Descriptions title="" size="middle" bordered>
|
||||
|
||||
<Descriptions.Item label="事故编号">{data.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故名称">{data.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="上报时间">{data.TIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="上报人员">{data.Nav_User.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故时间">{data.ACCIDENT_TIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故地点">{data.ACCIDENT_PLACE}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故种类">{
|
||||
data.Nav_ListAccidentListKind?.map((item, i) => {
|
||||
return (i > 0 ? "," : "") + item.Nav_AccidentKind.NAME
|
||||
})
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故类型">{data.Nav_AccidentType.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故部门">{data.Nav_Department.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故等级">{enums.AEAccidentLevel.enums[data.ACCIDENT_LEVEL]}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故起因">{data.ACCIDENT_REASON}</Descriptions.Item>
|
||||
<Descriptions.Item label="预估伤亡人数">{data.ESTIMATE_CASUALTY_COUNT}</Descriptions.Item>
|
||||
<Descriptions.Item label="直接经济损失(元)">{data.ECONOMIC_LOSSES}</Descriptions.Item>
|
||||
<Descriptions.Item label="波及范围">{data.IMPACT_SCOPE}</Descriptions.Item>
|
||||
<Descriptions.Item label="已采取措施">{data.TAKE_MEASURES}</Descriptions.Item>
|
||||
<Descriptions.Item label="其他现状备注">{data.REMARK}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故现场">{
|
||||
showFiles(data.Nav_Files, config.picServerHost)
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="响应级别">{enums.AERspLevel.enums[data.RSP_LEVEL]}</Descriptions.Item>
|
||||
<Descriptions.Item label="下一步工作建议" span={3}>{data.WORK_SUGGEST}</Descriptions.Item>
|
||||
{
|
||||
data.STATUS >= 20 ?
|
||||
<Descriptions.Item label="审核意见" span={3}>{
|
||||
showApprove(data.Nav_Approve?.Nav_ApproveDetails, this.props.app.enums.NodeApproveStatus.enums, config.picServerHost, 100, 65)
|
||||
}</Descriptions.Item>
|
||||
: null
|
||||
}
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(AE006ShowPrint)
|
||||
@ -1,128 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, extendIgnoreDataRule, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class AE008ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
item: null,
|
||||
btndisplay: 'none',
|
||||
ALLTOTAL: 0,
|
||||
ALLUSE: 0,
|
||||
ALLLEFT: 0
|
||||
}
|
||||
}
|
||||
|
||||
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' + this.props.record.ID);
|
||||
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")
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: "PF123",
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
|
||||
//审批意见 改变
|
||||
NOTJOINREASONCHANGE = (val) => {
|
||||
this.state.NOTJOINREASON = val
|
||||
}
|
||||
|
||||
|
||||
//加载数据(传过来的参数都在props里面,包括登录信息)
|
||||
loadData = (id) => {
|
||||
var orgId = this.props.login ? this.props.login.OrgId : ''; //登录后有存储登录信息
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id); //ID=‘’,字段,等于,条件值, 1代表=,2代表不等于,3小于,4小于等于,5大于,6大于等于,7以开始的Like,8以结束的Like,9包含
|
||||
extendInclude(json, 'Nav_AccidentEventReport.Nav_Department');
|
||||
extendInclude(json, 'Nav_LeaderUser');
|
||||
extendInclude(json, 'Nav_DeputyLeaderUser.Nav_User');
|
||||
extendInclude(json, 'Nav_TeamMembers.Nav_User');
|
||||
extendInclude(json, 'Nav_SurveyUser');
|
||||
extendIgnoreDataRule(json)
|
||||
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'AE/AccidentSurveyTeamMember/Get',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data, ALLTOTAL, ALLUSE, ALLLEFT } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon="export">审批详情</Button></td> */}
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='事故调查小组成员' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<FormPage {...this.state.tmpData} />
|
||||
{/* 安全检查 */}
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>事故调查小组成员</h1>
|
||||
{
|
||||
data ? <div>
|
||||
<Descriptions title="" size="middle" bordered>
|
||||
<Descriptions.Item label="事故编号">{data.Nav_AccidentEventReport.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故名称">{data.Nav_AccidentEventReport.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故部门">{data.Nav_AccidentEventReport.Nav_Department.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故地点">{data.Nav_AccidentEventReport.ACCIDENT_PLACE}</Descriptions.Item>
|
||||
<Descriptions.Item label="组长">{data.Nav_LeaderUser?.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="副组长">{data.Nav_DeputyLeaderUser?.map((item, i) => {
|
||||
return (i > 0 ? "," : "") + item.Nav_User.NAME
|
||||
})}</Descriptions.Item>
|
||||
<Descriptions.Item label="组员">{data.Nav_TeamMembers?.map((item, i) => {
|
||||
return (i > 0 ? "," : "") + item.Nav_User.NAME
|
||||
})}</Descriptions.Item>
|
||||
<Descriptions.Item label="调查记录人">{data.Nav_SurveyUser?.NAME}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(AE008ShowPrint)
|
||||
@ -1,323 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, extendIgnoreDataRule, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove, ShowDateTime } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class AE010ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
item: null,
|
||||
btndisplay: 'none',
|
||||
ALLTOTAL: 0,
|
||||
ALLUSE: 0,
|
||||
ALLLEFT: 0
|
||||
}
|
||||
}
|
||||
|
||||
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' + this.props.record.ID);
|
||||
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")
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: "PF123",
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
|
||||
//审批意见 改变
|
||||
NOTJOINREASONCHANGE = (val) => {
|
||||
this.state.NOTJOINREASON = val
|
||||
}
|
||||
|
||||
|
||||
//加载数据(传过来的参数都在props里面,包括登录信息)
|
||||
loadData = (id) => {
|
||||
var orgId = this.props.login ? this.props.login.OrgId : ''; //登录后有存储登录信息
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id); //ID=‘’,字段,等于,条件值, 1代表=,2代表不等于,3小于,4小于等于,5大于,6大于等于,7以开始的Like,8以结束的Like,9包含
|
||||
extendInclude(json, 'Nav_AccidentEventReport.Nav_ListAccidentListKind.Nav_AccidentKind');
|
||||
extendInclude(json, 'Nav_AccidentEventReport.Nav_AccidentType');
|
||||
extendInclude(json, 'Nav_ListSurveyDamageObject.Nav_DamageObject');
|
||||
extendInclude(json, 'Nav_RiskSubmit');
|
||||
extendInclude(json, 'Nav_FilesP.Nav_ImgFile.Nav_File');
|
||||
extendInclude(json, 'Nav_FilesSurvey.Nav_ImgFile.Nav_File');
|
||||
extendInclude(json, 'Nav_Approve.Nav_ApproveDetails.Nav_ApproveUser.Nav_UserSignFiles.Nav_ImgFile.Nav_File');
|
||||
extendIgnoreDataRule(json)
|
||||
// extendInclude(json, 'Nav_ListReason.Nav_ListReasonType.Nav_ReasonType');
|
||||
// extendInclude(json, 'Nav_ListForensics');
|
||||
// extendInclude(json, 'Nav_ListEquipmentLoss');
|
||||
// extendInclude(json, 'Nav_ListCasualties.Nav_User');
|
||||
// extendInclude(json, 'Nav_ListAdmPunishment.Nav_Department');
|
||||
// extendInclude(json, 'Nav_ListAdmPunishment.Nav_User');
|
||||
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'AE/AEAccidentEventSurveyResult/GetAE010',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data, ALLTOTAL, ALLUSE, ALLLEFT } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon="export">审批详情</Button></td>
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='事故事件调查结果' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<FormPage {...this.state.tmpData} />
|
||||
{/* 安全检查 */}
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>事故事件调查结果</h1>
|
||||
{
|
||||
data ? <div>
|
||||
<Descriptions title="" size="middle" bordered>
|
||||
<Descriptions.Item label="事故事件编号">{data.Nav_AccidentEventReport.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件名称">{data.Nav_AccidentEventReport.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件时间">{ShowDateTime(data.Nav_AccidentEventReport.ACCIDENT_TIME)}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件地点">{data.Nav_AccidentEventReport.ACCIDENT_PLACE}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件种类">{
|
||||
data.Nav_AccidentEventReport?.Nav_ListAccidentListKind?.map((item, i) => {
|
||||
return (i > 0 ? "," : "") + item.Nav_AccidentKind.NAME
|
||||
})
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件类型">{data.Nav_AccidentEventReport.Nav_AccidentType.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件等级">{enums.AEAccidentLevel.enums[data.Nav_AccidentEventReport.ACCIDENT_LEVEL]}</Descriptions.Item>
|
||||
<Descriptions.Item label="致害物">{
|
||||
data.Nav_ListSurveyDamageObject?.map((item, i) => {
|
||||
return (i > 0 ? "," : "") + item.Nav_DamageObject.NAME
|
||||
})
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故伤亡人数">{data.CASUALTY_COUNT}</Descriptions.Item>
|
||||
<Descriptions.Item label="直接经济损失(元)">{data.ECONOMIC_LOSSES}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件经过" style={{ maxWith: "300px" }}>{data.ACCIDENT_COURSE}</Descriptions.Item>
|
||||
<Descriptions.Item label="限制结案时间">{ShowDateTime(data.SYSTEMMAXTIME)}</Descriptions.Item>
|
||||
<Descriptions.Item label="实际结案时间">{ShowDateTime(data.TIME)}</Descriptions.Item>
|
||||
<Descriptions.Item label="调查报告附件">{
|
||||
showFiles(data.Nav_FilesSurvey, config.picServerHost)
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="公示文件附件">{
|
||||
showFiles(data.Nav_FilesP, config.picServerHost)
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="隐患上报表单">{data.Nav_RiskSubmit?.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="审批意见">{
|
||||
showApprove(data.Nav_Approve?.Nav_ApproveDetails, this.props.app.enums.NodeApproveStatus.enums, config.picServerHost)
|
||||
}</Descriptions.Item>
|
||||
|
||||
|
||||
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
|
||||
{
|
||||
data?.Nav_ListReason ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={4} className={styles.showPrintHead2} >事故事件原因</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>直接/间接原因</td>
|
||||
<td>原因类别</td>
|
||||
<td>原因分析</td>
|
||||
</tr>
|
||||
{data.Nav_ListReason != null && data.Nav_ListReason.length > 0 ?
|
||||
data.Nav_ListReason?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1}</td>
|
||||
<td>{enums.AEReasonModel.enums[item.REASON_MODEL]} </td>
|
||||
<td>{item.Nav_ListReasonType?.map((itemtype, j) => {
|
||||
return (j > 0 ? "," : "") + itemtype.Nav_ReasonType.NAME
|
||||
})}</td>
|
||||
<td>{item.REASON_ANALYZE} </td>
|
||||
</tr>
|
||||
})
|
||||
: <tr> <td colSpan={4} >查无数据</td> </tr>
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
|
||||
{
|
||||
data?.Nav_ListForensics ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={4} className={styles.showPrintHead2}>调查取证资料</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>证据来源</td>
|
||||
<td>证据描述</td>
|
||||
<td>附件(证据)</td>
|
||||
</tr>
|
||||
|
||||
{
|
||||
data.Nav_ListForensics != null && data.Nav_ListForensics.length > 0 ?
|
||||
data.Nav_ListForensics.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1}</td>
|
||||
<td>{enums.AEEvidenceSource.enums[item.EVIDENCE_SOURCE]} </td>
|
||||
<td>{item.EVIDENCE_DESC} </td>
|
||||
<td>{
|
||||
showFiles(data.Nav_FilesSurvey, config.picServerHost)
|
||||
} </td>
|
||||
</tr>
|
||||
})
|
||||
: <tr> <td colSpan={4} >查无数据</td> </tr>
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
|
||||
|
||||
{
|
||||
data?.Nav_ListEquipmentLoss ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={6} className={styles.showPrintHead2}>设备设施损失信息</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>设备/设施名称</td>
|
||||
<td>规格型号</td>
|
||||
<td>责任人员</td>
|
||||
<td>损失情况</td>
|
||||
</tr>
|
||||
{
|
||||
data.Nav_ListEquipmentLoss != null && data.Nav_ListEquipmentLoss.length > 0 ?
|
||||
data.Nav_ListEquipmentLoss?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1}</td>
|
||||
<td>{item.MACHINE_NAME} </td>
|
||||
<td>{item.SPEC} </td>
|
||||
<td>{item.USER_NAME} </td>
|
||||
<td>{item.LOSS_CONDITION} </td>
|
||||
</tr>
|
||||
}) : <tr> <td colSpan={5} >查无数据</td> </tr>
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
{
|
||||
data?.Nav_ListCasualties ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={4} className={styles.showPrintHead2}>人员伤亡信息</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>姓名</td>
|
||||
<td>受伤时间</td>
|
||||
<td>受伤部位</td>
|
||||
</tr>
|
||||
{
|
||||
|
||||
data.Nav_ListCasualties != null && data.Nav_ListCasualties.length > 0 ?
|
||||
data.Nav_ListCasualties.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1}</td>
|
||||
<td>{item?.Nav_User?.NAME} </td>
|
||||
<td>{ShowDateTime(item.INJURED_TIME)} </td>
|
||||
<td>{item.INJURED_AREA} </td>
|
||||
</tr>
|
||||
})
|
||||
: <tr> <td colSpan={4} >查无数据</td> </tr>
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
{
|
||||
data?.Nav_ListAdmPunishment ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={5} className={styles.showPrintHead2}>行政处罚信息
|
||||
</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>责任部门</td>
|
||||
<td>处理人</td>
|
||||
<td>处罚结果</td>
|
||||
<td>处罚原因</td>
|
||||
</tr>
|
||||
{
|
||||
data.Nav_ListAdmPunishment != null && data.Nav_ListAdmPunishment.length > 0 ?
|
||||
data.Nav_ListAdmPunishment.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1}</td>
|
||||
<td>{item.Nav_Department?.NAME} </td>
|
||||
<td>{item.Nav_User?.NAME} </td>
|
||||
<td>{item.PUNISHMENT_RESULT} </td>
|
||||
<td>{item.PUNISHMENT_REASON} </td>
|
||||
</tr>
|
||||
})
|
||||
: <tr> <td colSpan={5} >查无数据</td> </tr>
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
{/* Nav_ListReason C39635C3-160C-41FB-BB5C-C1D550B31702
|
||||
Nav_ListForensics FE38AFF4-9EE6-4FB5-9545-E2A98F848E66
|
||||
Nav_ListEquipmentLoss 0B1E8368-5793-48DA-B36E-F8D7E0B0729C
|
||||
Nav_ListCasualties B5C28E0D-4BE8-404D-8B58-76A9DAE9B61E
|
||||
Nav_ListAdmPunishment D289ED37-D479-43CF-9528-EC87FAE25735 */}
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(AE010ShowPrint)
|
||||
@ -1,185 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, extendIgnoreDataRule, setDataFieldValue, guid, initQueryFilter, showFiles, showUsersSign, showUserSign } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class AE018ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
item: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: false,
|
||||
listSign: []
|
||||
}
|
||||
}
|
||||
|
||||
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' + this.props.record.ID);
|
||||
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")
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: "PF123",
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
|
||||
onClickCheck = () => {
|
||||
let json = initFilter(this.props.login.OrgId, this.props.data.id, null, null, null, this.props.data.TaskID);
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'AE/AEInvestigationRecord/Read',
|
||||
onComplete: (ret) => {
|
||||
this.props.data.onCancel();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//审批意见 改变
|
||||
NOTJOINREASONCHANGE = (val) => {
|
||||
this.state.NOTJOINREASON = val
|
||||
}
|
||||
|
||||
|
||||
//加载数据(传过来的参数都在props里面,包括登录信息)
|
||||
loadData = (id) => {
|
||||
var orgId = this.props.login ? this.props.login.OrgId : ''; //登录后有存储登录信息
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id); //ID=‘’,字段,等于,条件值, 1代表=,2代表不等于,3小于,4小于等于,5大于,6大于等于,7以开始的Like,8以结束的Like,9包含
|
||||
extendInclude(json, 'Nav_Department');
|
||||
extendInclude(json, 'Nav_User');
|
||||
extendInclude(json, 'Nav_Accident');
|
||||
extendInclude(json, 'Nav_UsersInvestigation.Nav_User.Nav_UserSignFiles.Nav_ImgFile.Nav_File');
|
||||
extendInclude(json, 'Nav_UsersAsk.Nav_User');
|
||||
extendInclude(json, 'Nav_FilesAcc.Nav_ImgFile.Nav_File');
|
||||
extendInclude(json, 'Nav_FilesChart.Nav_ImgFile.Nav_File');
|
||||
extendInclude(json, 'Nav_NotesFilesNotes.Nav_ImgFile.Nav_File');
|
||||
extendInclude(json, 'Nav_LeaderUser.Nav_UserSignFiles.Nav_ImgFile.Nav_File');
|
||||
extendIgnoreDataRule(json)
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'AE/InvestigationRecord/Get',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
var IsCheck = true
|
||||
if ((this.props.data.tableKey == null) || (this.props.data.tableKey != undefined && this.props.data.tableKey == "2")) {
|
||||
IsCheck = false
|
||||
}
|
||||
|
||||
var ListSign = []
|
||||
if (ret.Nav_UsersInvestigation != null && ret.Nav_UsersInvestigation.length > 0) {
|
||||
for (let i = 0; i < ret.Nav_UsersInvestigation.length; i++) {
|
||||
if (ret.Nav_UsersInvestigation[i].STATUS != 0) {
|
||||
ListSign.push(ret.Nav_UsersInvestigation[i]);
|
||||
}
|
||||
}
|
||||
}
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
isCheck: IsCheck,
|
||||
listSign: ListSign
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data, isCheck, listSign } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon="export">审批详情</Button></td>
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='勘察记录' tableId={'tableId' + this.props.data.id} /></td>
|
||||
{isCheck ? <td><Button onClick={() => this.onClickCheck()} style={{ marginLeft: '8px' }} type={'primary'} icon={'save'} >确认</Button></td> : null}
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<FormPage {...this.state.tmpData} />
|
||||
{/* 安全检查 */}
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>勘察记录</h1>
|
||||
{/* 事故事件调查结果 */}
|
||||
{
|
||||
data ? <div>
|
||||
<Descriptions title="" size="middle" bordered>
|
||||
<Descriptions.Item label="创建日期">{data.LAUNCH_TIME?.split(' '[0])}</Descriptions.Item>
|
||||
<Descriptions.Item label="创建部门">{data.Nav_Department.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="创建人">{data.Nav_User.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件编号">{data.Nav_Accident.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件名称">{data.Nav_Accident.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="勘察时间">{data.INVESTIGATION_TIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="勘察地点">{data.INVESTIGATION_LOCATION}</Descriptions.Item>
|
||||
<Descriptions.Item label="勘察事由">{data.INVESTIGATION_REASON}</Descriptions.Item>
|
||||
<Descriptions.Item label="勘察人员">{data.Nav_UsersInvestigation?.map((item, i) => {
|
||||
return <a style={{ color: item.STATUS == 0 ? "red" : "#000000A6" }}> {(i > 0 ? "," : "") + item.Nav_User.NAME}</a>
|
||||
})}</Descriptions.Item>
|
||||
<Descriptions.Item label="询问人员">{data.Nav_UsersAsk?.map((item, i) => {
|
||||
return (i > 0 ? "," : "") + item.Nav_User.NAME
|
||||
})}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故现场外围和环境情况">{data.SCENE_ENV_DESC}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故现场情况">{data.SCENE_DESC}</Descriptions.Item>
|
||||
<Descriptions.Item label="现场物证情况">{data.SCENE_EVIDENCE_DESC}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故照片">{
|
||||
showFiles(data.Nav_FilesAcc, config.picServerHost)}</Descriptions.Item>
|
||||
<Descriptions.Item label="绘制事故图">{
|
||||
showFiles(data.Nav_FilesChart, config.picServerHost)}</Descriptions.Item>
|
||||
<Descriptions.Item label="现场笔录" span={3}>{
|
||||
showFiles(data.Nav_NotesFilesNotes, config.picServerHost)
|
||||
}</Descriptions.Item>
|
||||
|
||||
<Descriptions.Item span={3} label="勘察人员签名">{
|
||||
// showFiles(data.Nav_NotesFilesNotes, config.picServerHost)
|
||||
showUsersSign(listSign, config.picServerHost, 80, 35)
|
||||
}</Descriptions.Item>
|
||||
|
||||
<Descriptions.Item span={3} label="审阅意见">{
|
||||
data.STATUS > 20 ?
|
||||
showUserSign(data.Nav_LeaderUser, config.picServerHost, 80, 35)
|
||||
: null
|
||||
// showFiles(data.Nav_NotesFilesNotes, config.picServerHost)
|
||||
|
||||
}</Descriptions.Item>
|
||||
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(AE018ShowPrint)
|
||||
@ -1,358 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendIgnoreDataRule, extendInclude, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove, ShowDateTime } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class AE019ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
item: null,
|
||||
btndisplay: 'none',
|
||||
ALLTOTAL: 0,
|
||||
ALLUSE: 0,
|
||||
ALLLEFT: 0
|
||||
}
|
||||
}
|
||||
|
||||
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' + this.props.record.ID);
|
||||
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")
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: "PF123",
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
|
||||
//审批意见 改变
|
||||
NOTJOINREASONCHANGE = (val) => {
|
||||
this.state.NOTJOINREASON = val
|
||||
}
|
||||
|
||||
|
||||
//加载数据(传过来的参数都在props里面,包括登录信息)
|
||||
loadData = (id) => {
|
||||
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: 'AE/AEAccidentEventReport/LibGet',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data, ALLTOTAL, ALLUSE, ALLLEFT } = 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><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='事故事件明细' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<FormPage {...this.state.tmpData} />
|
||||
{/* 安全检查 */}
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>事故事件明细</h1>
|
||||
{
|
||||
data?.Report ? <div>
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
{/* <tr>
|
||||
<td colSpan={4} style={{ fontSize: "25px", color: "#333", margin: "20px 0 20px 0" }}>事故事件原因</td>
|
||||
</tr> */}
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>事故事件编号</td>
|
||||
<td>事故事件名称</td>
|
||||
<td>事故事件时间</td>
|
||||
<td>事故事件种类</td>
|
||||
<td>事故事件等级</td>
|
||||
<td>事故事件地点</td>
|
||||
<td>事故类型</td>
|
||||
{/*事故事件类别 */}
|
||||
<td>致害物</td>
|
||||
<td>事故伤亡人数</td>
|
||||
<td>直接经济损失</td>
|
||||
<td style={{ maxWidth: "300px" }}>事故事件经过</td>
|
||||
<td>事故事件部门</td>
|
||||
<td>事故事件报告人</td>
|
||||
<td>限制结案时间</td>
|
||||
<td>实际结案时间</td>
|
||||
<td>调查报告附件</td>
|
||||
<td>公示文件附件</td>
|
||||
</tr>
|
||||
<tr >
|
||||
<td>{data.Report.CODE}</td>
|
||||
<td>{data.Report.NAME}</td>
|
||||
<td>{ShowDateTime(data.Report.ACCIDENT_TIME)}</td>
|
||||
<td>{
|
||||
data.Report.Nav_ListAccidentListKind.map((item, j) => {
|
||||
return <p className={styles.pLin}> {item.Nav_AccidentKind.NAME}</p>
|
||||
})
|
||||
}</td>
|
||||
<td>{enums.AEAccidentLevel.enums[data.Report.ACCIDENT_LEVEL]}</td>
|
||||
<td>{data.Report.ACCIDENT_PLACE}</td>
|
||||
<td>{
|
||||
data.Result?.Nav_ListSurveyDamageObject.map((item, j) => {
|
||||
// return (j > 0 ? "," : "") + item.Nav_DamageObject.NAME
|
||||
return <p className={styles.pLin}> {item.Nav_DamageObject.NAME}</p>
|
||||
})
|
||||
}</td>
|
||||
<td>{data.Report.Nav_AccidentType.NAME} </td>
|
||||
<td>{data.Result?.CASUALTY_COUNT}</td>
|
||||
<td>{data.Report.ECONOMIC_LOSSES}</td>
|
||||
<td>{data.Result?.ACCIDENT_COURSE}</td>
|
||||
<td>{data.Report.Nav_Department.NAME}</td>
|
||||
<td>{data.Report.Nav_User.NAME}</td>
|
||||
<td>{ShowDateTime(data.Result?.SYSTEMMAXTIME)}</td>
|
||||
<td>{ShowDateTime(data.Result?.TIME)}</td>
|
||||
<td style={{ maxWidth: '100px' }} >{
|
||||
showFiles(data.Result?.Nav_FilesSurvey, config.picServerHost)
|
||||
}</td>
|
||||
<td style={{ maxWidth: '100px' }} >{
|
||||
showFiles(data.Result?.Nav_FilesP, config.picServerHost)
|
||||
}</td>
|
||||
</tr>
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
</div> : null
|
||||
}
|
||||
|
||||
{/* <Descriptions title="" size="middle" bordered>
|
||||
<Descriptions.Item label="事故事件编号">{data.Nav_AccidentEventReport.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件名称">{data.Nav_AccidentEventReport.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件时间">{data.Nav_AccidentEventReport.ACCIDENT_TIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件地点">{data.Nav_AccidentEventReport.ACCIDENT_PLACE}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件种类">{
|
||||
data.Nav_AccidentEventReport?.Nav_ListAccidentListKind?.map((item, i) => {
|
||||
return (i > 0 ? "," : "") + item.Nav_AccidentKind.NAME
|
||||
})
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件类型">{data.Nav_AccidentEventReport.Nav_AccidentType.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件等级">{enums.AEAccidentLevel.enums[data.Nav_AccidentEventReport.ACCIDENT_LEVEL]}</Descriptions.Item>
|
||||
<Descriptions.Item label="致害物">{
|
||||
data.Nav_ListSurveyDamageObject?.map((item, i) => {
|
||||
return (i > 0 ? "," : "") + item.Nav_DamageObject.NAME
|
||||
})
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故伤亡人数">{data.CASUALTY_COUNT}</Descriptions.Item>
|
||||
<Descriptions.Item label="直接经济损失(元)">{data.ECONOMIC_LOSSES}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件经过">{data.ACCIDENT_COURSE}</Descriptions.Item>
|
||||
<Descriptions.Item label="限制结案时间">{data.SYSTEMMAXTIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="实际结案时间">{data.TIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="调查报告附件">{
|
||||
showFiles(data.Nav_FilesSurvey, config.picServerHost)
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="公示文件附件">{
|
||||
showFiles(data.Nav_FilesP, config.picServerHost)
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="隐患上报表单">{data.Nav_RiskSubmit?.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="审批意见">{
|
||||
showApprove(data.Nav_Approve?.Nav_ApproveDetails, this.props.app.enums.NodeApproveStatus.enums, config.picServerHost)
|
||||
}</Descriptions.Item>
|
||||
</Descriptions> */}
|
||||
|
||||
{
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={4} className={styles.showPrintHead2}>事故事件原因</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>直接/间接原因</td>
|
||||
<td>原因类别</td>
|
||||
<td>原因分析</td>
|
||||
</tr>
|
||||
{data?.Result?.Nav_ListReason ? data.Result.Nav_ListReason.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1}</td>
|
||||
<td>{enums.AEReasonModel.enums[item.REASON_MODEL]} </td>
|
||||
<td>{item.Nav_ListReasonType?.map((itemtype, j) => {
|
||||
return (j > 0 ? "," : "") + itemtype.Nav_ReasonType.NAME
|
||||
})}</td>
|
||||
<td>{item.REASON_ANALYZE} </td>
|
||||
</tr>
|
||||
}) : <tr><td colSpan={4}>暂无数据</td></tr>}
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
}
|
||||
|
||||
{
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={4} className={styles.showPrintHead2}>调查取证资料</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>证据来源</td>
|
||||
<td>证据描述</td>
|
||||
<td>附件(证据)</td>
|
||||
</tr>
|
||||
{data?.Result?.Nav_ListForensics ? data.Result.Nav_ListForensics.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1}</td>
|
||||
<td>{enums.AEEvidenceSource.enums[item.EVIDENCE_SOURCE]} </td>
|
||||
<td>{item.EVIDENCE_DESC} </td>
|
||||
<td>{
|
||||
showFiles(item.Nav_FilesSurvey, config.picServerHost)
|
||||
} </td>
|
||||
</tr>
|
||||
}) : <tr><td colSpan={4}>暂无数据</td></tr>}
|
||||
</tbody>
|
||||
</table>
|
||||
}
|
||||
|
||||
|
||||
{
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={5} className={styles.showPrintHead2}>设备设施损失信息</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>设备/设施名称</td>
|
||||
<td>规格型号</td>
|
||||
<td>责任人员</td>
|
||||
<td>损失情况</td>
|
||||
</tr>
|
||||
{data?.Result?.Nav_ListEquipmentLoss ? data.Result.Nav_ListEquipmentLoss.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1}</td>
|
||||
<td>{item.MACHINE_NAME} </td>
|
||||
<td>{item.SPEC} </td>
|
||||
<td>{item.USER_NAME} </td>
|
||||
<td>{item.LOSS_CONDITION} </td>
|
||||
</tr>
|
||||
}) : <tr><td colSpan={5}>暂无数据</td></tr>}
|
||||
</tbody>
|
||||
</table>
|
||||
}
|
||||
{
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={15} className={styles.showPrintHead2}>人员伤亡信息</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>姓名</td>
|
||||
<td>受伤时间</td>
|
||||
<td>受伤部位/疾病名称</td>
|
||||
|
||||
|
||||
<td>就诊医院</td>
|
||||
<td>是否住院</td>
|
||||
<td>员工报销金额(元)</td>
|
||||
<td>社保报销金额(元)</td>
|
||||
<td>工伤认定时间</td>
|
||||
<td>工伤认定机构</td>
|
||||
<td>伤残等级</td>
|
||||
<td>伤残鉴定时间</td>
|
||||
<td>伤残鉴定机构</td>
|
||||
<td>备注</td>
|
||||
<td>相关附件</td>
|
||||
|
||||
</tr>
|
||||
{data?.Result?.Nav_ListCasualties ? data.Result.Nav_ListCasualties.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1}</td>
|
||||
<td>{item.Nav_User.NAME} </td>
|
||||
<td>{ShowDateTime(item.INJURED_TIME)} </td>
|
||||
<td>{item.INJURED_AREA} </td>
|
||||
{/* Nav_ClaimRecord */}
|
||||
<td>{item.Nav_ClaimRecord?.HOSPITAL} </td>
|
||||
<td>{enums.YesNoEnum.enums[item.Nav_ClaimRecord?.IN_HOSPITAL]} </td>
|
||||
<td>{item.Nav_ClaimRecord?.USER_CLAIM_AMOUNT} </td>
|
||||
<td>{item.Nav_ClaimRecord?.INSURANCE_CLAIM_AMOUNT} </td>
|
||||
<td>{ShowDateTime(item.Nav_ClaimRecord?.INJURE_AFFIRM_TIME)} </td>
|
||||
<td>{item.Nav_ClaimRecord?.INJURE_AFFIRM_AGENCY} </td>
|
||||
<td>{enums.TIDisabilityLevelEnum.enums[item.Nav_ClaimRecord?.DISABILITY_LEVEL]} </td>
|
||||
|
||||
<td>{ShowDateTime(item.Nav_ClaimRecord?.DISABILITY_AFFIRM_TIME)} </td>
|
||||
<td>{item.Nav_ClaimRecord?.DISABILITY_AFFIRM_AGENCY} </td>
|
||||
<td>{item.Nav_ClaimRecord?.REMARK} </td>
|
||||
<td>{
|
||||
showFiles(item.Nav_ClaimRecord?.Nav_Files, config.picServerHost)
|
||||
} </td>
|
||||
</tr>
|
||||
}) : <tr><td colSpan={15}>暂无数据</td></tr>}
|
||||
</tbody>
|
||||
</table>
|
||||
}
|
||||
{
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={5} className={styles.showPrintHead2}>行政处罚信息
|
||||
</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>责任部门</td>
|
||||
<td>处理人</td>
|
||||
<td>处罚结果</td>
|
||||
<td>处罚原因</td>
|
||||
</tr>
|
||||
{data?.Result?.Nav_ListAdmPunishment ? data.Result.Nav_ListAdmPunishment.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1}</td>
|
||||
<td>{item.Nav_Department.NAME} </td>
|
||||
<td>{item.Nav_User.NAME} </td>
|
||||
<td>{item.PUNISHMENT_RESULT} </td>
|
||||
<td>{item.PUNISHMENT_REASON} </td>
|
||||
</tr>
|
||||
}) : <tr><td colSpan={5}>暂无数据</td></tr>}
|
||||
</tbody>
|
||||
</table>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(AE019ShowPrint)
|
||||
@ -1,199 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, extendIgnoreDataRule, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove, showUserSign, showUsersSign } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class OH003ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
item: null,
|
||||
btndisplay: 'none',
|
||||
isTaskSign: false, //是否待办 审批
|
||||
JOINRESULT: 0, //10 参加 20 请假
|
||||
NOTJOINREASON: '',//请假原因
|
||||
isHasOpinion: false,//会议意见库
|
||||
isMinutesDetail: false,//会议纪要落实
|
||||
listSign: []//会议签到
|
||||
}
|
||||
}
|
||||
|
||||
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' + this.props.record.ID);
|
||||
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")
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: "PF123",
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
|
||||
// //审批意见 改变
|
||||
// NOTJOINREASONCHANGE = (val) => {
|
||||
// this.state.NOTJOINREASON = val
|
||||
// }
|
||||
// //请假/参加
|
||||
// sign = () => {
|
||||
// let json = initFilter(this.props.login.OrgId, this.props.data.id, null, null, null, this.props.data.TaskID);
|
||||
// this.props.dispatch({
|
||||
// type: 'app/getDataByPost',
|
||||
// payload: json,
|
||||
// url: 'SC/SCMtMeetingMinutes/MeetingMinutesSign',
|
||||
// onComplete: (ret) => {
|
||||
// if (ret) {
|
||||
// this.props.data.onCancel();
|
||||
// }
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
|
||||
// //请假/参加
|
||||
// sureCheck = (val) => {
|
||||
// if (val && val == 20 && (this.state.NOTJOINREASON == undefined || this.state.NOTJOINREASON == null || this.state.NOTJOINREASON.length < 1)) {
|
||||
// message.error("请填写请假备注!");
|
||||
// return false
|
||||
// }
|
||||
// let json = initFilter(this.props.login.OrgId, this.props.data.id, null, null, null, this.props.data.TaskID, val, this.state.NOTJOINREASON);
|
||||
// this.props.dispatch({
|
||||
// type: 'app/getDataByPost',
|
||||
// payload: json,
|
||||
// url: 'SC/SCMTMeeting/PAllCheck',
|
||||
// onComplete: (ret) => {
|
||||
// if (ret) {
|
||||
// this.props.data.onCancel();
|
||||
// }
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
|
||||
//加载数据(传过来的参数都在props里面,包括登录信息)
|
||||
loadData = (id) => {
|
||||
var taskID = this.props.data.TaskID
|
||||
var loginID = this.props.login.user.ID
|
||||
var orgId = this.props.login ? this.props.login.OrgId : ''; //登录后有存储登录信息
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id); //ID=‘’,字段,等于,条件值, 1代表=,2代表不等于,3小于,4小于等于,5大于,6大于等于,7以开始的Like,8以结束的Like,9包含
|
||||
|
||||
extendInclude(json, 'Nav_ListDepartment.Nav_Department');
|
||||
extendInclude(json, 'Nav_ListDepartment.Nav_User');
|
||||
extendIgnoreDataRule(json)
|
||||
let attendanceAry = [], leaveAry = [];
|
||||
let that = this;
|
||||
let btndisplay = 'none';
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'OH/HealthExamPlan/Get',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
if (ret) { //判断是否有记录
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon="export">审批详情</Button></td>
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='体检计划' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<FormPage {...this.state.tmpData} />
|
||||
{/* 安全检查 */}
|
||||
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>体检计划</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="体检计划名称">{data.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="年度">{data.YEAR}</Descriptions.Item>
|
||||
<Descriptions.Item label="上报截止时间">{data.DUE_TIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="上报部门">{data.Nav_ListDepartment?.map((item, i) => {
|
||||
return (i > 0 ? ',' : '') + item.Nav_Department.NAME
|
||||
})}</Descriptions.Item>
|
||||
<Descriptions.Item label="计划内容">{data.CONTENT}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
{
|
||||
(data?.Nav_ListDepartment && data?.Nav_ListDepartment.length > 0) ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
{/* <tr>
|
||||
<td colSpan={10} className={styles.showPrintHead2}>体检计划人员登记</td>
|
||||
</tr> */}
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>部门</td>
|
||||
<td>接收人</td>
|
||||
<td>上报情况</td>
|
||||
</tr>
|
||||
{data?.Nav_ListDepartment?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i+1} </td>
|
||||
<td>{item.Nav_Department?.NAME} </td>
|
||||
<td>{item.Nav_User?.NAME} </td>
|
||||
<td>{enums.PFStandardStatus.enums[item.STATUS]} </td>
|
||||
|
||||
{/* <td>{item.Nav_DepartmentWorkshop?.NAME} </td> */}
|
||||
{/* <td>{item.Nav_User?.NAME} </td>
|
||||
<td>{item.Nav_User?.ID_CARD} </td>
|
||||
<td>{item.Nav_User?.SEX ? enums.FMSexEnum.enums[item.Nav_User.SEX] : ""} </td>
|
||||
<td>{item.Nav_User?.Nav_Person?.Nav_Post?.NAME} </td>
|
||||
<td>{item.WORKYEAR} </td>
|
||||
<td>{item.Nav_ListHazard?.map((itemtype, j) => { return (j > 0 ? ',' : '') + itemtype.Nav_Hazard.NAME })}</td>
|
||||
<td>{item.HEALTH_EXAM_CONTENT} </td>
|
||||
<td>{enums.OHHealthExamType.enums[item.TYPE]} </td> */}
|
||||
</tr>
|
||||
})}
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(OH003ShowPrint)
|
||||
@ -1,143 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, extendIgnoreDataRule, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove, showUserSign, showUsersSign } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class OH005ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
extendInclude(json, 'Nav_Plan.Nav_ListDepartment.Nav_Department')
|
||||
extendInclude(json, 'Nav_Plan.Nav_ListPlanRegister.Nav_Department')
|
||||
// extendInclude(json, 'Nav_Plan.Nav_ListPlanRegister.Nav_DepartmentWorkshop')
|
||||
extendInclude(json, 'Nav_Plan.Nav_ListPlanRegister.Nav_User.Nav_Person.Nav_Post')
|
||||
// extendInclude(json, 'Nav_Plan.Nav_ListPlanRegister.Nav_SCPost')
|
||||
extendInclude(json, 'Nav_Plan.Nav_ListPlanRegister.Nav_ListHazard.Nav_Hazard')
|
||||
extendIgnoreDataRule(json)
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'OH/OHHealthEaxmPlanDepartment/GetDep',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
this.setState({
|
||||
data: ret,
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon='export'>审批详情</Button></td>
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='部体检计划表' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>{ data?.Nav_Department?.NAME}体检计划表</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="体检计划名称">{data.Nav_Plan?.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="年度">{data.Nav_Plan?.YEAR}</Descriptions.Item>
|
||||
<Descriptions.Item label="上报截止时间">{data.Nav_Plan?.DUE_TIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="上报部门">{data.Nav_Plan?.Nav_ListDepartment?.map((itemt, j) => { return (j > 0 ? ',' : '') + itemt.Nav_Department.NAME })}</Descriptions.Item>
|
||||
<Descriptions.Item label="计划内容">{data.Nav_Plan?.CONTENT}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
{
|
||||
(data?.Nav_Plan.Nav_ListPlanRegister && data?.Nav_Plan.Nav_ListPlanRegister.length > 0) ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={10} className={styles.showPrintHead2}>体检计划人员登记</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>部门</td>
|
||||
{/* <td>车间</td> */}
|
||||
<td>姓名</td>
|
||||
<td>身份证号</td>
|
||||
<td>性别</td>
|
||||
<td>岗位</td>
|
||||
<td>工龄</td>
|
||||
<td>职业危害类型</td>
|
||||
<td>体检项目</td>
|
||||
<td>体检类型</td>
|
||||
</tr>
|
||||
{data?.Nav_Plan.Nav_ListPlanRegister?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{item.Nav_Department?.NAME} </td>
|
||||
{/* <td>{item.Nav_DepartmentWorkshop?.NAME} </td> */}
|
||||
<td>{item.Nav_User?.NAME} </td>
|
||||
<td>{item.Nav_User?.ID_CARD} </td>
|
||||
<td>{item.Nav_User?.SEX ? enums.FMSexEnum.enums[item.Nav_User.SEX] : ""} </td>
|
||||
<td>{item.Nav_User?.Nav_Person?.Nav_Post?.NAME} </td>
|
||||
<td>{item.WORKYEAR} </td>
|
||||
<td>{item.Nav_ListHazard?.map((itemtype, j) => { return (j > 0 ? ',' : '') + itemtype.Nav_Hazard.NAME })}</td>
|
||||
<td>{item.HEALTH_EXAM_CONTENT} </td>
|
||||
<td>{enums.OHHealthExamType.enums[item.TYPE]} </td>
|
||||
</tr>
|
||||
})}
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(OH005ShowPrint)
|
||||
@ -1,201 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendIgnoreDataRule, extendInclude, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove, showUserSign, showUsersSign } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class OH006ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
item: null,
|
||||
btndisplay: 'none',
|
||||
isTaskSign: false, //是否待办 审批
|
||||
JOINRESULT: 0, //10 参加 20 请假
|
||||
NOTJOINREASON: '',//请假原因
|
||||
isHasOpinion: false,//会议意见库
|
||||
isMinutesDetail: false,//会议纪要落实
|
||||
listSign: []//会议签到
|
||||
}
|
||||
}
|
||||
|
||||
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' + this.props.record.ID);
|
||||
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")
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: "PF123",
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
|
||||
// //审批意见 改变
|
||||
// NOTJOINREASONCHANGE = (val) => {
|
||||
// this.state.NOTJOINREASON = val
|
||||
// }
|
||||
// //请假/参加
|
||||
// sign = () => {
|
||||
// let json = initFilter(this.props.login.OrgId, this.props.data.id, null, null, null, this.props.data.TaskID);
|
||||
// this.props.dispatch({
|
||||
// type: 'app/getDataByPost',
|
||||
// payload: json,
|
||||
// url: 'SC/SCMtMeetingMinutes/MeetingMinutesSign',
|
||||
// onComplete: (ret) => {
|
||||
// if (ret) {
|
||||
// this.props.data.onCancel();
|
||||
// }
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
|
||||
// //请假/参加
|
||||
// sureCheck = (val) => {
|
||||
// if (val && val == 20 && (this.state.NOTJOINREASON == undefined || this.state.NOTJOINREASON == null || this.state.NOTJOINREASON.length < 1)) {
|
||||
// message.error("请填写请假备注!");
|
||||
// return false
|
||||
// }
|
||||
// let json = initFilter(this.props.login.OrgId, this.props.data.id, null, null, null, this.props.data.TaskID, val, this.state.NOTJOINREASON);
|
||||
// this.props.dispatch({
|
||||
// type: 'app/getDataByPost',
|
||||
// payload: json,
|
||||
// url: 'SC/SCMTMeeting/PAllCheck',
|
||||
// onComplete: (ret) => {
|
||||
// if (ret) {
|
||||
// this.props.data.onCancel();
|
||||
// }
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
|
||||
//加载数据(传过来的参数都在props里面,包括登录信息)
|
||||
loadData = (id) => {
|
||||
var taskID = this.props.data.TaskID
|
||||
var loginID = this.props.login.user.ID
|
||||
var orgId = this.props.login ? this.props.login.OrgId : ''; //登录后有存储登录信息
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id); //ID=‘’,字段,等于,条件值, 1代表=,2代表不等于,3小于,4小于等于,5大于,6大于等于,7以开始的Like,8以结束的Like,9包含
|
||||
extendIgnoreDataRule(json)
|
||||
let attendanceAry = [], leaveAry = [];
|
||||
let that = this;
|
||||
let btndisplay = 'none';
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'OH/OHHealthExamPlan/GetOH006',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
if (ret) { //判断是否有记录
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon="export">审批详情</Button></td>
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='体检计划汇总表' tableId={'tableId' + this.props.data.id} /></td>
|
||||
{/* {isTaskSign ? <td><Button className={styles.sign} type={'primary'} icon={'check'} onClick={() => this.sign()} >签到</Button></td> : null} */}
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<FormPage {...this.state.tmpData} />
|
||||
{/* 安全检查 */}
|
||||
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>体检计划汇总表</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="体检计划名称">{data.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="年度">{data.YEAR}</Descriptions.Item>
|
||||
<Descriptions.Item label="上报截止时间">{data.DUE_TIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="上报部门">{data.Nav_ListDepartment?.map((item, i) => {
|
||||
return (i > 0 ? ',' : '') + item.Nav_Department.NAME
|
||||
})}</Descriptions.Item>
|
||||
<Descriptions.Item label="计划内容">{data.CONTENT}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
{
|
||||
data?.Nav_ListPlanRegister ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
{/* <td colSpan={10} style={{ fontSize: '25px', color: '#333', margin: '20px 0 20px 0' }}>体检计划人员登记</td> */}
|
||||
<td colSpan={10} className={styles.showPrintHead2}>体检计划人员登记</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>部门</td>
|
||||
{/* <td>车间</td> */}
|
||||
<td>姓名</td>
|
||||
<td>身份证号</td>
|
||||
<td>性别</td>
|
||||
<td>岗位</td>
|
||||
<td>工龄</td>
|
||||
<td>职业危害类型</td>
|
||||
<td>体检项目</td>
|
||||
<td>体检类型</td>
|
||||
</tr>
|
||||
{data?.Nav_ListPlanRegister?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{item.Nav_Department?.NAME} </td>
|
||||
{/* <td>{item.Nav_DepartmentWorkshop?.NAME} </td> */}
|
||||
<td>{item.Nav_User?.NAME} </td>
|
||||
<td>{item.Nav_User?.ID_CARD} </td>
|
||||
<td>{enums.FMSexEnum.enums[item.Nav_User?.SEX]} </td>
|
||||
<td>{item.Nav_SCPost?.NAME} </td>
|
||||
<td>{item.WORKYEAR == 0 ? "" : item.WORKYEAR} </td>
|
||||
<td>{item.Nav_ListHazard?.map((itemtype, j) => {
|
||||
return (j > 0 ? ',' : '') + itemtype?.Nav_Hazard.NAME
|
||||
})}</td>
|
||||
<td>{item.HEALTH_EXAM_CONTENT} </td>
|
||||
<td>{enums.OHHealthExamType.enums[item.TYPE]} </td>
|
||||
</tr>
|
||||
})}
|
||||
|
||||
</tbody>
|
||||
</table> : null
|
||||
}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(OH006ShowPrint)
|
||||
@ -1,169 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendIgnoreDataRule, extendInclude, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove, showUserSign, showUsersSign } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class OH010ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
item: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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' + this.props.record.ID);
|
||||
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")
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: "PF123",
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
|
||||
//请假/参加
|
||||
sign = () => {
|
||||
let json = initFilter(this.props.login.OrgId, this.props.data.id, null, null, null, this.props.data.TaskID);
|
||||
extendIgnoreDataRule(json)
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'OH/OHHealthExamNotice/NoticeSign',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
this.props.data.onCancel();
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//加载数据(传过来的参数都在props里面,包括登录信息)
|
||||
loadData = (id) => {
|
||||
var orgId = this.props.login ? this.props.login.OrgId : ''; //登录后有存储登录信息
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id); //ID=‘’,字段,等于,条件值, 1代表=,2代表不等于,3小于,4小于等于,5大于,6大于等于,7以开始的Like,8以结束的Like,9包含
|
||||
extendIgnoreDataRule(json)
|
||||
let that = this;
|
||||
let btndisplay = 'none';
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'OH/OHHealthExamNotice/GetNotice',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
if (ret) { //判断是否有记录
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
isCheck: (that.props.data.tableKey != undefined && that.props.data.tableKey == "1") ? true : false
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data, isCheck } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon="export">审批详情</Button></td>
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='体检通知' tableId={'tableId' + this.props.data.id} /></td>
|
||||
{isCheck ? <td><Button className={styles.sign} type={'primary'} icon={'check'} onClick={() => this.sign()} >确认</Button></td> : null}
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<FormPage {...this.state.tmpData} />
|
||||
{/* 安全检查 */}
|
||||
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>体检通知</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="体检通知编号">{data.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="体检通知名称">{data.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="其他安排事项">{data.OTHER_STUFF}</Descriptions.Item>
|
||||
<Descriptions.Item label="附件">{showFiles(data.Nav_Files, config.picServerHost)}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
{
|
||||
data?.Nav_ListNoticeRegister ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={10} className={styles.showPrintHead2}>体检人员安排</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>体检类型</td>
|
||||
<td>部门</td>
|
||||
<td>用户</td>
|
||||
<td>身份证号</td>
|
||||
<td>上次体检日期</td>
|
||||
<td>职业危害类型</td>
|
||||
<td>体检批次</td>
|
||||
<td>体检时间</td>
|
||||
<td>体检地点</td>
|
||||
<td>带队人</td>
|
||||
</tr>
|
||||
{data?.Nav_ListNoticeRegister?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{enums.OHHealthExamType.enums[item.TYPE]} </td>
|
||||
<td>{item.Nav_Department?.NAME} </td>
|
||||
<td>{item.Nav_User?.NAME} </td>
|
||||
<td>{item.Nav_User.ID_CARD} </td>
|
||||
<td>{item.LASTDATE?.split(' ')[0]} </td>
|
||||
<td>{item.Nav_ListOccHazard?.map((itemtype, j) => {
|
||||
return (j > 0 ? ',' : '') + itemtype.Nav_Hazard.NAME
|
||||
})} </td>
|
||||
<td>{item.Nav_ExamBatch?.BATCH}</td>
|
||||
<td>{item.Nav_ExamBatch?.TIME} </td>
|
||||
<td>{item.Nav_ExamBatch?.LOCATION} </td>
|
||||
<td>{item.Nav_ExamBatch?.Nav_User.NAME} </td>
|
||||
</tr>
|
||||
})}
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(OH010ShowPrint)
|
||||
@ -1,148 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, extendIgnoreDataRule, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove, showUserSign, showUsersSign } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class OH012ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
extendInclude(json, 'Nav_NoticeRegister.Nav_ExamBatch');
|
||||
extendInclude(json, 'Nav_NoticeRegister.Nav_User');
|
||||
extendInclude(json, 'Nav_OccDiseaseList.Nav_OccDisease');
|
||||
extendInclude(json, 'Nav_OccDiseaseList.Nav_OccDiseaseSeverity');
|
||||
extendInclude(json, 'Nav_OccDiseaseList.Nav_Files.Nav_ImgFile.Nav_File');
|
||||
extendIgnoreDataRule(json)
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'OH/HealthExamResult/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
this.setState({
|
||||
data: ret,
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon='export'>审批详情</Button></td>
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='体检结果' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>体检结果</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="体检批次">{
|
||||
data?.Nav_NoticeRegister?.Nav_ExamBatch.BATCH
|
||||
// data?.Nav_NoticeRegister?.Nav_ExamBatch?.map((item, i) => {
|
||||
// return (i > 0 ? ',' : '') + item.BATCH
|
||||
// })
|
||||
}
|
||||
|
||||
</Descriptions.Item>
|
||||
<Descriptions.Item label="体检人员">{data?.Nav_NoticeRegister?.Nav_User.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="体检人身份证号">{data?.Nav_User?.ID_CARD}</Descriptions.Item>
|
||||
<Descriptions.Item label="体检结论">{enums.OHHealthExamResultEdit.enums[data.RESULT_ENUM]}</Descriptions.Item>
|
||||
<Descriptions.Item label="结果描述">{data.DESCRIPTION}</Descriptions.Item>
|
||||
<Descriptions.Item label="处理意见">{data.SUGGESTION}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
{
|
||||
(data?.Nav_OccDiseaseList && data?.Nav_OccDiseaseList.length > 0) ?
|
||||
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={8} className={styles.showPrintHead2}>职业病信息</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>职业病名称</td>
|
||||
<td>诊断机构</td>
|
||||
<td>诊断方式</td>
|
||||
<td>职业病严重程度</td>
|
||||
<td>病状描述</td>
|
||||
<td>入厂前工作史</td>
|
||||
<td>是否启动医疗救助</td>
|
||||
<td>附件</td>
|
||||
</tr>
|
||||
{data?.Nav_OccDiseaseList?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{item.Nav_OccDisease?.NAME}</td>
|
||||
<td>{item.DIAGNOSE_AGENCY} </td>
|
||||
<td>{item.DIAGNOSE_METHOD} </td>
|
||||
<td>{item.Nav_OccDiseaseSeverity?.NAME}</td>
|
||||
<td>{item.DESCRIPTION} </td>
|
||||
<td>{item.OCC_HISTORY} </td>
|
||||
<td>{enums.YesNoEnum.enums[item.MEDICAL_AID]} </td>
|
||||
<td>{showFiles(item.Nav_Files, config.picServerHost)} </td>
|
||||
</tr>
|
||||
})}
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(OH012ShowPrint)
|
||||
|
||||
@ -1,240 +0,0 @@
|
||||
import React from 'react';
|
||||
import { connect } from 'dva';
|
||||
import { Button, Icon, Upload, Form } from 'antd';
|
||||
import config from "../../../config.js";
|
||||
import storage from '../../../utils/storage';
|
||||
import styles from '../HI/StepForm.css';
|
||||
import { initFilter, extendRule, downLoad, extendInclude, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove, showUserSign, showUsersSign } from "../../../utils/common";
|
||||
|
||||
class OH017Import extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
fileName: props.data.fileName,
|
||||
data: null,
|
||||
Msg: '',
|
||||
isMsgShow: false,
|
||||
url: props.data.url,
|
||||
isOk: true,
|
||||
id: props.data.id,
|
||||
TaskID: props.data.TaskID,
|
||||
dataBack: []
|
||||
}
|
||||
}
|
||||
|
||||
getRequestHeaders = () => {
|
||||
// 请求参数
|
||||
const addHeader = 'Bearer ' + storage('lacal').getItem('accessToken').val
|
||||
const userId = storage('lacal').getItem('userid').val
|
||||
const user = storage('lacal').getItem('loginUserVerify').val
|
||||
const RootOrgId = storage('lacal').getItem('RootOrgId').val
|
||||
const orgId = storage('lacal').getItem('webOrgId').val
|
||||
const Tenant = storage('lacal').getItem('Tenant').val
|
||||
const headers = {
|
||||
// 'Content-Type': type === 'post' ? 'application/json' : 'application/x-www-form-urlencoded',
|
||||
Authorization: addHeader,
|
||||
userid: userId,
|
||||
username: user ? user.username : '',
|
||||
RootOrgId,
|
||||
orgId,
|
||||
Tenant: Tenant
|
||||
}
|
||||
return headers
|
||||
}
|
||||
|
||||
fillImportData = (ret) => {
|
||||
if (!ret) {
|
||||
this.setState({
|
||||
data: [],
|
||||
selectedRowKeys: [],
|
||||
messages: '',
|
||||
})
|
||||
return;
|
||||
}
|
||||
if (ret.ErrorMessage) {
|
||||
this.setState({
|
||||
messages: ('错误:' + ret.ErrorMessage)
|
||||
});
|
||||
}
|
||||
let messages = '';
|
||||
if (ret.Data && ret.Data.MessageList && ret.Data.MessageList.length) {
|
||||
var tmps = [];
|
||||
ret.Data.MessageList.forEach((n, i) => {
|
||||
tmps.push(n);
|
||||
});
|
||||
messages = tmps.join('\n');
|
||||
}
|
||||
const selectedRowKeys = [];
|
||||
if (ret.Data && ret.Data.Data) {
|
||||
ret.Data.Data.forEach((n, i) => {
|
||||
selectedRowKeys.push(n.ID);
|
||||
});
|
||||
}
|
||||
this.setState({
|
||||
data: (ret.Data && ret.Data.Data ? ret.Data.Data : []),
|
||||
selectedRowKeys,
|
||||
messages
|
||||
});
|
||||
}
|
||||
|
||||
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);
|
||||
}
|
||||
}
|
||||
loadData = (id) => {
|
||||
var orgId = this.props.login ? this.props.login.OrgId : ''; //登录后有存储登录信息
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id); //ID=‘’,字段,等于,条件值, 1代表=,2代表不等于,3小于,4小于等于,5大于,6大于等于,7以开始的Like,8以结束的Like,9包含
|
||||
let that = this;
|
||||
let btndisplay = 'none';
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'OH/OHHealthExamResult/GetImportIni',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
if (ret) { //判断是否有记录
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
isMsgShow: true,
|
||||
dataBack: ret.Nav_ListResult
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
// downLoad = (fileName) => {
|
||||
// let link = document.createElement('a')
|
||||
// // link.style.display=nonWhiteSpace
|
||||
// link.href = config.picServerHost + '/' + fileName,
|
||||
// document.body.appendChild(link)
|
||||
// link.click()
|
||||
// }
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data, Msg, fileName, isMsgShow, url, urlDown, isOk, dataBack, id, TaskID } = this.state;
|
||||
const enums = this.props.data.enums ? this.props.data.enums : this.props.app.enums;
|
||||
const that = this;
|
||||
const uploadProps = {
|
||||
name: 'file',
|
||||
action: config.serviceHost(url),
|
||||
data: { OrgId: this.props.login.OrgId, id: id, TaskID: TaskID },//, ImportConfigCode: configCode, delFlag: delFlag
|
||||
fileList: this.state.updateLoadFileList,
|
||||
accept: '.xls,.xlsx',
|
||||
headers: this.getRequestHeaders(),
|
||||
onChange(info) {
|
||||
var Msg = ''
|
||||
var isOk = true
|
||||
var dataBack = []
|
||||
if (info.file.status === 'done') {
|
||||
if (info.file.response.IsSuccessful) {
|
||||
// Msg = "【" + info.file.name + '】' + info.file.response.Data.Data
|
||||
// message.info(`${info.file.name} 导入并保存成功`);
|
||||
dataBack = info.file.response.Data
|
||||
|
||||
} else {
|
||||
//失败
|
||||
Msg = info.file.response.ErrorMessage
|
||||
isOk = false
|
||||
// message.error(`${info.file.response.ErrorMessage} `);
|
||||
}
|
||||
} else if (info.file.status === 'error') {
|
||||
isOk = false
|
||||
if (info.file.response && info.file.response.ErrorMessage) {
|
||||
Msg = "【" + info.file.name + '】导入错误,详情:' + info.file.response.ErrorMessage
|
||||
// message.error(`${info.file.name} 导入错误,详情:${info.file.response.ErrorMessage}`);
|
||||
}
|
||||
else {
|
||||
Msg = "【" + info.file.name + '】导入错误'
|
||||
}
|
||||
}
|
||||
that.setState({
|
||||
updateLoadFileList: info.fileList,
|
||||
data: info,
|
||||
Msg: '导入说明:' + Msg,
|
||||
isMsgShow: true,
|
||||
isOk: isOk,
|
||||
dataBack: dataBack
|
||||
});
|
||||
},
|
||||
};
|
||||
|
||||
return <div>
|
||||
<div style={{ padding: '10px' }}>
|
||||
<Form>
|
||||
<table>
|
||||
<tr >
|
||||
<td>
|
||||
<Upload {...uploadProps}>
|
||||
<Button>
|
||||
<Icon type="upload" /> 选择数据
|
||||
</Button>
|
||||
</Upload>
|
||||
</td>
|
||||
<td>
|
||||
<Button onClick={() => { downLoad(config.picServerHost, fileName) }}>
|
||||
<Icon type="vertical-align-bottom" /> 下载模板
|
||||
</Button>
|
||||
</td>
|
||||
</tr>
|
||||
{
|
||||
isMsgShow ? (
|
||||
isOk ? <tr >
|
||||
<td colSpan={2}>
|
||||
<div>{Msg}</div>
|
||||
</td>
|
||||
</tr>
|
||||
:
|
||||
<tr style={{ color: 'red' }}>
|
||||
<td colSpan={2}>
|
||||
<div>{Msg}</div>
|
||||
</td>
|
||||
</tr>
|
||||
)
|
||||
: null
|
||||
}
|
||||
</table>
|
||||
</Form>
|
||||
</div>
|
||||
|
||||
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>体检结果导入</h1>
|
||||
{
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>体检批次</td>
|
||||
<td>体检人员</td>
|
||||
<td>身份证号</td>
|
||||
<td>体检结论</td>
|
||||
<td>结果描述</td>
|
||||
<td>处理意见</td>
|
||||
</tr>
|
||||
{dataBack?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{item.Nav_NoticeRegister?.Nav_ExamBatch?.BATCH}</td>
|
||||
<td>{item.Nav_User?.NAME}</td>
|
||||
<td>{item.Nav_User?.ID_CARD} </td>
|
||||
<td>{item.RESULT_ENUM == 0 ? '' : enums.OHHealthExamResult.enums[item.RESULT_ENUM]} </td>
|
||||
<td>{item.DESCRIPTION} </td>
|
||||
<td>{item.SUGGESTION} </td>
|
||||
</tr>
|
||||
})}
|
||||
</tbody>
|
||||
</table>
|
||||
}
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(OH017Import)
|
||||
@ -1,171 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, extendIgnoreDataRule, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove, showUserSign, showUsersSign } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class OH024ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
extendInclude(json, 'Nav_User');
|
||||
extendInclude(json, 'Nav_Type');
|
||||
extendInclude(json, 'Nav_Detail.Nav_Rule.Nav_Type');
|
||||
extendInclude(json, 'Nav_Detail.Nav_Rule.Nav_DepartmentWorkshop');
|
||||
extendIgnoreDataRule(json)
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'OH/HazardMonitorJob/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
this.setState({
|
||||
data: ret,
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon='export'>审批详情</Button></td>
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='职业危害监测' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>职业危害监测</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="监测类型">{data?.Nav_Type?.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="监测时间">{data.MONITOR_TIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="监测人">{data.Nav_User?.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="仪器名称">{data.DEVICE_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="仪器规格/型号">{data.DEVICE_SPEC}</Descriptions.Item>
|
||||
<Descriptions.Item label="监测方法">{data.MONITOR_METHOD}</Descriptions.Item>
|
||||
{data.MONITOR_TYPE == 40 ? <Descriptions.Item label="取样人">{data.SAMPLE_PEOPLE}</Descriptions.Item> : null}
|
||||
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
{
|
||||
(data?.Nav_Detail && data?.Nav_Detail.length > 0) ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={17} className={styles.showPrintHead2}>职业危害监测明细</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>监测类别</td>
|
||||
<td>监测车间</td>
|
||||
<td>监测地点</td>
|
||||
|
||||
{data.MONITOR_TYPE == 10 ? <td>扬尘来源</td> : null}
|
||||
{data.MONITOR_TYPE == 20 ? <td>噪声来源</td> : null}
|
||||
|
||||
|
||||
{data.MONITOR_TYPE == 10 || data.MONITOR_TYPE == 20 ? <td>作业状态</td> : null}
|
||||
{data.MONITOR_TYPE == 10 || data.MONITOR_TYPE == 20 ? <td>个体防护情况</td> : null}
|
||||
{data.MONITOR_TYPE == 10 || data.MONITOR_TYPE == 20 ? <td>最低测定结果</td> : null}
|
||||
{data.MONITOR_TYPE == 10 || data.MONITOR_TYPE == 20 ? <td>最高测定结果</td> : null}
|
||||
|
||||
{data.MONITOR_TYPE == 30 ? <td>0.5m处监测值</td> : null}
|
||||
{data.MONITOR_TYPE == 30 ? <td>1m处监测值</td> : null}
|
||||
{data.MONITOR_TYPE == 30 ? <td>周围环境值</td> : null}
|
||||
|
||||
{data.MONITOR_TYPE == 40 ? <td>取样时间</td> : null}
|
||||
{data.MONITOR_TYPE == 40 ? <td>化验时间</td> : null}
|
||||
{data.MONITOR_TYPE == 40 ? <td>监测数据</td> : null}
|
||||
<td>是否超限</td>
|
||||
{data.MONITOR_TYPE == 40 ? <td>化验部门</td> : null}
|
||||
{data.MONITOR_TYPE == 40 ? <td>化验人</td> : null}
|
||||
</tr>
|
||||
{data?.Nav_Detail?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{item.Nav_Rule?.Nav_Type.SMALL_TYPE} </td>
|
||||
<td>{item.Nav_Rule?.Nav_DepartmentWorkshop.NAME} </td>
|
||||
<td>{item.Nav_Rule?.LOCATION} </td>
|
||||
|
||||
|
||||
{data.MONITOR_TYPE == 10 || data.MONITOR_TYPE == 20 ? <td>{item.SAMPLE_SOURCE} </td> : null}
|
||||
{data.MONITOR_TYPE == 10 || data.MONITOR_TYPE == 20 ? <td>{enums.OHHazardMonitorJobStageEnum.enums[item.JOB_STATUS]} </td> : null}
|
||||
{data.MONITOR_TYPE == 10 || data.MONITOR_TYPE == 20 ? <td>{enums.OHHazardMonitorJobProtectEnum.enums[item.PROTECT_STATUS]} </td> : null}
|
||||
{data.MONITOR_TYPE == 10 || data.MONITOR_TYPE == 20 ? <td>{item.MONITOR_RESULT_LOW} </td> : null}
|
||||
{data.MONITOR_TYPE == 10 || data.MONITOR_TYPE == 20 ? <td>{item.MONITOR_RESULT_HIGH} </td> : null}
|
||||
|
||||
{data.MONITOR_TYPE == 30 ? <td>{item.MONITOR_RESULT_05} </td> : null}
|
||||
{data.MONITOR_TYPE == 30 ? <td>{item.MONITOR_RESULT_10} </td> : null}
|
||||
{data.MONITOR_TYPE == 30 ? <td>{item.MONITOR_RESULT_AROUND} </td> : null}
|
||||
|
||||
|
||||
{data.MONITOR_TYPE == 40 ? <td>{item.SAMPLE_TIME} </td> : null}
|
||||
{data.MONITOR_TYPE == 40 ? <td>{item.TEST_TIME} </td> : null}
|
||||
{data.MONITOR_TYPE == 40 ? <td>{item.MONITOR_RESULT} </td> : null}
|
||||
<td>{enums.YesNoEnum.enums[item.OVER_LIMIT]} </td>
|
||||
{data.MONITOR_TYPE == 40 ? <td>{item.TEST_DEPARTMENT} </td> : null}
|
||||
{data.MONITOR_TYPE == 40 ? <td>{item.TESTER} </td> : null}
|
||||
|
||||
</tr>
|
||||
})}
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(OH024ShowPrint)
|
||||
@ -1,132 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, extendIgnoreDataRule, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove, showUserSign, showUsersSign } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class OH028ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
extendInclude(json, 'Nav_ListMonitorResult.Nav_Rule.Nav_Type');
|
||||
extendInclude(json, 'Nav_ListMonitorResult.Nav_Rule.Nav_DepartmentWorkshop');
|
||||
extendIgnoreDataRule(json)
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'OH/OHHazardMonitorResultSum/GetSumEdit',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
ret.STR_RATIO = ret.RATIO * 100 + '%'
|
||||
this.setState({
|
||||
data: ret,
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = this.state;
|
||||
return <div>
|
||||
<div style={{ padding: '10px' }}>
|
||||
<table>
|
||||
<tr>
|
||||
<td><Button onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon='export'>审批详情</Button></td>
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='监测结果统计汇总' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>监测结果统计汇总</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="分析年度">{data.YEAR}</Descriptions.Item>
|
||||
<Descriptions.Item label="汇总日期">{data.TIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="分析比率">{data.STR_RATIO}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
{
|
||||
(data?.Nav_ListMonitorResult && data?.Nav_ListMonitorResult.length > 0) ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={7} className={styles.showPrintHead2}>监测结果明细</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>职业危害监测项目</td>
|
||||
<td>监测车间</td>
|
||||
<td>监测地点</td>
|
||||
<td>监测数</td>
|
||||
<td>合格数</td>
|
||||
<td>合格率</td>
|
||||
<td>趋势分析</td>
|
||||
</tr>
|
||||
{data?.Nav_ListMonitorResult?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{item.Nav_Rule.Nav_Type.NAME} </td>
|
||||
<td>{item.Nav_Rule.Nav_DepartmentWorkshop.NAME} </td>
|
||||
<td>{item.Nav_Rule.LOCATION} </td>
|
||||
<td>{item.MONITOR_COUNT} </td>
|
||||
<td>{item.OK_COUNT} </td>
|
||||
<td>{item.OK_PERCENT} </td>
|
||||
<td>{item.TREND} </td>
|
||||
</tr>
|
||||
})}
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login }) => ({ login }))(OH028ShowPrint)
|
||||
|
||||
@ -1,102 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, extendIgnoreDataRule, setDataFieldValue, showApprove, guid, initQueryFilter, ShowDateTime, ShowPrintClose, showFiles } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class OH034ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File')
|
||||
extendIgnoreDataRule(json)
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'OH/HazardMonitorJobReport/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
this.setState({
|
||||
data: ret,
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = this.state;
|
||||
return <div>
|
||||
<div style={{ padding: '10px' }}>
|
||||
<table>
|
||||
<tr>
|
||||
<td><Button onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon='export'>审批详情</Button></td>
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='职业危害监测报告' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>职业危害监测报告</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="年度">{data.YEAR}</Descriptions.Item>
|
||||
<Descriptions.Item label="文件名称">{data.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="监测单位">{data.DEPARTMENTNAME_JOB}</Descriptions.Item>
|
||||
<Descriptions.Item label="监测开始日期">{data.BEGINTIME_MONITOR?.split(' ')[0]}</Descriptions.Item>
|
||||
<Descriptions.Item label="监测结束日期">{data.ENDTIME_MONITOR?.split(' ')[0]}</Descriptions.Item>
|
||||
<Descriptions.Item label="附件">{showFiles(data.Nav_Files, config.picServerHost)}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login }) => ({ login }))(OH034ShowPrint)
|
||||
@ -1,173 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, extendIgnoreDataRule, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class TI008ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
item: null,
|
||||
btndisplay: 'none'
|
||||
}
|
||||
}
|
||||
|
||||
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' + this.props.record.ID);
|
||||
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")
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: "PF123",
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
|
||||
//审批意见 改变
|
||||
NOTJOINREASONCHANGE = (val) => {
|
||||
this.state.NOTJOINREASON = val
|
||||
}
|
||||
|
||||
|
||||
//加载数据(传过来的参数都在props里面,包括登录信息)
|
||||
loadData = (id) => {
|
||||
var taskID = this.props.data.TaskID
|
||||
// var loginID = this.props.login.user.ID
|
||||
var orgId = this.props.login ? this.props.login.OrgId : ''; //登录后有存储登录信息
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id); //ID=‘’,字段,等于,条件值, 1代表=,2代表不等于,3小于,4小于等于,5大于,6大于等于,7以开始的Like,8以结束的Like,9包含
|
||||
|
||||
extendInclude(json, 'Nav_Department');
|
||||
extendInclude(json, 'Nav_User');
|
||||
extendInclude(json, 'Nav_SafePdtCostRecordType.Nav_CostType');
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File');
|
||||
extendInclude(json, 'Nav_Approve.Nav_ApproveDetails.Nav_ApproveUser.Nav_UserSignFiles.Nav_ImgFile.Nav_File');
|
||||
extendIgnoreDataRule(json)
|
||||
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TI/SafePdtCostRecord/Get',// url: 'SC/MtMeeting/Get',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
if (ret) { //判断是否有记录
|
||||
var isTaskCheck = false
|
||||
var isHasOpinion = false
|
||||
if (ret.STATUS == 30 && taskID != undefined && taskID.length > 0) {
|
||||
if (ret.USER_ID_HOST == loginID || ret.USER_ID_RECORDER == loginID) {
|
||||
//后台查看 task 是否已经操作过
|
||||
isTaskCheck = true
|
||||
}
|
||||
if (!isTaskCheck) {
|
||||
for (let i = 0; i < ret.Nav_ListPAll.length; i++) {
|
||||
// JOINRESULT
|
||||
// debugger
|
||||
if (ret.Nav_ListPAll[i].USER_ID == loginID && (ret.Nav_ListPAll[i].JOINRESULT == undefined || ret.Nav_ListPAll[i].JOINRESULT == null)) {
|
||||
isTaskCheck = true
|
||||
break
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (isTaskCheck && ((that.props.data.tableKey == null) || (that.props.data.tableKey != undefined && that.props.data.tableKey == "2"))) {
|
||||
isTaskCheck = false
|
||||
}
|
||||
|
||||
if (ret.Nav_ListMeetingContent != null && ret.Nav_ListMeetingContent.length > 0) {
|
||||
for (let j = 0; j < ret.Nav_ListMeetingContent.length; j++) {
|
||||
if (!isHasOpinion && ret.Nav_ListMeetingContent[j].Nav_ContentName != null && ret.Nav_ListMeetingContent[j].Nav_ContentName.Nav_ListContent != null && ret.Nav_ListMeetingContent[j].Nav_ContentName.Nav_ListContent.length > 0) {
|
||||
isHasOpinion = true
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
isTaskCheck: isTaskCheck,//有taskID 状态 审核完成 登陆者 属于参会人
|
||||
isHasOpinion: isHasOpinion//有会议意见
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data, isTaskCheck, isHasOpinion } = this.state;
|
||||
return <div>
|
||||
<div style={{ padding: '10px' }}>
|
||||
<table>
|
||||
<tr>
|
||||
<td><Button onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon="export">审批详情</Button></td>
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='安全生产费用使用记录' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<FormPage {...this.state.tmpData} />
|
||||
{/* 安全检查 */}
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>安全生产费用使用记录</h1>
|
||||
{
|
||||
data ? <div>
|
||||
<Descriptions title="" size="middle" bordered>
|
||||
<Descriptions.Item label="使用日期">{data.USETIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="使用部门">{data.Nav_Department.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="记录人">{data.Nav_User.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="使用项目" >{data.PROJECT}</Descriptions.Item>
|
||||
<Descriptions.Item label="费用类型">{
|
||||
data.Nav_SafePdtCostRecordType?.map((item, i) => {
|
||||
return (i > 0 ? "," : "") + item.Nav_CostType.NAME
|
||||
})
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="用途">{data.PURPOSE}</Descriptions.Item>
|
||||
<Descriptions.Item label="单位">{data.UNIT}</Descriptions.Item>
|
||||
<Descriptions.Item label="数量">{data.COUNT}</Descriptions.Item>
|
||||
<Descriptions.Item label="使用金额(万元)">{data.USE_AMOUNT}</Descriptions.Item>
|
||||
<Descriptions.Item label="附件" span={3}>{
|
||||
showFiles(data.Nav_Files, config.picServerHost)
|
||||
}</Descriptions.Item>
|
||||
{
|
||||
data.STATUS > 20 ?
|
||||
<Descriptions.Item label="审阅意见" span={3}>{
|
||||
showApprove(data.Nav_Approve?.Nav_ApproveDetails, this.props.app.enums.NodeApproveStatus.enums, config.picServerHost, 100)
|
||||
}</Descriptions.Item>
|
||||
: null
|
||||
}
|
||||
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(TI008ShowPrint)
|
||||
@ -1,169 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, ShowDateTime, extendIgnoreDataRule, extendRule, extendInclude, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove, extendFilterGroup, initFilterGroup } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
let ids = [];
|
||||
class TI008ShowPrints extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
item: null,
|
||||
total: 0,
|
||||
btndisplay: 'none'
|
||||
}
|
||||
}
|
||||
|
||||
componentDidMount() {
|
||||
// if (this.props.data?.id)
|
||||
// this.loadData(this.props.data?.id);
|
||||
}
|
||||
|
||||
componentWillReceiveProps(NextProps) {
|
||||
let nextIds = NextProps.data?.getTableSelectedRowKeys();
|
||||
if (nextIds != ids) {
|
||||
ids = nextIds;
|
||||
this.loadData(nextIds);
|
||||
}
|
||||
}
|
||||
|
||||
onTableBtnExport() {
|
||||
// let TableWrap = document.getElementById('table1' + this.props.record.ID);
|
||||
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")
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: "PF123",
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
|
||||
//审批意见 改变
|
||||
NOTJOINREASONCHANGE = (val) => {
|
||||
this.state.NOTJOINREASON = val
|
||||
}
|
||||
|
||||
|
||||
//加载数据(传过来的参数都在props里面,包括登录信息)
|
||||
loadData = (id) => {
|
||||
var taskID = this.props.data.TaskID
|
||||
// var loginID = this.props.login.user.ID
|
||||
var orgId = this.props.login ? this.props.login.OrgId : ''; //登录后有存储登录信息
|
||||
let json = initFilter(orgId);
|
||||
let group = initFilterGroup(false);
|
||||
for (let i = 0; i < id.length; i++) {
|
||||
let rule = {
|
||||
Field: "ID",
|
||||
Operate: 1,
|
||||
Value: id[i]
|
||||
}
|
||||
group.Rules.push(rule);
|
||||
}
|
||||
extendFilterGroup(json, group);
|
||||
// extendInclude(json, 'Nav_Department');
|
||||
// extendInclude(json, 'Nav_User');
|
||||
extendInclude(json, 'Nav_SafePdtCostRecordType.Nav_CostType');
|
||||
extendIgnoreDataRule(json)
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TI/SafePdtCostRecord/OrderPaged',// url: 'SC/MtMeeting/Get',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
var total = 0
|
||||
if (ret.length > 0) {
|
||||
for (let i = 0; i < ret.length; i++) {
|
||||
total += ret[i].USE_AMOUNT
|
||||
}
|
||||
}
|
||||
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
total: total
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data, total } = this.state;
|
||||
return <div>
|
||||
<div style={{ padding: '10px' }}>
|
||||
<table>
|
||||
<tr>
|
||||
{/* <td><Button onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon="export">审批详情</Button></td> */}
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='安全生产费用使用记录' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<FormPage {...this.state.tmpData} />
|
||||
{/* 安全检查 */}
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>安全生产费用使用情况</h1>
|
||||
{/*安全生产费用使用记录SSSSSSSS */}
|
||||
|
||||
{
|
||||
data ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>使用日期</td>
|
||||
{/* <td>使用部门</td> */}
|
||||
{/* <td>记录人</td> */}
|
||||
<td>使用项目</td>
|
||||
<td>费用类型</td>
|
||||
<td>单位</td>
|
||||
<td>数量</td>
|
||||
<td>金额(万元)</td>
|
||||
<td>用途</td>
|
||||
</tr>
|
||||
{data?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1}</td>
|
||||
<td>{ShowDateTime(item.USETIME)}</td>
|
||||
{/* <td>{item.Nav_Department.NAME}</td> */}
|
||||
{/* <td>{item.Nav_User.NAME}</td> */}
|
||||
<td>{item.PROJECT}</td>
|
||||
<td>{
|
||||
item.Nav_SafePdtCostRecordType?.map((item, i) => {
|
||||
return (i > 0 ? "," : "") + item.Nav_CostType.NAME
|
||||
})
|
||||
}</td>
|
||||
<td>{item.UNIT}</td>
|
||||
<td>{item.COUNT}</td>
|
||||
<td>{item.USE_AMOUNT}</td>
|
||||
<td>{item.PURPOSE}</td>
|
||||
</tr>
|
||||
})}
|
||||
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>总金额</td>
|
||||
<td colSpan={7}>{total}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(TI008ShowPrints)
|
||||
@ -1,174 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, extendIgnoreDataRule, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class TI010ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
item: null,
|
||||
btndisplay: 'none'
|
||||
}
|
||||
}
|
||||
|
||||
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' + this.props.record.ID);
|
||||
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")
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: "PF123",
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
|
||||
//审批意见 改变
|
||||
NOTJOINREASONCHANGE = (val) => {
|
||||
this.state.NOTJOINREASON = val
|
||||
}
|
||||
|
||||
|
||||
//加载数据(传过来的参数都在props里面,包括登录信息)
|
||||
loadData = (id) => {
|
||||
var taskID = this.props.data.TaskID
|
||||
// var loginID = this.props.login.user.ID
|
||||
var orgId = this.props.login ? this.props.login.OrgId : ''; //登录后有存储登录信息
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id); //ID=‘’,字段,等于,条件值, 1代表=,2代表不等于,3小于,4小于等于,5大于,6大于等于,7以开始的Like,8以结束的Like,9包含
|
||||
|
||||
extendInclude(json, 'Nav_Department');
|
||||
extendInclude(json, 'Nav_User');
|
||||
extendInclude(json, 'Nav_Sources.Nav_Source');
|
||||
extendInclude(json, 'Nav_Ranges.Nav_Range');
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File');
|
||||
extendInclude(json, 'Nav_ListProject.Nav_Manger');
|
||||
// extendInclude(json, 'Nav_Approve.Nav_ApproveDetails.Nav_ApproveUser.Nav_UserSignFiles.Nav_ImgFile.Nav_File');
|
||||
extendIgnoreDataRule(json)
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TI/Plan/Get',// url: 'SC/MtMeeting/Get',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data, isTaskCheck, isHasOpinion } = this.state;
|
||||
return <div>
|
||||
<div style={{ padding: '10px' }}>
|
||||
<table>
|
||||
<tr>
|
||||
{/* <td><Button onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon="export">审批详情</Button></td> */}
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='安全科技计划' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<FormPage {...this.state.tmpData} />
|
||||
{/* 安全检查 */}
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>安全科技计划</h1>
|
||||
{
|
||||
data ? <div>
|
||||
<Descriptions title="" size="middle" bordered>
|
||||
<Descriptions.Item label="发起时间">{data.BEGINTIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="发起部门">{data.Nav_Department.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="发起人">{data.Nav_User.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="计划年度" >{data.YEAR}</Descriptions.Item>
|
||||
|
||||
|
||||
<Descriptions.Item label="项目来源">{
|
||||
data.Nav_Sources?.map((item, i) => {
|
||||
return (i > 0 ? "," : "") + item.Nav_Source.NAME
|
||||
})
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="项目范围">{
|
||||
data.Nav_Ranges?.map((item, i) => {
|
||||
return (i > 0 ? "," : "") + item.Nav_Range.NAME
|
||||
})
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="附件" span={3}>{
|
||||
showFiles(data.Nav_Files, config.picServerHost)
|
||||
}</Descriptions.Item>
|
||||
|
||||
{/* {
|
||||
data.STATUS > 20 ?
|
||||
<Descriptions.Item label="审阅意见" span={3}>{
|
||||
showApprove(data.Nav_Approve?.Nav_ApproveDetails, this.props.app.enums.NodeApproveStatus.enums, config.picServerHost,100,50)
|
||||
}</Descriptions.Item>
|
||||
: null
|
||||
} */}
|
||||
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
|
||||
{
|
||||
(data?.Nav_ListProject && data?.Nav_ListProject.length > 0) ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={5} className={styles.showPrintHead2}>安全科技计划明细</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>项目编号</td>
|
||||
<td>项目名称</td>
|
||||
<td>申报经费(万元)</td>
|
||||
<td>是否涉外</td>
|
||||
<td>项目负责人</td>
|
||||
</tr>
|
||||
{data?.Nav_ListProject?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{item.CODE} </td>
|
||||
<td>{item.NAME} </td>
|
||||
<td>{item.MONEY} </td>
|
||||
<td>{item?.IS_FOREIGN == true ? "是" : "否"} </td>
|
||||
<td>{item.Nav_Manger.NAME} </td>
|
||||
</tr>
|
||||
})}
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
|
||||
|
||||
|
||||
</div >
|
||||
</div >
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(TI010ShowPrint)
|
||||
@ -1,145 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, extendIgnoreDataRule, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class TI012ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
item: null,
|
||||
btndisplay: 'none'
|
||||
}
|
||||
}
|
||||
|
||||
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' + this.props.record.ID);
|
||||
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")
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: "PF123",
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
|
||||
//审批意见 改变
|
||||
NOTJOINREASONCHANGE = (val) => {
|
||||
this.state.NOTJOINREASON = val
|
||||
}
|
||||
|
||||
|
||||
//加载数据(传过来的参数都在props里面,包括登录信息)
|
||||
loadData = (id) => {
|
||||
var taskID = this.props.data.TaskID
|
||||
// var loginID = this.props.login.user.ID
|
||||
var orgId = this.props.login ? this.props.login.OrgId : ''; //登录后有存储登录信息
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id); //ID=‘’,字段,等于,条件值, 1代表=,2代表不等于,3小于,4小于等于,5大于,6大于等于,7以开始的Like,8以结束的Like,9包含
|
||||
|
||||
extendInclude(json, 'Nav_Department');
|
||||
extendInclude(json, 'Nav_User');
|
||||
extendInclude(json, 'Nav_Manger');
|
||||
extendInclude(json, 'Nav_Sources.Nav_Source');
|
||||
extendInclude(json, 'Nav_Ranges.Nav_Range');
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File');
|
||||
extendInclude(json, 'Nav_WFFiles.Nav_ImgFile.Nav_File');
|
||||
// extendInclude(json, 'Nav_Approve.Nav_ApproveDetails.Nav_ApproveUser.Nav_UserSignFiles.Nav_ImgFile.Nav_File');
|
||||
extendIgnoreDataRule(json)
|
||||
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TI/Project/Get',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data, isTaskCheck, isHasOpinion } = this.state;
|
||||
return <div>
|
||||
<div style={{ padding: '10px' }}>
|
||||
<table>
|
||||
<tr>
|
||||
{/* <td><Button onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon="export">审批详情</Button></td> */}
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='安全科技计划' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<FormPage {...this.state.tmpData} />
|
||||
{/* 安全检查 */}
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>安全科技计划</h1>
|
||||
{
|
||||
data ? <div>
|
||||
<Descriptions title="" size="middle" bordered>
|
||||
<Descriptions.Item label="发起时间">{data.BEGINTIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="发起部门">{data.Nav_Department.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="发起人">{data.Nav_User.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="计划年度" >{data.YEAR}</Descriptions.Item>
|
||||
|
||||
<Descriptions.Item label="项目来源">{
|
||||
data.Nav_Sources?.map((item, i) => {
|
||||
return (i > 0 ? "," : "") + item.Nav_Source.NAME
|
||||
})
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="项目范围">{
|
||||
data.Nav_Ranges?.map((item, i) => {
|
||||
return (i > 0 ? "," : "") + item.Nav_Range.NAME
|
||||
})
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="项目编号" >{data.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="项目名称" >{data.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="申报经费(万元)" >{data.MONEY}</Descriptions.Item>
|
||||
<Descriptions.Item label="是否涉外" >{(data.IS_FOREIGN != undefined && data.IS_FOREIGN == true) ? "是" : "否"}</Descriptions.Item>
|
||||
<Descriptions.Item label="项目负责人" >{data.Nav_Manger.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="计划年度" >{data.YEAR}</Descriptions.Item>
|
||||
<Descriptions.Item label="立项附件" span={3}>{
|
||||
showFiles(data.Nav_Files, config.picServerHost)
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="审批附件" span={3}>{
|
||||
showFiles(data.Nav_WFFiles, config.picServerHost)
|
||||
}</Descriptions.Item>
|
||||
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(TI012ShowPrint)
|
||||
@ -1,153 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, extendIgnoreDataRule, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class TI014ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
item: null,
|
||||
btndisplay: 'none'
|
||||
}
|
||||
}
|
||||
|
||||
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' + this.props.record.ID);
|
||||
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")
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: "PF123",
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
|
||||
//审批意见 改变
|
||||
NOTJOINREASONCHANGE = (val) => {
|
||||
this.state.NOTJOINREASON = val
|
||||
}
|
||||
|
||||
|
||||
//加载数据(传过来的参数都在props里面,包括登录信息)
|
||||
loadData = (id) => {
|
||||
var taskID = this.props.data.TaskID
|
||||
// var loginID = this.props.login.user.ID
|
||||
var orgId = this.props.login ? this.props.login.OrgId : ''; //登录后有存储登录信息
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id); //ID=‘’,字段,等于,条件值, 1代表=,2代表不等于,3小于,4小于等于,5大于,6大于等于,7以开始的Like,8以结束的Like,9包含
|
||||
|
||||
extendInclude(json, 'Nav_Department');
|
||||
extendInclude(json, 'Nav_User');
|
||||
extendInclude(json, 'Nav_Project.Nav_Manger');
|
||||
extendInclude(json, 'Nav_Project.Nav_Sources.Nav_Source');
|
||||
extendInclude(json, 'Nav_Project.Nav_Ranges.Nav_Range');
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File');
|
||||
extendInclude(json, 'Nav_WFFiles.Nav_ImgFile.Nav_File');
|
||||
// extendInclude(json, 'Nav_Approve.Nav_ApproveDetails.Nav_ApproveUser.Nav_UserSignFiles.Nav_ImgFile.Nav_File');
|
||||
extendIgnoreDataRule(json)
|
||||
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TI/ProjectCheck/Get',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data, isTaskCheck, isHasOpinion } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon="export">审批详情</Button></td> */}
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='项目结题验收' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<FormPage {...this.state.tmpData} />
|
||||
{/* 安全检查 */}
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>项目结题验收</h1>
|
||||
{
|
||||
data ? <div>
|
||||
<Descriptions title="" size="middle" bordered>
|
||||
<Descriptions.Item label="发起时间">{data.BEGINTIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="发起部门">{data.Nav_Department.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="发起人">{data.Nav_User.NAME}</Descriptions.Item>
|
||||
|
||||
|
||||
<Descriptions.Item label="项目编号">{data.Nav_Project.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="项目名称">{data.Nav_Project.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="计划年度" >{data.Nav_Project.YEAR}</Descriptions.Item>
|
||||
|
||||
<Descriptions.Item label="项目来源">{
|
||||
data.Nav_Project?.Nav_Sources?.map((item, i) => {
|
||||
return (i > 0 ? "," : "") + item.Nav_Source.NAME
|
||||
})
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="项目范围">{
|
||||
data.Nav_Project?.Nav_Ranges?.map((item, i) => {
|
||||
return (i > 0 ? "," : "") + item.Nav_Range.NAME
|
||||
})
|
||||
}</Descriptions.Item>
|
||||
|
||||
|
||||
|
||||
<Descriptions.Item label="实际使用经费(万元)" >{data.MONEY}</Descriptions.Item>
|
||||
<Descriptions.Item label="是否涉外" >{(data.Nav_Project.IS_FOREIGN != undefined && data.Nav_Project.IS_FOREIGN == true) ? "是" : "否"}</Descriptions.Item>
|
||||
<Descriptions.Item label="项目负责人" >{data.Nav_Project.Nav_Manger.NAME}</Descriptions.Item>
|
||||
|
||||
<Descriptions.Item label="验收结果" >{enums.TIProjectResult.enums[data.RESULT]}</Descriptions.Item>
|
||||
|
||||
<Descriptions.Item label="项目成果附件" span={3}>{
|
||||
showFiles(data.Nav_Files, config.picServerHost)
|
||||
}</Descriptions.Item>
|
||||
<Descriptions.Item label="审批附件" span={3}>{
|
||||
showFiles(data.Nav_WFFiles, config.picServerHost)
|
||||
}</Descriptions.Item>
|
||||
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(TI014ShowPrint)
|
||||
@ -1,164 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, extendIgnoreDataRule, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class TI016ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
item: null,
|
||||
btndisplay: 'none',
|
||||
ALLTOTAL: 0,
|
||||
ALLUSE: 0,
|
||||
ALLLEFT: 0
|
||||
}
|
||||
}
|
||||
|
||||
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' + this.props.record.ID);
|
||||
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")
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: "PF123",
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
|
||||
//审批意见 改变
|
||||
NOTJOINREASONCHANGE = (val) => {
|
||||
this.state.NOTJOINREASON = val
|
||||
}
|
||||
|
||||
|
||||
//加载数据(传过来的参数都在props里面,包括登录信息)
|
||||
loadData = (id) => {
|
||||
var taskID = this.props.data.TaskID
|
||||
// var loginID = this.props.login.user.ID
|
||||
var orgId = this.props.login ? this.props.login.OrgId : ''; //登录后有存储登录信息
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id); //ID=‘’,字段,等于,条件值, 1代表=,2代表不等于,3小于,4小于等于,5大于,6大于等于,7以开始的Like,8以结束的Like,9包含
|
||||
|
||||
extendInclude(json, 'Nav_Project.Nav_Manger');
|
||||
extendInclude(json, 'Nav_Details.Nav_Files.Nav_ImgFile.Nav_File');
|
||||
extendIgnoreDataRule(json)
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TI/ProjectMoney/Get',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
var allTOTAL = 0
|
||||
var allUSE = 0
|
||||
var allLEFT = 0
|
||||
if (ret.Nav_Details != null && ret.Nav_Details.length > 0) {
|
||||
for (let i = 0; i < ret.Nav_Details.length; i++) {
|
||||
allTOTAL += ret.Nav_Details[i].TOTAL
|
||||
allUSE += ret.Nav_Details[i].USE
|
||||
allLEFT += ret.Nav_Details[i].LEFT
|
||||
}
|
||||
}
|
||||
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
ALLTOTAL: allTOTAL,
|
||||
ALLUSE: allUSE,
|
||||
ALLLEFT: allLEFT
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data, ALLTOTAL, ALLUSE, ALLLEFT } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon="export">审批详情</Button></td> */}
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='项目结题验收' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<FormPage {...this.state.tmpData} />
|
||||
{/* 安全检查 */}
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>项目结题验收</h1>
|
||||
{
|
||||
data ? <div>
|
||||
<Descriptions title="" size="middle" bordered>
|
||||
<Descriptions.Item label="项目名称">{data.Nav_Project.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="项目编号">{data.Nav_Project.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="项目负责人" >{data.Nav_Project.Nav_Manger.NAME}</Descriptions.Item>
|
||||
|
||||
<Descriptions.Item label="专项经费合计(万元)">{ALLTOTAL}</Descriptions.Item>
|
||||
<Descriptions.Item label="支出经费合计(万元)">{ALLUSE}</Descriptions.Item>
|
||||
<Descriptions.Item label="剩余经费(万元)">{ALLLEFT}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
{
|
||||
data?.Nav_Details ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>科目名称</td>
|
||||
<td>专项经费(万元)</td>
|
||||
<td>支出经费(万元)</td>
|
||||
<td>剩余经费(万元)</td>
|
||||
<td>凭单上传</td>
|
||||
</tr>
|
||||
{data.Nav_Details?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1}</td>
|
||||
<td>{item.NAME}</td>
|
||||
<td>{item.TOTAL}</td>
|
||||
<td>{item.USE}</td>
|
||||
<td>{item.LEFT}</td>
|
||||
<td>{
|
||||
showFiles(item.Nav_Files, config.picServerHost)
|
||||
}</td>
|
||||
</tr>
|
||||
})}
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(TI016ShowPrint)
|
||||
@ -1,155 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, ShowDateTime, extendIgnoreDataRule, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class TI018ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
item: null,
|
||||
btndisplay: 'none',
|
||||
INSURE_DURATION: 0
|
||||
}
|
||||
}
|
||||
|
||||
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' + this.props.record.ID);
|
||||
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")
|
||||
}
|
||||
|
||||
//加载数据(传过来的参数都在props里面,包括登录信息)
|
||||
loadData = (id) => {
|
||||
var taskID = this.props.data.TaskID
|
||||
var orgId = this.props.login ? this.props.login.OrgId : ''; //登录后有存储登录信息
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id); //ID=‘’,字段,等于,条件值, 1代表=,2代表不等于,3小于,4小于等于,5大于,6大于等于,7以开始的Like,8以结束的Like,9包含
|
||||
extendInclude(json, 'Nav_User.Nav_Person.Nav_Post');
|
||||
extendInclude(json, 'Nav_User.Nav_Department');
|
||||
extendIgnoreDataRule(json)
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TI/TIInsuranceRecord/GetUserRecord',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data, INSURE_DURATION } = 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><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='参保信息' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<FormPage {...this.state.tmpData} />
|
||||
{/* 安全检查 */}
|
||||
{/* <div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>参保记录</h1>
|
||||
{
|
||||
data ? <div>
|
||||
<Descriptions title="" size="middle" bordered>
|
||||
<Descriptions.Item label="参保类型">{enums.TIInsuranceTypeEnum.enums[data.TYPE]}</Descriptions.Item>
|
||||
<Descriptions.Item label="附件" span={3}>{
|
||||
showFiles(data.Nav_Files, config.picServerHost)
|
||||
}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
{
|
||||
data?.Nav_UserList ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>工号</td>
|
||||
<td>姓名</td>
|
||||
<td>性别</td>
|
||||
<td>部门名称</td>
|
||||
<td>岗位名称</td>
|
||||
<td>身份证 </td>
|
||||
<td>参保时间</td>
|
||||
<td>参保状态</td>
|
||||
<td>停缴时间</td>
|
||||
</tr>
|
||||
{data.Nav_UserList?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1}</td>
|
||||
<td>{item.Nav_User.CODE} </td>
|
||||
<td>{item.Nav_User.NAME}</td>
|
||||
<td>{item.Nav_User.SEX} </td>
|
||||
<td>{item.DEPARTMENTNAME} </td>
|
||||
<td>{item.USERPOSTNAME} </td>
|
||||
<td>{item.Nav_User.ID_CARD} </td>
|
||||
<td>{item.INSURE_TIME} </td>
|
||||
<td>{enums.TIInsuranceStatusEnum.enums[item.INSURE_STATUS] } </td>
|
||||
<td>{item.STOP_TIME} </td>
|
||||
</tr>
|
||||
})}
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
</div> */}
|
||||
|
||||
|
||||
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>参保信息</h1>
|
||||
{
|
||||
data ? <div>
|
||||
<Descriptions title="" size="middle" bordered>
|
||||
<Descriptions.Item label="工号">{data.Nav_User.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="姓名">{data.Nav_User.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="性别">{enums.FMSexEnum.enums[data.Nav_User.SEX]}</Descriptions.Item>
|
||||
<Descriptions.Item label="部门名称">{data.Nav_User.Nav_Department.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="岗位名称">{data.Nav_User.Nav_Person.Nav_Post.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="身份证">{data.Nav_User.ID_CARD}</Descriptions.Item>
|
||||
<Descriptions.Item label="参保类型">{enums.TIInsuranceTypeEnum.enums[data.TYPE]}</Descriptions.Item>
|
||||
<Descriptions.Item label="参保时间">{ShowDateTime(data.INSURE_TIME)}</Descriptions.Item>
|
||||
<Descriptions.Item label="参保状态">{enums.TIInsuranceStatusEnum.enums[data.INSURE_STATUS]}</Descriptions.Item>
|
||||
<Descriptions.Item label="停缴时间">{ShowDateTime(data.STOP_TIME)}</Descriptions.Item>
|
||||
<Descriptions.Item label="参保期限(月)">{data.INSURE_DURATION}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(TI018ShowPrint)
|
||||
@ -1,133 +0,0 @@
|
||||
import { Checkbox, message, Radio } from "antd/lib/index";
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, extendIgnoreDataRule, setDataFieldValue, guid, initQueryFilter, showFiles, showApprove } from "../../../utils/common";
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import styles from '../HI/StepForm.css';
|
||||
import ReactToPrint from "react-to-print";
|
||||
import moment from 'moment';
|
||||
import config from "../../../config.js";
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import FormPage from '../../FormPage'
|
||||
|
||||
class TI021ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
item: null,
|
||||
btndisplay: 'none'
|
||||
}
|
||||
}
|
||||
|
||||
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' + this.props.record.ID);
|
||||
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")
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: "PF123",
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
|
||||
//审批意见 改变
|
||||
NOTJOINREASONCHANGE = (val) => {
|
||||
this.state.NOTJOINREASON = val
|
||||
}
|
||||
|
||||
|
||||
//加载数据(传过来的参数都在props里面,包括登录信息)
|
||||
loadData = (id) => {
|
||||
var taskID = this.props.data.TaskID
|
||||
// var loginID = this.props.login.user.ID
|
||||
var orgId = this.props.login ? this.props.login.OrgId : ''; //登录后有存储登录信息
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id); //ID=‘’,字段,等于,条件值, 1代表=,2代表不等于,3小于,4小于等于,5大于,6大于等于,7以开始的Like,8以结束的Like,9包含
|
||||
|
||||
extendInclude(json, 'Nav_Department');
|
||||
extendInclude(json, 'Nav_User');
|
||||
extendInclude(json, 'Nav_Accident');
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File');
|
||||
extendIgnoreDataRule(json)
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TI/InsuranceClaimRecord/Get',
|
||||
onComplete: (ret) => { //返回查询结果ret
|
||||
this.setState({ //设置setState全局变量
|
||||
data: ret, //将ret对象赋值给data, data供页面调用
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//渲染页面
|
||||
render() {
|
||||
const { data, ALLTOTAL, ALLUSE, ALLLEFT } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon="export">审批详情</Button></td> */}
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} pageStyle={"#tableId" + this.props.data.id + " { padding:0 40px;} img{width :120px}"} /></td>
|
||||
<td><ExportToExcel fileName='工伤保险理赔信息' tableId={'tableId' + this.props.data.id} /></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<FormPage {...this.state.tmpData} />
|
||||
{/* 安全检查 */}
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>工伤保险理赔信息</h1>
|
||||
{
|
||||
data ? <div>
|
||||
<Descriptions title="" size="middle" bordered>
|
||||
<Descriptions.Item label="发起部门">{data.Nav_Department.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="姓名">{data.Nav_User.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="事故事件">{data.Nav_Accident.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="受伤日期">{data.INJURE_TIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="受伤部位/疾病名称">{data.INJURE_DETAIL}</Descriptions.Item>
|
||||
<Descriptions.Item label="是否住院">{enums.YesNoEnum.enums[data.IN_HOSPITAL]}</Descriptions.Item>
|
||||
<Descriptions.Item label="就诊医院">{data.HOSPITAL}</Descriptions.Item>
|
||||
<Descriptions.Item label="员工报销金额(元)">{data.USER_CLAIM_AMOUNT}</Descriptions.Item>
|
||||
<Descriptions.Item label="社保报销金额(元)">{data.INSURANCE_CLAIM_AMOUNT}</Descriptions.Item>
|
||||
<Descriptions.Item label="工伤认定时间">{data.INJURE_AFFIRM_TIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="工伤认定机构">{data.INJURE_AFFIRM_AGENCY}</Descriptions.Item>
|
||||
<Descriptions.Item label="伤残等级">{enums.TIDisabilityLevelEnum.enums[data.DISABILITY_LEVEL]}</Descriptions.Item>
|
||||
<Descriptions.Item label="伤残认定时间">{data.DISABILITY_AFFIRM_TIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="伤残认定机构">{data.DISABILITY_AFFIRM_AGENCY}</Descriptions.Item>
|
||||
<Descriptions.Item label="备注">{data.REMARK}</Descriptions.Item>
|
||||
{/* <Descriptions.Item label="附件">{data.Nav_Files}</Descriptions.Item>
|
||||
<Descriptions.Item label="参保类型">{enums.TIInsuranceTypeEnum.enums[data.TYPE]}</Descriptions.Item> */}
|
||||
<Descriptions.Item label="附件" span={3}>{
|
||||
showFiles(data.Nav_Files, config.picServerHost)
|
||||
}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(TI021ShowPrint)
|
||||
@ -1,100 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, setDataFieldValue, showApprove, guid, initQueryFilter, ShowDateTime, ShowPrintClose, showFiles } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class TL004ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
// extendInclude(json, 'Nav_Tailing')
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File')
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/FileSum/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
this.setState({
|
||||
data: ret,
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon='export'>审批详情</Button></td>
|
||||
<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>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>文件集合</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="尾矿库">{data.TAILING_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="消息内容">{data.CONTENT}</Descriptions.Item>
|
||||
<Descriptions.Item label="附件">{showFiles(data.Nav_Files, config.picServerHost)}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login }) => ({ login }))(TL004ShowPrint)
|
||||
@ -1,111 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, setDataFieldValue, showApprove, guid, initQueryFilter, ShowDateTime, ShowPrintClose, showFiles } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class TL006ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
// extendInclude(json, 'Nav_Tailing')
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File')
|
||||
extendInclude(json, 'Nav_FilesWatch.Nav_ImgFile.Nav_File')
|
||||
extendInclude(json, 'Nav_FilesCheck.Nav_ImgFile.Nav_File')
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/ProjectRecord/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
this.setState({
|
||||
data: ret,
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon='export'>审批详情</Button></td>
|
||||
<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>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>单项工程记录管理</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="尾矿库">{data.TAILING_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="项目编号">{data.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="项目名称">{data.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="施工记录">{showFiles(data.Nav_Files, config.picServerHost)}</Descriptions.Item>
|
||||
<Descriptions.Item label="施工是否满足规程及安全、健康要求">{enums.Result.enums[data.RESULT]}</Descriptions.Item>
|
||||
<Descriptions.Item label="不满足描述">{data.RESULT_REASON}</Descriptions.Item>
|
||||
<Descriptions.Item label="监理记录">{showFiles(data.Nav_FilesWatch, config.picServerHost)}</Descriptions.Item>
|
||||
<Descriptions.Item label="安全设施是否与主体工程同时设计、同时施工、同时投入生产和使用">{enums.Result.enums[data.RESULT_CHECK]}</Descriptions.Item>
|
||||
<Descriptions.Item label="不同时描述">{data.RESULT_CHECK_REASON}</Descriptions.Item>
|
||||
<Descriptions.Item label="验收记录">{showFiles(data.Nav_FilesCheck, config.picServerHost)}</Descriptions.Item>
|
||||
<Descriptions.Item label="验收是否按照规程进行">{enums.Result.enums[data.RESULT_WATCH]}</Descriptions.Item>
|
||||
<Descriptions.Item label="未遵守描述">{data.RESULT_WATCH_REASON}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(TL006ShowPrint)
|
||||
@ -1,103 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, setDataFieldValue, showApprove, guid, initQueryFilter, ShowDateTime, ShowPrintClose, showFiles } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class TL008ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
// extendInclude(json, 'Nav_Tailing')
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File')
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/ProjectHight/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
this.setState({
|
||||
data: ret,
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon='export'>审批详情</Button></td>
|
||||
<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>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>隐蔽工程验收管理</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="尾矿库">{data.TAILING_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="项目编号">{data.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="工程名称">{data.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="隐蔽工程验收记录">{showFiles(data.Nav_Files, config.picServerHost)}</Descriptions.Item>
|
||||
<Descriptions.Item label="是否验收合格后进行下一阶段施工">{enums.FMTureOrFalse.enums[data.RESULT]}</Descriptions.Item>
|
||||
<Descriptions.Item label="不合格描述">{data.RESULT_REASON}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(TL008ShowPrint)
|
||||
@ -1,103 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, setDataFieldValue, showApprove, guid, initQueryFilter, ShowDateTime, ShowPrintClose, showFiles } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class TL010ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
// extendInclude(json, 'Nav_Tailing')
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File')
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/ProjectFinish/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
this.setState({
|
||||
data: ret,
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon='export'>审批详情</Button></td>
|
||||
<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>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>安全设施竣工验收</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="尾矿库">{data.TAILING_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="项目编号">{data.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="工程名称">{data.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="安全设施竣工验收">{showFiles(data.Nav_Files, config.picServerHost)}</Descriptions.Item>
|
||||
<Descriptions.Item label="是否妥善保存了所有勘察、设计、施工纪录和验收文件和图纸">{enums.FMTureOrFalse.enums[data.RESULT]}</Descriptions.Item>
|
||||
<Descriptions.Item label="不妥善说明">{data.RESULT_REASON}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(TL010ShowPrint)
|
||||
@ -1,164 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, setDataFieldValue, showApprove, guid, initQueryFilter, ShowDateTime, ShowPrintClose, showFiles } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class TL014ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
extendInclude(json, 'Nav_ListBackRequire.Nav_Require')
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File')
|
||||
extendInclude(json, 'Nav_ListDetail.Nav_ListDetailUser.Nav_User')
|
||||
json.IgnoreDataRule = true
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/Back/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
if (ret.Nav_ListDetail != null && ret.Nav_ListDetail.length > 0) {
|
||||
ret.Nav_ListDetail.sort(function (a, b) {
|
||||
return b.NUM > a.NUM ? -1 : 1
|
||||
})
|
||||
}
|
||||
|
||||
if (isCheck) {
|
||||
isCheck = ret.STATUS == 10 ? true : false
|
||||
}
|
||||
this.setState({
|
||||
data: ret,
|
||||
isCheck: isCheck
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//确认
|
||||
sureCheck = () => {
|
||||
let json = initFilter(this.props.login.OrgId, this.props.data.id, null, null, null, this.props.data.TaskID);
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/TLBack/sendCheck',
|
||||
onComplete: (ret) => {
|
||||
this.BtnClose()
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
BtnClose = () => {
|
||||
if (typeof this.props.data.onCancel != "undefined" && typeof this.props.data.onCancel == 'function')
|
||||
this.props.data.onCancel();
|
||||
}
|
||||
|
||||
render() {
|
||||
const { data, isCheck } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon='export'>审批详情</Button></td>
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} /></td>
|
||||
{/* <td><Button type={'primary'} icon={'check'} onClick={() => this.sureCheck()} >确认</Button> </td> */}
|
||||
<td><ExportToExcel fileName='回采计划' tableId={'tableId' + this.props.data.id} /></td>
|
||||
{
|
||||
isCheck ? <td><Button type={'primary'} icon={'check'} onClick={() => this.sureCheck()} >确认</Button> </td> : null
|
||||
}
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>回采计划</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="尾矿库">{data.TAILING_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="项目编号">{data.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="工程名称">{data.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="制定要求">{data.Nav_ListBackRequire?.map((item, i) => {
|
||||
return (i > 0 ? ',' : '') + item.Nav_Require.NAME
|
||||
})}</Descriptions.Item>
|
||||
<Descriptions.Item label="回采计划">{showFiles(data.Nav_Files, config.picServerHost)}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
{
|
||||
(data?.Nav_ListDetail && data?.Nav_ListDetail.length > 0) ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={4} className={styles.showPrintHead2}>计划明细</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>回踩日期</td>
|
||||
<td>回踩开始时间</td>
|
||||
<td>回踩结束时间</td>
|
||||
<td>值班人</td>
|
||||
</tr>
|
||||
{data?.Nav_ListDetail?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{item.DATE?.split(' ')[0]} </td>
|
||||
<td>{item.DATESTART?.split(' ')[1]} </td>
|
||||
<td>{item.DATEEND?.split(' ')[1]} </td>
|
||||
<td>{item.Nav_ListDetailUser?.map((itemtype, j) => { return (j > 0 ? ' ' : '') + itemtype.Nav_User.NAME })}</td>
|
||||
</tr>
|
||||
})}
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login }) => ({ login }))(TL014ShowPrint)
|
||||
@ -1,149 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, setDataFieldValue, showApprove, guid, initQueryFilter, ShowDateTime, ShowPrintClose, showUsersSign } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class TL016ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: false, //是否待办 审批
|
||||
listSign: []
|
||||
}
|
||||
}
|
||||
|
||||
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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
extendInclude(json, 'Nav_ListUser.Nav_User.Nav_UserSignFiles.Nav_ImgFile.Nav_File')
|
||||
json.IgnoreDataRule = true
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/BackRecord/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
if (isCheck) {
|
||||
isCheck = ret.STATUS == 10 ? true : false
|
||||
}
|
||||
let listSign = []
|
||||
ret.Nav_ListUser.forEach(e => {
|
||||
if (e.ISCHECK)
|
||||
listSign.push(e)
|
||||
})
|
||||
|
||||
this.setState({
|
||||
data: ret,
|
||||
isCheck: isCheck,
|
||||
listSign: listSign
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
//确认
|
||||
sureCheck = () => {
|
||||
let json = initFilter(this.props.login.OrgId, this.props.data.id, null, null, null, this.props.data.TaskID);
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/TLBackRecord/sendCheck',
|
||||
onComplete: (ret) => {
|
||||
this.BtnClose()
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
BtnClose = () => {
|
||||
if (typeof this.props.data.onCancel != "undefined" && typeof this.props.data.onCancel == 'function')
|
||||
this.props.data.onCancel();
|
||||
}
|
||||
|
||||
render() {
|
||||
const { data, isCheck, listSign } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon='export'>审批详情</Button></td>
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} /></td>
|
||||
<td><ExportToExcel fileName='回采记录' tableId={'tableId' + this.props.data.id} /></td>
|
||||
{
|
||||
isCheck ? <td><Button type={'primary'} icon={'check'} onClick={() => this.sureCheck()} >确认</Button> </td> : null
|
||||
}
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>回采记录</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="尾矿库">{data.TAILING_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="回采开始时间(时)">{data.BACKTIME}</Descriptions.Item>
|
||||
<Descriptions.Item label="回采结束时间(时)">{data.BACKTIMEEND?.split(' ')[1]}</Descriptions.Item>
|
||||
<Descriptions.Item label="工程名称">{data.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="回采方向">{data.BACK_DIREACT}</Descriptions.Item>
|
||||
<Descriptions.Item label="回采顺序">{enums.BackOrder.enums[data.BACK_ORDER]}</Descriptions.Item>
|
||||
<Descriptions.Item label="回采厚度(m)">{data.BACK_THICKNESS}</Descriptions.Item>
|
||||
<Descriptions.Item label="回采量(m³)">{data.BACK_NUMBER}</Descriptions.Item>
|
||||
<Descriptions.Item label="回采边坡坡比">{data.BACK_SCALE}</Descriptions.Item>
|
||||
<Descriptions.Item label="安全超高(m)">{data.SAFE_HIGHT}</Descriptions.Item>
|
||||
<Descriptions.Item label="干滩长度(m)">{data.DRIVE_LONG}</Descriptions.Item>
|
||||
<Descriptions.Item label="值班人">{data.Nav_ListUser?.map((item, i) => {
|
||||
return item.ISCHECK ? item.Nav_User.NAME : <a style={{ color: "red" }}>{item.Nav_User.NAME}</a>
|
||||
})}</Descriptions.Item>
|
||||
|
||||
<Descriptions.Item label="值班人签名">{
|
||||
showUsersSign(listSign, config.picServerHost, 200)
|
||||
}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(TL016ShowPrint)
|
||||
@ -1,100 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, setDataFieldValue, showApprove, guid, initQueryFilter, ShowDateTime, ShowPrintClose, showFiles } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class TL018ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
// extendInclude(json, 'Nav_Tailing')
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File')
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/Out/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
this.setState({
|
||||
data: ret,
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon='export'>审批详情</Button></td>
|
||||
<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>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>尾矿库注销</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="尾矿库">{data.TAILING_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="注销日期">{data.OUTDATE?.split(' ')[0]}</Descriptions.Item>
|
||||
<Descriptions.Item label="尾矿库注销文件">{showFiles(data.Nav_Files, config.picServerHost)}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login }) => ({ login }))(TL018ShowPrint)
|
||||
@ -1,101 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, setDataFieldValue, showApprove, guid, initQueryFilter, ShowDateTime, ShowPrintClose, showFiles } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class TL025ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
// extendInclude(json, 'Nav_Tailing')
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File')
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/QualityCheck/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
this.setState({
|
||||
data: ret,
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon='export'>审批详情</Button></td>
|
||||
<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>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>子坝质量验收</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="尾矿库">{data.TAILING_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="项目编号">{data.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="工程名称">{data.NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="子坝质量验收记录">{showFiles(data.Nav_Files, config.picServerHost)}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login }) => ({ login }))(TL025ShowPrint)
|
||||
@ -1,101 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, setDataFieldValue, showApprove, guid, initQueryFilter, ShowDateTime, ShowPrintClose, showFiles } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class TL027ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
// extendInclude(json, 'Nav_Tailing')
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File')
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/Caculate/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
this.setState({
|
||||
data: ret,
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon='export'>审批详情</Button></td>
|
||||
<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>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>调洪演算报告</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="项目编号">{data.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="尾矿库">{data.TAILING_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="日期">{data.DATE?.split(' ')[0]}</Descriptions.Item>
|
||||
<Descriptions.Item label="调洪演算报告">{showFiles(data.Nav_Files, config.picServerHost)}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login }) => ({ login }))(TL027ShowPrint)
|
||||
@ -1,101 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, setDataFieldValue, showApprove, guid, initQueryFilter, ShowDateTime, ShowPrintClose, showFiles } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class TL029ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
// extendInclude(json, 'Nav_Tailing')
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File')
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/ProjectIntroduce/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
this.setState({
|
||||
data: ret,
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon='export'>审批详情</Button></td>
|
||||
<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>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>上游工程情况说明</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="项目编号">{data.CODE}</Descriptions.Item>
|
||||
<Descriptions.Item label="尾矿库">{data.TAILING_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="日期">{data.DATE?.split(' ')[0]}</Descriptions.Item>
|
||||
<Descriptions.Item label="上游工程情况说明">{showFiles(data.Nav_Files, config.picServerHost)}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login }) => ({ login }))(TL029ShowPrint)
|
||||
@ -1,166 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, setDataFieldValue, showApprove, guid, initQueryFilter, ShowDateTime, showUsersSign, showFiles } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class TL037ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
sureCheck = () => {
|
||||
let json = initFilter(this.props.login.OrgId, this.props.data.id, null, null, null, this.props.data.TaskID);
|
||||
extendRule(json, 'ID', 1, this.props.data.id);
|
||||
extendRule(json, "Parameter1", 1, this.props.data.TaskID)
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/TLWatchDayly/sendCheck',
|
||||
onComplete: (ret) => {
|
||||
this.BtnClose()
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
BtnClose = () => {
|
||||
if (typeof this.props.data.onCancel != "undefined" && typeof this.props.data.onCancel == 'function')
|
||||
this.props.data.onCancel();
|
||||
}
|
||||
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
// extendInclude(json, 'Nav_Tailing')
|
||||
extendInclude(json, 'Nav_ListDetail.Nav_ListUser.Nav_User.Nav_UserSignFiles.Nav_ImgFile.Nav_File')
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/WatchDayly/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
let users = []
|
||||
let userID = []
|
||||
if (ret.Nav_ListDetail && ret.Nav_ListDetail.length > 0) {
|
||||
ret.Nav_ListDetail.forEach(e => {
|
||||
if (e.Nav_ListUser != null && e.Nav_ListUser.length > 0) {
|
||||
e.Nav_ListUser.forEach(eu => {
|
||||
if (eu.ISCHECK && eu.ISCHECK == true && userID.indexOf(eu.USER_ID) == -1) {
|
||||
userID.push(eu.USER_ID)
|
||||
users.push(eu)
|
||||
}
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
this.setState({
|
||||
data: ret,
|
||||
isCheck: isCheck,
|
||||
users: users
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = this.state;
|
||||
return <div>
|
||||
<div style={{ padding: '10px' }}>
|
||||
<table>
|
||||
<tr>
|
||||
<td><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} /></td>
|
||||
<td><ExportToExcel fileName='尾矿库日常观测记录表' tableId={'tableId' + this.props.data.id} /></td>
|
||||
{
|
||||
this.state.isCheck ? <td><Button type={'primary'} icon={'check'} onClick={() => this.sureCheck()} >确认</Button> </td> : null
|
||||
}
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>尾矿库日常观测记录表</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="尾矿库">{data.TAILING_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="日期">{data.DATE?.split(' ')[0]}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
{
|
||||
(data?.Nav_ListDetail && data?.Nav_ListDetail.length > 0) ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={7} className={styles.showPrintHead2}>尾矿库日常观测记录明细</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>观测时间(时)</td>
|
||||
<td>干滩长度/m</td>
|
||||
<td>库水位/m</td>
|
||||
<td>降雨量/mm</td>
|
||||
<td>滩顶高程/m</td>
|
||||
<td>安全超高/m</td>
|
||||
<td>观测人</td>
|
||||
</tr>
|
||||
{data?.Nav_ListDetail?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{item.DATE?.split(' ')[1]} </td>
|
||||
<td>{item.LONG} </td>
|
||||
<td>{item.WATERLINE} </td>
|
||||
<td>{item.DREEP} </td>
|
||||
<td>{item.HIGHTEST} </td>
|
||||
<td>{item.HIGHT_MORE} </td>
|
||||
<td>{item.Nav_ListUser?.map((itemtype, j) => { return (j > 0 ? ',' : '') + itemtype.Nav_User.NAME })}</td>
|
||||
</tr>
|
||||
})}
|
||||
|
||||
|
||||
<tr >
|
||||
<td>签名</td>
|
||||
<td colSpan={6}>{
|
||||
showUsersSign(this.state.users, config.picServerHost)
|
||||
}</td>
|
||||
</tr>
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login }) => ({ login }))(TL037ShowPrint)
|
||||
@ -1,160 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, showUsersSign } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class TL039ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
sureCheck = () => {
|
||||
let json = initFilter(this.props.login.OrgId, this.props.data.id, null, null, null, this.props.data.TaskID);
|
||||
extendRule(json, 'ID', 1, this.props.data.id);
|
||||
extendRule(json, "Parameter1", 1, this.props.data.TaskID)
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/TLWatchPercent/sendCheck',
|
||||
onComplete: (ret) => {
|
||||
this.BtnClose()
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
BtnClose = () => {
|
||||
if (typeof this.props.data.onCancel != "undefined" && typeof this.props.data.onCancel == 'function')
|
||||
this.props.data.onCancel();
|
||||
}
|
||||
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
// extendInclude(json, 'Nav_Tailing')
|
||||
extendInclude(json, 'Nav_ListDetail.Nav_ListUser.Nav_User.Nav_UserSignFiles.Nav_ImgFile.Nav_File')
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/WatchPercent/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
let users = []
|
||||
let userID = []
|
||||
if (ret.Nav_ListDetail && ret.Nav_ListDetail.length > 0) {
|
||||
ret.Nav_ListDetail.forEach(e => {
|
||||
if (e.Nav_ListUser != null && e.Nav_ListUser.length > 0) {
|
||||
e.Nav_ListUser.forEach(eu => {
|
||||
if (eu.ISCHECK && eu.ISCHECK == true && userID.indexOf(eu.USER_ID) == -1) {
|
||||
userID.push(eu.USER_ID)
|
||||
users.push(eu)
|
||||
}
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
this.setState({
|
||||
data: ret,
|
||||
isCheck: isCheck,
|
||||
users: users
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = 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><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} /></td>
|
||||
<td><ExportToExcel fileName='坡比观测' tableId={'tableId' + this.props.data.id} /></td>
|
||||
{
|
||||
this.state.isCheck ? <td><Button type={'primary'} icon={'check'} onClick={() => this.sureCheck()} >确认</Button> </td> : null
|
||||
}
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>坡比观测</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="尾矿库">{data.TAILING_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="日期">{data.DATE?.split(' ')[0]}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
{
|
||||
(data?.Nav_ListDetail && data?.Nav_ListDetail.length > 0) ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={4} className={styles.showPrintHead2}>坡比观测明细</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>观测时间(时)</td>
|
||||
<td>内坡比</td>
|
||||
<td>外坡比</td>
|
||||
<td>观测人</td>
|
||||
</tr>
|
||||
{data?.Nav_ListDetail?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{item.DATE?.split(' ')[1]} </td>
|
||||
<td>{item.INT_PERCENT} </td>
|
||||
<td>{item.OUT_PERCENT} </td>
|
||||
<td>{item.Nav_ListUser?.map((itemtype, j) => { return (j > 0 ? ',' : '') + itemtype.Nav_User.NAME })}</td>
|
||||
</tr>
|
||||
})}
|
||||
|
||||
<tr >
|
||||
<td>签名</td>
|
||||
<td colSpan={6}>{
|
||||
showUsersSign(this.state.users, config.picServerHost)
|
||||
}</td>
|
||||
</tr>
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login }) => ({ login }))(TL039ShowPrint)
|
||||
@ -1,165 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, showUsersSign, showApprove, guid, initQueryFilter, ShowDateTime, ShowPrintClose, showFiles } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class TL041ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
sureCheck = () => {
|
||||
let json = initFilter(this.props.login.OrgId, this.props.data.id, null, null, null, this.props.data.TaskID);
|
||||
extendRule(json, 'ID', 1, this.props.data.id);
|
||||
extendRule(json, "Parameter1", 1, this.props.data.TaskID)
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/TLWatchMove/sendCheck',
|
||||
onComplete: (ret) => {
|
||||
this.BtnClose()
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
BtnClose = () => {
|
||||
if (typeof this.props.data.onCancel != "undefined" && typeof this.props.data.onCancel == 'function')
|
||||
this.props.data.onCancel();
|
||||
}
|
||||
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
// extendInclude(json, 'Nav_Tailing')
|
||||
extendInclude(json, 'Nav_ListDetail.Nav_WatchMovePoint')
|
||||
extendInclude(json, 'Nav_ListDetail.Nav_ListUser.Nav_User.Nav_UserSignFiles.Nav_ImgFile.Nav_File')
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/WatchMove/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
let users = []
|
||||
let userID = []
|
||||
if (ret.Nav_ListDetail && ret.Nav_ListDetail.length > 0) {
|
||||
ret.Nav_ListDetail.forEach(e => {
|
||||
if (e.Nav_ListUser != null && e.Nav_ListUser.length > 0) {
|
||||
e.Nav_ListUser.forEach(eu => {
|
||||
if (eu.ISCHECK && eu.ISCHECK == true && userID.indexOf(eu.USER_ID) == -1) {
|
||||
userID.push(eu.USER_ID)
|
||||
users.push(eu)
|
||||
}
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
this.setState({
|
||||
data: ret,
|
||||
isCheck: isCheck,
|
||||
users: users
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = 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><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} /></td>
|
||||
<td><ExportToExcel fileName='位移观测' tableId={'tableId' + this.props.data.id} /></td>
|
||||
{
|
||||
this.state.isCheck ? <td><Button type={'primary'} icon={'check'} onClick={() => this.sureCheck()} >确认</Button> </td> : null
|
||||
}
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>位移观测</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="尾矿库">{data.TAILING_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="日期">{data.DATE?.split(' ')[0]}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
{
|
||||
(data?.Nav_ListDetail && data?.Nav_ListDetail.length > 0) ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={7} className={styles.showPrintHead2}>位移观测明细</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>观测时间(时)</td>
|
||||
<td>基准点号</td>
|
||||
<td>原坐标X/Y/Z</td>
|
||||
<td>观测点号</td>
|
||||
<td>观测值X/Y/Z</td>
|
||||
<td>变化量△X/△Y/△Z</td>
|
||||
<td>观测人</td>
|
||||
</tr>
|
||||
{data?.Nav_ListDetail?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{item.DATE?.split(' ')[1]} </td>
|
||||
<td>{item.Nav_WatchMovePoint?.NAME_BASE}</td>
|
||||
<td>{item.Nav_WatchMovePoint?.POINT_BASE} </td>
|
||||
<td>{item.Nav_WatchMovePoint?.NAME_WATCH} </td>
|
||||
<td>{item.LOOKPOINT} </td>
|
||||
<td>{item.CHANGELOOKPOINT} </td>
|
||||
<td>{item.Nav_ListUser?.map((itemtype, j) => { return (j > 0 ? ',' : '') + itemtype.Nav_User.NAME })}</td>
|
||||
</tr>
|
||||
})}
|
||||
<tr >
|
||||
<td>签名</td>
|
||||
<td colSpan={6}>{
|
||||
showUsersSign(this.state.users, config.picServerHost)
|
||||
}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login }) => ({ login }))(TL041ShowPrint)
|
||||
@ -1,163 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, setDataFieldValue, showApprove, guid, initQueryFilter, ShowDateTime, ShowPrintClose, showUsersSign } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class TL043ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
sureCheck = () => {
|
||||
let json = initFilter(this.props.login.OrgId, this.props.data.id, null, null, null, this.props.data.TaskID);
|
||||
extendRule(json, 'ID', 1, this.props.data.id);
|
||||
extendRule(json, "Parameter1", 1, this.props.data.TaskID)
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/TLWatchLine/sendCheck',
|
||||
onComplete: (ret) => {
|
||||
this.BtnClose()
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
BtnClose = () => {
|
||||
if (typeof this.props.data.onCancel != "undefined" && typeof this.props.data.onCancel == 'function')
|
||||
this.props.data.onCancel();
|
||||
}
|
||||
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
// extendInclude(json, 'Nav_Tailing')
|
||||
extendInclude(json, 'Nav_ListDetail.Nav_WatchLinePoint')
|
||||
extendInclude(json, 'Nav_ListDetail.Nav_ListUser.Nav_User.Nav_UserSignFiles.Nav_ImgFile.Nav_File')
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/WatchLine/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
let users = []
|
||||
let userID = []
|
||||
if (ret.Nav_ListDetail && ret.Nav_ListDetail.length > 0) {
|
||||
ret.Nav_ListDetail.forEach(e => {
|
||||
if (e.Nav_ListUser != null && e.Nav_ListUser.length > 0) {
|
||||
e.Nav_ListUser.forEach(eu => {
|
||||
if (eu.ISCHECK && eu.ISCHECK == true && userID.indexOf(eu.USER_ID) == -1) {
|
||||
userID.push(eu.USER_ID)
|
||||
users.push(eu)
|
||||
}
|
||||
})
|
||||
}
|
||||
});
|
||||
}
|
||||
this.setState({
|
||||
data: ret,
|
||||
isCheck: isCheck,
|
||||
users: users
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = 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><ReactToPrint trigger={() => <Button type={'default'} icon={'printer'} >打印</Button>} content={() => this.componentRef} /></td>
|
||||
<td><ExportToExcel fileName='浸润线观测' tableId={'tableId' + this.props.data.id} /></td>
|
||||
{
|
||||
this.state.isCheck ? <td><Button type={'primary'} icon={'check'} onClick={() => this.sureCheck()} >确认</Button> </td> : null
|
||||
}
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>浸润线观测</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="尾矿库名称">{data.TAILING_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="日期">{data.DATE?.split(' ')[0]}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
{
|
||||
(data?.Nav_ListDetail && data?.Nav_ListDetail.length > 0) ?
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={6} className={styles.showPrintHead2}>浸润线观测明细</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>观测时间(时)</td>
|
||||
<td>位置</td>
|
||||
<td>孔号</td>
|
||||
<td>孔深</td>
|
||||
<td>浸润线埋深/m</td>
|
||||
<td>观测人员</td>
|
||||
</tr>
|
||||
{data?.Nav_ListDetail?.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{item.DATE?.split(' ')[1]} </td>
|
||||
<td>{item.Nav_WatchLinePoint?.LOCATION}</td>
|
||||
<td>{item.Nav_WatchLinePoint?.POINT_NO} </td>
|
||||
<td>{item.Nav_WatchLinePoint?.POINT_DEEP} </td>
|
||||
<td>{item.DEEP} </td>
|
||||
<td>{item.Nav_ListUser?.map((itemtype, j) => { return (j > 0 ? ',' : '') + itemtype.Nav_User.NAME })}</td>
|
||||
</tr>
|
||||
})}
|
||||
<tr >
|
||||
<td>签名</td>
|
||||
<td colSpan={6}>{
|
||||
showUsersSign(this.state.users, config.picServerHost)
|
||||
}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
: null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login }) => ({ login }))(TL043ShowPrint)
|
||||
@ -1,260 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, setDataFieldValue, showApprove, guid, initQueryFilter, ShowDateTime, showUsersSign, showFiles } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class TL044ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
// extendInclude(json, 'Nav_Tailing')
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/TLWatchSum/GetALL',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
this.setState({
|
||||
data: ret,
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = 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><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>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>人工观测汇总</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="尾矿库名称">{data.TAILING_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="日期">{data.DATE?.split(' ')[0]}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={8} className={styles.showPrintHead2}>日常观测记录</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>观测时间(时)</td>
|
||||
<td>干滩长度/m</td>
|
||||
<td>库水位/m</td>
|
||||
<td>降雨量/mm</td>
|
||||
<td>滩顶高程/m</td>
|
||||
<td>安全超高/m</td>
|
||||
<td>观测人</td>
|
||||
</tr>
|
||||
{
|
||||
data && data.Nav_ListDetailDayly && data.Nav_ListDetailDayly.length > 0 ?
|
||||
data.Nav_ListDetailDayly.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1} </td>
|
||||
<td>{item.DATE?.split(' ')[1]} </td>
|
||||
<td>{item.LONG} </td>
|
||||
<td>{item.WATERLINE} </td>
|
||||
<td>{item.DREEP} </td>
|
||||
<td>{item.HIGHTEST} </td>
|
||||
<td>{item.HIGHT_MORE} </td>
|
||||
<td>{item.Nav_ListUser?.map((itemtype, j) => { return (j > 0 ? ',' : '') + itemtype.Nav_User.NAME })}</td>
|
||||
</tr>
|
||||
})
|
||||
:
|
||||
<tr><td colSpan={8}>查无数据</td></tr>
|
||||
}
|
||||
{
|
||||
data && data.Nav_ListSignDayly && data.Nav_ListSignDayly.length > 0 ?
|
||||
<tr >
|
||||
<td > 观测人签名 </td>
|
||||
<td colSpan={7} style={{ textAlign: "left" }}> {showUsersSign(data.Nav_ListSignDayly, config.picServerHost, 200)}</td>
|
||||
</tr>
|
||||
: null
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={5} className={styles.showPrintHead2}>坡比观测记录</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>观测时间(时)</td>
|
||||
<td>内坡比</td>
|
||||
<td>外坡比</td>
|
||||
<td>观测人</td>
|
||||
</tr>
|
||||
{
|
||||
data && data.Nav_ListDetailPercent && data.Nav_ListDetailPercent.length > 0 ?
|
||||
data.Nav_ListDetailPercent.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1} </td>
|
||||
<td>{item.DATE?.split(' ')[1]} </td>
|
||||
<td>{item.INT_PERCENT} </td>
|
||||
<td>{item.OUT_PERCENT} </td>
|
||||
<td>{item.Nav_ListUser?.map((itemtype, j) => { return (j > 0 ? ',' : '') + itemtype.Nav_User.NAME })}</td>
|
||||
</tr>
|
||||
})
|
||||
: <tr><td colSpan={5}>查无数据</td></tr>
|
||||
}
|
||||
{
|
||||
data && data.Nav_ListSignPercent && data.Nav_ListSignPercent.length > 0 ?
|
||||
<tr >
|
||||
<td > 观测人签名 </td>
|
||||
<td colSpan={7} style={{ textAlign: "left" }}> {showUsersSign(data.Nav_ListSignPercent, config.picServerHost, 200)}</td>
|
||||
</tr>
|
||||
: null
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={8} className={styles.showPrintHead2}>位移观测记录</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>观测时间(时)</td>
|
||||
<td>基准点号</td>
|
||||
<td>原坐标X/Y/Z</td>
|
||||
<td>观测点号</td>
|
||||
<td>观测值X/Y/Z</td>
|
||||
<td>变化量△X/△Y/△Z</td>
|
||||
<td>观测人</td>
|
||||
</tr>
|
||||
{
|
||||
|
||||
data && data.Nav_ListDetailMovd && data.Nav_ListDetailMovd.length > 0 ?
|
||||
data.Nav_ListDetailMovd.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1} </td>
|
||||
<td>{item.DATE?.split(' ')[1]} </td>
|
||||
<td>{item.Nav_WatchMovePoint?.NAME_BASE}</td>
|
||||
<td>{item.Nav_WatchMovePoint?.POINT_BASE} </td>
|
||||
<td>{item.Nav_WatchMovePoint?.NAME_WATCH} </td>
|
||||
<td>{item.LOOKPOINT} </td>
|
||||
<td>{item.CHANGELOOKPOINT} </td>
|
||||
<td>{item.Nav_ListUser?.map((itemtype, j) => { return (j > 0 ? ',' : '') + itemtype.Nav_User.NAME })}</td>
|
||||
</tr>
|
||||
})
|
||||
: <tr><td colSpan={8}>查无数据</td></tr>
|
||||
}
|
||||
{
|
||||
data && data.Nav_ListSignMovd && data.Nav_ListSignMovd.length > 0 ?
|
||||
<tr >
|
||||
<td > 观测人签名 </td>
|
||||
<td colSpan={7} style={{ textAlign: "left" }}> {showUsersSign(data.Nav_ListSignMovd, config.picServerHost, 200)}</td>
|
||||
</tr>
|
||||
: null
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<table className={styles.PrintFormLight}>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td colSpan={7} className={styles.showPrintHead2}>浸润线观测记录</td>
|
||||
</tr>
|
||||
<tr className={styles.PrintFormLightTh}>
|
||||
<td>序号</td>
|
||||
<td>观测时间(时)</td>
|
||||
<td>位置</td>
|
||||
<td>孔号</td>
|
||||
<td>孔深</td>
|
||||
<td>浸润线埋深/m</td>
|
||||
<td>观测人员</td>
|
||||
</tr>
|
||||
{
|
||||
data && data.Nav_ListDetailLine && data.Nav_ListDetailLine.length > 0 ?
|
||||
data.Nav_ListDetailLine.map((item, i) => {
|
||||
return <tr>
|
||||
<td>{i + 1} </td>
|
||||
<td>{item.DATE?.split(' ')[1]} </td>
|
||||
<td>{item.Nav_WatchLinePoint?.LOCATION}</td>
|
||||
<td>{item.Nav_WatchLinePoint?.POINT_NO} </td>
|
||||
<td>{item.Nav_WatchLinePoint?.POINT_DEEP} </td>
|
||||
<td>{item.DEEP} </td>
|
||||
<td>{item.Nav_ListUser?.map((itemtype, j) => { return (j > 0 ? ',' : '') + itemtype.Nav_User.NAME })}</td>
|
||||
</tr>
|
||||
})
|
||||
: <tr><td colSpan={7}>查无数据</td></tr>
|
||||
}
|
||||
{
|
||||
data && data.Nav_ListSignLine && data.Nav_ListSignLine.length > 0 ?
|
||||
<tr >
|
||||
<td > 观测人签名 </td>
|
||||
<td colSpan={7} style={{ textAlign: "left" }}> {showUsersSign(data.Nav_ListSignLine, config.picServerHost, 200)}</td>
|
||||
</tr>
|
||||
: null
|
||||
}
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login }) => ({ login }))(TL044ShowPrint)
|
||||
@ -1,106 +0,0 @@
|
||||
import { Button, Descriptions, Badge, Popconfirm, Row, Col, Form, Input, Select, Table } from 'antd';
|
||||
import React from 'react';
|
||||
import { initFilter, extendRule, extendInclude, setDataFieldValue, showApprove, guid, showFiles } from '../../../utils/common';
|
||||
import ReactToPrint from 'react-to-print';
|
||||
import { ExportToExcel } from '@woowalker/feui'
|
||||
import XLSX from 'xlsx';
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import { message } from 'antd/lib/index';
|
||||
import styles from '../../../components/CustomPages/HI/StepForm.css';
|
||||
import config from '../../../config.js';
|
||||
import FormPage from '../../FormPage'
|
||||
class TL046ShowPrint extends React.Component {
|
||||
constructor(props) {
|
||||
super(props);
|
||||
this.state = {
|
||||
data: null,
|
||||
btndisplay: 'none',
|
||||
isCheck: 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')
|
||||
|
||||
}
|
||||
|
||||
onClickApprove = (appVisible) => {
|
||||
const newtmpData = {
|
||||
data: { id: this.props.data.id, isShow: true, key: guid(), param: this.props.data.param, appVisible: appVisible, BtnAgreeDisplay: 'none' },
|
||||
formCode: 'PF123',
|
||||
}
|
||||
this.setState({
|
||||
tmpData: newtmpData,
|
||||
});
|
||||
}
|
||||
loadData = (id) => {
|
||||
var isCheck = (this.props.data.tableKey != undefined && this.props.data.tableKey == '1') ? true : false
|
||||
var orgId = this.props.login ? this.props.login.OrgId : '';
|
||||
let json = initFilter(orgId);
|
||||
extendRule(json, 'ID', 1, id);
|
||||
// extendInclude(json, 'Nav_Tailing')
|
||||
extendInclude(json, 'Nav_Files_Sub.Nav_ImgFile.Nav_File')
|
||||
extendInclude(json, 'Nav_Files_Proj.Nav_ImgFile.Nav_File')
|
||||
extendInclude(json, 'Nav_Files.Nav_ImgFile.Nav_File')
|
||||
this.props.dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
payload: json,
|
||||
url: 'TL/ProjectSlopebank/Get',
|
||||
onComplete: (ret) => {
|
||||
if (ret) {
|
||||
this.setState({
|
||||
data: ret,
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
render() {
|
||||
const { data } = 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 onClick={() => this.onClickApprove(true)} style={{ marginRight: '8px' }} icon='export'>审批详情</Button></td>
|
||||
<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>
|
||||
<FormPage {...this.state.tmpData} />
|
||||
<div ref={el => (this.componentRef = el)} style={{ padding: '20px', paddingTop: '20px' }} id={'tableId' + this.props.data.id}>
|
||||
<h1 className={styles.showPrintHead}>子坝坡岸处理</h1>
|
||||
{
|
||||
data ? <div style={{ width: '95%' }}>
|
||||
<Descriptions title='' size='middle' bordered>
|
||||
<Descriptions.Item label="尾矿库">{data.TAILING_NAME}</Descriptions.Item>
|
||||
<Descriptions.Item label="子坝名称">{data.NAMESUB}</Descriptions.Item>
|
||||
<Descriptions.Item label="期数">{data.COUNTNUM}</Descriptions.Item>
|
||||
<Descriptions.Item label="坡岸处理">{showFiles(data.Nav_Files_Sub, config.picServerHost)}</Descriptions.Item>
|
||||
<Descriptions.Item label="隐蔽工程">{showFiles(data.Nav_Files_Proj, config.picServerHost)}</Descriptions.Item>
|
||||
<Descriptions.Item label="冲刷情况">{enums.WashSituaction.enums[data.RESULT]}</Descriptions.Item>
|
||||
<Descriptions.Item label="附件">{showFiles(data.Nav_Files, config.picServerHost)}</Descriptions.Item>
|
||||
</Descriptions>
|
||||
</div> : null
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
}
|
||||
export default connect(({ login, app }) => ({ login, app }))(TL046ShowPrint)
|
||||
@ -1,26 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 事故事件上报
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'AE006', '事故事件上报前端日志')
|
||||
},
|
||||
|
||||
onBeforeEdit: ({ isNew, setFieldValueByBatch, login }) => {
|
||||
if (isNew) {
|
||||
const temps = [];
|
||||
temps.push({ field: 'USER_ID', value: login.user.ID })
|
||||
temps.push({ field: 'Nav_User.NAME', value: login.user.NAME })
|
||||
temps.push({ field: 'TIME', value: (new Date()).Format("yyyy-MM-dd HH:mm:ss") })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
},
|
||||
|
||||
}
|
||||
@ -1,26 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 事故调查小组成员
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'AE008', '事故调查小组成员前端日志')
|
||||
},
|
||||
|
||||
// onBeforeEdit: ({ isNew, setFieldValueByBatch, login }) => {
|
||||
// if (isNew) {
|
||||
// const temps = [];
|
||||
// temps.push({ field: 'USER_ID', value: login.user.ID })
|
||||
// temps.push({ field: 'Nav_User.NAME', value: login.user.NAME })
|
||||
// temps.push({ field: 'TIME', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
// setFieldValueByBatch(temps);
|
||||
// }
|
||||
// },
|
||||
|
||||
}
|
||||
@ -1,119 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, guid, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import config from "../../config.js"
|
||||
import { Button, Row, Col, Form, Input, Select, Upload, Icon, Modal, Spin } from 'antd';
|
||||
import storage from '../../utils/storage'
|
||||
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 事故事件调查结果填报
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'AE010', '事故事件调查结果填报前端日志')
|
||||
},
|
||||
onBeforeEdit(params) {
|
||||
const { stateData } = params ? params : {};
|
||||
if (stateData.Nav_ListForensics != null && stateData.Nav_ListForensics.length > 0) {
|
||||
// 字表重写
|
||||
let details = [];
|
||||
stateData.Nav_ListForensics.forEach(t => {
|
||||
let detail = {
|
||||
Files: [],
|
||||
Nav_FilesSurvey: t.Nav_FilesSurvey,
|
||||
ID: t.ID,
|
||||
|
||||
// MONEY_ID: t.MONEY_ID,
|
||||
// NAME: t.NAME,
|
||||
// TOTAL: t.TOTAL,
|
||||
// USE: t.USE,
|
||||
EVIDENCE_SOURCE: t.EVIDENCE_SOURCE,
|
||||
EVIDENCE_DESC: t.EVIDENCE_DESC,
|
||||
|
||||
ROW_NO: t.ROW_NO,
|
||||
ENTITY_ORG_TPYE: t.ENTITY_ORG_TPYE,
|
||||
ORG_ID: t.ORG_ID,
|
||||
CREATE_TIME: t.CREATE_TIME,
|
||||
IS_DELETED: t.IS_DELETED
|
||||
}
|
||||
if (t.Nav_FilesSurvey) {
|
||||
t.Nav_FilesSurvey.forEach(x => {
|
||||
//附件信息赋值给数据库对象,多个附件需要遍历附件信息
|
||||
detail.Files.push({
|
||||
uid: x.ID,
|
||||
name: x.name ? x.name : (x.Nav_ImgFile ? x.Nav_ImgFile.FILE_NAME : '未知文件'),
|
||||
status: x.status ? x.status : 'done',
|
||||
response: { Data: { imgFileID: x.IMG_FILE_ID }, file: x },
|
||||
url: x.Nav_ImgFile ? (config.picServerHost + x.Nav_ImgFile.Nav_File.FILE_PATH) : '',
|
||||
})
|
||||
})
|
||||
}
|
||||
details.push(detail);
|
||||
});
|
||||
details = details.map((item, i) => {
|
||||
return item;
|
||||
});
|
||||
stateData.Nav_ListForensics = details;
|
||||
}
|
||||
|
||||
params['record'] = stateData;
|
||||
},
|
||||
handleRenderRowControl(params) {
|
||||
if (params.colConfig.field === 'Nav_FilesSurvey') {
|
||||
const Tenant = storage('lacal').getItem('Tenant').val;
|
||||
const that = this;
|
||||
const uploadSopProps = {
|
||||
name: 'file',
|
||||
action: config.serviceHost('api/PF/File/UploadFile'),
|
||||
data: { OrgId: params.login.OrgId },
|
||||
fileList: params.record['Files'],
|
||||
headers: {
|
||||
Tenant: Tenant,
|
||||
},
|
||||
onChange(info) {
|
||||
params.record['Files'] = [...info.fileList];
|
||||
// params.saveRowRecord(params.record);
|
||||
if (info.file.status !== 'uploading') {
|
||||
|
||||
}
|
||||
if (info.file.status === 'removed') {
|
||||
if (info.file.response && info.file.response.file) {
|
||||
info.file.response.file.IS_DELETED = true;
|
||||
}
|
||||
}
|
||||
if (info.file.status === 'done') {
|
||||
let uploadFiles = [...info.fileList]
|
||||
if (uploadFiles) {
|
||||
let navFiles = [];
|
||||
uploadFiles.forEach(t => {
|
||||
if (t.response) {
|
||||
//附件信息赋值给数据库对象,多个附件需要遍历附件信息
|
||||
navFiles.push({
|
||||
IMG_FILE_ID: t.response.Data.imgFileID, //附件表文件名称
|
||||
ID: t.response.file ? t.uid : guid()//标记ID
|
||||
})
|
||||
}
|
||||
});
|
||||
params.record['Nav_FilesSurvey'] = navFiles;
|
||||
}
|
||||
message.success(`${info.file.name} 上传成功`);
|
||||
} else if (info.file.status === 'error') {
|
||||
message.error(`${info.file.name} 上传失败!`);
|
||||
}
|
||||
params.saveRowRecord(params.record);
|
||||
},
|
||||
};
|
||||
return <>
|
||||
<Upload {...uploadSopProps}>
|
||||
<Button>
|
||||
<Icon type="upload" /> 上传附件
|
||||
</Button>
|
||||
</Upload>
|
||||
</>
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1,38 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import config from "../../config.js"
|
||||
import { Button, Row, Col, Form, Input, Select, Upload, Icon, Modal, Spin } from 'antd';
|
||||
import storage from '../../utils/storage'
|
||||
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 勘察记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
// onBeforeSaveHandleRecordLog(params, 'AE018', '事故事件调查结果填报前端日志')
|
||||
},
|
||||
|
||||
onBeforeEdit: ({ isNew, setFieldValueByBatch, setFieldEditable, login, stateData, setFieldValue }) => {
|
||||
if (isNew) {
|
||||
const temps = [];
|
||||
temps.push({ field: 'DEPARTMENT_ID', value: login.user.Nav_Department.ID })
|
||||
temps.push({ field: 'Nav_Department.NAME', value: login.user.Nav_Department.NAME })
|
||||
temps.push({ field: 'USER_ID', value: login.user.ID })
|
||||
temps.push({ field: 'Nav_User.NAME', value: login.user.NAME })
|
||||
temps.push({ field: 'LAUNCH_TIME', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
setFieldValueByBatch(temps);
|
||||
} else if (!stateData.LAUNCH_TIME) {
|
||||
setFieldValue('LAUNCH_TIME', (new Date()).Format("yyyy-MM-dd"))
|
||||
}
|
||||
|
||||
if (stateData.Nav_Accident?.CODE.length > 0) {
|
||||
setFieldEditable("Nav_Accident.CODE", false)
|
||||
}
|
||||
},
|
||||
|
||||
}
|
||||
@ -1,30 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 事故事件上报
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'OH004', '体检计划前端日志')
|
||||
},
|
||||
|
||||
onBeforeEdit: ({ isNew, stateData, setFieldValue, login }) => {
|
||||
if (stateData.YEAR == null) {
|
||||
setFieldValue('YEAR', (new Date()).Format("yyyy"))
|
||||
}
|
||||
|
||||
// if (isNew) {
|
||||
// const temps = [];
|
||||
// temps.push({ field: 'USER_ID', value: login.user.ID })
|
||||
// temps.push({ field: 'Nav_User.NAME', value: login.user.NAME })
|
||||
// temps.push({ field: 'TIME', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
// setFieldValueByBatch(temps);
|
||||
// }
|
||||
},
|
||||
|
||||
}
|
||||
@ -1,188 +0,0 @@
|
||||
//import { message, notification } from 'antd';
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 部门级体检计划表
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'OH005', '部门级体检计划前端日志')
|
||||
},
|
||||
|
||||
|
||||
onSubChange: ({ row, pageCode, record, colInfo, dispatch, stateData, saveRowRecord, setDataState, setFieldValueByBatch }) => {
|
||||
// if (colInfo != null && colInfo.FIELD_NAME == "Nav_ExamCycle.Nav_ListOccHazard") {
|
||||
// //选择了职业危害类型 匹配体检项目
|
||||
// var Nav_ListOccHazard = record.Nav_ExamCycle?.Nav_ListOccHazard
|
||||
// if (Nav_ListOccHazard != null && Nav_ListOccHazard.length > 0) {
|
||||
// //有数据 数据库 查找
|
||||
// var Keyword = Nav_ListOccHazard[0].HAZARD_ID
|
||||
// if (Nav_ListOccHazard.length > 1) {
|
||||
// for (let i = 1; i < Nav_ListOccHazard.length; i++) {
|
||||
// Keyword += ',' + Nav_ListOccHazard[i].HAZARD_ID
|
||||
// }
|
||||
// }
|
||||
|
||||
// var orgId = colInfo.ORG_ID; //登录后有存储登录信息
|
||||
// let json = initFilter(orgId, Keyword, null, null, 1, record.USER_ID, record.DEPARTMENT_ID, record.DEPARTMENT_ID_WORKSHOP);
|
||||
// dispatch({
|
||||
// type: 'app/getDataByPost',
|
||||
// url: 'OH/OHHealthExamPlan/GetExamCycleByIdentifying',
|
||||
// payload: json,
|
||||
// onlyData: false,
|
||||
// onComplete: (ret) => {
|
||||
|
||||
// // let temps = [];
|
||||
// // if (ret && ret.IsSuccessful && ret.Data) {
|
||||
// // let detail = ret.Data.map((item, i) => {
|
||||
// // item['ROW_NO'] = i + 1;
|
||||
// // return item;
|
||||
// // });
|
||||
// // temps.push({ field: "Nav_ListSafeCheckDetail", value: detail });
|
||||
|
||||
// // if (detail.length > 50) {
|
||||
// // notification.info({
|
||||
// // message: <a style={{ color: 'red' }}>温馨提示</a>,
|
||||
// // description: '检查任务超过50条后会影响执行效率,请谨慎操作!',
|
||||
// // placement: 'bottomLeft',
|
||||
// // });
|
||||
// // }
|
||||
|
||||
// // } else {
|
||||
// // temps.push({ field: "Nav_ListSafeCheckDetail", value: null });
|
||||
// // }
|
||||
// // setFieldValueByBatch(temps);
|
||||
// }
|
||||
// });
|
||||
// } else {
|
||||
// //清空
|
||||
// }
|
||||
// } else
|
||||
if (colInfo != null && colInfo.FIELD_NAME == "Nav_User.NAME") {
|
||||
if (!record.CREATER_ID) {
|
||||
if (record.USER_ID == null) {
|
||||
// for (let i = 0; i < stateData.Nav_Plan.Nav_ListPlanRegister.length; i++) {
|
||||
// if (stateData.Nav_Plan.Nav_ListPlanRegister[i].ID == record.ID) {
|
||||
// stateData.Nav_Plan.Nav_ListPlanRegister[i].Nav_Department = null
|
||||
// stateData.Nav_Plan.Nav_ListPlanRegister[i].Nav_DepartmentWorkshop = null
|
||||
// stateData.Nav_Plan.Nav_ListPlanRegister[i].Nav_SCPost = null
|
||||
// stateData.Nav_Plan.Nav_ListPlanRegister[i].Nav_User = null
|
||||
// }
|
||||
// }
|
||||
} else {
|
||||
var orgId = colInfo.ORG_ID;
|
||||
// 获取人员后 去后台判断 再获取数据
|
||||
let json = initFilter(orgId, record.USER_ID, null, null, 1, stateData.PLAN_ID, record.ID, stateData.DEPARTMENT_ID);
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'OH/OHHealthExamPlan/GetCombinPlanRegister',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
if (ret && ret.IsSuccessful) {
|
||||
record = ret.Data
|
||||
|
||||
// record.Nav_Department.NAME = ret.Data.Nav_Department?.NAME
|
||||
// record.Nav_DepartmentWorkshop.NAME = ret.Data.Nav_DepartmentWorkshop?.NAME
|
||||
// record.Nav_User.NAME = ret.Data.Nav_User.NAME
|
||||
// record.Nav_User.ID_CARD = ret.Data.Nav_User.ID_CARD
|
||||
// record.Nav_User.SEX = ret.Data.Nav_User.SEX
|
||||
// record.Nav_SCPost.NAME = ret.Data.Nav_SCPost?.NAME
|
||||
// record.WORKYEAR = ret.Data.WORKYEAR
|
||||
// // record.Nav_ListHazard.Nav_Hazard.NAME = ret.Data.Nav_ListHazard.Nav_Hazard.NAME
|
||||
// // record.Nav_ListHazard = ret.Data.Nav_ListHazard
|
||||
// record.HEALTH_EXAM_CONTENT = ret.Data.HEALTH_EXAM_CONTENT
|
||||
// record.TYPE = ret.Data.TYPE
|
||||
|
||||
// setDataFieldValue(record, 'Nav_Department.NAME', record.Nav_Department?.NAME);
|
||||
// setDataFieldValue(record, 'Nav_User.NAME', record.Nav_User.NAME);
|
||||
// setDataFieldValue(record, 'Nav_User.ID_CARD', record.Nav_User.ID_CARD);
|
||||
// setDataFieldValue(record, 'Nav_SCPost.NAME', record.Nav_SCPost?.NAME);
|
||||
// setDataFieldValue(record, 'HEALTH_EXAM_CONTENT', record.HEALTH_EXAM_CONTENT);
|
||||
// setDataFieldValue(record, 'Nav_User.SEX', record.Nav_User.SEX);
|
||||
// // setDataFieldValue(record, 'Nav_ListHazard', record.Nav_ListHazard);
|
||||
// // setDataFieldValue(record, 'Nav_ListHazard.Nav_Hazard.NAME', record.Nav_ListHazard.Nav_Hazard.NAME);
|
||||
// setDataFieldValue(record, 'TYPE', record.TYPE);
|
||||
// setDataFieldValue(record, 'Nav_DepartmentWorkshop.NAME', record.Nav_DepartmentWorkshop?.NAME);
|
||||
// setDataFieldValue(record, 'WORKYEAR', record.WORKYEAR);
|
||||
|
||||
// const temps = [];
|
||||
// temps.push({ field: 'USER_ID', value: login.user.ID })
|
||||
// setFieldValueByBatch(temps)
|
||||
|
||||
for (let i = 0; i < stateData.Nav_Plan.Nav_ListPlanRegister.length; i++) {
|
||||
if (stateData.Nav_Plan.Nav_ListPlanRegister[i].ID == record.ID) {
|
||||
stateData.Nav_Plan.Nav_ListPlanRegister[i] = record
|
||||
}
|
||||
}
|
||||
|
||||
// stateData.Nav_Plan.Nav_ListPlanRegister.map((v, i) => {
|
||||
// if (v.ID == record.ID) {
|
||||
// debugger
|
||||
// v = record
|
||||
// v.DEPARTMENT_ID = record.DEPARTMENT_ID
|
||||
// v.DEPARTMENT_ID_WORKSHOP = record.DEPARTMENT_ID_WORKSHOP
|
||||
// v.SC_POST_ID = record.SC_POST_ID
|
||||
// v.WORKYEAR = record.WORKYEAR
|
||||
// v.Nav_Department.NAME = record.Nav_Department?.NAME
|
||||
// // v.Nav_User.NAME = record.Nav_User.NAME
|
||||
// // v.Nav_User.ID_CARD = record.Nav_User.ID_CARD
|
||||
|
||||
// // v.Nav_SCPost.NAME = record.Nav_SCPost?.NAME
|
||||
// // v.HEALTH_EXAM_CONTENT = record.HEALTH_EXAM_CONTENT
|
||||
// // v.Nav_User.SEX = record.Nav_User.SEX
|
||||
// // // v.Nav_ListHazard = record.Nav_ListHazard
|
||||
// // // v.Nav_ListHazard.Nav_Hazard.NAME = record.Nav_ListHazard.Nav_Hazard.NAME
|
||||
// v.TYPE = record.TYPE
|
||||
// // v.Nav_DepartmentWorkshop.NAME = record.Nav_DepartmentWorkshop?.NAME
|
||||
// v.WORKYEAR = record.WORKYEAR
|
||||
// }
|
||||
// });
|
||||
}
|
||||
|
||||
// setDataFieldValue(record, 'OVER_LIMIT', record.OVER_LIMIT);
|
||||
// stateData.Nav_Detail.map((v, i) => {
|
||||
// if (v.ID == record.ID) {
|
||||
// v.OVER_LIMIT = record.OVER_LIMIT;
|
||||
// }
|
||||
// });
|
||||
|
||||
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
// handleRenderRowControl(params) {
|
||||
// if (params.record.CREATE_TIME) {
|
||||
// if (params.colConfig.field == 'Nav_User.NAME') {
|
||||
// debugger
|
||||
// return <>
|
||||
// {params.record.Nav_User.NAME}
|
||||
// </>
|
||||
// }
|
||||
// // else if (params.colConfig.field == 'Nav_ListHazard') {
|
||||
// // return <>
|
||||
// // {params.record.Nav_CheckProject?.NAME}
|
||||
// // </>
|
||||
// // }
|
||||
// // else if (params.colConfig.field == 'HEALTH_EXAM_CONTENT') {
|
||||
// // return <>
|
||||
// // {params.record.HEALTH_EXAM_CONTENT}
|
||||
// // </>
|
||||
// // }
|
||||
// } else {
|
||||
// return '';
|
||||
// }
|
||||
// }
|
||||
|
||||
|
||||
}
|
||||
@ -1,112 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 事故事件上报
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'OH006', '体检计划汇总前端日志')
|
||||
},
|
||||
|
||||
onSubChange: ({ row, pageCode, record, colInfo, dispatch, stateData, saveRowRecord, setDataState, setFieldValueByBatch }) => {
|
||||
if (colInfo != null && colInfo.FIELD_NAME == "Nav_User.NAME") {
|
||||
if (!record.CREATER_ID) {
|
||||
if (record.USER_ID == null) {
|
||||
// for (let i = 0; i < stateData.Nav_Plan.Nav_ListPlanRegister.length; i++) {
|
||||
// if (stateData.Nav_Plan.Nav_ListPlanRegister[i].ID == record.ID) {
|
||||
// stateData.Nav_Plan.Nav_ListPlanRegister[i].Nav_Department = null
|
||||
// stateData.Nav_Plan.Nav_ListPlanRegister[i].Nav_DepartmentWorkshop = null
|
||||
// stateData.Nav_Plan.Nav_ListPlanRegister[i].Nav_SCPost = null
|
||||
// stateData.Nav_Plan.Nav_ListPlanRegister[i].Nav_User = null
|
||||
// }
|
||||
// }
|
||||
} else {
|
||||
var orgId = colInfo.ORG_ID;
|
||||
// 获取人员后 去后台判断 再获取数据
|
||||
let json = initFilter(orgId, record.USER_ID, null, null, 1, stateData.ID, record.ID, stateData.DEPARTMENT_ID);
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'OH/OHHealthExamPlan/GetCombinPlanRegister',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
if (ret && ret.IsSuccessful) {
|
||||
record = ret.Data
|
||||
for (let i = 0; i < stateData.Nav_ListPlanRegister.length; i++) {
|
||||
if (stateData.Nav_ListPlanRegister[i].ID == record.ID) {
|
||||
stateData.Nav_ListPlanRegister[i] = record
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
// handleRenderRowControl(params) {
|
||||
// if (params.record.CREATE_TIME) {
|
||||
// if (params.colConfig.field == 'Nav_Department.NAME') {
|
||||
// return <>
|
||||
// {params.record.Nav_Department?.NAME}
|
||||
// </>
|
||||
// }
|
||||
// else if (params.colConfig.field == 'Nav_DepartmentWorkshop.NAME') {
|
||||
// return <>
|
||||
// {params.record.Nav_DepartmentWorkshop?.NAME}
|
||||
// </>
|
||||
// }
|
||||
// else if (params.colConfig.field == 'Nav_User.NAME') {
|
||||
// return <>
|
||||
// {params.record.Nav_User.NAME}
|
||||
// </>
|
||||
// }
|
||||
// // else if (params.colConfig.field == 'Nav_User.ID_CARD') {
|
||||
// // return <>
|
||||
// // {params.record.Nav_User.ID_CARD}
|
||||
// // </>
|
||||
// // }
|
||||
// // else if (params.colConfig.field == 'Nav_User.SEX') {
|
||||
// // return <>
|
||||
// // {params.record.Nav_User.SEX}
|
||||
// // </>
|
||||
// // }
|
||||
// // else if (params.colConfig.field == 'Nav_SCPost.NAME') {
|
||||
// // return <>
|
||||
// // {params.record.Nav_SCPost?.NAME}
|
||||
// // </>
|
||||
// // }
|
||||
// // else if (params.colConfig.field == 'WORKYEAR') {
|
||||
// // return <>
|
||||
// // {params.record.WORKYEAR}
|
||||
// // </>
|
||||
// // }
|
||||
// else if (params.colConfig.field == 'Nav_ExamCycle.HEALTH_EXAM_CONTENT') {
|
||||
// return <>
|
||||
// {params.record.Nav_ExamCycle.HEALTH_EXAM_CONTENT}
|
||||
// </>
|
||||
// }
|
||||
// else if (params.colConfig.field == 'TYPE') {
|
||||
// return <>
|
||||
// {params.record.TYPE}
|
||||
// </>
|
||||
// }
|
||||
// // else if (params.colConfig.field == 'CHECKCONTENT') {
|
||||
// // return <>
|
||||
// // {params.record.CHECKCONTENT}
|
||||
// // </>
|
||||
// // }
|
||||
// } else {
|
||||
// return '';
|
||||
// }
|
||||
// }
|
||||
|
||||
|
||||
|
||||
}
|
||||
@ -1,166 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 事故事件上报
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'OH010', '体检通知前端日志')
|
||||
},
|
||||
onSubChange: ({ row, setDataState, pageCode, record, colInfo, dispatch, stateData, props }) => {
|
||||
//如果修改原有库 直接填写对应ID
|
||||
// debugger
|
||||
// if (record.ISMAINCHANGE == undefined || record.ISMAINCHANGE == null || !record.ISMAINCHANGE) {
|
||||
// var MainId = record.CHECK_MAIN_ID
|
||||
// if (MainId != null && MainId != undefined && MainId.length > 0) {
|
||||
// stateData.Nav_ListSafeCheckDetail[record.ROW_NO - 1].ISMAINCHANGE = true
|
||||
// }
|
||||
// }
|
||||
|
||||
if (colInfo.FIELD_NAME == "Nav_ExamBatch.BATCH") {
|
||||
//更新选中人员
|
||||
let tmp = "";
|
||||
var DEPARTMENT_ID_WORKSHOP = record.DEPARTMENT_ID_WORKSHOP
|
||||
var DEPARTMENT_ID = record.DEPARTMENT_ID
|
||||
var banchRecord = record.Nav_ExamBatch
|
||||
//有车间 车间所有的一起同步
|
||||
// DEPARTMENT_ID_WORKSHOP
|
||||
//没有车间有部门 所有的一起同步
|
||||
// DEPARTMENT_ID
|
||||
if (DEPARTMENT_ID_WORKSHOP || DEPARTMENT_ID) {
|
||||
for (var x = 0; x < stateData.Nav_ListNoticeRegister.length; x++) {
|
||||
let regist = stateData.Nav_ListNoticeRegister[x]
|
||||
// let banch = regist.Nav_ExamBatch
|
||||
if (!regist.Nav_ExamBatch) {
|
||||
if (DEPARTMENT_ID_WORKSHOP && DEPARTMENT_ID_WORKSHOP.length > 0) {
|
||||
if (regist.DEPARTMENT_ID_WORKSHOP && regist.DEPARTMENT_ID_WORKSHOP == DEPARTMENT_ID_WORKSHOP) {
|
||||
regist.Nav_ExamBatch = banchRecord
|
||||
regist.EXAM_BATCH_ID = banchRecord.ID
|
||||
}
|
||||
|
||||
} else if (DEPARTMENT_ID && DEPARTMENT_ID.length > 0) {
|
||||
if (regist.DEPARTMENT_ID && regist.DEPARTMENT_ID == DEPARTMENT_ID && regist.DEPARTMENT_ID_WORKSHOP == null) {
|
||||
regist.Nav_ExamBatch = banchRecord
|
||||
regist.EXAM_BATCH_ID = banchRecord.ID
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// if (banch) {
|
||||
// for (let i = 0; i < banch.length; i++) {
|
||||
// if (!banch[i].IS_DELETED) {
|
||||
// if (tmp.indexOf(banch[i].Nav_User.NAME) == -1) {
|
||||
// tmp += (tmp.length > 0 ? "," : "") + banch[i].Nav_User.NAME
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
}
|
||||
}
|
||||
stateData.CheckUsers = tmp
|
||||
setDataState({ ...stateData });
|
||||
|
||||
// } else if (colInfo.FIELD_NAME == "QUESTION_LEVEL") {
|
||||
// if (record.QUESTION_LEVEL == "10") {
|
||||
// stateData.Nav_ListSafeCheckDetail[record.ROW_NO - 1].SERIOUS_RISK = 1
|
||||
// } else {
|
||||
// stateData.Nav_ListSafeCheckDetail[record.ROW_NO - 1].SERIOUS_RISK = 0
|
||||
// }
|
||||
}
|
||||
|
||||
|
||||
|
||||
// CheckUsers
|
||||
// setDataState("CheckUsers", "jianc")
|
||||
// if (colInfo.FIELD_NAME == "Nav_CheckType.NAME") {
|
||||
// //只要檢查類型修改 清空 項目分類 檢查層級
|
||||
// stateData.Nav_ListContentCheckTypes[0].Nav_CheckProjectCategory = []
|
||||
// stateData.Nav_ListContentCheckTypes[0].Nav_ListContentCheckTypeLevels = []
|
||||
// // if (record.Nav_CheckType.Name) {
|
||||
// // } else {
|
||||
// // //清空項目分類 檢查層級
|
||||
// // }
|
||||
// }
|
||||
},
|
||||
|
||||
// onBeforeEdit: ({ isNew, stateData, setFieldValue, login }) => {
|
||||
// debugger
|
||||
// if (stateData.YEAR == null) {
|
||||
// setFieldValue('YEAR', (new Date()).Format("yyyy"))
|
||||
// }
|
||||
|
||||
// // if (isNew) {
|
||||
// // const temps = [];
|
||||
// // temps.push({ field: 'USER_ID', value: login.user.ID })
|
||||
// // temps.push({ field: 'Nav_User.NAME', value: login.user.NAME })
|
||||
// // temps.push({ field: 'TIME', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
// // setFieldValueByBatch(temps);
|
||||
// // }
|
||||
// },
|
||||
|
||||
// handleRenderRowControl(params) {
|
||||
// if (params.record.CREATE_TIME) {
|
||||
// if (params.colConfig.field == 'Nav_Department.NAME') {
|
||||
// return <>
|
||||
// {params.record.Nav_Department?.NAME}
|
||||
// </>
|
||||
// }
|
||||
// else if (params.colConfig.field == 'Nav_DepartmentWorkshop.NAME') {
|
||||
// return <>
|
||||
// {params.record.Nav_DepartmentWorkshop?.NAME}
|
||||
// </>
|
||||
// }
|
||||
// else if (params.colConfig.field == 'Nav_User.NAME') {
|
||||
// return <>
|
||||
// {params.record.Nav_User.NAME}
|
||||
// </>
|
||||
// }
|
||||
// // else if (params.colConfig.field == 'Nav_User.ID_CARD') {
|
||||
// // return <>
|
||||
// // {params.record.Nav_User.ID_CARD}
|
||||
// // </>
|
||||
// // }
|
||||
// // else if (params.colConfig.field == 'Nav_User.SEX') {
|
||||
// // return <>
|
||||
// // {params.record.Nav_User.SEX}
|
||||
// // </>
|
||||
// // }
|
||||
// // else if (params.colConfig.field == 'Nav_SCPost.NAME') {
|
||||
// // return <>
|
||||
// // {params.record.Nav_SCPost?.NAME}
|
||||
// // </>
|
||||
// // }
|
||||
// // else if (params.colConfig.field == 'WORKYEAR') {
|
||||
// // return <>
|
||||
// // {params.record.WORKYEAR}
|
||||
// // </>
|
||||
// // }
|
||||
// else if (params.colConfig.field == 'Nav_ExamCycle.HEALTH_EXAM_CONTENT') {
|
||||
// return <>
|
||||
// {params.record.Nav_ExamCycle.HEALTH_EXAM_CONTENT}
|
||||
// </>
|
||||
// }
|
||||
// else if (params.colConfig.field == 'TYPE') {
|
||||
// return <>
|
||||
// {params.record.TYPE}
|
||||
// </>
|
||||
// }
|
||||
// // else if (params.colConfig.field == 'CHECKCONTENT') {
|
||||
// // return <>
|
||||
// // {params.record.CHECKCONTENT}
|
||||
// // </>
|
||||
// // }
|
||||
// } else {
|
||||
// return '';
|
||||
// }
|
||||
// }
|
||||
|
||||
|
||||
|
||||
}
|
||||
@ -1,152 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 事故事件上报
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
//如果是保存
|
||||
// 如果现在状态 是 待填写 职业病 状态不变
|
||||
if (params.customParams == 0 && params.record.STATUS == 10 && params.record.RESULT_ENUM == 15) {
|
||||
// params.record.STATUS = params.customParams;//状态不变 后台处理数据
|
||||
} else {
|
||||
params.record.STATUS = params.customParams;
|
||||
}
|
||||
onBeforeSaveHandleRecordLog(params, 'OH010', '体检通知前端日志')
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, setFieldVisible, setFieldEditable, login }) => {
|
||||
//如果是 待填写职业病 STATUS 10 RESULT_ENUM 15
|
||||
//那么 页面属性不可编辑
|
||||
if (!isNew&&stateData.STATUS!=0&&stateData.STATUS!=10) {
|
||||
if (stateData.Nav_NoticeRegister?.Nav_User) {
|
||||
setFieldEditable("Nav_NoticeRegister.Nav_ExamBatch.BATCH", false);
|
||||
setFieldEditable("Nav_NoticeRegister.Nav_User.NAME", false);
|
||||
setFieldEditable("RESULT_ENUM", false);
|
||||
setFieldEditable("DESCRIPTION", false);
|
||||
setFieldEditable("SUGGESTION", false);
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
onSubChange: ({ row, setDataState, pageCode, record, colInfo, dispatch, stateData, props }) => {
|
||||
//如果修改原有库 直接填写对应ID
|
||||
// debugger
|
||||
// if (record.ISMAINCHANGE == undefined || record.ISMAINCHANGE == null || !record.ISMAINCHANGE) {
|
||||
// var MainId = record.CHECK_MAIN_ID
|
||||
// if (MainId != null && MainId != undefined && MainId.length > 0) {
|
||||
// stateData.Nav_ListSafeCheckDetail[record.ROW_NO - 1].ISMAINCHANGE = true
|
||||
// }
|
||||
// }
|
||||
|
||||
if (colInfo.FIELD_NAME == "Nav_ExamBatch.BATCH") {
|
||||
//更新选中人员
|
||||
let tmp = "";
|
||||
var DEPARTMENT_ID_WORKSHOP = record.DEPARTMENT_ID_WORKSHOP
|
||||
var DEPARTMENT_ID = record.DEPARTMENT_ID
|
||||
var banchRecord = record.Nav_ExamBatch
|
||||
//有车间 车间所有的一起同步
|
||||
// DEPARTMENT_ID_WORKSHOP
|
||||
//没有车间有部门 所有的一起同步
|
||||
// DEPARTMENT_ID
|
||||
if (DEPARTMENT_ID_WORKSHOP || DEPARTMENT_ID) {
|
||||
for (var x = 0; x < stateData.Nav_ListNoticeRegister.length; x++) {
|
||||
let regist = stateData.Nav_ListNoticeRegister[x]
|
||||
// let banch = regist.Nav_ExamBatch
|
||||
if (!regist.Nav_ExamBatch) {
|
||||
if (DEPARTMENT_ID_WORKSHOP && DEPARTMENT_ID_WORKSHOP.length > 0) {
|
||||
if (regist.DEPARTMENT_ID_WORKSHOP && regist.DEPARTMENT_ID_WORKSHOP == DEPARTMENT_ID_WORKSHOP) {
|
||||
regist.Nav_ExamBatch = banchRecord
|
||||
regist.EXAM_BATCH_ID = banchRecord.ID
|
||||
}
|
||||
|
||||
} else if (DEPARTMENT_ID && DEPARTMENT_ID.length > 0) {
|
||||
if (regist.DEPARTMENT_ID && regist.DEPARTMENT_ID == DEPARTMENT_ID && regist.DEPARTMENT_ID_WORKSHOP == null) {
|
||||
regist.Nav_ExamBatch = banchRecord
|
||||
regist.EXAM_BATCH_ID = banchRecord.ID
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// if (banch) {
|
||||
// for (let i = 0; i < banch.length; i++) {
|
||||
// if (!banch[i].IS_DELETED) {
|
||||
// if (tmp.indexOf(banch[i].Nav_User.NAME) == -1) {
|
||||
// tmp += (tmp.length > 0 ? "," : "") + banch[i].Nav_User.NAME
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
}
|
||||
}
|
||||
stateData.CheckUsers = tmp
|
||||
setDataState({ ...stateData });
|
||||
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
// handleRenderRowControl(params) {
|
||||
// if (params.record.CREATE_TIME) {
|
||||
// if (params.colConfig.field == 'Nav_Department.NAME') {
|
||||
// return <>
|
||||
// {params.record.Nav_Department?.NAME}
|
||||
// </>
|
||||
// }
|
||||
// else if (params.colConfig.field == 'Nav_DepartmentWorkshop.NAME') {
|
||||
// return <>
|
||||
// {params.record.Nav_DepartmentWorkshop?.NAME}
|
||||
// </>
|
||||
// }
|
||||
// else if (params.colConfig.field == 'Nav_User.NAME') {
|
||||
// return <>
|
||||
// {params.record.Nav_User.NAME}
|
||||
// </>
|
||||
// }
|
||||
// // else if (params.colConfig.field == 'Nav_User.ID_CARD') {
|
||||
// // return <>
|
||||
// // {params.record.Nav_User.ID_CARD}
|
||||
// // </>
|
||||
// // }
|
||||
// // else if (params.colConfig.field == 'Nav_User.SEX') {
|
||||
// // return <>
|
||||
// // {params.record.Nav_User.SEX}
|
||||
// // </>
|
||||
// // }
|
||||
// // else if (params.colConfig.field == 'Nav_SCPost.NAME') {
|
||||
// // return <>
|
||||
// // {params.record.Nav_SCPost?.NAME}
|
||||
// // </>
|
||||
// // }
|
||||
// // else if (params.colConfig.field == 'WORKYEAR') {
|
||||
// // return <>
|
||||
// // {params.record.WORKYEAR}
|
||||
// // </>
|
||||
// // }
|
||||
// else if (params.colConfig.field == 'Nav_ExamCycle.HEALTH_EXAM_CONTENT') {
|
||||
// return <>
|
||||
// {params.record.Nav_ExamCycle.HEALTH_EXAM_CONTENT}
|
||||
// </>
|
||||
// }
|
||||
// else if (params.colConfig.field == 'TYPE') {
|
||||
// return <>
|
||||
// {params.record.TYPE}
|
||||
// </>
|
||||
// }
|
||||
// // else if (params.colConfig.field == 'CHECKCONTENT') {
|
||||
// // return <>
|
||||
// // {params.record.CHECKCONTENT}
|
||||
// // </>
|
||||
// // }
|
||||
// } else {
|
||||
// return '';
|
||||
// }
|
||||
// }
|
||||
|
||||
|
||||
|
||||
}
|
||||
@ -1,87 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 事故事件上报
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'OH010', '体检通知前端日志')
|
||||
},
|
||||
action: ({ }) => {
|
||||
|
||||
debugger
|
||||
|
||||
},
|
||||
|
||||
onSubChange: ({ row, setDataState, pageCode, record, colInfo, dispatch, stateData, props }) => {
|
||||
//如果修改原有库 直接填写对应ID
|
||||
// debugger
|
||||
// if (record.ISMAINCHANGE == undefined || record.ISMAINCHANGE == null || !record.ISMAINCHANGE) {
|
||||
// var MainId = record.CHECK_MAIN_ID
|
||||
// if (MainId != null && MainId != undefined && MainId.length > 0) {
|
||||
// stateData.Nav_ListSafeCheckDetail[record.ROW_NO - 1].ISMAINCHANGE = true
|
||||
// }
|
||||
// }
|
||||
|
||||
if (colInfo.FIELD_NAME == "Nav_ExamBatch.BATCH") {
|
||||
//更新选中人员
|
||||
let tmp = "";
|
||||
var DEPARTMENT_ID_WORKSHOP = record.DEPARTMENT_ID_WORKSHOP
|
||||
var DEPARTMENT_ID = record.DEPARTMENT_ID
|
||||
var banchRecord = record.Nav_ExamBatch
|
||||
//有车间 车间所有的一起同步
|
||||
// DEPARTMENT_ID_WORKSHOP
|
||||
//没有车间有部门 所有的一起同步
|
||||
// DEPARTMENT_ID
|
||||
if (DEPARTMENT_ID_WORKSHOP || DEPARTMENT_ID) {
|
||||
for (var x = 0; x < stateData.Nav_ListNoticeRegister.length; x++) {
|
||||
let regist = stateData.Nav_ListNoticeRegister[x]
|
||||
// let banch = regist.Nav_ExamBatch
|
||||
if (!regist.Nav_ExamBatch) {
|
||||
if (DEPARTMENT_ID_WORKSHOP && DEPARTMENT_ID_WORKSHOP.length > 0) {
|
||||
if (regist.DEPARTMENT_ID_WORKSHOP && regist.DEPARTMENT_ID_WORKSHOP == DEPARTMENT_ID_WORKSHOP) {
|
||||
regist.Nav_ExamBatch = banchRecord
|
||||
regist.EXAM_BATCH_ID = banchRecord.ID
|
||||
}
|
||||
|
||||
} else if (DEPARTMENT_ID && DEPARTMENT_ID.length > 0) {
|
||||
if (regist.DEPARTMENT_ID && regist.DEPARTMENT_ID == DEPARTMENT_ID && regist.DEPARTMENT_ID_WORKSHOP == null) {
|
||||
regist.Nav_ExamBatch = banchRecord
|
||||
regist.EXAM_BATCH_ID = banchRecord.ID
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// if (banch) {
|
||||
// for (let i = 0; i < banch.length; i++) {
|
||||
// if (!banch[i].IS_DELETED) {
|
||||
// if (tmp.indexOf(banch[i].Nav_User.NAME) == -1) {
|
||||
// tmp += (tmp.length > 0 ? "," : "") + banch[i].Nav_User.NAME
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
}
|
||||
}
|
||||
stateData.CheckUsers = tmp
|
||||
setDataState({ ...stateData });
|
||||
|
||||
// } else if (colInfo.FIELD_NAME == "QUESTION_LEVEL") {
|
||||
// if (record.QUESTION_LEVEL == "10") {
|
||||
// stateData.Nav_ListSafeCheckDetail[record.ROW_NO - 1].SERIOUS_RISK = 1
|
||||
// } else {
|
||||
// stateData.Nav_ListSafeCheckDetail[record.ROW_NO - 1].SERIOUS_RISK = 0
|
||||
// }
|
||||
}
|
||||
|
||||
|
||||
},
|
||||
|
||||
|
||||
}
|
||||
@ -1,333 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 职业危害因素监测规则
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'OH022', '职业危害因素监测规则前端日志')
|
||||
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, setFieldVisible, setFieldValue, login }) => {
|
||||
setFieldVisible("THRESHOLD_DUST", false);
|
||||
setFieldVisible("THRESHOLD_NOISE", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_05", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_10", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_AROUND", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_LOW", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_HIGH", false);
|
||||
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("MONTH", false);
|
||||
setFieldVisible("DAY", false);
|
||||
|
||||
if (!isNew) {
|
||||
const temps = [];
|
||||
switch (stateData.Nav_Type.MONITOR_TYPE) {
|
||||
case 10:
|
||||
setFieldVisible("THRESHOLD_DUST", true);
|
||||
setFieldVisible("THRESHOLD_NOISE", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_05", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_10", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_AROUND", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_LOW", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_HIGH", false);
|
||||
break;
|
||||
case 20:
|
||||
setFieldVisible("THRESHOLD_DUST", false);
|
||||
setFieldVisible("THRESHOLD_NOISE", true);
|
||||
setFieldVisible("THRESHOLD_RADIATION_05", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_10", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_AROUND", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_LOW", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_HIGH", false);
|
||||
break;
|
||||
case 30:
|
||||
setFieldVisible("THRESHOLD_DUST", false);
|
||||
setFieldVisible("THRESHOLD_NOISE", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_05", true);
|
||||
setFieldVisible("THRESHOLD_RADIATION_10", true);
|
||||
setFieldVisible("THRESHOLD_RADIATION_AROUND", true);
|
||||
setFieldVisible("THRESHOLD_WARTER_LOW", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_HIGH", false);
|
||||
break;
|
||||
case 40:
|
||||
setFieldVisible("THRESHOLD_DUST", false);
|
||||
setFieldVisible("THRESHOLD_NOISE", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_05", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_10", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_AROUND", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_LOW", true);
|
||||
setFieldVisible("THRESHOLD_WARTER_HIGH", true);
|
||||
break;
|
||||
default:
|
||||
setFieldVisible("THRESHOLD_DUST", false);
|
||||
setFieldVisible("THRESHOLD_NOISE", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_05", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_10", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_AROUND", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_LOW", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_HIGH", false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
onChange: ({ stateData, value, colInfo, setFieldVisible, setFieldValue, dispatch, setFieldValueByBatch, getSubTableData, updateSubTableData }) => {
|
||||
if (colInfo != null) {
|
||||
/// 生产扬尘浓度监测 10 工作场所噪声监测 20 放射源放射性监测 30 水质监测记录表单 40
|
||||
if (colInfo.FIELD_NAME == "Nav_Type.NAME") {
|
||||
|
||||
const temps = [];
|
||||
switch (stateData.Nav_Type.MONITOR_TYPE) {
|
||||
case 10:
|
||||
setFieldVisible("THRESHOLD_DUST", true);
|
||||
setFieldVisible("THRESHOLD_NOISE", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_05", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_10", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_AROUND", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_LOW", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_HIGH", false);
|
||||
|
||||
temps.push({ field: 'THRESHOLD_NOISE', value: null })
|
||||
temps.push({ field: 'THRESHOLD_RADIATION_05', value: null })
|
||||
temps.push({ field: 'THRESHOLD_RADIATION_10', value: null })
|
||||
temps.push({ field: 'THRESHOLD_RADIATION_AROUND', value: null })
|
||||
temps.push({ field: 'THRESHOLD_WARTER_LOW', value: null })
|
||||
temps.push({ field: 'THRESHOLD_WARTER_HIGH', value: null })
|
||||
setFieldValueByBatch(temps);
|
||||
|
||||
break;
|
||||
case 20:
|
||||
setFieldVisible("THRESHOLD_DUST", false);
|
||||
setFieldVisible("THRESHOLD_NOISE", true);
|
||||
setFieldVisible("THRESHOLD_RADIATION_05", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_10", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_AROUND", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_LOW", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_HIGH", false);
|
||||
|
||||
temps.push({ field: 'THRESHOLD_DUST', value: null })
|
||||
temps.push({ field: 'THRESHOLD_RADIATION_05', value: null })
|
||||
temps.push({ field: 'THRESHOLD_RADIATION_10', value: null })
|
||||
temps.push({ field: 'THRESHOLD_RADIATION_AROUND', value: null })
|
||||
temps.push({ field: 'THRESHOLD_WARTER_LOW', value: null })
|
||||
temps.push({ field: 'THRESHOLD_WARTER_HIGH', value: null })
|
||||
setFieldValueByBatch(temps);
|
||||
|
||||
break;
|
||||
case 30:
|
||||
setFieldVisible("THRESHOLD_DUST", false);
|
||||
setFieldVisible("THRESHOLD_NOISE", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_05", true);
|
||||
setFieldVisible("THRESHOLD_RADIATION_10", true);
|
||||
setFieldVisible("THRESHOLD_RADIATION_AROUND", true);
|
||||
setFieldVisible("THRESHOLD_WARTER_LOW", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_HIGH", false);
|
||||
|
||||
temps.push({ field: 'THRESHOLD_DUST', value: null })
|
||||
temps.push({ field: 'THRESHOLD_NOISE', value: null })
|
||||
temps.push({ field: 'THRESHOLD_WARTER_LOW', value: null })
|
||||
temps.push({ field: 'THRESHOLD_WARTER_HIGH', value: null })
|
||||
setFieldValueByBatch(temps);
|
||||
|
||||
break;
|
||||
case 40:
|
||||
setFieldVisible("THRESHOLD_DUST", false);
|
||||
setFieldVisible("THRESHOLD_NOISE", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_05", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_10", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_AROUND", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_LOW", true);
|
||||
setFieldVisible("THRESHOLD_WARTER_HIGH", true);
|
||||
|
||||
temps.push({ field: 'THRESHOLD_DUST', value: null })
|
||||
temps.push({ field: 'THRESHOLD_NOISE', value: null })
|
||||
temps.push({ field: 'THRESHOLD_RADIATION_05', value: null })
|
||||
temps.push({ field: 'THRESHOLD_RADIATION_10', value: null })
|
||||
temps.push({ field: 'THRESHOLD_RADIATION_AROUND', value: null })
|
||||
setFieldValueByBatch(temps);
|
||||
|
||||
break;
|
||||
default:
|
||||
|
||||
setFieldVisible("THRESHOLD_DUST", false);
|
||||
setFieldVisible("THRESHOLD_NOISE", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_05", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_10", false);
|
||||
setFieldVisible("THRESHOLD_RADIATION_AROUND", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_LOW", false);
|
||||
setFieldVisible("THRESHOLD_WARTER_HIGH", false);
|
||||
|
||||
temps.push({ field: 'THRESHOLD_DUST', value: null })
|
||||
temps.push({ field: 'THRESHOLD_NOISE', value: null })
|
||||
temps.push({ field: 'THRESHOLD_RADIATION_05', value: null })
|
||||
temps.push({ field: 'THRESHOLD_RADIATION_10', value: null })
|
||||
temps.push({ field: 'THRESHOLD_RADIATION_AROUND', value: null })
|
||||
temps.push({ field: 'THRESHOLD_WARTER_LOW', value: null })
|
||||
temps.push({ field: 'THRESHOLD_WARTER_HIGH', value: null })
|
||||
setFieldValueByBatch(temps);
|
||||
break;
|
||||
}
|
||||
} else if (colInfo.FIELD_NAME == "MONITOR_INTERVAL") {
|
||||
// OHHazardMonitorIntervalEnum
|
||||
/// 每天 10, 每周 20, 每月 30, 每季(每季度第一月) 40, 每半年 50, 每年 60,
|
||||
|
||||
const temps = [];
|
||||
switch (value) {
|
||||
case 10:
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("MONTH", false);
|
||||
setFieldVisible("DAY", false);
|
||||
|
||||
temps.push({ field: 'WEEKDATA', value: null })
|
||||
temps.push({ field: 'DAY', value: null })
|
||||
temps.push({ field: 'MONTH', value: null })
|
||||
setFieldValueByBatch(temps);
|
||||
|
||||
break;
|
||||
case 20:
|
||||
setFieldVisible("DAY", false);
|
||||
setFieldVisible("MONTH", false);
|
||||
setFieldVisible("WEEKDATA", true);
|
||||
|
||||
temps.push({ field: 'DAY', value: null })
|
||||
temps.push({ field: 'MONTH', value: null })
|
||||
setFieldValueByBatch(temps);
|
||||
|
||||
break;
|
||||
case 30:
|
||||
setFieldVisible("DAY", true);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("MONTH", false);
|
||||
|
||||
|
||||
temps.push({ field: 'WEEKDATA', value: null })
|
||||
temps.push({ field: 'MONTH', value: null })
|
||||
setFieldValueByBatch(temps);
|
||||
|
||||
break;
|
||||
case 40:
|
||||
case 50:
|
||||
case 60:
|
||||
|
||||
setFieldVisible("DAY", true);
|
||||
setFieldVisible("MONTH", true);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
|
||||
setFieldValue("WEEKDATA", null);
|
||||
break;
|
||||
default:
|
||||
setFieldVisible("DAY", false);
|
||||
setFieldVisible("MONTH", false);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
|
||||
temps.push({ field: 'WEEKDATA', value: null })
|
||||
temps.push({ field: 'DAY', value: null })
|
||||
temps.push({ field: 'MONTH', value: null })
|
||||
setFieldValueByBatch(temps);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// if (colInfo.FIELD_NAME == "Nav_ListCheckProjectCategory" || colInfo.FIELD_NAME == "Nav_ListCheckRiskArea" || colInfo.FIELD_NAME == "Nav_ListCheckProject") {
|
||||
// //填充数据 OrderPagedCheckMain
|
||||
// var orgId = colInfo.ORG_ID; //登录后有存储登录信息
|
||||
// let json = initFilter(orgId);
|
||||
// let CHECK_TYPE_ID = getFieldValue("CHECK_TYPE_ID")
|
||||
// let CHECK_TYPE_LEVEL_ID = getFieldValue("CHECK_TYPE_LEVEL_ID")
|
||||
|
||||
// extendRule(json, 'Parameter2', 1, CHECK_TYPE_ID);
|
||||
// extendRule(json, 'Parameter3', 1, getFieldValue("CHECKOBJECT"));
|
||||
// extendRule(json, 'Parameter4', 1, CHECK_TYPE_LEVEL_ID);
|
||||
|
||||
// let listArea = getFieldValue("Nav_ListCheckRiskArea")
|
||||
// let areaIDs = ""
|
||||
// if (listArea != undefined && listArea.length > 0) {
|
||||
// for (let i = 0; i < listArea.length; i++) {
|
||||
// if (listArea[i].IS_DELETED == undefined || listArea[i].IS_DELETED == null || listArea[i].IS_DELETED == false)
|
||||
// areaIDs += (areaIDs.length > 0 ? "," : "") + listArea[i].RISK_AREA_ID
|
||||
// }
|
||||
// }
|
||||
// extendRule(json, 'Parameter5', 1, areaIDs);
|
||||
|
||||
// let listProject = getFieldValue("Nav_ListCheckProject")
|
||||
// let ProjectIDs = ""
|
||||
// if (listProject != undefined && listProject.length > 0) {
|
||||
// for (let i = 0; i < listProject.length; i++) {
|
||||
// if (listProject[i].IS_DELETED == undefined || listProject[i].IS_DELETED == null || listProject[i].IS_DELETED == false)
|
||||
// ProjectIDs += (ProjectIDs.length > 0 ? "," : "") + listProject[i].CHECK_PROJECT_ID
|
||||
// }
|
||||
// }
|
||||
// extendRule(json, 'Parameter6', 1, ProjectIDs);
|
||||
// let valCategory = getFieldValue('Nav_ListCheckProjectCategory');
|
||||
// let ProjectCategoryIDs = ""
|
||||
// if (valCategory != undefined && valCategory.length > 0) {
|
||||
// for (let i = 0; i < valCategory.length; i++) {
|
||||
// if (valCategory[i].IS_DELETED == undefined || valCategory[i].IS_DELETED == null || valCategory[i].IS_DELETED == false)
|
||||
// ProjectCategoryIDs += (ProjectCategoryIDs.length > 0 ? "," : "") + valCategory[i].CHECK_PROJECT_CATEGORY_ID
|
||||
// }
|
||||
// }
|
||||
// extendRule(json, 'Parameter1', 1, ProjectCategoryIDs);
|
||||
// extendRule(json, 'Keyword', 1, getFieldValue("ID"));
|
||||
// if (areaIDs.length > 0 && ProjectIDs.length > 0 && ProjectCategoryIDs.length > 0 && CHECK_TYPE_ID != undefined && CHECK_TYPE_ID.length > 0 && CHECK_TYPE_LEVEL_ID != undefined && CHECK_TYPE_LEVEL_ID.length > 0) {
|
||||
// dispatch({
|
||||
// type: 'app/getDataByPost',
|
||||
// url: 'BS/BSSafeCheck/OrderPagedSafeCheckDetail',
|
||||
// payload: json,
|
||||
// onlyData: false,
|
||||
// onComplete: (ret) => {
|
||||
// let temps = [];
|
||||
// if (ret && ret.IsSuccessful && ret.Data) {
|
||||
// let detail = ret.Data.map((item, i) => {
|
||||
// item['ROW_NO'] = i + 1;
|
||||
// return item;
|
||||
// });
|
||||
// temps.push({ field: "Nav_ListSafeCheckDetail", value: detail });
|
||||
|
||||
// if (detail.length > 50) {
|
||||
// notification.info({
|
||||
// message: <a style={{ color: 'red' }}>温馨提示</a>,
|
||||
// description: '检查任务超过50条后会影响执行效率,请谨慎操作!',
|
||||
// placement: 'bottomLeft',
|
||||
// });
|
||||
// }
|
||||
|
||||
// } else {
|
||||
// temps.push({ field: "Nav_ListSafeCheckDetail", value: null });
|
||||
// }
|
||||
// setFieldValueByBatch(temps);
|
||||
// }
|
||||
// });
|
||||
// } else {
|
||||
// if (stateData == undefined || (stateData != undefined && stateData.CREACTTYPE != undefined && stateData.CREACTTYPE != 30)) {
|
||||
// let temps = [];
|
||||
// temps.push({ field: "Nav_ListSafeCheckDetail", value: null });
|
||||
// setFieldValueByBatch(temps);
|
||||
// }
|
||||
// }
|
||||
// } else {
|
||||
// if (colInfo != null && (colInfo.FIELD_NAME == "Nav_CheckTypeLevel.Nav_Enums.NAME" || colInfo.FIELD_NAME == "Nav_CheckType.NAME")) {
|
||||
// // getFieldValue, setFieldValue
|
||||
// var typeName = getFieldValue("Nav_CheckType.NAME")
|
||||
// if (typeName == null || typeName == '') {
|
||||
// const temps = [];
|
||||
// temps.push({ field: 'Nav_CheckTypeLevel.Nav_Enums.NAME', value: null })
|
||||
// temps.push({ field: 'NAME', value: '' })
|
||||
// setFieldValueByBatch(temps);
|
||||
// } else {
|
||||
// var levelName = getFieldValue("Nav_CheckTypeLevel.Nav_Enums.NAME")
|
||||
// setFieldValue("NAME", (levelName == null ? "" : levelName) + (typeName == null ? "" : typeName))
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
},
|
||||
|
||||
}
|
||||
@ -1,482 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 职业危害因素监测规则
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'OH024', '职业危害因素监测前端日志')
|
||||
|
||||
},
|
||||
onBeforeEdit: ({ isNew, setRowFieldVisible,setRowFieldLabel, editConfig, setEditConfig, stateData, setFieldVisible, setFieldValueByBatch, getSubTableData, setFieldEditable, login }) => {
|
||||
if (isNew) {
|
||||
setFieldVisible("SAMPLE_PEOPLE", false);
|
||||
const temps = [];
|
||||
// temps.push({ field: 'SAMPLE_PEOPLE', value: login.user.ID })
|
||||
temps.push({ field: 'USER_ID', value: login.user.ID })
|
||||
temps.push({ field: 'Nav_User.NAME', value: login.user.NAME })
|
||||
temps.push({ field: 'MONITOR_TIME', value: (new Date()).Format("yyyy-MM-dd HH:mm:ss") })
|
||||
setFieldValueByBatch(temps);
|
||||
} else {
|
||||
|
||||
if (stateData.USER_ID == null) {
|
||||
const temps = [];
|
||||
// temps.push({ field: 'SAMPLE_PEOPLE', value: login.user.ID })
|
||||
temps.push({ field: 'USER_ID', value: login.user.ID })
|
||||
temps.push({ field: 'Nav_User.NAME', value: login.user.NAME })
|
||||
temps.push({ field: 'MONITOR_TIME', value: (new Date()).Format("yyyy-MM-dd HH:mm:ss") })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
// debugger
|
||||
if (stateData.TYPE_ID != null) {
|
||||
setFieldEditable("Nav_Type.NAME", false)
|
||||
}
|
||||
|
||||
//子表显示隐藏
|
||||
switch (stateData.MONITOR_TYPE) {
|
||||
case 10:
|
||||
/// 生产扬尘浓度监测 10
|
||||
// 监测车间 监测地点 扬尘来源 扬尘类别 作业状态 个体防护情况 测定结果最低 测定结果最高 是否超限
|
||||
setRowFieldVisible(
|
||||
"T_OH_HAZARD_MONITOR_JOB_DETAIL",
|
||||
{
|
||||
// Nav_Rule.Nav_Type.SMALL_TYPE:true,
|
||||
SAMPLE_SOURCE: true,
|
||||
JOB_STATUS: true,
|
||||
PROTECT_STATUS: true,
|
||||
MONITOR_RESULT_LOW: true,
|
||||
MONITOR_RESULT_HIGH: true,
|
||||
// OVER_LIMIT: false,
|
||||
MONITOR_RESULT_05: false,
|
||||
MONITOR_RESULT_10: false,
|
||||
MONITOR_RESULT_AROUND: false,
|
||||
SAMPLE_TIME: false,
|
||||
TEST_TIME: false,
|
||||
MONITOR_RESULT: false,
|
||||
TEST_DEPARTMENT: false,
|
||||
TESTER: false,
|
||||
}
|
||||
);
|
||||
setFieldVisible("Nav_User.NAME", true)
|
||||
setFieldVisible("DEVICE_NAME", true)
|
||||
setFieldVisible("DEVICE_SPEC", true)
|
||||
setFieldVisible("MONITOR_METHOD", true)
|
||||
setFieldVisible("SAMPLE_PEOPLE", false)
|
||||
|
||||
setRowFieldLabel(
|
||||
"T_OH_HAZARD_MONITOR_JOB_DETAIL", {
|
||||
SAMPLE_SOURCE: '扬尘来源',
|
||||
'Nav_Rule.Nav_Type.SMALL_TYPE': '扬尘类别',
|
||||
"Nav_Rule.Nav_DepartmentWorkshop.NAME": '监测车间',
|
||||
})
|
||||
break;
|
||||
case 20:
|
||||
/// 工作场所噪声监测 20
|
||||
// 监测车间 监测地点 噪声来源 作业状态 个体防护情况 测定结果最低 测定结果最高 是否超限
|
||||
//子表列不可见
|
||||
setRowFieldVisible(
|
||||
"T_OH_HAZARD_MONITOR_JOB_DETAIL",
|
||||
{
|
||||
SAMPLE_SOURCE: true,
|
||||
JOB_STATUS: true,
|
||||
PROTECT_STATUS: true,
|
||||
MONITOR_RESULT_LOW: true,
|
||||
MONITOR_RESULT_HIGH: true,
|
||||
// OVER_LIMIT: false,
|
||||
MONITOR_RESULT_05: false,
|
||||
MONITOR_RESULT_10: false,
|
||||
MONITOR_RESULT_AROUND: false,
|
||||
SAMPLE_TIME: false,
|
||||
TEST_TIME: false,
|
||||
MONITOR_RESULT: false,
|
||||
TEST_DEPARTMENT: false,
|
||||
TESTER: false,
|
||||
}
|
||||
);
|
||||
//页面属性 不可见
|
||||
setFieldVisible("Nav_User.NAME", true)
|
||||
setFieldVisible("DEVICE_NAME", true)
|
||||
setFieldVisible("DEVICE_SPEC", true)
|
||||
setFieldVisible("MONITOR_METHOD", true)
|
||||
setFieldVisible("SAMPLE_PEOPLE", false)
|
||||
//子表 列标题
|
||||
setRowFieldLabel(
|
||||
"T_OH_HAZARD_MONITOR_JOB_DETAIL", {
|
||||
SAMPLE_SOURCE: '噪声来源',
|
||||
'Nav_Rule.Nav_Type.SMALL_TYPE': '检测细分',
|
||||
"Nav_Rule.Nav_DepartmentWorkshop.NAME": '监测车间',
|
||||
})
|
||||
break;
|
||||
case 30:
|
||||
// 放射源放射性监测 30
|
||||
// 类别 监测车间 监测地点 0.5m处监测值 1m处监测值 周围环境值 是否超限
|
||||
setRowFieldVisible(
|
||||
"T_OH_HAZARD_MONITOR_JOB_DETAIL",
|
||||
{
|
||||
SAMPLE_SOURCE: false,
|
||||
JOB_STATUS: false,
|
||||
PROTECT_STATUS: false,
|
||||
MONITOR_RESULT_LOW: false,
|
||||
MONITOR_RESULT_HIGH: false,
|
||||
// OVER_LIMIT: false,
|
||||
MONITOR_RESULT_05: true,
|
||||
MONITOR_RESULT_10: true,
|
||||
MONITOR_RESULT_AROUND: true,
|
||||
SAMPLE_TIME: false,
|
||||
TEST_TIME: false,
|
||||
MONITOR_RESULT: false,
|
||||
TEST_DEPARTMENT: false,
|
||||
TESTER: false,
|
||||
}
|
||||
);
|
||||
setFieldVisible("Nav_User.NAME", true)
|
||||
setFieldVisible("DEVICE_NAME", true)
|
||||
setFieldVisible("DEVICE_SPEC", true)
|
||||
setFieldVisible("MONITOR_METHOD", true)
|
||||
setFieldVisible("SAMPLE_PEOPLE", false)
|
||||
|
||||
setRowFieldLabel(
|
||||
"T_OH_HAZARD_MONITOR_JOB_DETAIL", {
|
||||
'Nav_Rule.Nav_Type.SMALL_TYPE': '检测细分',
|
||||
"Nav_Rule.Nav_DepartmentWorkshop.NAME": '监测车间',
|
||||
})
|
||||
break;
|
||||
case 40:
|
||||
// 水质监测记录表单 40
|
||||
// 类别 取样车间 取样地点 水来源 取样时间 化验时间 监测数据 是否超限 化验部门 化验人
|
||||
setRowFieldVisible(
|
||||
"T_OH_HAZARD_MONITOR_JOB_DETAIL",
|
||||
{
|
||||
SAMPLE_SOURCE: true,
|
||||
JOB_STATUS: false,
|
||||
PROTECT_STATUS: false,
|
||||
MONITOR_RESULT_LOW: false,
|
||||
MONITOR_RESULT_HIGH: false,
|
||||
// OVER_LIMIT: false,
|
||||
MONITOR_RESULT_05: false,
|
||||
MONITOR_RESULT_10: false,
|
||||
MONITOR_RESULT_AROUND: false,
|
||||
SAMPLE_TIME: true,
|
||||
TEST_TIME: true,
|
||||
MONITOR_RESULT: true,
|
||||
TEST_DEPARTMENT: true,
|
||||
TESTER: true,
|
||||
}
|
||||
);
|
||||
|
||||
setFieldVisible("Nav_User.NAME", false)
|
||||
setFieldVisible("DEVICE_NAME", false)
|
||||
setFieldVisible("DEVICE_SPEC", false)
|
||||
setFieldVisible("MONITOR_METHOD", false)
|
||||
setFieldVisible("SAMPLE_PEOPLE", true)
|
||||
|
||||
setRowFieldLabel(
|
||||
"T_OH_HAZARD_MONITOR_JOB_DETAIL", {
|
||||
SAMPLE_SOURCE: '水来源',
|
||||
"Nav_Rule.Nav_DepartmentWorkshop.NAME": '取样车间',
|
||||
'Nav_Rule.Nav_Type.SMALL_TYPE': '检测细分'
|
||||
})
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
onChange: ({ stateData, setRowFieldLabel, setRowFieldVisible, value, colInfo, setFieldVisible, setFieldValue, dispatch, setFieldValueByBatch, getSubTableData, updateSubTableData }) => {
|
||||
|
||||
if (colInfo != null) {
|
||||
/// 生产扬尘浓度监测 10 工作场所噪声监测 20 放射源放射性监测 30 水质监测记录表单 40
|
||||
if (colInfo.FIELD_NAME == "Nav_Type.NAME") {
|
||||
const temps = [];
|
||||
switch (stateData.Nav_Type.MONITOR_TYPE) {
|
||||
case 10:
|
||||
/// 生产扬尘浓度监测 10
|
||||
// 监测车间 监测地点 扬尘来源 扬尘类别 作业状态 个体防护情况 测定结果最低 测定结果最高 是否超限
|
||||
setRowFieldVisible(
|
||||
"T_OH_HAZARD_MONITOR_JOB_DETAIL",
|
||||
{
|
||||
SAMPLE_SOURCE: true,
|
||||
JOB_STATUS: true,
|
||||
PROTECT_STATUS: true,
|
||||
MONITOR_RESULT_LOW: true,
|
||||
MONITOR_RESULT_HIGH: true,
|
||||
// OVER_LIMIT: false,
|
||||
MONITOR_RESULT_05: false,
|
||||
MONITOR_RESULT_10: false,
|
||||
MONITOR_RESULT_AROUND: false,
|
||||
SAMPLE_TIME: false,
|
||||
TEST_TIME: false,
|
||||
MONITOR_RESULT: false,
|
||||
TEST_DEPARTMENT: false,
|
||||
TESTER: false,
|
||||
}
|
||||
);
|
||||
setFieldVisible("Nav_User.NAME", true)
|
||||
setFieldVisible("DEVICE_NAME", true)
|
||||
setFieldVisible("DEVICE_SPEC", true)
|
||||
setFieldVisible("MONITOR_METHOD", true)
|
||||
setFieldVisible("SAMPLE_PEOPLE", false)
|
||||
|
||||
setRowFieldLabel(
|
||||
"T_OH_HAZARD_MONITOR_JOB_DETAIL", {
|
||||
SAMPLE_SOURCE: '扬尘来源',
|
||||
'Nav_Rule.Nav_Type.SMALL_TYPE': '扬尘类别',
|
||||
"Nav_Rule.Nav_DepartmentWorkshop.NAME": '监测车间',
|
||||
})
|
||||
break;
|
||||
case 20:
|
||||
/// 工作场所噪声监测 20
|
||||
// 监测车间 监测地点 噪声来源 作业状态 个体防护情况 测定结果最低 测定结果最高 是否超限
|
||||
setRowFieldVisible(
|
||||
"T_OH_HAZARD_MONITOR_JOB_DETAIL",
|
||||
{
|
||||
SAMPLE_SOURCE: true,
|
||||
JOB_STATUS: true,
|
||||
PROTECT_STATUS: true,
|
||||
MONITOR_RESULT_LOW: true,
|
||||
MONITOR_RESULT_HIGH: true,
|
||||
// OVER_LIMIT: false,
|
||||
MONITOR_RESULT_05: false,
|
||||
MONITOR_RESULT_10: false,
|
||||
MONITOR_RESULT_AROUND: false,
|
||||
SAMPLE_TIME: false,
|
||||
TEST_TIME: false,
|
||||
MONITOR_RESULT: false,
|
||||
TEST_DEPARTMENT: false,
|
||||
TESTER: false,
|
||||
}
|
||||
);
|
||||
setFieldVisible("Nav_User.NAME", true)
|
||||
setFieldVisible("DEVICE_NAME", true)
|
||||
setFieldVisible("DEVICE_SPEC", true)
|
||||
setFieldVisible("MONITOR_METHOD", true)
|
||||
setFieldVisible("SAMPLE_PEOPLE", false)
|
||||
|
||||
setRowFieldLabel(
|
||||
"T_OH_HAZARD_MONITOR_JOB_DETAIL", {
|
||||
SAMPLE_SOURCE: '噪声来源',
|
||||
'Nav_Rule.Nav_Type.SMALL_TYPE': '检测细分',
|
||||
"Nav_Rule.Nav_DepartmentWorkshop.NAME": '监测车间',
|
||||
})
|
||||
break;
|
||||
case 30:
|
||||
// 放射源放射性监测 30
|
||||
// 类别 监测车间 监测地点 0.5m处监测值 1m处监测值 周围环境值 是否超限
|
||||
setRowFieldVisible(
|
||||
"T_OH_HAZARD_MONITOR_JOB_DETAIL",
|
||||
{
|
||||
SAMPLE_SOURCE: false,
|
||||
JOB_STATUS: false,
|
||||
PROTECT_STATUS: false,
|
||||
MONITOR_RESULT_LOW: false,
|
||||
MONITOR_RESULT_HIGH: false,
|
||||
// OVER_LIMIT: false,
|
||||
MONITOR_RESULT_05: true,
|
||||
MONITOR_RESULT_10: true,
|
||||
MONITOR_RESULT_AROUND: true,
|
||||
SAMPLE_TIME: false,
|
||||
TEST_TIME: false,
|
||||
MONITOR_RESULT: false,
|
||||
TEST_DEPARTMENT: false,
|
||||
TESTER: false,
|
||||
}
|
||||
);
|
||||
setFieldVisible("Nav_User.NAME", true)
|
||||
setFieldVisible("DEVICE_NAME", true)
|
||||
setFieldVisible("DEVICE_SPEC", true)
|
||||
setFieldVisible("MONITOR_METHOD", true)
|
||||
setFieldVisible("SAMPLE_PEOPLE", false)
|
||||
|
||||
setRowFieldLabel(
|
||||
"T_OH_HAZARD_MONITOR_JOB_DETAIL", {
|
||||
'Nav_Rule.Nav_Type.SMALL_TYPE': '检测细分',
|
||||
"Nav_Rule.Nav_DepartmentWorkshop.NAME": '监测车间',
|
||||
})
|
||||
break;
|
||||
case 40:
|
||||
// 水质监测记录表单 40
|
||||
// 类别 取样车间 取样地点 水来源 取样时间 化验时间 监测数据 是否超限 化验部门 化验人
|
||||
setRowFieldVisible(
|
||||
"T_OH_HAZARD_MONITOR_JOB_DETAIL",
|
||||
{
|
||||
SAMPLE_SOURCE: true,
|
||||
JOB_STATUS: false,
|
||||
PROTECT_STATUS: false,
|
||||
MONITOR_RESULT_LOW: false,
|
||||
MONITOR_RESULT_HIGH: false,
|
||||
// OVER_LIMIT: false,
|
||||
MONITOR_RESULT_05: false,
|
||||
MONITOR_RESULT_10: false,
|
||||
MONITOR_RESULT_AROUND: false,
|
||||
SAMPLE_TIME: true,
|
||||
TEST_TIME: true,
|
||||
MONITOR_RESULT: true,
|
||||
TEST_DEPARTMENT: true,
|
||||
TESTER: true,
|
||||
}
|
||||
);
|
||||
setFieldVisible("Nav_User.NAME", false)
|
||||
setFieldVisible("DEVICE_NAME", false)
|
||||
setFieldVisible("DEVICE_SPEC", false)
|
||||
setFieldVisible("MONITOR_METHOD", false)
|
||||
setFieldVisible("SAMPLE_PEOPLE", true)
|
||||
|
||||
|
||||
setRowFieldLabel(
|
||||
"T_OH_HAZARD_MONITOR_JOB_DETAIL", {
|
||||
SAMPLE_SOURCE: '水来源',
|
||||
"Nav_Rule.Nav_DepartmentWorkshop.NAME": '取样车间',
|
||||
'Nav_Rule.Nav_Type.SMALL_TYPE': '检测细分'
|
||||
})
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
onSubChange: ({ row, pageCode, record, colInfo, dispatch, stateData, saveRowRecord, setDataState, setFieldValueByBatch }) => {
|
||||
// debugger
|
||||
if (stateData.MONITOR_TYPE == 30 && (colInfo.FIELD_NAME == 'MONITOR_RESULT_05' || colInfo.FIELD_NAME == 'MONITOR_RESULT_10' || colInfo.FIELD_NAME == 'MONITOR_RESULT_AROUND')) {
|
||||
//放射性
|
||||
if (record.MONITOR_RESULT_05 > record.Nav_Rule.THRESHOLD_RADIATION_05 || record.MONITOR_RESULT_10 > record.Nav_Rule.THRESHOLD_RADIATION_10 || record.MONITOR_RESULT_AROUND > record.Nav_Rule.THRESHOLD_RADIATION_AROUND) {
|
||||
record.OVER_LIMIT = 10
|
||||
} else {
|
||||
record.OVER_LIMIT = 20
|
||||
}
|
||||
setDataFieldValue(record, 'OVER_LIMIT', record.OVER_LIMIT);
|
||||
stateData.Nav_Detail.map((v, i) => {
|
||||
if (v.ID == record.ID) {
|
||||
v.OVER_LIMIT = record.OVER_LIMIT;
|
||||
}
|
||||
});
|
||||
} else if ((stateData.MONITOR_TYPE == 10 || stateData.MONITOR_TYPE == 20) && (colInfo.FIELD_NAME == 'MONITOR_RESULT_LOW' || colInfo.FIELD_NAME == 'MONITOR_RESULT_HIGH')) {
|
||||
//尘 噪音 生产扬尘浓度监测 10 工作场所噪声监测 20 放射源放射性监测 30 水质监测记录表单 40
|
||||
//THRESHOLD_NOISE
|
||||
if (stateData.MONITOR_TYPE == 10) {
|
||||
if (record.MONITOR_RESULT_HIGH > record.Nav_Rule.THRESHOLD_DUST || record.MONITOR_RESULT_LOW > record.Nav_Rule.THRESHOLD_DUST) {
|
||||
record.OVER_LIMIT = 10
|
||||
} else {
|
||||
record.OVER_LIMIT = 20
|
||||
}
|
||||
} else {
|
||||
//噪音
|
||||
if (record.MONITOR_RESULT_HIGH > record.Nav_Rule.THRESHOLD_NOISE || record.MONITOR_RESULT_LOW > record.Nav_Rule.THRESHOLD_NOISE) {
|
||||
record.OVER_LIMIT = 10
|
||||
} else {
|
||||
record.OVER_LIMIT = 20
|
||||
}
|
||||
}
|
||||
|
||||
setDataFieldValue(record, 'OVER_LIMIT', record.OVER_LIMIT);
|
||||
stateData.Nav_Detail.map((v, i) => {
|
||||
if (v.ID == record.ID) {
|
||||
v.OVER_LIMIT = record.OVER_LIMIT;
|
||||
}
|
||||
});
|
||||
} else if ((stateData.MONITOR_TYPE == 40) && (colInfo.FIELD_NAME == 'MONITOR_RESULT')) {
|
||||
//水质
|
||||
if (record.MONITOR_RESULT < record.Nav_Rule.THRESHOLD_WARTER_LOW || record.MONITOR_RESULT > record.Nav_Rule.THRESHOLD_WARTER_HIGH) {
|
||||
record.OVER_LIMIT = 10
|
||||
} else {
|
||||
record.OVER_LIMIT = 20
|
||||
}
|
||||
setDataFieldValue(record, 'OVER_LIMIT', record.OVER_LIMIT);
|
||||
stateData.Nav_Detail.map((v, i) => {
|
||||
if (v.ID == record.ID) {
|
||||
v.OVER_LIMIT = record.OVER_LIMIT;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
// if (colInfo.FIELD_NAME == 'FREQUENCY') {
|
||||
// let FREQUENCY = getDataFieldValue(record, 'FREQUENCY');
|
||||
// if (FREQUENCY < 0) {
|
||||
// message.error("周期内执行次数必须大于0");
|
||||
// setDataFieldValue(record, 'FREQUENCY', 0);
|
||||
// stateData.Nav_Details.map((v, i) => {
|
||||
// if (v.ID == record.ID) {
|
||||
// v.FREQUENCY = record.FREQUENCY;
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
// }
|
||||
// if (colInfo.FIELD_NAME == 'RISK_TYPE') {
|
||||
// let riskType = getDataFieldValue(record, 'RISK_TYPE');
|
||||
// if (riskType == 0 || riskType == 1) {
|
||||
// const json = initFilter();
|
||||
// extendRule(json, 'RISK_TYPE', 1, riskType);
|
||||
// extendOrder(json, 'CODE', 0);
|
||||
// dispatch({
|
||||
// type: 'app/getDataByPost',
|
||||
// url: 'HM/Identifying/OrderEntities',
|
||||
// payload: json,
|
||||
// onComplete: (ret) => {
|
||||
// if (ret) {
|
||||
// let identifyings = [];
|
||||
// if (ret && ret.length > 0) {
|
||||
// ret.forEach(item => {
|
||||
// let objIdentifying = {
|
||||
// DETAIL_ID: record.ID,
|
||||
// ID: guid(),
|
||||
// IDENTIFYING_ID: item.ID,
|
||||
// Nav_Identifying: { "NAME": item.NAME },
|
||||
// ORG_ID: record.ORG_ID,
|
||||
// }
|
||||
// identifyings.push(objIdentifying);
|
||||
// })
|
||||
// }
|
||||
// record["Nav_Identifyings"] = identifyings;
|
||||
// saveRowRecord(record)
|
||||
// }
|
||||
// }
|
||||
// })
|
||||
// } else {
|
||||
// record.Nav_Identifyings = [];
|
||||
// saveRowRecord(record)
|
||||
// }
|
||||
// }
|
||||
// if (colInfo.FIELD_NAME == 'Nav_Areas') {
|
||||
// let areas = getDataFieldValue(record, 'Nav_Areas');
|
||||
// let riskType = getDataFieldValue(record, 'RISK_TYPE');
|
||||
// let areaids = []
|
||||
// areas.forEach(element => {
|
||||
// areaids.push(element.AREA_ID)
|
||||
// });
|
||||
// const json = initFilter(null, areaids.toString())
|
||||
// json.Parameter1 = riskType;
|
||||
// if (areas.length > 0) {
|
||||
// dispatch({
|
||||
// type: 'app/getDataByPost',
|
||||
// url: 'HM/HMNoticeRelease/searchChargeUser',
|
||||
// payload: json,
|
||||
// onComplete: (ret) => {
|
||||
// if (ret) {
|
||||
// let chargePerson = {
|
||||
// NAME: ret,
|
||||
// }
|
||||
// record["Nav_ChargePerson"] = chargePerson;
|
||||
// saveRowRecord(record)
|
||||
// } else {
|
||||
// record.Nav_ChargePerson = "";
|
||||
// saveRowRecord(record)
|
||||
// }
|
||||
// }
|
||||
// })
|
||||
// } else {
|
||||
// record.Nav_ChargePerson = "";
|
||||
// saveRowRecord(record)
|
||||
// }
|
||||
// }
|
||||
},
|
||||
}
|
||||
@ -1,138 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 事故事件上报
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'OH006', '体检通知前端日志')
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, login, app }) => {
|
||||
|
||||
// if (!isNew && stateData.ISSYSTEM) {
|
||||
// //如果是系统推送 巡回检查通知 需要加载体检人员
|
||||
// var orgId = login ? login.OrgId : ''; //登录后有存储登录信息
|
||||
// let json = initFilter(orgId);
|
||||
// extendRule(json, 'ID', 1, id); //ID=‘’,字段,等于,条件值, 1代表=,2代表不等于,3小于,4小于等于,5大于,6大于等于,7以开始的Like,8以结束的Like,9包含
|
||||
// let that = this;
|
||||
// let btndisplay = 'none';
|
||||
// this.props.dispatch({
|
||||
// type: 'app/getDataByPost',
|
||||
// payload: json,
|
||||
// url: 'OH/OHHealthExamNotice/GetNoticeCycle',
|
||||
// onComplete: (ret) => { //返回查询结果ret
|
||||
// debugger
|
||||
// if (ret) { //判断是否有记录
|
||||
// this.setState({ //设置setState全局变量
|
||||
// data: ret, //将ret对象赋值给data, data供页面调用
|
||||
// // isMsgShow: true,
|
||||
// // dataBack: ret.Nav_ListResult
|
||||
// })
|
||||
// }
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
},
|
||||
|
||||
onSubChange: ({ row, pageCode, record, colInfo, dispatch, stateData, saveRowRecord, setDataState, setFieldValueByBatch }) => {
|
||||
if (colInfo != null && colInfo.FIELD_NAME == "Nav_User.NAME") {
|
||||
if (!record.CREATER_ID) {
|
||||
if (record.USER_ID == null) {
|
||||
// for (let i = 0; i < stateData.Nav_Plan.Nav_ListPlanRegister.length; i++) {
|
||||
// if (stateData.Nav_Plan.Nav_ListPlanRegister[i].ID == record.ID) {
|
||||
// stateData.Nav_Plan.Nav_ListPlanRegister[i].Nav_Department = null
|
||||
// stateData.Nav_Plan.Nav_ListPlanRegister[i].Nav_DepartmentWorkshop = null
|
||||
// stateData.Nav_Plan.Nav_ListPlanRegister[i].Nav_SCPost = null
|
||||
// stateData.Nav_Plan.Nav_ListPlanRegister[i].Nav_User = null
|
||||
// }
|
||||
// }
|
||||
} else {
|
||||
var orgId = colInfo.ORG_ID;
|
||||
// 获取人员后 去后台判断 再获取数据
|
||||
let json = initFilter(orgId, record.USER_ID, null, null, 1, stateData.ID, record.ID, record.TYPE);
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'OH/OHHealthExamNotice/GetCombinNoticeRegister',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
if (ret && ret.IsSuccessful) {
|
||||
record = ret.Data
|
||||
for (let i = 0; i < stateData.Nav_ListNoticeRegister.length; i++) {
|
||||
if (stateData.Nav_ListNoticeRegister[i].ID == record.ID) {
|
||||
stateData.Nav_ListNoticeRegister[i] = record
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
// handleRenderRowControl(params) {
|
||||
// if (params.record.CREATE_TIME) {
|
||||
// if (params.colConfig.field == 'Nav_Department.NAME') {
|
||||
// return <>
|
||||
// {params.record.Nav_Department?.NAME}
|
||||
// </>
|
||||
// }
|
||||
// else if (params.colConfig.field == 'Nav_DepartmentWorkshop.NAME') {
|
||||
// return <>
|
||||
// {params.record.Nav_DepartmentWorkshop?.NAME}
|
||||
// </>
|
||||
// }
|
||||
// else if (params.colConfig.field == 'Nav_User.NAME') {
|
||||
// return <>
|
||||
// {params.record.Nav_User.NAME}
|
||||
// </>
|
||||
// }
|
||||
// // else if (params.colConfig.field == 'Nav_User.ID_CARD') {
|
||||
// // return <>
|
||||
// // {params.record.Nav_User.ID_CARD}
|
||||
// // </>
|
||||
// // }
|
||||
// // else if (params.colConfig.field == 'Nav_User.SEX') {
|
||||
// // return <>
|
||||
// // {params.record.Nav_User.SEX}
|
||||
// // </>
|
||||
// // }
|
||||
// // else if (params.colConfig.field == 'Nav_SCPost.NAME') {
|
||||
// // return <>
|
||||
// // {params.record.Nav_SCPost?.NAME}
|
||||
// // </>
|
||||
// // }
|
||||
// // else if (params.colConfig.field == 'WORKYEAR') {
|
||||
// // return <>
|
||||
// // {params.record.WORKYEAR}
|
||||
// // </>
|
||||
// // }
|
||||
// else if (params.colConfig.field == 'Nav_ExamCycle.HEALTH_EXAM_CONTENT') {
|
||||
// return <>
|
||||
// {params.record.Nav_ExamCycle.HEALTH_EXAM_CONTENT}
|
||||
// </>
|
||||
// }
|
||||
// else if (params.colConfig.field == 'TYPE') {
|
||||
// return <>
|
||||
// {params.record.TYPE}
|
||||
// </>
|
||||
// }
|
||||
// // else if (params.colConfig.field == 'CHECKCONTENT') {
|
||||
// // return <>
|
||||
// // {params.record.CHECKCONTENT}
|
||||
// // </>
|
||||
// // }
|
||||
// } else {
|
||||
// return '';
|
||||
// }
|
||||
// }
|
||||
|
||||
|
||||
|
||||
}
|
||||
@ -1,62 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 监测结果统计与分析汇总
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
|
||||
// STR_RATIO
|
||||
|
||||
onBeforeSaveHandleRecordLog(params, 'OH028', '监测结果统计与分析汇总前端日志')
|
||||
},
|
||||
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, login, app, setFieldValue }) => {
|
||||
//(stateData.RATIO == null || stateData.RATIO == 0) &&
|
||||
if (stateData.Nav_ListMonitorResult != null && stateData.Nav_ListMonitorResult.length > 0) {
|
||||
var radio = 0;
|
||||
let countHas = 0;
|
||||
for (let i = 0; i < stateData.Nav_ListMonitorResult.length; i++) {
|
||||
if (stateData.Nav_ListMonitorResult[i].TREND != null && stateData.Nav_ListMonitorResult[i].TREND.length > 0) {
|
||||
countHas++
|
||||
}
|
||||
}
|
||||
if (countHas == 0) {
|
||||
// setFieldValue("RATIO", '');
|
||||
setFieldValue("STR_RATIO", '');
|
||||
} else {
|
||||
radio = (100.0 * countHas / stateData.Nav_ListMonitorResult.length).toFixed(1)
|
||||
// setFieldValue("RATIO", radio);
|
||||
setFieldValue("STR_RATIO", radio + '%');
|
||||
}
|
||||
}
|
||||
},
|
||||
onSubChange: ({ row, pageCode, record, colInfo, dispatch, stateData, setFieldValue, setDataState, setFieldValueByBatch }) => {
|
||||
if (colInfo != null && colInfo.FIELD_NAME == "TREND") {
|
||||
if (stateData.Nav_ListMonitorResult != null && stateData.Nav_ListMonitorResult.length > 0) {
|
||||
var radio = 0;
|
||||
let countHas = 0;
|
||||
for (let i = 0; i < stateData.Nav_ListMonitorResult.length; i++) {
|
||||
if (stateData.Nav_ListMonitorResult[i].TREND != null && stateData.Nav_ListMonitorResult[i].TREND.length > 0) {
|
||||
countHas++
|
||||
}
|
||||
}
|
||||
if (countHas == 0) {
|
||||
// stateData.RATIO = ''
|
||||
stateData.STR_RATIO = ''
|
||||
stateData.RATIO = 0
|
||||
} else {
|
||||
radio = (100.0 * countHas / stateData.Nav_ListMonitorResult.length).toFixed(1)
|
||||
// stateData.RATIO = radio
|
||||
stateData.STR_RATIO = radio + '%'
|
||||
stateData.RATIO = radio / 100.0
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1,34 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 监测结果统计与分析汇总
|
||||
export default {
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, login, app, setFieldValueByBatch }) => {
|
||||
var dtDEPARTURETIME = ''
|
||||
var dtENTRYTIME = ''
|
||||
var dtStartTIME = ''
|
||||
if (stateData.Nav_NoticeRegister != null && stateData.Nav_NoticeRegister.Nav_User != null && stateData.Nav_NoticeRegister.Nav_User.DEPARTURETIME != '0001-01-01 00:00:00') {
|
||||
dtDEPARTURETIME = stateData.Nav_NoticeRegister?.Nav_User?.DEPARTURETIME.split(' ')[0]
|
||||
}
|
||||
if (stateData.Nav_NoticeRegister != null && stateData.Nav_NoticeRegister.Nav_User != null && stateData.Nav_NoticeRegister.Nav_User.ENTRYTIME != '0001-01-01 00:00:00') {
|
||||
dtENTRYTIME = stateData.Nav_NoticeRegister?.Nav_User?.ENTRYTIME.split(' ')[0]
|
||||
}
|
||||
|
||||
if (stateData.Nav_NoticeRegister?.Nav_ExamBatch?.START_TIME != '0001-01-01 00:00:00') {
|
||||
dtStartTIME = stateData?.Nav_NoticeRegister?.Nav_ExamBatch?.START_TIME.split(' ')[0]
|
||||
}
|
||||
const temps = [];
|
||||
temps.push({ field: 'Nav_NoticeRegister.Nav_ExamBatch.BATCH', value: stateData.Nav_NoticeRegister.Nav_ExamBatch.BATCH })
|
||||
temps.push({ field: 'Nav_NoticeRegister.Nav_User.NAME', value: stateData.Nav_NoticeRegister.Nav_User.NAME })
|
||||
temps.push({ field: 'Nav_User.ID_CARD', value: stateData.Nav_User.ID_CARD })
|
||||
temps.push({ field: 'Nav_NoticeRegister.Nav_User.DEPARTURETIME', value: dtDEPARTURETIME })
|
||||
temps.push({ field: 'Nav_NoticeRegister.Nav_User.ENTRYTIME', value: dtENTRYTIME })
|
||||
temps.push({ field: 'Nav_NoticeRegister.Nav_ExamBatch.START_TIME', value: dtStartTIME })
|
||||
setFieldValueByBatch(temps);
|
||||
|
||||
}
|
||||
}
|
||||
@ -1,24 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 职业危害因素监测规则
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'OH034', '第三方检测报告')
|
||||
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, setFieldVisible, setFieldValueByBatch, setFieldEditable, login }) => {
|
||||
if (isNew || !stateData.YEAR) {
|
||||
const temps = [];
|
||||
temps.push({ field: 'NAME', value: '职业危害检测报告' })
|
||||
temps.push({ field: 'YEAR', value: (new Date()).Format("yyyy") })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1,26 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'TI008', '前端日志')
|
||||
},
|
||||
|
||||
onBeforeEdit: ({ isNew, setFieldValueByBatch, login }) => {
|
||||
if (isNew) {
|
||||
const temps = [];
|
||||
temps.push({ field: 'USER_ID', value: login.user.ID })
|
||||
temps.push({ field: 'Nav_User.NAME', value: login.user.NAME })
|
||||
temps.push({ field: 'USETIME', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
},
|
||||
|
||||
}
|
||||
@ -1,37 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全科技计划
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'TI008', '前端日志')
|
||||
},
|
||||
|
||||
onBeforeEdit: ({ isNew, setFieldValueByBatch, login }) => {
|
||||
if (isNew) {
|
||||
const temps = [];
|
||||
temps.push({ field: 'DEPARTMENT_ID', value: login.user.DEPARTMENT_ID });
|
||||
temps.push({ field: 'Nav_Department.NAME', value: login.user.Nav_Department.NAME });
|
||||
temps.push({ field: 'USER_ID', value: login.user.ID })
|
||||
temps.push({ field: 'Nav_User.NAME', value: login.user.NAME })
|
||||
temps.push({ field: 'BEGINTIME', value: (new Date()).Format("yyyy-MM-dd HH:mm:ss") })
|
||||
temps.push({ field: 'YEAR', value: (new Date()).Format("yyyy") })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
},
|
||||
|
||||
onChange: ({ value, colInfo, dispatch, setFieldValueByBatch, record, stateData, data, getFieldValue, setFieldVisible, setFieldValue }) => {
|
||||
if (colInfo != null && colInfo.FIELD_NAME == "Nav_Department.NAME") {
|
||||
const temps = [];
|
||||
temps.push({ field: 'USER_ID', value: null })
|
||||
temps.push({ field: 'Nav_User.NAME', value: null })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1,43 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全科技计划
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'TI008', '前端日志')
|
||||
},
|
||||
|
||||
onBeforeEdit: ({ isNew, setFieldValueByBatch, login, stateData, setFieldEditable }) => {
|
||||
if (isNew) {
|
||||
const temps = [];
|
||||
temps.push({ field: 'DEPARTMENT_ID', value: login.user.DEPARTMENT_ID });
|
||||
temps.push({ field: 'Nav_Department.NAME', value: login.user.Nav_Department.NAME });
|
||||
temps.push({ field: 'USER_ID', value: login.user.ID })
|
||||
temps.push({ field: 'Nav_User.NAME', value: login.user.NAME })
|
||||
temps.push({ field: 'BEGINTIME', value: (new Date()).Format("yyyy-MM-dd HH:mm:ss") })
|
||||
temps.push({ field: 'YEAR', value: (new Date()).Format("yyyy") })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
if (stateData.PLAN_ID) {
|
||||
setFieldEditable("YEAR", false);
|
||||
setFieldEditable("CODE", false);
|
||||
setFieldEditable("NAME", false);
|
||||
setFieldEditable("Nav_Manger.NAME", false);
|
||||
}
|
||||
},
|
||||
|
||||
onChange: ({ value, colInfo, dispatch, setFieldValueByBatch, record, stateData, data, getFieldValue, setFieldVisible, setFieldValue }) => {
|
||||
if (colInfo != null && colInfo.FIELD_NAME == "Nav_Department.NAME") {
|
||||
const temps = [];
|
||||
temps.push({ field: 'USER_ID', value: null })
|
||||
temps.push({ field: 'Nav_User.NAME', value: null })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1,98 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全科技计划
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'TI008', '前端日志')
|
||||
},
|
||||
|
||||
onBeforeEdit: ({ isNew, setFieldValueByBatch, login }) => {
|
||||
if (isNew) {
|
||||
const temps = [];
|
||||
temps.push({ field: 'DEPARTMENT_ID', value: login.user.DEPARTMENT_ID });
|
||||
temps.push({ field: 'Nav_Department.NAME', value: login.user.Nav_Department.NAME });
|
||||
temps.push({ field: 'USER_ID', value: login.user.ID })
|
||||
temps.push({ field: 'Nav_User.NAME', value: login.user.NAME })
|
||||
temps.push({ field: 'BEGINTIME', value: (new Date()).Format("yyyy-MM-dd HH:mm:ss") })
|
||||
temps.push({ field: 'YEAR', value: (new Date()).Format("yyyy") })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
},
|
||||
|
||||
onChange: ({ value, colInfo, dispatch, setFieldValueByBatch, record, stateData, data, getFieldValue, setFieldVisible, setFieldValue }) => {
|
||||
if (colInfo != null && colInfo.FIELD_NAME == "Nav_Department.NAME") {
|
||||
const temps = [];
|
||||
temps.push({ field: 'USER_ID', value: null })
|
||||
temps.push({ field: 'Nav_User.NAME', value: null })
|
||||
setFieldValueByBatch(temps);
|
||||
} else if (colInfo != null && colInfo.FIELD_NAME == "Nav_Project.CODE") {
|
||||
// 项目编号 加载 项目来源 所属范围 Nav_Project.Nav_Sources Nav_Project.Nav_Ranges
|
||||
var projectID = getFieldValue("PROJECT_ID")
|
||||
if (projectID != undefined && projectID != null && projectID.length > 0) {
|
||||
let json = initFilter(colInfo.ORG_ID, projectID);
|
||||
extendInclude(json, 'Nav_Sources.Nav_Source');
|
||||
extendInclude(json, 'Nav_Ranges.Nav_Range');
|
||||
extendInclude(json, 'Nav_Manger');
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TI/TIProject/GetCheck',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
let temps = [];
|
||||
var strSource = ""
|
||||
var strRange = ""
|
||||
if (ret && ret.IsSuccessful && ret.Data) {
|
||||
if (ret.Data.Nav_Sources != null && ret.Data.Nav_Sources.length > 0) {
|
||||
for (let i = 0; i < ret.Data.Nav_Sources.length; i++) {
|
||||
strSource += (strSource.length > 0 ? "," : "") + ret.Data.Nav_Sources[i].Nav_Source.NAME
|
||||
}
|
||||
}
|
||||
if (ret.Data.Nav_Ranges != null && ret.Data.Nav_Ranges.length > 0) {
|
||||
for (let i = 0; i < ret.Data.Nav_Ranges.length; i++) {
|
||||
strRange += (strRange.length > 0 ? "," : "") + ret.Data.Nav_Ranges[i].Nav_Range.NAME
|
||||
}
|
||||
}
|
||||
temps.push({ field: 'PROJECT_ID', value: ret.Data.ID })
|
||||
temps.push({ field: 'Nav_Project.NAME', value: ret.Data.NAME })
|
||||
temps.push({ field: 'Nav_Project.CODE', value: ret.Data.CODE })
|
||||
temps.push({ field: 'Nav_Project.YEAR', value: ret.Data.YEAR })
|
||||
temps.push({ field: 'Nav_Project.Nav_Manger.NAME', value: ret.Data.Nav_Manger.NAME })
|
||||
temps.push({ field: 'Nav_Project.IS_FOREIGN', value: ret.Data.IS_FOREIGN })
|
||||
} else {
|
||||
temps.push({ field: 'PROJECT_ID', value: '' })
|
||||
temps.push({ field: 'Nav_Project.NAME', value: '' })
|
||||
temps.push({ field: 'Nav_Project.CODE', value: '' })
|
||||
temps.push({ field: 'Nav_Project.YEAR', value: '' })
|
||||
temps.push({ field: 'Nav_Project.Nav_Manger.NAME', value: '' })
|
||||
temps.push({ field: 'Nav_Project.IS_FOREIGN', value: '' })
|
||||
}
|
||||
temps.push({ field: 'Nav_Project.Nav_Sources', value: strSource })
|
||||
temps.push({ field: 'Nav_Project.Nav_Ranges', value: strRange })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
});
|
||||
} else {
|
||||
const temps = [];
|
||||
temps.push({ field: 'PROJECT_ID', value: '' })
|
||||
temps.push({ field: 'Nav_Project.NAME', value: '' })
|
||||
temps.push({ field: 'Nav_Project.CODE', value: '' })
|
||||
temps.push({ field: 'Nav_Project.YEAR', value: '' })
|
||||
temps.push({ field: 'Nav_Project.Nav_Manger.NAME', value: '' })
|
||||
temps.push({ field: 'Nav_Project.IS_FOREIGN', value: '' })
|
||||
|
||||
temps.push({ field: 'Nav_Project.Nav_Sources', value: "" })
|
||||
temps.push({ field: 'Nav_Project.Nav_Ranges', value: "" })
|
||||
setFieldValueByBatch(temps);
|
||||
|
||||
}
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1,170 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, guid } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
import config from "../../config.js"
|
||||
import { Button, Row, Col, Form, Input, Select, Upload, Icon, Modal, Spin } from 'antd';
|
||||
import storage from '../../utils/storage'
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 项目经费管理
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.STATUS = params.customParams;
|
||||
params.record.TaskID = params.data.TaskID;
|
||||
},
|
||||
|
||||
onBeforeEdit(params) {
|
||||
if (params.isNew != undefined && !params.isNew && params.stateData != undefined && params.stateData != null && params.stateData.PROJECT_ID != undefined && params.stateData.PROJECT_ID.length > 0) {
|
||||
params.setFieldEditable("Nav_Project.NAME", false)
|
||||
}
|
||||
const { stateData } = params ? params : {};
|
||||
if (stateData.Nav_Details != null && stateData.Nav_Details.length > 0) {
|
||||
//头部赋值
|
||||
var allTOTAL = 0
|
||||
var allUSE = 0
|
||||
var allLEFT = 0
|
||||
if (stateData.Nav_Details != null && stateData.Nav_Details.length > 0) {
|
||||
for (let i = 0; i < stateData.Nav_Details.length; i++) {
|
||||
allTOTAL += stateData.Nav_Details[i].TOTAL
|
||||
allUSE += stateData.Nav_Details[i].USE
|
||||
allLEFT += stateData.Nav_Details[i].LEFT
|
||||
}
|
||||
}
|
||||
// const temps = [];
|
||||
// temps.push({ field: 'ALLTOTAL', value: allTOTAL });
|
||||
// temps.push({ field: 'ALLUSE', value: allUSE });
|
||||
// temps.push({ field: 'ALLLEFT', value: allLEFT })
|
||||
// setFieldValueByBatch(temps);
|
||||
|
||||
// 字表重写
|
||||
let details = [];
|
||||
stateData.Nav_Details.forEach(t => {
|
||||
let detail = {
|
||||
Files: [],
|
||||
Nav_Files: t.Nav_Files,
|
||||
ID: t.ID,
|
||||
MONEY_ID: t.MONEY_ID,
|
||||
NAME: t.NAME,
|
||||
TOTAL: t.TOTAL,
|
||||
USE: t.USE,
|
||||
LEFT: t.LEFT,
|
||||
ROW_NO: t.ROW_NO,
|
||||
ENTITY_ORG_TPYE: t.ENTITY_ORG_TPYE,
|
||||
ORG_ID: t.ORG_ID,
|
||||
CREATE_TIME: t.CREATE_TIME,
|
||||
IS_DELETED: t.IS_DELETED
|
||||
}
|
||||
if (t.Nav_Files) {
|
||||
t.Nav_Files.forEach(x => {
|
||||
//附件信息赋值给数据库对象,多个附件需要遍历附件信息
|
||||
detail.Files.push({
|
||||
uid: x.ID,
|
||||
name: x.name ? x.name : (x.Nav_ImgFile ? x.Nav_ImgFile.FILE_NAME : '未知文件'),
|
||||
status: x.status ? x.status : 'done',
|
||||
response: { Data: { imgFileID: x.IMG_FILE_ID }, file: x },
|
||||
url: x.Nav_ImgFile ? (config.picServerHost + x.Nav_ImgFile.Nav_File.FILE_PATH) : '',
|
||||
})
|
||||
})
|
||||
}
|
||||
details.push(detail);
|
||||
});
|
||||
details = details.map((item, i) => {
|
||||
return item;
|
||||
});
|
||||
stateData.Nav_Details = details;
|
||||
}
|
||||
stateData.ALLTOTAL = allTOTAL
|
||||
stateData.ALLUSE = allUSE
|
||||
stateData.ALLLEFT = allLEFT
|
||||
params['record'] = stateData;
|
||||
},
|
||||
|
||||
// 金额修改 修改同行数据 和头部数据
|
||||
onSubChange: ({ row, setDataState, pageCode, record, colInfo, setFieldValue, dispatch, stateData, props }) => {
|
||||
if (colInfo.FIELD_NAME == "TOTAL" || colInfo.FIELD_NAME == "USE") {
|
||||
var allTotal = 0
|
||||
var allUse = 0
|
||||
var allLeft = 0
|
||||
|
||||
for (let i = 0; i < stateData.Nav_Details.length; i++) {
|
||||
if (stateData.IS_DELETED)
|
||||
continue;
|
||||
if (record.ROW_NO == i + 1) {
|
||||
if (stateData.Nav_Details[i].TOTAL != undefined && stateData.Nav_Details[i].USE != undefined) {
|
||||
stateData.Nav_Details[i].LEFT = stateData.Nav_Details[i].TOTAL - stateData.Nav_Details[i].USE
|
||||
}
|
||||
}
|
||||
//专项经费
|
||||
if (stateData.Nav_Details[i].TOTAL != undefined) {
|
||||
allTotal += stateData.Nav_Details[i].TOTAL
|
||||
}
|
||||
//支出经费
|
||||
if (stateData.Nav_Details[i].USE != undefined) {
|
||||
allUse += stateData.Nav_Details[i].USE
|
||||
}
|
||||
//剩余经费
|
||||
if (stateData.Nav_Details[i].LEFT != undefined) {
|
||||
allLeft += stateData.Nav_Details[i].LEFT
|
||||
}
|
||||
|
||||
//页面属性赋值
|
||||
stateData.ALLTOTAL = allTotal
|
||||
stateData.ALLUSE = allUse
|
||||
stateData.ALLLEFT = allLeft
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
handleRenderRowControl(params) {
|
||||
if (params.colConfig.field === 'Nav_Files') {
|
||||
const Tenant = storage('lacal').getItem('Tenant').val;
|
||||
const that = this;
|
||||
const uploadSopProps = {
|
||||
name: 'file',
|
||||
action: config.serviceHost('api/PF/File/UploadFile'),
|
||||
data: { OrgId: params.login.OrgId },
|
||||
fileList: params.record['Files'],
|
||||
headers: {
|
||||
Tenant: Tenant,
|
||||
},
|
||||
onChange(info) {
|
||||
params.record['Files'] = [...info.fileList];
|
||||
// params.saveRowRecord(params.record);
|
||||
if (info.file.status !== 'uploading') {
|
||||
|
||||
}
|
||||
if (info.file.status === 'done') {
|
||||
let uploadFiles = [...info.fileList]
|
||||
if (uploadFiles) {
|
||||
let navFiles = [];
|
||||
uploadFiles.forEach(t => {
|
||||
if (t.response) {
|
||||
//附件信息赋值给数据库对象,多个附件需要遍历附件信息
|
||||
navFiles.push({
|
||||
IMG_FILE_ID: t.response.Data.imgFileID, //附件表文件名称
|
||||
ID: t.response.file ? t.uid : guid()
|
||||
})
|
||||
}
|
||||
});
|
||||
params.record['Nav_Files'] = navFiles;
|
||||
}
|
||||
message.success(`${info.file.name} 上传成功`);
|
||||
} else if (info.file.status === 'error') {
|
||||
message.error(`${info.file.name} 上传失败!`);
|
||||
}
|
||||
params.saveRowRecord(params.record);
|
||||
},
|
||||
};
|
||||
return <>
|
||||
<Upload {...uploadSopProps}>
|
||||
<Button>
|
||||
<Icon type="upload" /> 上传附件
|
||||
</Button>
|
||||
</Upload>
|
||||
</>
|
||||
}
|
||||
},
|
||||
|
||||
}
|
||||
@ -1,49 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全科技计划
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'TI008', '前端日志')
|
||||
},
|
||||
|
||||
// onBeforeEdit: ({ isNew, setFieldValueByBatch, login }) => {
|
||||
// if (isNew) {
|
||||
// const temps = [];
|
||||
// temps.push({ field: 'DEPARTMENT_ID', value: login.user.DEPARTMENT_ID });
|
||||
// temps.push({ field: 'Nav_Department.NAME', value: login.user.Nav_Department.NAME });
|
||||
// temps.push({ field: 'USER_ID', value: login.user.ID })
|
||||
// temps.push({ field: 'Nav_User.NAME', value: login.user.NAME })
|
||||
// temps.push({ field: 'BEGINTIME', value: (new Date()).Format("yyyy-MM-dd HH:mm:ss") })
|
||||
// temps.push({ field: 'YEAR', value: (new Date()).Format("yyyy") })
|
||||
// setFieldValueByBatch(temps);
|
||||
// }
|
||||
// },
|
||||
|
||||
// onChange: ({ value, colInfo, dispatch, setFieldValueByBatch, record, stateData, data, getFieldValue, setFieldVisible, setFieldValue }) => {
|
||||
// if (colInfo != null && colInfo.FIELD_NAME == "Nav_Department.NAME") {
|
||||
// const temps = [];
|
||||
// temps.push({ field: 'USER_ID', value: null })
|
||||
// temps.push({ field: 'Nav_User.NAME', value: null })
|
||||
// setFieldValueByBatch(temps);
|
||||
// }
|
||||
// },
|
||||
|
||||
|
||||
onSubChange: ({ row, setDataState, pageCode, record, colInfo, setFieldValue, dispatch, stateData, props }) => {
|
||||
// if (colInfo.FIELD_NAME == "INSURE_TIME" || colInfo.FIELD_NAME == "STOP_TIME") {
|
||||
// if (record.ROW_NO == i + 1) {
|
||||
// if (stateData.Nav_UserList[i].INSURE_TIME != undefined && stateData.Nav_UserList[i].STOP_TIME != undefined) {
|
||||
// // 显示整数,不满一月的按一个月算 参保状态正常时,当前月-参保时间;参保状态停缴时,停缴时间-参保时间
|
||||
// stateData.Nav_UserList[i].INSURE_DURATION = stateData.Nav_UserList[i].STOP_TIME - stateData.Nav_UserList[i].INSURE_TIME
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
}
|
||||
}
|
||||
@ -1,16 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 工伤保险理赔信息
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
// params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
onBeforeSaveHandleRecordLog(params, 'TI021', '工伤保险理赔信息前端日志')
|
||||
},
|
||||
|
||||
}
|
||||
@ -1,43 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
// onBeforeSaveHandleRecordLog(params, 'TL004', '前端日志')
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, setFieldValueByBatch }) => {
|
||||
if (isNew) {
|
||||
//如果 尾矿库只有一条 默认选择 日期默认 当前日期
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'STATE', 1, '20');
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/Tailing/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
// stateData.TAILING_ID = ret.Data[0].ID
|
||||
// stateData.Nav_Tailing = ret.Data[0]
|
||||
// stateData.TAILING_NAME = ret.Data[0].NAME
|
||||
|
||||
const temps = [];
|
||||
temps.push({ field: 'TAILING_ID', value: ret.Data[0].ID })
|
||||
temps.push({ field: 'Nav_Tailing', value: ret.Data[0] })
|
||||
temps.push({ field: 'TAILING_NAME', value: ret.Data[0].NAME })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
|
||||
}
|
||||
@ -1,58 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.STATUS = params.customParams;
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, setFieldValueByBatch, setFieldVisibleByBatch }) => {
|
||||
if (isNew) {
|
||||
var arrayList = []
|
||||
arrayList.push({ field: 'RESULT_REASON', visible: false });
|
||||
arrayList.push({ field: 'RESULT_CHECK_REASON', visible: false });
|
||||
arrayList.push({ field: 'RESULT_WATCH_REASON', visible: false });
|
||||
setFieldVisibleByBatch(arrayList);
|
||||
|
||||
//如果 尾矿库只有一条 默认选择 日期默认 当前日期
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'STATE', 1, '20');
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/Tailing/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
// stateData.TAILING_ID = ret.Data[0].ID
|
||||
// stateData.Nav_Tailing = ret.Data[0]
|
||||
// stateData.TAILING_NAME = ret.Data[0].NAME
|
||||
|
||||
const temps = [];
|
||||
temps.push({ field: 'TAILING_ID', value: ret.Data[0].ID })
|
||||
temps.push({ field: 'Nav_Tailing', value: ret.Data[0] })
|
||||
temps.push({ field: 'TAILING_NAME', value: ret.Data[0].NAME })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
onChange: ({ colInfo, value, setFieldVisible, setFieldValue }) => {
|
||||
if (colInfo != null && (colInfo.FIELD_NAME == "RESULT" || colInfo.FIELD_NAME == "RESULT_CHECK" || colInfo.FIELD_NAME == "RESULT_WATCH")) {
|
||||
var fileName = colInfo.FIELD_NAME + "_REASON"
|
||||
if (value == 0) {
|
||||
setFieldVisible(fileName, false)
|
||||
setFieldValue(fileName, '')
|
||||
}
|
||||
else {
|
||||
setFieldVisible(fileName, true)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1,51 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.STATUS = params.customParams;
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, setFieldVisible, setFieldValueByBatch }) => {
|
||||
if (isNew) {
|
||||
setFieldVisible("RESULT_REASON", false)
|
||||
//如果 尾矿库只有一条 默认选择 日期默认 当前日期
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'STATE', 1, '20');
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/Tailing/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
// stateData.TAILING_ID = ret.Data[0].ID
|
||||
// stateData.Nav_Tailing = ret.Data[0]
|
||||
// stateData.TAILING_NAME = ret.Data[0].NAME
|
||||
const temps = [];
|
||||
temps.push({ field: 'TAILING_ID', value: ret.Data[0].ID })
|
||||
temps.push({ field: 'Nav_Tailing', value: ret.Data[0] })
|
||||
temps.push({ field: 'TAILING_NAME', value: ret.Data[0].NAME })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
onChange: ({ colInfo, value, setFieldVisible, setFieldValue }) => {
|
||||
if (colInfo != null && colInfo.FIELD_NAME == "RESULT") {
|
||||
if (value == 0) {
|
||||
setFieldVisible('RESULT_REASON', true)
|
||||
}
|
||||
else {
|
||||
setFieldVisible('RESULT_REASON', false)
|
||||
setFieldValue('RESULT_REASON', '')
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1,51 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.STATUS = params.customParams;
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, setFieldVisible, setFieldValueByBatch }) => {
|
||||
if (isNew) {
|
||||
setFieldVisible("RESULT_REASON", false)
|
||||
//如果 尾矿库只有一条 默认选择 日期默认 当前日期
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'STATE', 1, '20');
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/Tailing/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
// stateData.TAILING_ID = ret.Data[0].ID
|
||||
// stateData.Nav_Tailing = ret.Data[0]
|
||||
// stateData.TAILING_NAME = ret.Data[0].NAME
|
||||
const temps = [];
|
||||
temps.push({ field: 'TAILING_ID', value: ret.Data[0].ID })
|
||||
temps.push({ field: 'Nav_Tailing', value: ret.Data[0] })
|
||||
temps.push({ field: 'TAILING_NAME', value: ret.Data[0].NAME })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
onChange: ({ colInfo, value, setFieldVisible, setFieldValue }) => {
|
||||
if (colInfo != null && colInfo.FIELD_NAME == "RESULT") {
|
||||
if (value == 0) {
|
||||
setFieldVisible('RESULT_REASON', true)
|
||||
}
|
||||
else {
|
||||
setFieldVisible('RESULT_REASON', false)
|
||||
setFieldValue('RESULT_REASON', '')
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1,115 +0,0 @@
|
||||
import React from 'react'
|
||||
import { message, Checkbox, Row, Radio } from "antd/lib/index";
|
||||
// import { Checkbox } from 'antd'
|
||||
import { guid, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.STATUS = params.customParams;
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, setFieldValueByBatch }) => {
|
||||
if (isNew) {
|
||||
//如果 尾矿库只有一条 默认选择 日期默认 当前日期
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'STATE', 1, '20');
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/Tailing/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
const temps = [];
|
||||
if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
// stateData.TAILING_ID = ret.Data[0].ID
|
||||
// stateData.Nav_Tailing = ret.Data[0]
|
||||
// stateData.TAILING_NAME = ret.Data[0].NAME
|
||||
temps.push({ field: 'TAILING_ID', value: ret.Data[0].ID })
|
||||
temps.push({ field: 'Nav_Tailing', value: ret.Data[0] })
|
||||
temps.push({ field: 'TAILING_NAME', value: ret.Data[0].NAME })
|
||||
temps.push({ field: 'BACKDATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
} else {
|
||||
temps.push({ field: 'BACKDATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
}
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
updateInfoB: ({ row, pageCode, record, colInfo, resetFields, stateData, saveHeadRecord, saveRowRecord, getSelectedRecords, setState }) => {
|
||||
let DetailCheck = getSelectedRecords();
|
||||
if (DetailCheck && DetailCheck.length > 1) {
|
||||
var DATESTART = DetailCheck[0].DATESTART
|
||||
for (let i = 1; i < DetailCheck.length; i++) {
|
||||
DetailCheck[i].DATESTART = DATESTART
|
||||
}
|
||||
}
|
||||
},
|
||||
updateInfoE: ({ row, pageCode, record, colInfo, resetFields, stateData, saveHeadRecord, saveRowRecord, getSelectedRecords, setState }) => {
|
||||
let DetailCheck = getSelectedRecords();
|
||||
if (DetailCheck && DetailCheck.length > 1) {
|
||||
var DATEEND = DetailCheck[0].DATEEND
|
||||
for (let i = 1; i < DetailCheck.length; i++) {
|
||||
DetailCheck[i].DATEEND = DATEEND
|
||||
}
|
||||
}
|
||||
},
|
||||
updateInfoU: ({ row, pageCode, record, colInfo, resetFields, stateData, saveHeadRecord, saveRowRecord, getSelectedRecords, setState }) => {
|
||||
let DetailCheck = getSelectedRecords();
|
||||
if (DetailCheck && DetailCheck.length > 1) {
|
||||
let ListCheckUserFirst = DetailCheck[0].Nav_ListDetailUser;
|
||||
//更新行数据
|
||||
for (let i = 1; i < DetailCheck.length; i++) {
|
||||
//组装数据
|
||||
let updateList = [];
|
||||
if (ListCheckUserFirst != undefined && ListCheckUserFirst.length > 0) {
|
||||
for (let j = 0; j < ListCheckUserFirst.length; j++) {
|
||||
if (!ListCheckUserFirst[j].IS_DELETED) {
|
||||
let updateObj = { ...ListCheckUserFirst[j] };
|
||||
updateObj["ID"] = guid()
|
||||
updateList.push(updateObj);
|
||||
}
|
||||
}
|
||||
let iRow = { ...DetailCheck[i] };
|
||||
iRow.Nav_ListDetailUser = updateList;
|
||||
saveRowRecord({ record: iRow, editCode: "T_TL_BACK_DETAIL_USER" })
|
||||
for (var x = 0; x < stateData.Nav_ListDetail.length; x++) {
|
||||
if (iRow.ID == stateData.Nav_ListDetail[x].ID) {
|
||||
stateData.Nav_ListDetail[x].Nav_ListDetailUser = updateList;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
//人员删除
|
||||
let iRow = { ...DetailCheck[i] };
|
||||
for (let j = 0; j < iRow.Nav_ListDetailUser.length; j++) {
|
||||
iRow.Nav_ListDetailUser[j].IS_DELETED = true
|
||||
}
|
||||
saveRowRecord({ record: iRow, editCode: "T_TL_BACK_DETAIL_USER" })
|
||||
}
|
||||
|
||||
// //更新选中人员
|
||||
// let tmp = "";
|
||||
// for (var x = 0; x < stateData.Nav_ListDetail.length; x++) {
|
||||
// let users = stateData.Nav_ListDetail[x].Nav_ListDetailUser
|
||||
// if (users) {
|
||||
// for (let i = 0; i < users.length; i++) {
|
||||
// if (!users[i].IS_DELETED) {
|
||||
// if (tmp.indexOf(users[i].Nav_User.NAME) == -1) {
|
||||
// debugger
|
||||
// tmp += (tmp.length > 0 ? "," : "") + users[i].Nav_User.NAME
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// stateData.CheckUsers = tmp
|
||||
// setState({ data: stateData });
|
||||
}
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1,53 +0,0 @@
|
||||
import React from 'react'
|
||||
import { message, Checkbox, Row, Radio } from "antd/lib/index";
|
||||
// import { Checkbox } from 'antd'
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
if (params.record.BACKTIME != undefined && params.record.BACKTIME.length == 13) {
|
||||
params.record.BACKTIME = params.record.BACKTIME + ":00:00"
|
||||
}
|
||||
|
||||
params.record.TaskID = params.data.TaskID //TaskID传递消息表ID
|
||||
params.record.STATUS = params.customParams;
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, setFieldValueByBatch, setFieldEditable }) => {
|
||||
if (isNew) {
|
||||
//如果 尾矿库只有一条 默认选择 日期默认 当前日期
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'STATE', 1, '20');
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/Tailing/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
// stateData.TAILING_ID = ret.Data[0].ID
|
||||
// stateData.Nav_Tailing = ret.Data[0]
|
||||
// stateData.TAILING_NAME = ret.Data[0].NAME
|
||||
const temps = [];
|
||||
temps.push({ field: 'TAILING_ID', value: ret.Data[0].ID })
|
||||
temps.push({ field: 'Nav_Tailing', value: ret.Data[0] })
|
||||
temps.push({ field: 'TAILING_NAME', value: ret.Data[0].NAME })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
}
|
||||
})
|
||||
} else if (stateData.BACK_DETAIL_ID != undefined && stateData.BACK_DETAIL_ID != null && stateData.BACK_DETAIL_ID.length > 0) {
|
||||
//视为系统触发 不可编辑
|
||||
setFieldEditable("Nav_Tailing.NAME", false)
|
||||
setFieldEditable("BACKTIME", false)
|
||||
setFieldEditable("BACKTIMEEND", false)
|
||||
setFieldEditable("Nav_ListUser", false)
|
||||
setFieldEditable("NAME", false)
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1,40 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.STATUS = params.customParams;
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, setFieldValueByBatch }) => {
|
||||
if (isNew) {
|
||||
//如果 尾矿库只有一条 默认选择 日期默认 当前日期
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'STATE', 1, '20');
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/Tailing/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
// stateData.TAILING_ID = ret.Data[0].ID
|
||||
// stateData.Nav_Tailing = ret.Data[0]
|
||||
// stateData.TAILING_NAME = ret.Data[0].NAME
|
||||
|
||||
const temps = [];
|
||||
temps.push({ field: 'TAILING_ID', value: ret.Data[0].ID })
|
||||
temps.push({ field: 'Nav_Tailing', value: ret.Data[0] })
|
||||
temps.push({ field: 'TAILING_NAME', value: ret.Data[0].NAME })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1,111 +0,0 @@
|
||||
import { message } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 制定任务
|
||||
export default {
|
||||
|
||||
onBeforeEdit: ({ isNew, stateData, setFieldVisible }) => {
|
||||
// 控制控件显示 / 隐藏
|
||||
if (isNew) {
|
||||
//新增
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
} else {
|
||||
//修改
|
||||
switch (stateData.PLANCHECKFREQUENCY) {
|
||||
// case 5:
|
||||
// setFieldVisible("DATA", false);
|
||||
// setFieldVisible("WEEKDATA", false);
|
||||
// setFieldVisible("RUNDATA", true);
|
||||
// break;
|
||||
case 10:
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
break;
|
||||
case 20:
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", true);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
break;
|
||||
case 30:
|
||||
case 40:
|
||||
case 50:
|
||||
setFieldVisible("DATA", true);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
break;
|
||||
case 60:
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", true);
|
||||
break;
|
||||
default:
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
},
|
||||
onChange: ({ value, colInfo, record, stateData, data, getFieldValue, setFieldVisible, setFieldValue }) => {
|
||||
if (colInfo != null && colInfo.FIELD_NAME == "PLANCHECKFREQUENCY") {
|
||||
//单次5 每天10 每周20 每月30 每季40
|
||||
switch (value) {
|
||||
// case 5:
|
||||
// setFieldVisible("DATA", false);
|
||||
// setFieldVisible("WEEKDATA", false);
|
||||
// setFieldVisible("RUNDATA", true);
|
||||
// setFieldValue("WEEKDATA", null);
|
||||
// setFieldValue("DATA", null);
|
||||
// setFieldValue("RUNDATA", null);
|
||||
// break;
|
||||
case 10:
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
setFieldValue("WEEKDATA", null);
|
||||
setFieldValue("DATA", null);
|
||||
setFieldValue("RUNDATA", null);
|
||||
break;
|
||||
case 20:
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", true);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
setFieldValue("DATA", null);
|
||||
setFieldValue("RUNDATA", null);
|
||||
break;
|
||||
case 30:
|
||||
case 40:
|
||||
case 50:
|
||||
setFieldVisible("DATA", true);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
setFieldValue("WEEKDATA", null);
|
||||
setFieldValue("RUNDATA", null);
|
||||
break;
|
||||
case 60:
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", true);
|
||||
setFieldValue("WEEKDATA", null);
|
||||
setFieldValue("DATA", null);
|
||||
setFieldValue("RUNDATA", null);
|
||||
break;
|
||||
|
||||
default:
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
setFieldValue("WEEKDATA", null);
|
||||
setFieldValue("DATA", null);
|
||||
setFieldValue("RUNDATA", null);
|
||||
break;
|
||||
}
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1,41 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.STATUS = params.customParams;
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, setFieldValueByBatch }) => {
|
||||
if (isNew) {
|
||||
//如果 尾矿库只有一条 默认选择 日期默认 当前日期
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'STATE', 1, '20');
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/Tailing/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
// stateData.TAILING_ID = ret.Data[0].ID
|
||||
// stateData.Nav_Tailing = ret.Data[0]
|
||||
// stateData.TAILING_NAME = ret.Data[0].NAME
|
||||
|
||||
const temps = [];
|
||||
temps.push({ field: 'TAILING_ID', value: ret.Data[0].ID })
|
||||
temps.push({ field: 'Nav_Tailing', value: ret.Data[0] })
|
||||
temps.push({ field: 'TAILING_NAME', value: ret.Data[0].NAME })
|
||||
// temps.push({ field: 'DATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1,43 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.STATUS = params.customParams;
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, setFieldValueByBatch }) => {
|
||||
if (isNew) {
|
||||
//如果 尾矿库只有一条 默认选择 日期默认 当前日期
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'STATE', 1, '20');
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/Tailing/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
// if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
// stateData.TAILING_ID = ret.Data[0].ID
|
||||
// stateData.Nav_Tailing = ret.Data[0]
|
||||
// stateData.TAILING_NAME = ret.Data[0].NAME
|
||||
// }
|
||||
|
||||
if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
const temps = [];
|
||||
temps.push({ field: 'TAILING_ID', value: ret.Data[0].ID })
|
||||
temps.push({ field: 'Nav_Tailing', value: ret.Data[0] })
|
||||
temps.push({ field: 'TAILING_NAME', value: ret.Data[0].NAME })
|
||||
// temps.push({ field: 'DATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1,48 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.STATUS = params.customParams;
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, setFieldValueByBatch }) => {
|
||||
if (isNew) {
|
||||
// if (stateData.DATE == undefined) {
|
||||
// stateData.DATE = new Date()
|
||||
// }
|
||||
//如果 尾矿库只有一条 默认选择 日期默认 当前日期
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'STATE', 1, '20');
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/Tailing/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
// if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
// stateData.TAILING_ID = ret.Data[0].ID
|
||||
// stateData.Nav_Tailing = ret.Data[0]
|
||||
// stateData.TAILING_NAME = ret.Data[0].NAME
|
||||
// }
|
||||
|
||||
const temps = [];
|
||||
if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
temps.push({ field: 'TAILING_ID', value: ret.Data[0].ID })
|
||||
temps.push({ field: 'Nav_Tailing', value: ret.Data[0] })
|
||||
temps.push({ field: 'TAILING_NAME', value: ret.Data[0].NAME })
|
||||
temps.push({ field: 'DATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
} else {
|
||||
temps.push({ field: 'DATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
}
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1,53 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.STATUS = params.customParams;
|
||||
},
|
||||
|
||||
onBeforeEdit: ({ isNew, setFieldValueByBatch, setFieldEditable, login }) => {
|
||||
if (isNew) {
|
||||
const temps = [];
|
||||
temps.push({ field: 'YEAR', value: (new Date()).Format("yyyy") })
|
||||
temps.push({ field: 'DEPARTMENT_ID', value: login.user.Nav_Department.ID })
|
||||
temps.push({ field: 'Nav_Department.NAME', value: login.user.Nav_Department.NAME })
|
||||
setFieldValueByBatch(temps);
|
||||
|
||||
setFieldEditable("YEAR", false);
|
||||
setFieldEditable("Nav_Department.NAME", false);
|
||||
}
|
||||
},
|
||||
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, setFieldValueByBatch }) => {
|
||||
if (isNew) {
|
||||
//如果 尾矿库只有一条 默认选择 日期默认 当前日期
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'STATE', 1, '20');
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/Tailing/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
const temps = [];
|
||||
if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
temps.push({ field: 'TAILING_ID', value: ret.Data[0].ID })
|
||||
temps.push({ field: 'Nav_Tailing', value: ret.Data[0] })
|
||||
temps.push({ field: 'TAILING_NAME', value: ret.Data[0].NAME })
|
||||
temps.push({ field: 'DATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
} else {
|
||||
temps.push({ field: 'DATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
}
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1,111 +0,0 @@
|
||||
import { message } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 制定任务
|
||||
export default {
|
||||
|
||||
onBeforeEdit: ({ isNew, stateData, setFieldVisible }) => {
|
||||
// 控制控件显示 / 隐藏
|
||||
if (isNew) {
|
||||
//新增
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
} else {
|
||||
//修改
|
||||
switch (stateData.PLANCHECKFREQUENCY) {
|
||||
// case 5:
|
||||
// setFieldVisible("DATA", false);
|
||||
// setFieldVisible("WEEKDATA", false);
|
||||
// setFieldVisible("RUNDATA", true);
|
||||
// break;
|
||||
case 10:
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
break;
|
||||
case 20:
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", true);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
break;
|
||||
case 30:
|
||||
case 40:
|
||||
case 50:
|
||||
setFieldVisible("DATA", true);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
break;
|
||||
case 60:
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", true);
|
||||
break;
|
||||
default:
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
},
|
||||
onChange: ({ value, colInfo, record, stateData, data, getFieldValue, setFieldVisible, setFieldValue }) => {
|
||||
if (colInfo != null && colInfo.FIELD_NAME == "PLANCHECKFREQUENCY") {
|
||||
//单次5 每天10 每周20 每月30 每季40
|
||||
switch (value) {
|
||||
// case 5:
|
||||
// setFieldVisible("DATA", false);
|
||||
// setFieldVisible("WEEKDATA", false);
|
||||
// setFieldVisible("RUNDATA", true);
|
||||
// setFieldValue("WEEKDATA", null);
|
||||
// setFieldValue("DATA", null);
|
||||
// setFieldValue("RUNDATA", null);
|
||||
// break;
|
||||
case 10:
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
setFieldValue("WEEKDATA", null);
|
||||
setFieldValue("DATA", null);
|
||||
setFieldValue("RUNDATA", null);
|
||||
break;
|
||||
case 20:
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", true);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
setFieldValue("DATA", null);
|
||||
setFieldValue("RUNDATA", null);
|
||||
break;
|
||||
case 30:
|
||||
case 40:
|
||||
case 50:
|
||||
setFieldVisible("DATA", true);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
setFieldValue("WEEKDATA", null);
|
||||
setFieldValue("RUNDATA", null);
|
||||
break;
|
||||
case 60:
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", true);
|
||||
setFieldValue("WEEKDATA", null);
|
||||
setFieldValue("DATA", null);
|
||||
setFieldValue("RUNDATA", null);
|
||||
break;
|
||||
|
||||
default:
|
||||
setFieldVisible("DATA", false);
|
||||
setFieldVisible("WEEKDATA", false);
|
||||
setFieldVisible("RUNDATA", false);
|
||||
setFieldValue("WEEKDATA", null);
|
||||
setFieldValue("DATA", null);
|
||||
setFieldValue("RUNDATA", null);
|
||||
break;
|
||||
}
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1,113 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format, guid } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
|
||||
if (params.record.DATE && params.record.DATE.length == 10 && params.record.Nav_ListDetail && params.record.Nav_ListDetail.length > 0) {
|
||||
params.record.Nav_ListDetail.forEach(e => {
|
||||
if (e.DATE && e.DATE.length == 8) {
|
||||
e.DATE = params.record.DATE + ' ' + e.DATE
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
params.record.STATUS = params.customParams
|
||||
params.record.TaskID = params.data.TaskID
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, setFieldValueByBatch }) => {
|
||||
if (isNew) {
|
||||
// if (stateData.DATE == undefined) {
|
||||
// stateData.DATE = new Date()
|
||||
// }
|
||||
//如果 尾矿库只有一条 默认选择 日期默认 当前日期
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'STATE', 1, '20');
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/Tailing/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
// if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
// stateData.TAILING_ID = ret.Data[0].ID
|
||||
// stateData.Nav_Tailing = ret.Data[0]
|
||||
// stateData.TAILING_NAME = ret.Data[0].NAME
|
||||
// }
|
||||
|
||||
const temps = [];
|
||||
if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
temps.push({ field: 'TAILING_ID', value: ret.Data[0].ID })
|
||||
temps.push({ field: 'Nav_Tailing', value: ret.Data[0] })
|
||||
temps.push({ field: 'TAILING_NAME', value: ret.Data[0].NAME })
|
||||
temps.push({ field: 'DATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
} else {
|
||||
temps.push({ field: 'DATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
}
|
||||
setFieldValueByBatch(temps);
|
||||
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
updateCheckUser: ({ row, pageCode, record, colInfo, resetFields, stateData, saveHeadRecord, saveRowRecord, getSelectedRecords, setState }) => {
|
||||
let DetailCheck = getSelectedRecords();
|
||||
if (DetailCheck && DetailCheck.length > 1) {
|
||||
let ListCheckUserFirst = DetailCheck[0].Nav_ListUser;
|
||||
//更新行数据
|
||||
for (let i = 1; i < DetailCheck.length; i++) {
|
||||
//组装数据
|
||||
let updateList = [];
|
||||
if (ListCheckUserFirst != undefined && ListCheckUserFirst.length > 0) {
|
||||
for (let j = 0; j < ListCheckUserFirst.length; j++) {
|
||||
if (!ListCheckUserFirst[j].IS_DELETED) {
|
||||
let updateObj = { ...ListCheckUserFirst[j] };
|
||||
updateObj["ID"] = guid()
|
||||
updateObj["LINE_DAYLY_ID"] = DetailCheck[i].ID
|
||||
updateList.push(updateObj);
|
||||
}
|
||||
}
|
||||
let iRow = { ...DetailCheck[i] };
|
||||
iRow.Nav_ListUser = updateList;
|
||||
saveRowRecord({ record: iRow, editCode: "T_TL_WATCH_DAYLY_DETAIL" })
|
||||
|
||||
for (var x = 0; x < stateData.Nav_ListDetail.length; x++) {
|
||||
if (iRow.ID == stateData.Nav_ListDetail[x].ID) {
|
||||
stateData.Nav_ListDetail[x].Nav_ListUser = updateList;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
//人员删除
|
||||
let iRow = { ...DetailCheck[i] };
|
||||
for (let j = 0; j < iRow.Nav_ListUser.length; j++) {
|
||||
iRow.Nav_ListUser[j].IS_DELETED = true
|
||||
}
|
||||
saveRowRecord({ record: iRow, editCode: "T_TL_WATCH_DAYLY_DETAIL" })
|
||||
}
|
||||
|
||||
//更新选中人员
|
||||
let tmp = "";
|
||||
for (var x = 0; x < stateData.Nav_ListDetail.length; x++) {
|
||||
let users = stateData.Nav_ListDetail[x].Nav_ListUser
|
||||
if (users) {
|
||||
for (let i = 0; i < users.length; i++) {
|
||||
if (!users[i].IS_DELETED) {
|
||||
if (tmp.indexOf(users[i].Nav_User.NAME) == -1) {
|
||||
tmp += (tmp.length > 0 ? "," : "") + users[i].Nav_User.NAME
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
stateData.CheckUsers = tmp
|
||||
setState({ data: stateData });
|
||||
}
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1,111 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format, guid } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
if (params.record.DATE && params.record.DATE.length == 10 && params.record.Nav_ListDetail && params.record.Nav_ListDetail.length > 0) {
|
||||
params.record.Nav_ListDetail.forEach(e => {
|
||||
if (e.DATE && e.DATE.length == 8) {
|
||||
e.DATE = params.record.DATE + ' ' + e.DATE
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
params.record.STATUS = params.customParams
|
||||
params.record.TaskID = params.data.TaskID
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, setFieldValueByBatch }) => {
|
||||
if (isNew) {
|
||||
// if (stateData.DATE == undefined) {
|
||||
// stateData.DATE = new Date()
|
||||
// }
|
||||
//如果 尾矿库只有一条 默认选择 日期默认 当前日期
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'STATE', 1, '20');
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/Tailing/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
// if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
// stateData.TAILING_ID = ret.Data[0].ID
|
||||
// stateData.Nav_Tailing = ret.Data[0]
|
||||
// stateData.TAILING_NAME = ret.Data[0].NAME
|
||||
// }
|
||||
|
||||
const temps = [];
|
||||
if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
temps.push({ field: 'TAILING_ID', value: ret.Data[0].ID })
|
||||
temps.push({ field: 'Nav_Tailing', value: ret.Data[0] })
|
||||
temps.push({ field: 'TAILING_NAME', value: ret.Data[0].NAME })
|
||||
temps.push({ field: 'DATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
} else {
|
||||
temps.push({ field: 'DATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
}
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
updateCheckUser: ({ row, pageCode, record, colInfo, resetFields, stateData, saveHeadRecord, saveRowRecord, getSelectedRecords, setState }) => {
|
||||
let DetailCheck = getSelectedRecords();
|
||||
if (DetailCheck && DetailCheck.length > 1) {
|
||||
let ListCheckUserFirst = DetailCheck[0].Nav_ListUser;
|
||||
//更新行数据
|
||||
for (let i = 1; i < DetailCheck.length; i++) {
|
||||
//组装数据
|
||||
let updateList = [];
|
||||
if (ListCheckUserFirst != undefined && ListCheckUserFirst.length > 0) {
|
||||
for (let j = 0; j < ListCheckUserFirst.length; j++) {
|
||||
if (!ListCheckUserFirst[j].IS_DELETED) {
|
||||
let updateObj = { ...ListCheckUserFirst[j] };
|
||||
updateObj["ID"] = guid()
|
||||
updateObj["LINE_PERCENT_ID"] = DetailCheck[i].ID
|
||||
updateList.push(updateObj);
|
||||
}
|
||||
}
|
||||
let iRow = { ...DetailCheck[i] };
|
||||
iRow.Nav_ListUser = updateList;
|
||||
saveRowRecord({ record: iRow, editCode: "T_TL_WATCH_PERCENT_DETAIL" })
|
||||
|
||||
for (var x = 0; x < stateData.Nav_ListDetail.length; x++) {
|
||||
if (iRow.ID == stateData.Nav_ListDetail[x].ID) {
|
||||
stateData.Nav_ListDetail[x].Nav_ListUser = updateList;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
//人员删除
|
||||
let iRow = { ...DetailCheck[i] };
|
||||
for (let j = 0; j < iRow.Nav_ListUser.length; j++) {
|
||||
iRow.Nav_ListUser[j].IS_DELETED = true
|
||||
}
|
||||
saveRowRecord({ record: iRow, editCode: "T_TL_WATCH_PERCENT_DETAIL" })
|
||||
}
|
||||
|
||||
//更新选中人员
|
||||
let tmp = "";
|
||||
for (var x = 0; x < stateData.Nav_ListDetail.length; x++) {
|
||||
let users = stateData.Nav_ListDetail[x].Nav_ListUser
|
||||
if (users) {
|
||||
for (let i = 0; i < users.length; i++) {
|
||||
if (!users[i].IS_DELETED) {
|
||||
if (tmp.indexOf(users[i].Nav_User.NAME) == -1) {
|
||||
tmp += (tmp.length > 0 ? "," : "") + users[i].Nav_User.NAME
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
stateData.CheckUsers = tmp
|
||||
setState({ data: stateData });
|
||||
}
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1,235 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format, guid } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
|
||||
if (params.record.DATE && params.record.DATE.length == 10 && params.record.Nav_ListDetail && params.record.Nav_ListDetail.length > 0) {
|
||||
params.record.Nav_ListDetail.forEach(e => {
|
||||
if (e.DATE && e.DATE.length == 8) {
|
||||
e.DATE = params.record.DATE + ' ' + e.DATE
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
params.record.STATUS = params.customParams
|
||||
params.record.TaskID = params.data.TaskID
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, setFieldValueByBatch }) => {
|
||||
if (isNew) {
|
||||
// if (stateData.DATE == undefined) {
|
||||
// stateData.DATE = new Date()
|
||||
// }
|
||||
//如果 尾矿库只有一条 默认选择 日期默认 当前日期
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'STATE', 1, '20');
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/Tailing/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
// if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
// stateData.TAILING_ID = ret.Data[0].ID
|
||||
// stateData.Nav_Tailing = ret.Data[0]
|
||||
// stateData.TAILING_NAME = ret.Data[0].NAME
|
||||
// }
|
||||
|
||||
const temps = [];
|
||||
if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
temps.push({ field: 'TAILING_ID', value: ret.Data[0].ID })
|
||||
temps.push({ field: 'Nav_Tailing', value: ret.Data[0] })
|
||||
temps.push({ field: 'TAILING_NAME', value: ret.Data[0].NAME })
|
||||
temps.push({ field: 'DATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
} else {
|
||||
temps.push({ field: 'DATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
}
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
//新增
|
||||
AddAny: ({ row, pageCode, record, colInfo, resetFields, stateData, dispatch, saveHeadRecord, saveRowRecord, getSelectedRecords, setFieldValueByBatch }) => {
|
||||
if (stateData.TAILING_ID == undefined || stateData.TAILING_ID == '00000000-0000-0000-0000-000000000000') {
|
||||
alert('请选择尾矿库后再新增!')
|
||||
} else {
|
||||
//获取 尾矿库 有效的 【位移观测配置】
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'ENABLE_STATUS', 1, 0);
|
||||
extendRule(json, 'TAILING_ID', 1, stateData.TAILING_ID);
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/WatchMovePoint/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
let temps = [];
|
||||
let detail = stateData.Nav_ListDetail
|
||||
if (ret && ret.IsSuccessful && ret.Data) {
|
||||
temps = ret.Data.map((item, i) => {
|
||||
let itemAdd = {}
|
||||
itemAdd['ROW_NO'] = i + 1
|
||||
itemAdd['ID'] = new guid()
|
||||
itemAdd['MOVE_ID'] = stateData.ID
|
||||
itemAdd['TAILING_ID'] = stateData.TAILING_ID
|
||||
itemAdd['WATCH_MOVE_POINT_ID'] = item.ID
|
||||
itemAdd['Nav_WatchMovePoint'] = item
|
||||
return itemAdd;
|
||||
});
|
||||
}
|
||||
if (stateData.Nav_ListDetail == undefined) {
|
||||
stateData.Nav_ListDetail = temps
|
||||
} else {
|
||||
detail = detail.concat(temps)
|
||||
stateData.Nav_ListDetail = detail
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
},
|
||||
updateCheckUser: ({ row, pageCode, record, colInfo, resetFields, stateData, saveHeadRecord, saveRowRecord, getSelectedRecords, setState }) => {
|
||||
let DetailCheck = getSelectedRecords();
|
||||
if (DetailCheck && DetailCheck.length > 1) {
|
||||
let ListCheckUserFirst = DetailCheck[0].Nav_ListUser;
|
||||
//更新行数据
|
||||
for (let i = 1; i < DetailCheck.length; i++) {
|
||||
//组装数据
|
||||
let updateList = [];
|
||||
if (ListCheckUserFirst != undefined && ListCheckUserFirst.length > 0) {
|
||||
for (let j = 0; j < ListCheckUserFirst.length; j++) {
|
||||
if (!ListCheckUserFirst[j].IS_DELETED) {
|
||||
let updateObj = { ...ListCheckUserFirst[j] };
|
||||
updateObj["ID"] = guid()
|
||||
updateObj["LINE_MOVE_ID"] = DetailCheck[i].ID
|
||||
updateList.push(updateObj);
|
||||
}
|
||||
}
|
||||
let iRow = { ...DetailCheck[i] };
|
||||
iRow.Nav_ListUser = updateList;
|
||||
saveRowRecord({ record: iRow, editCode: "T_TL_WATCH_MOVE_DETAIL" })
|
||||
|
||||
for (var x = 0; x < stateData.Nav_ListDetail.length; x++) {
|
||||
if (iRow.ID == stateData.Nav_ListDetail[x].ID) {
|
||||
stateData.Nav_ListDetail[x].Nav_ListUser = updateList;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
//人员删除
|
||||
let iRow = { ...DetailCheck[i] };
|
||||
for (let j = 0; j < iRow.Nav_ListUser.length; j++) {
|
||||
iRow.Nav_ListUser[j].IS_DELETED = true
|
||||
}
|
||||
saveRowRecord({ record: iRow, editCode: "T_TL_WATCH_MOVE_DETAIL" })
|
||||
}
|
||||
|
||||
//更新选中人员
|
||||
let tmp = "";
|
||||
for (var x = 0; x < stateData.Nav_ListDetail.length; x++) {
|
||||
let users = stateData.Nav_ListDetail[x].Nav_ListUser
|
||||
if (users) {
|
||||
for (let i = 0; i < users.length; i++) {
|
||||
if (!users[i].IS_DELETED) {
|
||||
if (tmp.indexOf(users[i].Nav_User.NAME) == -1) {
|
||||
tmp += (tmp.length > 0 ? "," : "") + users[i].Nav_User.NAME
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
stateData.CheckUsers = tmp
|
||||
setState({ data: stateData });
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
onSubChange: ({ record, colInfo, stateData, row, setDataState, pageCode, dispatch, props }) => {
|
||||
if (colInfo.FIELD_NAME == 'LOOKPOINT') {
|
||||
if (record != null && record.Nav_WatchMovePoint != null && record.LOOKPOINT != null && record.LOOKPOINT?.indexOf('/') > -1 && record?.Nav_WatchMovePoint?.POINT_BASE?.length > 0) {
|
||||
var listPOINT_BASE = record.Nav_WatchMovePoint.POINT_BASE.split('/')
|
||||
var listLOOKPOINT = record.LOOKPOINT.split('/')
|
||||
if (listPOINT_BASE.length == listLOOKPOINT.length) {
|
||||
if (listPOINT_BASE[listPOINT_BASE.length - 1].length > 0) {
|
||||
var recordCHANGELOOKPOINT = ''
|
||||
var perDet = ''
|
||||
var isNumber = true
|
||||
for (let i = 0; i < listLOOKPOINT.length; i++) {
|
||||
perDet = listLOOKPOINT[i] - listPOINT_BASE[i]
|
||||
if (isNumber && isNaN(perDet)) {
|
||||
isNumber = false
|
||||
}
|
||||
|
||||
if (isNumber && perDet != undefined && String(perDet).indexOf('.') > -1) {
|
||||
perDet = perDet.toFixed(2)
|
||||
}
|
||||
|
||||
if (isNumber)
|
||||
recordCHANGELOOKPOINT += (recordCHANGELOOKPOINT.length > 0 ? '/' : '') + perDet
|
||||
}
|
||||
if (isNumber)
|
||||
stateData.Nav_ListDetail[record.ROW_NO - 1].CHANGELOOKPOINT = recordCHANGELOOKPOINT
|
||||
else {
|
||||
stateData.Nav_ListDetail[record.ROW_NO - 1].LOOKPOINT = ''
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// //如果修改原有库 直接填写对应ID
|
||||
// // debugger
|
||||
// if ((colInfo.FIELD_NAME != "ROW_NO") && (record.ISMAINCHANGE == undefined || record.ISMAINCHANGE == null || !record.ISMAINCHANGE)) {
|
||||
// var MainId = record.CHECK_MAIN_ID
|
||||
// if (MainId != null && MainId != undefined && MainId.length > 0) {
|
||||
// stateData.Nav_ListSafeCheckDetail[record.ROW_NO - 1].ISMAINCHANGE = true
|
||||
// }
|
||||
// }
|
||||
|
||||
// if (colInfo.FIELD_NAME == "Nav_ListCheckDetailUser") {
|
||||
|
||||
// //更新选中人员
|
||||
// let tmp = "";
|
||||
// for (var x = 0; x < stateData.Nav_ListSafeCheckDetail.length; x++) {
|
||||
// let users = stateData.Nav_ListSafeCheckDetail[x].Nav_ListCheckDetailUser
|
||||
// if (users) {
|
||||
// for (let i = 0; i < users.length; i++) {
|
||||
// if (!users[i].IS_DELETED) {
|
||||
// if (tmp.indexOf(users[i].Nav_User.NAME) == -1) {
|
||||
// tmp += (tmp.length > 0 ? "," : "") + users[i].Nav_User.NAME
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// stateData.CheckUsers = tmp
|
||||
// setDataState({ ...stateData });
|
||||
|
||||
// } else if (colInfo.FIELD_NAME == "QUESTION_LEVEL") {
|
||||
// if (record.QUESTION_LEVEL == "10") {
|
||||
// stateData.Nav_ListSafeCheckDetail[record.ROW_NO - 1].SERIOUS_RISK = 1
|
||||
// } else {
|
||||
// stateData.Nav_ListSafeCheckDetail[record.ROW_NO - 1].SERIOUS_RISK = 0
|
||||
// }
|
||||
// }
|
||||
|
||||
// CheckUsers
|
||||
// setDataState("CheckUsers", "jianc")
|
||||
// if (colInfo.FIELD_NAME == "Nav_CheckType.NAME") {
|
||||
// //只要檢查類型修改 清空 項目分類 檢查層級
|
||||
// stateData.Nav_ListContentCheckTypes[0].Nav_CheckProjectCategory = []
|
||||
// stateData.Nav_ListContentCheckTypes[0].Nav_ListContentCheckTypeLevels = []
|
||||
// // if (record.Nav_CheckType.Name) {
|
||||
// // } else {
|
||||
// // //清空項目分類 檢查層級
|
||||
// // }
|
||||
// }
|
||||
},
|
||||
}
|
||||
@ -1,153 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format, guid } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
|
||||
if (params.record.DATE && params.record.DATE.length == 10 && params.record.Nav_ListDetail && params.record.Nav_ListDetail.length > 0) {
|
||||
params.record.Nav_ListDetail.forEach(e => {
|
||||
if (e.DATE && e.DATE.length == 8) {
|
||||
e.DATE = params.record.DATE + ' ' + e.DATE
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
params.record.STATUS = params.customParams
|
||||
params.record.TaskID = params.data.TaskID
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, setFieldValueByBatch }) => {
|
||||
if (isNew) {
|
||||
// if (stateData.DATE == undefined) {
|
||||
// stateData.DATE = new Date()
|
||||
// }
|
||||
//如果 尾矿库只有一条 默认选择 日期默认 当前日期
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'STATE', 1, '20');
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/Tailing/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
// if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
// stateData.TAILING_ID = ret.Data[0].ID
|
||||
// stateData.Nav_Tailing = ret.Data[0]
|
||||
// stateData.TAILING_NAME = ret.Data[0].NAME
|
||||
// }
|
||||
|
||||
const temps = [];
|
||||
if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
temps.push({ field: 'TAILING_ID', value: ret.Data[0].ID })
|
||||
temps.push({ field: 'Nav_Tailing', value: ret.Data[0] })
|
||||
temps.push({ field: 'TAILING_NAME', value: ret.Data[0].NAME })
|
||||
temps.push({ field: 'DATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
} else {
|
||||
temps.push({ field: 'DATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
}
|
||||
setFieldValueByBatch(temps);
|
||||
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
//新增
|
||||
AddAny: ({ row, pageCode, record, colInfo, resetFields, stateData, dispatch, saveHeadRecord, saveRowRecord, getSelectedRecords, setFieldValueByBatch }) => {
|
||||
if (stateData.TAILING_ID == undefined || stateData.TAILING_ID == '00000000-0000-0000-0000-000000000000') {
|
||||
alert('请选择尾矿库后再新增!')
|
||||
} else {
|
||||
//获取 尾矿库 有效的 【位移观测配置】
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'ENABLE_STATUS', 1, 0);
|
||||
extendRule(json, 'TAILING_ID', 1, stateData.TAILING_ID);
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/WatchLinePoint/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
let temps = [];
|
||||
let detail = stateData.Nav_ListDetail
|
||||
if (ret && ret.IsSuccessful && ret.Data) {
|
||||
temps = ret.Data.map((item, i) => {
|
||||
let itemAdd = {}
|
||||
itemAdd['ROW_NO'] = i + 1
|
||||
itemAdd['ID'] = new guid()
|
||||
itemAdd['LINE_ID'] = stateData.ID
|
||||
itemAdd['TAILING_ID'] = stateData.TAILING_ID
|
||||
itemAdd['WATCH_LINE_POINT_ID'] = item.ID
|
||||
itemAdd['Nav_WatchLinePoint'] = item
|
||||
return itemAdd;
|
||||
});
|
||||
}
|
||||
if (stateData.Nav_ListDetail == undefined) {
|
||||
stateData.Nav_ListDetail = temps
|
||||
} else {
|
||||
detail = detail.concat(temps)
|
||||
stateData.Nav_ListDetail = detail
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
},
|
||||
updateCheckUser: ({ row, pageCode, record, colInfo, resetFields, stateData, saveHeadRecord, saveRowRecord, getSelectedRecords, setState }) => {
|
||||
let DetailCheck = getSelectedRecords();
|
||||
if (DetailCheck && DetailCheck.length > 1) {
|
||||
let ListCheckUserFirst = DetailCheck[0].Nav_ListUser;
|
||||
//更新行数据
|
||||
for (let i = 1; i < DetailCheck.length; i++) {
|
||||
//组装数据
|
||||
let updateList = [];
|
||||
if (ListCheckUserFirst != undefined && ListCheckUserFirst.length > 0) {
|
||||
for (let j = 0; j < ListCheckUserFirst.length; j++) {
|
||||
if (!ListCheckUserFirst[j].IS_DELETED) {
|
||||
let updateObj = { ...ListCheckUserFirst[j] };
|
||||
updateObj["ID"] = guid()
|
||||
updateObj["LINE_DETAIL_ID"] = DetailCheck[i].ID
|
||||
updateList.push(updateObj);
|
||||
}
|
||||
}
|
||||
let iRow = { ...DetailCheck[i] };
|
||||
iRow.Nav_ListUser = updateList;
|
||||
saveRowRecord({ record: iRow, editCode: "T_TL_WATCH_LINE_DETAIL" })
|
||||
|
||||
for (var x = 0; x < stateData.Nav_ListDetail.length; x++) {
|
||||
if (iRow.ID == stateData.Nav_ListDetail[x].ID) {
|
||||
stateData.Nav_ListDetail[x].Nav_ListUser = updateList;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
//人员删除
|
||||
let iRow = { ...DetailCheck[i] };
|
||||
for (let j = 0; j < iRow.Nav_ListUser.length; j++) {
|
||||
iRow.Nav_ListUser[j].IS_DELETED = true
|
||||
}
|
||||
saveRowRecord({ record: iRow, editCode: "T_TL_WATCH_LINE_DETAIL" })
|
||||
}
|
||||
|
||||
//更新选中人员
|
||||
let tmp = "";
|
||||
for (var x = 0; x < stateData.Nav_ListDetail.length; x++) {
|
||||
let users = stateData.Nav_ListDetail[x].Nav_ListUser
|
||||
if (users) {
|
||||
for (let i = 0; i < users.length; i++) {
|
||||
if (!users[i].IS_DELETED) {
|
||||
if (tmp.indexOf(users[i].Nav_User.NAME) == -1) {
|
||||
tmp += (tmp.length > 0 ? "," : "") + users[i].Nav_User.NAME
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
stateData.CheckUsers = tmp
|
||||
setState({ data: stateData });
|
||||
}
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1,48 +0,0 @@
|
||||
import { message, Checkbox, Radio } from "antd/lib/index";
|
||||
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, empty, onBeforeSaveHandleRecordLog, Format } from "../../utils/common";
|
||||
import { connect } from 'dva';
|
||||
import moment from 'moment';
|
||||
/**
|
||||
* @return {string}
|
||||
*/
|
||||
// 编辑 安全生产费用使用记录
|
||||
export default {
|
||||
onBeforeSaveHandleRecord(params) {
|
||||
params.record.STATUS = params.customParams;
|
||||
},
|
||||
onBeforeEdit: ({ isNew, stateData, dispatch, setFieldValueByBatch }) => {
|
||||
if (isNew) {
|
||||
// if (stateData.DATE == undefined) {
|
||||
// stateData.DATE = new Date()
|
||||
// }
|
||||
//如果 尾矿库只有一条 默认选择 日期默认 当前日期
|
||||
let json = initFilter(stateData.ORG_ID);
|
||||
extendRule(json, 'STATE', 1, '20');
|
||||
json.Sort = 'CREATE_TIME'
|
||||
dispatch({
|
||||
type: 'app/getDataByPost',
|
||||
url: 'TL/Tailing/OrderPaged',
|
||||
payload: json,
|
||||
onlyData: false,
|
||||
onComplete: (ret) => {
|
||||
// if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
// stateData.TAILING_ID = ret.Data[0].ID
|
||||
// stateData.Nav_Tailing = ret.Data[0]
|
||||
// stateData.TAILING_NAME = ret.Data[0].NAME
|
||||
// }
|
||||
|
||||
const temps = [];
|
||||
if (ret.IsSuccessful && ret.Data.length == 1) {
|
||||
temps.push({ field: 'TAILING_ID', value: ret.Data[0].ID })
|
||||
temps.push({ field: 'Nav_Tailing', value: ret.Data[0] })
|
||||
temps.push({ field: 'TAILING_NAME', value: ret.Data[0].NAME })
|
||||
// temps.push({ field: 'DATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
// } else {
|
||||
// temps.push({ field: 'DATE', value: (new Date()).Format("yyyy-MM-dd") })
|
||||
}
|
||||
setFieldValueByBatch(temps);
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
}
|
||||
@ -1241,95 +1241,6 @@ const OG020Edit = Loadable({
|
||||
loader: () => import('../components/CustomPages/OG/OG020Edit'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TI008ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TI/TI008ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TI008ShowPrints = Loadable({
|
||||
loader: () => import('../components/CustomPages/TI/TI008ShowPrints'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TI010ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TI/TI010ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TI012ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TI/TI012ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TI014ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TI/TI014ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TI016ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TI/TI016ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TI018ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TI/TI018ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TI021ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TI/TI021ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH003ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH003ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH005ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH005ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH006ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH006ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH010ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH010ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH012ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH012ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH017Import = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH017Import'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH024ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH024ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH028ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH028ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH034ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH034ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const AE006ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/AE/AE006ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const AE008ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/AE/AE008ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const AE010ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/AE/AE010ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const AE019ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/AE/AE019ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const AE018ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/AE/AE018ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
|
||||
const SC046ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/SC/SC046ShowPrint'),
|
||||
loading: () => <div />
|
||||
@ -1539,72 +1450,6 @@ const FO025ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/FO/FO025ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL037ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL037ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL039ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL039ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL041ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL041ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL043ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL043ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL044ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL044ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL046ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL046ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
|
||||
|
||||
const TL004ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL004ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL006ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL006ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL008ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL008ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL010ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL010ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL014ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL014ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL016ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL016ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL018ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL018ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL025ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL025ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL027ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL027ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL029ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL029ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const BI020ApproveAnalysis = Loadable({
|
||||
loader: () => import('../components/CustomPages/BI/BI020ApproveAnalysis'),
|
||||
loading: () => <div />
|
||||
@ -1885,31 +1730,7 @@ export default function (componentName, formId, formParam, data, formCode, formD
|
||||
|
||||
OG018Check: <OG018Check formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OG020Edit: <OG020Edit formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
|
||||
TI008ShowPrint: <TI008ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TI008ShowPrints: <TI008ShowPrints formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TI010ShowPrint: <TI010ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TI012ShowPrint: <TI012ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TI014ShowPrint: <TI014ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TI016ShowPrint: <TI016ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TI018ShowPrint: <TI018ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TI021ShowPrint: <TI021ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
AE006ShowPrint: <AE006ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
AE008ShowPrint: <AE008ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
AE010ShowPrint: <AE010ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
AE019ShowPrint: <AE019ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
AE018ShowPrint: <AE018ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
|
||||
OH003ShowPrint: <OH003ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OH005ShowPrint: <OH005ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OH006ShowPrint: <OH006ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OH010ShowPrint: <OH010ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OH012ShowPrint: <OH012ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OH017Import: <OH017Import formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OH024ShowPrint: <OH024ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OH028ShowPrint: <OH028ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OH034ShowPrint: <OH034ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
|
||||
|
||||
SC046ShowPrint: <SC046ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
SC052ShowPrint: <SC052ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
|
||||
@ -1962,23 +1783,7 @@ export default function (componentName, formId, formParam, data, formCode, formD
|
||||
PF136FormRunAnalysis: <PF136FormRunAnalysis formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
BI009FormRunAnalysis: <BI009FormRunAnalysis formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
FO025ShowPrint: <FO025ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL037ShowPrint: <TL037ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL039ShowPrint: <TL039ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL041ShowPrint: <TL041ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL043ShowPrint: <TL043ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL044ShowPrint: <TL044ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL046ShowPrint: <TL046ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
|
||||
TL004ShowPrint: <TL004ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL006ShowPrint: <TL006ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL008ShowPrint: <TL008ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL010ShowPrint: <TL010ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL016ShowPrint: <TL016ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL016ShowPrint: <TL016ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL018ShowPrint: <TL018ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL025ShowPrint: <TL025ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL027ShowPrint: <TL027ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL029ShowPrint: <TL029ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
|
||||
BI020ApproveAnalysis: <BI020ApproveAnalysis formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
}[componentName]
|
||||
}
|
||||
|
||||
@ -157,27 +157,6 @@ const PFFormConfigSqlPage = Loadable({
|
||||
loader: () => import('../components/CustomPages/PF/FormConfigSqlPage'),
|
||||
loading: () => <div />
|
||||
})
|
||||
|
||||
const AE006ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/AE/AE006ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const AE008ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/AE/AE008ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const AE010ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/AE/AE010ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const AE019ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/AE/AE019ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const AE018ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/AE/AE018ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const CM018ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/CM/CM018ShowPrint'),
|
||||
loading: () => <div />
|
||||
@ -237,151 +216,11 @@ const PFFormConfigByNamePage = Loadable({
|
||||
loading: () => <div />
|
||||
})
|
||||
|
||||
const OH003ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH003ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH005ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH005ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH006ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH006ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH010ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH010ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH012ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH012ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH017Import = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH017Import'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH024ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH024ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH028ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH028ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const OH034ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/OH/OH034ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
|
||||
const TI008ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TI/TI008ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TI008ShowPrints = Loadable({
|
||||
loader: () => import('../components/CustomPages/TI/TI008ShowPrints'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TI010ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TI/TI010ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TI012ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TI/TI012ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TI014ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TI/TI014ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TI016ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TI/TI016ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TI018ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TI/TI018ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TI021ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TI/TI021ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const FMUserEditPage = Loadable({
|
||||
loader: () => import('../components/CustomPages/FM/UserEditPage'),
|
||||
loading: () => <div />
|
||||
})
|
||||
|
||||
const TL037ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL037ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL039ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL039ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL041ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL041ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL043ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL043ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL044ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL044ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
|
||||
const TL046ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL046ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
|
||||
|
||||
const TL004ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL004ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL006ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL006ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL008ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL008ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL010ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL010ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL014ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL014ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL016ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL016ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL018ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL018ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL025ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL025ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL027ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL027ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
const TL029ShowPrint = Loadable({
|
||||
loader: () => import('../components/CustomPages/TL/TL029ShowPrint'),
|
||||
loading: () => <div />
|
||||
})
|
||||
|
||||
|
||||
|
||||
|
||||
export default function (componentName, formId, formParam, data, formCode, formData) {
|
||||
return {
|
||||
FMUserEditPage: <FMUserEditPage formId={formId} formParam={formParam} data={data} formCode={formCode} formData={formData} />,
|
||||
@ -429,12 +268,6 @@ export default function (componentName, formId, formParam, data, formCode, formD
|
||||
PFCommonApproveView: <PFCommonApproveView formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
PFFormConfigSqlPage: <PFFormConfigSqlPage formId={formId} formParam={formParam} data={data} />,
|
||||
|
||||
AE006ShowPrint: <AE006ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
AE008ShowPrint: <AE008ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
AE010ShowPrint: <AE010ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
AE019ShowPrint: <AE019ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
AE018ShowPrint: <AE018ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
|
||||
CM018ShowPrint: <CM018ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
CM023ShowPrint: <CM023ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
CM026ShowPrint: <CM026ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
@ -450,42 +283,6 @@ export default function (componentName, formId, formParam, data, formCode, formD
|
||||
DM010ShowPrint: <DM010ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
DM032ShowPrint: <DM032ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
|
||||
OH003ShowPrint: <OH003ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OH005ShowPrint: <OH005ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OH006ShowPrint: <OH006ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OH010ShowPrint: <OH010ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OH012ShowPrint: <OH012ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OH017Import: <OH017Import formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OH024ShowPrint: <OH024ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OH028ShowPrint: <OH028ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
OH034ShowPrint: <OH034ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
|
||||
TI008ShowPrint: <TI008ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TI008ShowPrints: <TI008ShowPrints formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TI010ShowPrint: <TI010ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TI012ShowPrint: <TI012ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TI014ShowPrint: <TI014ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TI016ShowPrint: <TI016ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TI018ShowPrint: <TI018ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TI021ShowPrint: <TI021ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL037ShowPrint: <TL037ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL039ShowPrint: <TL039ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL041ShowPrint: <TL041ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL043ShowPrint: <TL043ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL044ShowPrint: <TL044ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL046ShowPrint: <TL046ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
|
||||
TL004ShowPrint: <TL004ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL006ShowPrint: <TL006ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL008ShowPrint: <TL008ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL010ShowPrint: <TL010ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL014ShowPrint: <TL014ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL016ShowPrint: <TL016ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL018ShowPrint: <TL018ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL025ShowPrint: <TL025ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL027ShowPrint: <TL027ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
TL029ShowPrint: <TL029ShowPrint formId={formId} formParam={formParam} data={data} formCode={formCode} />,
|
||||
|
||||
}[componentName]
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user