|
@@ -65,84 +65,46 @@ pc端视频位置 videoPcLoc
|
|
|
before:开场图片前
|
|
|
later:开场图片后
|
|
|
-->
|
|
|
- <div class="coverBase" v-if="info.coverInfo">
|
|
|
+ <div class="coverBase" v-if="info.workCoverType">
|
|
|
<!-- 顶上标题 -->
|
|
|
<span class="title">{{ coverBase_button }}</span>
|
|
|
- <i
|
|
|
- class="iconfont icon-help_i tool-tip-for-editor"
|
|
|
- v-tooltip="coverBase_button_tips"
|
|
|
- >
|
|
|
- </i>
|
|
|
+ <i class="iconfont icon-help_i tool-tip-for-editor" v-tooltip="coverBase_button_tips"> </i>
|
|
|
<br />
|
|
|
<div class="switch-wrapper">
|
|
|
<span class="label">{{ $i18n.t("edit_settings.cover_show") }}</span>
|
|
|
- <Switcher
|
|
|
- :value="info.coverInfo.isShowCover"
|
|
|
- @change="onSwitcherChange"
|
|
|
- ></Switcher>
|
|
|
+ <Switcher :value="info.workCoverType.isShowCover" @change="onSwitcherChange"></Switcher>
|
|
|
</div>
|
|
|
<div class="cover_pull">
|
|
|
<!-- 封面类型选择下拉框 -->
|
|
|
<div class="cover_pull_tit">{{ cover_pull_tit }}</div>
|
|
|
|
|
|
- <Select
|
|
|
- v-model="info.coverInfo.coverSelect"
|
|
|
- class="base-select"
|
|
|
- placement="bottom"
|
|
|
- >
|
|
|
- <Option
|
|
|
- v-for="item in selectList"
|
|
|
- :key="item.type"
|
|
|
- :label="item.txt"
|
|
|
- :value="item.type"
|
|
|
- >
|
|
|
- </Option>
|
|
|
+ <Select v-model="info.workCoverType.coverSelect" class="base-select" placement="bottom">
|
|
|
+ <Option v-for="item in selectList" :key="item.type" :label="item.txt" :value="item.type"> </Option>
|
|
|
</Select>
|
|
|
- <!-- {{ info.coverInfo.coverSelect }} -->
|
|
|
+ <!-- {{ info.workCoverType.coverSelect }} -->
|
|
|
<!-- 关于图片 -->
|
|
|
- <div class="mainImgBox" v-show="info.coverInfo.coverSelect !== 'video'">
|
|
|
+ <div class="mainImgBox" v-show="info.workCoverType.coverSelect !== 'video'">
|
|
|
<div class="coverImgTit">{{ coverImgTit }}</div>
|
|
|
<div class="coverImgBox">
|
|
|
<!-- pc图片 -->
|
|
|
<div class="coverImgBox_ll">
|
|
|
<div class="tit">{{ $i18n.t(`edit_settings.pc`) }}</div>
|
|
|
<div class="coverImgMain">
|
|
|
- <SelectedImage
|
|
|
- :imgSrc="info.coverInfo.coverPc"
|
|
|
- :defaultImgSrc="require('@/assets/img/coverUpTit1.png')"
|
|
|
- @cancel="onCancelPcTip"
|
|
|
- ></SelectedImage>
|
|
|
+ <SelectedImage :imgSrc="info.workCoverType.coverPc" :defaultImgSrc="require('@/assets/img/coverUpTit1.png')" @cancel="onCancelPcTip"></SelectedImage>
|
|
|
<div class="imgRight">
|
|
|
<!-- 上传图片按钮 -->
|
|
|
- <button
|
|
|
- class="ui-button submit"
|
|
|
- @click="
|
|
|
- (isShowSelectionWindow = true),
|
|
|
- (selectingFor = 'pc'),
|
|
|
- (upType = 'image'),
|
|
|
- (upTypeSta = 'imgBac')
|
|
|
- "
|
|
|
- >
|
|
|
+ <button class="ui-button submit" @click="(isShowSelectionWindow = true), (selectingFor = 'pc'), (upType = 'image'), (upTypeSta = 'imgBac')">
|
|
|
{{ $i18n.t(`edit_settings.select_image`) }}
|
|
|
</button>
|
|
|
<!-- 上传提示 -->
|
|
|
- <div
|
|
|
- class="ui-remark"
|
|
|
- v-html="$i18n.t(`edit_settings.coverUpTit1`)"
|
|
|
- ></div>
|
|
|
+ <div class="ui-remark" v-html="$i18n.t(`edit_settings.coverUpTit1`)"></div>
|
|
|
<!-- 选择居中和全屏 -->
|
|
|
<div class="coverImglocBox">
|
|
|
- <div
|
|
|
- :class="{ active: info.coverInfo.coverPcLoc === 'center' }"
|
|
|
- @click="info.coverInfo.coverPcLoc = 'center'"
|
|
|
- >
|
|
|
+ <div :class="{ active: info.workCoverType.coverPcLoc === 'center' }" @click="info.workCoverType.coverPcLoc = 'center'">
|
|
|
<div class="inco"></div>
|
|
|
<div class="txt">{{ coverImgLoc1 }}</div>
|
|
|
</div>
|
|
|
- <div
|
|
|
- :class="{ active: info.coverInfo.coverPcLoc === 'full' }"
|
|
|
- @click="info.coverInfo.coverPcLoc = 'full'"
|
|
|
- >
|
|
|
+ <div :class="{ active: info.workCoverType.coverPcLoc === 'full' }" @click="info.workCoverType.coverPcLoc = 'full'">
|
|
|
<div class="inco inco2"></div>
|
|
|
<div class="txt">{{ coverImgLoc2 }}</div>
|
|
|
</div>
|
|
@@ -154,42 +116,21 @@ pc端视频位置 videoPcLoc
|
|
|
<div class="tit">{{ $i18n.t(`edit_settings.mobile`) }}</div>
|
|
|
<!-- 移动端图片 -->
|
|
|
<div class="coverImgMain">
|
|
|
- <SelectedImage
|
|
|
- :imgSrc="info.coverInfo.coverMo"
|
|
|
- :defaultImgSrc="require('@/assets/img/coverUpTit1.png')"
|
|
|
- @cancel="onCancelAppTip"
|
|
|
- ></SelectedImage>
|
|
|
+ <SelectedImage :imgSrc="info.workCoverType.coverMo" :defaultImgSrc="require('@/assets/img/coverUpTit1.png')" @cancel="onCancelAppTip"></SelectedImage>
|
|
|
<div class="imgRight">
|
|
|
<!-- 上传图片按钮 -->
|
|
|
- <button
|
|
|
- class="ui-button submit"
|
|
|
- @click="
|
|
|
- (isShowSelectionWindow = true),
|
|
|
- (selectingFor = 'mobile'),
|
|
|
- (upType = 'image'),
|
|
|
- (upTypeSta = 'imgBac')
|
|
|
- "
|
|
|
- >
|
|
|
+ <button class="ui-button submit" @click="(isShowSelectionWindow = true), (selectingFor = 'mobile'), (upType = 'image'), (upTypeSta = 'imgBac')">
|
|
|
{{ $i18n.t(`edit_settings.select_image`) }}
|
|
|
</button>
|
|
|
<!-- 上传提示 -->
|
|
|
- <div
|
|
|
- class="ui-remark"
|
|
|
- v-html="$i18n.t(`edit_settings.coverUpTit2`)"
|
|
|
- ></div>
|
|
|
+ <div class="ui-remark" v-html="$i18n.t(`edit_settings.coverUpTit2`)"></div>
|
|
|
<!-- 选择居中和全屏 -->
|
|
|
<div class="coverImglocBox">
|
|
|
- <div
|
|
|
- :class="{ active: info.coverInfo.coverMoLoc === 'center' }"
|
|
|
- @click="info.coverInfo.coverMoLoc = 'center'"
|
|
|
- >
|
|
|
+ <div :class="{ active: info.workCoverType.coverMoLoc === 'center' }" @click="info.workCoverType.coverMoLoc = 'center'">
|
|
|
<div class="inco"></div>
|
|
|
<div class="txt">{{ coverImgLoc1 }}</div>
|
|
|
</div>
|
|
|
- <div
|
|
|
- :class="{ active: info.coverInfo.coverMoLoc === 'full' }"
|
|
|
- @click="info.coverInfo.coverMoLoc = 'full'"
|
|
|
- >
|
|
|
+ <div :class="{ active: info.workCoverType.coverMoLoc === 'full' }" @click="info.workCoverType.coverMoLoc = 'full'">
|
|
|
<div class="inco inco2"></div>
|
|
|
<div class="txt">{{ coverImgLoc2 }}</div>
|
|
|
</div>
|
|
@@ -202,63 +143,24 @@ pc端视频位置 videoPcLoc
|
|
|
<!-- 图片背景设置 -->
|
|
|
<div class="coverImgBacBox">
|
|
|
<div class="tit">{{ $i18n.t(`edit_settings.coverImgBacTit`) }}</div>
|
|
|
- <Select
|
|
|
- v-model="info.coverInfo.coverImgBac"
|
|
|
- class="base-select"
|
|
|
- placement="bottom"
|
|
|
- >
|
|
|
- <Option
|
|
|
- v-for="item in coverImgBacList"
|
|
|
- :key="item.type"
|
|
|
- :label="item.txt"
|
|
|
- :value="item.type"
|
|
|
- >
|
|
|
- </Option>
|
|
|
+ <Select v-model="info.workCoverType.coverImgBac" class="base-select" placement="bottom">
|
|
|
+ <Option v-for="item in coverImgBacList" :key="item.type" :label="item.txt" :value="item.type"> </Option>
|
|
|
</Select>
|
|
|
<!-- 选择颜色 -->
|
|
|
- <div
|
|
|
- class="imgColorSelec"
|
|
|
- v-show="info.coverInfo.coverImgBac === 'colorFill'"
|
|
|
- >
|
|
|
- <div class="ll">{{ info.coverInfo.imgColorSelec }}</div>
|
|
|
- <div
|
|
|
- class="rr"
|
|
|
- :style="`background-color: ${info.coverInfo.imgColorSelec};`"
|
|
|
- ></div>
|
|
|
- <ColorPicker
|
|
|
- @change="imgColorSelecChange"
|
|
|
- v-model="info.coverInfo.imgColorSelec"
|
|
|
- :predefine="predefineColors"
|
|
|
- >
|
|
|
- </ColorPicker>
|
|
|
+ <div class="imgColorSelec" v-show="info.workCoverType.coverImgBac === 'colorFill'">
|
|
|
+ <div class="ll">{{ info.workCoverType.imgColorSelec }}</div>
|
|
|
+ <div class="rr" :style="`background-color: ${info.workCoverType.imgColorSelec};`"></div>
|
|
|
+ <ColorPicker @change="imgColorSelecChange" v-model="info.workCoverType.imgColorSelec" :predefine="predefineColors"> </ColorPicker>
|
|
|
</div>
|
|
|
<!-- 选择背景图片 -->
|
|
|
- <div
|
|
|
- class="imgClolrBacImg"
|
|
|
- v-show="info.coverInfo.coverImgBac === 'imgTile'"
|
|
|
- >
|
|
|
- <SelectedImage
|
|
|
- :imgSrc="info.coverInfo.coverBac"
|
|
|
- :defaultImgSrc="require('@/assets/img/coverUpTit1.png')"
|
|
|
- @cancel="onCancelBac"
|
|
|
- ></SelectedImage>
|
|
|
+ <div class="imgClolrBacImg" v-show="info.workCoverType.coverImgBac === 'imgTile'">
|
|
|
+ <SelectedImage :imgSrc="info.workCoverType.coverBac" :defaultImgSrc="require('@/assets/img/coverUpTit1.png')" @cancel="onCancelBac"></SelectedImage>
|
|
|
<!-- 上传图片按钮 -->
|
|
|
<div class="imgRight">
|
|
|
- <button
|
|
|
- class="ui-button submit"
|
|
|
- @click="
|
|
|
- (isShowSelectionWindow = true),
|
|
|
- (selectingFor = 'bac'),
|
|
|
- (upType = 'image'),
|
|
|
- (upTypeSta = 'imgBac')
|
|
|
- "
|
|
|
- >
|
|
|
+ <button class="ui-button submit" @click="(isShowSelectionWindow = true), (selectingFor = 'bac'), (upType = 'image'), (upTypeSta = 'imgBac')">
|
|
|
{{ $i18n.t(`edit_settings.select_image`) }}
|
|
|
</button>
|
|
|
- <div
|
|
|
- class="ui-remark"
|
|
|
- v-html="$i18n.t(`edit_settings.coverUpTit3`)"
|
|
|
- ></div>
|
|
|
+ <div class="ui-remark" v-html="$i18n.t(`edit_settings.coverUpTit3`)"></div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -272,16 +174,13 @@ pc端视频位置 videoPcLoc
|
|
|
{{ $i18n.t(`edit_settings.coverImageInWayTit`) }}
|
|
|
</div>
|
|
|
<div class="VideoTitR">
|
|
|
- <Switcher
|
|
|
- :value="info.coverInfo.coverImageInWay"
|
|
|
- @change="coverImageInWayChange"
|
|
|
- ></Switcher>
|
|
|
+ <Switcher :value="info.workCoverType.coverImageInWay" @change="coverImageInWayChange"></Switcher>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
<!-- 关于视频 -->
|
|
|
- <div class="mainVideoBox" v-show="info.coverInfo.coverSelect !== 'img'">
|
|
|
+ <div class="mainVideoBox" v-show="info.workCoverType.coverSelect !== 'img'">
|
|
|
<div class="coverImgTit">
|
|
|
{{ $i18n.t(`edit_settings.coverVideoTit`) }}
|
|
|
</div>
|
|
@@ -290,42 +189,21 @@ pc端视频位置 videoPcLoc
|
|
|
<div class="coverImgBox_ll">
|
|
|
<div class="tit">{{ $i18n.t(`edit_settings.pc`) }}</div>
|
|
|
<div class="coverImgMain">
|
|
|
- <SelectedImage
|
|
|
- :imgSrc="info.coverInfo.videoPcIcon"
|
|
|
- :defaultImgSrc="require('@/assets/img/coverUpTit2.png')"
|
|
|
- @cancel="clearVideoPc"
|
|
|
- ></SelectedImage>
|
|
|
+ <SelectedImage :imgSrc="info.workCoverType.videoPcIcon" :defaultImgSrc="require('@/assets/img/coverUpTit2.png')" @cancel="clearVideoPc"></SelectedImage>
|
|
|
<div class="imgRight">
|
|
|
<!-- 上传视频按钮 -->
|
|
|
- <button
|
|
|
- class="ui-button submit"
|
|
|
- @click="
|
|
|
- (isShowSelectionWindow = true),
|
|
|
- (selectingFor = 'pc'),
|
|
|
- (upType = 'video'),
|
|
|
- (upTypeSta = 'videoBac')
|
|
|
- "
|
|
|
- >
|
|
|
+ <button class="ui-button submit" @click="(isShowSelectionWindow = true), (selectingFor = 'pc'), (upType = 'video'), (upTypeSta = 'videoBac')">
|
|
|
{{ $i18n.t(`edit_settings.select_video`) }}
|
|
|
</button>
|
|
|
<!-- 上传提示 -->
|
|
|
- <div
|
|
|
- class="ui-remark"
|
|
|
- v-html="$i18n.t(`edit_settings.coverUpTit4`)"
|
|
|
- ></div>
|
|
|
+ <div class="ui-remark" v-html="$i18n.t(`edit_settings.coverUpTit4`)"></div>
|
|
|
<!-- 选择居中和全屏 -->
|
|
|
<div class="coverImglocBox">
|
|
|
- <div
|
|
|
- :class="{ active: info.coverInfo.videoPcLoc === 'center' }"
|
|
|
- @click="info.coverInfo.videoPcLoc = 'center'"
|
|
|
- >
|
|
|
+ <div :class="{ active: info.workCoverType.videoPcLoc === 'center' }" @click="info.workCoverType.videoPcLoc = 'center'">
|
|
|
<div class="inco"></div>
|
|
|
<div class="txt">{{ coverImgLoc1 }}</div>
|
|
|
</div>
|
|
|
- <div
|
|
|
- :class="{ active: info.coverInfo.videoPcLoc === 'full' }"
|
|
|
- @click="info.coverInfo.videoPcLoc = 'full'"
|
|
|
- >
|
|
|
+ <div :class="{ active: info.workCoverType.videoPcLoc === 'full' }" @click="info.workCoverType.videoPcLoc = 'full'">
|
|
|
<div class="inco inco2"></div>
|
|
|
<div class="txt">{{ coverImgLoc2 }}</div>
|
|
|
</div>
|
|
@@ -337,42 +215,21 @@ pc端视频位置 videoPcLoc
|
|
|
<div class="tit">{{ $i18n.t(`edit_settings.mobile`) }}</div>
|
|
|
<!-- 移动端视频 -->
|
|
|
<div class="coverImgMain">
|
|
|
- <SelectedImage
|
|
|
- :imgSrc="info.coverInfo.videoMoIcon"
|
|
|
- :defaultImgSrc="require('@/assets/img/coverUpTit2.png')"
|
|
|
- @cancel="clearVideoMo"
|
|
|
- ></SelectedImage>
|
|
|
+ <SelectedImage :imgSrc="info.workCoverType.videoMoIcon" :defaultImgSrc="require('@/assets/img/coverUpTit2.png')" @cancel="clearVideoMo"></SelectedImage>
|
|
|
<div class="imgRight">
|
|
|
<!-- 上传视频按钮 -->
|
|
|
- <button
|
|
|
- class="ui-button submit"
|
|
|
- @click="
|
|
|
- (isShowSelectionWindow = true),
|
|
|
- (selectingFor = 'mobile'),
|
|
|
- (upType = 'video'),
|
|
|
- (upTypeSta = 'videoBac')
|
|
|
- "
|
|
|
- >
|
|
|
+ <button class="ui-button submit" @click="(isShowSelectionWindow = true), (selectingFor = 'mobile'), (upType = 'video'), (upTypeSta = 'videoBac')">
|
|
|
{{ $i18n.t(`edit_settings.select_video`) }}
|
|
|
</button>
|
|
|
<!-- 上传提示 -->
|
|
|
- <div
|
|
|
- class="ui-remark"
|
|
|
- v-html="$i18n.t(`edit_settings.coverUpTit5`)"
|
|
|
- ></div>
|
|
|
+ <div class="ui-remark" v-html="$i18n.t(`edit_settings.coverUpTit5`)"></div>
|
|
|
<!-- 选择居中和全屏 -->
|
|
|
<div class="coverImglocBox">
|
|
|
- <div
|
|
|
- :class="{ active: info.coverInfo.videoMoLoc === 'center' }"
|
|
|
- @click="info.coverInfo.videoMoLoc = 'center'"
|
|
|
- >
|
|
|
+ <div :class="{ active: info.workCoverType.videoMoLoc === 'center' }" @click="info.workCoverType.videoMoLoc = 'center'">
|
|
|
<div class="inco"></div>
|
|
|
<div class="txt">{{ coverImgLoc1 }}</div>
|
|
|
</div>
|
|
|
- <div
|
|
|
- :class="{ active: info.coverInfo.videoMoLoc === 'full' }"
|
|
|
- @click="info.coverInfo.videoMoLoc = 'full'"
|
|
|
- >
|
|
|
+ <div :class="{ active: info.workCoverType.videoMoLoc === 'full' }" @click="info.workCoverType.videoMoLoc = 'full'">
|
|
|
<div class="inco inco2"></div>
|
|
|
<div class="txt">{{ coverImgLoc2 }}</div>
|
|
|
</div>
|
|
@@ -385,59 +242,24 @@ pc端视频位置 videoPcLoc
|
|
|
<!-- 视频背景设置 -->
|
|
|
<div class="coverImgBacBox">
|
|
|
<div class="tit">{{ $i18n.t(`edit_settings.coverImgBacTit`) }}</div>
|
|
|
- <Select v-model="info.coverInfo.coverVideoBac" class="base-select">
|
|
|
- <Option
|
|
|
- v-for="item in coverImgBacList"
|
|
|
- :key="item.type"
|
|
|
- :label="item.txt"
|
|
|
- :value="item.type"
|
|
|
- >
|
|
|
- </Option>
|
|
|
+ <Select v-model="info.workCoverType.coverVideoBac" class="base-select">
|
|
|
+ <Option v-for="item in coverImgBacList" :key="item.type" :label="item.txt" :value="item.type"> </Option>
|
|
|
</Select>
|
|
|
<!-- 选择颜色 -->
|
|
|
- <div
|
|
|
- class="imgColorSelec"
|
|
|
- v-show="info.coverInfo.coverVideoBac === 'colorFill'"
|
|
|
- >
|
|
|
- <div class="ll">{{ info.coverInfo.videoColorSelec }}</div>
|
|
|
- <div
|
|
|
- class="rr"
|
|
|
- :style="`background-color: ${info.coverInfo.videoColorSelec};`"
|
|
|
- ></div>
|
|
|
- <ColorPicker
|
|
|
- @change="videoColorSelecChange"
|
|
|
- v-model="info.coverInfo.videoColorSelec"
|
|
|
- :predefine="predefineColors"
|
|
|
- >
|
|
|
- </ColorPicker>
|
|
|
+ <div class="imgColorSelec" v-show="info.workCoverType.coverVideoBac === 'colorFill'">
|
|
|
+ <div class="ll">{{ info.workCoverType.videoColorSelec }}</div>
|
|
|
+ <div class="rr" :style="`background-color: ${info.workCoverType.videoColorSelec};`"></div>
|
|
|
+ <ColorPicker @change="videoColorSelecChange" v-model="info.workCoverType.videoColorSelec" :predefine="predefineColors"> </ColorPicker>
|
|
|
</div>
|
|
|
<!-- 选择背景图片 -->
|
|
|
- <div
|
|
|
- class="imgClolrBacImg"
|
|
|
- v-show="info.coverInfo.coverVideoBac === 'imgTile'"
|
|
|
- >
|
|
|
- <SelectedImage
|
|
|
- :imgSrc="info.coverInfo.videoBacImg"
|
|
|
- :defaultImgSrc="require('@/assets/img/coverUpTit1.png')"
|
|
|
- @cancel="onCancelBac2"
|
|
|
- ></SelectedImage>
|
|
|
+ <div class="imgClolrBacImg" v-show="info.workCoverType.coverVideoBac === 'imgTile'">
|
|
|
+ <SelectedImage :imgSrc="info.workCoverType.videoBacImg" :defaultImgSrc="require('@/assets/img/coverUpTit1.png')" @cancel="onCancelBac2"></SelectedImage>
|
|
|
<!-- 上传图片按钮 -->
|
|
|
<div class="imgRight">
|
|
|
- <button
|
|
|
- class="ui-button submit"
|
|
|
- @click="
|
|
|
- (isShowSelectionWindow = true),
|
|
|
- (selectingFor = 'bac'),
|
|
|
- (upType = 'image'),
|
|
|
- (upTypeSta = 'videoBac')
|
|
|
- "
|
|
|
- >
|
|
|
+ <button class="ui-button submit" @click="(isShowSelectionWindow = true), (selectingFor = 'bac'), (upType = 'image'), (upTypeSta = 'videoBac')">
|
|
|
{{ $i18n.t(`edit_settings.select_image`) }}
|
|
|
</button>
|
|
|
- <div
|
|
|
- class="ui-remark"
|
|
|
- v-html="$i18n.t(`edit_settings.coverUpTit3`)"
|
|
|
- ></div>
|
|
|
+ <div class="ui-remark" v-html="$i18n.t(`edit_settings.coverUpTit3`)"></div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -451,10 +273,7 @@ pc端视频位置 videoPcLoc
|
|
|
{{ $i18n.t(`edit_settings.coverVideoInWayTit`) }}
|
|
|
</div>
|
|
|
<div class="VideoTitR">
|
|
|
- <Switcher
|
|
|
- :value="info.coverInfo.coverVideoInWay"
|
|
|
- @change="coverVideoInWayChange"
|
|
|
- ></Switcher>
|
|
|
+ <Switcher :value="info.workCoverType.coverVideoInWay" @change="coverVideoInWayChange"></Switcher>
|
|
|
</div>
|
|
|
</div>
|
|
|
<!-- 视频控件 -->
|
|
@@ -466,33 +285,16 @@ pc端视频位置 videoPcLoc
|
|
|
{{ $i18n.t(`edit_settings.coverVideoControlTit`) }}
|
|
|
</div>
|
|
|
<div class="VideoTitR">
|
|
|
- <Switcher
|
|
|
- :value="info.coverInfo.coverVideoControl"
|
|
|
- @change="coverVideoControlChange"
|
|
|
- ></Switcher>
|
|
|
+ <Switcher :value="info.workCoverType.coverVideoControl" @change="coverVideoControlChange"></Switcher>
|
|
|
</div>
|
|
|
</div>
|
|
|
<!-- 出现顺序 -->
|
|
|
|
|
|
- <div
|
|
|
- class="coverImgTit"
|
|
|
- v-show="info.coverInfo.coverSelect === 'videoAndImg'"
|
|
|
- >
|
|
|
+ <div class="coverImgTit" v-show="info.workCoverType.coverSelect === 'videoAndImg'">
|
|
|
{{ $i18n.t(`edit_settings.coverImageOrder`) }}
|
|
|
</div>
|
|
|
- <Select
|
|
|
- placement="bottom"
|
|
|
- class="base-select"
|
|
|
- v-model="info.coverInfo.coverImageOrder"
|
|
|
- v-show="info.coverInfo.coverSelect === 'videoAndImg'"
|
|
|
- >
|
|
|
- <Option
|
|
|
- v-for="item in coverImageOrderList"
|
|
|
- :key="item.type"
|
|
|
- :label="item.txt"
|
|
|
- :value="item.type"
|
|
|
- >
|
|
|
- </Option>
|
|
|
+ <Select placement="bottom" class="base-select" v-model="info.workCoverType.coverImageOrder" v-show="info.workCoverType.coverSelect === 'videoAndImg'">
|
|
|
+ <Option v-for="item in coverImageOrderList" :key="item.type" :label="item.txt" :value="item.type"> </Option>
|
|
|
</Select>
|
|
|
</div>
|
|
|
<br />
|
|
@@ -552,7 +354,7 @@ export default {
|
|
|
},
|
|
|
],
|
|
|
|
|
|
- coverInfo: {
|
|
|
+ workCoverType: {
|
|
|
// 封面类型下拉框数据
|
|
|
coverSelect: "img",
|
|
|
// 图片pc端位置
|
|
@@ -599,16 +401,7 @@ export default {
|
|
|
{ txt: i18n.t("edit_settings.coverImgBacSelec2"), type: "imgTile" },
|
|
|
],
|
|
|
|
|
|
- predefineColors: [
|
|
|
- "#000000",
|
|
|
- "#ff4500",
|
|
|
- "#ff8c00",
|
|
|
- "#ffd700",
|
|
|
- "#90ee90",
|
|
|
- "#00ced1",
|
|
|
- "#1e90ff",
|
|
|
- "#c71585",
|
|
|
- ],
|
|
|
+ predefineColors: ["#000000", "#ff4500", "#ff8c00", "#ffd700", "#90ee90", "#00ced1", "#1e90ff", "#c71585"],
|
|
|
|
|
|
isShowSelectionWindow: false,
|
|
|
selectingFor: "", // 'pc', 'mobile'
|
|
@@ -621,24 +414,19 @@ export default {
|
|
|
},
|
|
|
computed: {
|
|
|
...mapGetters({
|
|
|
- info: "info",
|
|
|
+ // info: "info",
|
|
|
+ oldInfo: "info",
|
|
|
+ info: "base/baseInfo",
|
|
|
}),
|
|
|
},
|
|
|
watch: {
|
|
|
- "info.coverInfo": {
|
|
|
+ "info.workCoverType": {
|
|
|
handler(val) {
|
|
|
if (val) {
|
|
|
- const folderIds = [
|
|
|
- val.coverPcId,
|
|
|
- val.coverMoId,
|
|
|
- val.videoPcId,
|
|
|
- val.videoMoId,
|
|
|
- val.coverImgBacId,
|
|
|
- val.videoBacImgId,
|
|
|
- ].filter((i) => i);
|
|
|
+ const folderIds = [val.coverPcId, val.coverMoId, val.videoPcId, val.videoMoId, val.coverImgBacId, val.videoBacImgId].filter((i) => i);
|
|
|
// console.log("folderIds", folderIds);
|
|
|
this.folderIds = folderIds;
|
|
|
- // this.info.coverInfo.fodderId = folderIds;
|
|
|
+ // this.info.workCoverType.fodderId = folderIds;
|
|
|
}
|
|
|
},
|
|
|
immediate: true,
|
|
@@ -648,55 +436,55 @@ export default {
|
|
|
methods: {
|
|
|
//是否显示
|
|
|
onSwitcherChange(data) {
|
|
|
- this.info.coverInfo.isShowCover = data;
|
|
|
+ this.info.workCoverType.isShowCover = data;
|
|
|
},
|
|
|
|
|
|
// 视频的进入方式
|
|
|
coverVideoInWayChange(val) {
|
|
|
- this.info.coverInfo.coverVideoInWay = val;
|
|
|
+ this.info.workCoverType.coverVideoInWay = val;
|
|
|
},
|
|
|
// 图片的进入方式
|
|
|
coverImageInWayChange(val) {
|
|
|
console.log(val, "coverImageInWayChange");
|
|
|
- this.info.coverInfo.coverImageInWay = val;
|
|
|
+ this.info.workCoverType.coverImageInWay = val;
|
|
|
},
|
|
|
coverVideoControlChange(val) {
|
|
|
- this.info.coverInfo.coverVideoControl = val;
|
|
|
+ this.info.workCoverType.coverVideoControl = val;
|
|
|
},
|
|
|
// 图片的颜色选择器改变事件
|
|
|
imgColorSelecChange(val) {
|
|
|
- this.info.coverInfo.imgColorSelec = val;
|
|
|
+ this.info.workCoverType.imgColorSelec = val;
|
|
|
},
|
|
|
videoColorSelecChange(val) {
|
|
|
- this.info.coverInfo.videoColorSelec = val;
|
|
|
+ this.info.workCoverType.videoColorSelec = val;
|
|
|
},
|
|
|
handleSubmitFromMaterialSelector(selected) {
|
|
|
// 点击确定的时候是选择的图片上传
|
|
|
if (this.upTypeSta === "imgBac") {
|
|
|
if (this.selectingFor === "pc") {
|
|
|
- this.info.coverInfo.coverPc = selected[0].icon;
|
|
|
- this.info.coverInfo.coverPcId = selected[0].id;
|
|
|
+ this.info.workCoverType.coverPc = selected[0].icon;
|
|
|
+ this.info.workCoverType.coverPcId = selected[0].id;
|
|
|
} else if (this.selectingFor === "mobile") {
|
|
|
- this.info.coverInfo.coverMo = selected[0].icon;
|
|
|
- this.info.coverInfo.coverMoId = selected[0].id;
|
|
|
+ this.info.workCoverType.coverMo = selected[0].icon;
|
|
|
+ this.info.workCoverType.coverMoId = selected[0].id;
|
|
|
} else {
|
|
|
- this.info.coverInfo.coverBac = selected[0].icon;
|
|
|
- this.info.coverInfo.coverBacId = selected[0].id;
|
|
|
+ this.info.workCoverType.coverBac = selected[0].icon;
|
|
|
+ this.info.workCoverType.coverBacId = selected[0].id;
|
|
|
}
|
|
|
} else {
|
|
|
// 视频上传
|
|
|
if (this.selectingFor === "pc") {
|
|
|
console.log(selected[0], "selected[0]");
|
|
|
- this.info.coverInfo.videoPc = selected[0].ossPath;
|
|
|
- this.info.coverInfo.videoPcIcon = selected[0].icon;
|
|
|
- this.info.coverInfo.videoPcId = selected[0].id;
|
|
|
+ this.info.workCoverType.videoPc = selected[0].ossPath;
|
|
|
+ this.info.workCoverType.videoPcIcon = selected[0].icon;
|
|
|
+ this.info.workCoverType.videoPcId = selected[0].id;
|
|
|
} else if (this.selectingFor === "mobile") {
|
|
|
- this.info.coverInfo.videoMo = selected[0].ossPath;
|
|
|
- this.info.coverInfo.videoMoId = selected[0].id;
|
|
|
- this.info.coverInfo.videoMoIcon = selected[0].icon;
|
|
|
+ this.info.workCoverType.videoMo = selected[0].ossPath;
|
|
|
+ this.info.workCoverType.videoMoId = selected[0].id;
|
|
|
+ this.info.workCoverType.videoMoIcon = selected[0].icon;
|
|
|
} else {
|
|
|
- this.info.coverInfo.videoBacImg = selected[0].icon;
|
|
|
- this.info.coverInfo.videoBacImgId = selected[0].id;
|
|
|
+ this.info.workCoverType.videoBacImg = selected[0].icon;
|
|
|
+ this.info.workCoverType.videoBacImgId = selected[0].id;
|
|
|
}
|
|
|
}
|
|
|
this.isShowSelectionWindow = false;
|
|
@@ -705,72 +493,77 @@ export default {
|
|
|
},
|
|
|
onCancelPcTip() {
|
|
|
this.$nextTick(() => {
|
|
|
- this.info.coverInfo.coverPc = "";
|
|
|
- this.info.coverInfo.coverPcId = null;
|
|
|
+ this.info.workCoverType.coverPc = "";
|
|
|
+ this.info.workCoverType.coverPcId = null;
|
|
|
this.updateFolderIds();
|
|
|
- console.log("onCancelPcTip-1", this.info.coverInfo);
|
|
|
+ console.log("onCancelPcTip-1", this.info.workCoverType);
|
|
|
});
|
|
|
},
|
|
|
onCancelAppTip() {
|
|
|
this.$nextTick(() => {
|
|
|
- this.info.coverInfo.coverMo = "";
|
|
|
- this.info.coverInfo.coverMoId = null;
|
|
|
+ this.info.workCoverType.coverMo = "";
|
|
|
+ this.info.workCoverType.coverMoId = null;
|
|
|
this.updateFolderIds();
|
|
|
});
|
|
|
},
|
|
|
onCancelBac() {
|
|
|
this.$nextTick(() => {
|
|
|
- this.info.coverInfo.coverBac = "";
|
|
|
- this.info.coverInfo.coverBacId = null;
|
|
|
+ this.info.workCoverType.coverBac = "";
|
|
|
+ this.info.workCoverType.coverBacId = null;
|
|
|
this.updateFolderIds();
|
|
|
});
|
|
|
},
|
|
|
// 关于视频
|
|
|
clearVideoPc() {
|
|
|
- this.info.coverInfo.videoPc = "";
|
|
|
- this.info.coverInfo.videoPcId = null;
|
|
|
- this.info.coverInfo.videoPcIcon = "";
|
|
|
+ this.info.workCoverType.videoPc = "";
|
|
|
+ this.info.workCoverType.videoPcId = null;
|
|
|
+ this.info.workCoverType.videoPcIcon = "";
|
|
|
this.updateFolderIds();
|
|
|
},
|
|
|
clearVideoMo() {
|
|
|
- this.info.coverInfo.videoMo = "";
|
|
|
- this.info.coverInfo.videoMoId = null;
|
|
|
- this.info.coverInfo.videoMoIcon = "";
|
|
|
+ this.info.workCoverType.videoMo = "";
|
|
|
+ this.info.workCoverType.videoMoId = null;
|
|
|
+ this.info.workCoverType.videoMoIcon = "";
|
|
|
this.updateFolderIds();
|
|
|
},
|
|
|
onCancelBac2() {
|
|
|
- this.info.coverInfo.videoBacImg = "";
|
|
|
- this.info.coverInfo.videoBacImgId = null;
|
|
|
+ this.info.workCoverType.videoBacImg = "";
|
|
|
+ this.info.workCoverType.videoBacImgId = null;
|
|
|
this.updateFolderIds();
|
|
|
},
|
|
|
updateFolderIds() {
|
|
|
//fodderId 以前的字段有误在先
|
|
|
setTimeout(() => {
|
|
|
console.log("updateFolderIds:", this.folderIds);
|
|
|
- this.info.coverInfo.fodderId = this.folderIds;
|
|
|
+ this.info.workCoverType.fodderId = this.folderIds;
|
|
|
}, 300);
|
|
|
},
|
|
|
},
|
|
|
created() {
|
|
|
- if (!this.info.coverInfo) {
|
|
|
- this.$store.commit("SetInfo", {
|
|
|
- coverInfo: { ...this.coverInfo },
|
|
|
- ...this.info,
|
|
|
+ if (!this.info.workCoverType) {
|
|
|
+
|
|
|
+
|
|
|
+ // this.$store.commit("SetInfo", {
|
|
|
+ // workCoverType: { ...this.workCoverType },
|
|
|
+ // ...this.info,
|
|
|
+ // });
|
|
|
+ this.$store.commit("base/setData", {
|
|
|
+ workCoverType: this.workCoverType,
|
|
|
});
|
|
|
} else {
|
|
|
- Object.keys(this.coverInfo).forEach((i) => {
|
|
|
- if (!(i in this.info.coverInfo)) {
|
|
|
- this.info.coverInfo[i] = this.coverInfo[i];
|
|
|
+ Object.keys(this.workCoverType).forEach((i) => {
|
|
|
+ if (!(i in this.info.workCoverType)) {
|
|
|
+ this.info.workCoverType[i] = this.workCoverType[i];
|
|
|
}
|
|
|
});
|
|
|
-
|
|
|
this.$store.commit("SetInfo", {
|
|
|
- ...this.info,
|
|
|
+ // ...this.info,
|
|
|
+ ...this.oldInfo,
|
|
|
});
|
|
|
}
|
|
|
},
|
|
|
mounted() {
|
|
|
- // console.log("this.info.coverInfo", this.info.coverInfo);
|
|
|
+ // console.log("this.info.workCoverType", this.info.workCoverType);
|
|
|
},
|
|
|
beforeCreate() {}, //生命周期 - 创建之前
|
|
|
beforeMount() {}, //生命周期 - 挂载之前
|