diff --git a/config.gradle b/config.gradle index f3ad9d81e..4aab71a23 100644 --- a/config.gradle +++ b/config.gradle @@ -9,9 +9,9 @@ ext { ] manifestPlaceholders = [ //正式、 -// serverHost : "https://napi.yaoulive.com", + serverHost : "https://napi.yaoulive.com", // 测试 - serverHost : "https://ceshi.yaoulive.com", +// serverHost : "https://ceshi.yaoulive.com", //腾讯地图 txMapAppKey : "EOZBZ-ASLCU-4XPV3-BDCHZ-4E3Q7-H4BWB", diff --git a/main/src/main/java/com/yunbao/main/views/AbsMainListChildViewHolder.java b/main/src/main/java/com/yunbao/main/views/AbsMainListChildViewHolder.java index 41b565440..a32de8e80 100644 --- a/main/src/main/java/com/yunbao/main/views/AbsMainListChildViewHolder.java +++ b/main/src/main/java/com/yunbao/main/views/AbsMainListChildViewHolder.java @@ -91,11 +91,14 @@ public abstract class AbsMainListChildViewHolder extends AbsMainViewHolder imple public void onData(List list, List outRankHide) { for (int i = 0; i < list.size(); i++) { if (outRankHide != null) { - for (String hideId : outRankHide) { - if (i < 3) { - hv.setData(list.get(i).setHide(TextUtils.equals(list.get(i).getUid(), hideId)), i); - } + + + if (i < 3 && outRankHide.contains(list.get(i).getUid())) { + hv.setData(list.get(i).setHide(true), i); + } else if (i < 3) { + hv.setData(list.get(i).setHide(false), i); } + } else { if (i < 3) { hv.setData(list.get(i), i); @@ -337,10 +340,10 @@ public abstract class AbsMainListChildViewHolder extends AbsMainViewHolder imple if (bean.getAttention() != 1) { getItem(position, mBtnFollow1, mBtnFollow2, mBtnFollow3).doChecked(true); getItem(position, mBtnFollow1, mBtnFollow2, mBtnFollow3).setText("+" + mContext.getString(R.string.follow)); - if (isRankOne==0) { + if (isRankOne == 0) { getItem(position, mBtnFollow1, mBtnFollow2, mBtnFollow3).setBackgroundResource(R.drawable.background_ffff79c2); getItem(position, mBtnFollow1, mBtnFollow2, mBtnFollow3).setTextColor(Color.parseColor("#FFFFFF")); - } else if (isRankOne==1){ + } else if (isRankOne == 1) { getItem(position, mBtnFollow1, mBtnFollow2, mBtnFollow3).setBackgroundResource(R.drawable.background_7bbaff); getItem(position, mBtnFollow1, mBtnFollow2, mBtnFollow3).setTextColor(Color.parseColor("#FFFFFF")); } else if (isRankOne == 2) { @@ -357,7 +360,8 @@ public abstract class AbsMainListChildViewHolder extends AbsMainViewHolder imple getItem(position, mName1, mName2, mName3).setText(R.string.mystery_man); ImgLoader.display(mContext, R.mipmap.hide, getItem(position, mAvatar1, mAvatar2, mAvatar3)); getItem(position, mSex1, mSex2, mSex3).setVisibility(View.GONE); - getItem(position, mVotes1, mVotes2, mVotes3).setVisibility(View.GONE); + setVisibility(View.GONE, position, svga1, svga2, svga3); + setVisibility(View.GONE, position, mBtnFollow1, mBtnFollow2, mBtnFollow3); } else { ImgLoader.display(mContext, bean.getAvatarThumb(), getItem(position, mAvatar1, mAvatar2, mAvatar3)); getItem(position, mName1, mName2, mName3).setText(bean.getUserNiceName()); diff --git a/main/src/main/java/com/yunbao/main/views/MainListContributeViewHolder.java b/main/src/main/java/com/yunbao/main/views/MainListContributeViewHolder.java index af9da6db1..94bee61b2 100644 --- a/main/src/main/java/com/yunbao/main/views/MainListContributeViewHolder.java +++ b/main/src/main/java/com/yunbao/main/views/MainListContributeViewHolder.java @@ -27,7 +27,7 @@ public class MainListContributeViewHolder extends AbsMainListChildViewHolder { public MainListContributeViewHolder(Context context, ViewGroup parentView) { super(context, parentView); - isRankOne = 2; + isRankOne = 1; } @Override diff --git a/main/src/main/java/com/yunbao/main/views/MainListProfitViewHolder.java b/main/src/main/java/com/yunbao/main/views/MainListProfitViewHolder.java index 5ce848333..06800cd08 100644 --- a/main/src/main/java/com/yunbao/main/views/MainListProfitViewHolder.java +++ b/main/src/main/java/com/yunbao/main/views/MainListProfitViewHolder.java @@ -24,7 +24,7 @@ public class MainListProfitViewHolder extends AbsMainListChildViewHolder { public MainListProfitViewHolder(Context context, ViewGroup parentView) { super(context, parentView); - isRankOne = 1; + isRankOne = 0; } @Override