dispatching

This commit is contained in:
Belen Curcio
2017-01-24 14:13:43 -03:00
parent 765edb48b9
commit f375ff48c9
2 changed files with 11 additions and 6 deletions
@@ -1,5 +1,6 @@
import React, {Component} from 'react';
import {connect} from 'react-redux';
import {compose} from 'react-apollo';
import {I18n} from '../../coral-framework';
import {updateOpenStatus, updateConfiguration} from '../../coral-framework/actions/config';
@@ -57,8 +58,9 @@ class ConfigureStreamContainer extends Component {
}
render () {
const {status} = this.props;
const {status, asset} = this.props;
// asset.closedAt === null
console.log(this.props.apollo.data)
return (
<div>
<ConfigureCommentStream
@@ -81,10 +83,7 @@ class ConfigureStreamContainer extends Component {
const mapStateToProps = (state) => ({
config: state.config.toJS(),
asset: state.items
.get('assets')
.first()
.toJS()
apollo: state.apollo
});
const mapDispatchToProps = dispatch => ({
+6
View File
@@ -48,6 +48,12 @@ class Embed extends Component {
}).isRequired
}
componentWillReceiveProps (nextProps) {
if (nextProps.data != null) {
console.log(nextProps.data)
}
}
render () {
const {activeTab} = this.state;
const {dispatch} = this.props;