X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/7df2da959b583d3646b9fde606f9e74d598d4bb9..91fe76f4a3f8e5f59d12343ae69d2ba5a43d8e55:/apps/workbench/app/models/job.rb diff --git a/apps/workbench/app/models/job.rb b/apps/workbench/app/models/job.rb index c853302c1a..9e9c096787 100644 --- a/apps/workbench/app/models/job.rb +++ b/apps/workbench/app/models/job.rb @@ -1,5 +1,5 @@ class Job < ArvadosBase - def self.goes_in_folders? + def self.goes_in_projects? true end @@ -8,7 +8,11 @@ class Job < ArvadosBase end def attribute_editable? attr, *args - false + if attr.to_sym == :description + super && attr.to_sym == :description + else + false + end end def self.creatable? @@ -29,4 +33,12 @@ class Job < ArvadosBase x += " submitted #{created_at.strftime('%b %-d')}" end end + + def cancel + arvados_api_client.api "jobs/#{self.uuid}/", "cancel", {} + end + + def textile_attributes + [ 'description' ] + end end