Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

allowing storing/updating time_zone in mobile app user settings table #2601

Merged
merged 3 commits into from
Jul 20, 2023

Conversation

joeyorlando
Copy link
Contributor

@joeyorlando joeyorlando commented Jul 20, 2023

What this PR does

closes #2450

Checklist

  • Unit, integration, and e2e (if applicable) tests updated
  • Documentation added (or pr:no public docs PR label added if not required)
  • CHANGELOG.md updated (or pr:no changelog PR label added if not required)

mobile app user settings table
@joeyorlando joeyorlando added the pr:no public docs Added to a PR that does not require public documentation updates label Jul 20, 2023
@joeyorlando joeyorlando requested review from a team July 20, 2023 15:31
AddDefaultValue(
model_name='mobileappusersettings',
name='time_zone',
value='UTC',
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we are already using "UTC" as the fallback value here if a value is not set in the user object.

user_tz = user_timezone

localized_dt = dt.astimezone(pytz.timezone(user_tz))
localized_dt = dt.astimezone(pytz.timezone(mobile_app_user_settings.time_zone))
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

main change of the PR

@joeyorlando joeyorlando merged commit 67393dd into dev Jul 20, 2023
@joeyorlando joeyorlando deleted the jorlando/add-maus-timezone branch July 20, 2023 18:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr:no public docs Added to a PR that does not require public documentation updates
Projects
None yet
Development

Successfully merging this pull request may close these issues.

use mobile device timezone when sending "You're going oncall" push notifications
2 participants