diff --git a/app/models/document.rb b/app/models/document.rb index 414772ea..fc5d15dd 100644 --- a/app/models/document.rb +++ b/app/models/document.rb @@ -21,7 +21,7 @@ class Document < ActiveRecord::Base acts_as_attachable :delete_permission => :manage_documents acts_as_journalized :event_title => Proc.new {|o| "#{l(:label_document)}: #{o.title}"}, - :event_url => Proc.new {|o| {:controller => 'documents', :action => 'show', :id => o.id} }, + :event_url => Proc.new {|o| {:controller => 'documents', :action => 'show', :id => o.versioned_id}}, :event_author => (Proc.new do |o| o.attachments.find(:first, :order => "#{Attachment.table_name}.created_on ASC").try(:author) end)