Commit a8817daf authored by 黄奎's avatar 黄奎

11

parent 17318a6a
......@@ -1053,6 +1053,7 @@
@click="goFncUrl('DebitNote', subItem.FinanceId)">{{$t('objFill.jiezhidan')}}</span></p>
</td>
<td width="80" class="_zhidan">
<template v-if="myLineId==90">
<div style="margin:10px 0" v-for="(cur,index2) in CurrencyListMoney">
<template v-for="leadr in cur.LeaderGetPriceArr" v-if=" leadr.TCNUMS == item.TCNUMS">
......@@ -1071,6 +1072,9 @@
<span style="color:red;" @click="GoCompanyAlipay(item)"> {{$t('objFill.v101.dmc.yikqqydf')}}</span>
</template>
</template>
<!-- <input type="button" value="变更报价单" class="normalBtn" @click="gotoOfferChange(leadr.OfferId)" /> -->
</div>
</template>
<template v-else>
......@@ -1098,6 +1102,7 @@
<template v-else-if="!item.hideZDBtn && index2==0">
<span>{{$t('objFill.chaoguowtsjxzwfzd')}}</span>
</template>
<!-- <input type="button" value="变更报价单" class="normalBtn" @click="gotoOfferChange(leadr.OfferId)" /> -->
</template>
</div>
</template>
......@@ -1760,8 +1765,20 @@
err => {}
);
},
//跳转报报价单
gotoOfferChange(offerId) {
if (offerId) {
this.$router.push({
name: 'OfferChange',
query: {
'offerid': offerId,
'Qtype': 3,
'blank': 'y',
}
});
}
},
ZhuiJiaTuanKuan(item) {
this.apipost('financestatistics_post_GetTravelPrerealContrast', {
TCID: item.TCIDS
}, res => {
......@@ -1773,14 +1790,7 @@
cancelButtonText: this.$t('pub.cancelBtn'),
type: 'warning'
}).then(() => {
this.$router.push({
name: 'OfferChange',
query: {
'offerid': res.data.data.OfferId,
'Qtype': 3,
'blank': 'y',
}
});
this.gotoOfferChange(res.data.data.OfferId);
}).catch(() => {
});
......@@ -1790,14 +1800,7 @@
cancelButtonText: this.$t('pub.cancelBtn'),
type: 'warning'
}).then(() => {
this.$router.push({
name: 'OfferChange',
query: {
'offerid': res.data.data.OfferId,
'Qtype': 3,
'blank': 'y',
}
});
this.gotoOfferChange(res.data.data.OfferId);
}).catch(() => {
});
......@@ -1916,14 +1919,7 @@
cancelButtonText: this.$t('pub.cancelBtn'),
type: 'warning'
}).then(() => {
this.$router.push({
name: 'OfferChange',
query: {
'offerid': res.data.data.OfferId,
'Qtype': 3,
'blank': 'y',
}
});
this.gotoOfferChange(res.data.data.OfferId)
}).catch(() => {
});
......@@ -1933,17 +1929,8 @@
cancelButtonText: this.$t('pub.cancelBtn'),
type: 'warning'
}).then(() => {
this.$router.push({
name: 'OfferChange',
query: {
'offerid': res.data.data.OfferId,
'Qtype': 3,
'blank': 'y',
}
});
}).catch(() => {
});
this.gotoOfferChange(res.data.data.OfferId)
}).catch(() => {});
}
} else {
this.goDiJieZhiDan(obj, num, leadr, cur);
......@@ -2342,7 +2329,8 @@
LeaderGetPriceT: 0,
ShowTotalPrice: 0,
TCNUMS: x.TCNUMS,
TCIDS: x.TCIDS
TCIDS: x.TCIDS,
OfferId: x.OfferId,
};
x.LeaderGetPriceList.forEach(price => {
if (cur.CurrencyId == price.CurrencyId) {
......@@ -3152,11 +3140,6 @@
border-collapse: collapse;
}
/* table.OtherExpensesList th:first {
border: 1px solid #ccc;
padding: 8px;
background-color: #dedede ;
} */
table.OtherExpensesList th {
border: 1px solid #ccc;
padding: 8px;
......
......@@ -155,15 +155,16 @@
<td class="CP_ComTitle2 CostcomCenter">{{$t('hotel.hotel_CurrentRate')}}</td>
<td v-for='(item,index) in CostCurrencyList' :key="index+20000" style=" white-space: nowrap;">
{{item.ExchangeRate}}
<template v-if="item.OtherChangeModel!=null"> <font style="color:red;">
<template v-if="item.OtherChangeModel!=null">
<font style="color:red;">
<template v-if="item.OtherChangeModel.HotelChangeValue>0">
+{{item.OtherChangeModel.HotelChangeValue}}
</template>
<template v-else>
{{item.OtherChangeModel.HotelChangeValue}}
</template>
</font></template>
</font>
</template>
<!-- </br><a v-if="IsEdit==3" style="color:blue;cursor:pointer"
@click="showOfferChange(3,item,index)">{{$t('objFill.dayofferchange')}}</a> -->
</td>
......@@ -174,18 +175,19 @@
<td class="CP_ComTitle2 CostcomCenter">{{$t('admin.admin_personNumber')}}</td>
<td v-for="(item,index) in CostNumberList" :key="index+30000">
{{item.PeopleNumber}}
<template v-if="item.OtherChangeModel!=null"> <font style="color:red;">
<template v-if="item.OtherChangeModel!=null">
<font style="color:red;">
<template v-if="item.OtherChangeModel.HotelChangeValue>0">
+{{item.OtherChangeModel.HotelChangeValue}}
</template>
<template v-else>
{{item.OtherChangeModel.HotelChangeValue}}
</template>
</font></template>
</font>
</template>
<!-- <br/>
<a v-if="IsEdit==3" style="color:blue;cursor:pointer"
@click="showOfferChange(3,item,index)">{{$t('objFill.dayofferchange')}}</a> -->
</td>
<td :colspan="13-2-CostNumberList.length+1">
</td>
......@@ -219,6 +221,7 @@
<td class="CP_ComTitle2 CostcomCenter" style="width:100px">{{$t('system.query_airName')}}</td>
<td class="CP_ComTitle2 CostcomCenter" style="width:100px">{{$t('Operation.Op_price')}}</td>
</tr>
<template v-for="(subItem,subIndex) in dayCostPrice">
<tr :key="subIndex+100000">
<td align="center">
......@@ -288,8 +291,16 @@
<template v-if="subItem.BreakfastName&&subItem.BreakfastName!=''">
{{$t('objFill.v101.zaocanmc')}}: {{subItem.BreakfastName}}<br />
</template>
<template v-if="subItem.LunchName&&subItem.LunchName!=''">
{{$t('objFill.v101.wucanmc')}}: {{subItem.LunchName}}<br />
<template
v-if="(subItem.LunchName&&subItem.LunchName!='')||(subItem.IsLunchChange&&subItem.LunchChangeContent!='')">
{{$t('objFill.v101.wucanmc')}}:
<font v-if="subItem.LunchName!=''"
:style="(subItem.IsLunchChange&&subItem.LunchChangeContent!='')?'text-decoration: line-through;':''">
{{subItem.LunchName}}</font>
<font v-if="subItem.IsLunchChange&&subItem.LunchChangeContent!=''" style="color:red;">
<br /> {{subItem.LunchChangeContent}}
</font>
<br />
<template v-if="subItem.LunchRealName&&subItem.LunchRealName!=''">
<font style="color:#106BAF;">{{$t('ground.zhenshimingcheng')}}:
<template v-if="subItem.LunchUrl&&subItem.LunchUrl!=''">
......@@ -301,8 +312,16 @@
</font><br />
</template>
</template>
<template v-if="subItem.DinnerName&&subItem.DinnerName!=''">
{{$t('objFill.v101.wancaimc')}}: {{subItem.DinnerName}}<br />
<template
v-if="(subItem.DinnerName&&subItem.DinnerName!='')||(subItem.IsDinnerChange&&subItem.DinnerChangeContent!='')">
{{$t('objFill.v101.wancaimc')}}:
<font v-if="subItem.DinnerName!=''"
:style="(subItem.IsDinnerChange&&subItem.DinnerChangeContent!='')?'text-decoration: line-through;':''">
{{subItem.DinnerName}}
</font>
<font v-if="subItem.IsDinnerChange&&subItem.DinnerChangeContent!=''" style="color:red;">
<br /> {{subItem.DinnerChangeContent}}
</font>
<template v-if="subItem.DinnerRealName&&subItem.DinnerRealName!=''">
<font style="color:#106BAF;">{{$t('ground.zhenshimingcheng')}}:
<template v-if="subItem.DinnerUrl&&subItem.DinnerUrl!=''">
......@@ -314,6 +333,7 @@
</font><br />
</template>
</template>
</td>
<td style="white-space:nowrap;">
<template v-if="subItem.BreakfastCostPrice>0||subItem.IsBreakfastChange">
......@@ -367,9 +387,13 @@
</td>
<td>
<template v-for="(childItem,childIndex) in subItem.ScenicList">
<template v-if="childItem.TicketId>0||childItem.TicketName!=''">
<template
v-if="(childItem.TicketName&&childItem.TicketName!='')||(childItem.NewTicketName&&childItem.NewTicketName!='')">
<font>
{{childIndex+1}}{{childItem.TicketName}}
{{childIndex+1}}
<font v-if="childItem.TicketName!=''" :style="(childItem.TicketCostPrice+childItem.NewTicketCostPrice==0)?'text-decoration: line-through;':''">{{childItem.TicketName}}</font>
<font v-if="childItem.NewTicketName&&childItem.NewTicketName!=''" style="color:red;">
{{childItem.NewTicketName}}</font>
</font>
<br />
</template>
......@@ -377,16 +401,23 @@
</td>
<td style="white-space:nowrap;">
<template v-for="(childItem,childIndex) in subItem.ScenicList">
<template v-if="childItem.TicketId>0||childItem.TicketName!=''">
<template
v-if="(childItem.TicketName&&childItem.TicketName!='')||(childItem.NewTicketName&&childItem.NewTicketName!='')">
<font>
{{childItem.TicketCostPrice}}
</font>
<font v-if="childItem.NewTicketCostPrice!=0" style="color:red;">
<template v-if="childItem.NewTicketCostPrice>0">
+
</template>
{{childItem.NewTicketCostPrice}}={{childItem.TicketCostPrice+childItem.NewTicketCostPrice}}
</font>
<br />
</template>
</template>
<template v-if="subItem.IsScenicChange">
<br />
{{subItem.ScenicCostPrice}}
小计: {{subItem.ScenicCostPrice}}
<el-tooltip class="item" effect="dark" :content="subItem.ScenicChangeRemark" placement="top-start">
<font style="color:red;">
<template v-if="subItem.ScenicChangeValue>0">
......@@ -525,7 +556,8 @@
</template>
</font>
=<font style="color:red">{{Number(getDayXiaoJi(1,2))+Number(getDayChangeXiaoJi(1,2))+Number(getRateChangeXiaoJi(1))}}</font>
=<font style="color:red">
{{Number(getDayXiaoJi(1,2))+Number(getDayChangeXiaoJi(1,2))+Number(getRateChangeXiaoJi(1))}}</font>
</template>
</td>
<!--车资小计-->
......@@ -550,7 +582,8 @@
</template>
</template>
</font>
=<font style="color:red">{{Number(getDayXiaoJi(2,2))+Number(getDayChangeXiaoJi(2,2))+Number(getRateChangeXiaoJi(2))}}</font>
=<font style="color:red">
{{Number(getDayXiaoJi(2,2))+Number(getDayChangeXiaoJi(2,2))+Number(getRateChangeXiaoJi(2))}}</font>
</template>
</td>
<!--餐小计-->
......@@ -575,7 +608,8 @@
</template>
</template>
</font>
=<font style="color:red">{{Number(getDayXiaoJi(4,2))+Number(getDayChangeXiaoJi(4,2))+Number(getRateChangeXiaoJi(4))}}</font>
=<font style="color:red">
{{Number(getDayXiaoJi(4,2))+Number(getDayChangeXiaoJi(4,2))+Number(getRateChangeXiaoJi(4))}}</font>
</template>
</td>
<!--门票小计-->
......@@ -600,7 +634,8 @@
</template>
</template>
</font>
=<font style="color:red">{{Number(getDayXiaoJi(3,2))+Number(getDayChangeXiaoJi(3,2))+Number(getRateChangeXiaoJi(3))}}</font>
=<font style="color:red">
{{Number(getDayXiaoJi(3,2))+Number(getDayChangeXiaoJi(3,2))+Number(getRateChangeXiaoJi(3))}}</font>
</template>
</td>
<!--其它费用小计-->
......@@ -625,7 +660,8 @@
</template>
</template>
</font>
=<font style="color:red;">{{Number(getDayXiaoJi(9,2))+Number(getDayChangeXiaoJi(9,2))+Number(getRateChangeXiaoJi(9))}}</font>
=<font style="color:red;">
{{Number(getDayXiaoJi(9,2))+Number(getDayChangeXiaoJi(9,2))+Number(getRateChangeXiaoJi(9))}}</font>
</template>
</td>
</tr>
......@@ -1005,14 +1041,16 @@
{{$t('fnc.a_heji')}}
</td>
<td>
{{subItem.PeopleNumber}}<template v-if="subItem.OtherChangeModel!=null"> <font style="color:red;">
{{subItem.PeopleNumber}}<template v-if="subItem.OtherChangeModel!=null">
<font style="color:red;">
<template v-if="subItem.OtherChangeModel.HotelChangeValue>0">
+{{subItem.OtherChangeModel.HotelChangeValue}}
</template>
<template v-else>
{{subItem.OtherChangeModel.HotelChangeValue}}
</template>
</font></template>
</font>
</template>
</td>
<td>
{{getDayXiaoJi(1,1)}}
......@@ -1078,7 +1116,8 @@
</td>
<td style="white-space:nowrap;">
{{getLocalJpyTotalMoney(subItem.PeopleNumber)}}
<template v-if="(getLocalJpyChangeTotalMoney(subItem.PeopleNumber)!=0||getPeopleNumJpyChangeTotalMoney(subItem))!=0">
<template
v-if="(getLocalJpyChangeTotalMoney(subItem.PeopleNumber)!=0||getPeopleNumJpyChangeTotalMoney(subItem))!=0">
<font style="color:red;">
<template v-if="getLocalJpyChangeTotalMoney(subItem.PeopleNumber)!=0">
<template v-if="getLocalJpyChangeTotalMoney(subItem.PeopleNumber)>0">
......@@ -1105,7 +1144,8 @@
<td colspan="2">
<template v-if="teamPrice&&teamPrice.SingleDMCPrice&&teamPrice.SingleDMCPrice>0">
{{teamPrice.SingleDMCPrice}}
<template v-if="(getLocalChangeTotalMoney(subItem.PeopleNumber)!=0||getPeopleNumberChangeTotalMoney(subItem))!=0">
<template
v-if="(getLocalChangeTotalMoney(subItem.PeopleNumber)!=0||getPeopleNumberChangeTotalMoney(subItem))!=0">
<font style="color:red;">
<template v-if="getLocalChangeTotalMoney(subItem.PeopleNumber)!=0">
<template v-if="getLocalChangeTotalMoney(subItem.PeopleNumber)>0">
......@@ -1131,7 +1171,8 @@
</template>
<template v-else-if="postConfig.LineId==14||postConfig.LineId==118">
{{getLocalTotalMoney(subItem.PeopleNumber)}}
<template v-if="(getLocalChangeTotalMoney(subItem.PeopleNumber)+getPeopleNumberChangeTotalMoney(subItem))!=0">
<template
v-if="(getLocalChangeTotalMoney(subItem.PeopleNumber)+getPeopleNumberChangeTotalMoney(subItem))!=0">
<font style="color:red;">
<template v-if="getLocalChangeTotalMoney(subItem.PeopleNumber)!=0">
<template v-if="getLocalChangeTotalMoney(subItem.PeopleNumber)>0">
......@@ -1157,7 +1198,8 @@
</template>
<template v-else-if="postConfig.LineId==168">
{{getLocalTotalMoney(subItem.PeopleNumber)}}
<template v-if="(getLocalChangeTotalMoney(subItem.PeopleNumber)+getPeopleNumberChangeTotalMoney(subItem))!=0">
<template
v-if="(getLocalChangeTotalMoney(subItem.PeopleNumber)+getPeopleNumberChangeTotalMoney(subItem))!=0">
<font style="color:red;">
<template v-if="getLocalChangeTotalMoney(subItem.PeopleNumber)!=0">
<template v-if="getLocalChangeTotalMoney(subItem.PeopleNumber)>0">
......@@ -1187,7 +1229,8 @@
</td>
<td colspan="2">
{{subItem.TotalMoney}}
<template v-if="(getLocalChangeTotalMoney(subItem.PeopleNumber))!=0||getPeopleNumberChangeTotalMoney(subItem)!=0||getChangeCostTotalMoney()!=0">
<template
v-if="(getLocalChangeTotalMoney(subItem.PeopleNumber))!=0||getPeopleNumberChangeTotalMoney(subItem)!=0||getChangeCostTotalMoney()!=0">
<font style="color:red;">
<template v-if="getLocalChangeTotalMoney(subItem.PeopleNumber)!=0">
<template v-if="getLocalChangeTotalMoney(subItem.PeopleNumber)>0">
......@@ -1228,7 +1271,9 @@
<template v-if="postConfig.OutBranchId==1245">
<template v-if="subItem.SaleList&&subItem.SaleList.length>0">
<template v-for="(tItem,tIndex) in subItem.SaleList">
<br/> <font :key="`s_`+subIndex+`t_`+tIndex" style="color:blue;">{{tItem.ItemName}}{{tItem.ItemPrice}}</font>
<br />
<font :key="`s_`+subIndex+`t_`+tIndex" style="color:blue;">
{{tItem.ItemName}}{{tItem.ItemPrice}}</font>
</template>
</template>
</template>
......@@ -1353,17 +1398,19 @@
</template>
</template>
<template v-for="(cItem,cIndex) in CostCurrencyList">
<template
v-if="cItem.OtherChangeModel!=null&&cItem.OtherChangeModel.HotelChangeValue!=0">
<template v-if="cItem.OtherChangeModel!=null&&cItem.OtherChangeModel.HotelChangeValue!=0">
<p :key="cIndex">{{cItem.CurrencyName}}
汇率:{{cItem.OtherChangeModel.HotelChangeRemark}} (<font style="color:red">{{cItem.OtherChangeModel.HotelChangeValue}}</font>)
汇率:{{cItem.OtherChangeModel.HotelChangeRemark}} (<font style="color:red">
{{cItem.OtherChangeModel.HotelChangeValue}}</font>)
<template v-if="CostNumberList!=null&&CostNumberList.length>0">
<template v-if="CostNumberList[cIndex]!=null&&CostNumberList[cIndex].Id>0">
<template
v-if="CostNumberList[cIndex].OtherChangeModel!=null&&CostNumberList[cIndex].OtherChangeModel.HotelChangeValue!=0">
人数{{CostNumberList[cIndex].PeopleNumber}}
{{CostNumberList[cIndex].OtherChangeModel.HotelChangeRemark}} (<font style="color:red">{{CostNumberList[cIndex].OtherChangeModel.HotelChangeValue>0?"+":""}}{{CostNumberList[cIndex].OtherChangeModel.HotelChangeValue}}</font>)
{{CostNumberList[cIndex].OtherChangeModel.HotelChangeRemark}} (<font style="color:red">
{{CostNumberList[cIndex].OtherChangeModel.HotelChangeValue>0?"+":""}}{{CostNumberList[cIndex].OtherChangeModel.HotelChangeValue}}
</font>)
</template>
</template>
......@@ -1372,11 +1419,11 @@
</template>
</template>
<template v-for="(cItem,cIndex) in OtherChangeList">
<template
v-if="cItem.IsChange">
<template v-if="cItem.IsChange">
<p :key="cIndex">其它成本(人民币)
<template >
{{getChangeTypeText(cItem.ChangeType)}}{{cItem.HotelChangeRemark}} (<font style="color:red">{{cItem.HotelChangeValue}}</font>)
<template>
{{getChangeTypeText(cItem.ChangeType)}}{{cItem.HotelChangeRemark}} (<font style="color:red">
{{cItem.HotelChangeValue}}</font>)
</template>
</p>
</template>
......@@ -1411,20 +1458,27 @@
</div>
<template v-if="changMsg.EditType==3">
<el-dialog custom-class='w1006' :title="dialogDiningTitle" :visible.sync="changMsg.isShowChangeOffer" center modal>
<changeOfferExchangeRate v-if="changMsg.isShowChangeOffer" :OfferCurrency="changMsg" :costNumberList="CostNumberList" :costCurrencyList="CostCurrencyList" @success="refreshPage" @closeDialog="closeDialog">
<el-dialog custom-class='w1006' :title="dialogDiningTitle" :visible.sync="changMsg.isShowChangeOffer" center
modal>
<changeOfferExchangeRate v-if="changMsg.isShowChangeOffer" :OfferCurrency="changMsg"
:costNumberList="CostNumberList" :costCurrencyList="CostCurrencyList" @success="refreshPage"
@closeDialog="closeDialog">
</changeOfferExchangeRate>
</el-dialog>
</template>
<template v-else-if="changMsg.EditType==4">
<el-dialog custom-class='w1006' :title="dialogDiningTitle" :visible.sync="changMsg.isShowChangeOffer" center modal>
<changeOfferOtherCost v-if="changMsg.isShowChangeOffer" :OfferCurrency="changMsg" :otherPrice="OtherPrice" :teamPrice="teamPrice" @success="refreshPage" @closeDialog="closeDialog">
<el-dialog custom-class='w1006' :title="dialogDiningTitle" :visible.sync="changMsg.isShowChangeOffer" center
modal>
<changeOfferOtherCost v-if="changMsg.isShowChangeOffer" :OfferCurrency="changMsg" :otherPrice="OtherPrice"
:teamPrice="teamPrice" @success="refreshPage" @closeDialog="closeDialog">
</changeOfferOtherCost>
</el-dialog>
</template>
<template v-else>
<el-dialog custom-class='w1006' :title="dialogDiningTitle" :visible.sync="changMsg.isShowChangeOffer" center modal>
<changeOffer v-if="changMsg.isShowChangeOffer" :qMsg="changMsg" @success="refreshPage" @closeDialog="closeDialog">
<el-dialog custom-class='w1006' :title="dialogDiningTitle" :visible.sync="changMsg.isShowChangeOffer" center
modal>
<changeOffer v-if="changMsg.isShowChangeOffer" :qMsg="changMsg" @success="refreshPage"
@closeDialog="closeDialog">
</changeOffer>
</el-dialog>
</template>
......@@ -1441,7 +1495,7 @@
return {
AduitMsg: {}, //审核信息
OtherPrice: {},
OtherChangeList:[],
OtherChangeList: [],
dayCostPrice: [],
CostCurrencyList: [],
CostNumberList: [],
......@@ -1479,8 +1533,8 @@
},
components: {
changeOffer: changeOffer,
changeOfferExchangeRate:changeOfferExchangeRate,
changeOfferOtherCost:changeOfferOtherCost,
changeOfferExchangeRate: changeOfferExchangeRate,
changeOfferOtherCost: changeOfferOtherCost,
},
methods: {
switchOffer(dateStr) {
......@@ -1498,7 +1552,7 @@
})
if (selectOfferObj) {
this.OtherPrice = selectOfferObj.otherPrice;
this.OtherChangeList=selectOfferObj.otherChangeList;
this.OtherChangeList = selectOfferObj.otherChangeList;
this.teamPrice = selectOfferObj.teamPrice;
this.CostNumberList = selectOfferObj.CostNumberList;
this.offerDataObj = selectOfferObj;
......@@ -1525,19 +1579,16 @@
/**
* EditType:1-行程相关变更,2-基础数据变更,3-汇率/人数,4-其他成本变更
*/
showOfferChange(EditType, item,index) {
showOfferChange(EditType, item, index) {
this.changMsg.isShowChangeOffer = true;
this.changMsg.OfferId = item.OfferId;
this.changMsg.EditType = EditType;
if(EditType==3){
if (EditType == 3) {
this.dialogDiningTitle = "汇率/人数变更"
var costCurrency=this.CostCurrencyList[index];
}
else if(EditType==4)
{
var costCurrency = this.CostCurrencyList[index];
} else if (EditType == 4) {
this.dialogDiningTitle = "其他成本变更"
}
else{
} else {
this.dialogDiningTitle = "报价单变更"
if (item && item.DayNum) {
this.changMsg.DayNum = item.DayNum;
......@@ -1576,7 +1627,7 @@
getDayXiaoJi(type, currencyType) {
var xiaoJi = 0;
if (this.dayCostPrice && this.dayCostPrice.length > 0) {
this.dayCostPrice.forEach((item,index) => {
this.dayCostPrice.forEach((item, index) => {
var currencyRate = 1;
if (currencyType == 2) {
currencyRate = this.getCurrencyMoney(item.CurrencyId);
......@@ -1669,10 +1720,11 @@
//获取汇率/人数变更合计
getRateChangeXiaoJi(type) {
var xiaoJi = 0;
if(this.CostCurrencyList && this.CostCurrencyList.length > 0 && this.dayCostPrice && this.dayCostPrice.length > 0) {
if (this.CostCurrencyList && this.CostCurrencyList.length > 0 && this.dayCostPrice && this.dayCostPrice.length >
0) {
this.CostCurrencyList.forEach(currency => {
if(currency.OtherChangeModel!=null&&currency.OtherChangeModel.HotelChangeValue!=0){
if (currency.OtherChangeModel != null && currency.OtherChangeModel.HotelChangeValue != 0) {
var currencyRate = currency.OtherChangeModel.HotelChangeValue;
// 查找 dayCostPrice 中 CurrencyId 匹配当前 currency 的项
const matchedItems = this.dayCostPrice.filter(item => item.CurrencyId === currency.CurrencyId);
......@@ -1680,51 +1732,51 @@
matchedItems.forEach(item => {
//酒店
if (type == 1) {
var hotelPrice=Number(item.HotelCostPrice);
var hotelPrice = Number(item.HotelCostPrice);
if (item.IsHotelChange) {
hotelPrice += Number(item.HotelChangeValue) ;
hotelPrice += Number(item.HotelChangeValue);
}
xiaoJi += Number(hotelPrice)* Number(currencyRate);
xiaoJi += Number(hotelPrice) * Number(currencyRate);
}
//车
if (type == 2) {
var busPrice=Number(item.BusCostPrice);
var busPrice = Number(item.BusCostPrice);
if (item.IsBusChange) {
busPrice += Number(item.BusChangeValue) ;
busPrice += Number(item.BusChangeValue);
}
xiaoJi += Number(item.PassFee) * Number(currencyRate);
xiaoJi += Number(busPrice)* Number(currencyRate);
xiaoJi += Number(busPrice) * Number(currencyRate);
}
//景点
if (type == 3) {
var scenicPrice=Number(item.ScenicCostPrice);
var scenicPrice = Number(item.ScenicCostPrice);
if (item.IsScenicChange) {
scenicPrice += Number(item.ScenicChangeValue) ;
scenicPrice += Number(item.ScenicChangeValue);
}
xiaoJi += Number(scenicPrice)* Number(currencyRate);
xiaoJi += Number(scenicPrice) * Number(currencyRate);
}
//早餐
if (type == 4) {
var breakfastPrice=Number(item.BreakfastCostPrice);
var breakfastPrice = Number(item.BreakfastCostPrice);
if (item.IsBreakfastChange) {
breakfastPrice += Number(item.BreakfastChangeValue) ;
breakfastPrice += Number(item.BreakfastChangeValue);
}
xiaoJi += Number(breakfastPrice) * Number(currencyRate);
var lunchPrice=Number(item.LunchCostPrice) ;
var lunchPrice = Number(item.LunchCostPrice);
if (item.IsLunchChange) {
lunchPrice += Number(item.LunchChangeValue) ;
lunchPrice += Number(item.LunchChangeValue);
}
xiaoJi += Number(lunchPrice) * Number(currencyRate);
var dinnerPrice=Number(item.DinnerCostPrice) ;
var dinnerPrice = Number(item.DinnerCostPrice);
if (item.IsDinnerChange) {
dinnerPrice += Number(item.DinnerChangeValue) ;
dinnerPrice += Number(item.DinnerChangeValue);
}
xiaoJi += Number(dinnerPrice) * Number(currencyRate);
}
if (type == 9) {
var otherPrice=Number(item.OtherPrice) ;
var otherPrice = Number(item.OtherPrice);
if (item.IsOtherChange) {
otherPrice += Number(item.OtherChangeValue) ;
otherPrice += Number(item.OtherChangeValue);
}
xiaoJi += Number(otherPrice) * Number(currencyRate)
}
......@@ -1754,9 +1806,9 @@
getChangeCostTotalMoney() {
let totalMoney = 0.0;
//机票+中段机票+税金+领队导游分摊+联运+过夜+保险
if(this.OtherChangeList!=null&&this.OtherChangeList.length>0){
if (this.OtherChangeList != null && this.OtherChangeList.length > 0) {
this.OtherChangeList.forEach(item => {
totalMoney+=Number(this.getConvertMoney(item.HotelChangeValue) )
totalMoney += Number(this.getConvertMoney(item.HotelChangeValue))
});
}
return totalMoney.toFixed(2);
......@@ -1794,8 +1846,8 @@
let currency = 1;
this.CostCurrencyList.forEach(x => {
if (x.CurrencyId == currencyId) {
if(x.OtherChangeModel!=null&&x.OtherChangeModel.HotelChangeValue!=0)
currency = x.ExchangeRate+x.OtherChangeModel.HotelChangeValue;
if (x.OtherChangeModel != null && x.OtherChangeModel.HotelChangeValue != 0)
currency = x.ExchangeRate + x.OtherChangeModel.HotelChangeValue;
}
});
return currency;
......@@ -1875,15 +1927,14 @@
//地接成本(日元)
getPeopleNumJpyChangeTotalMoney(subItem) {
let totalMoney = 0.0;
var peopleNumber=Number(subItem.PeopleNumber);
if(subItem.OtherChangeModel!=null&&subItem.OtherChangeModel.HotelChangeValue!=0){
peopleNumber+=Number(subItem.OtherChangeModel.HotelChangeValue);
var peopleNumber = Number(subItem.PeopleNumber);
if (subItem.OtherChangeModel != null && subItem.OtherChangeModel.HotelChangeValue != 0) {
peopleNumber += Number(subItem.OtherChangeModel.HotelChangeValue);
var busFee = Number(this.getDayXiaoJi(2, 1)) / peopleNumber;
var otherPrice = Number(this.getDayXiaoJi(9, 1)) / peopleNumber; //其它费用
totalMoney = busFee + otherPrice;//hotelPrice + sencePrice + canPrice +
if(subItem.OtherChangeModel.HotelChangeValue>0){
totalMoney=Number(totalMoney)*Number(-1);
totalMoney = busFee + otherPrice; //hotelPrice + sencePrice + canPrice +
if (subItem.OtherChangeModel.HotelChangeValue > 0) {
totalMoney = Number(totalMoney) * Number(-1);
}
}
return totalMoney.toFixed(2);
......@@ -1895,24 +1946,23 @@
var sencePrice = Number(this.getRateChangeXiaoJi(3)); //景点费用
var canPrice = Number(this.getRateChangeXiaoJi(4)); //餐
var otherPrice = Number(this.getRateChangeXiaoJi(9)) / Number(subItem.PeopleNumber); //其它费用
var busFee = Number(this.getRateChangeXiaoJi(2)) /Number(subItem.PeopleNumber); //车费
var busFee = Number(this.getRateChangeXiaoJi(2)) / Number(subItem.PeopleNumber); //车费
totalMoney = busFee + hotelPrice + sencePrice + canPrice + otherPrice;
var peopleNumber=subItem.PeopleNumber;
var peopleNumber = subItem.PeopleNumber;
if (subItem.PeopleNumber <= 0) {
peopleNumber = 1;
}
//人数的变更
if(subItem.OtherChangeModel!=null&&subItem.OtherChangeModel.HotelChangeValue!=0){
peopleNumber+=Number(subItem.OtherChangeModel.HotelChangeValue);
console.log(peopleNumber,"otherPrice",this.getRateChangeXiaoJi(9));
console.log(peopleNumber,"busFee",this.getRateChangeXiaoJi(2));
if(subItem.OtherChangeModel.HotelChangeValue>0){
if (subItem.OtherChangeModel != null && subItem.OtherChangeModel.HotelChangeValue != 0) {
peopleNumber += Number(subItem.OtherChangeModel.HotelChangeValue);
// console.log(peopleNumber, "otherPrice", this.getRateChangeXiaoJi(9));
// console.log(peopleNumber, "busFee", this.getRateChangeXiaoJi(2));
if (subItem.OtherChangeModel.HotelChangeValue > 0) {
totalMoney -= Number(this.getRateChangeXiaoJi(9)) / Number(peopleNumber); //其它费用
totalMoney -= Number(this.getRateChangeXiaoJi(2)) /Number(peopleNumber); //车费
}
else{
totalMoney -= Number(this.getRateChangeXiaoJi(2)) / Number(peopleNumber); //车费
} else {
totalMoney += Number(this.getRateChangeXiaoJi(9)) / Number(peopleNumber); //其它费用
totalMoney += Number(this.getRateChangeXiaoJi(2)) /Number(peopleNumber); //车费
totalMoney += Number(this.getRateChangeXiaoJi(2)) / Number(peopleNumber); //车费
}
}
return totalMoney.toFixed(2);
......
......@@ -15,11 +15,20 @@
<CostNewPriceAudit v-if="haveData" ref="CostNewPrice" :postConfig="postData" :OfferArray="OfferArray"
:IsEdit="IsEdit" @success="refreshPage"></CostNewPriceAudit>
</div>
<div class="btnFixedDiv" v-if="haveData">
<div class="toTop">
<i class="iconfont icon-huidaodingbu"></i>
</div>
<div class="DTSaveBtn" :class="{'disClick':!isSubmit}" @click="SaveData(2)">{{$t('fnc.tijiao')}}</div>
<div class="btnFixedDiv" v-if="haveData" style="margin:0 auto;">
<el-button @click="SaveData(2)" :loading="saveLoading"
style="background-color:#ffc2c2;color:#cc1212;font-size:12px;margin-left:7px;margin-top:10px;border:none;width:45px;height:45px;padding:0;">
{{$t('fnc.tijiao')}}
</el-button>
<template v-if="IsEdit==3">
<br />
<el-tooltip class="item" effect="dark" content="根据地接数据更新报价单" placement="top">
<el-button :loading="saveLoading" @click="ReCalcOffer()"
style="background-color:#ffc2c2;color:#cc1212;font-size:12px;margin-left:7px;margin-top:5px; border:none;width:45px;height:45px;padding:0;padding-top:10px;">
更新
</el-button>
</el-tooltip>
</template>
</div>
</div>
</template>
......@@ -80,28 +89,52 @@
AssistantList: [], //助理OP
PriceTeamType: 0, //团队类型,
PriceTeamTypeName: "", //团队类型,
OfferArray:[],
OfferArray: [],
OfferId: 0,
},
pMsg: {
offerId: 0,
// BatchNum: "",
},
isSubmit: true,
loading: false,
IsEdit: 0,
saveLoading: false,
};
},
methods: {
ReCalcOffer() {
this.saveLoading = true;
var newMsg = {
OfferId: this.pMsg.offerId,
}
this.apipost(
"travel_post_CalcChangeOffer", newMsg,
res => {
this.saveLoading = false;
if (res.data.resultCode == 1) {
this.Success(res.data.message);
this.getPostData();
} else {
this.Error(res.data.message);
}
},
err => {
this.saveLoading = false;
}
);
},
//保存数据
SaveData(Type) {
this.saveLoading = true;
var nObj = {
offerid:this.pMsg.offerId,
offerid: this.pMsg.offerId,
};
this.loading = true;
this.apipost(
"travel_post_SetOfferChangeAudit", nObj,
res => {
this.loading = false;
this.saveLoading = false;
if (res.data.resultCode == 1) {
this.Success(res.data.message);
this.goUrl('newQuotation');
......@@ -134,9 +167,13 @@
this.loading = false;
if (res.data.resultCode == 1) {
var tempData = res.data.data;
console.log("travel_get_PriceOfferInfo",tempData);
if (tempData.ID && tempData.ID > 0) {
this.postData.ID = tempData.ID;
}
if (tempData.OfferId && tempData.OfferId > 0) {
this.postData.OfferId = tempData.OfferId;
}
if (tempData.LineId && tempData.LineId > 0) {
this.postData.LineId = tempData.LineId;
}
......
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