Fixed item deletion to also respect deleted orders (which should not

exist)
This commit is contained in:
Raphael Michel
2015-08-13 18:32:33 +02:00
parent 699a2ec2ff
commit 63928ab557

View File

@@ -908,7 +908,7 @@ class ItemDelete(EventPermissionRequiredMixin, DeleteView):
return context
def is_allowed(self) -> bool:
return not self.get_object().positions.current.exists()
return not self.get_object().positions.exists()
def get_object(self, queryset=None) -> Property:
if not hasattr(self, 'object') or not self.object: