Module: ShopHelper
- Defined in:
- app/helpers/shop_helper.rb
Instance Method Summary collapse
Instance Method Details
#input_currency(amount) ⇒ Object
2 3 4 |
# File 'app/helpers/shop_helper.rb', line 2 def input_currency(amount) number_to_currency(amount, :unit => '', :delimiter => '') end |
#routes_to_js(routes) ⇒ Object
6 7 8 9 10 11 12 |
# File 'app/helpers/shop_helper.rb', line 6 def routes_to_js(routes) js = "ROUTES = new Array;\n" @routes.each do |route| js << "ROUTES[#{route[:name].to_json}] = #{route[:path].to_json}\n" end javascript_tag js end |