From 9727960eb95ad2eb4d50f285beb2f969ab81ff9f Mon Sep 17 00:00:00 2001 From: Johannes Meyer Date: Thu, 1 Jun 2023 12:50:09 +0200 Subject: [PATCH] Completer.js: Don't reset upon autosubmits fixes #152 --- asset/js/widget/Completer.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/asset/js/widget/Completer.js b/asset/js/widget/Completer.js index aba54cd2..d03006ce 100644 --- a/asset/js/widget/Completer.js +++ b/asset/js/widget/Completer.js @@ -324,8 +324,10 @@ define(["../notjQuery"], function ($) { */ onSubmit(event) { - // Reset all states, the user is about to navigate away - this.reset(); + if (! event.detail || ! event.detail.submittedBy) { + // Reset all states, the user is about to navigate away + this.reset(); + } } onFocusOut(event) {