Hi Ofek

You have to bind change events with js on those fields and disable/enable 
submit button. Active scaffold adds a class with column name to each input 
([column_name]-input) which you can use to bind events to. For example with 
jQuery:

$(document).on('change', '.column-input', function {
  if (...) {
    $(this).closest('form').find('.submit').prop('disabled', true);
  }
});

El 12/06/2018 19:29, Ofek Inbar <[email protected]> escribió:
>
> Hi, I'm new to ActiveScaffold and Rails in general and I was navigating 
> through the documentation but I couldn't seem to find a solution to my issue.
> I want to disable submission of an edit/create form if certain fields don't 
> meet certain conditions (simply disabling the "Update" button will do).
> Can anybody help me find a solution?
>
> -- 
> You received this message because you are subscribed to the Google Groups 
> "ActiveScaffold : Ruby on Rails Gem" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at https://groups.google.com/group/activescaffold.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"ActiveScaffold : Ruby on Rails Gem" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/activescaffold.
For more options, visit https://groups.google.com/d/optout.
  • Disable submission Ofek Inbar
    • Re: Disable su... 'Sergio Cambra' via ActiveScaffold : Ruby on Rails Gem

Reply via email to