Amendment request mail changes

This commit is contained in:
rajesh
2025-09-17 16:50:53 +05:30
parent d877db39fa
commit 446b304e75
2 changed files with 28 additions and 3 deletions

View File

@@ -18,6 +18,7 @@ import net.gepafin.tendermanagement.service.impl.EmailServiceFactory;
import net.gepafin.tendermanagement.util.DateTimeUtil;
import net.gepafin.tendermanagement.service.impl.SystemEmailService;
import net.gepafin.tendermanagement.util.Utils;
import net.gepafin.tendermanagement.util.Validator;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
@@ -76,6 +77,9 @@ public class EmailNotificationDao {
@Autowired
private SystemEmailTemplatesDao systemEmailTemplatesDao;
@Autowired
private Validator validator;
private void sendEmail(ApplicationEntity applicationEntity, SystemEmailTemplatesEntity.SystemEmailTemplatesEntityTypeEnum templateType, Map<String, String> bodyPlaceholders,
List<String> additionalRecipients, Long amendmentId) {
@@ -95,8 +99,10 @@ public class EmailNotificationDao {
Map<String, String> bodyPlaceholders
) {
SystemEmailTemplateResponse systemEmailTemplateResponse = systemEmailTemplatesService.retrieveTemplateByTypeAndCall(templateType, hubEntity, null);
Map<String, String> subjectPlaceholders = new HashMap<>();
if(Boolean.TRUE.equals(templateType.equals(SystemEmailTemplatesEntity.SystemEmailTemplatesEntityTypeEnum.DOCUMENTATION_INTEGRATION_REQUEST)) && Boolean.TRUE.equals(validator.isProductionProfileActivated()) && applicationEntity.getCall().getId().equals(23l)) {
systemEmailTemplateResponse.setHtmlContent(systemEmailTemplatesDao.replaceEmailSignature(hubEntity,GepafinConstant.APPLICATION_AMENDMENT_REQUESTED_MAIL_BODY,null));
}
Map<String, String> subjectPlaceholders = new HashMap<>();
CompanyEntity company = companyService.validateCompany(applicationEntity.getCompanyId());
subjectPlaceholders.put("{{call_name}}", applicationEntity.getCall().getName());
subjectPlaceholders.put("{{company_name}}", company.getCompanyName());