|
|
@@ -140,6 +140,6 @@ public interface AssetRepo extends JpaRepository<Asset, Long>, JpaSpecificationE
|
|
|
@Query(value = "select * from asset where name like ?1 and status in ?2 and id not in ?3 and del = false", nativeQuery = true)
|
|
|
List<Asset> findAllBoats(String name, List<AssetStatus> status, List<Long> boatIds);
|
|
|
|
|
|
- @Query("select count(id) from Asset where name like ?1 and status = 'NORMAL' and ownerId = ?2")
|
|
|
- Long countNameLikeNotDestroyedAndOwner(String name,Long ownerId);
|
|
|
+ @Query(value = "SELECT count(a.id) from asset a where a.name LIKE ?1 and status = 'NORMAL' and owner_id = ?2", nativeQuery = true)
|
|
|
+ Long countNameLikeNotDestroyedAndOwner(String name, Long ownerId);
|
|
|
}
|