AutoCommit Fre Aug 21 21:03:01 CEST 2015

This commit is contained in:
Andreas Stephanides
2015-08-21 21:03:01 +02:00
parent c396c7410e
commit bfe65e14e3
6 changed files with 23 additions and 6 deletions

View File

@@ -13,9 +13,9 @@ module AttachmentsHelper
render(partial:"attachments/attachment_list", object: p.attachments, locals: {editor: (can?(:edit, p)), parent: p} )
end
def render_new_attachments_for(p, text, options={})
def render_new_attachments_for(p, text="", options={})
a= Attachment.new
a.parent=p
((can?(:edit, p))? (render partial:"attachments/form_bulk2", object: a ): "")+ link_to(text, new_calentry_path(),options)
((can?(:edit, p))? (render partial:"attachments/form_bulk2", object: a ): "")
end
end