package com.wd.workoffice.ui.adapter;


import android.text.TextUtils;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.wd.workoffice.R;
import com.wd.workoffice.bean.FlowBean;
import com.wd.workoffice.bean.ProPriceBean;

import java.util.List;

/**
 * Created by flexible on 2018/8/13.
 */

public class WorkFlowAdapter extends BaseQuickAdapter<FlowBean.RecordsBean, BaseViewHolder> {

    public WorkFlowAdapter(int layoutResId, List data) {
        super(layoutResId, data);
    }


    @Override
    protected void convert(BaseViewHolder helper, FlowBean.RecordsBean item) {
//        helper.setText(R.id.tv_price,(TextUtils.equals("支出", item.getTypeName()) ? "-" : "+") +  String.valueOf(item.getMoney()));
        helper.setText(R.id.tv_price,String.valueOf(item.getMoney()));
        helper.setText(R.id.tv_time, item.getCreatedTime());
        helper.setText(R.id.tv_desc, item.getDisplayTypeName());
        helper.setText(R.id.tv_dep, item.getDeptName());
    }
}

