Fix "select all" long task threw an error and didn't complete

Progressbar was not found because the load event was never fired from the dialog.
This commit is contained in:
nathan 2022-08-26 09:28:33 -06:00
parent 6d38f22949
commit 23977d6c21

View File

@ -697,11 +697,14 @@ export class et2_dataview_selectionManager
width: 300 width: 300
}); });
(this._context._widget.getDOMNode() || document.body).appendChild(dialog); (this._context._widget.getDOMNode() || document.body).appendChild(dialog);
dialog.addEventListener('load', function() dialog.updateComplete.then(() =>
{
dialog.template.DOMContainer.addEventListener('load', function()
{ {
// Get access to template widgets // Get access to template widgets
progressbar = dialog.template.widgetContainer.getWidgetById('progressbar'); progressbar = dialog.template.widgetContainer.getWidgetById('progressbar');
}); });
});
for(var i = 0; i < queryRanges.length; i++) for(var i = 0; i < queryRanges.length; i++)
{ {