|
|
@@ -313,7 +313,7 @@
|
|
|
|
|
|
<!-- 修改按钮部分 -->
|
|
|
<el-link
|
|
|
- v-if="setList.contentType == 1 && roles.includes('edit_sop_temp_content')"
|
|
|
+ v-if="(setList.contentType == 1 || setList.contentType == 15) && roles.includes('edit_sop_temp_content')"
|
|
|
type="primary"
|
|
|
@click="toggleSalesCall(index, contentIndex, setIndex)"
|
|
|
style="margin-top: 10px;"
|
|
|
@@ -321,7 +321,7 @@
|
|
|
{{ setList.isSalesCallAdded ? '移除#销售称呼#' : '添加#销售称呼#' }}
|
|
|
</el-link>
|
|
|
<el-link
|
|
|
- v-if="setList.contentType == 1 && roles.includes('edit_sop_temp_content')"
|
|
|
+ v-if="(setList.contentType == 1 || setList.contentType == 15) && roles.includes('edit_sop_temp_content')"
|
|
|
type="primary"
|
|
|
@click="toggleUserNameCall(index, contentIndex, setIndex)"
|
|
|
style="margin-top: 10px; margin-left: 20px"
|
|
|
@@ -334,7 +334,7 @@
|
|
|
type="image" :num="1" :width="150" :height="150"/>
|
|
|
|
|
|
<div
|
|
|
- v-if="setList.contentType == 3 || (setList.contentType == 9 && content.type==2 )">
|
|
|
+ v-if="(setList.contentType == 3 || item.contentType ==9) || (setList.contentType == 9 && content.type==2 )">
|
|
|
<el-card class="box-card">
|
|
|
<el-form-item label="链接标题:" label-width="100px" required>
|
|
|
<el-input :disabled="formType == 3 || (form.sendType == 11 && contentIndex != 0 && setIndex == 0)" v-model="setList.linkTitle"
|
|
|
@@ -474,7 +474,7 @@
|
|
|
</video>
|
|
|
</el-form-item>
|
|
|
</div>
|
|
|
- <div v-if="setList.contentType == 7 ">
|
|
|
+ <div v-if="setList.contentType == 7 || setList.contentType == 16">
|
|
|
<el-input
|
|
|
:disabled="formType == 3 || !roles.includes('edit_sop_temp_content')"
|
|
|
v-model="setList.value"
|
|
|
@@ -526,6 +526,27 @@
|
|
|
|
|
|
</el-card>
|
|
|
</div>
|
|
|
+ <div v-if="setList.contentType == 14">
|
|
|
+ <el-card class="box-card">
|
|
|
+ <el-form-item label="福袋名称" >
|
|
|
+ <el-select :disabled="formType == 3" v-model="setList.luckyBagId"
|
|
|
+ placeholder="请选择福袋" size="mini"
|
|
|
+ @change="getLuckyBagStatus(setList)" >
|
|
|
+ <el-option
|
|
|
+ v-for="dict in luckyBagList"
|
|
|
+ :key="dict.id"
|
|
|
+ :label="dict.name"
|
|
|
+ :value="dict.id"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="福袋状态" >
|
|
|
+ <el-tag :disabled="formType == 3" :type="setList.luckyBagDataStatus == 1 ? 'success' : 'danger'">
|
|
|
+ {{ setList.luckyBagDataStatus == 1 ? '启用' : '禁用' }}
|
|
|
+ </el-tag>
|
|
|
+ </el-form-item>
|
|
|
+ </el-card>
|
|
|
+ </div>
|
|
|
</el-form-item>
|
|
|
<!-- <el-form-item label="添加短链"-->
|
|
|
<!-- v-if="content.type == 2 && setList.contentType == 1 ">-->
|
|
|
@@ -731,6 +752,7 @@ import {courseList, videoList} from "@/api/qw/sop";
|
|
|
import {listToLiveNoEnd} from "@/api/live/live";
|
|
|
import ImageUpload from "@/views/qw/sop/ImageUpload";
|
|
|
import userVideo from "@/views/qw/userVideo/userVideo.vue";
|
|
|
+import {listReward} from "@/api/qw/luckyBag";
|
|
|
import {
|
|
|
getRoles,
|
|
|
} from "@/api/qw/sop";
|
|
|
@@ -740,6 +762,14 @@ export default {
|
|
|
components: {ImageUpload, userVideo, draggable},
|
|
|
data() {
|
|
|
return {
|
|
|
+ queryParams1: {
|
|
|
+ pageNum: 1,
|
|
|
+ pageSize: 10,
|
|
|
+ dataStatus: '1',
|
|
|
+ name: null,
|
|
|
+ type: null
|
|
|
+ },
|
|
|
+ luckyBagList: [],
|
|
|
projectFrom:process.env.VUE_APP_PROJECT_FROM,
|
|
|
addTag: [{
|
|
|
addTag: [],
|
|
|
@@ -874,6 +904,9 @@ export default {
|
|
|
listToLiveNoEnd().then(response => {
|
|
|
this.liveList = response.rows;
|
|
|
})
|
|
|
+ listReward(this.queryParams1).then(response => {
|
|
|
+ this.luckyBagList = response.rows;
|
|
|
+ });
|
|
|
|
|
|
const id = this.$route.params && this.$route.params.id;
|
|
|
this.id = id;
|
|
|
@@ -882,6 +915,15 @@ export default {
|
|
|
this.handleUpdate(id);
|
|
|
},
|
|
|
methods: {
|
|
|
+ getLuckyBagStatus(content) {
|
|
|
+ const selectedLuckyBag = this.luckyBagList.find(item => item.id === content.luckyBagId);
|
|
|
+ if (selectedLuckyBag) {
|
|
|
+ content.luckyBagDataStatus = selectedLuckyBag.dataStatus; // 自动填充标题
|
|
|
+ } else {
|
|
|
+ // 若未找到对应直播间,清空标题和封面(可选)
|
|
|
+ content.luckyBagDataStatus = null;
|
|
|
+ }
|
|
|
+ },
|
|
|
liveChange(content) {
|
|
|
// content.liveId 是选中的直播间 ID(liveId)
|
|
|
const selectedLive = this.liveList.find(live => live.liveId === content.liveId);
|