How to Re-index Form Objects on solr?
# Open Python Shell & Execute
# Importing Model
from axonator.models import FormObject
# To index all form objects
for formobject in FormObject.objects.filter():
formobject.index_on_solr()
# To index all form objects of a form
for formobject in FormObject.objects.filter(form_id=FORMID):
formobject.index_on_solr()
# To index all form objects of a app
for formobject in FormObject.objects.filter(form_app_app_id=APP_ID, form_app_version=APP_VERSION):
formobject.index_on_solr()
0 Comments