Skip to content

Commit

Permalink
add only donation received for qacc
Browse files Browse the repository at this point in the history
  • Loading branch information
ae2079 committed Aug 20, 2024
1 parent daf6970 commit a62fe30
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 207 deletions.
210 changes: 3 additions & 207 deletions migrations/1723505340806-addNotificationTypesForQacc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,215 +8,11 @@ import { MICRO_SERVICES } from '../src/utils/utils';

const QaccNotificationTypes = [
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_UNLISTED_SUPPORTED,
description: NOTIFICATION_TYPE_NAMES.PROJECT_UNLISTED_SUPPORTED,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.SUPPORTED_PROJECTS,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_UNVERIFIED_WHO_SUPPORTED,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_LISTED_SUPPORTED,
description: NOTIFICATION_TYPE_NAMES.PROJECT_LISTED_SUPPORTED,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.SUPPORTED_PROJECTS,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_LISTED,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_UNLISTED_OWNER,
description: NOTIFICATION_TYPE_NAMES.PROJECT_UNLISTED_OWNER,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_UNLISTED,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_LISTED_OWNER,
description: NOTIFICATION_TYPE_NAMES.PROJECT_LISTED_OWNER,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_LISTED,
},
{
name: NOTIFICATION_TYPE_NAMES.DRAFT_PUBLISHED_OWNER,
description: NOTIFICATION_TYPE_NAMES.DRAFT_PUBLISHED_OWNER,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.DRAFTED_PROJECT_ACTIVATED,
},
{
name: NOTIFICATION_TYPE_NAMES.DRAFT_PROJECT_HAS_BEEN_SAVED_OWNER,
description: NOTIFICATION_TYPE_NAMES.DRAFT_PROJECT_HAS_BEEN_SAVED_OWNER,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.DRAFTED_PROJECT_SAVED,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_BOOSTED_OWNER,
description: NOTIFICATION_TYPE_NAMES.PROJECT_BOOSTED_OWNER,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_HAS_BEEN_BOOSTED,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_BOOSTED_BY_PROJECT_OWNER,
description: NOTIFICATION_TYPE_NAMES.PROJECT_BOOSTED_BY_PROJECT_OWNER,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.USER_BOOSTED,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_CANCELLED_OWNER,
description: NOTIFICATION_TYPE_NAMES.PROJECT_CANCELLED_OWNER,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_CANCELLED,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_CANCELLED_SUPPORTED,
description: NOTIFICATION_TYPE_NAMES.PROJECT_CANCELLED_SUPPORTED,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.SUPPORTED_PROJECTS,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_CANCELLED,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_ACTIVATED_OWNER,
description: NOTIFICATION_TYPE_NAMES.PROJECT_ACTIVATED_OWNER,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_ACTIVATED,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_ACTIVATED_SUPPORTED,
description: NOTIFICATION_TYPE_NAMES.PROJECT_ACTIVATED_SUPPORTED,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.SUPPORTED_PROJECTS,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_ACTIVATED,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_DEACTIVATED_OWNER,
description: NOTIFICATION_TYPE_NAMES.PROJECT_DEACTIVATED_OWNER,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_DEACTIVATED,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_DEACTIVATED_SUPPORTED,
description: NOTIFICATION_TYPE_NAMES.PROJECT_DEACTIVATED_SUPPORTED,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.SUPPORTED_PROJECTS,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_DEACTIVATED,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_VERIFIED_OWNER,
description: NOTIFICATION_TYPE_NAMES.PROJECT_VERIFIED_OWNER,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_VERIFIED,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_VERIFIED_SUPPORTED,
description: NOTIFICATION_TYPE_NAMES.PROJECT_VERIFIED_SUPPORTED,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.SUPPORTED_PROJECTS,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_VERIFIED,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_UNVERIFIED_OWNER,
description: NOTIFICATION_TYPE_NAMES.PROJECT_UNVERIFIED_OWNER,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_UNVERIFIED,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_UNVERIFIED_SUPPORTED,
description: NOTIFICATION_TYPE_NAMES.PROJECT_UNVERIFIED_SUPPORTED,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.SUPPORTED_PROJECTS,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_UNVERIFIED_WHO_SUPPORTED,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_BADGE_REVOKE_REMINDER,
description: NOTIFICATION_TYPE_NAMES.PROJECT_BADGE_REVOKE_REMINDER,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_BADGE_REVOKE_REMINDER,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_BADGE_REVOKE_WARNING,
description: NOTIFICATION_TYPE_NAMES.PROJECT_BADGE_REVOKE_WARNING,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_BADGE_REVOKE_WARNING,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_BADGE_REVOKE_LAST_WARNING,
description: NOTIFICATION_TYPE_NAMES.PROJECT_BADGE_REVOKE_LAST_WARNING,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_BADGE_REVOKE_LAST_WARNING,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_BADGE_UP_FOR_REVOKING,
description: NOTIFICATION_TYPE_NAMES.PROJECT_BADGE_UP_FOR_REVOKING,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_BADGE_UP_FOR_REVOKING,
},
{
name: NOTIFICATION_TYPE_NAMES.VERIFICATION_FORM_GOT_DRAFT_BY_ADMIN,
description: NOTIFICATION_TYPE_NAMES.VERIFICATION_FORM_GOT_DRAFT_BY_ADMIN,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator:
SCHEMA_VALIDATORS_NAMES.VERIFICATION_FORM_GOT_DRAFT_BY_ADMIN,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_UPDATE_ADDED,
description: NOTIFICATION_TYPE_NAMES.PROJECT_UPDATE_ADDED,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.SUPPORTED_PROJECTS,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_UPDATED_ADDED_WHO_SUPPORTS,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_HAS_A_NEW_RANK,
description: NOTIFICATION_TYPE_NAMES.PROJECT_HAS_A_NEW_RANK,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_HAS_A_NEW_RANK,
},
{
name: NOTIFICATION_TYPE_NAMES.PROJECT_HAS_RISEN_IN_THE_RANK,
description: NOTIFICATION_TYPE_NAMES.PROJECT_HAS_RISEN_IN_THE_RANK,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.PROJECT_HAS_RISEN_IN_THE_RANK,
},
{
name: NOTIFICATION_TYPE_NAMES.YOUR_PROJECT_GOT_A_RANK,
description: NOTIFICATION_TYPE_NAMES.YOUR_PROJECT_GOT_A_RANK,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.PROJECT_RELATED,
schemaValidator: SCHEMA_VALIDATORS_NAMES.YOUR_PROJECT_GOT_A_RANK,
},
{
name: NOTIFICATION_TYPE_NAMES.SUBSCRIBE_ONBOARDING,
description: NOTIFICATION_TYPE_NAMES.SUBSCRIBE_ONBOARDING,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.ORTTO,
schemaValidator: SCHEMA_VALIDATORS_NAMES.SUBSCRIBE_ONBOARDING,
},
{
name: NOTIFICATION_TYPE_NAMES.CREATE_ORTTO_PROFILE,
description: NOTIFICATION_TYPE_NAMES.CREATE_ORTTO_PROFILE,
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.ORTTO,
schemaValidator: SCHEMA_VALIDATORS_NAMES.CREATE_ORTTO_PROFILE,
},
{
name: NOTIFICATION_TYPE_NAMES.NOTIFY_REWARD_AMOUNT,
description: NOTIFICATION_TYPE_NAMES.NOTIFY_REWARD_AMOUNT,
name: NOTIFICATION_TYPE_NAMES.DONATION_RECEIVED_FOR_QACC,
description: 'Project has received a donation',
microService: MICRO_SERVICES.qacc,
category: NOTIFICATION_CATEGORY.ORTTO,
schemaValidator: SCHEMA_VALIDATORS_NAMES.NOTIFY_REWARD_AMOUNT,
schemaValidator: SCHEMA_VALIDATORS_NAMES.DONATION_RECEIVED_FOR_QACC,
},
];

Expand Down
1 change: 1 addition & 0 deletions src/entities/notificationType.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ export const SCHEMA_VALIDATORS_NAMES = {
YOUR_PROJECT_GOT_A_RANK: 'yourProjectGotARank',

NOTIFY_REWARD_AMOUNT: 'notifyRewardAmount',
DONATION_RECEIVED_FOR_QACC: 'DonationReceivedForQacc',
};
export type HtmlTemplate = { type: string; content: string; href?: string }[];

Expand Down
1 change: 1 addition & 0 deletions src/types/general.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,4 +55,5 @@ export enum NOTIFICATION_TYPE_NAMES {
CREATE_ORTTO_PROFILE = 'Create Ortto profile',

NOTIFY_REWARD_AMOUNT = 'Notify reward amount',
DONATION_RECEIVED_FOR_QACC = 'Donation received for qacc',
}

0 comments on commit a62fe30

Please sign in to comment.