summaryrefslogtreecommitdiff
path: root/indoteknik_custom/models
diff options
context:
space:
mode:
Diffstat (limited to 'indoteknik_custom/models')
-rwxr-xr-xindoteknik_custom/models/stock_vendor.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/indoteknik_custom/models/stock_vendor.py b/indoteknik_custom/models/stock_vendor.py
index e72748c3..dcbeb399 100755
--- a/indoteknik_custom/models/stock_vendor.py
+++ b/indoteknik_custom/models/stock_vendor.py
@@ -17,12 +17,10 @@ class StockVendor(models.Model):
('done', 'Done')
], string="Cache Reset")
- @api.model
- def get_stock_updated_last_7_days(self, id):
+ def get_stock_updated_last_7_days(self):
date_7_days_ago = datetime.now() - timedelta(days=7)
stocks = self.search([
- ('product_variant_id', '=', id),
('write_date', '>=', date_7_days_ago.strftime("%Y-%m-%d %H:%M:%S"))
], limit=1)