|
@@ -28,6 +28,7 @@
|
|
|
<span @click="liveon"><i class="iconfont iconshexiangtou"></i>直播</span>
|
|
|
<span @click="liveclose">关闭</span>
|
|
|
<span @click="shareon"><i class="iconfont iconfenxiang"></i>屏幕</span>
|
|
|
+ <span><el-switch @change="recordclick" v-model="isrecord" active-text="录制" inactive-text="停录"> </el-switch></span>
|
|
|
</el-col>
|
|
|
<el-col :span="2" class="noVideo"> </el-col>
|
|
|
<el-col :span="20" class="video">
|
|
@@ -78,6 +79,7 @@ import Vue from 'vue';
|
|
|
import { mapState, createNamespacedHelpers } from 'vuex';
|
|
|
const { mapActions: gensign } = createNamespacedHelpers('gensign');
|
|
|
const { mapActions: chat } = createNamespacedHelpers('chat');
|
|
|
+const { mapActions: room } = createNamespacedHelpers('room');
|
|
|
import TRTC from 'trtc-js-sdk';
|
|
|
export default {
|
|
|
name: 'detailInfo',
|
|
@@ -104,6 +106,7 @@ export default {
|
|
|
open_: false,
|
|
|
content: '',
|
|
|
dataList: [],
|
|
|
+ isrecord: false,
|
|
|
};
|
|
|
},
|
|
|
created() {
|
|
@@ -117,6 +120,17 @@ export default {
|
|
|
methods: {
|
|
|
...gensign(['gensignFetch']),
|
|
|
...chat(['query', 'create', 'fetch']),
|
|
|
+ ...room(['startrecord', 'stoprecord']),
|
|
|
+ async recordclick() {
|
|
|
+ console.log(this.isrecord);
|
|
|
+ if (this.isrecord) {
|
|
|
+ const info = { roomid: this.id, roomname: this.name };
|
|
|
+ let res = await this.startrecord({ ...info });
|
|
|
+ } else {
|
|
|
+ const info = { roomid: this.id, roomname: this.name };
|
|
|
+ let res = await this.stoprecord({ ...info });
|
|
|
+ }
|
|
|
+ },
|
|
|
async chatSearch({ skip = 0, limit = 1000 } = {}) {
|
|
|
const info = { roomid: this.id };
|
|
|
let res = await this.query({ skip, limit, ...info });
|