Skip to content

Commit

Permalink
Merge pull request #72 from Donut-DONationUTile/feature/wallet
Browse files Browse the repository at this point in the history
Feature/wallet
  • Loading branch information
Kang1221 authored Apr 30, 2024
2 parents 2bac1e4 + a3b46fe commit c6b7e72
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public interface GiftRepository extends JpaRepository<Gift, Long> {
"AND g.due_date BETWEEN :startDate AND :endDate", nativeQuery = true)
List<Gift> findAllByNotAssignedAndStatusAndDueDateBetween(String status,LocalDateTime startDate, LocalDateTime endDate);

@Query(value = "SELECT * FROM gift g WHERE g.auto_donation = true AND g.status = 'stored' AND g.giver_id = :giverId AND g.due_date >= :today", nativeQuery = true)
@Query(value = "SELECT * FROM gift g WHERE g.auto_donation = true AND g.status = 'STORED' AND g.giver_id = :giverId AND g.due_date >= :today", nativeQuery = true)
List<Gift> findAllByGiverAndStatusAndDueDateAfterOrToday(@Param("giverId") Long giverId, @Param("today") LocalDateTime today);

@Query(value = "SELECT COUNT(g) FROM gift g WHERE g.giver_id = :giverId AND g.is_assigned = false", nativeQuery = true)
Expand Down

0 comments on commit c6b7e72

Please sign in to comment.