Skip to content

Instantly share code, notes, and snippets.

@MadanThangavelu
Created February 26, 2012 21:44
Show Gist options
  • Save MadanThangavelu/1919128 to your computer and use it in GitHub Desktop.
Save MadanThangavelu/1919128 to your computer and use it in GitHub Desktop.
haystack-manager-patch
class MySearchIndex1(indexes.SearchIndex, indexes.Indexable):
author = indexes.CharField(model_attr='author')
pub_date = indexes.DateTimeField(model_attr='pub_date')
def get_model(self):
return MockModel
class MySearchIndex2(indexes.SearchIndex, indexes.Indexable):
author = indexes.CharField(model_attr='author')
pub_date = indexes.DateTimeField(model_attr='pub_date')
def get_model(self):
return MockModel
class meta:
index_label='different_connection_name'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment