diff options
Diffstat (limited to 'yaksh/forms.py')
-rw-r--r-- | yaksh/forms.py | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/yaksh/forms.py b/yaksh/forms.py index 7d5362b..c0f40ea 100644 --- a/yaksh/forms.py +++ b/yaksh/forms.py @@ -49,6 +49,12 @@ test_case_types = ( ("floattestcase", "Float Testcase"), ) +status_types = ( + ('select','Select Status'), + ('active', 'Active'), + ('closed', 'Inactive'), + ) + UNAME_CHARS = letters + "._" + digits PWD_CHARS = letters + punctuation + digits @@ -377,6 +383,19 @@ class QuestionFilterForm(forms.Form): ) +class SearchFilterForm(forms.Form): + search_tags = forms.CharField( + label='Search Tags', + widget=forms.TextInput(attrs={'placeholder': 'Search', + 'class': form_input_class,}), + required=False + ) + search_status = forms.CharField(max_length=16, widget=forms.Select( + choices=status_types, + attrs={'class': 'custom-select'}), + ) + + class CourseForm(forms.ModelForm): """ course form for moderators """ class Meta: |