mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-08-02 16:02:15 +02:00
updated changes
This commit is contained in:
parent
61236b07b4
commit
3dab617ff1
1 changed files with 5 additions and 7 deletions
|
@ -317,7 +317,8 @@ class DomainRenewalView(DomainBaseView):
|
|||
template_name = "domain_renewal.html"
|
||||
|
||||
def get_context_data(self, **kwargs):
|
||||
"""Grabbing security email information for the renewal form"""
|
||||
"""Grabs the security email information and adds security_email to the renewal form context
|
||||
sets it to None if it uses a default email"""
|
||||
|
||||
context = super().get_context_data(**kwargs)
|
||||
|
||||
|
@ -334,16 +335,13 @@ class DomainRenewalView(DomainBaseView):
|
|||
|
||||
def in_editable_state(self, pk):
|
||||
"""Override in_editable_state from DomainPermission
|
||||
Allow renewal form to be accessed"""
|
||||
|
||||
Allow renewal form to be accessed
|
||||
returns boolean"""
|
||||
requested_domain = None
|
||||
if Domain.objects.filter(id=pk).exists():
|
||||
requested_domain = Domain.objects.get(id=pk)
|
||||
|
||||
if requested_domain and (requested_domain.is_expiring() or requested_domain.is_expired()):
|
||||
return True
|
||||
|
||||
return False
|
||||
return requested_domain and requested_domain.is_editable() and (requested_domain.is_expiring() or requested_domain.is_expired())
|
||||
|
||||
def post(self, request, pk):
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue