You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@aurora.apache.org by ma...@apache.org on 2014/04/05 02:05:10 UTC

[24/50] [abbrv] git commit: Now showing and hiding details.

Now showing and hiding details.

The UX is a bit confusing though.


Project: http://git-wip-us.apache.org/repos/asf/incubator-aurora/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-aurora/commit/1b1c9de2
Tree: http://git-wip-us.apache.org/repos/asf/incubator-aurora/tree/1b1c9de2
Diff: http://git-wip-us.apache.org/repos/asf/incubator-aurora/diff/1b1c9de2

Branch: refs/heads/mansu/job_page
Commit: 1b1c9de2529d0fd70bd129318164a01bb3b20873
Parents: 5c14c10
Author: Suman Karumuri <sk...@twitter.com>
Authored: Sat Mar 29 20:34:08 2014 -0700
Committer: Suman Karumuri <sk...@twitter.com>
Committed: Sat Mar 29 20:34:08 2014 -0700

----------------------------------------------------------------------
 .../org/apache/aurora/scheduler/http/ui/css/app.css     |  4 ----
 .../apache/aurora/scheduler/http/ui/js/controllers.js   |  3 ++-
 .../apache/aurora/scheduler/http/ui/js/directives.js    |  8 +++++++-
 .../aurora/scheduler/http/ui/schedulingDetail.html      |  2 +-
 .../org/apache/aurora/scheduler/http/ui/taskStatus.html | 12 ++++++++++--
 5 files changed, 20 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/1b1c9de2/src/main/resources/org/apache/aurora/scheduler/http/ui/css/app.css
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/ui/css/app.css b/src/main/resources/org/apache/aurora/scheduler/http/ui/css/app.css
index 151a98e..e327dc9 100644
--- a/src/main/resources/org/apache/aurora/scheduler/http/ui/css/app.css
+++ b/src/main/resources/org/apache/aurora/scheduler/http/ui/css/app.css
@@ -29,7 +29,3 @@ ul.breadcrumb {
   margin: 0px auto;
   float: none;
 }
-
-.undecorated-list {
-  list-style: none;
-}

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/1b1c9de2/src/main/resources/org/apache/aurora/scheduler/http/ui/js/controllers.js
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/ui/js/controllers.js b/src/main/resources/org/apache/aurora/scheduler/http/ui/js/controllers.js
index f7df538..0074a89 100644
--- a/src/main/resources/org/apache/aurora/scheduler/http/ui/js/controllers.js
+++ b/src/main/resources/org/apache/aurora/scheduler/http/ui/js/controllers.js
@@ -369,7 +369,8 @@ auroraUIControllers.controller('JobController',
               : lastTransition - runningTaskEvent.timestamp,
             isActive: isActive,
             taskId: task.assignedTask.taskId,
-            taskEvents: toTaskEvents(sortedTaskEvents)
+            taskEvents: toTaskEvents(sortedTaskEvents),
+            showDetails: false
           };
         })
         .value();

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/1b1c9de2/src/main/resources/org/apache/aurora/scheduler/http/ui/js/directives.js
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/ui/js/directives.js b/src/main/resources/org/apache/aurora/scheduler/http/ui/js/directives.js
index 73e44b2..a7be8b5 100644
--- a/src/main/resources/org/apache/aurora/scheduler/http/ui/js/directives.js
+++ b/src/main/resources/org/apache/aurora/scheduler/http/ui/js/directives.js
@@ -46,7 +46,13 @@ auroraUI.directive('taskSandboxLink', function () {
 
 auroraUI.directive('taskStatus', function () {
   return {
-    restrict: 'E'
+    restrict: 'E',
+    replace: true,
+    link: function (scope, element, attrs, ctrl) {
+      element.on('click', function (e) {
+        scope.showDetails = !scope.showDetails;
+      });
+    }
   };
 });
 

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/1b1c9de2/src/main/resources/org/apache/aurora/scheduler/http/ui/schedulingDetail.html
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/ui/schedulingDetail.html b/src/main/resources/org/apache/aurora/scheduler/http/ui/schedulingDetail.html
index 22c1b39..b7e3049 100644
--- a/src/main/resources/org/apache/aurora/scheduler/http/ui/schedulingDetail.html
+++ b/src/main/resources/org/apache/aurora/scheduler/http/ui/schedulingDetail.html
@@ -1,5 +1,5 @@
 <div class='scheduling-detail'>
-  <ul class='undecorated-list'>
+  <ul class='unstyled'>
     <li>resources:
       cpu: {{dataRow.schedulingDetail.numCpus | toCores}},
       ram: {{dataRow.schedulingDetail.ramMb | scaleMb}},

http://git-wip-us.apache.org/repos/asf/incubator-aurora/blob/1b1c9de2/src/main/resources/org/apache/aurora/scheduler/http/ui/taskStatus.html
----------------------------------------------------------------------
diff --git a/src/main/resources/org/apache/aurora/scheduler/http/ui/taskStatus.html b/src/main/resources/org/apache/aurora/scheduler/http/ui/taskStatus.html
index f68d0ff..a66b0b0 100644
--- a/src/main/resources/org/apache/aurora/scheduler/http/ui/taskStatus.html
+++ b/src/main/resources/org/apache/aurora/scheduler/http/ui/taskStatus.html
@@ -1,7 +1,15 @@
 <task-status>
   <div>
-    <a href='#' title='{{formatedValue | scheduleStatusTooltip}}'>{{formatedValue}}</a>
-    <ul>
+    <a ng-href='#' title='{{formatedValue | scheduleStatusTooltip}}'>
+      <span ng-if='!showDetails'>
+        <i class='icon-plus'></i> {{formatedValue}}
+      </span>
+      <span ng-if='showDetails'>
+        <i class='icon-minus'></i> {{formatedValue}}
+      </span>
+    </a>
+
+    <ul ng-if='showDetails'>
       <li ng-repeat='taskEvent in dataRow.taskEvents'>
         {{taskEvent.date}} UTC -
         <a href='#' title='{{taskEvent.status | scheduleStatusTooltip}}'>{{taskEvent.status}}</a>