Disallow Treasurer to approve claim when already approved

This commit is contained in:
Yingtong Li 2020-02-09 22:18:44 +11:00
parent 16f859cb6e
commit a170d1ea89
Signed by: RunasSudo
GPG Key ID: 7234E476BF21C61A

View File

@ -293,7 +293,7 @@ class ReimbursementClaim(models.Model):
return False
if not user.groups.filter(name='Treasury').exists():
return False
if self.state != ClaimState.PAID.value:
if self.state == ClaimState.DRAFT.value or self.state == ClaimState.RESUBMIT.value or self.state == ClaimState.AWAIT_REVIEW.value:
return True
return False