Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion frontend/assets/user_defined_in_basic.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ UserDefinedInBasic.prototype.init = function(fields, read_only_view, hide_user_d
var user_defined_section = $('section.subrecord-form[data-object-name="user_defined"]');
var remove_btn = user_defined_section.find('.subrecord-form-remove');
if (remove_btn.length == 0) {
user_defined_section.find('.btn-default').filter(':visible').click();
user_defined_section.find('.btn-default').filter(':visible').trigger('click');
window.scrollTo(0,0);
}

Expand Down
6 changes: 4 additions & 2 deletions frontend/views/layout_head.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,14 @@ end
}

// For Resource record updates
$(document).bind("loadedrecordform.aspace", init);
$(document).on("loadedrecordform.aspace", init);

// For everything else
// had to bind this call to window load because a bare call to init()
// was causing Firefox to jump the gun ... javascript, sheesh
$(window).load(init);
$(window).on('load', function(){
init
})

</script>

Expand Down