Fixup some string escaping issues in the data browser

This commit is contained in:
Tom Hughes 2011-09-30 14:30:59 +01:00
parent 3f9fdb122c
commit 607d23f6d6
8 changed files with 20 additions and 15 deletions

View file

@ -4,7 +4,12 @@ module BrowseHelper
end
def printable_name(object, version=false)
name = t 'printable_name.with_id', :id => object.id.to_s
if object.id.is_a?(Array)
id = object.id[0]
else
id = object.id
end
name = t 'printable_name.with_id', :id => id.to_s
if version
name = t 'printable_name.with_version', :id => name, :version => object.version.to_s
end