diff options
| author | Mqdd <ahmadmiqdad27@gmail.com> | 2026-02-23 10:39:48 +0700 |
|---|---|---|
| committer | Mqdd <ahmadmiqdad27@gmail.com> | 2026-02-23 10:39:48 +0700 |
| commit | 18bdbf118d2f582ac0c520a9b4cc5b61fe88488f (patch) | |
| tree | 0f8daf76fde494a5d2efb34fac2eacf7a2dad295 /indoteknik_custom/models | |
| parent | 345d45f5fae0f152ca39e9ba491513582a5c6791 (diff) | |
<Miqdad> show date maturity in line & remove old keywords code
Diffstat (limited to 'indoteknik_custom/models')
| -rw-r--r-- | indoteknik_custom/models/keywords.py | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/indoteknik_custom/models/keywords.py b/indoteknik_custom/models/keywords.py index 2ee217f7..3fa9dd72 100644 --- a/indoteknik_custom/models/keywords.py +++ b/indoteknik_custom/models/keywords.py @@ -160,37 +160,6 @@ class Keywords(models.Model): return True - # Old - # def _sync_keywords_queue_callback(self): - # """Callback method executed by apache.solr.queue - syncs keyword data to Solr""" - # documents = [] - # for keyword in self: - # # Skip syncing if product count is 0 - # if len(keyword.product_ids) == 0: - # _logger.info('Skipping Solr sync for keyword "%s" - no products found', keyword.keywords) - # continue - - # searchkey = (keyword.keywords or '').strip().lower().replace(' ', '-') - # try: - # doc = { - # 'id': keyword.id, - # 'category_id_i': keyword.category_id.id, - # 'keywords_s': searchkey, - # 'url_s': keyword.url, - # 'product_ids_is': [p.product_tmpl_id.id for p in keyword.product_ids], - # } - # documents.append(doc) - # except Exception as e: - # _logger.error('failed %s', e) - # _logger.error('doc data: %s', doc) - - # if documents: - # solr.add(documents) - - # self.write({'solr_flag': 0}) - - # return True - def _sync_keywords_queue_callback(self): success_keywords = self.browse() |
