package com.zj365.health.adapter

import com.chad.library.adapter.base.viewholder.BaseViewHolder
import com.xty.base.adapter.BaseAdapter
import com.zj365.health.R
import com.xty.network.model.XueyaRecordListBean

class XyaRecordAdapter:BaseAdapter<XueyaRecordListBean>(R.layout.item_xya_record) {
    override fun convert(holder: BaseViewHolder, item: XueyaRecordListBean) {
        holder.setText(R.id.tvGyazhi,item.gbp.toString()+"mmHg")
        holder.setText(R.id.tvDyazhi,item.dbp.toString()+"mmHg")
        holder.setText(R.id.tvStudyRecord,item.createTime)
        when(item.type){
            0 ->  holder.setText(R.id.tvStatus,"学习失败")
            1 ->  holder.setText(R.id.tvStatus,"学习成功")
            2 ->  holder.setText(R.id.tvStatus,"学习中")
        }

    }
}