mirror of
https://github.com/ae-utbm/sith.git
synced 2025-09-14 12:05:44 +00:00
feat: automatic product archiving
This commit is contained in:
@@ -445,7 +445,8 @@ class Product(models.Model):
|
||||
buying_groups = list(self.buying_groups.all())
|
||||
if not buying_groups:
|
||||
return True
|
||||
return any(user.is_in_group(pk=group.id) for group in buying_groups)
|
||||
res = any(user.is_in_group(pk=group.id) for group in buying_groups)
|
||||
return res
|
||||
|
||||
@property
|
||||
def profit(self):
|
||||
|
Reference in New Issue
Block a user