Skip to content

Commit

Permalink
Merge pull request #16 from witsch/edit-urls
Browse files Browse the repository at this point in the history
Also strip `/base_edit` or `/atct_edit` when fetching query results
  • Loading branch information
mauritsvanrees authored Sep 7, 2020
2 parents 55b4c3e + 901e3b3 commit c25b729
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down
2 changes: 1 addition & 1 deletion archetypes/querywidget/querywidget.js
Original file line number Diff line number Diff line change
Expand Up @@ -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("/");
}
Expand Down

0 comments on commit c25b729

Please sign in to comment.