Commit 08d0f902715fa90a8cc61c1da404d4b5c73b99af
1 parent
4ebcbe31
Exists in
theme-brasil-digital-from-staging
and in
9 other branches
Fix 'more files' button in upload files view
Showing
1 changed file
with
1 additions
and
3 deletions
Show diff stats
app/helpers/cms_helper.rb
| ... | ... | @@ -10,9 +10,7 @@ module CmsHelper |
| 10 | 10 | end |
| 11 | 11 | |
| 12 | 12 | def add_upload_file_field(name, locals) |
| 13 | - button_to_function :add, name, nil do |page| | |
| 14 | - page.insert_html :bottom, :uploaded_files, CGI::escapeHTML(render(:partial => 'upload_file', :locals => locals, :object => UploadedFile.new)) | |
| 15 | - end | |
| 13 | + button_to_function :add, name, ("jQuery('#uploaded_files').append(jQuery('#uploaded_files>p').last().clone())") | |
| 16 | 14 | end |
| 17 | 15 | |
| 18 | 16 | def pagination_links(collection, options={}) | ... | ... |