Index
hypha.apply.funds.models
¶
ApplicationRevision
¶
Bases: BaseStreamForm
, AccessFormData
, Model
submission_form_class
class-attribute
instance-attribute
¶
submission_form_class = PageStreamBaseForm
wagtail_reference_index_ignore
class-attribute
instance-attribute
¶
submission
class-attribute
instance-attribute
¶
form_data
class-attribute
instance-attribute
¶
form_data = JSONField(encoder=StreamFieldDataEncoder)
author
class-attribute
instance-attribute
¶
stream_file
classmethod
¶
Source code in hypha/apply/funds/models/mixins.py
process_file
classmethod
¶
process_file_data
¶
Source code in hypha/apply/funds/models/mixins.py
extract_files
¶
from_db
classmethod
¶
Source code in hypha/apply/stream_forms/models.py
deserialised_data
classmethod
¶
Source code in hypha/apply/funds/models/mixins.py
get_definitive_id
¶
field
¶
data
¶
get_serialize_multi_inputs_answer
¶
Source code in hypha/apply/funds/models/mixins.py
serialize
¶
Source code in hypha/apply/funds/models/mixins.py
get_multi_inputs_answer
¶
Source code in hypha/apply/funds/models/mixins.py
render_answer
¶
Source code in hypha/apply/funds/models/mixins.py
render_answers
¶
render_first_group_text_answers
¶
render_text_blocks_answers
¶
Source code in hypha/apply/funds/models/mixins.py
output_answers
¶
output_text_answers
¶
output_first_group_text_answers
¶
get_answer_from_label
¶
Source code in hypha/apply/funds/models/mixins.py
deserialize_form_data
classmethod
¶
Source code in hypha/apply/stream_forms/models.py
get_defined_fields
¶
get_form_fields
¶
Source code in hypha/apply/stream_forms/models.py
57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 |
|
get_form_class
¶
get_compare_url_to_latest
¶
get_absolute_url
¶
Source code in hypha/apply/funds/models/application_revisions.py
ApplicationSettings
¶
RoundsAndLabs
¶
Bases: Page
This behaves as a useful way to get all the rounds and labs that are defined in the project regardless of how they are implemented (lab/round/sealed_round)
get_absolute_url
¶
AssignedReviewers
¶
Bases: Model
wagtail_reference_index_ignore
class-attribute
instance-attribute
¶
reviewer
class-attribute
instance-attribute
¶
reviewer = ForeignKey(AUTH_USER_MODEL, on_delete=CASCADE, limit_choices_to=LIMIT_TO_REVIEWER_GROUPS)
submission
class-attribute
instance-attribute
¶
role
class-attribute
instance-attribute
¶
ApplicationForm
¶
Bases: Model
wagtail_reference_index_ignore
class-attribute
instance-attribute
¶
form_fields
class-attribute
instance-attribute
¶
form_fields = StreamField(ApplicationCustomFormFieldsBlock(), use_json_field=True)
panels
class-attribute
instance-attribute
¶
Reminder
¶
Bases: Model
ACTION_MESSAGE
class-attribute
instance-attribute
¶
ACTION_MESSAGE = {f'{REVIEW}-{EMAIL}': REVIEW_REMINDER}
submission
class-attribute
instance-attribute
¶
action
class-attribute
instance-attribute
¶
action = CharField(choices=items(), default=REVIEW, max_length=50)
title
class-attribute
instance-attribute
¶
ReviewerRole
¶
Bases: Model
icon
class-attribute
instance-attribute
¶
icon = ForeignKey('images.CustomImage', null=True, blank=True, related_name='+', on_delete=SET_NULL)
order
class-attribute
instance-attribute
¶
order = IntegerField(help_text=gettext_lazy('The order this role should appear in the Update Reviewers form.'), null=True, blank=True)
panels
class-attribute
instance-attribute
¶
wagtail_reference_index_ignore
class-attribute
instance-attribute
¶
ReviewerSettings
¶
Bases: BaseSiteSetting
SUBMISSIONS
class-attribute
instance-attribute
¶
STATES
class-attribute
instance-attribute
¶
STATES = [('all', 'All States'), ('ext_state_or_higher', 'Only External review and higher'), ('ext_state_only', 'Only External review')]
OUTCOMES
class-attribute
instance-attribute
¶
OUTCOMES = [('all', 'All Outcomes'), ('all_except_dismissed', 'All Outcomes Except Dismissed'), ('accepted', 'Only Accepted')]
submission
class-attribute
instance-attribute
¶
submission = CharField(choices=SUBMISSIONS, default='all', max_length=10, help_text=gettext_lazy('Submissions for which reviewers should have access to'))
state
class-attribute
instance-attribute
¶
state = CharField(choices=STATES, default='all', max_length=20, help_text=gettext_lazy('Submissions states for which reviewers should have access to'))
outcome
class-attribute
instance-attribute
¶
outcome = CharField(choices=OUTCOMES, default='all', max_length=20, help_text=gettext_lazy('Submissions outcomes for which reviewers should have access to'))
assigned
class-attribute
instance-attribute
¶
assigned = BooleanField(default=False, help_text=gettext_lazy('Submissions for which reviewer is assigned to'))
use_settings
class-attribute
instance-attribute
¶
use_settings = BooleanField(default=False, help_text=gettext_lazy('Use the above configured variables to filter out submissions'))
panels
class-attribute
instance-attribute
¶
panels = [FieldPanel('submission'), FieldPanel('state'), FieldPanel('outcome'), FieldPanel('assigned'), FieldPanel('use_settings')]
ScreeningStatus
¶
Bases: Model
yes
class-attribute
instance-attribute
¶
yes = BooleanField(default=False, verbose_name=gettext_lazy('Yes/No'), help_text=gettext_lazy('Tick mark for Yes otherwise No.'))
default
class-attribute
instance-attribute
¶
default = BooleanField(default=False, verbose_name=gettext_lazy('Default Yes/No'), help_text=gettext_lazy('Only one Yes and No screening decision can be set as default.'))
ApplicationSubmission
¶
Bases: WorkflowHelpers
, BaseStreamForm
, AccessFormData
, AbstractFormSubmission
submission_form_class
class-attribute
instance-attribute
¶
submission_form_class = PageStreamBaseForm
WORKFLOW_CHOICES
class-attribute
instance-attribute
¶
WORKFLOW_CHOICES = {name: _Llxfor (name, workflow) in items()}
workflow_name
class-attribute
instance-attribute
¶
workflow_name = CharField(choices=items(), max_length=100, default='single', verbose_name=gettext_lazy('Workflow'))
form_data
class-attribute
instance-attribute
¶
form_data = JSONField(encoder=StreamFieldDataEncoder)
form_fields
class-attribute
instance-attribute
¶
form_fields = StreamField(ApplicationCustomFormFieldsBlock(), use_json_field=True)
public_id
class-attribute
instance-attribute
¶
round
class-attribute
instance-attribute
¶
lead
class-attribute
instance-attribute
¶
lead = ForeignKey(AUTH_USER_MODEL, limit_choices_to=LIMIT_TO_STAFF, related_name='submission_lead', on_delete=PROTECT)
next
class-attribute
instance-attribute
¶
reviewers
class-attribute
instance-attribute
¶
reviewers = ManyToManyField(AUTH_USER_MODEL, related_name='submissions_reviewer', blank=True, through='AssignedReviewers')
partners
class-attribute
instance-attribute
¶
partners = ManyToManyField(AUTH_USER_MODEL, related_name='submissions_partner', limit_choices_to=LIMIT_TO_PARTNERS, blank=True)
meta_terms
class-attribute
instance-attribute
¶
meta_terms = ManyToManyField(MetaTerm, related_name='submissions', blank=True)
flags
class-attribute
instance-attribute
¶
flags = GenericRelation(Flag, content_type_field='target_content_type', object_id_field='target_object_id', related_query_name='submission')
activities
class-attribute
instance-attribute
¶
activities = GenericRelation('activity.Activity', content_type_field='source_content_type', object_id_field='source_object_id', related_query_name='submission')
user
class-attribute
instance-attribute
¶
status
class-attribute
instance-attribute
¶
status = FSMField(default=INITIAL_STATE, protected=True)
screening_statuses
class-attribute
instance-attribute
¶
screening_statuses = ManyToManyField('funds.ScreeningStatus', related_name='submissions', blank=True)
submit_time
class-attribute
instance-attribute
¶
live_revision
class-attribute
instance-attribute
¶
live_revision = OneToOneField('ApplicationRevision', on_delete=CASCADE, related_name='live', null=True, editable=False)
draft_revision
class-attribute
instance-attribute
¶
draft_revision = OneToOneField('ApplicationRevision', on_delete=CASCADE, related_name='draft', null=True, editable=False)
drupal_id
class-attribute
instance-attribute
¶
wagtail_reference_index_ignore
class-attribute
instance-attribute
¶
title_text_display
property
¶
Return the title text for display across the site.
Use SUBMISSION_TITLE_TEXT_TEMPLATE setting to change format.
is_determination_form_attached
property
¶
We use old django determination forms but now as we are moving to streamfield determination forms which can be created and attached to funds in admin.
This method checks if there are new determination forms attached to the submission or we would still use the old determination forms for backward compatibility.
Meta
¶
stream_file
classmethod
¶
Source code in hypha/apply/funds/models/mixins.py
process_file
classmethod
¶
process_file_data
¶
Source code in hypha/apply/funds/models/mixins.py
extract_files
¶
from_db
classmethod
¶
Source code in hypha/apply/stream_forms/models.py
deserialised_data
classmethod
¶
Source code in hypha/apply/funds/models/mixins.py
get_definitive_id
¶
field
¶
data
¶
get_serialize_multi_inputs_answer
¶
Source code in hypha/apply/funds/models/mixins.py
serialize
¶
Source code in hypha/apply/funds/models/mixins.py
get_multi_inputs_answer
¶
Source code in hypha/apply/funds/models/mixins.py
render_answer
¶
Source code in hypha/apply/funds/models/mixins.py
render_answers
¶
render_first_group_text_answers
¶
render_text_blocks_answers
¶
Source code in hypha/apply/funds/models/mixins.py
output_answers
¶
output_text_answers
¶
output_first_group_text_answers
¶
get_answer_from_label
¶
Source code in hypha/apply/funds/models/mixins.py
deserialize_form_data
classmethod
¶
Source code in hypha/apply/stream_forms/models.py
get_defined_fields
¶
get_form_fields
¶
Source code in hypha/apply/stream_forms/models.py
57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 |
|
get_form_class
¶
not_progressed
¶
restart_stage
¶
If running form the console please include your user using the kwarg "by"
u = User.objects.get(email="my@email.com") for a in ApplicationSubmission.objects.all(): a.restart_stage(by=u) a.save()
Source code in hypha/apply/funds/models/submissions.py
|
ensure_user_has_account
¶
Source code in hypha/apply/funds/models/submissions.py
get_from_parent
¶
progress_application
¶
Source code in hypha/apply/funds/models/submissions.py
from_draft
¶
Sets current form_data
to the form_data
from the draft revision.
Returns:
-
Self
–Self with the
form_data
attribute updated.
Source code in hypha/apply/funds/models/submissions.py
create_revision
¶
Create a new revision on the submission
This is used to save drafts, track changes when an RFI is made and save changes before rendering a preview
Parameters:
-
draft
–if the revision is a draft
-
force
–force a revision even if form data is the same
-
by
(Optional[AnonymousUser | AbstractBaseUser]
, default:None
) –the author of the revision
-
preview
–if the revision is being used to save befor a preview
Returns:
-
Optional[Model]
–Returns the
ApplicationRevision
if it was created, otherwise returnsNone
Source code in hypha/apply/funds/models/submissions.py
clean_submission
¶
get_assigned_meta_terms
¶
process_form_data
¶
save
¶
Source code in hypha/apply/funds/models/submissions.py
reviewed_by
¶
flagged_by
¶
has_permission_to_review
¶
Source code in hypha/apply/funds/models/submissions.py
can_review
¶
can_view_draft
¶
Source code in hypha/apply/funds/models/submissions.py
get_searchable_contents
¶
Source code in hypha/apply/funds/models/submissions.py
prepare_search_values
¶
Source code in hypha/apply/funds/models/submissions.py
index_components
¶
prepare_search_vector
¶
get_absolute_url
¶
get_data
¶
get_current_screening_status
¶
get_yes_screening_status
¶
FundType
¶
Bases: ApplicationBase
submission_form_class
class-attribute
instance-attribute
¶
submission_form_class = PageStreamBaseForm
wagtail_reference_index_ignore
class-attribute
instance-attribute
¶
WORKFLOW_CHOICES
class-attribute
instance-attribute
¶
WORKFLOW_CHOICES = {name: _EtVfor (name, workflow) in items()}
workflow_name
class-attribute
instance-attribute
¶
workflow_name = CharField(choices=items(), max_length=100, default='single', verbose_name=gettext_lazy('Workflow'))
content_panels
class-attribute
instance-attribute
¶
content_panels = content_panels + [FieldPanel('reviewers', widget=CheckboxSelectMultiple), FieldPanel('guide_link'), FieldPanel('description'), FieldPanel('image'), FieldPanel('weight'), FieldPanel('slack_channel'), FieldPanel('activity_digest_recipient_emails'), FieldPanel('list_on_front_page'), FieldPanel('show_deadline')]
confirmation_text_extra
class-attribute
instance-attribute
¶
confirmation_text_extra = TextField(blank=True, help_text=gettext_lazy('Additional text for the application confirmation message.'))
email_confirmation_panels
class-attribute
instance-attribute
¶
email_confirmation_panels = [MultiFieldPanel([FieldRowPanel([FieldPanel('from_address', classname='col6'), FieldPanel('to_address', classname='col6')]), FieldPanel('subject'), FieldPanel('confirmation_text_extra')], heading=gettext_lazy('Confirmation email'))]
email_tab
class-attribute
instance-attribute
¶
email_tab = ObjectList(email_confirmation_panels, heading=gettext_lazy('Confirmation email'))
reviewers
class-attribute
instance-attribute
¶
reviewers = ParentalManyToManyField(AUTH_USER_MODEL, related_name='%(class)s_reviewers', limit_choices_to=LIMIT_TO_REVIEWERS, blank=True)
image
class-attribute
instance-attribute
¶
image = ForeignKey('images.CustomImage', null=True, blank=True, on_delete=SET_NULL, related_name='+')
weight
class-attribute
instance-attribute
¶
weight = PositiveIntegerField(default=1, blank=True, validators=[MinValueValidator(1), MaxValueValidator(100)])
guide_link
class-attribute
instance-attribute
¶
guide_link = URLField(blank=True, max_length=255, help_text=gettext_lazy('Link to the apply guide.'))
slack_channel
class-attribute
instance-attribute
¶
slack_channel = CharField(blank=True, max_length=128, help_text=gettext_lazy('The slack #channel for notifications. If left empty, notifications will go to the default channel.'))
activity_digest_recipient_emails
class-attribute
instance-attribute
¶
activity_digest_recipient_emails = ArrayField(EmailField(default=''), blank=True, null=True, help_text=gettext_lazy('Comma separated list of emails where a summary of all the activities related to this fund will be sent.'))
list_on_front_page
class-attribute
instance-attribute
¶
list_on_front_page = BooleanField(default=True, help_text=gettext_lazy('Should the fund be listed on the front page.'))
show_deadline
class-attribute
instance-attribute
¶
show_deadline = BooleanField(default=True, help_text=gettext_lazy('Should the deadline date be visible for users.'))
parent_page_types
class-attribute
instance-attribute
¶
edit_handler
class-attribute
instance-attribute
¶
edit_handler = TabbedInterface([ObjectList(content_panels, heading=gettext_lazy('Content')), email_tab, ObjectList(promote_panels, heading=gettext_lazy('Promote'))])
from_db
classmethod
¶
Source code in hypha/apply/stream_forms/models.py
deserialize_form_data
classmethod
¶
Source code in hypha/apply/stream_forms/models.py
get_defined_fields
¶
get_form_fields
¶
Source code in hypha/apply/stream_forms/models.py
57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 |
|
get_form_class
¶
render_landing_page
¶
Source code in hypha/apply/funds/models/utils.py
send_mail
¶
get_template
¶
open_round
¶
next_deadline
¶
serve
¶
Source code in hypha/apply/funds/models/applications.py
RequestForPartners
¶
Bases: ApplicationBase
submission_form_class
class-attribute
instance-attribute
¶
submission_form_class = PageStreamBaseForm
wagtail_reference_index_ignore
class-attribute
instance-attribute
¶
WORKFLOW_CHOICES
class-attribute
instance-attribute
¶
WORKFLOW_CHOICES = {name: _0wwfor (name, workflow) in items()}
workflow_name
class-attribute
instance-attribute
¶
workflow_name = CharField(choices=items(), max_length=100, default='single', verbose_name=gettext_lazy('Workflow'))
content_panels
class-attribute
instance-attribute
¶
content_panels = content_panels + [FieldPanel('reviewers', widget=CheckboxSelectMultiple), FieldPanel('guide_link'), FieldPanel('description'), FieldPanel('image'), FieldPanel('weight'), FieldPanel('slack_channel'), FieldPanel('activity_digest_recipient_emails'), FieldPanel('list_on_front_page'), FieldPanel('show_deadline')]
confirmation_text_extra
class-attribute
instance-attribute
¶
confirmation_text_extra = TextField(blank=True, help_text=gettext_lazy('Additional text for the application confirmation message.'))
email_confirmation_panels
class-attribute
instance-attribute
¶
email_confirmation_panels = [MultiFieldPanel([FieldRowPanel([FieldPanel('from_address', classname='col6'), FieldPanel('to_address', classname='col6')]), FieldPanel('subject'), FieldPanel('confirmation_text_extra')], heading=gettext_lazy('Confirmation email'))]
email_tab
class-attribute
instance-attribute
¶
email_tab = ObjectList(email_confirmation_panels, heading=gettext_lazy('Confirmation email'))
reviewers
class-attribute
instance-attribute
¶
reviewers = ParentalManyToManyField(AUTH_USER_MODEL, related_name='%(class)s_reviewers', limit_choices_to=LIMIT_TO_REVIEWERS, blank=True)
image
class-attribute
instance-attribute
¶
image = ForeignKey('images.CustomImage', null=True, blank=True, on_delete=SET_NULL, related_name='+')
weight
class-attribute
instance-attribute
¶
weight = PositiveIntegerField(default=1, blank=True, validators=[MinValueValidator(1), MaxValueValidator(100)])
guide_link
class-attribute
instance-attribute
¶
guide_link = URLField(blank=True, max_length=255, help_text=gettext_lazy('Link to the apply guide.'))
slack_channel
class-attribute
instance-attribute
¶
slack_channel = CharField(blank=True, max_length=128, help_text=gettext_lazy('The slack #channel for notifications. If left empty, notifications will go to the default channel.'))
activity_digest_recipient_emails
class-attribute
instance-attribute
¶
activity_digest_recipient_emails = ArrayField(EmailField(default=''), blank=True, null=True, help_text=gettext_lazy('Comma separated list of emails where a summary of all the activities related to this fund will be sent.'))
list_on_front_page
class-attribute
instance-attribute
¶
list_on_front_page = BooleanField(default=True, help_text=gettext_lazy('Should the fund be listed on the front page.'))
show_deadline
class-attribute
instance-attribute
¶
show_deadline = BooleanField(default=True, help_text=gettext_lazy('Should the deadline date be visible for users.'))
parent_page_types
class-attribute
instance-attribute
¶
edit_handler
class-attribute
instance-attribute
¶
edit_handler = TabbedInterface([ObjectList(content_panels, heading=gettext_lazy('Content')), email_tab, ObjectList(promote_panels, heading=gettext_lazy('Promote'))])
subpage_types
class-attribute
instance-attribute
¶
from_db
classmethod
¶
Source code in hypha/apply/stream_forms/models.py
deserialize_form_data
classmethod
¶
Source code in hypha/apply/stream_forms/models.py
get_defined_fields
¶
get_form_fields
¶
Source code in hypha/apply/stream_forms/models.py
57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 |
|
get_form_class
¶
render_landing_page
¶
Source code in hypha/apply/funds/models/utils.py
send_mail
¶
get_template
¶
open_round
¶
next_deadline
¶
serve
¶
Source code in hypha/apply/funds/models/applications.py
Round
¶
Bases: RoundBase
submission_form_class
class-attribute
instance-attribute
¶
submission_form_class = PageStreamBaseForm
wagtail_reference_index_ignore
class-attribute
instance-attribute
¶
WORKFLOW_CHOICES
class-attribute
instance-attribute
¶
WORKFLOW_CHOICES = {name: _TW2for (name, workflow) in items()}
workflow_name
class-attribute
instance-attribute
¶
workflow_name = CharField(choices=items(), max_length=100, default='single', verbose_name=gettext_lazy('Workflow'))
content_panels
class-attribute
instance-attribute
¶
content_panels = content_panels + [FieldPanel('lead'), MultiFieldPanel([FieldRowPanel([FieldPanel('start_date'), FieldPanel('end_date')])], heading=gettext_lazy('Dates')), FieldPanel('reviewers', widget=CheckboxSelectMultiple), FieldPanel('submission_id_prefix'), ReadOnlyPanel('get_workflow_name_display', heading=gettext_lazy('Workflow'), help_text=gettext_lazy('Copied from the fund.')), ReadOnlyInlinePanel('forms', panels=[ReadOnlyPanel('name')], heading=gettext_lazy('Application forms'), help_text=gettext_lazy('Copied from the fund.')), ReadOnlyInlinePanel('review_forms', panels=[ReadOnlyPanel('name')], heading=gettext_lazy('Internal Review Form'), help_text=gettext_lazy('Copied from the fund.')), ReadOnlyInlinePanel('external_review_forms', panels=[ReadOnlyPanel('name')], help_text=gettext_lazy('Copied from the fund.'), heading=gettext_lazy('External Review Form')), ReadOnlyInlinePanel('determination_forms', panels=[ReadOnlyPanel('name')], help_text=gettext_lazy('Copied from the fund.'), heading=gettext_lazy('Determination Form'))]
submission_id_prefix
class-attribute
instance-attribute
¶
submission_id_prefix = SlugField(gettext_lazy('Submission ID Prefix'), max_length=10, blank=True, default='', null=False, help_text=gettext_lazy('Prefix for the submission id. e.g. "HYPHA23-" will result in a submission id of "HYPHA23-1".'))
lead
class-attribute
instance-attribute
¶
lead = ForeignKey(AUTH_USER_MODEL, limit_choices_to=LIMIT_TO_STAFF, related_name='%(class)s_lead', on_delete=PROTECT)
reviewers
class-attribute
instance-attribute
¶
reviewers = ParentalManyToManyField(AUTH_USER_MODEL, related_name='%(class)s_reviewer', limit_choices_to=LIMIT_TO_REVIEWERS, blank=True)
start_date
class-attribute
instance-attribute
¶
end_date
class-attribute
instance-attribute
¶
end_date = DateField(blank=True, null=True, default=today, help_text=gettext_lazy('When no end date is provided the round will remain open indefinitely.'))
edit_handler
class-attribute
instance-attribute
¶
edit_handler = TabbedInterface([ObjectList(content_panels, heading=gettext_lazy('Content')), ObjectList(promote_panels, heading=gettext_lazy('Promote'))])
is_open
property
¶
Checks if the application is open based on the current date.
The application is considered open if the current date is between the start and end dates (inclusive). If the end date is not set, the application is considered open if the current date is on or after the start date.
Returns:
-
bool
(bool
) –True if the application is open, False otherwise.
parent_page_types
class-attribute
instance-attribute
¶
from_db
classmethod
¶
Source code in hypha/apply/stream_forms/models.py
deserialize_form_data
classmethod
¶
Source code in hypha/apply/stream_forms/models.py
get_defined_fields
¶
get_form_fields
¶
Source code in hypha/apply/stream_forms/models.py
57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 |
|
get_form_class
¶
get_submission_class
¶
process_form_submission
¶
Source code in hypha/apply/funds/models/utils.py
get_submit_meta_data
¶
render_landing_page
¶
Source code in hypha/apply/funds/models/utils.py
get_url
¶
Generates the live url, primarily used in the wagtail admin for the "view live" button.
Returns:
-
str
(Optional[str]
) –The live url of the page, or None if the page is not live.
Source code in hypha/apply/funds/models/applications.py
get_template
¶
get_landing_page_template
¶
fund
¶
save
¶
Source code in hypha/apply/funds/models/applications.py
clean
¶
Source code in hypha/apply/funds/models/applications.py
get_initial_data_open_call_submission
¶
Source code in hypha/apply/funds/models/applications.py
get_form_parameters
¶
Source code in hypha/apply/funds/models/applications.py
get_form
¶
Source code in hypha/apply/funds/models/applications.py
serve
¶
Source code in hypha/apply/funds/models/applications.py
SealedRound
¶
Bases: RoundBase
Source code in hypha/apply/funds/models/__init__.py
submission_form_class
class-attribute
instance-attribute
¶
submission_form_class = PageStreamBaseForm
wagtail_reference_index_ignore
class-attribute
instance-attribute
¶
WORKFLOW_CHOICES
class-attribute
instance-attribute
¶
WORKFLOW_CHOICES = {name: _yqyfor (name, workflow) in items()}
workflow_name
class-attribute
instance-attribute
¶
workflow_name = CharField(choices=items(), max_length=100, default='single', verbose_name=gettext_lazy('Workflow'))
content_panels
class-attribute
instance-attribute
¶
content_panels = content_panels + [FieldPanel('lead'), MultiFieldPanel([FieldRowPanel([FieldPanel('start_date'), FieldPanel('end_date')])], heading=gettext_lazy('Dates')), FieldPanel('reviewers', widget=CheckboxSelectMultiple), FieldPanel('submission_id_prefix'), ReadOnlyPanel('get_workflow_name_display', heading=gettext_lazy('Workflow'), help_text=gettext_lazy('Copied from the fund.')), ReadOnlyInlinePanel('forms', panels=[ReadOnlyPanel('name')], heading=gettext_lazy('Application forms'), help_text=gettext_lazy('Copied from the fund.')), ReadOnlyInlinePanel('review_forms', panels=[ReadOnlyPanel('name')], heading=gettext_lazy('Internal Review Form'), help_text=gettext_lazy('Copied from the fund.')), ReadOnlyInlinePanel('external_review_forms', panels=[ReadOnlyPanel('name')], help_text=gettext_lazy('Copied from the fund.'), heading=gettext_lazy('External Review Form')), ReadOnlyInlinePanel('determination_forms', panels=[ReadOnlyPanel('name')], help_text=gettext_lazy('Copied from the fund.'), heading=gettext_lazy('Determination Form'))]
submission_id_prefix
class-attribute
instance-attribute
¶
submission_id_prefix = SlugField(gettext_lazy('Submission ID Prefix'), max_length=10, blank=True, default='', null=False, help_text=gettext_lazy('Prefix for the submission id. e.g. "HYPHA23-" will result in a submission id of "HYPHA23-1".'))
lead
class-attribute
instance-attribute
¶
lead = ForeignKey(AUTH_USER_MODEL, limit_choices_to=LIMIT_TO_STAFF, related_name='%(class)s_lead', on_delete=PROTECT)
reviewers
class-attribute
instance-attribute
¶
reviewers = ParentalManyToManyField(AUTH_USER_MODEL, related_name='%(class)s_reviewer', limit_choices_to=LIMIT_TO_REVIEWERS, blank=True)
start_date
class-attribute
instance-attribute
¶
end_date
class-attribute
instance-attribute
¶
end_date = DateField(blank=True, null=True, default=today, help_text=gettext_lazy('When no end date is provided the round will remain open indefinitely.'))
edit_handler
class-attribute
instance-attribute
¶
edit_handler = TabbedInterface([ObjectList(content_panels, heading=gettext_lazy('Content')), ObjectList(promote_panels, heading=gettext_lazy('Promote'))])
is_open
property
¶
Checks if the application is open based on the current date.
The application is considered open if the current date is between the start and end dates (inclusive). If the end date is not set, the application is considered open if the current date is on or after the start date.
Returns:
-
bool
(bool
) –True if the application is open, False otherwise.
parent_page_types
class-attribute
instance-attribute
¶
from_db
classmethod
¶
Source code in hypha/apply/stream_forms/models.py
deserialize_form_data
classmethod
¶
Source code in hypha/apply/stream_forms/models.py
get_defined_fields
¶
get_form_fields
¶
Source code in hypha/apply/stream_forms/models.py
57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 |
|
get_form_class
¶
get_submission_class
¶
process_form_submission
¶
Source code in hypha/apply/funds/models/utils.py
get_submit_meta_data
¶
render_landing_page
¶
Source code in hypha/apply/funds/models/utils.py
get_url
¶
Generates the live url, primarily used in the wagtail admin for the "view live" button.
Returns:
-
str
(Optional[str]
) –The live url of the page, or None if the page is not live.
Source code in hypha/apply/funds/models/applications.py
get_template
¶
get_landing_page_template
¶
fund
¶
save
¶
Source code in hypha/apply/funds/models/applications.py
clean
¶
Source code in hypha/apply/funds/models/applications.py
get_initial_data_open_call_submission
¶
Source code in hypha/apply/funds/models/applications.py
get_form_parameters
¶
Source code in hypha/apply/funds/models/applications.py
get_form
¶
Source code in hypha/apply/funds/models/applications.py
serve
¶
Source code in hypha/apply/funds/models/applications.py
LabType
¶
Bases: LabBase
submission_form_class
class-attribute
instance-attribute
¶
submission_form_class = PageStreamBaseForm
wagtail_reference_index_ignore
class-attribute
instance-attribute
¶
WORKFLOW_CHOICES
class-attribute
instance-attribute
¶
WORKFLOW_CHOICES = {name: _cbRfor (name, workflow) in items()}
workflow_name
class-attribute
instance-attribute
¶
workflow_name = CharField(choices=items(), max_length=100, default='single', verbose_name=gettext_lazy('Workflow'))
content_panels
class-attribute
instance-attribute
¶
content_panels = content_panels + [FieldPanel('lead'), FieldPanel('reviewers', widget=CheckboxSelectMultiple), FieldPanel('guide_link'), FieldPanel('description'), FieldPanel('image'), FieldPanel('weight'), FieldPanel('slack_channel'), FieldPanel('submission_id_prefix'), FieldPanel('activity_digest_recipient_emails'), FieldPanel('list_on_front_page')]
confirmation_text_extra
class-attribute
instance-attribute
¶
confirmation_text_extra = TextField(blank=True, help_text=gettext_lazy('Additional text for the application confirmation message.'))
email_confirmation_panels
class-attribute
instance-attribute
¶
email_confirmation_panels = [MultiFieldPanel([FieldRowPanel([FieldPanel('from_address', classname='col6'), FieldPanel('to_address', classname='col6')]), FieldPanel('subject'), FieldPanel('confirmation_text_extra')], heading=gettext_lazy('Confirmation email'))]
email_tab
class-attribute
instance-attribute
¶
email_tab = ObjectList(email_confirmation_panels, heading=gettext_lazy('Confirmation email'))
lead
class-attribute
instance-attribute
¶
lead = ForeignKey(AUTH_USER_MODEL, limit_choices_to=LIMIT_TO_STAFF, related_name='lab_lead', on_delete=PROTECT)
submission_id_prefix
class-attribute
instance-attribute
¶
submission_id_prefix = SlugField(gettext_lazy('Submission ID Prefix'), max_length=10, blank=True, default='', null=False, help_text=gettext_lazy('Prefix for the submission id. e.g. "HYPHA23-" will result in a submission id of "HYPHA23-1".'))
reviewers
class-attribute
instance-attribute
¶
reviewers = ParentalManyToManyField(AUTH_USER_MODEL, related_name='labs_reviewer', limit_choices_to=LIMIT_TO_REVIEWERS, blank=True)
image
class-attribute
instance-attribute
¶
image = ForeignKey('images.CustomImage', null=True, blank=True, on_delete=SET_NULL, related_name='+')
weight
class-attribute
instance-attribute
¶
weight = PositiveIntegerField(default=1, blank=True, validators=[MinValueValidator(1), MaxValueValidator(100)])
guide_link
class-attribute
instance-attribute
¶
guide_link = URLField(blank=True, max_length=255, help_text=gettext_lazy('Link to the apply guide.'))
slack_channel
class-attribute
instance-attribute
¶
slack_channel = CharField(blank=True, max_length=128, help_text=gettext_lazy('The slack #channel for notifications.'))
activity_digest_recipient_emails
class-attribute
instance-attribute
¶
activity_digest_recipient_emails = ArrayField(EmailField(default=''), blank=True, null=True, help_text=gettext_lazy('Comma separated list of emails where a summary of all the activities related to this lab will be sent.'))
list_on_front_page
class-attribute
instance-attribute
¶
list_on_front_page = BooleanField(default=True, help_text=gettext_lazy('Should the lab be listed on the front page.'))
parent_page_types
class-attribute
instance-attribute
¶
edit_handler
class-attribute
instance-attribute
¶
edit_handler = TabbedInterface([ObjectList(content_panels, heading=gettext_lazy('Content')), email_tab, ObjectList(promote_panels, heading=gettext_lazy('Promote'))])
from_db
classmethod
¶
Source code in hypha/apply/stream_forms/models.py
deserialize_form_data
classmethod
¶
Source code in hypha/apply/stream_forms/models.py
get_defined_fields
¶
get_form_fields
¶
Source code in hypha/apply/stream_forms/models.py
57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 |
|