[ARVADOS] updated: 1c0e350af2a30f4627ad879545c9c6fc6554d92a

git at public.curoverse.com git at public.curoverse.com
Wed Nov 5 23:34:16 EST 2014


Summary of changes:
 apps/workbench/app/assets/javascripts/select_modal.js  |  6 ++++++
 apps/workbench/app/assets/javascripts/selection.js.erb |  3 ++-
 apps/workbench/app/views/layouts/body.html.erb         | 13 -------------
 3 files changed, 8 insertions(+), 14 deletions(-)

       via  1c0e350af2a30f4627ad879545c9c6fc6554d92a (commit)
      from  81bfa2fd57ee5e4b0042d418115f0e50170ee5eb (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit 1c0e350af2a30f4627ad879545c9c6fc6554d92a
Author: radhika <radhika at curoverse.com>
Date:   Wed Nov 5 23:33:21 2014 -0500

    3177: restrict only one file selection in collection chooser; remove clippy; clear selections on load.

diff --git a/apps/workbench/app/assets/javascripts/select_modal.js b/apps/workbench/app/assets/javascripts/select_modal.js
index 36c145f..d840377 100644
--- a/apps/workbench/app/assets/javascripts/select_modal.js
+++ b/apps/workbench/app/assets/javascripts/select_modal.js
@@ -35,8 +35,14 @@ $(document).on('click', '.selectable', function() {
             });
     }
 }).on('click', '.persistent-selection', function() {
+    var checked_status = this.checked;
     var $modal = $(this).closest('.modal');
     $checked_selections = $modal.find('.persistent-selection:checked');
+
+    if (checked_status && ($checked_selections.length > 1)) {
+      $(this).prop('checked', false);
+    }
+
     any = ($checked_selections.length > 0);
     $(this).
         closest('.modal').
diff --git a/apps/workbench/app/assets/javascripts/selection.js.erb b/apps/workbench/app/assets/javascripts/selection.js.erb
index 59e6425..38f3f4a 100644
--- a/apps/workbench/app/assets/javascripts/selection.js.erb
+++ b/apps/workbench/app/assets/javascripts/selection.js.erb
@@ -108,7 +108,8 @@ jQuery(function($){
             }
         });
 
-    $(window).on('load storage', update_count);
+    $(window).on('load', clear_selections);
+    $(window).on('storage', update_count);
 
     $('#selection-form-content').on("click", function(e) {
         e.stopPropagation();
diff --git a/apps/workbench/app/views/layouts/body.html.erb b/apps/workbench/app/views/layouts/body.html.erb
index 3fc0c92..9e966e1 100644
--- a/apps/workbench/app/views/layouts/body.html.erb
+++ b/apps/workbench/app/views/layouts/body.html.erb
@@ -67,19 +67,6 @@
               </ul>
             </li>
 
-            <li class="dropdown selection-menu">
-              <a href="#" class="dropdown-toggle" data-toggle="dropdown">
-                <span class="fa fa-lg fa-paperclip"></span>
-                <span class="badge" id="persistent-selection-count"></span>
-              </a>
-              <ul class="dropdown-menu" role="menu" id="persistent-selection-list">
-                <%= form_tag '/actions' do %>
-                  <%= hidden_field_tag 'uuid', @object.andand.uuid %>
-                  <div id="selection-form-content"></div>
-                <% end %>
-              </ul>
-            </li>
-
             <% if current_user.is_admin %>
               <li class="dropdown">
                 <a href="#" class="dropdown-toggle" data-toggle="dropdown" id="system-menu">

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


hooks/post-receive
-- 




More information about the arvados-commits mailing list