package com.sambath.kunkhmer.remote
import com.google.gson.annotations.SerializedName
import com.squareup.moshi.Json
import com.squareup.moshi.JsonClass

@JsonClass(generateAdapter = true)
data class ResultResponse(
    @Json(name = "code")
    val resultCode: String,
    @Json(name = "message")
    val message: ResultMessage,
    @Json(name = "data")
    val data: ResultData?
)

@JsonClass(generateAdapter = true)
data class CfResultResponse(
    @Json(name = "code")
    val resultCode: String,
    @Json(name = "message")
    val message: ResultMessage,
    @Json(name = "data")
    val data: CfResultData?
)

@JsonClass(generateAdapter = true)
data class CfResultData(
    @Json(name = "chanel")
    val channel: Channel?,
    @Json(name = "result")
    val resultList: List<ResultCf>?
)

@JsonClass(generateAdapter = true)
data class ResultCf(
    @Json(name ="_id")
    val id: String? = null,
    @Json(name ="user_id")
    val userId: String? = null,
    @Json(name ="chanel_id")
    val chanelId: String? = null,
    @Json(name ="fight_no")
    val fightNo: String? = null,
    @Json(name ="type_betting")
    val beetingType: String? = null,
    @Json(name ="date")
    val tWalaTotalAmount: String? = null,
    @Json(name ="no")
    val no: String? = null,
    @Json(name ="color")
    val color: String? = null,
    @Json(name ="cid")
    val colunmId: Int? = null,
    @Json(name ="rid")
    val rowId: Int? = null,
    @Json(name ="group")
    val group: String? = null,
)

@JsonClass(generateAdapter = true)
data class ResultMessage(
    @Json(name = "code")
    val code: String,

    @Json(name = "descriptions")
    val description: String)

@JsonClass(generateAdapter = true)
data class ResultData(
    @Json(name = "object")
    val resultList: List<ResultLotto>?
)

@JsonClass(generateAdapter = true)
data class ResultLotto(

    @Json(name = "_id")
    var id: String,

    @Json(name = "no")
    var no: String,

    @Json(name = "set_result_id")
    var smallBigSetId: String,

    @Json(name = "type_of_betting")
    val resultSmallOrBig: String,

    @Json(name = "category")
    var categorySmallOrBig: String,

    @Json(name = "set_result_id_range")
    var rangeSetId: String,

    @Json(name = "type_of_betting_range")
    val resultRange: String,

    @Json(name = "category_range")
    var categoryRange: String
)

data class CfResult(
    @SerializedName("_id")
    var id: String? = null,
    @SerializedName("user_id")
    var userId: String? = null,
    @SerializedName("chanel_id")
    var chanelId: String? = null,
    @SerializedName("fight_no")
    var fightNo: String? = null,
    @SerializedName("type_betting")
    var beetingType: String? = null,
    @SerializedName("date")
    var tWalaTotalAmount: String? = null,
    @SerializedName("no")
    var no: String? = null,
    @SerializedName("color")
    var color: String? = null,
    @SerializedName("cid")
    var colunmId: Int? = null,
    @SerializedName("rid")
    var rowId: Int? = null,
    @SerializedName("group")
    var group: String? = null,
){}

