PiRSquared17 / activescaffold

Automatically exported from code.google.com/p/activescaffold
MIT License
0 stars 0 forks source link

Lost number formatting on calculation columns #740

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I've just update ActiveScaffold from a version dated 2010-02-06 to the
latest (2010-03-26)

I see that the part of frontends/default/views/_list_calculations.html.erb
has been broken out to a new function called render_column_calculation() in
lib/active_scaffold/helpers/view_helpers.rb 

I had a column setup as follows:

    config.columns[:chassis_profit].options[:format] = :currency
    config.columns[:chassis_profit].calculate = :sum

... and the calculation column used to also get correctly formatted. This
has now been lost.

Kind Regards

Original issue reported on code.google.com by ruinenl...@gmail.com on 28 Mar 2010 at 3:24

GoogleCodeExporter commented 9 years ago
The change only moved some code from view to a helper. I have reverted that 
change
and I can't get calculation formatted using options[:format]. Anyway I have 
added
that feature to master branch.

Original comment by sergio.c...@gmail.com on 29 Mar 2010 at 8:08