summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--indoteknik_custom/models/website_user_cart.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/indoteknik_custom/models/website_user_cart.py b/indoteknik_custom/models/website_user_cart.py
index ad97a029..dd3f87e6 100644
--- a/indoteknik_custom/models/website_user_cart.py
+++ b/indoteknik_custom/models/website_user_cart.py
@@ -131,13 +131,13 @@ class WebsiteUserCart(models.Model):
return result
def action_mail_reminder_to_checkout(self):
- # user_ids = self.search([]).mapped('user_id')
+ user_ids = self.search([]).mapped('user_id')
- user_ids = [1102]
+ # user_ids = [1102]
for user in user_ids:
- latest_cart = self.search([('user_id', '=', user), ('is_reminder', '=', False)], order='create_date desc', limit=1)
+ latest_cart = self.search([('user_id', '=', user.id), ('is_reminder', '=', False)], order='create_date desc', limit=1)
- carts_to_remind = self.search([('user_id', '=', user)])
+ carts_to_remind = self.search([('user_id', '=', user.id)])
if latest_cart and not latest_cart.is_reminder:
for cart in carts_to_remind:
check = cart.check_product_flashsale(cart.product_id.id)