search for: grain_kind

Displaying 1 result from an estimated 1 matches for "grain_kind".

2006 Jun 13
0
Best way to format attributes during visualization/editing
...1 => liquid ... To visualize the verbose representation I''ve overridden the default attribute''s accessor as follows: def kind() VERBOSE.index(read_attribute(:kind)) end This works like a charm. Now in my editing/inserting view i have this: <p><label for="grain_kind">Select Kind</label><br/> <%= select("grain", "kind", Grain::KINDS, { :include_blank => true}) %></p> This piece of code doesn''t work because it tries to call the "kind" method of the "grain" object. Normally it...