The Artima Developer Community
Sponsored Link

Ruby Buzz Forum
In Place Editor and Collection Partials

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
Amos King

Posts: 78
Nickname: adkron
Registered: Jan, 2007

Amos King is a Web Developer for the US Postal Service and for Ramped Media.
In Place Editor and Collection Partials Posted: Sep 2, 2007 12:49 PM
Reply to this message Reply

This post originated from an RSS feed registered with Ruby Buzz by Amos King.
Original Post: In Place Editor and Collection Partials
Feed Title: DirtyInformation
Feed URL: http://feeds.feedburner.com/Dirtyinformation
Feed Description: Information about Ruby/Rails/JRuby/WebDevelpoment/whatever.
Latest Ruby Buzz Posts
Latest Ruby Buzz Posts by Amos King
Latest Posts From DirtyInformation

Advertisement

I've noticed a lot of individuals have been having problems with the in_place_editor function and using a collection partial. The problem comes down to an in_place_editor looking for an variable beginning with an @. So here is the quick fix.


The partial function:

<%= render :partial => "item", :collection => @items %>


Inside the Partial:

>%@item = item%<
>%= in_place_editor_field :item, 'on_hand' %>

I know it is a bit of a hack, but it is a very quick fix. Happy Coding!

Read: In Place Editor and Collection Partials

Topic: Vlad 1.1 is approaching, the heavens sing and send us a sign Previous Topic   Next Topic Topic: Rails Development Performance Tip - dev_mode_performance_fixes

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use