Commit 724cf79b authored by qiaoyajun's avatar qiaoyajun
parents 24697171 cb2d63bf
......@@ -8,7 +8,8 @@
<div class="travelControlTrip detail-box">
<div class="trip_cover" v-show="pdfLoading" v-loading="pdfLoading"></div>
<input type="button" style="width: auto !important;" class="travelControlTripBtn" value="下载电脑版PDF" @click="toPDF(orderMsg.startDate + orderMsg.lineteamName+orderMsg.dayNum+'日游')" />
<input type="button" style="width: auto !important;" class="travelControlTripBtn" value="下载手机版WORD" @click="gernalFeature()" />
<input type="button" style="width: auto !important;" class="travelControlTripBtn" value="下载手机版WORD" @click="gernalFeature(0)" />
<input type="button" style="width: auto !important;" class="travelControlTripBtn" value="下载电脑版WORD" @click="gernalFeature(1)" />
<!-- ToWord(orderMsg.startDate + orderMsg.lineteamName+orderMsg.dayNum+'日游') -->
<!--&&isopOperation HK 注释 可以让销售修改基本信息-->
<input type="button" v-if="orderId>0" class="travelControlTripBtn" value="修改信息" @click="editMsgShow=true" />
......@@ -642,7 +643,7 @@
}, 2000)
},
methods: {
gernalFeature(){
gernalFeature(type){
this.pdfLoading = true;
let tcid = this.$route.query.tcid;
let UploadUrl = this.domainManager().UploadUrl
......@@ -655,7 +656,7 @@
success: function (data) {
let msg = JSON.parse(data)
if (msg.ResultCode) { // 已经存在文件 直接调用下载
_this.ToWord(_this.orderMsg.startDate + _this.orderMsg.lineteamName + _this.orderMsg.dayNum + '日游')
_this.ToWord(_this.orderMsg.startDate + _this.orderMsg.lineteamName + _this.orderMsg.dayNum + '日游',type)
} else { // 不存在图片保存图片后下载
document.querySelector("#gernalCanvas").querySelectorAll('img').forEach(x => {
let src = x.src
......@@ -705,7 +706,7 @@
if (allNum!==document.querySelectorAll(cName).length) {
allNum += 1
} else {
_this.ToWord(_this.orderMsg.startDate + _this.orderMsg.lineteamName + _this.orderMsg.dayNum + '日游')
_this.ToWord(_this.orderMsg.startDate + _this.orderMsg.lineteamName + _this.orderMsg.dayNum + '日游',type)
}
}
});
......@@ -718,7 +719,7 @@
}
});
} else {
this.ToWord(this.orderMsg.startDate + this.orderMsg.lineteamName + this.orderMsg.dayNum + '日游')
this.ToWord(this.orderMsg.startDate + this.orderMsg.lineteamName + this.orderMsg.dayNum + '日游',type)
}
},
//保存基础数据
......@@ -898,7 +899,7 @@
console.log(err)
})
},
ToWord:function(title)
ToWord:function(title,isPc)
{
let msg = {
configId: this.$route.query.configId,
......@@ -932,6 +933,8 @@
isShowTCNUM:this.vshowTCNUM?1:0,
//是否显示行程图片
isShowTripImage:this.vshowK?1:0,
//isPc是否PC下载
isPc: type,
};
this.GetLocalFile("DownLoadTripWord", msg,title+ ".doc", res=>{
this.pdfLoading = false
......
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