diff --git a/live/src/main/java/com/yunbao/live/activity/LiveActivity.java b/live/src/main/java/com/yunbao/live/activity/LiveActivity.java index 985bd667a..450101a5d 100644 --- a/live/src/main/java/com/yunbao/live/activity/LiveActivity.java +++ b/live/src/main/java/com/yunbao/live/activity/LiveActivity.java @@ -1200,7 +1200,13 @@ public abstract class LiveActivity extends AbsActivity implements SocketMessageL * 守护列表弹窗 */ public void openNewGuardListWindow(boolean showBuyView) { - LiveHttpUtil.getGuardList(mLiveUid, 1, new HttpCallback() { + openNewGuardListWindow(showBuyView,null); + } + public void openNewGuardListWindow(boolean showBuyView,String uid) { + if(uid==null){ + uid=mLiveUid; + } + LiveHttpUtil.getGuardList(uid, 1, new HttpCallback() { @Override public void onSuccess(int code, String msg, String[] info) { List list = JSON.parseArray(Arrays.toString(info), GuardUserBean.class); @@ -1226,16 +1232,21 @@ public abstract class LiveActivity extends AbsActivity implements SocketMessageL * 打開粉絲團 */ public void openFansWindow() { - + openFansWindow(null); + } + public void openFansWindow(String uid) { + if(uid==null){ + uid=mLiveUid; + } LiveFansFragment fragment = new LiveFansFragment(mContext); Bundle bundle = new Bundle(); //粉絲團粉絲團 //不是粉絲 if (LiveAudienceActivity.is_fans != null && LiveAudienceActivity.is_fans.equals("2")) { - bundle.putString(Constants.URL, CommonAppConfig.HOST + "/h5/live/joinFansClub.html" + "?uid=" + CommonAppConfig.getInstance().getUid() + "&token=" + CommonAppConfig.getInstance().getToken() + "&anchorUid=" + mLiveUid); + bundle.putString(Constants.URL, CommonAppConfig.HOST + "/h5/live/joinFansClub.html" + "?uid=" + CommonAppConfig.getInstance().getUid() + "&token=" + CommonAppConfig.getInstance().getToken() + "&anchorUid=" + uid); } else { - bundle.putString(Constants.URL, CommonAppConfig.HOST + "/h5/live/fansClub.html" + "?uid=" + CommonAppConfig.getInstance().getUid() + "&token=" + CommonAppConfig.getInstance().getToken() + "&anchorUid=" + mLiveUid); + bundle.putString(Constants.URL, CommonAppConfig.HOST + "/h5/live/fansClub.html" + "?uid=" + CommonAppConfig.getInstance().getUid() + "&token=" + CommonAppConfig.getInstance().getToken() + "&anchorUid=" + uid); } fragment.setArguments(bundle); fragment.show(getSupportFragmentManager(), "LiveGuardDialogFragment"); diff --git a/live/src/main/java/com/yunbao/live/dialog/LiveUserDialogFragment.java b/live/src/main/java/com/yunbao/live/dialog/LiveUserDialogFragment.java index 1d47e914a..2a445f86f 100644 --- a/live/src/main/java/com/yunbao/live/dialog/LiveUserDialogFragment.java +++ b/live/src/main/java/com/yunbao/live/dialog/LiveUserDialogFragment.java @@ -648,13 +648,13 @@ public class LiveUserDialogFragment extends AbsDialogFragment implements View.On } else if (i == R.id.avatar) { forwardHomePage(); } else if (i == R.id.btn_guard) { - ((LiveActivity) mContext).openNewGuardListWindow(mContext instanceof LiveRyAnchorActivity); + ((LiveActivity) mContext).openNewGuardListWindow(mContext instanceof LiveRyAnchorActivity,mToUid); } else if (i == R.id.btn_live) { gotoLive(mToUid); } else if (i == R.id.noble_icon_layout) { if (isAnchor) { dismiss(); - ((LiveActivity) mContext).openFansWindow(); + ((LiveActivity) mContext).openFansWindow(mToUid); } } else if (i == R.id.btn_setting) { setting();