X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/a800aed41550a1a0c5a9ecee08105149db1b9362..faf89f7e200e69dca019cf530e121d08ac06f105:/apps/workbench/app/models/collection.rb diff --git a/apps/workbench/app/models/collection.rb b/apps/workbench/app/models/collection.rb index 87a083e24b..686b816c08 100644 --- a/apps/workbench/app/models/collection.rb +++ b/apps/workbench/app/models/collection.rb @@ -66,12 +66,8 @@ class Collection < ArvadosBase dir_to_tree.call('.') end - def attribute_editable? attr, *args - if %w(name description manifest_text).include? attr.to_s - true - else - super - end + def editable_attributes + %w(name description manifest_text) end def self.creatable? @@ -94,20 +90,8 @@ class Collection < ArvadosBase end end - def portable_data_hash - if self[:portable_data_hash].nil? - return self[:uuid] - else - super - end - end - def friendly_link_name lookup=nil - if self.respond_to? :name - self.name - else - self.portable_data_hash - end + name || portable_data_hash end def textile_attributes