-
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.
Merge pull request #46 from gaeun5744/develop
[FEAT] 회고 조회 뷰 api 구현
- Loading branch information
Showing
34 changed files
with
542 additions
and
274 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
23 changes: 23 additions & 0 deletions
23
app/src/main/java/com/puzzling/puzzlingaos/data/repository/MyPageRepositoryImpl.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,23 @@ | ||
package com.puzzling.puzzlingaos.data.repository | ||
|
||
import com.puzzling.puzzlingaos.data.model.response.ResponseDetailRetroDto | ||
import com.puzzling.puzzlingaos.data.model.response.ResponseMyRetroListDto | ||
import com.puzzling.puzzlingaos.data.source.remote.MyPageDataSource | ||
import com.puzzling.puzzlingaos.domain.repository.MyPageRepository | ||
import javax.inject.Inject | ||
|
||
class MyPageRepositoryImpl @Inject constructor(private val myPageDataSource: MyPageDataSource) : | ||
MyPageRepository { | ||
override suspend fun getMyProjectReview(memberId: Int, projectId: Int): ResponseMyRetroListDto { | ||
return myPageDataSource.getMyProjectReview(memberId, projectId) | ||
} | ||
|
||
override suspend fun getMyDetailReview( | ||
memberId: Int, | ||
projectId: Int, | ||
startDate: String, | ||
endDate: String, | ||
): ResponseDetailRetroDto { | ||
return myPageDataSource.getMyDetailReview(memberId, projectId, startDate, endDate) | ||
} | ||
} |
23 changes: 23 additions & 0 deletions
23
app/src/main/java/com/puzzling/puzzlingaos/data/service/MyPageService.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,23 @@ | ||
package com.puzzling.puzzlingaos.data.service | ||
|
||
import com.puzzling.puzzlingaos.data.model.response.ResponseDetailRetroDto | ||
import com.puzzling.puzzlingaos.data.model.response.ResponseMyRetroListDto | ||
import retrofit2.http.GET | ||
import retrofit2.http.Path | ||
import retrofit2.http.Query | ||
|
||
interface MyPageService { | ||
@GET("api/v1/member/{memberId}/project/{projectId}/reviews") | ||
suspend fun getMyProjectReview( | ||
@Path("memberId") memberId: Int, | ||
@Path("projectId") projectId: Int, | ||
): ResponseMyRetroListDto | ||
|
||
@GET("api/v1/member/{memberId}/project/{projectId}/review?") | ||
suspend fun getMyDetailReview( | ||
@Path("memberId") memberId: Int, | ||
@Path("projectId") projectId: Int, | ||
@Query("startDate") startDate: String, | ||
@Query("endDate") endDate: String, | ||
): ResponseDetailRetroDto | ||
} |
18 changes: 18 additions & 0 deletions
18
app/src/main/java/com/puzzling/puzzlingaos/data/source/remote/MyPageDataSource.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,18 @@ | ||
package com.puzzling.puzzlingaos.data.source.remote | ||
|
||
import com.puzzling.puzzlingaos.data.model.response.ResponseDetailRetroDto | ||
import com.puzzling.puzzlingaos.data.model.response.ResponseMyRetroListDto | ||
|
||
interface MyPageDataSource { | ||
suspend fun getMyProjectReview( | ||
memberId: Int, | ||
projectId: Int, | ||
): ResponseMyRetroListDto | ||
|
||
suspend fun getMyDetailReview( | ||
memberId: Int, | ||
projectId: Int, | ||
startDate: String, | ||
endDate: String, | ||
): ResponseDetailRetroDto | ||
} |
22 changes: 22 additions & 0 deletions
22
app/src/main/java/com/puzzling/puzzlingaos/data/source/remote/impl/MyPageDataSourceImpl.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,22 @@ | ||
package com.puzzling.puzzlingaos.data.source.remote.impl | ||
|
||
import com.puzzling.puzzlingaos.data.model.response.ResponseDetailRetroDto | ||
import com.puzzling.puzzlingaos.data.model.response.ResponseMyRetroListDto | ||
import com.puzzling.puzzlingaos.data.service.MyPageService | ||
import com.puzzling.puzzlingaos.data.source.remote.MyPageDataSource | ||
import javax.inject.Inject | ||
|
||
class MyPageDataSourceImpl @Inject constructor(private val apiService: MyPageService) : | ||
MyPageDataSource { | ||
override suspend fun getMyProjectReview( | ||
memberId: Int, | ||
projectId: Int, | ||
): ResponseMyRetroListDto = apiService.getMyProjectReview(memberId, projectId) | ||
override suspend fun getMyDetailReview( | ||
memberId: Int, | ||
projectId: Int, | ||
startDate: String, | ||
endDate: String, | ||
): ResponseDetailRetroDto = | ||
apiService.getMyDetailReview(memberId, projectId, startDate, endDate) | ||
} |
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
19 changes: 19 additions & 0 deletions
19
app/src/main/java/com/puzzling/puzzlingaos/domain/repository/MyPageRepository.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,19 @@ | ||
package com.puzzling.puzzlingaos.domain.repository | ||
|
||
import com.puzzling.puzzlingaos.data.model.response.ResponseDetailRetroDto | ||
import com.puzzling.puzzlingaos.data.model.response.ResponseMyRetroListDto | ||
|
||
interface MyPageRepository { | ||
|
||
suspend fun getMyProjectReview( | ||
memberId: Int, | ||
projectId: Int, | ||
): ResponseMyRetroListDto | ||
|
||
suspend fun getMyDetailReview( | ||
memberId: Int, | ||
projectId: Int, | ||
startDate: String, | ||
endDate: String, | ||
): ResponseDetailRetroDto | ||
} |
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.