Closed bbenezech closed 8 years ago
@bbenezech please add me in skype - "igorkasyanchuk" if you want. I really like what you are making and found issues you have found and your solutions. I think we can discuss them and plan fixes together if you want.
SimpleForm fallbacks on custom types named after field's type.
For ex. a jsonb field would need an app/inputs/jsonb_input.rb
file:
class JsonbInput < SimpleForm::Inputs::TextInput; end
It works fine with a limited hassle.
Hello again,
Simple form doesn't support all field types. For example jsonb columns will raise
The way you handle it is your call. I guess I would default to text. Not sure how.
Catching around
form.input name, label: name
and retrying withas: :text
looks dirty, maybe you can try to toy around SimpleForm API to see if they expose smtg than can help you infind_mapping
.Unless you want to go with user-faced config hooks, but I sure wouldn't!