Displaying 1 result from an estimated 1 matches for "renject_render_options".
2006 Feb 07
0
Rendering objects directly via <%= render @some_object %>
...# Include renject functionality to allow object to render itself
include ActionView::Renjects::BaseRenject
# Generate hash to be parsed back to ActionView render method
# The options parameter, which contains the original options hash,
# could optionally be uesd to when generating the hash.
#
def renject_render_options( options = {} )
# Generate the wished for hash
return { :partial => @partial, :locals = {:foo => @foo, :baa => @baa }}
end
attr_writer :partial
attr_writer :foo
attr_writer :baa
end
@some_object = SomeClass
@some_object.partial = ''Partial''
@some_object.foo = ''...