V2 UI shouldn't sort dashboards lexicologically
authorrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 6 Oct 2015 21:41:56 +0000 (21:41 +0000)
committerrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 6 Oct 2015 21:41:56 +0000 (21:41 +0000)
https://bugs.webkit.org/show_bug.cgi?id=149856

Reviewed by Chris Dumez.

Don't sort the dashboards by name in App.Manifest.

* public/v2/app.js:
(App.IndexRoute.beforeModel): Don't transition to "undefined" (string) dashboard.
* public/v2/manifest.js:
(App.Manifest.._fetchedManifest):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@190647 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Websites/perf.webkit.org/ChangeLog
Websites/perf.webkit.org/public/v2/app.js
Websites/perf.webkit.org/public/v2/manifest.js

index c3dbbca..9e968f4 100644 (file)
@@ -1,5 +1,19 @@
 2015-10-06  Ryosuke Niwa  <rniwa@webkit.org>
 
+        V2 UI shouldn't sort dashboards lexicologically
+        https://bugs.webkit.org/show_bug.cgi?id=149856
+
+        Reviewed by Chris Dumez.
+
+        Don't sort the dashboards by name in App.Manifest.
+
+        * public/v2/app.js:
+        (App.IndexRoute.beforeModel): Don't transition to "undefined" (string) dashboard.
+        * public/v2/manifest.js:
+        (App.Manifest.._fetchedManifest):
+
+2015-10-06  Ryosuke Niwa  <rniwa@webkit.org>
+
         V2 UI fails to show the data for the very first point in charts
         https://bugs.webkit.org/show_bug.cgi?id=149857
 
index ed2dde7..3760624 100644 (file)
@@ -61,7 +61,7 @@ App.IndexRoute = Ember.Route.extend({
     {
         var self = this;
         App.Manifest.fetch(this.store).then(function () {
-            self.transitionTo('dashboard', App.Manifest.defaultDashboardName());
+            self.transitionTo('dashboard', App.Manifest.defaultDashboardName() || '');
         });
     },
 });
index c4ee46a..4c91967 100644 (file)
@@ -304,7 +304,7 @@ App.Manifest = Ember.Controller.extend({
 
         this.set('bugTrackers', store.all('bugTracker').sortBy('name'));
 
-        var dashboards = store.all('dashboard').sortBy('name');
+        var dashboards = store.all('dashboard').toArray();
         this.set('dashboards', dashboards);
         dashboards.forEach(function (dashboard) { self._dashboardByName[dashboard.get('name')] = dashboard; });
         this._defaultDashboardName = dashboards.length ? dashboards[0].get('name') : null;