Blocks
hypha.apply.funds.blocks
¶
ApplicationSingleIncludeFieldBlock
¶
Bases: SingleIncludeBlock
Source code in hypha/apply/utils/blocks.py
ApplicationMustIncludeFieldBlock
¶
Bases: MustIncludeFieldBlock
Source code in hypha/apply/utils/blocks.py
TitleBlock
¶
Bases: ApplicationMustIncludeFieldBlock
Source code in hypha/apply/utils/blocks.py
help_link
class-attribute
instance-attribute
¶
field_label
class-attribute
instance-attribute
¶
field_label = CharBlock(label=gettext_lazy('Label'), default=gettext_lazy('What is the title of your application?'))
help_text
class-attribute
instance-attribute
¶
help_text = TextBlock(required=False, label=gettext_lazy('Help text'), default=gettext_lazy('This project name can be changed if a full proposal is requested.'))
Meta
¶
get_slug
¶
get_field_class
¶
get_widget
¶
get_field_kwargs
¶
get_field
¶
decode
¶
serialize
¶
serialize_no_response
¶
prepare_data
¶
render
¶
Source code in hypha/apply/stream_forms/blocks.py
get_searchable_content
¶
ValueBlock
¶
Bases: ApplicationSingleIncludeFieldBlock
Source code in hypha/apply/utils/blocks.py
field_label
class-attribute
instance-attribute
¶
help_text
class-attribute
instance-attribute
¶
help_link
class-attribute
instance-attribute
¶
required
class-attribute
instance-attribute
¶
Meta
¶
get_slug
¶
get_field_class
¶
get_widget
¶
get_field_kwargs
¶
Source code in hypha/apply/stream_forms/blocks.py
get_field
¶
decode
¶
serialize
¶
serialize_no_response
¶
render
¶
Source code in hypha/apply/stream_forms/blocks.py
get_searchable_content
¶
no_response
¶
OrganizationNameBlock
¶
Bases: ApplicationSingleIncludeFieldBlock
Source code in hypha/apply/utils/blocks.py
field_label
class-attribute
instance-attribute
¶
help_text
class-attribute
instance-attribute
¶
help_link
class-attribute
instance-attribute
¶
required
class-attribute
instance-attribute
¶
get_slug
¶
get_field_class
¶
get_widget
¶
get_field_kwargs
¶
Source code in hypha/apply/stream_forms/blocks.py
get_field
¶
decode
¶
serialize
¶
serialize_no_response
¶
prepare_data
¶
render
¶
Source code in hypha/apply/stream_forms/blocks.py
get_searchable_content
¶
EmailBlock
¶
Bases: ApplicationMustIncludeFieldBlock
Source code in hypha/apply/utils/blocks.py
help_link
class-attribute
instance-attribute
¶
field_label
class-attribute
instance-attribute
¶
field_label = CharBlock(label=gettext_lazy('Label'), default=gettext_lazy('What email address should we use to contact you?'))
help_text
class-attribute
instance-attribute
¶
help_text = TextBlock(required=False, label=gettext_lazy('Help text'), default=gettext_lazy('We will use this email address to communicate with you about your proposal.'))
get_slug
¶
get_field_class
¶
get_widget
¶
get_field_kwargs
¶
get_field
¶
decode
¶
serialize
¶
serialize_no_response
¶
prepare_data
¶
render
¶
Source code in hypha/apply/stream_forms/blocks.py
get_searchable_content
¶
AddressFieldBlock
¶
Bases: ApplicationSingleIncludeFieldBlock
Source code in hypha/apply/utils/blocks.py
field_label
class-attribute
instance-attribute
¶
help_text
class-attribute
instance-attribute
¶
help_link
class-attribute
instance-attribute
¶
required
class-attribute
instance-attribute
¶
Meta
¶
get_slug
¶
get_field_class
¶
get_widget
¶
get_field_kwargs
¶
Source code in hypha/apply/stream_forms/blocks.py
get_field
¶
decode
¶
serialize
¶
serialize_no_response
¶
render
¶
Source code in hypha/apply/stream_forms/blocks.py
get_searchable_content
¶
no_response
¶
format_data
¶
prepare_data
¶
Source code in hypha/apply/funds/blocks.py
FullNameBlock
¶
Bases: ApplicationMustIncludeFieldBlock
Source code in hypha/apply/utils/blocks.py
help_link
class-attribute
instance-attribute
¶
field_label
class-attribute
instance-attribute
¶
help_text
class-attribute
instance-attribute
¶
help_text = TextBlock(required=False, label=gettext_lazy('Help text'), default=gettext_lazy('We will use this name when we communicate with you about your proposal.'))
Meta
¶
get_slug
¶
get_field_class
¶
get_widget
¶
get_field_kwargs
¶
get_field
¶
decode
¶
serialize
¶
serialize_no_response
¶
prepare_data
¶
render
¶
Source code in hypha/apply/stream_forms/blocks.py
get_searchable_content
¶
DurationBlock
¶
Bases: ApplicationSingleIncludeFieldBlock
Source code in hypha/apply/utils/blocks.py
field_label
class-attribute
instance-attribute
¶
help_text
class-attribute
instance-attribute
¶
help_link
class-attribute
instance-attribute
¶
required
class-attribute
instance-attribute
¶
DURATION_TYPE_CHOICES
class-attribute
instance-attribute
¶
DURATION_DAY_OPTIONS
class-attribute
instance-attribute
¶
DURATION_DAY_OPTIONS = {1: '1 day', 2: '2 days', 3: '3 days', 4: '4 days', 5: '5 days', 6: '6 days', 7: '7 days'}
DURATION_WEEK_OPTIONS
class-attribute
instance-attribute
¶
DURATION_WEEK_OPTIONS = {1: '1 week', 2: '2 weeks', 3: '3 weeks', 4: '4 weeks', 5: '5 weeks', 6: '6 weeks', 7: '7 weeks', 8: '8 weeks', 9: '9 weeks', 10: '10 weeks', 11: '11 weeks', 12: '12 weeks'}
DURATION_MONTH_OPTIONS
class-attribute
instance-attribute
¶
DURATION_MONTH_OPTIONS = {1: '1 month', 2: '2 months', 3: '3 months', 4: '4 months', 5: '5 months', 6: '6 months', 7: '7 months', 8: '8 months', 9: '9 months', 10: '10 months', 11: '11 months', 12: '12 months', 18: '18 months', 24: '24 months'}
duration_type
class-attribute
instance-attribute
¶
duration_type = ChoiceBlock(help_text='Duration type is used to display duration choices in Days, Weeks or Months in application forms. Be careful, changing the duration type in the active round can result in data inconsistency.', choices=DURATION_TYPE_CHOICES, default=MONTHS)
get_slug
¶
get_field_class
¶
get_widget
¶
get_field
¶
decode
¶
serialize
¶
serialize_no_response
¶
render
¶
Source code in hypha/apply/stream_forms/blocks.py
get_searchable_content
¶
no_response
¶
get_field_kwargs
¶
Source code in hypha/apply/funds/blocks.py
prepare_data
¶
Source code in hypha/apply/funds/blocks.py
ApplicationCustomFormFieldsBlock
¶
Bases: CustomFormFieldsBlock
, FormFieldsBlock
Source code in hypha/apply/utils/blocks.py
text_markup
class-attribute
instance-attribute
¶
header_markup
class-attribute
instance-attribute
¶
header_markup = HeadingBlock(group=gettext_lazy('Custom'), label=gettext_lazy('Section header'))
multi_inputs_char
class-attribute
instance-attribute
¶
multi_inputs_char = MultiInputCharFieldBlock(group=gettext_lazy('Fields'))
checkbox
class-attribute
instance-attribute
¶
checkbox = CheckboxFieldBlock(group=gettext_lazy('Fields'))
radios
class-attribute
instance-attribute
¶
radios = RadioButtonsFieldBlock(group=gettext_lazy('Fields'))
dropdown
class-attribute
instance-attribute
¶
dropdown = DropdownFieldBlock(group=gettext_lazy('Fields'))
checkboxes
class-attribute
instance-attribute
¶
checkboxes = CheckboxesFieldBlock(group=gettext_lazy('Fields'))
datetime
class-attribute
instance-attribute
¶
datetime = DateTimeFieldBlock(group=gettext_lazy('Fields'))
multi_file
class-attribute
instance-attribute
¶
multi_file = MultiFileFieldBlock(group=gettext_lazy('Fields'))
group_toggle
class-attribute
instance-attribute
¶
group_toggle = GroupToggleBlock(group=gettext_lazy('Custom'))
group_toggle_end
class-attribute
instance-attribute
¶
group_toggle_end = GroupToggleEndBlock(group=gettext_lazy('Custom'))
markdown_text
class-attribute
instance-attribute
¶
markdown_text = MarkdownTextFieldBlock(group=gettext_lazy('Fields'))
required_block_names
instance-attribute
¶
single_block_names
instance-attribute
¶
category
class-attribute
instance-attribute
¶
category = CategoryQuestionBlock(group=gettext_lazy('Custom'))
rich_text
class-attribute
instance-attribute
¶
rich_text = RichTextFieldBlock(group=gettext_lazy('Fields'))
clean
¶
Source code in hypha/apply/utils/blocks.py
add_error_to_child
¶
Source code in hypha/apply/utils/blocks.py
to_python
¶
This allows historic data to still be accessible even if a custom field type is removed from the code in the future.