I have some RJS that could use some refactoring. I use the function
called with afterFinish twice and Im wondering what the best way to
refactor is. This is all inline rjs in the controller mind you:
page.visual_effect :slide_down, "add_appt_#{params
[:day]}", :afterFinish => "function(){
$('end_drop_#{params[:day]}_#{params
[:appt_counter]}').style.display = 'block';
$('end_drop_#{params[:day]}_#{params
[:appt_counter]}').style.visibility = 'hidden';
$('start_drop_#{params[:day]}_#{params
[:appt_counter]}').style.display = 'block';
$('start_drop_#{params[:day]}_#{params
[:appt_counter]}').style.visibility = 'hidden';
}"
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---