红包中奖列表

This commit is contained in:
18401019693
2023-07-03 17:48:02 +08:00
parent 58508ca0ae
commit 895a1c6951
7 changed files with 109 additions and 30 deletions

View File

@@ -788,4 +788,13 @@ public interface PDLiveApi {
Observable<ResponseModel<List<RedPacketGiftModel>>> getRedPacketSuperPrizeReceive(
@Query("super_jackpot_id") String superJackpotId
);
/**
* 获取普通红包的领取记录
*/
@GET("/api/public/?service=Live.endRedPacket")
Observable<ResponseModel<Object>> endRedPacket(
@Query("liveuid") String liveUid,
@Query("red_packet_id") String redPacketId
);
}

View File

@@ -1692,6 +1692,28 @@ public class LiveNetManager {
}).isDisposed();
}
public void endRedPacket(String liveUid,String redPacketId, HttpCallback<String> callback) {
API.get().pdLiveApi(mContext)
.endRedPacket(liveUid, redPacketId)
.subscribeOn(Schedulers.io())
.observeOn(AndroidSchedulers.mainThread())
.subscribe(new Consumer<ResponseModel<Object>>() {
@Override
public void accept(ResponseModel<Object> objectResponseModel) throws Exception {
if (callback != null) {
callback.onSuccess("");
}
}
}, new Consumer<Throwable>() {
@Override
public void accept(Throwable throwable) throws Exception {
if (callback != null) {
callback.onError(mContext.getString(R.string.net_error));
}
}
}).isDisposed();
}
/**
* 直播间取消网络请求
*/