Skip to content

Commit af96280

Browse files
pyphiliakim
andauthored
feat: allow users to subscribe and unsubscribe to email notifications (#2060)
* feat: allow users to subscribe and unsubscribe to email notifications * refactor: curate get setting endpoint * refactor: rename to marketing emails subscribed at * refactor: fix patch member return value * refactor: fix types * refactor: fix test * refactor: apply PR requested changes --------- Co-authored-by: kim <kim.phanhoang@epfl.ch>
1 parent 5b5cad2 commit af96280

15 files changed

Lines changed: 4143 additions & 31 deletions
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
DROP VIEW "public"."members_view";--> statement-breakpoint
2+
ALTER TABLE "account" ADD COLUMN "marketing_emails_subscribed_at" timestamp with time zone DEFAULT now();--> statement-breakpoint
3+
CREATE VIEW "public"."members_view" AS (select "id", "name", "email", "extra", "type", "created_at", "updated_at", "user_agreements_date", "enable_save_actions", "last_authenticated_at", "is_validated", "marketing_emails_subscribed_at" from "account" where ("account"."type" = 'individual' and "account"."email" is not null));

0 commit comments

Comments
 (0)