Commit cffd11bf authored by zhengke's avatar zhengke

修改

parent 668a9bc6
......@@ -240,6 +240,8 @@
<searchsdialog v-if="currentEditItem.Id=='search_s'" :plugData="currentEditItemData"></searchsdialog>
<!-- 搜寻区块 其他 -->
<searcheldialog v-if="currentEditItem.Id=='search_el'" :plugData="currentEditItemData"></searcheldialog>
<!-- 自定版型 其他 -->
<otherdialog v-if="currentEditItem.Id=='white_label_other'" :plugData="currentEditItemData"></otherdialog>
<span slot="footer" class="dialog-footer">
<el-button @click="isShowDialog = false" size="small">取 消</el-button>
<el-button type="danger" size="small" @click="setSubPlugData()">确 定</el-button>
......@@ -264,6 +266,7 @@
import searchfdialog from "../WebSet/plug-in/searchf_dialog.vue"
import searchsdialog from "../WebSet/plug-in/searchs_dialog.vue"
import searcheldialog from "../WebSet/plug-in/searchel_dialog"
import otherdialog from "../WebSet/plug-in/other_dialog"
export default {
props: ["templateData"],
data() {
......@@ -301,7 +304,8 @@
bannerdialog,
searchfdialog,
searchsdialog,
searcheldialog
searcheldialog,
otherdialog
},
methods: {
//显示弹窗
......
<style>
.otherDialog .table-striped{
width:100%;
border-spacing: 0;
border-collapse: collapse;
}
.otherDialog .table-striped th,.otherDialog .table-striped td{
padding:8px;
text-align: center;
}
.otherDialog .table-striped>tr:nth-of-type(odd) {
background-color: #f9f9f9;
}
</style>
<template>
<div class="otherDialog">
<el-form label-width="80px">
<template v-if="plugData.Type==1">
<el-row>
<el-col :span="24">
<el-form-item>
此版型只會在前台增加一行高度40px的空白,可利用此版型調整畫面美觀唷。
</el-form-item>
</el-col>
</el-row>
</template>
<template v-if="plugData.Type==2">
<el-form-item label="主標題">
<el-input type="text" v-model="plugData.Title"></el-input>
</el-form-item>
<el-form-item>
<span style="color:#8a6d3b">未填標題或未傳檔案則不會顯示於前台,檔案類型限制:jpg、png、pdf,大小上限 8MB。</span>
</el-form-item>
<table class="table-striped">
<tr>
<th style="width:7%">項次</th>
<th style="width:47%">標題</th>
<th style="width:28%">上傳檔案</th>
<th style="width:18%">檢視檔案</th>
</tr>
<tr v-for="(item,index) in plugData.DownLoadList" :key="index">
<td>{{index+1}}</td>
<td>
<el-input type="text" v-model="item.LinkTitle"></el-input>
</td>
<td>
<el-upload :http-request="UploadImage" :show-file-list="false" :multiple="true" accept="" action=''>
<el-button size="small" type="primary" @click="checkIndex=index">点击上传</el-button>
</el-upload>
</td>
<td>
<a v-if="item.LinkUrl!=''" style="color:blue" target="_blank" :href="item.LinkUrl">预览</a>
</td>
</tr>
</table>
</template>
</el-form>
</div>
</template>
<script>
export default {
props: ["plugData"],
data() {
return {
checkIndex: 0
};
},
created() {},
methods: {
UploadImage(file) {
console.log(this.checkIndex,'index');
let newArr = [];
newArr.push(file.file);
let fileName = file.file.name;
var path = "/Upload/WebSite/";
this.UploadSelfFileT(path, newArr, x => {
var str = x.data.FilePath;
var imgUrl = this.domainManager().ViittoFileUrl + str;
this.plugData.DownLoadList[this.checkIndex].LinkUrl=imgUrl;
});
}
},
mounted() {
},
};
</script>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment