StandupMonkey icon indicating copy to clipboard operation
StandupMonkey copied to clipboard

Add frequency functionality for weekly or monthly only

Open datatalking opened this issue 1 year ago • 4 comments

This repo has potential and I'd like to help add features.

For people who are not needed to attend a daily standup, where would I change the frequency or introduce a function to enable that option?

  1. Does this prompt the user to do a standup or does it alert someone up the organization that xyz person has not done their standup at all or was late?

datatalking avatar Aug 06 '22 19:08 datatalking

It doesn't send any alert to the organization, simply saves responses and you can then request a report using the code below. Also, it sends standup status messages to the public channel as soon as someone submits them. /generate-report @user start_date end_date

iam-mhaseeb avatar Aug 07 '22 04:08 iam-mhaseeb

At the moment it doesn't support frequency functionality for that we would need to make changes in this piece of code and schedule it somehow.

iam-mhaseeb avatar Aug 07 '22 05:08 iam-mhaseeb

I suppose the easiest or shortest way to test it out could be to add a custom function with decorator below def action_today_standup_status() at line 233 and move the existing def action_blocker_standup_status() down.

` def action_today_standup_status(body, ack, say):

def action_weekly_standup_status(body, ack, say): ack() user_id = body['user']['id'] msg = body['actions'][0]['value'] # say(f"<@{body['user']['id']}> submitted standup status with message: {msg}.") # TODO RESEARCH SLACK API calendar function day_choice(user_id, column_name='today', message=msg upsert_today_standup_status(user_id, column_name='today', message=msg) post_standup_completion_message(user_id, say)

@app.action("blocker-action") def action_blocker_standup_status(body, ack, say): `

Which brings to mind further functionality, I will have to research SLACK_API if it supports saving requests, then prompting the user to choose an appointment if none was chosen from yesterdays or the previous session ended prior to selection of a date/time. This is something we would like in our slack group.

datatalking avatar Aug 09 '22 17:08 datatalking

Go for it, raise a PR, and I'll review and merge it.

iam-mhaseeb avatar Aug 10 '22 07:08 iam-mhaseeb