def create_comms_channel_action(headline_post): if headline_post.comms_channel: # No need to create an action, channel already exists return None return Button( ":speaking_head_in_silhouette: Create Comms Channel", HeadlinePost.CREATE_COMMS_CHANNEL_BUTTON, value=headline_post.incident.pk, )
def create_zoom_meeting(headline_post): if headline_post.incident.report_only: # Reports don't link to zoom meeting return None if headline_post.zoom_meeting: # No need to create an action, channel already exists return None return Button( ":telephone_receiver: Create Zoom Meeting", HeadlinePost.CREATE_ZOOM_MEETING_BUTTON, value=headline_post.incident.pk, )
def create_comms_channel_action(headline_post): if headline_post.incident.report_only: # Reports don't link to comms channels return None if headline_post.comms_channel: # No need to create an action, channel already exists return None return Button( ":slack: Create Incident Room", HeadlinePost.CREATE_COMMS_CHANNEL_BUTTON, value=headline_post.incident.pk, )
def close_incident_button(headline_post): return Button( ":white_check_mark: Close", HeadlinePost.CLOSE_INCIDENT_BUTTON, value=headline_post.incident.pk, )
def edit_incident_button(headline_post): return Button( ":pencil2: Edit", HeadlinePost.EDIT_INCIDENT_BUTTON, value=headline_post.incident.pk, )