Procházet zdrojové kódy

Allowing upc and score fields to be null for search index

master
Dawid Lorenz před 14 roky
rodič
revize
efa0dedff2
1 změnil soubory, kde provedl 2 přidání a 2 odebrání
  1. 2
    2
      oscar/apps/search/abstract_indexes.py

+ 2
- 2
oscar/apps/search/abstract_indexes.py Zobrazit soubor

@@ -10,8 +10,8 @@ class AbstractProductIndex(SearchIndex):
10 10
     own copy of oscar.search_indexes.py
11 11
     """
12 12
     text = EdgeNgramField(document=True, use_template=True, template_name='search/indexes/product/item_text.txt')
13
-    title = EdgeNgramField(model_attr='title')
14
-    upc = CharField(model_attr="upc")
13
+    title = EdgeNgramField(model_attr='title', null=True)
14
+    upc = CharField(model_attr="upc", null=True)
15 15
     score = FloatField(model_attr="score")
16 16
     date_created = DateTimeField(model_attr='date_created')
17 17
     date_updated = DateTimeField(model_attr='date_updated')

Načítá se…
Zrušit
Uložit