From 6745c597553aca9da4520aec8a0532a91cf1ed85 Mon Sep 17 00:00:00 2001 From: labkey-tchad Date: Mon, 9 Nov 2026 15:03:01 -0800 Subject: [PATCH 1/5] Cancel a combo box's pending type-ahead when it is destroyed --- api/webapp/extPatches/ext4-patches.js | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/api/webapp/extPatches/ext4-patches.js b/api/webapp/extPatches/ext4-patches.js index a81239777c8..90630c8ca2c 100644 --- a/api/webapp/extPatches/ext4-patches.js +++ b/api/webapp/extPatches/ext4-patches.js @@ -243,6 +243,20 @@ Ext4.override(Ext4.form.FieldContainer, { getLabelableRenderData: Ext4.form.field.Base.prototype.getLabelableRenderData }); +/** + * @Override + * A pending type-ahead fires after destroy and throws on the unbound store. + * Version: 4.2.1 + */ +Ext4.override(Ext4.form.field.ComboBox, { + onDestroy: function() { + if (this.typeAheadTask) { + this.typeAheadTask.cancel(); + } + this.callParent(arguments); + } +}); + /** * @Override * Sencha Issue: http://www.sencha.com/forum/showthread.php?269116-Ext-4.2.1.883-Sandbox-getRowStyleTableEl From 703dd47b3f4bcc1fa5e0c01d76d4c562e848c578 Mon Sep 17 00:00:00 2001 From: labkey-tchad Date: Mon, 9 Nov 2026 18:47:30 -0800 Subject: [PATCH 2/5] Clear stale errors when reapplying an authentication configuration --- .../client/components/DynamicConfigurationModal.tsx | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/core/src/client/components/DynamicConfigurationModal.tsx b/core/src/client/components/DynamicConfigurationModal.tsx index 323b9b0d345..9c9b67ea6cc 100644 --- a/core/src/client/components/DynamicConfigurationModal.tsx +++ b/core/src/client/components/DynamicConfigurationModal.tsx @@ -61,6 +61,7 @@ export default class DynamicConfigurationModal extends PureComponent { const { modalType, authConfig, configType, closeModal, updateAuthRowsAfterSave } = this.props; + this.setState({ errorMessage: '' }); if (this.areRequiredFieldsEmpty()) { return; } @@ -98,6 +99,7 @@ export default class DynamicConfigurationModal extends PureComponent { // Issue 50964: Save incomplete disabled authentication configurations if (!this.state.fieldValues.enabled) { + this.setState({ emptyRequiredFields: [] }); return false; } @@ -110,12 +112,8 @@ export default class DynamicConfigurationModal extends PureComponent this.state.fieldValues[name] == ''); - if (emptyRequiredFields.length > 0) { - this.setState({ emptyRequiredFields }); - return true; - } else { - return false; - } + this.setState({ emptyRequiredFields }); + return emptyRequiredFields.length > 0; }; onToggle = (): void => { From 3aa3a7eb8ad310645f48a274674e6facbb296ef2 Mon Sep 17 00:00:00 2001 From: labkey-tchad Date: Tue, 10 Nov 2026 13:45:34 -0800 Subject: [PATCH 3/5] Revert "Cancel a combo box's pending type-ahead when it is destroyed" This reverts commit 6745c597553aca9da4520aec8a0532a91cf1ed85. --- api/webapp/extPatches/ext4-patches.js | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/api/webapp/extPatches/ext4-patches.js b/api/webapp/extPatches/ext4-patches.js index 90630c8ca2c..a81239777c8 100644 --- a/api/webapp/extPatches/ext4-patches.js +++ b/api/webapp/extPatches/ext4-patches.js @@ -243,20 +243,6 @@ Ext4.override(Ext4.form.FieldContainer, { getLabelableRenderData: Ext4.form.field.Base.prototype.getLabelableRenderData }); -/** - * @Override - * A pending type-ahead fires after destroy and throws on the unbound store. - * Version: 4.2.1 - */ -Ext4.override(Ext4.form.field.ComboBox, { - onDestroy: function() { - if (this.typeAheadTask) { - this.typeAheadTask.cancel(); - } - this.callParent(arguments); - } -}); - /** * @Override * Sencha Issue: http://www.sencha.com/forum/showthread.php?269116-Ext-4.2.1.883-Sandbox-getRowStyleTableEl From b393df7fa00457f9a9c267bfd646164fdd0fe257 Mon Sep 17 00:00:00 2001 From: Josh Eckels Date: Fri, 6 Nov 2026 15:18:44 -0800 Subject: [PATCH 4/5] Ignore deferred combo work after an Ext4 combo is destroyed (#8286) ## Rationale Destroying an Ext4 combo while it still has deferred work pending throws a client-side error, because Ext 4.2.1 nulls the combo's store on destroy but lets its delayed type-ahead, delayed query, and remote load callback run afterward. Any combo can hit this; the EHR Apply Template window does when Submit is clicked right after picking a template, which made TNPRC_RequestsTest fail intermittently. Fixing it in the shared Ext4 patches covers every combo, including the duplicated ONPRC template window, instead of patching one window. ## Related Pull Requests - https://github.com/LabKey/tnprcEHRModules/pull/455 - https://github.com/LabKey/wnprc-modules/pull/1072 - https://github.com/LabKey/testAutomation/pull/3274 ## Changes - Skip a combo's delayed type-ahead, delayed query, and query completion once the combo has been destroyed ## Tasks - [x] Claude Code Review - [x] Manual Testing - N/A - [x] Test Automation - N/A - this is a test fix (cherry picked from commit cb674560c219ebf735c335d8b275dc6f8afc5ab2) --- api/webapp/extPatches/ext4-patches.js | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/api/webapp/extPatches/ext4-patches.js b/api/webapp/extPatches/ext4-patches.js index a81239777c8..65d74603c89 100644 --- a/api/webapp/extPatches/ext4-patches.js +++ b/api/webapp/extPatches/ext4-patches.js @@ -446,6 +446,24 @@ Ext4.override(Ext4.data.Store, { } }); +/** + * Delayed query/type-ahead tasks and remote load callbacks can fire after onDestroy has nulled the store. Avoid throwing by checking if destroyed. + */ +Ext4.override(Ext4.form.field.ComboBox, { + doRawQuery: function() { + if (!this.isDestroyed) + this.callParent(arguments); + }, + onTypeAhead: function() { + if (!this.isDestroyed) + this.callParent(arguments); + }, + afterQuery: function() { + if (!this.isDestroyed) + this.callParent(arguments); + } +}); + /** * RowExpander plugin is not properly configured to handle sandboxed ExtJS. */ From e1611ca3a0a827f42ce0d8db105593dfab652502 Mon Sep 17 00:00:00 2001 From: labkey-tchad Date: Wed, 11 Nov 2026 15:26:57 -0800 Subject: [PATCH 5/5] GH Issue 1793: Cancel a destroyed combo box's pending query and type-ahead --- api/webapp/extPatches/ext4-patches.js | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/api/webapp/extPatches/ext4-patches.js b/api/webapp/extPatches/ext4-patches.js index 65d74603c89..5cff5a9cf32 100644 --- a/api/webapp/extPatches/ext4-patches.js +++ b/api/webapp/extPatches/ext4-patches.js @@ -447,16 +447,15 @@ Ext4.override(Ext4.data.Store, { }); /** - * Delayed query/type-ahead tasks and remote load callbacks can fire after onDestroy has nulled the store. Avoid throwing by checking if destroyed. + * Delayed query/type-ahead tasks and remote load callbacks can fire after onDestroy has nulled the store. + * Cancel the tasks on destroy; a remote load's callback isn't a task, so guard it. */ Ext4.override(Ext4.form.field.ComboBox, { - doRawQuery: function() { - if (!this.isDestroyed) - this.callParent(arguments); - }, - onTypeAhead: function() { - if (!this.isDestroyed) - this.callParent(arguments); + onDestroy: function() { + this.doQueryTask.cancel(); + if (this.typeAheadTask) + this.typeAheadTask.cancel(); + this.callParent(arguments); }, afterQuery: function() { if (!this.isDestroyed)