Commit 4f963d49 by François C.

Add lost part of code during merge_requests/169 (shelfs/models.py)

parent c63a256a
Pipeline #2200 failed with stage
in 1 minute 29 seconds
......@@ -182,6 +182,18 @@ class Shelf(models.Model):
res['error'] = "L'enregistrement n'a pas pu se réaliser"
return res
def update_last_product_added_date(self):
res = {}
today = date.today().strftime("%Y-%m-%d")
f = {'date_last_product_added': today}
try:
res["update"] = self.o_api.update('product.shelfs', self.id, f)
except Exception as e:
res['error'] = str(e)
return res
def set_begin_inventory_datetime(self):
res = {}
now = datetime.now().isoformat()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment