Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Advanced Search does not work correctly with multiple categories #38

Open
rpremuz opened this issue Nov 1, 2018 · 1 comment
Open

Comments

@rpremuz
Copy link

rpremuz commented Nov 1, 2018

In <<AdvancedSearch>> macro (used on FindPage) you can select multiple categories (with Ctrl + click). In case of such a selection I would expect that the user wants to search pages that have all of the selected categories.

Currently (MoinMoin 1.9.10), if you select categories CategoryCat1 and CategoryCat2, the macro creates search query that includes the following expression:
category:CategoryCat1,CategoryCat2
which does not return expected result.

Instead, the search query should include the following expression:
(category:CategoryCat1 category:CategoryCat2)
which correctly finds pages that have both categories. I tested this by using the expression in the MoinMoin default search field (top right).

Could someone improve the macro to work correctly with multiple categories selected? I had a look at MoinMoin/macro/AdvancedSearch.py but my knowledge of Python is not sufficient to make necessary changes.

@ThomasWaldmann ThomasWaldmann changed the title Advanced Search does not work correctly with mulptiple categories Advanced Search does not work correctly with multiple categories Jul 22, 2019
@ThomasWaldmann
Copy link
Member

IIRC I had a quick look once, but it didn't look easy to solve.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants