Updated code for file detail in amendment

This commit is contained in:
nisha
2024-12-13 17:48:02 +05:30
parent 2b93145b5e
commit 709d40e032
2 changed files with 9 additions and 5 deletions

View File

@@ -376,10 +376,12 @@ public class ApplicationAmendmentRequestDao {
amendmentDocumentResponse.setFieldId(amendmentFieldRequest.getFieldId());
amendmentDocumentResponse.setNameValue(amendmentFieldRequest.getNameValue());
amendmentDocumentResponse.setValid(amendmentFieldRequest.getValid());
DocumentEntity documentEntity = documentService.validateDocument(Long.valueOf(amendmentFieldRequest.getFileValue()));
DocumentResponseBean responseBean = applicationEvaluationDao.createDocumentResponseBean(documentEntity);
amendmentDocumentResponse.setFileValue(responseBean);
amendmentDocumentResponse.setFileValue(null);
if(amendmentFieldRequest.getFileValue()!=null) {
DocumentEntity documentEntity = documentService.validateDocument(Long.valueOf(amendmentFieldRequest.getFileValue()));
DocumentResponseBean responseBean = applicationEvaluationDao.createDocumentResponseBean(documentEntity);
amendmentDocumentResponse.setFileValue(List.of(responseBean));
}
return amendmentDocumentResponse;
}