Resolved Conflicts
This commit is contained in:
@@ -40,5 +40,6 @@ public interface ApplicationRepository extends JpaRepository<ApplicationEntity,
|
||||
@Query("SELECT COUNT(a) FROM ApplicationEntity a WHERE a.status = 'DRAFT' And a.hubId = :hubId")
|
||||
public Long countDraftApplicationsByHubId(@Param("hubId") Long hubId);
|
||||
|
||||
|
||||
@Query("SELECT a.call.id FROM ApplicationEntity a WHERE a.id = :id")
|
||||
Long findCallIdById(@Param("id") Long id);
|
||||
}
|
||||
|
||||
@@ -1,13 +1,24 @@
|
||||
package net.gepafin.tendermanagement.repositories;
|
||||
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
import org.springframework.data.jpa.repository.Query;
|
||||
import org.springframework.data.repository.query.Param;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import net.gepafin.tendermanagement.entities.ApplicationSignedDocumentEntity;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Repository
|
||||
public interface ApplicationSignedDocumentRepository extends JpaRepository<ApplicationSignedDocumentEntity, Long> {
|
||||
|
||||
ApplicationSignedDocumentEntity findByApplicationIdAndStatus(Long applicationId, String status);
|
||||
|
||||
Long findApplicationIdById(Long id);
|
||||
|
||||
@Query("SELECT a.id FROM ApplicationSignedDocumentEntity d JOIN d.application a WHERE d.id = :id")
|
||||
List<Long> findApplicationIdIdsById(@Param("id") Long id);
|
||||
|
||||
@Query("SELECT d FROM ApplicationSignedDocumentEntity d WHERE d.status = :status")
|
||||
List<ApplicationSignedDocumentEntity> findAllByIsStatus(@Param("status")String status);
|
||||
}
|
||||
|
||||
@@ -25,5 +25,7 @@ public interface DocumentRepository extends JpaRepository<DocumentEntity, Long>
|
||||
|
||||
Optional<DocumentEntity> findByIdAndSourceIdAndSourceAndIsDeletedFalse(Long id, Long sourceId, String source);
|
||||
|
||||
@Query("SELECT d FROM DocumentEntity d WHERE d.isDeleted = false")
|
||||
List<DocumentEntity> findAllByIsDeleteFalse();
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,24 @@
|
||||
package net.gepafin.tendermanagement.repositories;
|
||||
|
||||
import net.gepafin.tendermanagement.entities.S3ConfigEntity;
|
||||
import net.gepafin.tendermanagement.enums.DocOtherSourceTypeEnum;
|
||||
import net.gepafin.tendermanagement.enums.DocumentSourceTypeEnum;
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
import org.springframework.data.jpa.repository.Query;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.Optional;
|
||||
|
||||
@Repository
|
||||
public interface S3ConfigRepository extends JpaRepository<S3ConfigEntity, Long> {
|
||||
Optional<S3ConfigEntity> getPathByType(String type);
|
||||
|
||||
S3ConfigEntity findS3PathConfigurationById(Long id);
|
||||
|
||||
String getBucketNameByType(DocumentSourceTypeEnum type);
|
||||
|
||||
String getBucketNameByType(DocOtherSourceTypeEnum type);
|
||||
|
||||
@Query("Select s3.parentFolder From S3ConfigEntity s3 Where s3.type = :s")
|
||||
String getPathByTypeOther(String s);
|
||||
}
|
||||
@@ -2,9 +2,15 @@ package net.gepafin.tendermanagement.repositories;
|
||||
|
||||
import org.springframework.data.jpa.repository.JpaRepository;
|
||||
import net.gepafin.tendermanagement.entities.UserCompanyDelegationEntity;
|
||||
import org.springframework.data.jpa.repository.Query;
|
||||
import org.springframework.data.repository.query.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface UserCompanyDelegationRepository extends JpaRepository<UserCompanyDelegationEntity, Long> {
|
||||
|
||||
UserCompanyDelegationEntity findByUserIdAndCompanyIdAndStatus(Long userId, Long companyId, String status);
|
||||
|
||||
@Query("SELECT d FROM UserCompanyDelegationEntity d where d.status = :status")
|
||||
List<UserCompanyDelegationEntity> findAllByStatus(@Param("status") String status);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user