projects
/
arvados.git
/ blobdiff
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
4523: Merge branch '4523-search-index' of git.curoverse.com:arvados into 4523-search...
[arvados.git]
/
apps
/
workbench
/
app
/
controllers
/
collections_controller.rb
diff --git
a/apps/workbench/app/controllers/collections_controller.rb
b/apps/workbench/app/controllers/collections_controller.rb
index 39f637e2274d5ac12037363c8051fd17b63d5d9e..f4aa0395f3d273a2948f3415be6ad4bfaf539673 100644
(file)
--- a/
apps/workbench/app/controllers/collections_controller.rb
+++ b/
apps/workbench/app/controllers/collections_controller.rb
@@
-14,7
+14,9
@@
class CollectionsController < ApplicationController
RELATION_LIMIT = 5
def show_pane_list
RELATION_LIMIT = 5
def show_pane_list
- %w(Files Provenance_graph Used_by Advanced)
+ panes = %w(Files Upload Provenance_graph Used_by Advanced)
+ panes = panes - %w(Upload) unless (@object.editable? rescue false)
+ panes
end
def set_persistent
end
def set_persistent
@@
-233,10
+235,7
@@
class CollectionsController < ApplicationController
def sharing_popup
@search_sharing = search_scopes
def sharing_popup
@search_sharing = search_scopes
- respond_to do |format|
- format.html
- format.js
- end
+ render("sharing_popup.js", content_type: "text/javascript")
end
helper_method :download_link
end
helper_method :download_link
@@
-246,18
+245,15
@@
class CollectionsController < ApplicationController
end
def share
end
def share
- a = ApiClientAuthorization.create(scopes: sharing_scopes)
- @search_sharing = search_scopes
- render 'sharing_popup'
+ ApiClientAuthorization.create(scopes: sharing_scopes)
+ sharing_popup
end
def unshare
end
def unshare
- @search_sharing = search_scopes
- @search_sharing.each do |s|
+ search_scopes.each do |s|
s.destroy
end
s.destroy
end
- @search_sharing = search_scopes
- render 'sharing_popup'
+ sharing_popup
end
protected
end
protected