search for: actual_amount_before_type_cast

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

2006 Jun 26
2
text_field weirdness?
I''m storying amounts of money in my database as cents. So I have custom accessors in my model, for example def actual_amount read_attribute("actual_amount").to_f / 100.0 end But when I use <%= text_field ''item'', ''actual_amount'' %> I get, for example, "3600" instead of "36.00". If I ignore the helper, and