[ARVADOS] created: c0c1111f322159333fdf14e3d3e8ce0c00662734

git at public.curoverse.com git at public.curoverse.com
Wed Feb 5 17:36:42 EST 2014


        at  c0c1111f322159333fdf14e3d3e8ce0c00662734 (commit)


commit c0c1111f322159333fdf14e3d3e8ce0c00662734
Author: Peter Amstutz <peter.amstutz at curoverse.com>
Date:   Wed Feb 5 17:37:36 2014 -0500

    Menubar and left nav redesign in progress.

diff --git a/apps/workbench/app/assets/stylesheets/application.css.scss b/apps/workbench/app/assets/stylesheets/application.css.scss
index 446f524..6fc4522 100644
--- a/apps/workbench/app/assets/stylesheets/application.css.scss
+++ b/apps/workbench/app/assets/stylesheets/application.css.scss
@@ -79,6 +79,7 @@ form.small-form-margin {
 .nowrap {
     white-space: nowrap;
 }
+
 .navbar .nav li.nav-separator > span {
     display: block;
     float: none;
@@ -87,6 +88,32 @@ form.small-form-margin {
     text-decoration: none;
     text-shadow: 0 1px 0 #ffffff;
 }
-.navbar .nav .dropdown .dropdown-menu li a {
+/*.navbar .nav .dropdown .dropdown-menu li a {
     padding: 2px 20px;
+}*/
+
+ul.arvados-nav {
+    list-style: none;
+    padding-left: 0em;
+    margin-left: 0em;
+}
+
+ul.arvados-nav li ul {
+    list-style: none;
+    padding-left: 0;
+}
+
+ul.arvados-nav li ul li {
+    list-style: none;
+    padding-left: 1em;
+}
+
+.badge {
+    background: red;
+}
+
+.dax {
+    max-width: 10%;
+    margin-right: 1em;
+    float: left
 }
diff --git a/apps/workbench/app/controllers/application_controller.rb b/apps/workbench/app/controllers/application_controller.rb
index 27a4f79..aa87a60 100644
--- a/apps/workbench/app/controllers/application_controller.rb
+++ b/apps/workbench/app/controllers/application_controller.rb
@@ -5,6 +5,7 @@ class ApplicationController < ActionController::Base
   around_filter :thread_with_api_token, :except => [:render_exception, :render_not_found]
   before_filter :find_object_by_uuid, :except => [:index, :render_exception, :render_not_found]
   before_filter :check_user_agreements, :except => [:render_exception, :render_not_found]
+  before_filter :check_user_notifications, :except => [:render_exception, :render_not_found]
   theme :select_theme
 
   begin
@@ -276,4 +277,100 @@ class ApplicationController < ActionController::Base
   def select_theme
     return Rails.configuration.arvados_theme
   end
+
+  @@notification_tests = []
+
+  @@notification_tests.push lambda { |controller, current_user|
+    AuthorizedKey.limit(1).where(authorized_user_uuid: current_user.uuid).each do   
+      return nil
+    end
+    return lambda { |view|
+      view.render partial: 'notifications/ssh_key_notification'
+    }
+  }
+
+  @@notification_tests.push lambda { |controller, current_user|
+    AuthorizedKey.limit(1).where(authorized_user_uuid: current_user.uuid).each do   
+      return nil
+    end
+    return lambda { |view|
+      view.render partial: 'notifications/jobs_notification'
+    }
+  }
+
+  @@notification_tests.push lambda { |controller, current_user|
+    Job.limit(1).where(created_by: current_user.uuid).each do   
+      return nil
+    end
+    return lambda { |view|
+      view.render partial: 'notifications/jobs_notification'
+    }
+  }
+
+  @@notification_tests.push lambda { |controller, current_user|
+    Collection.limit(1).where(created_by: current_user.uuid).each do   
+      return nil
+    end
+    return lambda { |view|
+      view.render partial: 'notifications/collections_notification'
+    }
+  }
+
+  @@notification_tests.push lambda { |controller, current_user|
+    PipelineInstance.limit(1).where(created_by: current_user.uuid).each do   
+      return nil
+    end
+    return lambda { |view|
+      view.render partial: 'notifications/pipelines_notification'
+    }
+  }
+
+  def check_user_notifications
+    @notification_count = 0
+    @notifications = []
+
+    if current_user
+      @showallalerts = false      
+      @@notification_tests.each do |t|
+        a = t.call(self, current_user)
+        if a
+          @notification_count += 1
+          @notifications.push a
+        end
+      end
+    end
+
+    if @notification_count == 0
+      @notification_count = ''
+    end
+    
+    # @my_ssh_keys = AuthorizedKey.where(authorized_user_uuid: current_user.uuid)
+    # @my_vm_perms = Link.where(tail_uuid: current_user.uuid, head_kind: 'arvados#virtual_machine', link_class: 'permission', name: 'can_login')
+    # @my_repo_perms = Link.where(tail_uuid: current_user.uuid, head_kind: 'arvados#repository', link_class: 'permission', name: 'can_write')
+
+    # @my_tag_links = {}
+
+    # @my_jobs = Job.
+    #   limit(10).
+    #   order('created_at desc').
+    #   where(created_by: current_user.uuid)
+
+    # @my_collections = Collection.
+    #   limit(10).
+    #   order('created_at desc').
+    #   where(created_by: current_user.uuid)
+
+    # Link.limit(1000).where(head_uuid: @my_collections.collect(&:uuid),
+    #                        link_class: 'tag').each do |link|
+    #   (@my_tag_links[link.head_uuid] ||= []) << link
+    # end
+
+    # @my_pipelines = PipelineInstance.
+    #   limit(10).
+    #   order('created_at desc').
+    #   where(created_by: current_user.uuid)
+
+    
+
+  end
 end
diff --git a/apps/workbench/app/views/application/_breadcrumb_page_name.html.erb b/apps/workbench/app/views/application/_breadcrumb_page_name.html.erb
index 1fcbe88..8b13789 100644
--- a/apps/workbench/app/views/application/_breadcrumb_page_name.html.erb
+++ b/apps/workbench/app/views/application/_breadcrumb_page_name.html.erb
@@ -1 +1 @@
-<%= link_to controller.breadcrumb_page_name, request.fullpath %>
+
diff --git a/apps/workbench/app/views/application/index.html.erb b/apps/workbench/app/views/application/index.html.erb
index 167fea1..4ebedf6 100644
--- a/apps/workbench/app/views/application/index.html.erb
+++ b/apps/workbench/app/views/application/index.html.erb
@@ -14,6 +14,7 @@
 
 <% pane_list = controller.index_pane_list rescue %w(recent) %>
 
+<% if pane_list.length > 1 %>
 <div class="tabbable">
 <ul class="nav nav-tabs">
   <% pane_list.each_with_index do |pane, i| %>
@@ -28,3 +29,9 @@
   </div>
   <% end %>
 </div>
+
+<% else %>
+  <% pane_list.each_with_index do |pane, i| %>
+    <%= render partial: pane %>
+  <% end %>
+<% end %>
diff --git a/apps/workbench/app/views/layouts/application.html.erb b/apps/workbench/app/views/layouts/application.html.erb
index 117db91..341be81 100644
--- a/apps/workbench/app/views/layouts/application.html.erb
+++ b/apps/workbench/app/views/layouts/application.html.erb
@@ -29,7 +29,22 @@
     @media (max-width: 979px) { body { padding-top: 0; } }
 
     .navbar .nav li.nav-separator > span.glyphicon.glyphicon-arrow-right {
-    padding-top: 1em;
+    padding-top: 1.25em;
+    }
+
+    /* Setting the height needs to be fixed with javascript. */
+    .dropdown-menu {
+    padding-right: 20px;
+    max-height: 440px;
+    width: 400px;
+    overflow-y: auto;
+    }
+    
+    .arvados-nav-active {
+    background: rgb(66, 139, 202);
+    }
+    .arvados-nav-active a {
+    color: white;
     }
   </style>
 </head>
@@ -38,7 +53,8 @@
   <div class="navbar navbar-default navbar-fixed-top">
     <div class="container-fluid">
       <ul class="nav navbar-nav navbar-left">
-        <li><a class="navbar-brand"><%= Rails.configuration.site_name rescue Rails.application.class.parent_name %></a></li>
+        <li><a class="navbar-brand" href="/"><%= Rails.configuration.site_name rescue Rails.application.class.parent_name %></a></li>
+        <% if current_user %>
         <li class="nav-separator"><span class="glyphicon glyphicon-arrow-right"></span></li>
         <% if content_for?(:breadcrumbs) %>
           <%= yield(:breadcrumbs) %>
@@ -53,53 +69,58 @@
               <span class="glyphicon glyphicon-arrow-right"></span>
             </li>
             <li>
-              <%= render partial: 'breadcrumb_page_name' %>
+<%= link_to controller.breadcrumb_page_name, request.fullpath %>
             </li>
           <% end %>
         <% end %>
+        <% end %>
       </ul>
   
       <ul class="nav navbar-nav navbar-right">
-        <!--
+
+        <% if current_user %>
         <li>
           <div class="loading" style="transform: translate(-20px,20px) scale(0.1,0.1); -ms-transform: translate(-20px,20px) scale(0.1,0.1); -webkit-transform: translate(-20px,20px) scale(0.1,0.1); display: none">
             <%= render partial: 'loading' %>
           </div>
         </li>
-        -->
-        <!--
-        <li class="dropdown">
-          <a href="#" class="dropdown-toggle" data-toggle="dropdown" href="/">
-            Help <span class="caret"></span>
-          </a>
-          <ul class="dropdown-menu">
-            <li><%= link_to 'Tutorials and User guide', "#{Rails.configuration.arvados_docsite}/user", target: "_blank" %></li>
-            <li><%= link_to 'API Reference', "#{Rails.configuration.arvados_docsite}/api", target: "_blank" %></li>
-            <li><%= link_to 'SDK Reference', "#{Rails.configuration.arvados_docsite}/sdk", target: "_blank" %></li>
-            <li><%= link_to 'Admin guide', "#{Rails.configuration.arvados_docsite}/admin", target: "_blank" %></li>
-          </ul>
-        </li>
-        -->
 
-        <li class="dropdown">
-          <a href="#" class="dropdown-toggle" data-toggle="dropdown">
-            <span class="glyphicon glyphicon-th-list"></span> (0)<span class="caret"></span>
-          </a>
-        </li>        
+        <li>
+          <form class="navbar-form" role="search">
+            <div class="input-group">
+              <input type="text" class="form-control" placeholder="search">
+              <span class="input-group-addon"><span class="glyphicon glyphicon-search"></span>
+            </div>
+        </li>
 
         <li class="dropdown">
           <a href="#" class="dropdown-toggle" data-toggle="dropdown">
-            <span class="glyphicon glyphicon-envelope"></span> (0)<span class="caret"></span>
+            <span class="glyphicon glyphicon-envelope"></span>
+            <span class="badge"><%= @notification_count %></span>
+            <span class="caret"></span>
           </a>
+          <ul class="dropdown-menu" role="menu">
+            <% if @notifications.length > 0 %>
+              <% @notifications.each do |n| %>
+                <li style="padding: 10px"><%= n.call(self) %></li>
+                <li class="divider"></li>
+              <% end %>
+            <% else %>
+              <li style="padding: 10px">No notifications.</li>
+            <% end %>
+          </ul>
         </li>        
 
-	<% if current_user -%>
         <li class="dropdown">
           <a href="#" class="dropdown-toggle" data-toggle="dropdown">
             <span class="glyphicon glyphicon-user"></span><span class="caret"></span>
           </a>
           <ul class="dropdown-menu" role="menu">
             <li role="presentation" class="dropdown-header"><%= current_user.email %></li>
+            <li role="presentation" class="divider"></li>
+            <li role="presentation"><a href="/authorized_keys" role="menuitem">Manage ssh keys</a></li>
+            <li role="presentation"><a href="/api_client_authorizations" role="menuitem">Manage API tokens</a></li>
+            <li role="presentation" class="divider"></li>
             <li role="presentation"><a href="<%= logout_path %>" role="menuitem">Log out</a></li>
           </ul>
         </li>
@@ -110,13 +131,61 @@
     </div>
   </div>
 
-  <div class="container-fluid">
-
-    <div class="body-content">
-      <%= yield %>
+  <div style="padding: 70px 15px 0px">
+    <div class="row">
+      <div class="col-sm-3">
+        <% if current_user %>
+        <div class="well">
+        <ul class="arvados-nav">
+          <li><a href="/">Dashboard</a></li>
+          <li>Data
+            <ul>
+              <li class="arvados-nav-active"><a href="/humans">Humans</a></li>
+              <li><a href="/traits">Traits</a></li>
+              <li><a href="/specimens">Specimens</a></li>
+              <li><a href="/collections">Files</a></li>
+            </ul>
+          </li>
+          <li>Compute
+            <ul>
+              <li><a href="/pipeline_templates">Pipelines</a></li>
+              <li><a href="/repositories">Script repositories</a></li>
+              <li><a href="/virtual_machines">Virtual machines</a></li>
+            </ul>
+          </li>
+          <li>History
+            <ul>
+              <li><a href="/pipeline_instances">Pipeline history</a></li>
+              <li><a href="/jobs">Job history</a></li>
+            </ul>
+          </li>
+          <li>Help
+            <ul>
+              <li><%= link_to 'Tutorials and User guide', "#{Rails.configuration.arvados_docsite}/user", target: "_blank" %></li>
+              <li><%= link_to 'API Reference', "#{Rails.configuration.arvados_docsite}/api", target: "_blank" %></li>
+              <li><%= link_to 'SDK Reference', "#{Rails.configuration.arvados_docsite}/sdk", target: "_blank" %></li>
+              <li><%= link_to 'Admin guide', "#{Rails.configuration.arvados_docsite}/admin", target: "_blank" %></li>
+            </ul>
+          </li>
+          <% if current_user.andand.is_admin %>
+          <li>Admin
+            <ul>
+              <li><a href="/users">Users</a></li>
+              <li><a href="/groups">Groups</a></li>
+              <li><a href="/compute_nodes">Compute nodes</a></li>
+              <li><a href="/keep_disks">Keep disks</a></li>
+            </ul>
+          </li>
+          <% end %>
+        </ul>
+        </div>
+        <% end %>
+      </div>
+      <div class="col-sm-9">
+        <%= yield %>
+      </div>
     </div>
-
-  </div> <!-- /container -->
+  </div>
 
   <%= piwik_tracking_tag %>
   <%= javascript_tag do %>
diff --git a/apps/workbench/app/views/notifications/_collections_notification.html.erb b/apps/workbench/app/views/notifications/_collections_notification.html.erb
new file mode 100644
index 0000000..4ef0d31
--- /dev/null
+++ b/apps/workbench/app/views/notifications/_collections_notification.html.erb
@@ -0,0 +1,7 @@
+  <%= image_tag "dax.png", class: "dax" %>
+  <p>
+    Hi, I noticed you haven't uploaded a new collection yet. 
+    <%= link_to "Click here to learn how to upload data to Arvados Keep.", 
+	"#{Rails.configuration.arvados_docsite}/user/tutorials/tutorial-keep.html", 
+	style: "font-weight: bold", target: "_blank" %>
+  </p>
diff --git a/apps/workbench/app/views/notifications/_jobs_notification.html.erb b/apps/workbench/app/views/notifications/_jobs_notification.html.erb
new file mode 100644
index 0000000..18ebd02
--- /dev/null
+++ b/apps/workbench/app/views/notifications/_jobs_notification.html.erb
@@ -0,0 +1,8 @@
+  <p><%= image_tag "dax.png", class: "dax" %>
+    Hi, I noticed you haven't run a job yet. 
+    <%= link_to "Click here to learn how to run an Arvados Crunch job.", 
+	"#{Rails.configuration.arvados_docsite}/user/tutorials/tutorial-job1.html", 
+	style: "font-weight: bold",
+	target: "_blank" %>
+  </p>
+
diff --git a/apps/workbench/app/views/notifications/_pipelines_notification.html.erb b/apps/workbench/app/views/notifications/_pipelines_notification.html.erb
new file mode 100644
index 0000000..143c1a0
--- /dev/null
+++ b/apps/workbench/app/views/notifications/_pipelines_notification.html.erb
@@ -0,0 +1,7 @@
+  <p><%= image_tag "dax.png", class: "dax" %>
+    Hi, I noticed you haven't run a pipeline yet.  
+    <%= link_to "Click here to learn how to run an Arvados Crunch pipeline.", 
+	"#{Rails.configuration.arvados_docsite}/user/tutorials/tutorial-new-pipeline.html", 
+	style: "font-weight: bold",
+	target: "_blank" %>
+  </p>
diff --git a/apps/workbench/app/views/notifications/_ssh_key_notification.html.erb b/apps/workbench/app/views/notifications/_ssh_key_notification.html.erb
new file mode 100644
index 0000000..b92dfe6
--- /dev/null
+++ b/apps/workbench/app/views/notifications/_ssh_key_notification.html.erb
@@ -0,0 +1,20 @@
+   <%= image_tag "dax.png", class: "dax" %> 
+    <div>
+      Hi, I noticed that you have not yet set up an SSH public key for use with Arvados.  
+      <%= link_to "Click here to learn about SSH keys in Arvados.",
+	  "#{Rails.configuration.arvados_docsite}/user/getting_started/ssh-access.html", 
+	  style: "font-weight: bold",
+	  target: "_blank" %>
+      When you have an SSH key you would like to use, paste the SSH public key
+      in the text box.
+    </div>
+    <%= form_for AuthorizedKey.new, remote: true do |f| %>
+      <div class="row-fluid">
+          <%= hidden_field_tag :return_to, request.original_url %>
+          <%= hidden_field_tag :disable_element, 'input[type=submit]' %>
+          <%= f.text_area :public_key, rows: 4, placeholder: "Paste your public key here", style: "width: 100%" %>
+      </div>
+      <div class="row-fluid" style="padding-top: 0; padding-bottom: 15px">
+          <%= f.submit :Save, value: raw("✓"), class: "btn btn-primary pull-right" %>
+      </div>
+<% end %>
diff --git a/apps/workbench/app/views/users/_home.html.erb b/apps/workbench/app/views/users/_home.html.erb
index 16e8449..688439b 100644
--- a/apps/workbench/app/views/users/_home.html.erb
+++ b/apps/workbench/app/views/users/_home.html.erb
@@ -29,35 +29,6 @@
 
 <div class="container-fluid">
 
-  <div class="span3 pull-right">
-    <br/>
-
-    <div class="well">
-<% if current_user.andand.is_active %>
-  <p>Your account status:<br/>
-    <strong>Active</strong></p>
-<% elsif current_user %>
-      <p>Your account status:<br/>
-	<strong>New / inactive</strong></p>
-      <p>
-	Your account must be activated by an Arvados administrator.  If this
-	is your first time accessing Arvados and would like to request
-	access, or you believe you are seeing the page in error, please 
-	<%= link_to "contact us", Rails.configuration.activation_contact_link %>.  
-	You should receive an email at the address you used to log in when
-	your account is activated.
-      </p>
-      <p>
-	<%= link_to raw('Contact us &#x2709;'),
-	    Rails.configuration.activation_contact_link, class: "btn btn-primary" %></p>
-<% end %>
-    </div>
-
-    <%= render :partial => 'notifications' %>
-  </div>
-  
-  <div class="span8" id="home-tables">
     <%= render :partial => 'tables' %>
-  </div>
 
 </div>
diff --git a/apps/workbench/app/views/users/_notifications.html.erb b/apps/workbench/app/views/users/_notifications.html.erb
index 9b9fc12..0144dd2 100644
--- a/apps/workbench/app/views/users/_notifications.html.erb
+++ b/apps/workbench/app/views/users/_notifications.html.erb
@@ -60,28 +60,13 @@
 <% if @my_pipelines.count == 0 || @showallalerts %>
 <div class="alert alert-info daxalert">
   <button type="button" class="close" data-dismiss="alert">×</button>
-  <p><%= image_tag "dax.png", class: "dax" %>
-    Hi, I noticed you haven't run a pipeline yet.  
-    <%= link_to "Click here to learn how to run an Arvados Crunch pipeline.", 
-	"#{Rails.configuration.arvados_docsite}/user/tutorials/tutorial-new-pipeline.html", 
-	style: "font-weight: bold",
-	target: "_blank" %>
-  </p>
+
 </div>
 <% end %>
 
 <% end %>
 
-<div class="well">
-  <p><strong>Useful links</strong></p>
-  <p><ul>
-      <li><%= link_to "Arvados project page", "http://arvados.org", target: "_blank" %></li>
-      <li><%= link_to "Tutorials and user guide",
-      "#{Rails.configuration.arvados_docsite}/user/", target: "_blank" %></li>
-    </ul>
-  </p>
-</div>
-
+<!--
 <% if current_user.andand.is_active %>
 <div class="well">
   <p><strong>System status</strong></p>
@@ -105,3 +90,4 @@
     </table>
 </div>
 <% end %>
+-->

commit 928aa8a0496f0c6f37579cac821e1048ce6cca96
Author: Peter Amstutz <peter.amstutz at curoverse.com>
Date:   Wed Feb 5 11:54:18 2014 -0500

    Reworked top menu.  Started upgrading to bootstrap 3.

diff --git a/apps/workbench/Gemfile b/apps/workbench/Gemfile
index 49a4888..1fd2d6a 100644
--- a/apps/workbench/Gemfile
+++ b/apps/workbench/Gemfile
@@ -24,9 +24,9 @@ group :assets do
 end
 
 gem 'jquery-rails'
-gem 'twitter-bootstrap-rails'
-gem 'anjlab-bootstrap-rails', '~> 2.3', :require => 'bootstrap-rails'
+gem 'bootstrap-sass', '~> 3.1.0'
 gem 'bootstrap-editable-rails'
+
 gem 'less'
 gem 'less-rails'
 
diff --git a/apps/workbench/Gemfile.lock b/apps/workbench/Gemfile.lock
index 5e53ef1..4526801 100644
--- a/apps/workbench/Gemfile.lock
+++ b/apps/workbench/Gemfile.lock
@@ -30,12 +30,11 @@ GEM
       i18n (~> 0.6, >= 0.6.4)
       multi_json (~> 1.0)
     andand (1.3.3)
-    anjlab-bootstrap-rails (2.3.1.2)
-      railties (>= 3.0)
-      sass (>= 3.2)
     arel (3.0.2)
     bootstrap-editable-rails (0.0.5)
       railties (>= 3.1)
+    bootstrap-sass (3.1.0.1)
+      sass (~> 3.2)
     builder (3.0.4)
     capistrano (2.15.5)
       highline
@@ -140,11 +139,6 @@ GEM
     treetop (1.4.15)
       polyglot
       polyglot (>= 0.3.1)
-    twitter-bootstrap-rails (2.2.8)
-      actionpack (>= 3.1)
-      execjs
-      rails (>= 3.1)
-      railties (>= 3.1)
     tzinfo (0.3.38)
     uglifier (2.3.1)
       execjs (>= 0.3.0)
@@ -156,8 +150,8 @@ PLATFORMS
 DEPENDENCIES
   RedCloth
   andand
-  anjlab-bootstrap-rails (~> 2.3)
   bootstrap-editable-rails
+  bootstrap-sass (~> 3.1.0)
   coffee-rails (~> 3.2.0)
   httpclient
   jquery-rails
@@ -174,5 +168,4 @@ DEPENDENCIES
   sqlite3
   themes_for_rails
   therubyracer
-  twitter-bootstrap-rails
   uglifier (>= 1.0.3)
diff --git a/apps/workbench/app/assets/javascripts/application.js b/apps/workbench/app/assets/javascripts/application.js
index 8bd556b..863776b 100644
--- a/apps/workbench/app/assets/javascripts/application.js
+++ b/apps/workbench/app/assets/javascripts/application.js
@@ -12,7 +12,8 @@
 //
 //= require jquery
 //= require jquery_ujs
-//= require twitter/bootstrap
+//= require bootstrap
+//= require bootstrap/dropdown
 //= require bootstrap-editable
 //= require bootstrap-editable-rails
 //= require_tree .
diff --git a/apps/workbench/app/assets/stylesheets/application.css b/apps/workbench/app/assets/stylesheets/application.css.scss
similarity index 98%
rename from apps/workbench/app/assets/stylesheets/application.css
rename to apps/workbench/app/assets/stylesheets/application.css.scss
index 8c777c8..446f524 100644
--- a/apps/workbench/app/assets/stylesheets/application.css
+++ b/apps/workbench/app/assets/stylesheets/application.css.scss
@@ -9,11 +9,12 @@
  * compiled file, but it's generally better to create a new file per style scope.
  *
  *= require_self
- *= require bootstrap_and_overrides
  *= require bootstrap-editable
  *= require_tree .
  */
 
+ at import "bootstrap";
+
 .contain-align-left {
     text-align: left;
 }
diff --git a/apps/workbench/app/assets/stylesheets/bootstrap_and_overrides.css.less b/apps/workbench/app/assets/stylesheets/bootstrap_and_overrides.css.less
deleted file mode 100644
index 0729ddb..0000000
--- a/apps/workbench/app/assets/stylesheets/bootstrap_and_overrides.css.less
+++ /dev/null
@@ -1,30 +0,0 @@
- at import "twitter/bootstrap/bootstrap";
- at import "twitter/bootstrap/responsive";
-
-// Set the correct sprite paths
- at iconSpritePath: asset-path("twitter/bootstrap/glyphicons-halflings");
- at iconWhiteSpritePath: asset-path("twitter/bootstrap/glyphicons-halflings-white");
-
-// Set the Font Awesome (Font Awesome is default. You can disable by commenting below lines)
- at fontAwesomeEotPath: asset-url("fontawesome-webfont.eot");
- at fontAwesomeEotPath_iefix: asset-url("fontawesome-webfont.eot#iefix");
- at fontAwesomeWoffPath: asset-url("fontawesome-webfont.woff");
- at fontAwesomeTtfPath: asset-url("fontawesome-webfont.ttf");
- at fontAwesomeSvgPath: asset-url("fontawesome-webfont.svg#fontawesomeregular");
-
-// Font Awesome
- at import "fontawesome/font-awesome";
-
-// Glyphicons
-//@import "twitter/bootstrap/sprites.less";
-
-// Your custom LESS stylesheets goes here
-//
-// Since bootstrap was imported above you have access to its mixins which
-// you may use and inherit here
-//
-// If you'd like to override bootstrap's own variables, you can do so here as well
-// See http://twitter.github.com/bootstrap/customize.html#variables for their names and documentation
-//
-// Example:
-// @linkColor: #ff0000;
diff --git a/apps/workbench/app/views/application/_breadcrumbs.html.erb b/apps/workbench/app/views/application/_breadcrumbs.html.erb
index 9929462..e69de29 100644
--- a/apps/workbench/app/views/application/_breadcrumbs.html.erb
+++ b/apps/workbench/app/views/application/_breadcrumbs.html.erb
@@ -1,18 +0,0 @@
-<ul class="nav">
-  <li class="nav-separator">
-    <span><i class="icon-arrow-right"></i></span>
-  </li>
-  <li>
-    <%= link_to(
-        controller.model_class.to_s.pluralize.underscore.gsub('_', ' '),
-        url_for({controller: params[:controller]})) %>
-  </li>
-  <% if params[:action] != 'index' %>
-    <li class="nav-separator">
-      <span><i class="icon-arrow-right"></i></span>
-    </li>
-    <li>
-      <%= render partial: 'breadcrumb_page_name' %>
-    </li>
-  <% end %>
-</ul>
diff --git a/apps/workbench/app/views/layouts/application.html.erb b/apps/workbench/app/views/layouts/application.html.erb
index 5b1e6b2..117db91 100644
--- a/apps/workbench/app/views/layouts/application.html.erb
+++ b/apps/workbench/app/views/layouts/application.html.erb
@@ -4,7 +4,7 @@
   <meta charset="utf-8">
   <title>
     <% if content_for? :page_title %>
-    <%= yield :page_title %> @<%= Rails.configuration.site_name %>
+    <%= yield :page_title %> / <%= Rails.configuration.site_name %>
     <% else %>
     <%= Rails.configuration.site_name %>
     <% end %>
@@ -22,58 +22,52 @@
   <%= yield :js %>
   <% end %>
   <style>
+    <%= yield :css %>
     body > div.container-fluid {
-    padding-top: 60px; /* 60px to make the container go all the way to the
-    bottom of the topbar */
+    padding-top: 70px; /* 70px to make the container go all the way to the bottom of the navbar */
     }
     @media (max-width: 979px) { body { padding-top: 0; } }
-    <%= yield :css %>
+
+    .navbar .nav li.nav-separator > span.glyphicon.glyphicon-arrow-right {
+    padding-top: 1em;
+    }
   </style>
 </head>
 <body>
 
-  <div class="navbar navbar-fixed-top">
-    <div class="navbar-inner">
-      <ul class="nav">
-        <li class="dropdown">
-          <a href="#" class="dropdown-toggle" data-toggle="dropdown" href="/">
-            <b><%= Rails.configuration.site_name rescue Rails.application.class.parent_name %></b>
-          </a>
-          <ul class="dropdown-menu">
-            <li><%= link_to 'Home', root_url %></li>
-            <li class="divider"></li>
-            <li><%= link_to 'Keys', authorized_keys_path %></li>
-            <li><%= link_to 'VMs', virtual_machines_path %></li>
-            <li><%= link_to 'Repositories', repositories_path %></li>
-            <li><%= link_to 'API Tokens', api_client_authorizations_path %></li>
-            <li class="divider"></li>
-            <li><%= link_to 'Jobs', jobs_path %></li>
-            <li><%= link_to 'Pipeline instances', pipeline_instances_path %></li>
-            <li><%= link_to 'Pipeline templates', pipeline_templates_path %></li>
-            <li class="divider"></li>
-            <li><%= link_to 'Collections', collections_path %></li>
-            <li><%= link_to 'Links', links_path %></li>
-            <li><%= link_to 'Humans', humans_path %></li>
-            <li><%= link_to 'Specimens', specimens_path %></li>
-            <li><%= link_to 'Traits', traits_path %></li>
-            <li class="divider"></li>
-            <% if current_user.andand.is_admin %>
-            <li><%= link_to 'Users', users_path %></li>
-            <% end %>
-            <li><%= link_to 'Groups', groups_path %></li>
-            <li><%= link_to 'Compute nodes', nodes_path %></li>
-            <li><%= link_to 'Keep disks', keep_disks_path %></li>
-          </ul>
-        </li>
+  <div class="navbar navbar-default navbar-fixed-top">
+    <div class="container-fluid">
+      <ul class="nav navbar-nav navbar-left">
+        <li><a class="navbar-brand"><%= Rails.configuration.site_name rescue Rails.application.class.parent_name %></a></li>
+        <li class="nav-separator"><span class="glyphicon glyphicon-arrow-right"></span></li>
+        <% if content_for?(:breadcrumbs) %>
+          <%= yield(:breadcrumbs) %>
+        <% else %>
+          <li>
+            <%= link_to(
+                        controller.model_class.to_s.pluralize.underscore.gsub('_', ' '),
+                        url_for({controller: params[:controller]})) %>
+          </li>
+          <% if params[:action] != 'index' %>
+            <li class="nav-separator">
+              <span class="glyphicon glyphicon-arrow-right"></span>
+            </li>
+            <li>
+              <%= render partial: 'breadcrumb_page_name' %>
+            </li>
+          <% end %>
+        <% end %>
       </ul>
-      <%= content_for?(:breadcrumbs) ? yield(:breadcrumbs) : render(partial: 'breadcrumbs') %>
-
-      <ul class="nav pull-right">
+  
+      <ul class="nav navbar-nav navbar-right">
+        <!--
         <li>
           <div class="loading" style="transform: translate(-20px,20px) scale(0.1,0.1); -ms-transform: translate(-20px,20px) scale(0.1,0.1); -webkit-transform: translate(-20px,20px) scale(0.1,0.1); display: none">
             <%= render partial: 'loading' %>
           </div>
         </li>
+        -->
+        <!--
         <li class="dropdown">
           <a href="#" class="dropdown-toggle" data-toggle="dropdown" href="/">
             Help <span class="caret"></span>
@@ -85,9 +79,30 @@
             <li><%= link_to 'Admin guide', "#{Rails.configuration.arvados_docsite}/admin", target: "_blank" %></li>
           </ul>
         </li>
+        -->
+
+        <li class="dropdown">
+          <a href="#" class="dropdown-toggle" data-toggle="dropdown">
+            <span class="glyphicon glyphicon-th-list"></span> (0)<span class="caret"></span>
+          </a>
+        </li>        
+
+        <li class="dropdown">
+          <a href="#" class="dropdown-toggle" data-toggle="dropdown">
+            <span class="glyphicon glyphicon-envelope"></span> (0)<span class="caret"></span>
+          </a>
+        </li>        
+
 	<% if current_user -%>
-          <li><span class="badge badge-info" style="margin: 10px auto 10px; padding-top: 4px; padding-bottom: 4px"><%= current_user.email %></span></li>
-          <li><a href="<%= logout_path %>">Log out</a></li>
+        <li class="dropdown">
+          <a href="#" class="dropdown-toggle" data-toggle="dropdown">
+            <span class="glyphicon glyphicon-user"></span><span class="caret"></span>
+          </a>
+          <ul class="dropdown-menu" role="menu">
+            <li role="presentation" class="dropdown-header"><%= current_user.email %></li>
+            <li role="presentation"><a href="<%= logout_path %>" role="menuitem">Log out</a></li>
+          </ul>
+        </li>
 	<% else -%>
           <li><a href="<%= $arvados_api_client.arvados_login_url(return_to: root_url) %>">Log in</a></li>
 	<% end -%>

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list