Created
November 30, 2015 12:57
-
-
Save kgish/4a93d4d84324628f0a79 to your computer and use it in GitHub Desktop.
Emberjs: Getting another store from controller
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
App.FormController = Em.ObjectController.extend({ | |
tagArray: Em.A(), | |
init: function() { | |
this.setTagArray(); | |
this._super(); | |
}, | |
setTagArray: function() { | |
var _this = this; | |
// Set the array | |
_this.get('controller.store').find('tag').then(function(tags) { | |
_this.set('tagArray', tags); | |
} | |
}, | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment