Skip to content

Commit

Permalink
DC-6642 : new templates for P2 (#1182)
Browse files Browse the repository at this point in the history
* DC-6642 : new templates for P2

* Fixed the test failures
  • Loading branch information
satyajosyula2020 authored Sep 13, 2024
1 parent 1eedc9e commit 4b99ade
Show file tree
Hide file tree
Showing 11 changed files with 384 additions and 10 deletions.
36 changes: 26 additions & 10 deletions app/preview/TemplateParams.scala
Original file line number Diff line number Diff line change
Expand Up @@ -677,6 +677,18 @@ object TemplateParams {
"tax_estimate_message_alert_cy" -> Map(
"fullName" -> "Mr Joe Bloggs"
),
"daily_tax_estimate_message_alert" -> Map(
"fullName" -> "Mr Joe Bloggs"
),
"daily_tax_estimate_message_alert_cy" -> Map(
"fullName" -> "Mr Joe Bloggs"
),
"annual_tax_estimate_message_alert" -> Map(
"fullName" -> "Mr Joe Bloggs"
),
"annual_tax_estimate_message_alert_cy" -> Map(
"fullName" -> "Mr Joe Bloggs"
),
"fandf_ask_help_notification" -> Map(
"helperLastName" -> "Bloggs",
"helperFirstName" -> "Joe",
Expand Down Expand Up @@ -3106,16 +3118,20 @@ object TemplateParams2 {
"companyName" -> "Acquisitions Incorporated",
"submissionReference" -> "NC38-N2ZC-TH68"
),
"newMessageAlert_P800" -> newMessageAlert_Names,
"newMessageAlert_P800_cy" -> newMessageAlert_Names,
"newMessageAlert_PA302" -> newMessageAlert_Names,
"newMessageAlert_PA302_cy" -> newMessageAlert_Names,
"newMessageAlert_P800_D2" -> newMessageAlert_Names,
"newMessageAlert_P800_D2_cy" -> newMessageAlert_Names,
"newMessageAlert_PA302_D2" -> newMessageAlert_Names,
"newMessageAlert_PA302_D2_cy" -> newMessageAlert_Names,
"new_message_alert_itsa" -> newMessageAlert_Names,
"new_message_alert_itsa_cy" -> newMessageAlert_Names,
"newMessageAlert_P800" -> newMessageAlert_Names,
"newMessageAlert_P800_cy" -> newMessageAlert_Names,
"newMessageAlert_PA302" -> newMessageAlert_Names,
"newMessageAlert_PA302_cy" -> newMessageAlert_Names,
"newMessageAlert_P800_D2" -> newMessageAlert_Names,
"newMessageAlert_P800_D2_cy" -> newMessageAlert_Names,
"newMessageAlert_PA302_D2" -> newMessageAlert_Names,
"newMessageAlert_PA302_D2_cy" -> newMessageAlert_Names,
"new_message_alert_itsa" -> newMessageAlert_Names,
"new_message_alert_itsa_cy" -> newMessageAlert_Names,
"annual_tax_estimate_message_alert" -> newMessageAlert_Names,
"annual_tax_estimate_message_alert_cy" -> newMessageAlert_Names,
"daily_tax_estimate_message_alert" -> newMessageAlert_Names,
"daily_tax_estimate_message_alert_cy" -> newMessageAlert_Names,
"oss_registration_confirmation" -> Map(
"recipientName_line1" -> "Joe Bloggs",
"businessName" -> "Test Business",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,42 @@ object PayeTemplates {
plainTemplate = txt.newMessageAlert_PA302_cy.f,
htmlTemplate = html.newMessageAlert_PA302_cy.f,
priority = Some(MessagePriority.Standard)
),
MessageTemplate.create(
templateId = "daily_tax_estimate_message_alert",
fromAddress = defaultFromAddress,
service = PayAsYouEarn,
subject = "Your new tax calculation from HMRC is ready",
plainTemplate = txt.daily_tax_estimate_message_alert.f,
htmlTemplate = html.daily_tax_estimate_message_alert.f,
priority = Some(MessagePriority.Standard)
),
MessageTemplate.create(
templateId = "daily_tax_estimate_message_alert_cy",
fromAddress = defaultFromAddressWelsh,
service = PayAsYouEarn,
subject = "Mae’ch cyfrifiad treth newydd gan CThEF yn barod",
plainTemplate = txt.daily_tax_estimate_message_alert_cy.f,
htmlTemplate = html.daily_tax_estimate_message_alert_cy.f,
priority = Some(MessagePriority.Standard)
),
MessageTemplate.create(
templateId = "annual_tax_estimate_message_alert",
fromAddress = defaultFromAddress,
service = PayAsYouEarn,
subject = "Your new tax calculation from HMRC is ready",
plainTemplate = txt.annual_tax_estimate_message_alert.f,
htmlTemplate = html.annual_tax_estimate_message_alert.f,
priority = Some(MessagePriority.Standard)
),
MessageTemplate.create(
templateId = "annual_tax_estimate_message_alert_cy",
fromAddress = defaultFromAddressWelsh,
service = PayAsYouEarn,
subject = "Mae’ch cyfrifiad treth newydd gan CThEF yn barod",
plainTemplate = txt.annual_tax_estimate_message_alert_cy.f,
htmlTemplate = html.annual_tax_estimate_message_alert_cy.f,
priority = Some(MessagePriority.Standard)
)
)
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
@*
* Copyright 2023 HM Revenue & Customs
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*@

@import uk.gov.hmrc.hmrcemailrenderer.templates.TemplateUtils
@(params: Map[String, Any])
@uk.gov.hmrc.hmrcemailrenderer.templates.helpers.html.template_main(params, "You have a tax code change") {
<p style="margin: 0 0 30px; font-size: 19px;">Dear @{params("fullName")}</p>
<p style="margin: 0 0 30px; font-size: 19px;">Your PAYE Income Tax records have recently changed, which means the amount of tax you pay will change.</p>
<p style="margin: 0 0 0px; font-size: 19px;">For security reasons we do not give the full details here, but it could be because:</p>
<ul>

<li>we have now calculated your tax code for the next tax year (tax year 2024 to 2025)</li>
<li>your job changed</li>
<li>your pay changed</li>
<li>your company benefits, such as a company car changed</li>
<li>your pension changed</li></ul>
<p style="margin: 30px 0 30px; font-size: 19px;"><strong>How to check your details to make sure you pay the right amount of tax</strong></p>
<p style="margin: 0 0 30px; font-size: 19px;">Search GOV.UK for ‘personal tax account’, sign in and go to the ‘Pay As You Earn (PAYE)’ section.</p>
<p style="margin: 0 0 30px; font-size: 19px;">If you sign in using a business tax account, you may be able to use it to access your personal tax account.</p>
<p style="margin: 0 0 30px; font-size: 19px;"><strong>If you do not have a personal tax account</strong></p>
<p style="margin: 0 0 30px; font-size: 19px;">You need to set one up before you can see your tax code change.</p>
<p style="margin: 0 0 30px; font-size: 19px;">Search GOV.UK for ‘Personal tax account: sign in or set up’.</p>
<h2 id="why-you-got-this-email" style="margin: 0 0 30px; font-size: 24px;">Why you got this email</h2>
<p style="margin: 0 0 30px; font-size: 19px;">You got this email because you've chosen to receive email updates instead of letters by post.</p>
<p style="margin: 0 0 30px; font-size: 19px;">For security reasons we have not included any links in this email.</p>
<p style="margin: 0 0 30px; font-size: 19px;">From HMRC Check your Income Tax</p>
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
@import uk.gov.hmrc.hmrcemailrenderer.templates.TemplateUtils
@(params: Map[String, Any])You have a tax code change


Dear @{params("fullName")}

Your PAYE Income Tax records have recently changed, which means the amount of tax you pay will change.

For security reasons we do not give the full details here, but it could be because:


- we have now calculated your tax code for the next tax year (tax year 2024 to 2025)
- your job changed
- your pay changed
- your company benefits, such as a company car changed
- your pension changed


How to check your details to make sure you pay the right amount of tax

Search GOV.UK for ‘personal tax account’, sign in and go to the ‘Pay As You Earn (PAYE)’ section.

If you sign in using a business tax account, you may be able to use it to access your personal tax account.


If you do not have a personal tax account

You need to set one up before you can see your tax code change.

Search GOV.UK for ‘Personal tax account: sign in or set up’.


Why you got this email

You have chosen to receive email updates instead of letters by post.

For security reasons we have not included any links in this email.

From HMRC Check your Income Tax


@{uk.gov.hmrc.hmrcemailrenderer.templates.helpers.txt.template_footer()}
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
@*
* Copyright 2023 HM Revenue & Customs
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*@

@import uk.gov.hmrc.hmrcemailrenderer.templates.TemplateUtils
@(params: Map[String, Any])
@uk.gov.hmrc.hmrcemailrenderer.templates.helpers.html.template_main(params, "Mae’ch cod treth wedi newid", isWelsh = true) {
<p style="margin: 0 0 30px; font-size: 19px;">Annwyl @{params("fullName")}</p>
<p style="margin: 0 0 30px; font-size: 19px;">Mae’ch cofnodion Treth Incwm TWE wedi newid yn ddiweddar, sy’n golygu y bydd swm y dreth rydych yn ei thalu yn newid.</p>
<p style="margin: 0 0 0px; font-size: 19px;">Oherwydd rhesymau diogelwch, nid ydym yn rhoi’r manylion llawn yma ond gallai fod oherwydd y canlynol:</p>
<ul>
<li>rydym bellach wedi cyfrifo’ch cod treth ar gyfer y flwyddyn dreth nesaf (blwyddyn dreth 2024 i 2025)</li>
<li>newidiodd eich swydd</li>
<li>newidiodd eich cyflog</li>
<li>newidiodd eich buddiannau cwmni, megis car cwmni</li>
<li>newidiodd eich pensiwn</li></ul>
<p style="margin: 30px 0 30px; font-size: 19px;"><strong>Sut i wirio’ch cofnodion i wneud yn siŵr eich bod yn talu’r swm cywir o dreth</strong></p>
<p style="margin: 0 0 30px; font-size: 19px;">Chwiliwch am ‘personal tax account’ ar GOV.UK, mewngofnodwch ac ewch i’r adran ‘Talu Wrth Ennill (TWE)’.</p>
<p style="margin: 0 0 30px; font-size: 19px;">Os ydych yn mewngofnodi gan ddefnyddio cyfrif treth busnes, mae’n bosibl y gallwch ei ddefnyddio i gael mynediad at eich cyfrif treth personol.</p>
<p style="margin: 0 0 30px; font-size: 19px;"><strong>Os nad oes cyfrif treth personol gennych</strong></p>
<p style="margin: 0 0 30px; font-size: 19px;">Mae angen i chi greu un cyn y gallwch weld y newid i’ch cod treth.</p>
<p style="margin: 0 0 30px; font-size: 19px;">Chwiliwch am ‘Personal tax account: sign in or set up’ ar GOV.UK.</p>
<h2 id="why-you-got-this-email" style="margin: 0 0 30px; font-size: 24px;">Pam y cawsoch yr e-bost hwn</h2>
<p style="margin: 0 0 30px; font-size: 19px;">Rydych wedi dewis cael diweddariadau drwy e-bost yn hytrach na chael llythyrau drwy’r post.</p>
<p style="margin: 0 0 30px; font-size: 19px;">Am resymau diogelwch, nid ydym wedi cynnwys unrhyw gysylltiadau yn yr e-bost hwn.</p>
<p style="margin: 0 0 30px; font-size: 19px;">Oddi wrth CThEF: Gwirio’ch Treth Incwm</p>
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
@import uk.gov.hmrc.hmrcemailrenderer.templates.TemplateUtils
@(params: Map[String, Any])Mae’ch cod treth wedi newid


Annwyl @{params("fullName")}

Mae’ch cofnodion Treth Incwm TWE wedi newid yn ddiweddar, sy’n golygu y bydd swm y dreth rydych yn ei thalu yn newid.

Oherwydd rhesymau diogelwch, nid ydym yn rhoi’r manylion llawn yma ond gallai fod oherwydd y canlynol:

- rydym bellach wedi cyfrifo’ch cod treth ar gyfer y flwyddyn dreth nesaf (blwyddyn dreth 2024 i 2025)
- newidiodd eich swydd
- newidiodd eich cyflog
- newidiodd eich buddiannau cwmni, megis car cwmni
- newidiodd eich pensiwn


Sut i wirio’ch cofnodion i wneud yn siŵr eich bod yn talu’r swm cywir o dreth

Chwiliwch am ‘personal tax account’ ar GOV.UK, mewngofnodwch ac ewch i’r adran ‘Talu Wrth Ennill (TWE)’.

Os ydych yn mewngofnodi gan ddefnyddio cyfrif treth busnes, mae’n bosibl y gallwch ei ddefnyddio i gael mynediad at eich cyfrif treth personol.


Os nad oes cyfrif treth personol gennych

Mae angen i chi greu un cyn y gallwch weld y newid i’ch cod treth.

Chwiliwch am ‘Personal tax account: sign in or set up’ ar GOV.UK.


Pam y cawsoch yr e-bost hwn

Rydych wedi dewis cael diweddariadau drwy e-bost yn hytrach na chael llythyrau drwy’r post.

Am resymau diogelwch, nid ydym wedi cynnwys unrhyw gysylltiadau yn yr e-bost hwn.

Oddi wrth CThEF: Gwirio’ch Treth Incwm


@{uk.gov.hmrc.hmrcemailrenderer.templates.helpers.txt.template_footer_cy()}
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
@*
* Copyright 2023 HM Revenue & Customs
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*@

@import uk.gov.hmrc.hmrcemailrenderer.templates.TemplateUtils
@(params: Map[String, Any])
@uk.gov.hmrc.hmrcemailrenderer.templates.helpers.html.template_main(params, "You have a tax code change") {
<p style="margin: 0 0 30px; font-size: 19px;">Dear @{params("fullName")}</p>
<p style="margin: 0 0 30px; font-size: 19px;">Your PAYE Income Tax records have recently changed, which means the amount of tax you pay will change.</p>
<p style="margin: 0 0 0px; font-size: 19px;">For security reasons we do not give the full details here, but it could be because:</p>
<ul>
<li>your job changed</li>
<li>your pay changed</li>
<li>your company benefits, such as a company car changed</li>
<li>your pension changed</li></ul>
<p style="margin: 30px 0 30px; font-size: 19px;"><strong>How to check your details to make sure you pay the right amount of tax</strong></p>
<p style="margin: 0 0 30px; font-size: 19px;">Search GOV.UK for ‘personal tax account’, sign in and go to the ‘Pay As You Earn (PAYE)’ section.</p>
<p style="margin: 0 0 30px; font-size: 19px;">If you sign in using a business tax account, you may be able to use it to access your personal tax account.</p>
<p style="margin: 0 0 30px; font-size: 19px;"><strong>If you do not have a personal tax account</strong></p>
<p style="margin: 0 0 30px; font-size: 19px;">You need to set one up before you can see your tax code change.</p>
<p style="margin: 0 0 30px; font-size: 19px;">Search GOV.UK for ‘Personal tax account: sign in or set up’.</p>
<h2 id="why-you-got-this-email" style="margin: 0 0 30px; font-size: 24px;">Why you got this email</h2>
<p style="margin: 0 0 30px; font-size: 19px;">You got this email because you've chosen to receive email updates instead of letters by post.</p>
<p style="margin: 0 0 30px; font-size: 19px;">For security reasons we have not included any links in this email.</p>
<p style="margin: 0 0 30px; font-size: 19px;">From HMRC Check your Income Tax</p>
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
@import uk.gov.hmrc.hmrcemailrenderer.templates.TemplateUtils
@(params: Map[String, Any])You have a tax code change


Dear @{params("fullName")}

Your PAYE Income Tax records have recently changed, which means the amount of tax you pay will change.

For security reasons we do not give the full details here, but it could be because:

- your job changed
- your pay changed
- your company benefits, such as a company car changed
- your pension changed


How to check your details to make sure you pay the right amount of tax

Search GOV.UK for ‘personal tax account’, sign in and go to the ‘Pay As You Earn (PAYE)’ section.

If you sign in using a business tax account, you may be able to use it to access your personal tax account.


If you do not have a personal tax account

You need to set one up before you can see your tax code change.

Search GOV.UK for ‘Personal tax account: sign in or set up’.


Why you got this email

You have chosen to receive email updates instead of letters by post.

For security reasons we have not included any links in this email.

From HMRC Check your Income Tax


@{uk.gov.hmrc.hmrcemailrenderer.templates.helpers.txt.template_footer()}
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
@*
* Copyright 2023 HM Revenue & Customs
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*@

@import uk.gov.hmrc.hmrcemailrenderer.templates.TemplateUtils
@(params: Map[String, Any])
@uk.gov.hmrc.hmrcemailrenderer.templates.helpers.html.template_main(params, "Mae’ch cod treth wedi newid", isWelsh = true) {
<p style="margin: 0 0 30px; font-size: 19px;">Annwyl @{params("fullName")}</p>
<p style="margin: 0 0 30px; font-size: 19px;">Mae’ch cofnodion Treth Incwm TWE wedi newid yn ddiweddar, sy’n golygu y bydd swm y dreth rydych yn ei thalu yn newid.</p>
<p style="margin: 0 0 0px; font-size: 19px;">Oherwydd rhesymau diogelwch, nid ydym yn rhoi’r manylion llawn yma ond gallai fod oherwydd y canlynol:</p>
<ul>
<li>newidiodd eich swydd</li>
<li>newidiodd eich cyflog</li>
<li>newidiodd eich buddiannau cwmni, megis car cwmni</li>
<li>newidiodd eich pensiwn</li></ul>
<p style="margin: 30px 0 30px; font-size: 19px;"><strong>Sut i wirio’ch cofnodion i wneud yn siŵr eich bod yn talu’r swm cywir o dreth</strong></p>
<p style="margin: 0 0 30px; font-size: 19px;">Chwiliwch am ‘personal tax account’ ar GOV.UK, mewngofnodwch ac ewch i’r adran ‘Talu Wrth Ennill (TWE)’.</p>
<p style="margin: 0 0 30px; font-size: 19px;">Os ydych yn mewngofnodi gan ddefnyddio cyfrif treth busnes, mae’n bosibl y gallwch ei ddefnyddio i gael mynediad at eich cyfrif treth personol.</p>
<p style="margin: 0 0 30px; font-size: 19px;"><strong>Os nad oes cyfrif treth personol gennych</strong></p>
<p style="margin: 0 0 30px; font-size: 19px;">Mae angen i chi greu un cyn y gallwch weld y newid i’ch cod treth.</p>
<p style="margin: 0 0 30px; font-size: 19px;">Chwiliwch am ‘Personal tax account: sign in or set up’ ar GOV.UK.</p>
<h2 id="why-you-got-this-email" style="margin: 0 0 30px; font-size: 24px;">Pam y cawsoch yr e-bost hwn</h2>
<p style="margin: 0 0 30px; font-size: 19px;">Rydych wedi dewis cael diweddariadau drwy e-bost yn hytrach na chael llythyrau drwy’r post.</p>
<p style="margin: 0 0 30px; font-size: 19px;">Am resymau diogelwch, nid ydym wedi cynnwys unrhyw gysylltiadau yn yr e-bost hwn.</p>
<p style="margin: 0 0 30px; font-size: 19px;">Oddi wrth CThEF: Gwirio’ch Treth Incwm</p>
}
Loading

0 comments on commit 4b99ade

Please sign in to comment.