diff --git a/common/src/main/java/com/yunbao/common/http/live/LiveNetManager.java b/common/src/main/java/com/yunbao/common/http/live/LiveNetManager.java index d5573475b..c7c63d736 100644 --- a/common/src/main/java/com/yunbao/common/http/live/LiveNetManager.java +++ b/common/src/main/java/com/yunbao/common/http/live/LiveNetManager.java @@ -35,9 +35,9 @@ import com.yunbao.common.bean.PrankHttpTurntableBean; import com.yunbao.common.bean.RandomPkUserBean; import com.yunbao.common.bean.RankPkInfoBean; import com.yunbao.common.bean.RedPacketDetailsBean; -import com.yunbao.common.bean.RedPacketListBean; import com.yunbao.common.bean.RedPacketGiftModel; import com.yunbao.common.bean.RedPacketInfoModel; +import com.yunbao.common.bean.RedPacketListBean; import com.yunbao.common.bean.SetAttentsModel; import com.yunbao.common.bean.StarChallengeStatusModel; import com.yunbao.common.bean.UserAreaBean; @@ -1554,6 +1554,7 @@ public class LiveNetManager { } }).isDisposed(); } + /** * 获取红包记录列表 */ @@ -1578,10 +1579,11 @@ public class LiveNetManager { } }).isDisposed(); } + /** * 获取红包记录列表 */ - public void getRedPacketUserList(int id,HttpCallback callback) { + public void getRedPacketUserList(int id, HttpCallback callback) { API.get().pdLiveApi(mContext) .getRedPacketDetails(id) .subscribeOn(Schedulers.io()) @@ -1626,6 +1628,7 @@ public class LiveNetManager { callback.onError(objectResponseModel.getData().getMsg()); } } + } }, new Consumer() { @Override @@ -1747,7 +1750,7 @@ public class LiveNetManager { }).isDisposed(); } - public void endRedPacket(String liveUid,String redPacketId, HttpCallback callback) { + public void endRedPacket(String liveUid, String redPacketId, HttpCallback callback) { API.get().pdLiveApi(mContext) .endRedPacket(liveUid, redPacketId) .subscribeOn(Schedulers.io()) diff --git a/common/src/main/res/values-en-rUS/string.xml b/common/src/main/res/values-en-rUS/string.xml index 7a4fb1493..6a4eb77b8 100644 --- a/common/src/main/res/values-en-rUS/string.xml +++ b/common/src/main/res/values-en-rUS/string.xml @@ -1212,4 +1212,7 @@ Limited ride And limited avatar frame Return to account Popularity Red packet Red packets + Save popular red packets + amount + drill diff --git a/common/src/main/res/values-zh-rHK/strings.xml b/common/src/main/res/values-zh-rHK/strings.xml index 4a8ed2ef9..a21fb1c96 100644 --- a/common/src/main/res/values-zh-rHK/strings.xml +++ b/common/src/main/res/values-zh-rHK/strings.xml @@ -1207,4 +1207,13 @@ 退回賬戶 攢人氣紅包 紅包專區 + 攢人氣紅包 + 金額 + + 條件 + + 關注主播 + 紅包%s鑚/個 + 共計消耗%s鑚 + 去充值> diff --git a/common/src/main/res/values-zh-rTW/strings.xml b/common/src/main/res/values-zh-rTW/strings.xml index bd87f6cda..0a64eceaa 100644 --- a/common/src/main/res/values-zh-rTW/strings.xml +++ b/common/src/main/res/values-zh-rTW/strings.xml @@ -1206,4 +1206,13 @@ 退回賬戶 攢人氣紅包 紅包專區 + 攢人氣紅包 + 金額 + + 條件 + + 關注主播 + 紅包%s鑚/個 + 共計消耗%s鑚 + 去充值> diff --git a/common/src/main/res/values-zh/strings.xml b/common/src/main/res/values-zh/strings.xml index 95b56959c..20ac80362 100644 --- a/common/src/main/res/values-zh/strings.xml +++ b/common/src/main/res/values-zh/strings.xml @@ -1207,4 +1207,13 @@ 退回賬戶 攢人氣紅包 紅包專區 + 攢人氣紅包 + 金額 + + 條件 + + 關注主播 + 紅包%s鑚/個 + 共計消耗%s鑚 + 去充值> diff --git a/common/src/main/res/values/strings.xml b/common/src/main/res/values/strings.xml index 2b4052028..118babd9e 100644 --- a/common/src/main/res/values/strings.xml +++ b/common/src/main/res/values/strings.xml @@ -1213,9 +1213,9 @@ Limited ride And limited avatar frame Return to account Popularity Red packet Red packets - 攢人氣紅包 - 金額 - + Save popular red packets + amount + drill 條件 關注主播 diff --git a/gradle.properties b/gradle.properties index a5066c177..e850a38e3 100644 --- a/gradle.properties +++ b/gradle.properties @@ -19,8 +19,8 @@ org.gradle.configureondemand=true android.useAndroidX=true android.enableJetifier=true -#systemProp.http.proxyHost=127.0.0.1 -#systemProp.https.proxyHost=127.0.0.1 -#systemProp.https.proxyPort=7890 -#systemProp.http.proxyPort=7890 +systemProp.http.proxyHost=127.0.0.1 +systemProp.https.proxyHost=127.0.0.1 +systemProp.https.proxyPort=10809 +systemProp.http.proxyPort=10809 #android.enableR8.fullMode=true \ No newline at end of file diff --git a/live/src/main/java/com/yunbao/live/dialog/ResultRendPacketPopup.java b/live/src/main/java/com/yunbao/live/dialog/ResultRendPacketPopup.java index b906133e0..4a2f92528 100644 --- a/live/src/main/java/com/yunbao/live/dialog/ResultRendPacketPopup.java +++ b/live/src/main/java/com/yunbao/live/dialog/ResultRendPacketPopup.java @@ -101,9 +101,14 @@ public class ResultRendPacketPopup extends CenterPopupView { new HttpCallback>() { @Override public void onSuccess(List data) { - new XPopup.Builder(getContext()) - .asCustom(new LuckUserRedPacketPopup(getContext(), data)) - .show(); + if (data.size() > 0) { + new XPopup.Builder(getContext()) + .asCustom(new LuckUserRedPacketPopup(getContext(), data)) + .show(); + } else { + ToastUtil.show(R.string.no_data); + } + } @Override @@ -117,9 +122,14 @@ public class ResultRendPacketPopup extends CenterPopupView { new HttpCallback>() { @Override public void onSuccess(List data) { - new XPopup.Builder(getContext()) - .asCustom(new LuckUserRedPacketPopup(getContext(), data)) - .show(); + if (data.size()>0){ + new XPopup.Builder(getContext()) + .asCustom(new LuckUserRedPacketPopup(getContext(), data)) + .show(); + }else { + ToastUtil.show(R.string.no_data); + } + } @Override diff --git a/live/src/main/java/com/yunbao/live/dialog/SendRendPacketPopup.java b/live/src/main/java/com/yunbao/live/dialog/SendRendPacketPopup.java index 0f26e4d36..60794d98d 100644 --- a/live/src/main/java/com/yunbao/live/dialog/SendRendPacketPopup.java +++ b/live/src/main/java/com/yunbao/live/dialog/SendRendPacketPopup.java @@ -100,7 +100,7 @@ public class SendRendPacketPopup extends CenterPopupView { totalConsumptionOfDrill.setText(String.format(getContext().getString(R.string.total_consumption_of_drill), String.valueOf((totalInt * numberInt)))); redEnvelopeRill.setText(String.format(getContext().getString(R.string.red_envelope_rill), s.toString())); } else { - ToastUtil.show(String.format(getContext().getString(R.string.range_range_is), "200~10000")); + ToastUtil.show(getContext().getString(R.string.amount) + String.format(getContext().getString(R.string.range_range_is), "200~10000")); } } @@ -135,7 +135,7 @@ public class SendRendPacketPopup extends CenterPopupView { if (numberInt >= 1 && numberInt <= 100) { totalConsumptionOfDrill.setText(String.format(getContext().getString(R.string.total_consumption_of_drill), String.valueOf((rillInt * numberInt)))); } else { - ToastUtil.show(String.format(getContext().getString(R.string.range_range_is), "1~100")); + ToastUtil.show(getContext().getString(R.string.drill) + String.format(getContext().getString(R.string.range_range_is), "1~100")); } } @@ -180,12 +180,12 @@ public class SendRendPacketPopup extends CenterPopupView { if (totalInt >= 1 && totalInt <= 100) { totalTrue = true; } else { - ToastUtil.show(String.format(getContext().getString(R.string.range_range_is), "1~100")); + ToastUtil.show(getContext().getString(R.string.drill) + String.format(getContext().getString(R.string.range_range_is), "1~100")); } if (rillInt >= 200 && rillInt <= 10000) { rillTrue = true; } else { - ToastUtil.show(String.format(getContext().getString(R.string.range_range_is), "200~10000")); + ToastUtil.show(getContext().getString(R.string.amount) + String.format(getContext().getString(R.string.range_range_is), "200~10000")); } if (totalTrue && rillTrue) { LiveNetManager.get(getContext()) diff --git a/live/src/main/java/com/yunbao/live/views/LiveRoomViewHolder.java b/live/src/main/java/com/yunbao/live/views/LiveRoomViewHolder.java index 8b1e4dfa2..253e2ba9f 100644 --- a/live/src/main/java/com/yunbao/live/views/LiveRoomViewHolder.java +++ b/live/src/main/java/com/yunbao/live/views/LiveRoomViewHolder.java @@ -1453,11 +1453,11 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis redPacketQueue.setVisibility(View.VISIBLE); redPacketCountdown.setVisibility(View.GONE); StringBuffer stringBuffer = new StringBuffer(); - stringBuffer.append(mRedPacketModel.getRedPacketRemain() ) + stringBuffer.append(mRedPacketModel.getRedPacketCount()) .append("/") .append(mRedPacketModel.getRedPacketQuantity()); redSchedule.setText(stringBuffer.toString()); - openRedPacket.setText(String.format(mContext.getString(R.string.open_red_packet), mRedPacketModel.getRedPacketCount()+ "")); + openRedPacket.setText(String.format(mContext.getString(R.string.open_red_packet), mRedPacketModel.getRedPacketRemain() + "")); } if (IMLoginManager.get(mContext).getUserInfo().anchorUserType() && mContext instanceof LiveRyAnchorActivity) { anchorTimeHandler.removeCallbacks(anchorTimeRunnable);