Fix js for news quick_edit and edit for files
This commit is contained in:
parent
6a4abc6c43
commit
4c4929c20a
|
@ -11,7 +11,7 @@ $('.news_bulletin_files_block a.delete').live('click', function(){
|
||||||
|
|
||||||
$(document).on('click', '.action a.remove_existing_record', function(){
|
$(document).on('click', '.action a.remove_existing_record', function(){
|
||||||
$(this).next('.should_destroy').attr('value', 1);
|
$(this).next('.should_destroy').attr('value', 1);
|
||||||
$("tr #" + $(this).prev().attr('value')).hide();
|
$("tr#" + $(this).prev().attr('value')).hide();
|
||||||
});
|
});
|
||||||
|
|
||||||
$(document).on('click', '.quick_edit_cancel', function(){
|
$(document).on('click', '.quick_edit_cancel', function(){
|
||||||
|
|
|
@ -62,6 +62,7 @@
|
||||||
<a class="delete"><i class="icon-remove"></i></a>
|
<a class="delete"><i class="icon-remove"></i></a>
|
||||||
<% else %>
|
<% else %>
|
||||||
<%= f.hidden_field :id %>
|
<%= f.hidden_field :id %>
|
||||||
|
<%= hidden_field_tag :tr, (dom_id form_news_bulletin_file) %>
|
||||||
<a class="remove_existing_record"><i class="icon-remove"></i></a>
|
<a class="remove_existing_record"><i class="icon-remove"></i></a>
|
||||||
<%= f.hidden_field :should_destroy, :value => nil, :class => 'should_destroy' %>
|
<%= f.hidden_field :should_destroy, :value => nil, :class => 'should_destroy' %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
Reference in New Issue