Integration of pop-up and generic js.erb
This commit is contained in:
1 parent
62aaf79491
commit
245def9cb6
14 files changed
+1613
-54
No files matched your search
@@ -0,0 +1,8 @@
|
||||
var to_render = '';
|
||||
<% if value %>
|
||||
to_render = "<%= escape_javascript(render(:partial => partial, :object => value, :locals => locals)) %>"
|
||||
<% elsif values %>
|
||||
to_render = "<%= escape_javascript(render(:partial => partial, :collection => values, :locals => locals)) %>"
|
||||
<% end %>
|
||||
|
||||
$("#<%= id %>").<%= function %>(to_render);
|
||||
Reference in new issue
Block a user