package com.swago.baseswago.dialog

import com.chad.library.adapter.base.BaseQuickAdapter
import com.chad.library.adapter.base.BaseViewHolder
import com.swago.baseswago.R
import com.swago.baseswago.model.pay.PayModel

/**
 *@date 2021/11/25 20:13
 *description:
 */
class RechargeAdapter : BaseQuickAdapter<PayModel,BaseViewHolder>(
    R.layout.item_recharge,
    arrayListOf()) {
    override fun convert(helper: BaseViewHolder, item: PayModel) {
            helper.apply {
                setText(R.id.tvCoin,item.product_coins)
                setText(R.id.tvMoney,item.product_price)
                if (item.isSelected){
                    setBackgroundRes(R.id.fl,R.drawable.shape_ff9300_5)
                }else{
                    setBackgroundRes(R.id.fl,R.drawable.shape_f7f8fa_5)
                }
            }
    }
}