Forráskód Böngészése

Merge branch 'feature/1.5.3-update-20240117' into develop

vothin 1 éve
szülő
commit
30fbbfa11b

+ 2 - 1
languages/en.js

@@ -233,7 +233,8 @@ module.exports = {
     simulateSend: 'Simulate Send',
     justify: 'alignment',
     indent: 'indentation',
-    image: 'picture'
+    image: 'picture',
+    video: 'video'
   },
   member: {
     face: 'Avatar',

+ 2 - 1
languages/es.js

@@ -233,7 +233,8 @@ module.exports = {
     simulateSend: 'Simular envío',
     justify: 'Alinear',
     indent: 'Sangrado',
-    image: 'Imagen'
+    image: 'Imagen',
+    video: 'Vídeo'
   },
   member: {
     face: 'Avatar',

+ 2 - 1
languages/ru-RU.js

@@ -233,7 +233,8 @@ module.exports = {
     simulateSend: 'аналоговая передача',
     justify: 'Выровнять',
     indent: 'Отступ',
-    image: 'Фотографии'
+    image: 'Фотографии',
+    video: 'Видео'
   },
   member: {
     face: 'Аватар',

+ 2 - 1
languages/zh-CN.js

@@ -233,7 +233,8 @@ module.exports = {
     simulateSend: '模拟发送',
     justify: '对齐',
     indent: '缩进',
-    image: '图片'
+    image: '图片',
+    video: '视频'
   },
   member: {
     face: '头像',

+ 9 - 9
src/components/WangEdiitor/wangEditorConfig.js

@@ -62,15 +62,15 @@ export const toolbarConfig = {
       menuKeys: ['uploadImage',
         'insertImage']
     },
-    // {
-    //   "key": "group-video",
-    //   "title": "视频",
-    //   "iconSvg": "<svg viewBox=\"0 0 1024 1024\"><path d=\"M981.184 160.096C837.568 139.456 678.848 128 512 128S186.432 139.456 42.816 160.096C15.296 267.808 0 386.848 0 512s15.264 244.16 42.816 351.904C186.464 884.544 345.152 896 512 896s325.568-11.456 469.184-32.096C1008.704 756.192 1024 637.152 1024 512s-15.264-244.16-42.816-351.904zM384 704V320l320 192-320 192z\"></path></svg>",
-    //   "menuKeys": [
-    //     "insertVideo",
-    //     "uploadVideo"
-    //   ]
-    // },
+    {
+      'key': 'group-video',
+      'title': i18n.t('action.image'),
+      'iconSvg': '<svg viewBox="0 0 1024 1024"><path d="M981.184 160.096C837.568 139.456 678.848 128 512 128S186.432 139.456 42.816 160.096C15.296 267.808 0 386.848 0 512s15.264 244.16 42.816 351.904C186.464 884.544 345.152 896 512 896s325.568-11.456 469.184-32.096C1008.704 756.192 1024 637.152 1024 512s-15.264-244.16-42.816-351.904zM384 704V320l320 192-320 192z"></path></svg>',
+      'menuKeys': [
+        'insertVideo'
+        // "uploadVideo"
+      ]
+    },
     'insertTable',
     'codeBlock',
     'divider',

+ 1 - 1
src/views/ncs-advice/index.vue

@@ -85,7 +85,7 @@
                   value-format="timestamp"
                   :default-value="new Date()"
                   :placeholder="this.$t('customerManage.choiceDate')"
-                  :picker-options="{disabledDate(time) { return time.getTime() > Date.now() }}"
+                  :picker-options="{disabledDate(time) { return time.getTime() < addAdviceForm.start_time }}"
               />
             </el-form-item>
           </el-col>

+ 65 - 54
src/views/ncs-interaction/index.vue

@@ -61,63 +61,61 @@
         @current-change="handlePageCurrentChange"
       />
     </ag-grid-layout>
-      <el-dialog :v-loading="this.loading" :title="this.$t('interaction.recordPlay')" :visible.sync="dialogVisible" :before-close="stop" width="70%">
-        <template>
-          <el-row v-if="this.streamingType">
-            <el-col :span="12">
-              <video
+    <el-dialog :v-loading="this.loading" :title="this.$t('interaction.recordPlay')" :visible.sync="dialogVisible" :before-close="stop" :width="this.streaming2Show ? '70%' : '40%'">
+      <template>
+        <el-row v-if="this.streamingType">
+          <el-col :span="this.streaming2Show ? 12 : 24">
+            <video
+              :src="this.srcStreaming1"
+              autoplay="autoplay"
+              controls="controls"
+              ref="video1"
+              style="width: 98%"
+            >
+            </video>
+          </el-col>
+
+          <el-col :span="12" v-show="this.streaming2Show">
+            <video
+              :src="this.srcStreaming2"
+              autoplay="autoplay"
+              controls="controls"
+              ref="video2"
+              style="width: 98%"
+            >
+            </video>
+          </el-col>
+        </el-row>
+
+        <el-row v-else>
+          <el-col :span="this.streaming2Show ? 12 : 24">
+            <audio
                 :src="this.srcStreaming1"
                 autoplay="autoplay"
                 controls="controls"
-                ref="video1"
+                ref="audio1"
                 style="width: 98%"
-              >
-              </video>
-            </el-col>
+            >
+            </audio>
+          </el-col>
 
-            <el-col :span="12">
-              <video
+          <el-col :span="12" v-show="streaming2Show">
+            <audio
                 :src="this.srcStreaming2"
                 autoplay="autoplay"
                 controls="controls"
-                ref="video2"
+                ref="audio2"
                 style="width: 98%"
-              >
-              </video>
-            </el-col>
-          </el-row>
-
-          <el-row v-else>
-
-            <el-col :span="12">
-              <audio
-                  :src="this.srcStreaming1"
-                  autoplay="autoplay"
-                  controls="controls"
-                  ref="audio1"
-                  style="width: 98%"
-              >
-              </audio>
-            </el-col>
-
-            <el-col :span="12">
-              <audio
-                  :src="this.srcStreaming2"
-                  autoplay="autoplay"
-                  controls="controls"
-                  ref="audio2"
-                  style="width: 98%"
-              >
-              </audio>
-            </el-col>
-          </el-row>
-
-          <div slot="footer" class="dialog-footer" style="text-align: center">
-            <el-button ref="play" type="primary" @click="onclick('onclick')"> {{ this.buttonStr }} </el-button>
-          </div>
-        </template>
-      </el-dialog>
+            >
+            </audio>
+          </el-col>
+        </el-row>
 
+        <div slot="footer" class="dialog-footer" style="text-align: center">
+          <el-button ref="play" type="primary" @click="onclick('onclick')"> {{ this.buttonStr }} </el-button>
+        </div>
+      </template>
+    </el-dialog>
   </div>
 </template>
 
@@ -132,6 +130,7 @@ import RecordButtonCellRender from "@/components/AgGridCellRender/RecordButtonCe
 import RadioFilter from "@/components/AgGridCustomFilter/RadioFilter";
 import ListFilter from "@/components/AgGridCustomFilter/ListFilter";
 import * as API_Part from "@/api/ncs_partInfo";
+import * as API_ServiceInfo from "@/api/ncs_service_info";
 const DeviceUrl = domain.DeviceUrl
 
 export default {
@@ -198,8 +197,9 @@ export default {
       beginSeconds: 0,
       buttonStr: this.$t('action.play'),
       dialogVisible: false,
+      streaming2Show: false,
       streamingType: true,
-      recordDir: '',
+      recordDir: ''
     }
   },
   computed: {
@@ -611,13 +611,24 @@ export default {
             this.streamingType = true
           } else if (res[0].endsWith("opus")) {
             this.streamingType = false
+          } else if (res[0].endsWith("wav")) {
+            this.streamingType = false
           }
 
-          this.srcStreaming1 = DeviceUrl + res[0]
-          this.srcStreaming2 = DeviceUrl + res[1]
-          console.log(this.srcStreaming1)
-          console.log(this.srcStreaming2)
-          this.dialogVisible = true
+          if (res.length === 2) {
+            this.streaming2Show = true
+            this.srcStreaming1 = DeviceUrl + res[0]
+            this.srcStreaming2 = DeviceUrl + res[1]
+            console.log(this.srcStreaming1)
+            console.log(this.srcStreaming2)
+            this.dialogVisible = true
+          }
+          else {
+            this.streaming2Show = false
+            this.srcStreaming1 = DeviceUrl + res[0]
+            console.log(this.srcStreaming1)
+            this.dialogVisible = true
+          }
         } else {
           this.$message(this.$t('action.noFile'))
         }
@@ -664,7 +675,7 @@ export default {
         this.$refs.audio2.pause()
       }
       this.dialogVisible = false
-    },
+    }
   }
 }
 </script>