mirror of
https://gitlab.silvrtree.co.uk/martind2000/nci.git
synced 2025-01-11 03:05:07 +00:00
fix route change issue
This commit is contained in:
parent
94d57445b3
commit
46bfedc506
@ -22,9 +22,12 @@ define([
|
||||
|
||||
var Component = React.createClass({
|
||||
mixins: [Reflux.ListenerMixin],
|
||||
statics: {
|
||||
willTransitionTo: function(transition, params, query) {
|
||||
BuildActions.read(Number(params.id));
|
||||
}
|
||||
},
|
||||
componentDidMount: function() {
|
||||
BuildActions.read(Number(this.props.params.id));
|
||||
|
||||
this.listenTo(buildStore, this.updateBuild);
|
||||
},
|
||||
updateBuild: function(build) {
|
||||
|
@ -18,10 +18,13 @@ define([
|
||||
|
||||
return React.createClass({
|
||||
mixins: [Reflux.ListenerMixin],
|
||||
statics: {
|
||||
willTransitionTo: function(transition, params, query) {
|
||||
ProjectActions.read({name: params.name});
|
||||
BuildActions.readAll({projectName: params.name});
|
||||
}
|
||||
},
|
||||
componentDidMount: function() {
|
||||
ProjectActions.read({name: this.props.params.name});
|
||||
BuildActions.readAll({projectName: this.props.params.name});
|
||||
|
||||
this.listenTo(projectStore, this.updateItem);
|
||||
},
|
||||
updateItem: function(project) {
|
||||
|
Loading…
Reference in New Issue
Block a user