Commit 43ab49ae authored by qzhxx's avatar qzhxx

测优化

parent bbd8c2ff
<template> <template>
<div> <div>
<el-upload <el-upload
accept=".jpg,.jpeg,.png,.gif,.bmp,.pdf,.JPG,.JPEG,.PBG,.GIF,.BMP,.PDF"
:class="{disabled:uploadDisabled}"
action="http://111.203.232.175:8088/mall/file/image/upload" action="http://111.203.232.175:8088/mall/file/image/upload"
list-type="picture-card" list-type="picture-card"
:on-preview="handlePictureCardPreview" :on-preview="handlePictureCardPreview"
...@@ -12,6 +14,7 @@ ...@@ -12,6 +14,7 @@
:multiple ="false" :multiple ="false"
> >
<i class="el-icon-plus"></i> <i class="el-icon-plus"></i>
<div slot="tip" class="el-upload__tip color_red">只能上传.jpg/.jpeg/.png/.gif/.bmp/.pdf文件</div>
</el-upload> </el-upload>
<el-dialog :visible.sync="dialogVisible"> <el-dialog :visible.sync="dialogVisible">
<img width="100%" :src="dialogImageUrl" alt /> <img width="100%" :src="dialogImageUrl" alt />
...@@ -31,6 +34,7 @@ export default { ...@@ -31,6 +34,7 @@ export default {
return { return {
dialogImageUrl: "", dialogImageUrl: "",
dialogVisible: false, dialogVisible: false,
imageUrl:""
}; };
}, },
computed: { computed: {
...@@ -39,6 +43,9 @@ export default { ...@@ -39,6 +43,9 @@ export default {
Authorization: localStorage.getItem("backToken") || "", Authorization: localStorage.getItem("backToken") || "",
}; };
}, },
uploadDisabled:function() {
return this.imageUrl !== ''
},
}, },
methods: { methods: {
// 图片上传成功的返回值 // 图片上传成功的返回值
...@@ -52,6 +59,7 @@ export default { ...@@ -52,6 +59,7 @@ export default {
}, },
handleRemove(file, fileList) { handleRemove(file, fileList) {
this.$emit("imgUrl", ""); this.$emit("imgUrl", "");
this.imageUrl=""
}, },
handlePictureCardPreview(file) { handlePictureCardPreview(file) {
this.dialogImageUrl = file.url; this.dialogImageUrl = file.url;
...@@ -68,9 +76,17 @@ export default { ...@@ -68,9 +76,17 @@ export default {
}; };
</script> </script>
<style> <style lang="less">
.avatar { .avatar {
width: 100%; width: 100%;
height: 100%; height: 100%;
} }
.color_red{
color:red;
}
.disabled .el-upload--picture-card {
display: none;
}
</style> </style>
<template> <template>
<div> <div>
<el-upload <el-upload
accept=".jpg,.jpeg,.png,.JPG,.JPEG,.PBG"
:class="{disabled:uploadDisabled}"
action="http://111.203.232.175:8088/mall/file/image/upload" action="http://111.203.232.175:8088/mall/file/image/upload"
list-type="picture-card" list-type="picture-card"
:on-preview="handlePictureCardPreview" :on-preview="handlePictureCardPreview"
...@@ -12,6 +14,7 @@ ...@@ -12,6 +14,7 @@
:multiple ="false" :multiple ="false"
> >
<i class="el-icon-plus"></i> <i class="el-icon-plus"></i>
<div slot="tip" class="el-upload__tip color_red">只能上传.jpg/.jpeg/.png文件</div>
</el-upload> </el-upload>
<el-dialog :visible.sync="dialogVisible"> <el-dialog :visible.sync="dialogVisible">
<img width="100%" :src="dialogImageUrl" alt /> <img width="100%" :src="dialogImageUrl" alt />
...@@ -35,26 +38,38 @@ export default { ...@@ -35,26 +38,38 @@ export default {
data() { data() {
return { return {
dialogImageUrl: "", dialogImageUrl: "",
dialogVisible: false dialogVisible: false,
imageUrl:""
}; };
}, },
computed: { computed: {
headers() { headers() {
// return { 'token': this.backToken } // return { 'token': this.backToken }
return {'Authorization':localStorage.getItem('backToken')} return {'Authorization':localStorage.getItem('backToken')}
} },
uploadDisabled:function() {
return this.imageUrl !== ''
},
}, },
methods: { methods: {
// 图片上传成功的返回值 // 图片上传成功的返回值
handleAvatarSuccess(res, file) { handleAvatarSuccess(res, file) {
console.log(res)
// console.log(res.url) // this.$emit('qrcodeUrl', res.data.url)
console.log(res.data.url)
this.$emit('qrcodeUrl', res.data.url) if (res.resultCode == 200) {
// this.imageUrl = URL.createObjectURL(file.raw); this.$emit('qrcodeUrl', res.data.url)
this.imageUrl = res.data.url;
} else {
this.$message.error(res.message);
}
}, },
handleRemove(file, fileList) { handleRemove(file, fileList) {
console.log(file, fileList); console.log(file, fileList);
this.$emit("qrcodeUrl", "");
this.imageUrl=""
}, },
handlePictureCardPreview(file) { handlePictureCardPreview(file) {
this.dialogImageUrl = file.url; this.dialogImageUrl = file.url;
...@@ -65,4 +80,11 @@ export default { ...@@ -65,4 +80,11 @@ export default {
</script> </script>
<style> <style>
.color_red{
color:red;
}
.disabled .el-upload--picture-card {
display: none;
}
</style> </style>
...@@ -93,7 +93,7 @@ ...@@ -93,7 +93,7 @@
</div> </div>
<!--新增弹框--> <!--新增弹框-->
<el-dialog <el-dialog
:title="type?'新建版权方':'编辑版权方'" :title="type?'新建展板分类':'编辑展板分类'"
custom-class="party-dialog" custom-class="party-dialog"
width="468px" width="468px"
:visible.sync="FormVisible" :visible.sync="FormVisible"
......
...@@ -120,11 +120,11 @@ ...@@ -120,11 +120,11 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item></el-form-item> <el-form-item></el-form-item>
<el-form-item label="导览音频" prop="audioIdList" required> <el-form-item label="导览音频" prop="audioIdList" >
<div style="color:red;">(可上传汉语、蒙语、藏语、维吾尔语、英语五种语言音频资料,命名方式为展板名称+语言)</div> <div style="color:red;">(可上传汉语、蒙语、藏语、维吾尔语、英语五种语言音频资料,命名方式为展板名称+语言)</div>
<upload-audio :fileList="ruleForm.audioList" @audioList="audioList"></upload-audio> <upload-audio :fileList="ruleForm.audioList" @audioList="audioList"></upload-audio>
</el-form-item> </el-form-item>
<el-form-item label="参考资料" prop="datumIdList" required> <el-form-item label="参考资料" prop="datumIdList" >
<div style="color:red;"> <div style="color:red;">
(可支持word、excel、PDF、ppt、视频类型文件及图片上传) (可支持word、excel、PDF、ppt、视频类型文件及图片上传)
</div> </div>
...@@ -225,6 +225,7 @@ export default { ...@@ -225,6 +225,7 @@ export default {
// this.getVideoData(); // this.getVideoData();
if (this.$route.query.type === "Update") { if (this.$route.query.type === "Update") {
this.getInfo(this.$route.query.id); this.getInfo(this.$route.query.id);
} }
}, },
// 更换展板版权方,展板分类清空 // 更换展板版权方,展板分类清空
...@@ -265,7 +266,10 @@ export default { ...@@ -265,7 +266,10 @@ export default {
imageList:[{url:data.cover}], imageList:[{url:data.cover}],
qrcodeList:[{url:data.qrcodeUrl}] qrcodeList:[{url:data.qrcodeUrl}]
} }
console.log(this.ruleForm) // console.log(this.ruleForm)
this.getVideoContentCatData();
this.getExhibitionBoardCatId();
this.getVideoData();
}).catch(function(err) { }).catch(function(err) {
console.log(err); console.log(err);
}); });
......
...@@ -50,7 +50,7 @@ ...@@ -50,7 +50,7 @@
</el-form> </el-form>
<div class="page-tip"> <div class="page-tip">
<span class="page-tip-title">页面说明:</span> <span class="page-tip-title">页面说明:</span>
<span class="page-tips">可通过展板名称、创建时间对展板信息进行快速检索。可对展板进行上架、下架、删除、修改及查看展板详情等操作。其中已上架的展板不能被删除。</span> <span class="page-tips">可通过展板名称、创建时间对展板信息进行快速检索。可对展板进行上架、下架、删除、修改及查看展板详情等操作。已上架展板需先下架才能删除。</span>
</div> </div>
</div> </div>
<div class="table-content"> <div class="table-content">
...@@ -302,14 +302,14 @@ export default { ...@@ -302,14 +302,14 @@ export default {
// des: `申请已提交,待审核…`, // des: `申请已提交,待审核…`,
// }; // };
if(res.data.resultCode === "200"){ if(res.data.resultCode === "200"){
if(_isPublish){ if(_isPublish){
this.$message({ type: "success", message: "上架申请已提交,待审核!" }); this.$message({ type: "success", message: "上架申请已提交,待审核!" });
}else{ }else{
this.$message({ type: "success", message: "下架申请已提交,待审核!" }); this.$message({ type: "success", message: "下架申请已提交,待审核!" });
} }
_this.onSearch();
_this.Search();
}else{ }else{
this.$message({ type: "error", message: res.data.message }); this.$message({ type: "error", message: res.data.message });
} }
......
...@@ -352,7 +352,7 @@ export default { ...@@ -352,7 +352,7 @@ export default {
url: "exhibitionBoardCat/getList", url: "exhibitionBoardCat/getList",
method: "post", method: "post",
authType: this.backToken authType: this.backToken
},{copyrightOwnerId:this.ruleForm.exhibitionBoardCatIdList.toString}) },this.$qs.stringify({copyrightOwnerId:this.ruleForm.copyrightOwnerIdList.toString()}))
.then(res => { .then(res => {
let data = res.data.data; let data = res.data.data;
vm.videoContentCat = data; vm.videoContentCat = data;
......
...@@ -80,7 +80,6 @@ ...@@ -80,7 +80,6 @@
</div> </div>
<div class="partyt-pagination"> <div class="partyt-pagination">
<el-pagination <el-pagination
background
@current-change="handleCurrentChange" @current-change="handleCurrentChange"
:current-page="page.currentPage" :current-page="page.currentPage"
:page-size="page.pageSize" :page-size="page.pageSize"
......
...@@ -4,8 +4,8 @@ ...@@ -4,8 +4,8 @@
<el-form :inline="true" :model="form" class="search-form" onsubmit="return false;"> <el-form :inline="true" :model="form" class="search-form" onsubmit="return false;">
<el-form-item label=""> <el-form-item label="">
<el-input <el-input
placeholder="请输入版权方名称" placeholder="请输入视频名称"
v-model="form.name" v-model="form.nameOrCode"
@keyup.enter.native="Search" @keyup.enter.native="Search"
clearable clearable
></el-input> ></el-input>
...@@ -104,7 +104,7 @@ ...@@ -104,7 +104,7 @@
<i class="icon-table icon-del"></i> <i class="icon-table icon-del"></i>
</el-button> </el-button>
</el-tooltip> </el-tooltip>
<el-tooltip content="详情" placement="top"> <el-tooltip content="审核详情" placement="top">
<el-button circle @click="openDetails(scope.row)"> <el-button circle @click="openDetails(scope.row)">
<i class="icon-table icon-detail"></i> <i class="icon-table icon-detail"></i>
</el-button> </el-button>
...@@ -389,7 +389,7 @@ export default { ...@@ -389,7 +389,7 @@ export default {
let searchObj = { let searchObj = {
_index: 1, _index: 1,
_size: _this.page.pageSize, _size: _this.page.pageSize,
name: _this.form.name, nameOrCode: _this.form.nameOrCode,
videoContentCatId:_this.form.videoContentCatId, videoContentCatId:_this.form.videoContentCatId,
videoContentCopyrightOwnerId:_this.form.videoContentCopyrightOwnerId videoContentCopyrightOwnerId:_this.form.videoContentCopyrightOwnerId
}; };
......
...@@ -49,7 +49,7 @@ ...@@ -49,7 +49,7 @@
</el-form> </el-form>
<div class="page-tip"> <div class="page-tip">
<span class="page-tip-title">页面说明:</span> <span class="page-tip-title">页面说明:</span>
<span class="page-tips">可使用版权方、视频分类、视频名称模糊搜索对需要汇出的视频进行快速检索,选定视频后将视频汇出到指定U盘</span> <span class="page-tips">可使用版权方、视频分类、视频名称模糊搜索对需要汇出的视频进行快速检索,下载至本地</span>
</div> </div>
</div> </div>
<div class="table-content"> <div class="table-content">
......
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