-
Notifications
You must be signed in to change notification settings - Fork 0
[Feat] 회원가입 api 수정 #206
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
The head ref may contain hidden characters: "FLT-16-\uD68C\uC6D0\uAC00\uC785-api-\uC218\uC815"
Merged
[Feat] 회원가입 api 수정 #206
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
47db18b
feat: 회원가입 요청 모델 내 OTT 구독 정보 필드를 약관 동의 필드로 변경
ckals413 1ce6084
feat: 온보딩 장르 필터링 기능 구현 및 검색 API 연동
ckals413 57da146
Merge remote-tracking branch 'origin' into FLT-16-회원가입-api-수정
ckals413 9c0952f
feat: 온보딩 약관 동의 화면 기능 구현 및 API 연동
ckals413 47fa362
refactor: ID 타입을 Long에서 String으로 변경 및 검색 작업(Job) 관리 로직 개선
ckals413 3f9d920
fix: 취소된 요청에 대한 네트워크 에러 처리 제외
ckals413 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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,20 @@ | ||
| package com.flint.data.api | ||
|
|
||
| import com.flint.data.dto.base.BaseResponse | ||
| import com.flint.data.dto.terms.response.TermResponseDto | ||
| import com.flint.data.dto.terms.response.TermsListResponseDto | ||
| import retrofit2.http.GET | ||
| import retrofit2.http.Path | ||
| import retrofit2.http.Query | ||
|
|
||
| interface TermsApi { | ||
| @GET("/api/v1/terms") | ||
| suspend fun getTermsList( | ||
| @Query("type") type: String? = null, | ||
| ): BaseResponse<TermsListResponseDto> | ||
|
|
||
| @GET("/api/v1/terms/{termsId}") | ||
| suspend fun getTermsDetail( | ||
| @Path("termsId") termsId: Long, | ||
| ): BaseResponse<TermResponseDto> | ||
| } |
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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
22 changes: 22 additions & 0 deletions
22
app/src/main/java/com/flint/data/dto/terms/response/TermResponseDto.kt
This file contains hidden or 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,22 @@ | ||
| package com.flint.data.dto.terms.response | ||
|
|
||
| import kotlinx.serialization.SerialName | ||
| import kotlinx.serialization.Serializable | ||
|
|
||
| @Serializable | ||
| data class TermResponseDto( | ||
| @SerialName("id") | ||
| val id: String, | ||
| @SerialName("type") | ||
| val type: String, | ||
| @SerialName("version") | ||
| val version: Int, | ||
| @SerialName("title") | ||
| val title: String, | ||
| @SerialName("content") | ||
| val content: String, | ||
| @SerialName("required") | ||
| val required: Boolean, | ||
| @SerialName("activeAt") | ||
| val activeAt: String, | ||
| ) |
10 changes: 10 additions & 0 deletions
10
app/src/main/java/com/flint/data/dto/terms/response/TermsListResponseDto.kt
This file contains hidden or 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,10 @@ | ||
| package com.flint.data.dto.terms.response | ||
|
|
||
| import kotlinx.serialization.SerialName | ||
| import kotlinx.serialization.Serializable | ||
|
|
||
| @Serializable | ||
| data class TermsListResponseDto( | ||
| @SerialName("terms") | ||
| val terms: List<TermResponseDto>, | ||
| ) |
This file contains hidden or 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 hidden or 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
17 changes: 17 additions & 0 deletions
17
app/src/main/java/com/flint/domain/mapper/terms/TermsMapper.kt
This file contains hidden or 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.flint.domain.mapper.terms | ||
|
|
||
| import com.flint.data.dto.terms.response.TermResponseDto | ||
| import com.flint.domain.model.terms.TermModel | ||
|
|
||
| fun TermResponseDto.toModel(): TermModel = | ||
| TermModel( | ||
| id = id, | ||
| type = type, | ||
| version = version, | ||
| title = title, | ||
| content = content, | ||
| required = required, | ||
| activeAt = activeAt, | ||
| ) | ||
|
|
||
| fun List<TermResponseDto>.toModel(): List<TermModel> = map { it.toModel() } | ||
This file contains hidden or 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
11 changes: 11 additions & 0 deletions
11
app/src/main/java/com/flint/domain/model/terms/TermModel.kt
This file contains hidden or 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.flint.domain.model.terms | ||
|
|
||
| data class TermModel( | ||
| val id: String, | ||
| val type: String, | ||
| val version: Int, | ||
| val title: String, | ||
| val content: String, | ||
| val required: Boolean, | ||
| val activeAt: String, | ||
| ) |
This file contains hidden or 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: 16 additions & 0 deletions
16
app/src/main/java/com/flint/domain/repository/TermsRepository.kt
This file contains hidden or 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,16 @@ | ||
| package com.flint.domain.repository | ||
|
|
||
| import com.flint.core.common.util.suspendRunCatching | ||
| import com.flint.data.api.TermsApi | ||
| import com.flint.domain.mapper.terms.toModel | ||
| import com.flint.domain.model.terms.TermModel | ||
| import javax.inject.Inject | ||
|
|
||
| class TermsRepository @Inject constructor( | ||
| private val api: TermsApi, | ||
| ) { | ||
| suspend fun getTermsList(type: String? = null): Result<List<TermModel>> = | ||
| suspendRunCatching { | ||
| api.getTermsList(type).data.terms.toModel() | ||
| } | ||
| } |
This file contains hidden or 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
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.