mirror of
https://github.com/Hopiu/wagtail.git
synced 2026-05-05 14:04:46 +00:00
fix whitespace
This commit is contained in:
parent
1aa0285bf4
commit
8374ec4df7
1 changed files with 9 additions and 9 deletions
|
|
@ -159,16 +159,16 @@ Callables also provide a way to index fields from related models. In the example
|
|||
.. code-block:: python
|
||||
|
||||
class BookPage(Page):
|
||||
...
|
||||
|
||||
def get_related_link_titles(self):
|
||||
# Get list of titles and concatenate them
|
||||
return '\n'.join(self.related_links.values_list('title', flat=True))
|
||||
|
||||
search_fields = Page.search_fields + [
|
||||
...
|
||||
index.SearchField('get_related_link_titles'),
|
||||
]
|
||||
|
||||
def get_related_link_titles(self):
|
||||
# Get list of titles and concatenate them
|
||||
return '\n'.join(self.related_links.values_list('title', flat=True))
|
||||
|
||||
search_fields = Page.search_fields + [
|
||||
...
|
||||
index.SearchField('get_related_link_titles'),
|
||||
]
|
||||
|
||||
.. _wagtailsearch_indexing_models:
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue