|
|
@@ -63,6 +63,10 @@ public class MineApplyListAdapter extends BaseListAdapter<EnrollmentBean, MineAp
|
|
|
Drawable d_success;
|
|
|
@BindView(R.id.tv_stage)
|
|
|
TextView tvStage;
|
|
|
+ @BindView(R.id.tv_cancel)
|
|
|
+ TextView tvCancel;
|
|
|
+ @BindView(R.id.tv_down)
|
|
|
+ TextView tvDown;
|
|
|
|
|
|
public MineApplyViewHolder(Context mContext) {
|
|
|
super(mContext);
|
|
|
@@ -84,20 +88,32 @@ public class MineApplyListAdapter extends BaseListAdapter<EnrollmentBean, MineAp
|
|
|
tvAddress.setText(obj.getHwRequirement() != null && TextUtils.isEmpty(obj.getHwRequirement().getProvinceCityCountry()) ? "" : obj.getHwRequirement().getProvinceCityCountry());
|
|
|
|
|
|
if (obj.getHwRequirement() != null && obj.getHwRequirement().getIsOn() == 0) {
|
|
|
- tvState.setTextColor(mContext.getResources().getColorStateList(R.color.text_gray_88));
|
|
|
- tvState.setBackgroundResource(R.color.bg_gray_f5);
|
|
|
- tvState.setCompoundDrawablesWithIntrinsicBounds(d_over, null, null, null);
|
|
|
- tvState.setText(R.string.demand_order_over);
|
|
|
- } else if (TextUtils.isEmpty(obj.getOrderNumber())) {
|
|
|
- tvState.setTextColor(mContext.getResources().getColorStateList(R.color.text_gold));
|
|
|
- tvState.setBackgroundResource(R.color.text_yellow);
|
|
|
- tvState.setCompoundDrawablesWithIntrinsicBounds(d_going, null, null, null);
|
|
|
- tvState.setText(R.string.demand_going);
|
|
|
+ tvDown.setVisibility(View.VISIBLE);
|
|
|
+ tvPrice.setTextColor(mContext.getResources().getColor(R.color.text_black));
|
|
|
+ tvStage.setTextColor(mContext.getResources().getColor(R.color.text_black));
|
|
|
+ }else{
|
|
|
+ tvDown.setVisibility(View.GONE);
|
|
|
+ tvPrice.setTextColor(mContext.getResources().getColor(R.color.text_blue_32));
|
|
|
+ tvStage.setTextColor(mContext.getResources().getColor(R.color.text_blue_32));
|
|
|
+ }
|
|
|
+
|
|
|
+ if (obj.isDisplayCancel()) {
|
|
|
+ tvCancel.setVisibility(View.VISIBLE);
|
|
|
+ tvState.setVisibility(View.GONE);
|
|
|
} else {
|
|
|
- tvState.setTextColor(mContext.getResources().getColorStateList(R.color.text_blue_66));
|
|
|
- tvState.setBackgroundResource(R.color.text_blue_ee);
|
|
|
- tvState.setCompoundDrawablesWithIntrinsicBounds(d_success, null, null, null);
|
|
|
- tvState.setText(R.string.demand_order_finish);
|
|
|
+ tvCancel.setVisibility(View.GONE);
|
|
|
+ tvState.setVisibility(View.VISIBLE);
|
|
|
+ if (TextUtils.isEmpty(obj.getOrderNumber())) {
|
|
|
+ tvState.setTextColor(mContext.getResources().getColorStateList(R.color.text_gold));
|
|
|
+ tvState.setBackgroundResource(R.color.text_yellow);
|
|
|
+ tvState.setCompoundDrawablesWithIntrinsicBounds(d_going, null, null, null);
|
|
|
+ tvState.setText(R.string.demand_going);
|
|
|
+ } else {
|
|
|
+ tvState.setTextColor(mContext.getResources().getColorStateList(R.color.text_blue_66));
|
|
|
+ tvState.setBackgroundResource(R.color.text_blue_ee);
|
|
|
+ tvState.setCompoundDrawablesWithIntrinsicBounds(d_success, null, null, null);
|
|
|
+ tvState.setText(R.string.demand_order_finish);
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
}
|