Commit b52c89fe by chenwq

朋友圈展示样式

1 parent fa7fd711
...@@ -54,13 +54,15 @@ ...@@ -54,13 +54,15 @@
</div> </div>
<div class="event-content">{{ item.eventContent }}</div> <div class="event-content">{{ item.eventContent }}</div>
<div class="event-link" v-if="item.object"> <div class="event-link" v-if="item.object">
<img class="m-r-10" v-if="item.object.additionalType" :src="require(`@/assets/sop/icon-${imgIcon[item.object.additionalType]}.png`)" alt /> <img class="m-r-10" v-if="item.object.additionalType && item.object.additionalType != 4" :src="require(`@/assets/sop/icon-${imgIcon[item.object.additionalType]}.png`)" alt />
<div v-if="item.object.additionalType == 4"> <div v-if="item.object.additionalType == 4">
<div v-if="item.object.showVideoContent.length"> <div v-if="item.object.showVideoContent.length">
<video class="model-item-img" :src="item.object.showVideoContent[0].attContent" controls="controls" /> <!-- <video class="model-item-img" :src="item.object.showVideoContent[0].attContent" controls="controls" /> -->
<video v-for="(subItem, subIndex) in item.object.showVideoContent" class="model-item-img" :key="subIndex" :src="subItem.attContent" controls="controls" />
</div> </div>
<div v-if="!item.object.showVideoContent.length && item.object.showImgContent.length"> <div v-if="!item.object.showVideoContent.length && item.object.showImgContent.length">
<img class="model-item-img" :src="item.object.showImgContent[0].attContent" /> <!-- <img class="model-item-img" :src="item.object.showImgContent[0].attContent" /> -->
<el-image v-for="(subItem, subIndex) in item.object.showImgContent" class="model-item-img" :key="subIndex" :src="subItem.attContent" :preview-src-list="[subItem.attContent]"></el-image>
</div> </div>
</div> </div>
<span v-else>{{ item.object.objectName }}</span> <span v-else>{{ item.object.objectName }}</span>
...@@ -583,8 +585,8 @@ export default { ...@@ -583,8 +585,8 @@ export default {
margin-bottom: 12px; margin-bottom: 12px;
} }
.model-item-img { .model-item-img {
width: 20px; width: 90px;
height: 20px; height: 78px;
margin-right: 5px; margin-right: 5px;
} }
.event-link { .event-link {
......
...@@ -47,13 +47,16 @@ ...@@ -47,13 +47,16 @@
<!-- additionalType 附加对象类型(1素材,2活动,3优惠券,4朋友券模板) --> <!-- additionalType 附加对象类型(1素材,2活动,3优惠券,4朋友券模板) -->
<div v-if="itm.additionalType" class="welcome-file"> <div v-if="itm.additionalType" class="welcome-file">
<template> <template>
<img :src="require(`@/assets/sop/icon-${btnList.find(k => k.id == itm.additionalType).type}.png`)" alt /> <img class="event-icon" v-if="itm.additionalType != 4" :src="require(`@/assets/sop/icon-${btnList.find(k => k.id == itm.additionalType).type}.png`)" alt />
<div v-if="itm.additionalType == 4"> <div v-if="itm.additionalType == 4">
<div v-if="itm.attContent.showVideoContent.length"> <div v-if="itm.attContent.showVideoContent.length">
<video class="model-item-img" :src="itm.attContent.showVideoContent[0].attContent" controls="controls" /> <!-- <video class="model-item-img" :src="itm.attContent.showVideoContent[0].attContent" controls="controls" /> -->
<video v-for="(subItem, subIndex) in itm.attContent.showVideoContent" class="model-item-img" :key="subIndex" :src="subItem.attContent" controls="controls" />
</div> </div>
<div v-if="!itm.attContent.showVideoContent.length && itm.attContent.showImgContent.length"> <div v-if="!itm.attContent.showVideoContent.length && itm.attContent.showImgContent.length">
<img class="model-item-img" :src="itm.attContent.showImgContent[0].attContent" /> <!-- <img class="model-item-img" :src="itm.attContent.showImgContent[0].attContent" /> -->
<el-image v-for="(subItem, subIndex) in itm.attContent.showImgContent" class="model-item-img" :key="subIndex" :src="subItem.attContent" :preview-src-list="[subItem.attContent]"></el-image>
<!-- <img :key="subIndex" :src="subItem.attContent" /> -->
</div> </div>
</div> </div>
<span v-else :title="itm.attContent.objectName">{{ itm.attContent.objectName }}</span> <span v-else :title="itm.attContent.objectName">{{ itm.attContent.objectName }}</span>
...@@ -64,7 +67,7 @@ ...@@ -64,7 +67,7 @@
<div class="btn-group"> <div class="btn-group">
<div class="add-btn" v-for="item in btnList" :key="item.id"> <div class="add-btn" v-for="item in btnList" :key="item.id">
<!-- <img :src="require(`@/assets/sop/add-${item.type}.png`)" alt v-if="item.id == 1" @click="selectEmotion" /> --> <!-- <img :src="require(`@/assets/sop/add-${item.type}.png`)" alt v-if="item.id == 1" @click="selectEmotion" /> -->
<img :src="require(`@/assets/sop/add-${item.type}.png`)" alt /> <img class="event-icon" :src="require(`@/assets/sop/add-${item.type}.png`)" alt />
<!-- <span v-if="item.id == 1" @click.stop="selectEmotion">{{ item.name }}</span> --> <!-- <span v-if="item.id == 1" @click.stop="selectEmotion">{{ item.name }}</span> -->
<span>{{ item.name }}</span> <span>{{ item.name }}</span>
<!-- <input v-if="item.type == 'img'" type="file" style="opacity: 0" :id="item.name + 'file'" ref="file" class="welcome-input upload-img" :accept="item.accept || 'image/png, image/jpeg, image/jpg'" @change="e => handleImgChange(e, item)" /> <!-- <input v-if="item.type == 'img'" type="file" style="opacity: 0" :id="item.name + 'file'" ref="file" class="welcome-input upload-img" :accept="item.accept || 'image/png, image/jpeg, image/jpg'" @change="e => handleImgChange(e, item)" />
...@@ -648,12 +651,16 @@ export default { ...@@ -648,12 +651,16 @@ export default {
margin-bottom: 10px; margin-bottom: 10px;
border-left: 1px solid #dcdfe6; border-left: 1px solid #dcdfe6;
border-right: 1px solid #dcdfe6; border-right: 1px solid #dcdfe6;
.model-item-img, .event-icon {
img {
width: 20px; width: 20px;
height: 20px; height: 20px;
margin-right: 5px; margin-right: 5px;
} }
.model-item-img {
width: 90px !important;
height: 78px !important;
margin-right: 5px;
}
span { span {
display: inline-block; display: inline-block;
margin-right: 20px; margin-right: 20px;
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!