Project

General

Profile

render_on and rjs

Added by Lluís Gili over 14 years ago

I am trying to use render_on method with :view_journals_notes_form_after_notes hook, but it doesn't work, I supose because it is into an rjs template.

in my hook:

  # this works
  def view_journals_notes_form_after_notes(context={})
    fields = l(:field_material)
    fields += text_area_tag(...)
    fields
  end

  # this doesn't
  render_on :view_journals_notes_form_after_notes, :partial => 'fields'

I was wondering if there's any way to render a template in view_journals_notes_form_after_notes hook

log says:

Rendered journals/_fields (3.8ms)
Rendered journals/_notes_form (11.9ms)

but browser doesn't update the page