Converted the Membership rate form to an Ajax remote form.

* Changed the form_for to be a remote_form_for
* Changed the url to use the js format
* Added RJS to add the Saved rate to the rate cell
* Added id to the table cell so the rate cell can be replaced on success
* Added an Error RJS to flash an error message

  #1921
This commit is contained in:
Eric Davis committed 2009-01-20 16:37:23 -08:00
1 parent 7930144e8c
commit 363e8c0c5a
4 files changed
+18 -4

No files matched your search

+2
View File
@@ -0,0 +1,2 @@
element = 'rate_' + @rate.project_id.to_s
page.replace_html element, "<strong>#{link_to number_to_currency(@rate.amount), { :action => 'edit', :id => @rate.user, :tab => 'rates'} }</strong>"