feat(content): 랭킹 유형 탭을 추가한다
This commit is contained in:
@@ -3,7 +3,7 @@ import Foundation
|
||||
import Moya
|
||||
|
||||
enum MainContentRankingApi {
|
||||
case getAudioRankings
|
||||
case getAudioRankings(type: AudioRankingType)
|
||||
}
|
||||
|
||||
extension MainContentRankingApi: TargetType {
|
||||
@@ -27,8 +27,11 @@ extension MainContentRankingApi: TargetType {
|
||||
|
||||
var task: Moya.Task {
|
||||
switch self {
|
||||
case .getAudioRankings:
|
||||
return .requestPlain
|
||||
case .getAudioRankings(let type):
|
||||
return .requestParameters(
|
||||
parameters: ["type": type.rawValue],
|
||||
encoding: URLEncoding.queryString
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user