Ejemplo n.º 1
0
 def __init__(self, *args, **kwargs):
     super(OutflowForm, self).__init__(*args, **kwargs)
     to_date_widget(self.fields)
     self.fields['send_date'].widget.attrs[
         'onchange'] = 'set_process_state(this)'
     self.fields['content'].widget = SummernoteWidget()
     self.fields['company'].widget = forms.HiddenInput()
Ejemplo n.º 2
0
 def __init__(self, *args, **kwargs):
     super(SymptomForm, self).__init__(*args, **kwargs)
     to_date_widget(self.fields)
     self.fields['content'].widget = SummernoteWidget()
     self.fields['company'].widget = forms.HiddenInput()
     self.fields['event_report_etc'].widget.attrs[
         'placeholder'] = '탐지보고서 선택시'
     self.fields['response_type_etc'].widget.attrs['placeholder'] = '기타 선택시'
     self.fields['product_etc'].widget.attrs['placeholder'] = '기타 선택시'
Ejemplo n.º 3
0
    def __init__(self, *args, **kwargs):
        super(DetectionPatternForm, self).__init__(*args, **kwargs)
        to_date_widget(self.fields)
        self.fields['pattern_name'].widget.attrs['readonly'] = 'true'
        self.fields['content'].widget = SummernoteWidget()
        self.fields['equipment_class'] = forms.ChoiceField(
            widget=forms.RadioSelect,
            choices=get_choices('se_equipment_class', defalut=False))
        self.fields['attack_class'] = forms.ChoiceField(
            widget=forms.RadioSelect(attrs={'onclick': 'set_sub_list(this)'}),
            choices=get_choices('attack_class', defalut=False))

        subs = get_choices('attack_class_sub1') + get_choices(
            'attack_class_sub2', defalut=False) + get_choices(
                'attack_class_sub3', defalut=False) + get_choices(
                    'attack_class_sub4', defalut=False)
        self.fields['attack_type'] = forms.ChoiceField(widget=forms.Select,
                                                       choices=subs)

        self.fields['attack_class_etc'].widget.attrs[
            'placeholder'] = '기타선택시 입력하세요'
        self.fields['attack_type_etc'].widget.attrs[
            'placeholder'] = '기타선택시 입력하세요'
Ejemplo n.º 4
0
 def __init__(self, *args, **kwargs):
     super(NoticeForm, self).__init__(*args, **kwargs)
     to_date_widget(self.fields)
Ejemplo n.º 5
0
 def __init__(self, *args, **kwargs):
     super(InternalForm, self).__init__(*args, **kwargs)
     to_date_widget(self.fields)
Ejemplo n.º 6
0
 def __init__(self, *args, **kwargs):
     super(SecurityForm, self).__init__(*args, **kwargs)
     to_date_widget(self.fields)
Ejemplo n.º 7
0
 def __init__(self, *args, **kwargs):
     super(RansomwarePostForm, self).__init__(*args, **kwargs)
     to_date_widget(self.fields)
     self.fields['send_date'].widget.attrs[
         'onchange'] = 'set_process_state(this)'
     self.fields['company'].widget = forms.HiddenInput()