-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #191 from Nexters/feature/190
Feature/190 : νμκ°μ μλͺ¨κΆ νμ λ λλ§ νλκ·Έ API
- Loading branch information
Showing
12 changed files
with
224 additions
and
7 deletions.
There are no files selected for viewing
41 changes: 41 additions & 0 deletions
41
src/main/generated/com/nexters/dailyphrase/prize/domain/QPrizeTicketPopupCheck.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
package com.nexters.dailyphrase.prize.domain; | ||
|
||
import static com.querydsl.core.types.PathMetadataFactory.*; | ||
|
||
import com.querydsl.core.types.dsl.*; | ||
|
||
import com.querydsl.core.types.PathMetadata; | ||
import javax.annotation.processing.Generated; | ||
import com.querydsl.core.types.Path; | ||
|
||
|
||
/** | ||
* QPrizeTicketPopupCheck is a Querydsl query type for PrizeTicketPopupCheck | ||
*/ | ||
@Generated("com.querydsl.codegen.DefaultEntitySerializer") | ||
public class QPrizeTicketPopupCheck extends EntityPathBase<PrizeTicketPopupCheck> { | ||
|
||
private static final long serialVersionUID = -2068721456L; | ||
|
||
public static final QPrizeTicketPopupCheck prizeTicketPopupCheck = new QPrizeTicketPopupCheck("prizeTicketPopupCheck"); | ||
|
||
public final NumberPath<Long> id = createNumber("id", Long.class); | ||
|
||
public final NumberPath<Long> memberId = createNumber("memberId", Long.class); | ||
|
||
public final EnumPath<com.nexters.dailyphrase.common.enums.PrizeTicketPopupType> type = createEnum("type", com.nexters.dailyphrase.common.enums.PrizeTicketPopupType.class); | ||
|
||
public QPrizeTicketPopupCheck(String variable) { | ||
super(PrizeTicketPopupCheck.class, forVariable(variable)); | ||
} | ||
|
||
public QPrizeTicketPopupCheck(Path<? extends PrizeTicketPopupCheck> path) { | ||
super(path.getType(), path.getMetadata()); | ||
} | ||
|
||
public QPrizeTicketPopupCheck(PathMetadata metadata) { | ||
super(PrizeTicketPopupCheck.class, metadata); | ||
} | ||
|
||
} | ||
|
5 changes: 5 additions & 0 deletions
5
src/main/java/com/nexters/dailyphrase/common/enums/PrizeTicketPopupType.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
package com.nexters.dailyphrase.common.enums; | ||
|
||
public enum PrizeTicketPopupType { | ||
GET_BY_SIGNUP | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 23 additions & 0 deletions
23
src/main/java/com/nexters/dailyphrase/prize/domain/PrizeTicketPopupCheck.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package com.nexters.dailyphrase.prize.domain; | ||
|
||
import jakarta.persistence.*; | ||
|
||
import com.nexters.dailyphrase.common.enums.PrizeTicketPopupType; | ||
|
||
import lombok.*; | ||
|
||
@Entity | ||
@Getter | ||
@Builder | ||
@NoArgsConstructor(access = AccessLevel.PROTECTED) | ||
@AllArgsConstructor | ||
public class PrizeTicketPopupCheck { | ||
@Id | ||
@GeneratedValue(strategy = GenerationType.IDENTITY) | ||
private Long id; | ||
|
||
private Long memberId; | ||
|
||
@Enumerated(EnumType.STRING) | ||
private PrizeTicketPopupType type; | ||
} |
11 changes: 11 additions & 0 deletions
11
...java/com/nexters/dailyphrase/prize/domain/repository/PrizeTicketPopupCheckRepository.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package com.nexters.dailyphrase.prize.domain.repository; | ||
|
||
import org.springframework.data.jpa.repository.JpaRepository; | ||
|
||
import com.nexters.dailyphrase.common.enums.PrizeTicketPopupType; | ||
import com.nexters.dailyphrase.prize.domain.PrizeTicketPopupCheck; | ||
|
||
public interface PrizeTicketPopupCheckRepository | ||
extends JpaRepository<PrizeTicketPopupCheck, Long> { | ||
boolean existsByMemberIdAndType(Long memberId, PrizeTicketPopupType type); | ||
} |
17 changes: 17 additions & 0 deletions
17
...ain/java/com/nexters/dailyphrase/prize/implement/PrizeTicketPopupCheckCommandAdapter.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
package com.nexters.dailyphrase.prize.implement; | ||
|
||
import com.nexters.dailyphrase.common.annotation.Adapter; | ||
import com.nexters.dailyphrase.prize.domain.PrizeTicketPopupCheck; | ||
import com.nexters.dailyphrase.prize.domain.repository.PrizeTicketPopupCheckRepository; | ||
|
||
import lombok.RequiredArgsConstructor; | ||
|
||
@Adapter | ||
@RequiredArgsConstructor | ||
public class PrizeTicketPopupCheckCommandAdapter { | ||
private final PrizeTicketPopupCheckRepository prizeTicketPopupCheckRepository; | ||
|
||
public PrizeTicketPopupCheck add(PrizeTicketPopupCheck prizeTicketPopupCheck) { | ||
return prizeTicketPopupCheckRepository.save(prizeTicketPopupCheck); | ||
} | ||
} |
17 changes: 17 additions & 0 deletions
17
src/main/java/com/nexters/dailyphrase/prize/implement/PrizeTicketPopupCheckQueryAdapter.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
package com.nexters.dailyphrase.prize.implement; | ||
|
||
import com.nexters.dailyphrase.common.annotation.Adapter; | ||
import com.nexters.dailyphrase.common.enums.PrizeTicketPopupType; | ||
import com.nexters.dailyphrase.prize.domain.repository.PrizeTicketPopupCheckRepository; | ||
|
||
import lombok.RequiredArgsConstructor; | ||
|
||
@Adapter | ||
@RequiredArgsConstructor | ||
public class PrizeTicketPopupCheckQueryAdapter { | ||
private final PrizeTicketPopupCheckRepository prizeTicketPopupCheckRepository; | ||
|
||
public boolean existsByMemberIdAndType(Long memberId, PrizeTicketPopupType type) { | ||
return prizeTicketPopupCheckRepository.existsByMemberIdAndType(memberId, type); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters