Commit 55cbe1f0 authored by liudong1993's avatar liudong1993
parents 4ec2285a f692649b
...@@ -1000,6 +1000,7 @@ ...@@ -1000,6 +1000,7 @@
} }
} }
this.apipost('dmcstatistics_get_GetHotelStaticsDetail_V2', msg, res => { this.apipost('dmcstatistics_get_GetHotelStaticsDetail_V2', msg, res => {
console.log("dmcstatistics_get_GetHotelStaticsDetail_V2",res.data);
if (res.data.resultCode == 1) { if (res.data.resultCode == 1) {
this.IsOperation = res.data.data.IsOperation; this.IsOperation = res.data.data.IsOperation;
if (this.IsEditHotel == 0) { if (this.IsEditHotel == 0) {
......
...@@ -151,8 +151,7 @@ ...@@ -151,8 +151,7 @@
<td class="w350" rowspan="3"> <td class="w350" rowspan="3">
<el-form-item :label="$t('objFill.v101.fengmian')+(index+1)" style="margin-bottom: 0;"> <el-form-item :label="$t('objFill.v101.fengmian')+(index+1)" style="margin-bottom: 0;">
<div class="webSliderDiv" @click="clickIndex=index"> <div class="webSliderDiv" @click="clickIndex=index">
<el-upload <el-upload :before-upload="(file)=>beforeUploadVideo(file,item.FileType)"
:before-upload="(file)=>beforeUploadVideo(file,item.FileType)"
:http-request="(file)=>UploadAttachment(file,item.FileType)" :multiple="true" :http-request="(file)=>UploadAttachment(file,item.FileType)" :multiple="true"
accept="image/jpeg,image/gif,image/png,image/bmp" :show-file-list="false" action=""> accept="image/jpeg,image/gif,image/png,image/bmp" :show-file-list="false" action="">
<img v-if="item.FileType==1&&item.FileUrl" :src="item.FileUrl" class="web_imgUrl" alt="" /> <img v-if="item.FileType==1&&item.FileUrl" :src="item.FileUrl" class="web_imgUrl" alt="" />
...@@ -207,7 +206,8 @@ ...@@ -207,7 +206,8 @@
</tbody> </tbody>
</table> </table>
</el-form> </el-form>
<el-dialog :title="$t('objFill.qingxzcd')" :visible.sync="isShowMenuDialog" width="1000px" class="webset_choosemenu" append-to-body> <el-dialog :title="$t('objFill.qingxzcd')" :visible.sync="isShowMenuDialog" width="1000px" class="webset_choosemenu"
append-to-body>
<!-- 行程选中 --> <!-- 行程选中 -->
<chooseMenu ref="chooseMenu"></chooseMenu> <chooseMenu ref="chooseMenu"></chooseMenu>
<span slot="footer" class="dialog-footer"> <span slot="footer" class="dialog-footer">
...@@ -259,7 +259,7 @@ ...@@ -259,7 +259,7 @@
var str = x.data.FilePath; var str = x.data.FilePath;
var imgUrl = this.domainManager().ViittoFileUrl + str; var imgUrl = this.domainManager().ViittoFileUrl + str;
this.plugData.MLogo = imgUrl; this.plugData.MLogo = imgUrl;
},2); }, 2);
}, },
addMenu() { addMenu() {
this.plugData.NavList.push(JSON.parse(JSON.stringify(this.MenuList))) this.plugData.NavList.push(JSON.parse(JSON.stringify(this.MenuList)))
...@@ -270,15 +270,14 @@ ...@@ -270,15 +270,14 @@
that.plugData.NavList.splice(index, 1) that.plugData.NavList.splice(index, 1)
}); });
}, },
beforeUploadVideo(file,FileType) { // 视频验证 beforeUploadVideo(file, FileType) { // 视频验证
if(file.type.indexOf('video')!=-1&&FileType==1) { if (file.type.indexOf('video') != -1 && FileType == 1) {
FileType=2 FileType = 2
} } else if (file.type.indexOf('video') == -1 && FileType == 2) {
else if(file.type.indexOf('video')==-1&&FileType==2) { FileType = 1
FileType=1
} }
this.plugData.NavList[this.clickIndex].FileType = FileType this.plugData.NavList[this.clickIndex].FileType = FileType
if(FileType==1) return true if (FileType == 1) return true
const isLt10M = file.size / 1024 / 1024 < 10; const isLt10M = file.size / 1024 / 1024 < 10;
if (['video/mp4', 'video/ogg', 'video/flv', 'video/avi', 'video/wmv', 'video/rmvb'].indexOf(file.type) === - if (['video/mp4', 'video/ogg', 'video/flv', 'video/avi', 'video/wmv', 'video/rmvb'].indexOf(file.type) === -
1) { 1) {
...@@ -291,32 +290,31 @@ ...@@ -291,32 +290,31 @@
} }
}, },
//上传图片 //上传图片
UploadAttachment(file,FileType) { UploadAttachment(file, FileType) {
let newArr = []; let newArr = [];
newArr.push(file.file); newArr.push(file.file);
var path = "/Upload/WebSite/"; var path = "/Upload/WebSite/";
this.$message.info(this.$t('tips.shangchuanzhong')) this.$message.info(this.$t('tips.shangchuanzhong'))
if(file.file.type.indexOf('video')!=-1&&FileType==1) { if (file.file.type.indexOf('video') != -1 && FileType == 1) {
FileType=2 FileType = 2
} } else if (file.file.type.indexOf('video') == -1 && FileType == 2) {
else if(file.file.type.indexOf('video')==-1&&FileType==2) { FileType = 1
FileType=1
} }
this.plugData.NavList[this.clickIndex].FileType = FileType this.plugData.NavList[this.clickIndex].FileType = FileType
if(FileType==1){ if (FileType == 1) {
this.UploadSelfFileT(path, newArr, x => { this.UploadSelfFileT(path, newArr, x => {
var str = x.data.FilePath; var str = x.data.FilePath;
var imgUrl = this.domainManager().ViittoFileUrl + str; var imgUrl = this.domainManager().ViittoFileUrl + str;
this.plugData.NavList[this.clickIndex].FileUrl = imgUrl; this.plugData.NavList[this.clickIndex].FileUrl = imgUrl;
this.$message.success(this.$t('tips.scchenggong')); this.$message.success(this.$t('tips.scchenggong'));
},2); }, 2);
}else{ } else {
this.UploadFileToAli2024(path, newArr, x => { this.UploadFileToAli2024(path, newArr, x => {
var str = x.data.FilePath; var str = x.data.FilePath;
var imgUrl = this.domainManager().OSSUrl + str; var imgUrl = this.domainManager().OSSUrl + str;
this.plugData.NavList[this.clickIndex].FileUrl = imgUrl; this.plugData.NavList[this.clickIndex].FileUrl = imgUrl;
this.$message.success(this.$t('tips.scchenggong')); this.$message.success(this.$t('tips.scchenggong'));
},2); }, 2);
} }
}, },
//显示菜单弹窗 //显示菜单弹窗
...@@ -330,6 +328,9 @@ ...@@ -330,6 +328,9 @@
this.isShowMenuDialog = false; this.isShowMenuDialog = false;
if (chooseMenuObj) { if (chooseMenuObj) {
this.clickItem.SubName = chooseMenuObj.MenuName; this.clickItem.SubName = chooseMenuObj.MenuName;
if (chooseMenuObj.MenuSubName) {
this.clickItem.SubDescribe = chooseMenuObj.MenuSubName;
}
this.clickItem.LinkUrl = chooseMenuObj.MenuUrl; this.clickItem.LinkUrl = chooseMenuObj.MenuUrl;
if (chooseMenuObj.ImgUrl && chooseMenuObj.ImgUrl != '') { if (chooseMenuObj.ImgUrl && chooseMenuObj.ImgUrl != '') {
this.clickItem.FileUrl = chooseMenuObj.ImgUrl; this.clickItem.FileUrl = chooseMenuObj.ImgUrl;
......
...@@ -152,8 +152,7 @@ ...@@ -152,8 +152,7 @@
<td class="w350" rowspan="3"> <td class="w350" rowspan="3">
<el-form-item :label="$t('objFill.v101.fengmian')+(index+1)" style="margin-bottom: 0;"> <el-form-item :label="$t('objFill.v101.fengmian')+(index+1)" style="margin-bottom: 0;">
<div class="webSliderDiv" @click="clickIndex=index"> <div class="webSliderDiv" @click="clickIndex=index">
<el-upload <el-upload :before-upload="(file)=>beforeUploadVideo(file,item.FileType)"
:before-upload="(file)=>beforeUploadVideo(file,item.FileType)"
:http-request="(file)=>UploadAttachment(file,item.FileType)" :multiple="true" :http-request="(file)=>UploadAttachment(file,item.FileType)" :multiple="true"
accept="image/jpeg,image/gif,image/png,image/bmp" :show-file-list="false" action=""> accept="image/jpeg,image/gif,image/png,image/bmp" :show-file-list="false" action="">
<img v-if="item.FileType==1&&item.FileUrl" :src="item.FileUrl" class="web_imgUrl" alt="" /> <img v-if="item.FileType==1&&item.FileUrl" :src="item.FileUrl" class="web_imgUrl" alt="" />
...@@ -262,7 +261,7 @@ ...@@ -262,7 +261,7 @@
var imgUrl = this.domainManager().ViittoFileUrl + str; var imgUrl = this.domainManager().ViittoFileUrl + str;
this.plugData.MLogo = imgUrl; this.plugData.MLogo = imgUrl;
this.$message.success(this.$t('tips.scchenggong')); this.$message.success(this.$t('tips.scchenggong'));
},2); }, 2);
}, },
addMenu() { addMenu() {
this.plugData.NavList.push(JSON.parse(JSON.stringify(this.MenuList))) this.plugData.NavList.push(JSON.parse(JSON.stringify(this.MenuList)))
...@@ -273,15 +272,14 @@ ...@@ -273,15 +272,14 @@
that.plugData.NavList.splice(index, 1) that.plugData.NavList.splice(index, 1)
}); });
}, },
beforeUploadVideo (file,FileType) { // 视频验证 beforeUploadVideo(file, FileType) { // 视频验证
if(file.type.indexOf('video')!=-1&&FileType==1) { if (file.type.indexOf('video') != -1 && FileType == 1) {
FileType=2 FileType = 2
} } else if (file.type.indexOf('video') == -1 && FileType == 2) {
else if(file.type.indexOf('video')==-1&&FileType==2) { FileType = 1
FileType=1
} }
this.plugData.NavList[this.clickIndex].FileType = FileType this.plugData.NavList[this.clickIndex].FileType = FileType
if(FileType==1) return true if (FileType == 1) return true
const isLt10M = file.size / 1024 / 1024 < 10; const isLt10M = file.size / 1024 / 1024 < 10;
if (['video/mp4', 'video/ogg', 'video/flv', 'video/avi', 'video/wmv', 'video/rmvb'].indexOf(file.type) === - if (['video/mp4', 'video/ogg', 'video/flv', 'video/avi', 'video/wmv', 'video/rmvb'].indexOf(file.type) === -
1) { 1) {
...@@ -294,32 +292,31 @@ ...@@ -294,32 +292,31 @@
} }
}, },
//上传图片 //上传图片
UploadAttachment(file,FileType) { UploadAttachment(file, FileType) {
let newArr = []; let newArr = [];
newArr.push(file.file); newArr.push(file.file);
var path = "/Upload/WebSite/"; var path = "/Upload/WebSite/";
this.$message.info(this.$t('tips.shangchuanzhong')) this.$message.info(this.$t('tips.shangchuanzhong'))
if(file.file.type.indexOf('video')!=-1&&FileType==1) { if (file.file.type.indexOf('video') != -1 && FileType == 1) {
FileType=2 FileType = 2
} } else if (file.file.type.indexOf('video') == -1 && FileType == 2) {
else if(file.file.type.indexOf('video')==-1&&FileType==2) { FileType = 1
FileType=1
} }
this.plugData.NavList[this.clickIndex].FileType = FileType this.plugData.NavList[this.clickIndex].FileType = FileType
if(FileType==1){ if (FileType == 1) {
this.UploadSelfFileT(path, newArr, x => { this.UploadSelfFileT(path, newArr, x => {
var str = x.data.FilePath; var str = x.data.FilePath;
var imgUrl = this.domainManager().ViittoFileUrl + str; var imgUrl = this.domainManager().ViittoFileUrl + str;
this.plugData.NavList[this.clickIndex].FileUrl = imgUrl; this.plugData.NavList[this.clickIndex].FileUrl = imgUrl;
this.$message.success(this.$t('tips.scchenggong')); this.$message.success(this.$t('tips.scchenggong'));
},2); }, 2);
}else{ } else {
this.UploadFileToAli2024(path, newArr, x => { this.UploadFileToAli2024(path, newArr, x => {
var str = x.data.FilePath; var str = x.data.FilePath;
var imgUrl = this.domainManager().OSSUrl + str; var imgUrl = this.domainManager().OSSUrl + str;
this.plugData.NavList[this.clickIndex].FileUrl = imgUrl; this.plugData.NavList[this.clickIndex].FileUrl = imgUrl;
this.$message.success(this.$t('tips.scchenggong')); this.$message.success(this.$t('tips.scchenggong'));
},2); }, 2);
} }
}, },
//显示菜单弹窗 //显示菜单弹窗
...@@ -333,6 +330,9 @@ ...@@ -333,6 +330,9 @@
this.isShowMenuDialog = false; this.isShowMenuDialog = false;
if (chooseMenuObj) { if (chooseMenuObj) {
this.clickItem.SubName = chooseMenuObj.MenuName; this.clickItem.SubName = chooseMenuObj.MenuName;
if (chooseMenuObj.MenuSubName) {
this.clickItem.SubDescribe = chooseMenuObj.MenuSubName;
}
this.clickItem.LinkUrl = chooseMenuObj.MenuUrl; this.clickItem.LinkUrl = chooseMenuObj.MenuUrl;
if (chooseMenuObj.ImgUrl && chooseMenuObj.ImgUrl != '') { if (chooseMenuObj.ImgUrl && chooseMenuObj.ImgUrl != '') {
this.clickItem.FileUrl = chooseMenuObj.ImgUrl; this.clickItem.FileUrl = chooseMenuObj.ImgUrl;
......
...@@ -151,8 +151,7 @@ ...@@ -151,8 +151,7 @@
<td class="w350" rowspan="3"> <td class="w350" rowspan="3">
<el-form-item :label="$t('objFill.v101.fengmian')+(index+1)" style="margin-bottom: 0;"> <el-form-item :label="$t('objFill.v101.fengmian')+(index+1)" style="margin-bottom: 0;">
<div class="webSliderDiv" @click="clickIndex=index"> <div class="webSliderDiv" @click="clickIndex=index">
<el-upload <el-upload :before-upload="(file)=>beforeUploadVideo(file,item.FileType)"
:before-upload="(file)=>beforeUploadVideo(file,item.FileType)"
:http-request="(file)=>UploadAttachment(file,item.FileType)" :multiple="true" :http-request="(file)=>UploadAttachment(file,item.FileType)" :multiple="true"
accept="image/jpeg,image/gif,image/png,image/bmp" :show-file-list="false" action=""> accept="image/jpeg,image/gif,image/png,image/bmp" :show-file-list="false" action="">
<img v-if="item.FileType==1&&item.FileUrl" :src="item.FileUrl" class="web_imgUrl" alt="" /> <img v-if="item.FileType==1&&item.FileUrl" :src="item.FileUrl" class="web_imgUrl" alt="" />
...@@ -260,7 +259,7 @@ ...@@ -260,7 +259,7 @@
var str = x.data.FilePath; var str = x.data.FilePath;
var imgUrl = this.domainManager().ViittoFileUrl + str; var imgUrl = this.domainManager().ViittoFileUrl + str;
this.plugData.MLogo = imgUrl; this.plugData.MLogo = imgUrl;
},2); }, 2);
}, },
addMenu() { addMenu() {
this.plugData.NavList.push(JSON.parse(JSON.stringify(this.MenuList))) this.plugData.NavList.push(JSON.parse(JSON.stringify(this.MenuList)))
...@@ -271,15 +270,14 @@ ...@@ -271,15 +270,14 @@
that.plugData.NavList.splice(index, 1) that.plugData.NavList.splice(index, 1)
}); });
}, },
beforeUploadVideo (file,FileType) { // 视频验证 beforeUploadVideo(file, FileType) { // 视频验证
if(file.type.indexOf('video')!=-1&&FileType==1) { if (file.type.indexOf('video') != -1 && FileType == 1) {
FileType=2 FileType = 2
} } else if (file.type.indexOf('video') == -1 && FileType == 2) {
else if(file.type.indexOf('video')==-1&&FileType==2) { FileType = 1
FileType=1
} }
this.plugData.NavList[this.clickIndex].FileType = FileType this.plugData.NavList[this.clickIndex].FileType = FileType
if(FileType==1) return true if (FileType == 1) return true
const isLt10M = file.size / 1024 / 1024 < 10; const isLt10M = file.size / 1024 / 1024 < 10;
if (['video/mp4', 'video/ogg', 'video/flv', 'video/avi', 'video/wmv', 'video/rmvb'].indexOf(file.type) === - if (['video/mp4', 'video/ogg', 'video/flv', 'video/avi', 'video/wmv', 'video/rmvb'].indexOf(file.type) === -
1) { 1) {
...@@ -292,31 +290,30 @@ ...@@ -292,31 +290,30 @@
} }
}, },
//上传图片 //上传图片
UploadAttachment(file,FileType) { UploadAttachment(file, FileType) {
console.log() console.log()
let newArr = []; let newArr = [];
newArr.push(file.file); newArr.push(file.file);
var path = "/Upload/WebSite/"; var path = "/Upload/WebSite/";
if(file.file.type.indexOf('video')!=-1&&FileType==1) { if (file.file.type.indexOf('video') != -1 && FileType == 1) {
FileType=2 FileType = 2
} } else if (file.file.type.indexOf('video') == -1 && FileType == 2) {
else if(file.file.type.indexOf('video')==-1&&FileType==2) { FileType = 1
FileType=1
} }
this.plugData.NavList[this.clickIndex].FileType = FileType this.plugData.NavList[this.clickIndex].FileType = FileType
if(FileType==1){ if (FileType == 1) {
this.UploadSelfFileT(path, newArr, x => { this.UploadSelfFileT(path, newArr, x => {
var str = x.data.FilePath; var str = x.data.FilePath;
var imgUrl = this.domainManager().ViittoFileUrl + str; var imgUrl = this.domainManager().ViittoFileUrl + str;
this.plugData.NavList[this.clickIndex].FileUrl = imgUrl; this.plugData.NavList[this.clickIndex].FileUrl = imgUrl;
},2); }, 2);
}else{ } else {
this.UploadFileToAli2024(path, newArr, x => { this.UploadFileToAli2024(path, newArr, x => {
var str = x.data.FilePath; var str = x.data.FilePath;
var imgUrl = this.domainManager().OSSUrl + str; var imgUrl = this.domainManager().OSSUrl + str;
this.plugData.NavList[this.clickIndex].FileUrl = imgUrl; this.plugData.NavList[this.clickIndex].FileUrl = imgUrl;
this.$message.success(this.$t('tips.scchenggong')); this.$message.success(this.$t('tips.scchenggong'));
},2); }, 2);
} }
}, },
...@@ -328,7 +325,7 @@ ...@@ -328,7 +325,7 @@
var str = x.data.FilePath; var str = x.data.FilePath;
var imgUrl = this.domainManager().ViittoFileUrl + str; var imgUrl = this.domainManager().ViittoFileUrl + str;
this.plugData.MLogo = imgUrl; this.plugData.MLogo = imgUrl;
},2); }, 2);
}, },
//显示菜单弹窗 //显示菜单弹窗
ShowMenuDialog(item) { ShowMenuDialog(item) {
...@@ -341,6 +338,9 @@ ...@@ -341,6 +338,9 @@
this.isShowMenuDialog = false; this.isShowMenuDialog = false;
if (chooseMenuObj) { if (chooseMenuObj) {
this.clickItem.SubName = chooseMenuObj.MenuName; this.clickItem.SubName = chooseMenuObj.MenuName;
if (chooseMenuObj.MenuSubName) {
this.clickItem.SubDescribe = chooseMenuObj.MenuSubName;
}
this.clickItem.LinkUrl = chooseMenuObj.MenuUrl; this.clickItem.LinkUrl = chooseMenuObj.MenuUrl;
if (chooseMenuObj.ImgUrl && chooseMenuObj.ImgUrl != '') { if (chooseMenuObj.ImgUrl && chooseMenuObj.ImgUrl != '') {
this.clickItem.FileUrl = chooseMenuObj.ImgUrl; this.clickItem.FileUrl = chooseMenuObj.ImgUrl;
......
...@@ -331,6 +331,7 @@ ...@@ -331,6 +331,7 @@
MenuName: "", MenuName: "",
MenuUrl: "", MenuUrl: "",
ImgUrl: "", ImgUrl: "",
MenuSubName: "",
}; };
var domainUrl = this.getLocalStorage().B2BDomain; var domainUrl = this.getLocalStorage().B2BDomain;
//自定义页面 //自定义页面
...@@ -354,7 +355,10 @@ ...@@ -354,7 +355,10 @@
this.dataList.forEach((item) => { this.dataList.forEach((item) => {
if (item.Checked) { if (item.Checked) {
obj.MenuName = item.Title; obj.MenuName = item.Title;
// obj.MenuUrl = this.$tripUtils.GetB2BUrl(domainUrl, item.ConfigId, item.TCID); console.log("item.ProductRecommend",item.ProductRecommend)
if (item.ProductRecommend && item.ProductRecommend != '') {
obj.MenuSubName = item.ProductRecommend;
}
obj.MenuUrl = this.$tripUtils.GetB2CHomeSeriesUrl(domainUrl, item.ID, item.TCIDEnStr); obj.MenuUrl = this.$tripUtils.GetB2CHomeSeriesUrl(domainUrl, item.ID, item.TCIDEnStr);
if (item.ImgCover && item.ImgCover.length > 0) { if (item.ImgCover && item.ImgCover.length > 0) {
obj.ImgUrl = item.ImgCover[0].Url; obj.ImgUrl = item.ImgCover[0].Url;
...@@ -367,6 +371,7 @@ ...@@ -367,6 +371,7 @@
obj.MenuUrl = domainUrl + obj.MenuUrl; obj.MenuUrl = domainUrl + obj.MenuUrl;
} }
} }
console.log("chooseObj",obj);
return obj; return obj;
}, },
//选中切换 //选中切换
......
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