package com.example.administrator.zhapp.adapter;

import android.content.Context;
import android.widget.TextView;
import com.example.administrator.zhapp.BaseListViewAdapter.CommonAdapter;
import com.example.administrator.zhapp.BaseListViewAdapter.ViewHolder;
import com.example.administrator.zhapp.R;
import com.example.administrator.zhapp.entity.HmLbBean;
import java.util.List;


/**
 * Created by ruihong on 2019/8/19.
 */

public class HmLbAdapter extends CommonAdapter<HmLbBean.DataBean> {

    private List<HmLbBean.DataBean> datas;

    public HmLbAdapter(Context context, List<HmLbBean.DataBean> datas) {
        super(context, R.layout.item_hmlb, datas);
        this.datas = datas;
    }

    @Override
    protected void convert(ViewHolder viewHolder, HmLbBean.DataBean item, int position) {

        TextView tvJhmc = viewHolder.getView(R.id.tv_jhmc);
        TextView tvKssj = viewHolder.getView(R.id.tv_kssj);
        TextView tvJssj = viewHolder.getView(R.id.tv_jssj);
        TextView tvSqr = viewHolder.getView(R.id.tv_sqr);
        TextView tvSqsj = viewHolder.getView(R.id.tv_sqsj);
        TextView tvSpr = viewHolder.getView(R.id.tv_spr);
        TextView tvSpsj = viewHolder.getView(R.id.tv_spsj);
        TextView tvHmbz = viewHolder.getView(R.id.tv_hmbz);
        TextView tvZt = viewHolder.getView(R.id.tv_zt);

        tvJhmc.setText("计划名称:" + item.getJHMC());
        tvKssj.setText("开始时间:" + item.getST());
        tvJssj.setText("结束时间:" + item.getET());
        tvSqr.setText("申请人:" + item.getSQR());
        tvSqsj.setText("申请时间:" + item.getSQSJ());
        tvSpr.setText("审批人:" + item.getSPR());
        tvSpsj.setText("审批时间:" + item.getSPSJ());
        tvHmbz.setText("豁免备注:" + item.getHMBZ());
        tvZt.setText(item.getSPZT());

    }
}
