Updated code for company document
This commit is contained in:
@@ -2668,7 +2668,7 @@ public class ApplicationDao {
|
|||||||
public List<CompanyDocumentEntity> validateCompanyDocuments(List<Long> ids) {
|
public List<CompanyDocumentEntity> validateCompanyDocuments(List<Long> ids) {
|
||||||
|
|
||||||
List<CompanyDocumentEntity> documents =
|
List<CompanyDocumentEntity> documents =
|
||||||
companyDocumentRepository.findByIdInAndIsDeletedFalseAndStatus(ids,CompanyDocumentStatusEnum.VALID.getValue());
|
companyDocumentRepository.findByIdInAndIsDeletedFalseAndStatusNot(ids,CompanyDocumentStatusEnum.EXPIRED.getValue());
|
||||||
|
|
||||||
Set<Long> foundIds = documents.stream()
|
Set<Long> foundIds = documents.stream()
|
||||||
.map(CompanyDocumentEntity::getId)
|
.map(CompanyDocumentEntity::getId)
|
||||||
|
|||||||
@@ -35,7 +35,7 @@ public interface CompanyDocumentRepository extends JpaRepository<CompanyDocument
|
|||||||
|
|
||||||
List<CompanyDocumentEntity> findByCategoryEntityId(Long categoryId);
|
List<CompanyDocumentEntity> findByCategoryEntityId(Long categoryId);
|
||||||
|
|
||||||
List<CompanyDocumentEntity> findByIdInAndIsDeletedFalseAndStatus(List<Long> ids,String status);
|
List<CompanyDocumentEntity> findByIdInAndIsDeletedFalseAndStatusNot(List<Long> ids, String status);
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user