-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This had some out of date references which was causing the full text search to miss bills like in #388. closes #388
- Loading branch information
Showing
4 changed files
with
41 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
from django.core.management.base import BaseCommand | ||
from chicago.models import ChicagoBill | ||
from chicago.search_indexes import BillIndex | ||
import pprint | ||
|
||
|
||
class Command(BaseCommand): | ||
"""A simple management command which clears the site-wide cache.""" | ||
|
||
help = "Preview the text template that will be used in the search." | ||
|
||
def add_arguments(self, parser): | ||
parser.add_argument( | ||
"identifier", | ||
help=( | ||
"The identifier of the bill to preview" | ||
), | ||
) | ||
|
||
|
||
|
||
def handle(self, *args, **kwargs): | ||
|
||
|
||
|
||
|
||
b = ChicagoBill.objects.get(identifier=kwargs['identifier']) | ||
|
||
self.stdout.write(pprint.pformat(BillIndex().prepare(b), indent=4)) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters