Skip to content

Commit

Permalink
Added description field to indexes as a stored field
Browse files Browse the repository at this point in the history
  • Loading branch information
notanumber committed Aug 11, 2010
1 parent 5f9b42c commit d3b75c7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ def handle(self, *args, **options):
page.description = meta.get('content', '')
else:
page.description = ''
page.language = soup.html.get('lang') # TODO: Discuss how to do this for multilang
page.language = soup.html.get('lang')
page.content = soup.prettify()
page.save()
count += 1
Expand Down
1 change: 1 addition & 0 deletions haystack_static_pages/search_indexes.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ class StaticPageIndex(indexes.SearchIndex):
title = indexes.CharField(model_attr='title')
url = indexes.CharField(model_attr='url')
content = indexes.CharField(model_attr='content')
description = indexes.CharField(model_attr='description')
language = indexes.CharField(model_attr='language')


Expand Down

0 comments on commit d3b75c7

Please sign in to comment.