I am trying to chain a calendaer_date_select to a select field, so the select list is filtered by the choosen date. I have followed the instructions as described here
I have in the activescaffold config:
config.columns[:order_date].form_ui = :calendar_date_select
config.columns[:order_date].options = {:update_column => :sale}
config.columns[:sale].form_ui = :select
... and in the helper:
def options_for_association_conditions(association)
if association.name == :sale
{'sales.order_date' => @record.order_date}
else
super
end
end
The problem is that picking a date from the javascript widget thingy doesn't trigger the select to refresh. However if I type in the date then it does. Any ideas?