Skip to content

Commit

Permalink
Add organisation_privacy_notice_url personalisation
Browse files Browse the repository at this point in the history
This ensures that the variable is provided to any templates used in
GOV.UK Notify to allow it to be shown to users.
  • Loading branch information
thomasleese committed Dec 14, 2024
1 parent 3e85432 commit 3a95c45
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
5 changes: 5 additions & 0 deletions app/lib/govuk_notify_personalisation.rb
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ def call
next_session_dates:,
next_session_dates_or:,
not_catch_up:,
organisation_privacy_notice_url:,
organisation_privacy_policy_url:,
outcome_administered:,
outcome_not_administered:,
Expand Down Expand Up @@ -159,6 +160,10 @@ def next_session_dates_or
.to_sentence(last_word_connector: ", or ", two_words_connector: " or ")
end

def organisation_privacy_notice_url
organisation.privacy_notice_url
end

def organisation_privacy_policy_url
organisation.privacy_policy_url
end
Expand Down
3 changes: 2 additions & 1 deletion spec/lib/govuk_notify_personalisation_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@
next_session_dates: "Thursday 1 January",
next_session_dates_or: "Thursday 1 January",
not_catch_up: "yes",
organisation_privacy_policy_url: "https://example.com/privacy",
organisation_privacy_notice_url: "https://example.com/privacy-notice",
organisation_privacy_policy_url: "https://example.com/privacy-policy",
programme_name: "HPV",
short_patient_name: "John",
short_patient_name_apos: "John’s",
Expand Down

0 comments on commit 3a95c45

Please sign in to comment.