package com.android.chmo.ui.activity.model;

import android.widget.ImageView;
import android.widget.TextView;

import com.android.chmo.R;
import com.android.chmo.base.BaseActivity;
import com.android.chmo.http.HttpApi;
import com.android.chmo.model.BrokerInfo;
import com.android.chmo.ui.view.TopBar;
import com.android.chmo.utils.XUtilsImage;

import butterknife.BindView;


public class BrokerInfoActivity extends BaseActivity {
    @BindView(R.id.topBar)
    TopBar topBar;
    @BindView(R.id.head)
     ImageView headView;
    @BindView(R.id.work_desc)
    TextView workDescView;
    @BindView(R.id.model_count)
    TextView modelCountView;

    private BrokerInfo broker;


    @Override
    protected int getContentResId() {
        return R.layout.activity_broker_info;
    }

    @Override
    public void initView() {
        broker = (BrokerInfo)getIntent().getSerializableExtra("broker");

        XUtilsImage.display(headView, HttpApi.getImgUrl(broker.logo),R.mipmap.def_img3);


        topBar.setTitle(broker.name);
        workDescView.setText(broker.intro);
        modelCountView.setText("模特数量：" + broker.modelcount + "人");
    }
}
