|
|
@@ -4,6 +4,7 @@ import com.izouma.nineth.dto.UserBankCard;
|
|
|
import org.springframework.data.jpa.repository.JpaRepository;
|
|
|
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
|
|
|
import org.springframework.data.jpa.repository.Modifying;
|
|
|
+import org.springframework.data.jpa.repository.Query;
|
|
|
|
|
|
import javax.transaction.Transactional;
|
|
|
import java.util.List;
|
|
|
@@ -14,4 +15,9 @@ public interface UserBankCardRepo extends JpaRepository<UserBankCard, Long>, Jpa
|
|
|
@Transactional
|
|
|
@Modifying
|
|
|
int deleteByUserId(Long userId);
|
|
|
+
|
|
|
+ @Query("select count(t) from UserBankCard t where t.userId = ?1")
|
|
|
+ @Modifying
|
|
|
+ @Transactional
|
|
|
+ Integer findByUserIds(Long id);
|
|
|
}
|