flink-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rmetz...@apache.org
Subject [4/8] flink git commit: [FLINK-3437] [web-dashboard] Fix UI router state for job plan
Date Fri, 26 Feb 2016 12:31:35 GMT
[FLINK-3437] [web-dashboard] Fix UI router state for job plan

Transitive dependency EvEmitter updated to 1.0.2

This closes #1661


Project: http://git-wip-us.apache.org/repos/asf/flink/repo
Commit: http://git-wip-us.apache.org/repos/asf/flink/commit/ee76fc45
Tree: http://git-wip-us.apache.org/repos/asf/flink/tree/ee76fc45
Diff: http://git-wip-us.apache.org/repos/asf/flink/diff/ee76fc45

Branch: refs/heads/master
Commit: ee76fc453cc2cf123e9733048214a17335efb963
Parents: db6fda6
Author: Greg Hogan <code@greghogan.com>
Authored: Wed Feb 17 16:52:22 2016 +0000
Committer: Robert Metzger <rmetzger@apache.org>
Committed: Fri Feb 26 11:32:00 2016 +0100

----------------------------------------------------------------------
 .../web-dashboard/app/partials/jobs/job.jade    |    2 +-
 .../web-dashboard/app/scripts/index.coffee      |   10 +-
 flink-runtime-web/web-dashboard/web/js/index.js |   89 +-
 .../web-dashboard/web/js/vendor.js              | 1138 ++++++++++++------
 .../web-dashboard/web/partials/jobs/job.html    |    2 +-
 5 files changed, 835 insertions(+), 406 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flink/blob/ee76fc45/flink-runtime-web/web-dashboard/app/partials/jobs/job.jade
----------------------------------------------------------------------
diff --git a/flink-runtime-web/web-dashboard/app/partials/jobs/job.jade b/flink-runtime-web/web-dashboard/app/partials/jobs/job.jade
index 39a6a1c..d80beee 100644
--- a/flink-runtime-web/web-dashboard/app/partials/jobs/job.jade
+++ b/flink-runtime-web/web-dashboard/app/partials/jobs/job.jade
@@ -50,7 +50,7 @@ nav.navbar.navbar-default.navbar-fixed-top.navbar-main(ng-if="job")
 nav.navbar.navbar-default.navbar-fixed-top.navbar-main-additional(ng-if="job")
   ul.nav.nav-tabs
     li(ui-sref-active='active')
-      a(ui-sref=".plan.subtasks") Plan
+      a(ui-sref=".plan") Plan
 
     //- li(ui-sref-active='active' ng-if="job['end-time'] > -1")
     li(ui-sref-active='active')

http://git-wip-us.apache.org/repos/asf/flink/blob/ee76fc45/flink-runtime-web/web-dashboard/app/scripts/index.coffee
----------------------------------------------------------------------
diff --git a/flink-runtime-web/web-dashboard/app/scripts/index.coffee b/flink-runtime-web/web-dashboard/app/scripts/index.coffee
index 120e2d6..e7a4829 100644
--- a/flink-runtime-web/web-dashboard/app/scripts/index.coffee
+++ b/flink-runtime-web/web-dashboard/app/scripts/index.coffee
@@ -54,6 +54,14 @@ angular.module('flinkApp', ['ui.router', 'angularMoment'])
 
 # --------------------------------------
 
+.run ($rootScope, $state) ->
+  $rootScope.$on '$stateChangeStart', (event, toState, toParams, fromState) ->
+    if toState.redirectTo
+      event.preventDefault()
+      $state.go toState.redirectTo, toParams
+
+# --------------------------------------
+
 .config ($stateProvider, $urlRouterProvider) ->
   $stateProvider.state "overview",
     url: "/overview"
@@ -86,7 +94,7 @@ angular.module('flinkApp', ['ui.router', 'angularMoment'])
 
   .state "single-job.plan",
     url: ""
-    abstract: true
+    redirectTo: "single-job.plan.subtasks"
     views:
       details:
         templateUrl: "partials/jobs/job.plan.html"


Mime
View raw message