feat(pushnotification): 홈 알림 리스트 화면과 딥링크 라우팅을 추가한다
This commit is contained in:
@@ -2,6 +2,8 @@ package kr.co.vividnext.sodalive.user
|
||||
|
||||
import io.reactivex.rxjava3.core.Single
|
||||
import kr.co.vividnext.sodalive.common.ApiResponse
|
||||
import kr.co.vividnext.sodalive.home.pushnotification.GetPushNotificationCategoryResponse
|
||||
import kr.co.vividnext.sodalive.home.pushnotification.GetPushNotificationListResponse
|
||||
import kr.co.vividnext.sodalive.explorer.profile.MemberBlockRequest
|
||||
import kr.co.vividnext.sodalive.live.room.detail.GetRoomDetailUser
|
||||
import kr.co.vividnext.sodalive.main.MarketingInfoUpdateRequest
|
||||
@@ -47,6 +49,19 @@ interface UserApi {
|
||||
@Header("Authorization") authHeader: String
|
||||
): Single<ApiResponse<GetMemberInfoResponse>>
|
||||
|
||||
@GET("/push/notification/categories")
|
||||
fun getPushNotificationCategories(
|
||||
@Header("Authorization") authHeader: String
|
||||
): Single<ApiResponse<GetPushNotificationCategoryResponse>>
|
||||
|
||||
@GET("/push/notification/list")
|
||||
fun getPushNotificationList(
|
||||
@Query("page") page: Int,
|
||||
@Query("size") size: Int,
|
||||
@Query("category") category: String?,
|
||||
@Header("Authorization") authHeader: String
|
||||
): Single<ApiResponse<GetPushNotificationListResponse>>
|
||||
|
||||
@POST("/member/notification")
|
||||
fun updateNotificationSettings(
|
||||
@Body request: UpdateNotificationSettingRequest,
|
||||
@@ -180,5 +195,4 @@ interface UserApi {
|
||||
fun loginLine(
|
||||
@Body request: SocialLoginRequest
|
||||
): Single<ApiResponse<LoginResponse>>
|
||||
|
||||
}
|
||||
|
||||
@@ -2,6 +2,8 @@ package kr.co.vividnext.sodalive.user
|
||||
|
||||
import io.reactivex.rxjava3.core.Single
|
||||
import kr.co.vividnext.sodalive.common.ApiResponse
|
||||
import kr.co.vividnext.sodalive.home.pushnotification.GetPushNotificationCategoryResponse
|
||||
import kr.co.vividnext.sodalive.home.pushnotification.GetPushNotificationListResponse
|
||||
import kr.co.vividnext.sodalive.explorer.profile.MemberBlockRequest
|
||||
import kr.co.vividnext.sodalive.live.room.detail.GetRoomDetailUser
|
||||
import kr.co.vividnext.sodalive.main.MarketingInfoUpdateRequest
|
||||
@@ -36,6 +38,24 @@ class UserRepository(private val userApi: UserApi) {
|
||||
|
||||
fun getMemberInfo(token: String) = userApi.getMemberInfo(authHeader = token)
|
||||
|
||||
fun getPushNotificationCategories(token: String): Single<ApiResponse<GetPushNotificationCategoryResponse>> {
|
||||
return userApi.getPushNotificationCategories(authHeader = token)
|
||||
}
|
||||
|
||||
fun getPushNotificationList(
|
||||
page: Int,
|
||||
size: Int,
|
||||
category: String?,
|
||||
token: String
|
||||
): Single<ApiResponse<GetPushNotificationListResponse>> {
|
||||
return userApi.getPushNotificationList(
|
||||
page = page,
|
||||
size = size,
|
||||
category = category,
|
||||
authHeader = token
|
||||
)
|
||||
}
|
||||
|
||||
fun getMyPage(token: String): Single<ApiResponse<MyPageResponse>> {
|
||||
return userApi.getMyPage(authHeader = token)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user