1
0
mirror of https://gitlab.com/animath/si/plateforme-corres2math.git synced 2024-12-05 02:06:52 +00:00

Autocomplete index

This commit is contained in:
Yohann D'ANELLO 2020-10-15 17:26:22 +02:00
parent df74f499ec
commit f05d2cca0b
2 changed files with 8 additions and 0 deletions

View File

@ -4,16 +4,22 @@ from .models import Participation, Team, Video
class TeamIndex(indexes.ModelSearchIndex, indexes.Indexable):
text = indexes.NgramField(document=True, use_template=True)
class Meta:
model = Team
class ParticipationIndex(indexes.ModelSearchIndex, indexes.Indexable):
text = indexes.NgramField(document=True, use_template=True)
class Meta:
model = Participation
class VideoIndex(indexes.ModelSearchIndex, indexes.Indexable):
text = indexes.NgramField(document=True, use_template=True)
class Meta:
model = Video

View File

@ -4,5 +4,7 @@ from .models import Registration
class RegistrationIndex(indexes.ModelSearchIndex, indexes.Indexable):
text = indexes.NgramField(document=True, use_template=True)
class Meta:
model = Registration