diff options
author | Aamir Khan <syst3m.w0rm@gmail.com> | 2012-06-26 23:59:54 -0400 |
---|---|---|
committer | Aamir Khan <syst3m.w0rm@gmail.com> | 2012-06-26 23:59:54 -0400 |
commit | c64b4fe35c7a01143c6d98cc4589d3b8298c54c3 (patch) | |
tree | ac6ccad3c285629b86b2bbd07f776272fb0b09c8 /views/forms.py | |
parent | a412cadc23541f4ed3005190e6e9632d86219fad (diff) | |
download | hyperkitty-c64b4fe35c7a01143c6d98cc4589d3b8298c54c3.tar.gz hyperkitty-c64b4fe35c7a01143c6d98cc4589d3b8298c54c3.tar.xz hyperkitty-c64b4fe35c7a01143c6d98cc4589d3b8298c54c3.zip |
code refactoring: two new view files added
Diffstat (limited to 'views/forms.py')
-rw-r--r-- | views/forms.py | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/views/forms.py b/views/forms.py new file mode 100644 index 0000000..a2aac0e --- /dev/null +++ b/views/forms.py @@ -0,0 +1,27 @@ +from django import forms + +class AddTagForm(forms.Form): + tag = forms.CharField(label='', help_text=None, + widget=forms.TextInput( + attrs={'placeholder': 'Add a tag...'} + ) + ) + from_url = forms.CharField(widget=forms.HiddenInput, required=False) + +class SearchForm(forms.Form): + target = forms.CharField(label='', help_text=None, + widget=forms.Select( + choices=(('Subject', 'Subject'), + ('Content', 'Content'), + ('SubjectContent', 'Subject & Content'), + ('From', 'From')) + ) + ) + + keyword = forms.CharField(max_length=100,label='', help_text=None, + widget=forms.TextInput( + attrs={'placeholder': 'Search this list.'} + ) + ) + + |