本文整理匯總了Python中mkt.extensions.models.Extension.get_indexer方法的典型用法代碼示例。如果您正苦於以下問題:Python Extension.get_indexer方法的具體用法?Python Extension.get_indexer怎麽用?Python Extension.get_indexer使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類mkt.extensions.models.Extension
的用法示例。
在下文中一共展示了Extension.get_indexer方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: tearDown
# 需要導入模塊: from mkt.extensions.models import Extension [as 別名]
# 或者: from mkt.extensions.models.Extension import get_indexer [as 別名]
def tearDown(self):
for o in Webapp.objects.all():
o.delete()
for o in Extension.objects.all():
o.delete()
super(TestMultiSearchView, self).tearDown()
# Make sure to delete and unindex *all* things. Normally we wouldn't
# care about stray deleted content staying in the index, but they can
# have an impact on relevancy scoring so we need to make sure. This
# needs to happen after super() has been called since it'll process the
# indexing tasks that should happen post_request, and we need to wait
# for ES to have done everything before continuing.
Webapp.get_indexer().unindexer(_all=True)
Extension.get_indexer().unindexer(_all=True)
HomescreenIndexer.unindexer(_all=True)
self.refresh(('webapp', 'extension', 'homescreen'))
示例2: tearDown
# 需要導入模塊: from mkt.extensions.models import Extension [as 別名]
# 或者: from mkt.extensions.models.Extension import get_indexer [as 別名]
def tearDown(self):
Extension.get_indexer().unindexer(_all=True)
super(TestExtensionSearchView, self).tearDown()
示例3: setUp
# 需要導入模塊: from mkt.extensions.models import Extension [as 別名]
# 或者: from mkt.extensions.models.Extension import get_indexer [as 別名]
def setUp(self):
self.indexer = Extension.get_indexer()()