summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMqdd <ahmadmiqdad27@gmail.com>2025-12-18 10:52:43 +0700
committerMqdd <ahmadmiqdad27@gmail.com>2025-12-18 10:52:43 +0700
commit33e6fc960fc3dcdbb77eedbff6239b7763ace468 (patch)
treeb18512997ca69632be80af0dc6b3c3f73ae64de9
parentdcfbed94e24f7bf6fd06bd0404c1424af2a840be (diff)
<Miqdad> fix query
-rw-r--r--indoteknik_custom/models/keywords.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/indoteknik_custom/models/keywords.py b/indoteknik_custom/models/keywords.py
index e0c7705c..69ecdd46 100644
--- a/indoteknik_custom/models/keywords.py
+++ b/indoteknik_custom/models/keywords.py
@@ -83,8 +83,8 @@ class Keywords(models.Model):
JOIN product_public_category_product_template_rel rel
ON rel.product_template_id = pt.id
WHERE
- pp.active = true
- AND COALESCE(pt.product_rating, 0) >= 8
+ COALESCE(pt.product_rating, 0) >= 3
+ AND (pt.unpublished IS FALSE OR pt.unpublished IS NULL)
AND (
pt.name ILIKE %s
OR COALESCE(pt.website_description, '') ILIKE %s