networks: I18N for static IP configuration

This commit is contained in:
Sunil Mohan Adapa 2015-12-09 12:20:37 +05:30
parent 1a1faa8a1b
commit d1b20ac113

View File

@ -59,8 +59,8 @@ available over this interfaces. Select Internal only for trusted networks.'),
choices=[('external', 'External'), ('internal', 'Internal')])
ipv4_method = forms.ChoiceField(
label=_('IPv4 Addressing Method'),
help_text='"Shared" will start a DHCP Server, "Automatic" will \
start a DHCP client.',
help_text=_('"Shared" method will start a DHCP server and "Automatic" '
'method will acquire configuration from a DHCP server.'),
choices=[('auto', 'Automatic (DHCP)'),
('shared', 'Shared'),
('manual', 'Manual')])
@ -70,27 +70,27 @@ available over this interfaces. Select Internal only for trusted networks.'),
required=False)
ipv4_netmask = forms.CharField(
label=_('Netmask'),
help_text='Optional value. If not given the default netmask \
(associated with the address) will be used',
help_text=_('Optional value. If left blank, a default netmask '
'based on the address will be used.'),
validators=[validators.validate_ipv4_address],
required=False)
ipv4_gateway = forms.CharField(
label=_('Gateway'),
help_text='Optional value.',
help_text=_('Optional value.'),
validators=[validators.validate_ipv4_address],
required=False)
ipv4_dns = forms.CharField(
label=_('DNS Server'),
help_text='Optional value. If this value is given and IPv4 \
Addressing Method is DHCP, the DNS Servers from DHCP Server \
will be ignored.',
help_text=_('Optional value. If this value is given and IPv4 '
'addressing method is "Automatic", the DNS Servers '
'provided by a DHCP server will be ignored.'),
validators=[validators.validate_ipv4_address],
required=False)
ipv4_second_dns = forms.CharField(
label=_('Second DNS Server'),
help_text='Optional value. If this value is given and IPv4 \
Addressing Method is DHCP, the DNS Servers from DHCP Server \
will be ignored.',
help_text=_('Optional value. If this value is given and IPv4 '
'Addressing Method is "Automatic", the DNS Servers '
'provided by a DHCP server will be ignored.'),
validators=[validators.validate_ipv4_address],
required=False)
@ -172,23 +172,27 @@ Point.'))
required=False)
ipv4_netmask = forms.CharField(
label=_('Netmask'),
help_text='Optional value. If not given the default netmask \
(associated with the address) will be used',
help_text=_('Optional value. If left blank, a default netmask '
'based on the address will be used.'),
validators=[validators.validate_ipv4_address],
required=False)
ipv4_gateway = forms.CharField(
label=_('Gateway'),
help_text='Optional value.',
help_text=_('Optional value.'),
validators=[validators.validate_ipv4_address],
required=False)
ipv4_dns = forms.CharField(
label=_('DNS Server'),
help_text='Optional value.',
help_text=_('Optional value. If this value is given and IPv4 '
'addressing method is "Automatic", the DNS Servers '
'provided by a DHCP server will be ignored.'),
validators=[validators.validate_ipv4_address],
required=False)
ipv4_second_dns = forms.CharField(
label=_('Second DNS Server'),
help_text='Optional value.',
help_text=_('Optional value. If this value is given and IPv4 '
'Addressing Method is "Automatic", the DNS Servers '
'provided by a DHCP server will be ignored.'),
validators=[validators.validate_ipv4_address],
required=False)