-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Timezone information in booking confirmation email (#367)
* π¨ fix case sensitive filename calls π * β show timezone for attendee in confirmation email * π¨ extend schedule test with attendee timezone * π¨ Make attendee timezone mandatory * π¨ Fix appointment tests
- Loading branch information
Showing
11 changed files
with
51 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
...src/appointment/migrations/versions/2024_04_18_0823-89e1197d980d_add_attendee_timezone.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
"""add attendee timezone | ||
Revision ID: 89e1197d980d | ||
Revises: fadd0d1ef438 | ||
Create Date: 2024-04-18 08:23:55.660065 | ||
""" | ||
from alembic import op | ||
import sqlalchemy as sa | ||
|
||
|
||
# revision identifiers, used by Alembic. | ||
revision = '89e1197d980d' | ||
down_revision = 'fadd0d1ef438' | ||
branch_labels = None | ||
depends_on = None | ||
|
||
|
||
def upgrade() -> None: | ||
op.add_column('attendees', sa.Column('timezone', sa.String(255), index=True)) | ||
|
||
|
||
def downgrade() -> None: | ||
op.drop_column('attendees', 'timezone') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -462,7 +462,8 @@ def bust_cached_events(self, all_calendars = False): | |
), | ||
attendee=schemas.AttendeeBase( | ||
email='[email protected]', | ||
name='Greg' | ||
name='Greg', | ||
timezone='Europe/Berlin' | ||
) | ||
).model_dump(mode='json') | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,7 +17,7 @@ def test_confirm(self, faker, with_l10n): | |
deny_url = 'https://example.org/no' | ||
fake_email = '[email protected]' | ||
now = datetime.datetime.now() | ||
attendee = schemas.AttendeeBase(email=faker.email(), name=faker.name()) | ||
attendee = schemas.AttendeeBase(email=faker.email(), name=faker.name(), timezone='Europe/Berlin') | ||
|
||
mailer = ConfirmationMail(confirm_url, deny_url, attendee, now, to=fake_email) | ||
assert mailer.html() | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters