Browse Source

话题管理详情语音

dev-用户反馈
mk 3 years ago
parent
commit
886ec9a3f9
  1. 59
      src/views/modules/shequzhili/htgl/cpts/htglInfo.vue
  2. 24
      src/views/modules/shequzhili/htgl/index.vue

59
src/views/modules/shequzhili/htgl/cpts/htglInfo.vue

@ -15,10 +15,13 @@
<el-row type="flex" >
<el-col :span="24" style="display: flex;">
<span class="img_label">图片:</span>
<span :class="htglDetailData.topicImages?'img_label':'htgl_info_label'" >图片:</span>
<template v-if=" htglDetailData.topicImages">
<section v-for="(item,index) in htglDetailData.topicImages" :key="index" >
<img :src="item" alt="" width="150px" height="200px" :style="{'margin-left': index==0?'0px':'16px'}" />
</section>
</template>
<span v-if="htglDetailData.topicImages==null">--</span>
</el-col>
</el-row>
@ -33,7 +36,18 @@
<span class="htgl_info_label">发布时间:</span> {{htglDetailData.releaseTime||'--'}}
</el-col>
</el-row>
<el-row type="flex" >
<el-col :span="24">
<span :class="htglDetailData.topicVoices ? 'img_label':'htgl_info_label'">语音详情:</span>
<div style=" display: inline-block;" v-if="htglDetailData.topicVoices">
<audio controls v-if="htglDetailData.topicVoices">
<source :src="htglDetailData.topicVoices[0].url" type="">
</audio>
</div>
<span v-else>--</span>
</el-col>
</el-row>
<el-row type="flex" >
<el-col :span="24">
<span class="htgl_info_label">当前支持:</span>{{htglDetailData.supportCount||'--'}},反对: {{htglDetailData.oppositionCount||'--'}}
@ -44,24 +58,45 @@
</template>
<script>
import nextTick from "dai-js/tools/nextTick";
import { requestPost } from "@/js/dai/request";
export default {
data() {
return {};
return {
htglDetailData:{}
};
},
props:{
htglDetailData:{
type:Object,
default:{}
},
topicId:{
htglDetailId:{
type:String,
default:''
default:""
},
},
created() {
this.getEditList()
// console.log(this.htglDetailData);
// this.$set(this.htglDetailData,'topicVoices',this.htglDetailData)
},
methods:{
async getEditList(){
const url = "/resi/group/ytTopic/topicDetail";
const { data, code, msg } = await requestPost(url, {
topicId: this.htglDetailId
});
if (code === 0) {
this.htglDetailData = { ...data };
} else {
this.$message.error(msg);
}
}
},
created() {},
methods: {},
mounted(){
},
components: {},
computed: {},
computed: {
},
watch: {},
};
</script>

24
src/views/modules/shequzhili/htgl/index.vue

@ -164,14 +164,14 @@
</div>
<el-dialog
title="话题详情"
:visible.sync="dialogVisible"
:visible.sync="showhtglDialog"
width="950px"
v-if="showhtglDialog"
@close="showhtglDialog = false"
>
<htgl-info
:htglDetailData="htglDetailData"
:topicId="topicId"
:htglDetailId="htglDetailId"
>
</htgl-info>
</el-dialog>
</div>
@ -200,11 +200,12 @@ export default {
startDate: '',
endDate: '',
},
showhtglDialog:false,
topicId:'',
tableData:[],
dialogVisible:false,
agencyIdArray: [],
htglDetailData:{},
htglDetailId:"",
pageNo: 1,
pageSize: window.localStorage.getItem("pageSize") || 20,
total: 1,
@ -294,17 +295,8 @@ export default {
}
},
async handleWatch (row) {
this.topicId = row.topicId
this.dialogVisible = true
const url = "/resi/group/ytTopic/topicDetail";
const { data, code, msg } = await requestPost(url, {
topicId: this.topicId,
});
if (code === 0) {
this.htglDetailData = { ...data };
} else {
this.$message.error(msg);
}
this.showhtglDialog = true
this.htglDetailId = row.topicId
},
},
components: {

Loading…
Cancel
Save