Sha256: 17f0dacb845f69050001db5a72a160b66a68df55ccd16a339c366970fcb6ef42

Contents?: true

Size: 622 Bytes

Versions: 79

Compression:

Stored size: 622 Bytes

Contents

InlineForms::SPECIAL_COLUMN_TYPES[:geo_code_curacao]=:string

# geo_code_curacao
def geo_code_curacao_show(object, attribute)
  attribute_value = object.send(attribute)._presentation rescue nil
  link_to_inline_edit object, attribute, attribute_value
end
def geo_code_curacao_edit(object, attribute)
  text_field_with_auto_complete :geo_code_curacao, :street, :skip_style => true
end
def geo_code_curacao_update(object, attribute)
  # extract the geocode
  geo_code = params[attribute.to_sym][:street].scan(/\d\d\d\d\d\d/).to_s || nil
  object[attribute.to_sym] = GeoCodeCuracao.new(geo_code).valid? ? geo_code : nil
end

Version data entries

79 entries across 79 versions & 1 rubygems

Version Path
inline_forms-1.2.7 lib/app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.2.5 lib/app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.2.4 lib/app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.2.3 lib/app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.2.2 lib/app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.2.1 lib/app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.2.0 lib/app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.1.20 lib/app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.1.19 lib/app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.1.18 lib/app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.1.17 lib/app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.1.16 lib/app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.1.15 lib/app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.1.13 app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.1.12 app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.1.11 app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.1.10 app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.1.9 app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.1.8 app/helpers/form_elements/geo_code_curacao.rb
inline_forms-1.1.7 app/helpers/form_elements/geo_code_curacao.rb