-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
�ReceiptOption 날짜 컬럼 Flyway 스키마 추가 (#336)
- Loading branch information
Showing
15 changed files
with
79 additions
and
51 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#!/bin/bash | ||
|
||
mkdir -p /home/ec2-user/cicd/backup | ||
cp /home/ec2-user/cicd/src/main/resources/application-prod.yml /home/ec2-user/cicd/backup/ |
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 @@ | ||
#!/bin/bash | ||
|
||
if [ -f /home/ec2-user/cicd/backup/application-prod.yml ]; then | ||
cp /home/ec2-user/cicd/backup/application-prod.yml /home/ec2-user/cicd/src/main/resources/application-prod.yml | ||
fi |
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
16 changes: 4 additions & 12 deletions
16
.../java/org/kakaoshare/backend/domain/member/dto/oauth/authenticate/OAuthLoginResponse.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 |
---|---|---|
@@ -1,15 +1,7 @@ | ||
package org.kakaoshare.backend.domain.member.dto.oauth.authenticate; | ||
|
||
import lombok.Builder; | ||
import org.kakaoshare.backend.domain.member.dto.oauth.profile.OAuthProfile; | ||
import org.kakaoshare.backend.domain.member.dto.oauth.token.RefreshTokenDto; | ||
import org.kakaoshare.backend.domain.member.entity.token.RefreshToken; | ||
|
||
@Builder | ||
public record OAuthLoginResponse(String accessToken, RefreshTokenDto refreshToken, OAuthLoginMemberResponse member) { | ||
public static OAuthLoginResponse of(final String accessToken, | ||
final RefreshToken refreshToken, | ||
final OAuthProfile oAuthProfile) { | ||
return new OAuthLoginResponse(accessToken, RefreshTokenDto.from(refreshToken), OAuthLoginMemberResponse.from(oAuthProfile)); | ||
public record OAuthLoginResponse(String accessToken, OAuthLoginMemberResponse member) { | ||
public static OAuthLoginResponse from(final OAuthLoginResult oAuthLoginResult) { | ||
return new OAuthLoginResponse(oAuthLoginResult.accessToken(), oAuthLoginResult.member()); | ||
} | ||
} | ||
} |
15 changes: 15 additions & 0 deletions
15
...in/java/org/kakaoshare/backend/domain/member/dto/oauth/authenticate/OAuthLoginResult.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,15 @@ | ||
package org.kakaoshare.backend.domain.member.dto.oauth.authenticate; | ||
|
||
import lombok.Builder; | ||
import org.kakaoshare.backend.domain.member.dto.oauth.profile.OAuthProfile; | ||
import org.kakaoshare.backend.domain.member.dto.oauth.token.RefreshTokenDto; | ||
import org.kakaoshare.backend.domain.member.entity.token.RefreshToken; | ||
|
||
@Builder | ||
public record OAuthLoginResult(String accessToken, RefreshTokenDto refreshToken, OAuthLoginMemberResponse member) { | ||
public static OAuthLoginResult of(final String accessToken, | ||
final RefreshToken refreshToken, | ||
final OAuthProfile oAuthProfile) { | ||
return new OAuthLoginResult(accessToken, RefreshTokenDto.from(refreshToken), OAuthLoginMemberResponse.from(oAuthProfile)); | ||
} | ||
} |
7 changes: 4 additions & 3 deletions
7
src/main/java/org/kakaoshare/backend/domain/member/repository/MemberRepository.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 |
---|---|---|
@@ -1,15 +1,16 @@ | ||
package org.kakaoshare.backend.domain.member.repository; | ||
|
||
import java.util.List; | ||
import org.kakaoshare.backend.domain.member.entity.Member; | ||
import org.kakaoshare.backend.domain.member.repository.query.MemberRepositoryCustom; | ||
import org.springframework.data.jpa.repository.JpaRepository; | ||
import org.springframework.data.jpa.repository.Query; | ||
import org.springframework.data.repository.query.Param; | ||
|
||
import java.util.List; | ||
import java.util.Optional; | ||
import org.springframework.data.jpa.repository.Query; | ||
|
||
public interface MemberRepository extends JpaRepository<Member, Long>, MemberRepositoryCustom { | ||
Optional<Member> findMemberByProviderId(String providerId); | ||
@Query("SELECT m FROM Member m WHERE m.providerId IN :providerIds") | ||
List<Member> findByProviderIds(List<String> providerIds); | ||
List<Member> findByProviderIds(@Param("providerIds") List<String> providerIds); | ||
} |
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
3 changes: 3 additions & 0 deletions
3
src/main/resources/db/migration/V11__add_receipt_option_date_column.sql
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,3 @@ | ||
ALTER TABLE receipt_option | ||
ADD COLUMN created_at datetime(6) null, | ||
ADD COLUMN updated_at datetime(6) null; |
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