Skip to content

Commit

Permalink
Apply collection nonce to migration/person
Browse files Browse the repository at this point in the history
  • Loading branch information
abartov committed Dec 24, 2024
1 parent e15c64a commit 73f6558
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/controllers/collections_migration_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def person
RefreshUncollectedWorksCollection.call(@author)
prep_toc
@top_nodes = GenerateTocTree.call(@author)

@nonce = 'top'
end

def create_collection
Expand Down
2 changes: 1 addition & 1 deletion app/views/collections_migration/person.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@
data: {collection: { collection_type: item_type, title: new_title}, authority: { id: #{@author.id } , role: $('#role').val()}},
success: function(data) {
$('#newcoll_section').hide();
$('html, body').animate({scrollTop: $('##{nonce}_coll_container_'+data.collection_id).offset().top + $('##{nonce}_coll_container_'+data.collection_id).outerHeight() - $('header').height() - 180}, 500);
$('html, body').animate({scrollTop: $('##{@nonce}_coll_container_'+data.collection_id).offset().top + $('##{@nonce}_coll_container_'+data.collection_id).outerHeight() - $('header').height() - 180}, 500);
}
});
});
Expand Down

0 comments on commit 73f6558

Please sign in to comment.