diff options
Diffstat (limited to 'javascript')
-rw-r--r-- | javascript/app/controllers/package.js | 8 | ||||
-rw-r--r-- | javascript/app/routes/package.js | 5 |
2 files changed, 4 insertions, 9 deletions
diff --git a/javascript/app/controllers/package.js b/javascript/app/controllers/package.js index 278899f..a9f5559 100644 --- a/javascript/app/controllers/package.js +++ b/javascript/app/controllers/package.js @@ -9,18 +9,14 @@ export default Ember.Controller.extend({ query : null, searchMode : "currentPackage", createSearchUrlFunction : Ember.computed("searchMode",function() { - const packageId = this.get('model.id'); - const query = this.get('query'); + const packageId = this.get('model.id'); if(this.get('searchMode') === "currentPackage") { return (query) => urls.identifierSearchUrl(packageId,query); - } else { + } else { return (query) => urls.globalIdentifiersUrl(query); } }), actions : { - searchModeChanged () { - - }, searchIdentifier (query) { if(query) { this.set('currentFile',null); diff --git a/javascript/app/routes/package.js b/javascript/app/routes/package.js index 037ed97..e908ca4 100644 --- a/javascript/app/routes/package.js +++ b/javascript/app/routes/package.js @@ -8,10 +8,9 @@ export default Ember.Route.extend({ .catch((e) => {console.log(e);this.transitionTo("/package-not-found");}); }, setupController(controller, model) { - this._super(controller, model); - const packageId = this.modelFor('package').id; + this._super(controller, model); controller.set('bottomPanelVisible',false); - }, + }, actions : { openFile (filePath) { this.transitionTo('package.show.file',filePath); |