Allow courrier to delete item in order
This commit is contained in:
parent
5e2d5e659c
commit
cff24dc096
1 changed files with 1 additions and 1 deletions
|
@ -49,6 +49,6 @@ class OrderItem(db.Model):
|
|||
if user_id is None:
|
||||
return False
|
||||
user = User.query.filter(User.id == user_id).first()
|
||||
if user and user.is_admin():
|
||||
if user and (user.is_admin() or user == self.order.courrier):
|
||||
return True
|
||||
return False
|
||||
|
|
Loading…
Reference in a new issue