VideoIntegrateController.java 1.8 KB
package com.skua.modules.video.controller;

import com.skua.core.api.vo.Result;
import com.skua.core.aspect.annotation.AutoLog;
import com.skua.modules.video.vo.VideoIntegrateVO;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * <pre>
 * 与三方视频对接
 * </pre>
 * @author Li Yuanyuan
 * @version V0.1, 2022年4月13日 下午4:49:21
 */
@Api(tags="与三方视频对接")
@RestController
@RequestMapping("/sys/video")
@ConditionalOnProperty("skua.video.ip")
public class VideoIntegrateController {

   @Value("${skua.video.ip:}")
   private String ip;
   @Value("${skua.video.port:}")
   private String port;
   @Value("${skua.video.appkey:}")
   private String appkey;
   @Value("${skua.video.secretkey:}")
   private String secretkey;

   /**
    * <pre>
    * 获取三方视频连接配置数据
    * </pre>
    * @return
    * @author Li Yuanyuan, 2020年6月1日 下午2:21:58
    */
   @AutoLog(value = "获取三方视频连接配置数据")
   @ApiOperation(value="获取三方视频连接配置数据", notes="获取三方视频连接配置数据")
   @GetMapping(value = "/getVideoIntegrateInfo")
   public Result<VideoIntegrateVO> getVideoIntegrateInfo() {
       Result<VideoIntegrateVO> result = new Result<VideoIntegrateVO>();
       VideoIntegrateVO vo = new VideoIntegrateVO();
       vo.setIp(ip);vo.setPort(port);vo.setAppkey(appkey);vo.setSecretkey(secretkey);
       result.success("三方视频配置获取成功");
       result.setResult(vo);
       return result;
   }
}