updated code

This commit is contained in:
rajesh
2024-11-25 11:21:56 +05:30
parent 5fc9ca3774
commit 24a1bc024f

View File

@@ -833,9 +833,9 @@ public class ApplicationAmendmentRequestDao {
public ApplicationAmendmentRequestResponse updateApplicationAmendmentStatus( public ApplicationAmendmentRequestResponse updateApplicationAmendmentStatus(
Long id, ApplicationAmendmentRequestEnum statusTypeEnum) { Long id, ApplicationAmendmentRequestEnum statusTypeEnum) {
log.info("Updating application amendement with status: {}", id); log.info("Updating application amendment with status: {}", id);
ApplicationAmendmentRequestEntity existingApplicationAmendment = validateApplicationAmendmentRequest(id); ApplicationAmendmentRequestEntity existingApplicationAmendment = validateApplicationAmendmentRequest(id);
if (Boolean.TRUE.equals(existingApplicationAmendment.getStatus().equals(ApplicationAmendmentRequestEnum.AWAITING.getValue())) && Boolean.TRUE.equals(statusTypeEnum.equals(ApplicationAmendmentRequestEnum.RESPONSE_RECEIVED))) { if (Boolean.TRUE.equals(existingApplicationAmendment.getStatus().equals(ApplicationAmendmentRequestEnum.AWAITING.getValue())) || Boolean.TRUE.equals(statusTypeEnum.equals(ApplicationAmendmentRequestEnum.RESPONSE_RECEIVED))) {
existingApplicationAmendment.setStatus(ApplicationAmendmentRequestEnum.RESPONSE_RECEIVED.getValue()); existingApplicationAmendment.setStatus(ApplicationAmendmentRequestEnum.RESPONSE_RECEIVED.getValue());
existingApplicationAmendment.setUpdatedDate(DateTimeUtil.DateServerToUTC(LocalDateTime.now())); existingApplicationAmendment.setUpdatedDate(DateTimeUtil.DateServerToUTC(LocalDateTime.now()));
applicationAmendmentRequestRepository.save(existingApplicationAmendment); applicationAmendmentRequestRepository.save(existingApplicationAmendment);