-
Notifications
You must be signed in to change notification settings - Fork 1
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 #101 from Begin-Vegan/feature/BVVER24-145-mypage-mโฆ
โฆy-recipe-api Mypage ๋์ ๋ ์ํผ API ์ฐ๊ฒฐ
- Loading branch information
Showing
33 changed files
with
418 additions
and
30 deletions.
There are no files selected for viewing
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified
BIN
+0 Bytes
(100%)
buildSrc/.gradle/8.4/executionHistory/executionHistory.lock
Binary file not shown.
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
15 changes: 15 additions & 0 deletions
15
data/src/main/java/com/example/data/mapper/mypage/MypageMyRecipeMapper.kt
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 com.example.data.mapper.mypage | ||
|
||
import com.example.data.model.mypage.MyRecipeItemDto | ||
import com.example.domain.mapper.Mapper | ||
import com.example.domain.model.mypage.MypageMyRecipeItem | ||
|
||
class MypageMyRecipeMapper:Mapper<List<MyRecipeItemDto>, List<MypageMyRecipeItem>> { | ||
override fun mapFromEntity(type: List<MyRecipeItemDto>): List<MypageMyRecipeItem> { | ||
return type.map { MypageMyRecipeItem( | ||
foodId = it.foodId, | ||
name = it.name, | ||
veganType = it.veganType | ||
) } | ||
} | ||
} |
15 changes: 15 additions & 0 deletions
15
data/src/main/java/com/example/data/model/mypage/MyRecipeResponse.kt
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 com.example.data.model.mypage | ||
|
||
import com.squareup.moshi.Json | ||
|
||
data class MyRecipeResponse ( | ||
@Json(name = "check") | ||
val check: Boolean, | ||
@Json(name = "information") | ||
val information: List<MyRecipeItemDto> | ||
) | ||
data class MyRecipeItemDto( | ||
@Json(name = "foodId") val foodId:Int, | ||
@Json(name = "name") val name:String, | ||
@Json(name = "veganType") val veganType:String | ||
) |
2 changes: 2 additions & 0 deletions
2
.../src/main/java/com/example/data/repository/remote/mypage/MypageMyScrapRemoteDataSource.kt
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,8 +1,10 @@ | ||
package com.example.data.repository.remote.mypage | ||
|
||
import com.example.data.model.mypage.MyMagazineResponse | ||
import com.example.data.model.mypage.MyRecipeResponse | ||
import com.skydoves.sandwich.ApiResponse | ||
|
||
interface MypageMyScrapRemoteDataSource { | ||
suspend fun getMyMagazineList(page: Int): ApiResponse<MyMagazineResponse> | ||
suspend fun getMyRecipeList(page: Int): ApiResponse<MyRecipeResponse> | ||
} |
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
2 changes: 2 additions & 0 deletions
2
domain/src/main/java/com/example/domain/repository/mypage/MypageMyScrapRepository.kt
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,9 +1,11 @@ | ||
package com.example.domain.repository.mypage | ||
|
||
import com.example.domain.model.mypage.MypageMyMagazineItem | ||
import com.example.domain.model.mypage.MypageMyRecipeItem | ||
import com.example.domain.model.tips.TipsMagazineItem | ||
import kotlinx.coroutines.flow.Flow | ||
|
||
interface MypageMyScrapRepository { | ||
suspend fun getMyMagazineList(page: Int): Flow<Result<List<MypageMyMagazineItem>>> | ||
suspend fun getMyRecipeList(page: Int): Flow<Result<List<MypageMyRecipeItem>>> | ||
} |
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
Oops, something went wrong.