|
@@ -1,5 +1,6 @@
|
|
|
package com.ym.mec.web.controller;
|
|
|
|
|
|
+import com.microsvc.toolkit.middleware.live.LivePluginContext;
|
|
|
import com.microsvc.toolkit.middleware.live.message.TencentWrapper;
|
|
|
import com.ym.mec.biz.dal.dto.ImLiveBroadcastRoomDto;
|
|
|
import com.ym.mec.biz.dal.dto.LiveRoomStatus;
|
|
@@ -19,6 +20,7 @@ import com.ym.mec.common.page.PageInfo;
|
|
|
import com.ym.mec.common.page.WrapperUtil;
|
|
|
import io.swagger.annotations.*;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
+import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.security.access.prepost.PreAuthorize;
|
|
|
import org.springframework.web.bind.annotation.*;
|
|
|
|
|
@@ -46,6 +48,8 @@ public class ImLiveBroadcastRoomController extends BaseController {
|
|
|
@Resource
|
|
|
private ImLiveBroadcastRoomService imLiveBroadcastRoomService;
|
|
|
|
|
|
+ @Autowired
|
|
|
+ private LivePluginContext livePluginContext;
|
|
|
@ApiImplicitParams({
|
|
|
@ApiImplicitParam(name = "search", dataType = "String", value = "模糊查询关键字"),
|
|
|
@ApiImplicitParam(name = "liveState", dataType = "Integer", value = "直播状态 0未开始 1开始 2结束"),
|
|
@@ -306,5 +310,20 @@ public class ImLiveBroadcastRoomController extends BaseController {
|
|
|
return succeed(imLiveBroadcastRoomService.roomLiveStreamStatus(roomUid));
|
|
|
}
|
|
|
|
|
|
+
|
|
|
+ @ApiOperation("直播间自定义")
|
|
|
+ @ApiImplicitParams({
|
|
|
+ @ApiImplicitParam(name = "roomUid", dataType = "String", value = "房间Uid", required = true),
|
|
|
+ })
|
|
|
+ @GetMapping(value = "/liveDefineData")
|
|
|
+ public HttpResponseResult<Object> liveDefineData(String roomUid) throws Exception {
|
|
|
+
|
|
|
+ // 直播间推流状态查询
|
|
|
+
|
|
|
+ List<TencentWrapper.ChatRoomGroupCounter> chatRoomGroupDefinedData = livePluginContext
|
|
|
+ .getPluginService().getChatRoomGroupDefinedData(roomUid);
|
|
|
+ return succeed(chatRoomGroupDefinedData);
|
|
|
+ }
|
|
|
+
|
|
|
}
|
|
|
|