2809: Merge branch 'master' into 2809-workbench-rails4 refs #2809
[arvados.git] / apps / workbench / app / models / collection.rb
index 6cd4315eaeaad913e6150d7c1aa314030f026ea3..6022d82433ec843a1aff509d619c964608259b84 100644 (file)
@@ -1,4 +1,5 @@
 class Collection < ArvadosBase
+  include ApplicationHelper
 
   MD5_EMPTY = 'd41d8cd98f00b204e9800998ecf8427e'
 
@@ -7,6 +8,10 @@ class Collection < ArvadosBase
     !!locator.to_s.match("^#{MD5_EMPTY}(\\+.*)?\$")
   end
 
+  def content_summary
+    human_readable_bytes_html(total_bytes) + " " + super
+  end
+
   def total_bytes
     if files
       tot = 0