package com.abbidot.tracker.bean

import android.os.Parcelable
import com.abbidot.tracker.constant.MultipleEntity
import com.chad.library.adapter.base.entity.MultiItemEntity
import kotlinx.parcelize.IgnoredOnParcel
import kotlinx.parcelize.Parcelize

/**
 *Created  by .yzq on 2024/9/4/004.
 * @link
 * @description:
 */
@Parcelize
data class SubscriptionsOrderBean(
    var annualCarePrice: Double,
    var annualCareType: Int,
    var couponCode: String,
    var couponPrice: Double,
    var createTime: String,
    var customerId: String,
    var deviceId: String,
    var deviceOutId: String,
    var enabled: Int,
    var id: String,
    var mealDesc: String,
    var mealId: String,
    var mealName: String,
    var mealPeriod: Int,
    var mealPrice: Double,
    var mealDiscountPrice: Double,
    var orderNum: String,
    var orderStatus: Int,//0支付取消 1支付成功 2支付失败 3待支付 4申请审核中 5退款中 6退款成功 7退款失败 8审核失败
    var payTime: Long,
    var payType: Int,
    var planCategory: String,
    var planId: String,
    var priceId: String,
    var reactivatePrice: Double,
    var reactivation: Int,
    var simId: String,
    var subscriptionId: String,
    var subscriptionStatus: Int,
    var surplusDays: Long,
    var autoRenewPrice: Double,
    var tax: Double,
    var totalAmountWithTax: Double,
    var transactionId: String,
    var updateTime: String,
    var useCoupon: Int,
    var userId: String,
    var mealUnit: String,
    var username: String,
    var iccid: String,
    var endTime: Long,
    var refundTime: Long,
    var planTimeMonthsCount: Int,
    var isRefundable: Int,//是否显示退款按钮 1:是 0:否
    var isAutoRenewal: Int,//是否是自动续订 1:是 0:否
    @MultipleEntity var menuType: Int,
    var isUpdateOrder: Int = 0//是否是升级订单 1:是 0:否
) : Parcelable, MultiItemEntity {
    constructor(@MultipleEntity menuType: Int) : this(
        0.0,
        0,
        "",
        0.0,
        "",
        "",
        "",
        "",
        0,
        "",
        "",
        "",
        "",
        0,
        0.0,
        0.0,
        "",
        0,
        0L,
        0,
        "",
        "",
        "",
        0.0,
        0,
        "",
        "",
        0,
        0L,
        0.0,
        0.0,
        0.0,
        "",
        "",
        0,
        "",
        "",
        "",
        "",
        0L,
        0L,
        0,
        0,
        0,
        menuType,
        0
    )

    constructor() : this(
        0.0,
        0,
        "",
        0.0,
        "",
        "",
        "",
        "",
        0,
        "",
        "",
        "",
        "",
        0,
        0.0,
        0.0,
        "",
        0,
        0L,
        0,
        "",
        "",
        "",
        0.0,
        0,
        "",
        "",
        0,
        0L,
        0.0,
        0.0,
        0.0,
        "",
        "",
        0,
        "",
        "",
        "",
        "",
        0L,
        0L,
        0,
        0,
        0,
        MultipleEntity.TEXT,
        0
    )

    @IgnoredOnParcel
    @MultipleEntity
    override val itemType = menuType
}
