it/itf/emailer/search_indexes.py
2012-03-28 01:58:28 +05:30

13 lines
315 B
Python
Executable File

from haystack.indexes import *
from haystack import site
from models import EmailerIssue
class EmailerIssueIndex(SearchIndex):
text = CharField(document=True, use_template=True)
title = CharField(model_attr='title')
date = DateField(model_attr='date')
site.register(EmailerIssue, EmailerIssueIndex)