summaryrefslogtreecommitdiff
path: root/indoteknik_custom/models/product_template.py
diff options
context:
space:
mode:
Diffstat (limited to 'indoteknik_custom/models/product_template.py')
-rwxr-xr-xindoteknik_custom/models/product_template.py7
1 files changed, 3 insertions, 4 deletions
diff --git a/indoteknik_custom/models/product_template.py b/indoteknik_custom/models/product_template.py
index ef0ead1b..74b4edb1 100755
--- a/indoteknik_custom/models/product_template.py
+++ b/indoteknik_custom/models/product_template.py
@@ -57,7 +57,6 @@ class ProductTemplate(models.Model):
current_time = datetime.now()
delta_time = current_time - timedelta(days=30)
- #current_time = current_time.strftime('%Y-%m-%d %H:%M:%S')
delta_time = delta_time.strftime('%Y-%m-%d %H:%M:%S')
products = self.env['product.template'].search([
@@ -65,7 +64,7 @@ class ProductTemplate(models.Model):
('active', '=', True),
('product_rating', '>', 3),
('create_date', '>=', delta_time),
- ], limit=1000)
+ ], limit=100)
seq = 0
for product in products:
@@ -146,7 +145,7 @@ class ProductTemplate(models.Model):
('active', '=', True),
('last_calculate_rating', '=', False),
# ('id', '=', 22798),
- ], limit=10000)
+ ], limit=100)
for product in products:
# print("Calculate Rating Product ", product)
@@ -171,7 +170,7 @@ class ProductTemplate(models.Model):
('type', '=', 'product'),
('active', '=', True),
('last_calculate_rating', '<', delta_time),
- ], limit=10000)
+ ], limit=100)
for product in products:
print("Calculate Rating Product OutOfDate", product)