Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NFDIV-4355 - Send email and letter to citizen when representation is removed by CW #4168

Open
wants to merge 9 commits into
base: NFDIV-4356-backend
Choose a base branch
from

Conversation

pallavijustice
Copy link
Contributor

Change description

Send email and letter to citizen when representation is removed by CW.
Send to joint applicants if both applicants are already identified in system as online.

JIRA link (if applicable)

https://tools.hmcts.net/jira/browse/NFDIV-4355

Comment on lines 144 to 145
if (beforeApplicant.getEmail() != null && !beforeApplicant.getEmail().isBlank()
&& (applicant.getEmail() == null || applicant.getEmail().isBlank())) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: I was thinking we could start simplifying this common pattern we have in the code with StringUtils to make it easier to read 🤔

Suggested change
if (beforeApplicant.getEmail() != null && !beforeApplicant.getEmail().isBlank()
&& (applicant.getEmail() == null || applicant.getEmail().isBlank())) {
if (isNotBlank(beforeApplicant.getEmail()) && isBlank(applicant.getEmail())) {

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change made

Comment on lines 340 to 343
if (data.getApplicationType() == ApplicationType.SOLE_APPLICATION) {
return true;
}
return false;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit:

Suggested change
if (data.getApplicationType() == ApplicationType.SOLE_APPLICATION) {
return true;
}
return false;
return data.getApplicationType() == ApplicationType.SOLE_APPLICATION;

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change made

@@ -49,6 +49,23 @@ public void sendNOC(final ApplicantNotification applicantNotification,
}
}

// Need different logic for NOC notification when sending invite to citizen
public void sendNOCToParty(final ApplicantNotification applicantNotification,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure how best to name this so people can distinguish it from sendNOC in the future - do you think we should include CaseInvite in the name and then you may be able to remove the comment?

Suggested change
public void sendNOCToParty(final ApplicantNotification applicantNotification,
public void sendNOCCaseInvite(final ApplicantNotification applicantNotification,

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes made to rename method

Copy link

github-actions bot commented Dec 8, 2024

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@github-actions github-actions bot added the stale label Dec 8, 2024
Copy link

This issue has been automatically closed because it has been stalled for 2 days with no activity.

@github-actions github-actions bot closed this Dec 10, 2024
@github-actions github-actions bot removed the stale label Dec 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants