Commit f3115e56 authored by 黄奎's avatar 黄奎

行程特色修改

parent f2e208e5
...@@ -34,25 +34,31 @@ ...@@ -34,25 +34,31 @@
:TCNUM="TCNUM" id="firstAnchor" :LineList="LineList"></TravelConfig> :TCNUM="TCNUM" id="firstAnchor" :LineList="LineList"></TravelConfig>
<TravelDaysTripDirect id="secondAnchor" @headCallBack="getDaysTrip" :NoticeParameters="NoticeParameters" <TravelDaysTripDirect id="secondAnchor" @headCallBack="getDaysTrip" :NoticeParameters="NoticeParameters"
:subConfig="journeyList" :isOpenGroup="false" :IsDirect="PostConfig.IsDirect" v-bind:AllCityList="AllCityList" :subConfig="journeyList" :isOpenGroup="false" :IsDirect="PostConfig.IsDirect" v-bind:AllCityList="AllCityList"
v-bind:StartCity="StartCity" :UseTypeArray="UseTypeArray" :AirPickUp="AirPickUp" :AirSend="AirSend" @change="handlerChangeData" :TeamType="TeamType" :IsOpenHotel="PostConfig.IsOpenHotel"></TravelDaysTripDirect> v-bind:StartCity="StartCity" :UseTypeArray="UseTypeArray" :AirPickUp="AirPickUp" :AirSend="AirSend"
<TravelFeature ref="TravelFeature" id="thirdAnchor" @featureCallBack="getFeature" :FeatureData="FeatureData" :TeamType="TeamType" @change="handlerChangeData" :TeamType="TeamType" :IsOpenHotel="PostConfig.IsOpenHotel"></TravelDaysTripDirect>
:isNewConfig="isNewConfig" @unlockFormCommit="unlockFormCommit"></TravelFeature> <TravelFeature ref="TravelFeature" id="thirdAnchor" @featureCallBack="getFeature" :FeatureData="FeatureData"
:TeamType="TeamType" :isNewConfig="isNewConfig" @unlockFormCommit="unlockFormCommit"></TravelFeature>
<TravelNotice ref="TravelNotice" id="fourAnchor" @headCallBack="getNotice" :subArray="NoticeParameters" <TravelNotice ref="TravelNotice" id="fourAnchor" @headCallBack="getNotice" :subArray="NoticeParameters"
:NoticeData="NoticeData" v-bind:PostConfig="PostConfig" v-bind:AllCityList="AllCityList" v-bind:CountryID="PostConfig.CountryID"></TravelNotice> :NoticeData="NoticeData" v-bind:PostConfig="PostConfig" v-bind:AllCityList="AllCityList"
v-bind:CountryID="PostConfig.CountryID"></TravelNotice>
<TravelPrice @saveMsg="SaveData(1)" ref="TravelPrice" id="fiveAnchor" @headCallBack="getPrice" :priceList="PriceList" v-if="TeamType==0" <TravelPrice @saveMsg="SaveData(1)" ref="TravelPrice" id="fiveAnchor" @headCallBack="getPrice"
:PostConfig="PostConfig" :modifyTcid="modifyTcid" :TeamType="TeamType"></TravelPrice> :priceList="PriceList" v-if="TeamType==0" :PostConfig="PostConfig" :modifyTcid="modifyTcid"
<TravelPrice2 ref="TravelPrice" id="fiveAnchor" @headCallBack="getPrice" :PostDaysTrip="PostDaysTrip" v-if="TeamType==1" :TeamType="TeamType"></TravelPrice>
:priceList="PriceList" :PostConfig="PostConfig" :modifyTcid="modifyTcid" :TeamType="TeamType"></TravelPrice2> <TravelPrice2 ref="TravelPrice" id="fiveAnchor" @headCallBack="getPrice" :PostDaysTrip="PostDaysTrip"
<TravelPrice3 ref="TravelPrice" id="fiveAnchor" @headCallBack="getPrice" :PostDaysTrip="PostDaysTrip" v-if="TeamType==2" v-if="TeamType==1" :priceList="PriceList" :PostConfig="PostConfig" :modifyTcid="modifyTcid"
:priceList="PriceList" :PostConfig="PostConfig" :modifyTcid="modifyTcid" :TeamType="TeamType"></TravelPrice3> :TeamType="TeamType"></TravelPrice2>
<TravelPrice3 ref="TravelPrice" id="fiveAnchor" @headCallBack="getPrice" :PostDaysTrip="PostDaysTrip"
v-if="TeamType==2" :priceList="PriceList" :PostConfig="PostConfig" :modifyTcid="modifyTcid"
:TeamType="TeamType"></TravelPrice3>
<div class="btnFixedDiv"> <div class="btnFixedDiv">
<div class="toTop" @click="backTop"> <div class="toTop" @click="backTop">
<i class="iconfont icon-huidaodingbu"></i> <i class="iconfont icon-huidaodingbu"></i>
</div> </div>
<div v-if="modifyType!=2" class="DTSaveBtn" :class="{'disClick':!isSubmit}" @click="submitForm(1)">保存</div> <div v-if="modifyType!=2" class="DTSaveBtn" :class="{'disClick':!isSubmit}" @click="submitForm(1)">保存</div>
<div v-if="modifyType!=2" class="DTSaveBtn" :class="{'disClick':!isSubmit}" @click="submitForm(2)">提交</div> <div v-if="modifyType!=2" class="DTSaveBtn" :class="{'disClick':!isSubmit}" @click="submitForm(2)">提交</div>
<div v-if="modifyType==2" class="DTSaveBtn" :class="{'disClick':!isSubmit}" @click="submitForm(3)" title="另存为新模板">保存 <div v-if="modifyType==2" class="DTSaveBtn" :class="{'disClick':!isSubmit}" @click="submitForm(3)"
title="另存为新模板">保存
</div> </div>
<div v-if="ConfigId>0" class="DTSaveBtn" :class="{'disClick':!isSubmit}" @click="goB2B()">预览</div> <div v-if="ConfigId>0" class="DTSaveBtn" :class="{'disClick':!isSubmit}" @click="goB2B()">预览</div>
</div> </div>
...@@ -87,6 +93,8 @@ ...@@ -87,6 +93,8 @@
IsDirect: 0, //是否直采 IsDirect: 0, //是否直采
LineId: 0 //线路编号 LineId: 0 //线路编号
}, },
FeatureHtmlJson: '',
FeatureHtmlJsonDelete: '',
NoticeData: { NoticeData: {
FeeInclude: "", FeeInclude: "",
FeeNonInclude: "", FeeNonInclude: "",
...@@ -123,9 +131,9 @@ ...@@ -123,9 +131,9 @@
fileList: [], fileList: [],
VideoStr: "", //视频地址 VideoStr: "", //视频地址
//是否更新酒店库存 //是否更新酒店库存
IsUpdateHotel:0, IsUpdateHotel: 0,
OpenTeamDescribe:"",//开团备注 OpenTeamDescribe: "", //开团备注
IsOpenHotel:0,//0可以添加删除酒店,1-不能修改酒店信息 IsOpenHotel: 0, //0可以添加删除酒店,1-不能修改酒店信息
}, },
//行程 //行程
FeatureData: { FeatureData: {
...@@ -193,7 +201,7 @@ ...@@ -193,7 +201,7 @@
ckedNav: 1, ckedNav: 1,
modifyType: 1, //1:系列团修改,2:单团修改 modifyType: 1, //1:系列团修改,2:单团修改
modifyTcid: 0, //修改单团期id modifyTcid: 0, //修改单团期id
TeamType:'', TeamType: '',
loading: false, loading: false,
isNewConfig: true, isNewConfig: true,
}; };
...@@ -316,16 +324,18 @@ ...@@ -316,16 +324,18 @@
basicData.ImgCover = this.PostConfig.ImgCover; basicData.ImgCover = this.PostConfig.ImgCover;
basicData.PriceIsDirect = this.PostConfig.PriceIsDirect; basicData.PriceIsDirect = this.PostConfig.PriceIsDirect;
basicData.IsDirect = this.PostConfig.IsDirect; basicData.IsDirect = this.PostConfig.IsDirect;
basicData.OpenTeamDescribe=this.PostConfig.OpenTeamDescribe; basicData.OpenTeamDescribe = this.PostConfig.OpenTeamDescribe;
basicData.RemoveChild = this.PostConfig.RemoveChild; basicData.RemoveChild = this.PostConfig.RemoveChild;
basicData.TeamType = this.PostConfig.TeamType; basicData.TeamType = this.PostConfig.TeamType;
basicData.DayNum = (this.PostDaysTrip && this.PostDaysTrip.DayNum != "") ? this.PostDaysTrip.DayNum : 0; basicData.DayNum = (this.PostDaysTrip && this.PostDaysTrip.DayNum != "") ? this.PostDaysTrip.DayNum : 0;
basicData.NightNum = (this.PostDaysTrip && this.PostDaysTrip.NightNum != "") ? this.PostDaysTrip.NightNum : 0; basicData.NightNum = (this.PostDaysTrip && this.PostDaysTrip.NightNum != "") ? this.PostDaysTrip.NightNum : 0;
basicData.StartCityId = (this.PostDaysTrip && this.PostDaysTrip.StartCityId != "") ? this.PostDaysTrip.StartCityId : basicData.StartCityId = (this.PostDaysTrip && this.PostDaysTrip.StartCityId != "") ? this.PostDaysTrip
.StartCityId :
0; 0;
basicData.ReturnArriveCityId = (this.PostDaysTrip && this.PostDaysTrip.ReturnArriveCityId != "") ? this.PostDaysTrip basicData.ReturnArriveCityId = (this.PostDaysTrip && this.PostDaysTrip.ReturnArriveCityId != "") ? this
.PostDaysTrip
.ReturnArriveCityId : 0; .ReturnArriveCityId : 0;
basicData.SelfpayingList = this.PostConfig.SelfpayingList; basicData.SelfpayingList = this.PostConfig.SelfpayingList;
...@@ -349,21 +359,28 @@ ...@@ -349,21 +359,28 @@
TripFeature.FeatureHtmlJson = TripFeature.FeatureHtmlJson ? TripFeature.FeatureHtmlJson = TripFeature.FeatureHtmlJson ?
JSON.stringify(TripFeature.FeatureHtmlJson) : JSON.stringify(TripFeature.FeatureHtmlJson) :
""; "";
TripFeature.FeatureHtmlJsonDelete = TripFeature.FeatureHtmlJsonDelete ? JSON.stringify(TripFeature.FeatureHtmlJsonDelete) : TripFeature.FeatureHtmlJsonDelete = TripFeature.FeatureHtmlJsonDelete ? JSON.stringify(TripFeature
.FeatureHtmlJsonDelete) :
""; "";
var htmlObj = document.getElementById("newFeatureBox"); var htmlObj = document.getElementById("newFeatureBox");
if(htmlObj){ if (htmlObj) {
if(htmlObj.innerHTML!=null||htmlObj.innerHTML!=""){ if (htmlObj.innerHTML != null || htmlObj.innerHTML != "") {}
} } else if (TripFeature.FeatureType >= 4) {
}else if(TripFeature.FeatureType>=4){
this.$alert('请点击更新行程特色','提示', { this.$confirm('是否更新行程特色?', '提示', {
confirmButtonText: '确定', confirmButtonText: '更新',
callback: action => { cancelButtonText: '不更新',
this.custormAnchor('thirdAnchor',3); type: 'warning'
this.isSubmit = true; }).then(() => {
} this.MsgBus.$emit('comUpTravel');
this.isSubmit = false;
}).catch(() => {
TripFeature.FeatureHtmlJson = this.FeatureHtmlJson;
TripFeature.FeatureHtmlJsonDelete = this.FeatureHtmlJsonDelete;
this.MsgBus.$emit('resetFresh');
this.custormAnchor('thirdAnchor', 3);
this.isSubmit = false;
}); });
return
} }
TripFeature.FeeInclude = this.PostNotice.FeeInclude; TripFeature.FeeInclude = this.PostNotice.FeeInclude;
TripFeature.FeeNonInclude = this.PostNotice.FeeNonInclude; TripFeature.FeeNonInclude = this.PostNotice.FeeNonInclude;
...@@ -389,8 +406,8 @@ ...@@ -389,8 +406,8 @@
if (SaveType == 3) { if (SaveType == 3) {
basicData.TravelInfoIsCopy = true; basicData.TravelInfoIsCopy = true;
} }
basicData.TeamType=this.TeamType; basicData.TeamType = this.TeamType;
basicData.IsUpdateHotel=this.PostConfig.IsUpdateHotel; basicData.IsUpdateHotel = this.PostConfig.IsUpdateHotel;
this.apipost( this.apipost(
"travel_post_SetTravelConfigInfo", "travel_post_SetTravelConfigInfo",
basicData, basicData,
...@@ -398,7 +415,7 @@ ...@@ -398,7 +415,7 @@
if (res.data.resultCode == 1) { if (res.data.resultCode == 1) {
//配置编号 //配置编号
TripFeature.ConfigId = res.data.data; TripFeature.ConfigId = res.data.data;
this.$refs.TravelFeature.getHtml(TripFeature, SaveType,this.TeamType); this.$refs.TravelFeature.getHtml(TripFeature, SaveType, this.TeamType);
this.$refs.TravelPrice.closeHotelDialog(); this.$refs.TravelPrice.closeHotelDialog();
this.$refs.TravelPrice.initStatus(); this.$refs.TravelPrice.initStatus();
} else if (res.data.resultCode == 10009) { } else if (res.data.resultCode == 10009) {
...@@ -419,7 +436,7 @@ ...@@ -419,7 +436,7 @@
//初始化团的幻灯片 //初始化团的幻灯片
initFileList() { initFileList() {
this.PostConfig.fileList=[]; this.PostConfig.fileList = [];
for (var i = 0; i < 5; i++) { for (var i = 0; i < 5; i++) {
var fileObj = this.$commonUtils.FileObject(); var fileObj = this.$commonUtils.FileObject();
this.PostConfig.fileList.push(fileObj); this.PostConfig.fileList.push(fileObj);
...@@ -584,14 +601,14 @@ ...@@ -584,14 +601,14 @@
}, },
firstLoadConfigInfo() { firstLoadConfigInfo() {
var routeName = this.$route.name; var routeName = this.$route.name;
if(routeName=='TravelManager2'){ if (routeName == 'TravelManager2') {
this.TeamType=0; this.TeamType = 0;
} }
if(routeName=='TravelManager3'){ if (routeName == 'TravelManager3') {
this.TeamType=1; this.TeamType = 1;
} }
if(routeName=='TravelManager4'){ if (routeName == 'TravelManager4') {
this.TeamType=2; this.TeamType = 2;
} }
let configId = this.$route.query.configId; let configId = this.$route.query.configId;
this.modifyTcid = this.$route.query.tcid; this.modifyTcid = this.$route.query.tcid;
...@@ -635,6 +652,10 @@ ...@@ -635,6 +652,10 @@
tempData.Feature.FeatureHtmlJsonDelete != "" && tempData.Feature.FeatureType > 3 ? tempData.Feature.FeatureHtmlJsonDelete != "" && tempData.Feature.FeatureType > 3 ?
JSON.parse(tempData.Feature.FeatureHtmlJsonDelete) : JSON.parse(tempData.Feature.FeatureHtmlJsonDelete) :
null; null;
this.FeatureHtmlJson = this.FeatureData.FeatureHtmlJson,
this.FeatureHtmlJsonDelete = this.FeatureData.FeatureHtmlJsonDelete,
this.NoticeData.FeeInclude = tempData.Feature.FeeInclude; this.NoticeData.FeeInclude = tempData.Feature.FeeInclude;
this.NoticeData.FeeNonInclude = tempData.Feature.FeeNonInclude; this.NoticeData.FeeNonInclude = tempData.Feature.FeeNonInclude;
this.NoticeData.ImportantTip = tempData.Feature.ImportantTip; this.NoticeData.ImportantTip = tempData.Feature.ImportantTip;
...@@ -666,8 +687,8 @@ ...@@ -666,8 +687,8 @@
this.PostConfig.CountryID = tempData.CountryID; this.PostConfig.CountryID = tempData.CountryID;
//视频地址 //视频地址
this.PostConfig.VideoStr = tempData.VideoStr; this.PostConfig.VideoStr = tempData.VideoStr;
this.PostConfig.OpenTeamDescribe=tempData.OpenTeamDescribe; this.PostConfig.OpenTeamDescribe = tempData.OpenTeamDescribe;
this.PostConfig.IsOpenHotel=tempData.IsOpenHotel; this.PostConfig.IsOpenHotel = tempData.IsOpenHotel;
this.NoticeParameters.ConfigId = tempData.ConfigId; this.NoticeParameters.ConfigId = tempData.ConfigId;
this.NoticeParameters.CountryID = tempData.CountryID; this.NoticeParameters.CountryID = tempData.CountryID;
......
...@@ -1750,6 +1750,14 @@ ...@@ -1750,6 +1750,14 @@
this.oldVal = JSON.parse(JSON.stringify(this.FeatureData)); this.oldVal = JSON.parse(JSON.stringify(this.FeatureData));
this.init() this.init()
} }
//调用初始化信息提示
var that = this;
that.MsgBus.$on('comUpTravel',function(){
that.UpDateInfo();
});
that.MsgBus.$on('resetFresh',function(){
that.Refresh=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