Send staff email digest
hypha.apply.activity.management.commands.send_staff_email_digest
¶
Command
¶
Bases: BaseCommand
Management command to send a summary of activities in hypha to configured emails.
It sends all the activities to the emails set in "ACTIVITY_DIGEST_RECIPIENT_EMAILS", if it is set.
It also checks for messages that belong a fund or lab, if a lab or fund has "activity_digest_recipient_emails" property set, it also sends the digest related to that fund or lab to that email.
help
class-attribute
instance-attribute
¶
handle
¶
Source code in hypha/apply/activity/management/commands/send_staff_email_digest.py
groupby_fund_lab_id
¶
Source code in hypha/apply/activity/management/commands/send_staff_email_digest.py
extract_fund_or_lab_property
¶
Retrieve properties from fund or lab, if present.
βββββββ
βFund β
βββββββ
event.source β
βββββββΌβββββββββββββ
β ββββΌβββ βββββββ β
β βRoundβ β Lab β β
β ββββ¬βββ ββ¬βββββ β
βββββββΌββββββΌβββββββ
ββββ¬βββ
β
βΌ
Args: event: Event ModelClass instance
Returns:
-
β
An array of emails or empty list.
Source code in hypha/apply/activity/management/commands/send_staff_email_digest.py
slack_message_to_markdown
¶
Converts messages in the slack format to markdown.
It converts href in the format
Parameters:
-
msg
βslack message as text