Skip to content

Commit

Permalink
[MMCA-4896] Send email notification for requested CSV cash account tr…
Browse files Browse the repository at this point in the history
…ansactions (#1186)

* [MMCA-4896] Send email notification for requested CSV cash account transactions

* [MMCA-4896] Fixing unit tests and typo fix

* [MMCA-4896] PR comments resolved
  • Loading branch information
wg-hmrc authored Sep 26, 2024
1 parent c59564d commit 1213d60
Show file tree
Hide file tree
Showing 6 changed files with 86 additions and 0 deletions.
3 changes: 3 additions & 0 deletions app/preview/TemplateParams.scala
Original file line number Diff line number Diff line change
Expand Up @@ -3767,6 +3767,9 @@ object TemplateParams3 {
"customs_financials_requested_notification_adjustment_statements_not_found" -> Map(
"recipientName_FullName" -> "ABC ltd"
),
"customs_financials_requested_cash_account_transactions" -> Map(
"recipientName_FullName" -> "ABC ltd"
),
"undertaking_admin_deadline_reminder" -> Map(
"deadline" -> "23 November 2023"
),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,15 @@ object CustomsFinancialsTemplates {
plainTemplate = txt.requestedNotificationAdjustmentStatementsNotFound.f,
htmlTemplate = html.requestedNotificationAdjustmentStatementsNotFound.f,
priority = Some(MessagePriority.Standard)
),
MessageTemplate.create(
templateId = "customs_financials_requested_cash_account_transactions",
fromAddress = govUkTeamAddress,
service = CustomsFinancials,
subject = "Requested cash account transactions are now available",
plainTemplate = txt.requestedCashAccountTransactions.f,
htmlTemplate = html.requestedCashAccountTransactions.f,
priority = Some(MessagePriority.Standard)
)
)
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
@*
* Copyright 2024 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.
*@

@(params: Map[String, Any])
@title = @{"Requested cash account transactions are now available"}

@uk.gov.hmrc.hmrcemailrenderer.templates.helpers.html.template_main(params, title) {

@uk.gov.hmrc.hmrcemailrenderer.templates.helpers.html.salutationLine1(params)

<div style="font-size: 19px;line-height: 1.315789474;margin: 0 0 30px 0;">

<p>Your requested cash account transactions are availble to view and download for the next 10 days.</p>

<p>To access your transactions:</p>

<ol>
<li>Go to GOV.UK.</li>
<li>Search for 'Use a cash account for Customs Declaration Service declarations'.</li>
</ol>

<p>For security reasons, we have not included a link in this email.</p>

<h4>If you need help</h4>

<p>Phone HMRC on 0300 059 4243. Opening times 9am to 12pm and 2pm to 4pm, Monday to Friday (closed bank holidays).</p>

<p>From the Customs Declaration Service</p>

</div>

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
@(params: Map[String, Any])Requested cash account transactions are now available

@uk.gov.hmrc.hmrcemailrenderer.templates.helpers.txt.salutation(params)

Your requested cash account transactions are availble to view and download for the next 10 days.

To access your transactions:

Go to GOV.UK.

Search for 'Use a cash account for Customs Declaration Service declarations'.

For security reasons, we have not included a link in this email.

If you need help

Phone HMRC on 0300 059 4243. Opening times 9am to 12pm and 2pm to 4pm, Monday to Friday (closed bank holidays).

From the Customs Declaration Service

@{uk.gov.hmrc.hmrcemailrenderer.templates.helpers.txt.template_footer()}
Original file line number Diff line number Diff line change
Expand Up @@ -379,6 +379,7 @@ class TemplateLocatorSpec extends AnyWordSpecLike with should.Matchers with Opti
"customs_financials_requested_c79_certificate_not_found",
"customs_financials_requested_postponed_import_vat_statements_not_found",
"customs_financials_requested_notification_adjustment_statements_not_found",
"customs_financials_requested_cash_account_transactions",
"customs_migrate_not_successful",
"customs_migrate_successful",
"customs_payment_required",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,13 @@ class CustomsFinancialsSpec extends TemplateComparisonSpec with CommonParamsForS
)
}

"have matching content in customs_financials_requested_cash_account_transactions" in {
val params = commonParameters ++ Map("recipientName_FullName" -> "ABC ltd")

compareContent("customs_financials_requested_cash_account_transactions", params)(
customsFinancialsTemplate
)
}
}

}

0 comments on commit 1213d60

Please sign in to comment.