-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Privacy link + chapter progress (#1342)
* create privacy_link migration file * consume privacy-link endpoints * add logic for chapter-progress at end of each chapter * add successMessage to partnerBlockEditor * add relevant files * complete bundle features * complete bundle features * refactor code * refactor code * update description text * remove unused code * update snapshot test * update snapshot test * update snapshot test * update snapshot test * update snapshot test * update snapshot test * remove redundant code * resolve review comments * resolve review comments * update snapshot test * resolve review comments * remove text-transform * update snapshot test
- Loading branch information
1 parent
10b199c
commit d937f33
Showing
59 changed files
with
482 additions
and
16 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
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
2 changes: 2 additions & 0 deletions
2
services/headless-lms/migrations/20241201122945_create_privacy_links.down.sql
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,2 @@ | ||
-- Add down migration script here | ||
DROP TABLE privacy_links; |
22 changes: 22 additions & 0 deletions
22
services/headless-lms/migrations/20241201122945_create_privacy_links.up.sql
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,22 @@ | ||
-- Add up migration script here | ||
CREATE TABLE privacy_links ( | ||
id UUID DEFAULT uuid_generate_v4() PRIMARY KEY, | ||
created_at TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW(), | ||
updated_at TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW(), | ||
deleted_at TIMESTAMP WITH TIME ZONE, | ||
title VARCHAR(255) NOT NULL, | ||
url TEXT NOT NULL, | ||
course_id UUID NOT NULL REFERENCES courses(id) | ||
); | ||
|
||
CREATE TRIGGER set_timestamp BEFORE | ||
UPDATE ON privacy_links FOR EACH ROW EXECUTE PROCEDURE trigger_set_timestamp(); | ||
|
||
COMMENT ON TABLE privacy_links IS 'This table stores custom privacy links for specific courses. By default, a generic privacy link is displayed in the website footer, but adding rows to this table allows overriding the default link with course-specific privacy URLs.'; | ||
COMMENT ON COLUMN privacy_links.id IS 'A unique identifier for the privacy link record.'; | ||
COMMENT ON COLUMN privacy_links.created_at IS 'Timestamp of when the record was created.'; | ||
COMMENT ON COLUMN privacy_links.updated_at IS 'Timestamp of the last update, automatically set by the set_timestamp trigger.'; | ||
COMMENT ON COLUMN privacy_links.deleted_at IS 'Timestamp of when the record was marked as deleted, if applicable.'; | ||
COMMENT ON COLUMN privacy_links.title IS 'The title or description of the privacy link.'; | ||
COMMENT ON COLUMN privacy_links.url IS 'The URL for the privacy link content.'; | ||
COMMENT ON COLUMN privacy_links.course_id IS 'The course ID the privacy link is associated with.'; |
48 changes: 48 additions & 0 deletions
48
.../models/.sqlx/query-669a92b24018a513f1c8b957d9fb56ca2ee77c31536317d768398c36cfd0265b.json
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.