From 6816393fbfa11ce67088832b45399a52a961586a Mon Sep 17 00:00:00 2001
From: Mr Ke <kelq@hugeinfo.com.cn>
Date: Wed, 27 May 2020 16:45:41 +0800
Subject: [PATCH] Merge branch 'master' of http://120.79.193.119:9090/r/nsjcy/frontEnd/nsjcy
---
SunshineIns/src/page/CriminalExecution.jsx | 54 ++++++++++++++++++++++++++++++------------------------
1 files changed, 30 insertions(+), 24 deletions(-)
diff --git a/SunshineIns/src/page/CriminalExecution.jsx b/SunshineIns/src/page/CriminalExecution.jsx
index 31d038d..dead32e 100644
--- a/SunshineIns/src/page/CriminalExecution.jsx
+++ b/SunshineIns/src/page/CriminalExecution.jsx
@@ -3,7 +3,7 @@
import HeadView from '../view/HeadView';
import TableBtnView from '../view/TableBtnView';
import CommonSearchForm from '../view/CommonSearchForm';
-import { Input, Button, DatePicker, Divider, message, Popconfirm, Select, Badge, Modal } from 'antd';
+import { Input, Button, DatePicker, Divider, message, Popconfirm, Select, Badge, Modal, Row, Col } from 'antd';
import moment from 'moment';
import Fetch from '../fetch';
import TableView from '../view/TableView';
@@ -65,17 +65,19 @@
},
resetKey: Date.now(),
loading: false,
- savedate:{}
+ zIndex: '-1',
+ savedate: {},
+ display: 'none'
};
}
componentDidMount() {
document.title = '社会观护管理';
window.addEventListener('message', function (e) {
-
+ console.log('反馈', e)
}, false);
console.log('this', this);
- // this.iframeAddEventListener();
+ this.iframeAddEventListener();
}
setFormData = data => {
@@ -105,7 +107,9 @@
showModal = (id) => {
this.setState({
visible: true,
+ zIndex: 1000
});
+ this.sendMsg()
// Fetch.socialCompanyDetail(id)
// .then(res => {
// this.setState({ savedate: res })
@@ -159,19 +163,25 @@
iframeAddEventListener = () => {
let _this = this;
- this.iframeWin = this.refs.iframe.contentWindow;
+ this.iframeWin = this.refs.iframe && this.refs.iframe.contentWindow;
this.refs.iframe && this.refs.iframe.addEventListener("load", function () {
//代码能执行到这里说明已经载入成功完毕了
//这里是回调函数
- console.log('menu', window.localStorage.getItem('menu'));
_this.iframeWin.postMessage({
fgData: false
}, '*');
}, false);
}
+ sendMsg = () => {
+ this.iframeWin = this.refs.iframe && this.refs.iframe.contentWindow;
+ this.iframeWin.postMessage({
+ fgData: false
+ }, '*');
+ }
+
render() {
- const { data, resetKey, visible, loading, savedate, closeKey, formData } = this.state;
+ const { data, resetKey, visible, loading, savedate, closeKey, formData, zIndex, display } = this.state;
return (
<div className="app-page">
<HeadView history={this.props.history} />
@@ -198,33 +208,28 @@
]} />
<TableView columns={this.renderColumns()} data={data} pageSize='10' size='default' loading={loading} />
</div>
- {/* <div style={{ display: 'block' }}> */}
- {/* <iframe
- style={{ width: '100%', height: '100%' }}
- onLoad={() => { }}
- ref="iframe"
- src='./fingerprint/指纹登记.html'
- width="100%"
- scrolling="no"
- frameBorder="0"
- /> */}
<Modal
+ zIndex={zIndex}
key={closeKey}
confirmLoading={loading}
- visible={visible}
- title="录入信息"
- onCancel={() => { this.setState({ visible: false }) }}
+ visible={true}
+ title="指纹录入"
+ onCancel={() => { this.setState({ visible: false, zIndex: '-1', }) }}
bodyStyle={{ lineHeight: 4 }}
// footer={null}
width={'60%'}
- bodyStyle={{ height: '800px',lineHeight: 4 }}
+ bodyStyle={{ lineHeight: 4 }}
>
<Input addonBefore="姓名" name='name' onChange={this.saveInputChange} value={savedate.name || ''} />
<Input addonBefore="牢房号" name='lnumber' onChange={this.saveInputChange} value={savedate.lnumber || ''} />
- <Input addonBefore="指纹唯一标识" name='bianshi' onChange={this.saveInputChange} value={savedate.bianshi || ''} />
- <Divider />
+ <Input addonBefore="指纹唯一标识" name='bianshi' onChange={this.saveInputChange} value={savedate.bianshi || ''} addonAfter={<Row type="flex" style={{ flexWrap: 'nowrap' }}>
+ <Col style={{ cursor: 'pointer' }} onClick={() => this.setState({ display: 'block'})}>
+ 录入指纹
+ </Col>
+ </Row>} />
+ <Divider style={{ margin: '2px 0' }} />
<iframe
- style={{ width: '100%', height: '100%' }}
+ style={{ width: '100%', height: '550px', display: display }}
onLoad={() => { }}
ref="iframe"
src='./fingerprint/指纹登记.html'
@@ -233,6 +238,7 @@
frameBorder="0"
/>
</Modal>
+
{/* </div> */}
</div>
)
--
Gitblit v1.8.0