diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 02515d98d0..3985dcc884 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -6,6 +6,7 @@ Changelog * Core templatetags (pageurl, image, wagtailuserbar, etc) are now compatible with Jinja2 * Image and document models now provide a `search` method on their QuerySets + * Search methods now accept an `operator` argument to determine whether multiple terms are ORed or ANDed together * InlinePanel now accepts `max_num` and `min_num` arguments to limit the number of inline items * 'Add' button on inline panels is disabled when `max_num` is reached (Salvador Faria) * WagtailRedirectMiddleware can now ignore the query string if there is no redirect that exactly matches it (Michael Cordover) diff --git a/docs/releases/1.2.rst b/docs/releases/1.2.rst index f728331851..48aa5258cc 100644 --- a/docs/releases/1.2.rst +++ b/docs/releases/1.2.rst @@ -18,12 +18,12 @@ The core templatetags (``pageurl``, ``slugurl``, ``image``, ``richtext`` and ``w See: :doc:`/advanced_topics/jinja2` -Improved search mechanism for images and documents -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +Search API improvements +~~~~~~~~~~~~~~~~~~~~~~~ -Wagtail's image and document models now provide a ``search`` method on their QuerySets, making it easy to perform searches on filtered data sets. +Wagtail's image and document models now provide a ``search`` method on their QuerySets, making it easy to perform searches on filtered data sets. In addition, search methods now accept an ``operator`` keyword argument, to determine whether multiple search terms will be treated as 'or' (any term may match) or 'and' (all terms must match). -See: :ref:`wagtailsearch_images_documents_custom_models` +See: :ref:`wagtailsearch_searching` ``max_num`` and ``min_num`` parameters on inline panels