콘텐츠 추가

This commit is contained in:
Yu Sung
2023-08-13 20:59:49 +09:00
parent a8338e6fea
commit cf0607334a
63 changed files with 3935 additions and 10 deletions

View File

@@ -22,11 +22,11 @@ final class ContentRepository {
}
func likeContent(audioContentId: Int) -> AnyPublisher<Response, MoyaError> {
return api.requestPublisher(.likeContent(request: PutAudioContentLikeRequest(audioContentId: audioContentId)))
return api.requestPublisher(.likeContent(request: PutAudioContentLikeRequest(contentId: audioContentId)))
}
func registerComment(audioContentId: Int, comment: String, parentId: Int? = nil) -> AnyPublisher<Response, MoyaError> {
return api.requestPublisher(.registerComment(request: RegisterAudioContentCommentRequest(comment: comment, audioContentId: audioContentId, parentId: parentId)))
return api.requestPublisher(.registerComment(request: RegisterAudioContentCommentRequest(comment: comment, contentId: audioContentId, parentId: parentId)))
}
func orderAudioContent(audioContentId: Int, orderType: OrderType) -> AnyPublisher<Response, MoyaError> {
@@ -73,7 +73,7 @@ final class ContentRepository {
return api.requestPublisher(.getNewContentOfTheme(theme: theme))
}
func donation(contentId: Int, coin: Int, comment: String) -> AnyPublisher<Response, MoyaError> {
return api.requestPublisher(.donation(request: AudioContentDonationRequest(audioContentId: contentId, donationCoin: coin, comment: comment)))
func donation(contentId: Int, can: Int, comment: String) -> AnyPublisher<Response, MoyaError> {
return api.requestPublisher(.donation(request: AudioContentDonationRequest(audioContentId: contentId, donationCan: can, comment: comment)))
}
}