修改测试问题

This commit is contained in:
18401019693 2024-03-28 09:50:29 +08:00
parent 1e466ac13d
commit f24744afe8
2 changed files with 20 additions and 1 deletions

View File

@ -50,6 +50,17 @@ public class GuardUserModel extends BaseModel {
private String guardName;
@SerializedName("guard_img")
private String guardImg;
@SerializedName("guard_level_card")
private String guardLevelCard;
public String getGuardLevelCard() {
return guardLevelCard;
}
public GuardUserModel setGuardLevelCard(String guardLevelCard) {
this.guardLevelCard = guardLevelCard;
return this;
}
public int getId() {
return id;

View File

@ -1,5 +1,6 @@
package com.yunbao.live.views;
import android.text.TextUtils;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;
@ -52,7 +53,14 @@ public class NewGuardViewHolder extends RecyclerView.ViewHolder {
user_nicename.setText(guardUserModel.getUserNicename());
userSex.setImageResource(CommonIconUtil.getSexIcon(guardUserModel.getSex()));
guardLevel.setText(String.valueOf(guardUserModel.getGuardLevel()));
ImgLoader.display(itemView.getContext(), guardUserModel.getGuardImg(), tagKing);
contribution.setText(guardUserModel.getContribute());
if (TextUtils.equals(guardUserModel.getGuardLevelCard(),"0")){
ImgLoader.display(itemView.getContext(), guardUserModel.getGuardImg(), tagKing);
}else {
ImgLoader.display(itemView.getContext(), guardUserModel.getGuardImg(), tagKing);
}
}
}