forked from CGM_Public/pretix_original
Added setting to disable order cancelling for users
This commit is contained in:
@@ -227,6 +227,10 @@ class Order(LoggedModel):
|
||||
|
||||
return False # nothing there to modify
|
||||
|
||||
@property
|
||||
def can_user_cancel(self) -> bool:
|
||||
return self.event.settings.cancel_allow_user
|
||||
|
||||
@property
|
||||
def is_expired_by_time(self):
|
||||
return (
|
||||
|
||||
@@ -121,6 +121,10 @@ DEFAULTS = {
|
||||
'default': None,
|
||||
'type': datetime
|
||||
},
|
||||
'cancel_allow_user': {
|
||||
'default': 'True',
|
||||
'type': bool
|
||||
},
|
||||
'contact_mail': {
|
||||
'default': None,
|
||||
'type': str
|
||||
|
||||
Reference in New Issue
Block a user