mirror of
https://gitlab.com/animath/si/plateforme-corres2math.git
synced 2025-02-06 11:33:00 +00:00
Autocomplete index
This commit is contained in:
parent
df74f499ec
commit
f05d2cca0b
@ -4,16 +4,22 @@ from .models import Participation, Team, Video
|
|||||||
|
|
||||||
|
|
||||||
class TeamIndex(indexes.ModelSearchIndex, indexes.Indexable):
|
class TeamIndex(indexes.ModelSearchIndex, indexes.Indexable):
|
||||||
|
text = indexes.NgramField(document=True, use_template=True)
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
model = Team
|
model = Team
|
||||||
|
|
||||||
|
|
||||||
class ParticipationIndex(indexes.ModelSearchIndex, indexes.Indexable):
|
class ParticipationIndex(indexes.ModelSearchIndex, indexes.Indexable):
|
||||||
|
text = indexes.NgramField(document=True, use_template=True)
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
model = Participation
|
model = Participation
|
||||||
|
|
||||||
|
|
||||||
class VideoIndex(indexes.ModelSearchIndex, indexes.Indexable):
|
class VideoIndex(indexes.ModelSearchIndex, indexes.Indexable):
|
||||||
|
text = indexes.NgramField(document=True, use_template=True)
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
model = Video
|
model = Video
|
||||||
|
|
||||||
|
@ -4,5 +4,7 @@ from .models import Registration
|
|||||||
|
|
||||||
|
|
||||||
class RegistrationIndex(indexes.ModelSearchIndex, indexes.Indexable):
|
class RegistrationIndex(indexes.ModelSearchIndex, indexes.Indexable):
|
||||||
|
text = indexes.NgramField(document=True, use_template=True)
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
model = Registration
|
model = Registration
|
||||||
|
Loading…
x
Reference in New Issue
Block a user