海报
This commit is contained in:
parent
f16e8b3fa5
commit
3996295ac9
@ -63,4 +63,4 @@ export function delPoser(id) {
|
||||
url: '/system/poser/' + id,
|
||||
method: 'delete'
|
||||
})
|
||||
}
|
||||
}
|
||||
@ -183,7 +183,13 @@
|
||||
@pagination="getList"
|
||||
/>
|
||||
<!-- 添加或修改泉医到家系统海报模块信息(包含咨询简介信息)对话框 -->
|
||||
<el-dialog :title="title" :visible.sync="open" width="800px" append-to-body>
|
||||
<el-dialog
|
||||
:title="title"
|
||||
:visible.sync="open"
|
||||
width="800px"
|
||||
:before-close="cancel"
|
||||
append-to-body
|
||||
>
|
||||
<el-form
|
||||
ref="form"
|
||||
:model="form"
|
||||
@ -209,7 +215,14 @@
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="所属护理站" prop="nurseStationId">
|
||||
<el-form-item
|
||||
label="所属护理站"
|
||||
prop="nurseStationId"
|
||||
v-if="
|
||||
form.moduleType == 'NURSE_AGENCY_MODULE' ||
|
||||
form.moduleType == 'NURSE_ITEM_MODULE'
|
||||
"
|
||||
>
|
||||
<template>
|
||||
<el-button
|
||||
type=""
|
||||
@ -242,7 +255,11 @@
|
||||
>
|
||||
</template>
|
||||
</el-form-item>
|
||||
<el-form-item label="所属护理项目" prop="nurseItemId">
|
||||
<el-form-item
|
||||
label="所属护理项目"
|
||||
prop="nurseItemId"
|
||||
v-if="form.moduleType == 'NURSE_ITEM_MODULE'"
|
||||
>
|
||||
<template>
|
||||
<el-button
|
||||
type=""
|
||||
@ -279,7 +296,7 @@
|
||||
<el-table
|
||||
label-width="50px"
|
||||
style="margin-top: 20px"
|
||||
:data="form.PosterPictureUrlList"
|
||||
:data="form.posterPictureUrlLists"
|
||||
>
|
||||
<el-table-column label="图片" align="center" width="300">
|
||||
<template slot-scope="scope">
|
||||
@ -299,7 +316,7 @@
|
||||
style="width: 208px"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in options"
|
||||
v-for="item in jumpTypes"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
@ -335,8 +352,9 @@
|
||||
<stationAcatar
|
||||
style="width: 208px"
|
||||
@imgUrl="imgUrl2"
|
||||
:img="form.posterVideoUrl"
|
||||
:tovideo="form.posterVideoUrl"
|
||||
:type="'posterVideoUrl'"
|
||||
v-if="open"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="海报显示顺序" prop="poserSort">
|
||||
@ -678,6 +696,20 @@ export default {
|
||||
label: "首页模块",
|
||||
},
|
||||
],
|
||||
jumpTypes: [
|
||||
{
|
||||
value: "NEW_PEOPLE_WELFARE",
|
||||
label: "新人福利",
|
||||
},
|
||||
{
|
||||
value: "HOME_PAGE",
|
||||
label: "首页",
|
||||
},
|
||||
{
|
||||
value: "SHOPPING",
|
||||
label: "商城",
|
||||
},
|
||||
],
|
||||
//页面链接
|
||||
stationid: "",
|
||||
nurseitemid: "",
|
||||
@ -744,18 +776,18 @@ export default {
|
||||
//删除海报图片列表
|
||||
delPictureUrl(item) {
|
||||
if (item.idd && !item.id) {
|
||||
if (this.form.PosterPictureUrlList.length == 1) {
|
||||
if (this.form.posterPictureUrlLists.length == 1) {
|
||||
this.$message.error("最后一条不可删除");
|
||||
} else {
|
||||
this.form.PosterPictureUrlList =
|
||||
this.form.PosterPictureUrlList.filter((e) => e.idd != item.idd);
|
||||
this.form.posterPictureUrlLists =
|
||||
this.form.posterPictureUrlLists.filter((e) => e.idd != item.idd);
|
||||
}
|
||||
} else if (!item.idd && item.id) {
|
||||
if (this.form.PosterPictureUrlList.length == 1) {
|
||||
if (this.form.posterPictureUrlLists.length == 1) {
|
||||
this.$message.error("最后一条不可删除");
|
||||
} else {
|
||||
this.form.PosterPictureUrlList =
|
||||
this.form.PosterPictureUrlList.filter((e) => e.id != item.id);
|
||||
this.form.posterPictureUrlLists =
|
||||
this.form.posterPictureUrlLists.filter((e) => e.id != item.id);
|
||||
}
|
||||
}
|
||||
},
|
||||
@ -767,7 +799,7 @@ export default {
|
||||
jumpType: "",
|
||||
idd: this.idd,
|
||||
};
|
||||
this.form.PosterPictureUrlList.push(obj);
|
||||
this.form.posterPictureUrlLists.push(obj);
|
||||
},
|
||||
//打开遮罩层
|
||||
clicknurseItemshow() {
|
||||
@ -879,6 +911,7 @@ export default {
|
||||
},
|
||||
imgUrl2(imgUrl) {
|
||||
this.videoForm.showVideoPath = baseurl + imgUrl;
|
||||
this.form.posterVideoUrl = imgUrl;
|
||||
},
|
||||
/** 查询泉医到家系统海报模块信息(包含咨询简介信息)列表 */
|
||||
getList() {
|
||||
@ -905,7 +938,7 @@ export default {
|
||||
// 表单重置
|
||||
reset() {
|
||||
this.form = {
|
||||
PosterPictureUrlList: [
|
||||
posterPictureUrlLists: [
|
||||
{
|
||||
posterPictureUrl: "",
|
||||
jumpType: "",
|
||||
@ -913,21 +946,11 @@ export default {
|
||||
},
|
||||
],
|
||||
id: null,
|
||||
nurseStationId: null,
|
||||
nurseItemId: null,
|
||||
poserName: null,
|
||||
poserCode: null,
|
||||
posterIntroduce: null,
|
||||
posterPictureUrl: null,
|
||||
posterVideoUrl: null,
|
||||
moduleType: null,
|
||||
posterVideoUrl2: null,
|
||||
poserSort: null,
|
||||
jumpLink: null,
|
||||
jumpType: null,
|
||||
createBy: null,
|
||||
createTime: null,
|
||||
updateBy: null,
|
||||
updateTime: null,
|
||||
nurseStationName: "请选择所属护理站",
|
||||
nurseStationId: null,
|
||||
nurseItemName: "请选择所属护理项目",
|
||||
|
||||
@ -20,7 +20,6 @@
|
||||
title="点击上传图片"
|
||||
style="width: 100px; height: 100px; line-height: 200px"
|
||||
/>
|
||||
|
||||
<i
|
||||
v-else
|
||||
class="el-icon-plus avatar-uploader-icon"
|
||||
@ -59,7 +58,7 @@
|
||||
<div class="avatar-upload-preview">
|
||||
<video
|
||||
style="width: 100%; height: 100%"
|
||||
v-if="videoForm.showVideoPath != ''"
|
||||
v-if="videoForm.showVideoPath"
|
||||
v-bind:src="videoForm.showVideoPath"
|
||||
class="avatar video-avatar"
|
||||
controls="controls"
|
||||
@ -143,7 +142,7 @@ import {
|
||||
export default {
|
||||
components: { VueCropper },
|
||||
|
||||
props: ["img", "type", "item"],
|
||||
props: ["img", "type", "item", "tovideo"],
|
||||
data() {
|
||||
return {
|
||||
imageUrl: "",
|
||||
@ -165,7 +164,7 @@ export default {
|
||||
items: {},
|
||||
//显示上传按钮
|
||||
videoForm: {
|
||||
showVideoPath: "", //回显的变量
|
||||
showVideoPath: null, //回显的变量
|
||||
},
|
||||
video: {
|
||||
VideoPath: null, //回显的变量
|
||||
@ -175,6 +174,8 @@ export default {
|
||||
created() {
|
||||
this.types = this.type;
|
||||
this.items = this.item;
|
||||
this.video.VideoPath = baseurl + this.tovideo;
|
||||
console.log(this.video)
|
||||
if (this.img == null) {
|
||||
this.options.img = null;
|
||||
} else if (this.img == "") {
|
||||
@ -189,6 +190,9 @@ export default {
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
tovideo: {
|
||||
handler(newimg, oldimg) {},
|
||||
},
|
||||
item: {
|
||||
handler(newimg, oldimg) {
|
||||
this.items = this.item;
|
||||
@ -291,7 +295,7 @@ export default {
|
||||
this.$emit("item", JSON.stringify(this.items));
|
||||
}
|
||||
if (this.types == "posterPictureUrl") {
|
||||
this.items.classifyPictureUrl = response.imgUrl;
|
||||
this.items.posterPictureUrl = response.imgUrl;
|
||||
this.$emit("item", JSON.stringify(this.items));
|
||||
}
|
||||
this.openimg = false;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user