summaryrefslogtreecommitdiffstats
path: root/web/react/components/access_history_modal.jsx
diff options
context:
space:
mode:
authorChristopher Speller <crspeller@gmail.com>2015-11-18 08:49:29 -0500
committerChristopher Speller <crspeller@gmail.com>2015-11-18 08:49:29 -0500
commit7b01528d17c61a762ded17a23ccd9a2a728910a0 (patch)
tree9dd7fd2667ae03c4e72bb4abd495d2c3d84373ea /web/react/components/access_history_modal.jsx
parent5716a5e2fd96859e7d0c8784bd0297b4654dcf4b (diff)
parent70de0125abdc84d70580f82b29a4314e3515a587 (diff)
downloadchat-7b01528d17c61a762ded17a23ccd9a2a728910a0.tar.gz
chat-7b01528d17c61a762ded17a23ccd9a2a728910a0.tar.bz2
chat-7b01528d17c61a762ded17a23ccd9a2a728910a0.zip
Merge pull request #1423 from hmhealey/plt737
PLT-737 Converted first set of Modals to ReactBootstrap
Diffstat (limited to 'web/react/components/access_history_modal.jsx')
-rw-r--r--web/react/components/access_history_modal.jsx10
1 files changed, 7 insertions, 3 deletions
diff --git a/web/react/components/access_history_modal.jsx b/web/react/components/access_history_modal.jsx
index ab5686720..65b80dfb7 100644
--- a/web/react/components/access_history_modal.jsx
+++ b/web/react/components/access_history_modal.jsx
@@ -14,8 +14,8 @@ export default class AccessHistoryModal extends React.Component {
this.onAuditChange = this.onAuditChange.bind(this);
this.handleMoreInfo = this.handleMoreInfo.bind(this);
- this.onHide = this.onHide.bind(this);
this.onShow = this.onShow.bind(this);
+ this.onHide = this.onHide.bind(this);
this.formatAuditInfo = this.formatAuditInfo.bind(this);
this.handleRevokedSession = this.handleRevokedSession.bind(this);
@@ -39,10 +39,14 @@ export default class AccessHistoryModal extends React.Component {
}
onHide() {
this.setState({moreInfo: []});
- this.props.onModalDismissed();
+ this.props.onHide();
}
componentDidMount() {
UserStore.addAuditsChangeListener(this.onAuditChange);
+
+ if (this.props.show) {
+ this.onShow();
+ }
}
componentDidUpdate(prevProps) {
if (this.props.show && !prevProps.show) {
@@ -406,5 +410,5 @@ export default class AccessHistoryModal extends React.Component {
AccessHistoryModal.propTypes = {
show: React.PropTypes.bool.isRequired,
- onModalDismissed: React.PropTypes.func.isRequired
+ onHide: React.PropTypes.func.isRequired
};