瀏覽代碼

播放优先级修改 2023-02-10

donggaosheng 2 年之前
父節點
當前提交
623a75ce76

+ 3 - 2
zd-modules/zd-algorithm/src/main/java/com/zd/alg/speaker/service/impl/SpeakerServiceImpl.java

@@ -179,7 +179,7 @@ public class SpeakerServiceImpl implements ISpeakerService {
             commonTextUrlVoice(texts, playVoList,playNum,level);
         } else {
             String deviceIp =playVoList.get(0).getDeviceIp();
-            PlayBatchVo playBatchVo=commonPatchTextUrlVoice(texts,playVoList,playNum);
+            PlayBatchVo playBatchVo=commonPatchTextUrlVoice(texts,playVoList,playNum,level);
             boolean isTrue = invokePost(JSONObject.toJSON(playBatchVo).toString(), deviceIp,1, playVoList.get(0).getPort());
             if (isTrue) {
                 textParseVoiceAppIps(texts,playVoList,playNum,level);
@@ -290,13 +290,14 @@ public class SpeakerServiceImpl implements ISpeakerService {
      * @param texts
      * @param playVoList
      */
-    private PlayBatchVo commonPatchTextUrlVoice(String texts,List<PlayVo> playVoList,Integer playNum) {
+    private PlayBatchVo commonPatchTextUrlVoice(String texts,List<PlayVo> playVoList,Integer playNum,Integer level) {
         PlayBatchVo playBatchVo = new PlayBatchVo();
         BeanUtils.copyProperties(playVoList.get(0), playBatchVo);
         List<UrlVo> urlVoList = getUrlList(texts,playNum);
         if (null != playBatchVo.getParams()) {
             playBatchVo.getParams().setTid(UUID.randomUUID().toString());
             playBatchVo.getParams().setUrls(urlVoList);
+            playBatchVo.getParams().setLevel(level);
         }
         List<String> snsList = new ArrayList<>();
         for (PlayVo playVo : playVoList) {