|
@@ -11,7 +11,14 @@
|
|
|
</div>
|
|
|
</el-col>
|
|
|
<el-col :span="24" class="chat">
|
|
|
- <chat></chat>
|
|
|
+ <van-tabs v-model="active">
|
|
|
+ <van-tab title="图文直播">
|
|
|
+ <textVideo :list="lunboList"></textVideo>
|
|
|
+ </van-tab>
|
|
|
+ <van-tab title="公共聊天">
|
|
|
+ <chat></chat>
|
|
|
+ </van-tab>
|
|
|
+ </van-tabs>
|
|
|
</el-col>
|
|
|
<el-col :span="24" class="tab">
|
|
|
<el-tabs v-model="activeName" stretch type="border-card">
|
|
@@ -57,15 +64,18 @@
|
|
|
|
|
|
<script>
|
|
|
import { mapState, createNamespacedHelpers } from 'vuex';
|
|
|
-const { mapActions: dock } = createNamespacedHelpers('dock');
|
|
|
import chat from '@/components/parts/chat.vue';
|
|
|
+import textVideo from '@/components/parts/textVideo.vue';
|
|
|
+const { mapActions: dock } = createNamespacedHelpers('dock');
|
|
|
const { mapActions: exportuser } = createNamespacedHelpers('exportuser');
|
|
|
-
|
|
|
+const { mapActions: marketuser } = createNamespacedHelpers('marketuser');
|
|
|
+import moment from 'moment';
|
|
|
export default {
|
|
|
name: 'videoDetail',
|
|
|
props: {},
|
|
|
components: {
|
|
|
chat,
|
|
|
+ textVideo,
|
|
|
},
|
|
|
data: function() {
|
|
|
return {
|
|
@@ -80,15 +90,21 @@ export default {
|
|
|
// 展会详情
|
|
|
dockInfo: {},
|
|
|
times: 5,
|
|
|
+ // 聊天
|
|
|
+ active: '1',
|
|
|
+ // 图文直播
|
|
|
+ lunboList: [],
|
|
|
};
|
|
|
},
|
|
|
async created() {
|
|
|
await this.seachdock();
|
|
|
await this.seachInfo();
|
|
|
+ await this.seachLunbo();
|
|
|
},
|
|
|
methods: {
|
|
|
...dock({ dockQuery: 'query', dockFetch: 'fetch' }),
|
|
|
...exportuser({ expertQuery: 'query' }),
|
|
|
+ ...marketuser({ operaFetch: 'operaFetch' }),
|
|
|
async seachInfo({ skip = 0, limit = 5, ...info } = {}) {
|
|
|
let res = await this.dockFetch(this.id);
|
|
|
if (this.$checkRes(res)) {
|
|
@@ -104,7 +120,6 @@ export default {
|
|
|
// 专家智库
|
|
|
let exportdata = await this.expertQuery({ role: 6, limit: 6 });
|
|
|
if (this.$checkRes(exportdata)) this.$set(this, `expertList`, exportdata.data);
|
|
|
- console.log('ad');
|
|
|
}
|
|
|
},
|
|
|
// 文字/视频倒计时
|
|
@@ -119,10 +134,23 @@ export default {
|
|
|
}, 1000);
|
|
|
},
|
|
|
async seachdock() {
|
|
|
- let res = await this.dockFetch(this.id);
|
|
|
+ if (this.id) {
|
|
|
+ let res = await this.dockFetch(this.id);
|
|
|
+ if (this.$checkRes(res)) {
|
|
|
+ // 对接会详情
|
|
|
+ this.$set(this, `dockInfo`, res.data);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ // 查询图文直播
|
|
|
+ async seachLunbo() {
|
|
|
+ let res = await this.operaFetch({ dockid: this.id });
|
|
|
+ for (const val of res.data) {
|
|
|
+ var date = moment(val.meta.createdAt).format('YYYY-MM-DD hh:mm');
|
|
|
+ val.date = date;
|
|
|
+ }
|
|
|
if (this.$checkRes(res)) {
|
|
|
- // 对接会详情
|
|
|
- this.$set(this, `dockInfo`, res.data);
|
|
|
+ this.$set(this, `lunboList`, res.data);
|
|
|
}
|
|
|
},
|
|
|
},
|
|
@@ -141,11 +169,12 @@ export default {
|
|
|
watch: {
|
|
|
times: {
|
|
|
handler(val) {
|
|
|
- if (val == 5) {
|
|
|
+ if (val && val == 5) {
|
|
|
this.daojishi();
|
|
|
}
|
|
|
},
|
|
|
immediate: true,
|
|
|
+ deep: true,
|
|
|
},
|
|
|
},
|
|
|
};
|
|
@@ -166,7 +195,7 @@ export default {
|
|
|
padding: 0px 0 15px 0px;
|
|
|
}
|
|
|
.videointro {
|
|
|
- background: url(/img/directBack.d8126f77.png);
|
|
|
+ background: url('~@/assets/directBack.png');
|
|
|
background-size: 100% 100%;
|
|
|
color: #fff;
|
|
|
padding: 0 15px;
|