Sha256: bdf40585192bb088c24a5ee7143bf0d956734991273cb6adabf08d04937993e1
Contents?: true
Size: 446 Bytes
Versions: 33
Compression:
Stored size: 446 Bytes
Contents
class AdminCurrencyInput < SimpleForm::Inputs::Base include ActionView::Helpers::NumberHelper include AdminBaseInput def input default_input_html_options = {class: 'money', value: number_with_precision(@builder.object.send(attribute_name), separator: ",", precision: 2) } options = merge_options(default_input_html_options, input_html_options) return "#{@builder.text_field(attribute_name, options)}".html_safe end end
Version data entries
33 entries across 33 versions & 1 rubygems