-
Notifications
You must be signed in to change notification settings - Fork 2
Description
Upon selecting object types and pressing the “Convert” button the page gets stuck. It seems to be stuck showing the backdrop for a modal, but the modal is not visible.
Before pressing the button
After pressing the button
There is nothing the browser console. And no network requests. I ended up using the browser debugger and tracked it down to the ATFAttachmentsToFiles class.
It seems like it is the code inside migrationPrompt()
function migrationPrompt(){
var byIdCheckbox = document.getElementById('byIdCheckbox').checked;
var byObjectIdCheckbox = document.getElementById('byObjectIdCheckbox').checked;
var byObjectCheckbox = document.getElementById('byObjectCheckbox').checked;
if(byIdCheckbox){
j$('#promptMigrateById').show();
j$( "#modalMigrateById" ).toggleClass( "slds-backdrop--close" );
j$( "#modalMigrateById" ).toggleClass( "slds-backdrop--open" );
}
if(byObjectIdCheckbox){
j$('#promptMigrateByObjectId').show();
j$( "#modalMigrateByObjectId" ).toggleClass( "slds-backdrop--close" );
j$( "#modalMigrateByObjectId" ).toggleClass( "slds-backdrop--open" );
}
if(byObjectCheckbox){
j$('#promptMigrateByObject').show();
j$( "#modalMigrateByObject" ).toggleClass( "slds-backdrop--close" );
j$( "#modalMigrateByObject" ).toggleClass( "slds-backdrop--open" );
}
}
specifically the issue is the the .show() calls are insufficient for displaying the modals. The modals have the slds-hide class, and slds-hide applies "display: none !important;". jQuery's .show() only applies "display: block;", which is not enough since the slds-hide's directive is !important.
I see this is a known issue in both the Community Group and AppExchange reviews
Hopefully this bug report is detailed enough to help you resolve the issue. I think it should be as simply as replacing j$('#promptMigrateByObject').show(); with j$('#promptMigrateByObject').toggleClass("slds-hide"); (and the same for the .hide() calls).