-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: create notification to email verification code flow
- Loading branch information
Showing
6 changed files
with
60 additions
and
3 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import { MigrationInterface, QueryRunner } from 'typeorm'; | ||
import { | ||
SCHEMA_VALIDATORS_NAMES, | ||
NotificationType, | ||
} from '../src/entities/notificationType'; | ||
import { NOTIFICATION_CATEGORY } from '../src/types/general'; | ||
import { NOTIFICATIONS_EVENT_NAMES } from '../src/types/notifications'; | ||
import { MICRO_SERVICES } from '../src/utils/utils'; | ||
const EmailConfirmationNotificationCodeFlowType = [ | ||
{ | ||
name: NOTIFICATIONS_EVENT_NAMES.SEND_EMAIL_CONFIRMATION_CODE_FLOW, | ||
description: NOTIFICATIONS_EVENT_NAMES.SEND_EMAIL_CONFIRMATION_CODE_FLOW, | ||
microService: MICRO_SERVICES.givethio, | ||
category: NOTIFICATION_CATEGORY.ORTTO, | ||
schemaValidator: SCHEMA_VALIDATORS_NAMES.SEND_EMAIL_CONFIRMATION_CODE_FLOW, | ||
}, | ||
]; | ||
|
||
export class AddEmailVerificationCodeFlow1723578137845 | ||
implements MigrationInterface | ||
{ | ||
public async up(queryRunner: QueryRunner): Promise<void> { | ||
await queryRunner.manager.save( | ||
NotificationType, | ||
EmailConfirmationNotificationCodeFlowType, | ||
); | ||
} | ||
|
||
public async down(queryRunner: QueryRunner): Promise<void> { | ||
await queryRunner.query( | ||
`DELETE FROM notification_type WHERE "name" = 'Send email confirmation code flow';`, | ||
); | ||
} | ||
} |
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
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