more stuff for not applying changesets when they have problems
This commit is contained in:
parent
ad252bf6c6
commit
a88f8cea34
3 changed files with 7 additions and 3 deletions
|
@ -167,7 +167,7 @@ class ChangeSet(models.Model):
|
|||
return self.can_edit(request) and self.state == 'unproposed'
|
||||
|
||||
def can_propose(self, request):
|
||||
return self.can_edit(request) and not self.proposed and self.changes
|
||||
return self.can_edit(request) and not self.proposed and self.changes and not self.problems.any
|
||||
|
||||
def can_unpropose(self, request):
|
||||
return self.author_id == request.user.pk and self.state in ('proposed', 'reproposed')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue