George Notaras avatar George Notaras committed a8bfc90

Added AxfrImportForm.

Comments (0)

Files changed (1)

src/powerdns_manager/forms.py

     overwrite = forms.BooleanField(required=False, label=_('Overwrite'), help_text="""If checked, existing zone will be replaced by this one. Proceed with caution.""")
 
 
+class AxfrImportForm(forms.Form):
+    """This form is used to import zone data from AXFR responses through the
+    ``import_axfr_view``.
+    
+    """
+    origin = forms.CharField(max_length=128, initial='', required=True, label=_('Origin'), help_text="""Enter the domain name to import.""")
+    nameserver = forms.GenericIPAddressField(protocol='both', required=True, label=_('Nameserver IP'), help_text="""Enter the IP address (IPv4 or IPv6 of the nameserver that contains zone information.""")
+    overwrite = forms.BooleanField(required=False, label=_('Overwrite'), help_text="""If checked, existing zone will be replaced by this one. Proceed with caution.""")
+
 
 class DynamicIPUpdateForm(forms.Form):
     """This form is used to validate the supplied data in the POST request.
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.