From ecbfc738bf09f1982ddbf43df833d3fbd1464ff3 Mon Sep 17 00:00:00 2001 From: Michael Elkins Date: Fri, 16 Nov 2012 00:08:22 +0000 Subject: add "autofocus=true" to the text boxes for entering ASNs and prefixes see #344 svn path=/trunk/; revision=4881 --- rpkid/rpki/gui/app/forms.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'rpkid/rpki/gui/app/forms.py') diff --git a/rpkid/rpki/gui/app/forms.py b/rpkid/rpki/gui/app/forms.py index 2dfbb6a5..9fdad55f 100644 --- a/rpkid/rpki/gui/app/forms.py +++ b/rpkid/rpki/gui/app/forms.py @@ -286,7 +286,11 @@ def AddASNForm(child): """ class _wrapped(forms.Form): - asns = forms.CharField(label='ASNs', help_text='single ASN or range') + asns = forms.CharField( + label='ASNs', + help_text='single ASN or range', + widget=forms.TextInput(attrs={'autofocus': 'true'}) + ) def clean_asns(self): try: @@ -319,7 +323,10 @@ def AddNetForm(child): """ class _wrapped(forms.Form): - address_range = forms.CharField(help_text='CIDR or range') + address_range = forms.CharField( + help_text='CIDR or range', + widget=forms.TextInput(attrs={'autofocus': 'true'}) + ) def clean_address_range(self): address_range = self.cleaned_data.get('address_range') -- cgit v1.2.3