From 9325315fe657d53970eec9542ec055b5c16eda1f Mon Sep 17 00:00:00 2001 From: Andreas Zeidler Date: Fri, 4 Sep 2020 17:51:22 +0200 Subject: [PATCH 1/2] Also strip `/base_edit` or `/atct_edit` MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Otherwise the loaded results will be the edit view itself, which is then injected and starts loading more results, which will be the edit view again and so on and so on… a.k.a. edit view inception! :) --- archetypes/querywidget/querywidget.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/archetypes/querywidget/querywidget.js b/archetypes/querywidget/querywidget.js index 1bb6940..b8c3975 100644 --- a/archetypes/querywidget/querywidget.js +++ b/archetypes/querywidget/querywidget.js @@ -157,7 +157,7 @@ $.querywidget.updateSearch = function () { var base_url = $("base").attr("href"); - base_url = base_url.replace(/\/edit$/, ''); + base_url = base_url.replace(/\/[a-z_]*edit$/, ''); if (base_url.indexOf("portal_factory") !== -1) { base_url = base_url.split("/").slice(0, -2).join("/"); } From 901e3b3349ffa70601b12fe861adc9f95b325c57 Mon Sep 17 00:00:00 2001 From: Andreas Zeidler Date: Fri, 4 Sep 2020 17:56:50 +0200 Subject: [PATCH 2/2] Add change log entry for 9325315f --- CHANGES.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGES.rst b/CHANGES.rst index ea7bed4..2ce10ec 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -14,7 +14,7 @@ New features: Bug fixes: -- *add item here* +- Also strip `/base_edit` or `/atct_edit` when fetching query results 1.1.3 (2016-08-12)