admin: add filter to hide classes with __debug_only__ when Debug is disabled

This commit is contained in:
Jens Langhammer
2020-07-01 18:53:13 +02:00
parent 3b70d12a5f
commit 3478a2cf6d
3 changed files with 11 additions and 7 deletions

View File

@ -16,6 +16,8 @@ class DummyPolicy(Policy):
"""Policy used for debugging the PolicyEngine. Returns a fixed result,
but takes a random time to process."""
__debug_only__ = True
result = models.BooleanField(default=False)
wait_min = models.IntegerField(default=5)
wait_max = models.IntegerField(default=30)