Commit a8a63470 authored by 黄奎's avatar 黄奎

新增页面

parent 32ce666e
......@@ -23,6 +23,12 @@
white-space: nowrap;
}
.QuotationPrice_SWT .link {
cursor: pointer;
color: blue;
text-decoration: underline;
}
</style>
<template>
<div class="QuotationPrice_SWT clearfix" v-loading="loading">
......@@ -100,7 +106,7 @@
<template v-if="postData.SWTFlightList&&postData.SWTFlightList.length>=1">
<el-input v-model="postData.SWTFlightList[0].flightContent" placeholder="航班信息"></el-input>
</template>
<a @click="AddFlight()">添加航班</a>
<a @click="AddFlight()" class="link">添加航班</a>
</td>
</tr>
<tr>
......@@ -132,7 +138,7 @@
<el-input v-model="postData.SWTFlightList[1].flightContent" placeholder="航班信息"></el-input>
</template>
<template v-if="postData.SWTFlightList&&postData.SWTFlightList.length>=2">
<a @click="DeleteFlight(1)">删除</a>
<a @click="DeleteFlight(1)" class="link">删除</a>
</template>
</td>
</tr>
......@@ -164,7 +170,7 @@
<el-input v-model="postData.SWTFlightList[2].flightContent" placeholder="航班信息"></el-input>
</template>
<template v-if="postData.SWTFlightList&&postData.SWTFlightList.length>=3">
<a @click="DeleteFlight(2)">删除</a>
<a @click="DeleteFlight(2)" class="link">删除</a>
</template>
</td>
</tr>
......@@ -204,7 +210,7 @@
<el-input v-model="postData.SWTFlightList[3].flightContent" placeholder="航班信息"></el-input>
</template>
<template v-if="postData.SWTFlightList&&postData.SWTFlightList.length>=4">
<a @click="DeleteFlight(3)">删除</a>
<a @click="DeleteFlight(3)" class="link">删除</a>
</template>
</td>
</tr>
......@@ -225,7 +231,7 @@
<el-input v-model="postData.SWTFlightList[4].flightContent" placeholder="航班信息"></el-input>
</template>
<template v-if="postData.SWTFlightList&&postData.SWTFlightList.length>=5">
<a @click="DeleteFlight(4)">删除</a>
<a @click="DeleteFlight(4)" class="link">删除</a>
</template>
</td>
</tr>
......@@ -246,7 +252,7 @@
<el-input v-model="postData.SWTFlightList[5].flightContent" placeholder="航班信息"></el-input>
</template>
<template v-if="postData.SWTFlightList&&postData.SWTFlightList.length>=6">
<a @click="DeleteFlight(5)">删除</a>
<a @click="DeleteFlight(5)" class="link">删除</a>
</template>
</td>
</tr>
......@@ -302,7 +308,7 @@
</td>
<td>
<el-input v-model="postData.HotelDisNum"
@keyup.native="checkInteger(postData,'HotelDisNum'),GetHotelCalc()" placeholder="酒店減免" maxlength="2">
@keyup.native="checkInteger(postData,'HotelDisNum'),CalcFeeTotal()" placeholder="酒店減免" maxlength="2">
</el-input>
</td>
<td>
......@@ -340,7 +346,7 @@
</td>
<td>
<el-select v-model="hItem.HotelId" class='w200' filterable :placeholder="$t('pub.pleaseSel')"
@visible-change="GetHotelList($event,hItem)" @change="GetHotelItem(hItem),GetHotelCalc()">
@visible-change="GetHotelList($event,hItem)" @change="GetHotelItem(hItem),CalcFeeTotal()">
<el-option :label="$t('pub.unlimitedSel')" :value='0'></el-option>
<el-option v-for="(subItem,subIndex) in hItem.HotelList" :value="subItem.ID" :label="subItem.Name"
:key="subIndex"></el-option>
......@@ -348,15 +354,15 @@
</td>
<td>
<el-input v-model="hItem.USPrice" maxlength="10"
@keyup.native="checkPrice(hItem,'USPrice'),GetHotelCalc()" placeholder="美金"></el-input>
@keyup.native="checkPrice(hItem,'USPrice'),CalcFeeTotal()" placeholder="美金"></el-input>
</td>
<td>
<el-input v-model="hItem.VNDPrice" maxlength="10"
@keyup.native="checkPrice(hItem,'VNDPrice'),GetHotelCalc()" placeholder="越盾">
@keyup.native="checkPrice(hItem,'VNDPrice'),CalcFeeTotal()" placeholder="越盾">
</el-input>
</td>
<td>
<el-input v-model="hItem.Times" @keyup.native="checkInteger(hItem,'Times'),GetHotelCalc()"
<el-input v-model="hItem.Times" @keyup.native="checkInteger(hItem,'Times'),CalcFeeTotal()"
placeholder="次/N數" maxlength="1"></el-input>
</td>
<td>
......@@ -413,7 +419,7 @@
</td>
<td>
<el-input v-model="postData.DinnerDisNum"
@keyup.native="checkInteger(postData,'DinnerDisNum'),GetDinnerCalc()" placeholder="餐食減免" maxlength="2">
@keyup.native="checkInteger(postData,'DinnerDisNum'),CalcFeeTotal()" placeholder="餐食減免" maxlength="2">
</el-input>
</td>
<td>
......@@ -463,7 +469,7 @@
<td>
<el-select v-model="childItem.DinnerId" class='w200' filterable :placeholder="$t('pub.pleaseSel')"
@visible-change="GetDinnerList($event,subItem,childItem)"
@change="GetDinnerItem(childItem),GetDinnerCalc()">
@change="GetDinnerItem(childItem),CalcFeeTotal()">
<el-option :label="$t('pub.unlimitedSel')" :value='0'></el-option>
<el-option v-for="(qitem,qindex) in childItem.DinnerList" :value="qitem.ID" :label="qitem.Name"
:key="qindex"></el-option>
......@@ -471,21 +477,20 @@
</td>
<td>
<el-input v-model="childItem.USPrice" maxlength="10"
@keyup.native="checkPrice(childItem,'USPrice'),GetDinnerCalc()" placeholder="美金"></el-input>
@keyup.native="checkPrice(childItem,'USPrice'),CalcFeeTotal()" placeholder="美金"></el-input>
</td>
<td>
<el-input v-model="childItem.VNDPrice" maxlength="10"
@keyup.native="checkPrice(childItem,'VNDPrice'),GetDinnerCalc()" placeholder="越盾">
@keyup.native="checkPrice(childItem,'VNDPrice'),CalcFeeTotal()" placeholder="越盾">
</el-input>
</td>
<td>
<el-input v-model="childItem.Times" @keyup.native="checkInteger(childItem,'Times'),GetDinnerCalc()"
<el-input v-model="childItem.Times" @keyup.native="checkInteger(childItem,'Times'),CalcFeeTotal()"
placeholder="次/N數" maxlength="1"></el-input>
</td>
<td>
{{childItem.TotalNum}}/ {{childItem.FOCNum}}
</td>
<td>
{{childItem.DinnerDisNum}}
</td>
......@@ -538,7 +543,7 @@
</td>
<td>
<el-input v-model="postData.TicketDisNum"
@keyup.native="checkInteger(postData,'TicketDisNum'),GetScenicCalc()" placeholder="景點減免" maxlength="2">
@keyup.native="checkInteger(postData,'TicketDisNum'),CalcFeeTotal()" placeholder="景點減免" maxlength="2">
</el-input>
</td>
<td>
......@@ -583,7 +588,7 @@
</template>
<el-select v-model="childItem.CouponsId" class='w200' filterable :placeholder="$t('pub.pleaseSel')"
@visible-change="GetScenicList($event,subItem,childItem)"
@change="GetScenicItem(childItem),GetScenicCalc()">
@change="GetScenicItem(childItem),CalcFeeTotal()">
<el-option :label="$t('pub.unlimitedSel')" :value='0'></el-option>
<el-option v-for="(qitem,qindex) in childItem.TicketList" :value="qitem.ID" :label="qitem.Name"
:key="qindex"></el-option>
......@@ -591,15 +596,15 @@
</td>
<td>
<el-input v-model="childItem.USPrice" maxlength="10"
@keyup.native="checkPrice(childItem,'USPrice'),GetScenicCalc()" placeholder="美金"></el-input>
@keyup.native="checkPrice(childItem,'USPrice'),CalcFeeTotal()" placeholder="美金"></el-input>
</td>
<td>
<el-input v-model="childItem.VNDPrice" maxlength="10"
@keyup.native="checkPrice(childItem,'VNDPrice'),GetScenicCalc()" placeholder="越盾">
@keyup.native="checkPrice(childItem,'VNDPrice'),CalcFeeTotal()" placeholder="越盾">
</el-input>
</td>
<td>
<el-input v-model="childItem.Times" @keyup.native="checkInteger(childItem,'Times'),GetScenicCalc()"
<el-input v-model="childItem.Times" @keyup.native="checkInteger(childItem,'Times'),CalcFeeTotal()"
placeholder="次/N數" maxlength="1"></el-input>
</td>
<td>
......@@ -702,7 +707,7 @@
</template>
<el-select v-model="childItem.BusConfigId" class='w200' filterable :placeholder="$t('pub.pleaseSel')"
@visible-change="GetBusConfigList($event,subItem,childItem)"
@change="GetBusItem(childItem),GetBusCalc()">
@change="GetBusItem(childItem),CalcFeeTotal()">
<el-option :label="$t('pub.unlimitedSel')" :value='0'></el-option>
<el-option v-for="(qitem,qindex) in childItem.BusList" :value="qitem.Id" :label="qitem.Trip"
:key="qindex"></el-option>
......@@ -710,20 +715,20 @@
</td>
<td>
<el-input v-model="childItem.Kilometre" maxlength="10"
@keyup.native="checkInteger(childItem,'Kilometre')" placeholder="公里數"></el-input>
@keyup.native="checkInteger(childItem,'Kilometre'),CalcFeeTotal()" placeholder="公里數"></el-input>
</td>
<td>
<el-input v-model="childItem.VNDPrice" maxlength="10"
@keyup.native="checkPrice(childItem,'VNDPrice'),GetBusCalc()" placeholder="越盾">
@keyup.native="checkPrice(childItem,'VNDPrice'),CalcFeeTotal()" placeholder="越盾">
</el-input>
</td>
<td>
<el-input v-model="childItem.Times" @keyup.native="checkInteger(childItem,'Times'),GetBusCalc()"
placeholder="次/N數" maxlength="1"></el-input>
<el-input v-model="childItem.Times" @keyup.native="checkInteger(childItem,'Times'),CalcFeeTotal()"
placeholder="次/N數" maxlength="10"></el-input>
</td>
<td>
<el-input v-model="childItem.Price" @keyup.native="checkPrice(childItem,'Price'),GetBusCalc()"
placeholder="次/N數" maxlength="1"></el-input>
<el-input v-model="childItem.Price" @keyup.native="checkPrice(childItem,'Price'),CalcFeeTotal()"
placeholder="次/N數" maxlength="10"></el-input>
</td>
<td colspan="2">
{{childItem.VNDSubTotal}}
......@@ -752,146 +757,482 @@
</tr>
</tbody>
<tbody title="船導遊機票">
<tbody title="船導遊機票">
<tr>
<td colspan="10">
</td>
</tr>
<tr>
<td colspan="7">
船 或 導遊機票
船或導遊機票 <a class="link" @click="AddBaoJiaConfigItem(4)">添加</a>
</td>
<td>
</td>
<td>
</td>
<td>
</td>
</tr>
<tr>
<td colspan="2">
</td>
<td class="ComTitle" colspan="2">
名称
</td>
<td class="ComTitle">
美金
</td>
<td class="ComTitle">
越南盾
</td>
<td class="ComTitle">
次/N數
</td>
<td class="ComTitle">
</td>
<td class="ComTitle" colspan="2">
合计
</td>
</tr>
<template v-for="(childItem,childIndex) in postData.SWTShipList">
<tr :key="childIndex">
<td colspan="2">
</td>
<td colspan="2">
<a class="link" @click="DeleteBaoJiaConfigItem(4,childIndex)">删除</a>
<el-select v-model="childItem.BaoJiaConfigId" class='w200' filterable :placeholder="$t('pub.pleaseSel')"
@change="GetConfigItem(childItem,4),CalcFeeTotal()">
<el-option :label="$t('pub.unlimitedSel')" :value='0'></el-option>
<el-option v-for="(qitem,qindex) in ShipList" :value="qitem.Id" :label="qitem.CName" :key="qindex">
</el-option>
</el-select>
</td>
<td>
<el-input v-model="childItem.USPrice" maxlength="10"
@keyup.native="checkPrice(childItem,'USPrice'),CalcFeeTotal()" placeholder="美金"></el-input>
</td>
<td>
<el-input v-model="childItem.VNDPrice" maxlength="10"
@keyup.native="checkPrice(childItem,'VNDPrice'),CalcFeeTotal()" placeholder="越盾">
</el-input>
</td>
<td>
<el-input v-model="childItem.Times" @keyup.native="checkInteger(childItem,'Times'),CalcFeeTotal()"
placeholder="次/N數" maxlength="1"></el-input>
</td>
<td>
{{childItem.TotalNum}}
</td>
<td>
{{childItem.USSubTotal}}
</td>
<td>
{{childItem.VNDSubTotal}}
</td>
</tr>
</template>
</tbody>
<tbody title="船合计">
<tr>
<td colspan="2">
</td>
<td colspan="2">
</td>
<td>
US合計:{{ShipSum.USPriceSum}}
</td>
<td>
VND合計:{{ShipSum.VNDPriceSum}}
</td>
<td class="ComTitle">
車資
<td>
</td>
<td>
</td>
<td>
{{ShipSum.USTotalSum}}
</td>
<td>
{{ShipSum.VNDTotalSum}}
</td>
</tr>
</tbody>
<tbody title="雜支">
<tr>
<td colspan="10">
</td>
</tr>
<tr>
<td colspan="7">
雜支 <a class="link" @click="AddBaoJiaConfigItem(1)">添加</a>
</td>
<td>
</td>
<td>
</td>
<td>
</td>
</tr>
<tr>
<td colspan="2">
</td>
<td class="ComTitle">
行程
名称
</td>
<td class="ComTitle">
公里數
美金
</td>
<td class="ComTitle">
車資
越南盾
</td>
<td class="ComTitle">
次/N數
</td>
<td class="ComTitle">
單價
</td>
<td class="ComTitle">
FOC
</td>
<td class="ComTitle" colspan="2">
合计
</td>
</tr>
<template v-for="(childItem,childIndex) in postData.SWTOtherPayList">
<tr :key="childIndex">
<td colspan="2">
</td>
<td>
<a class="link" @click="DeleteBaoJiaConfigItem(1,childIndex)">删除</a>
<el-select v-model="childItem.BaoJiaConfigId" class='w200' filterable :placeholder="$t('pub.pleaseSel')"
@change="GetConfigItem(childItem,1),CalcFeeTotal()">
<el-option :label="$t('pub.unlimitedSel')" :value='0'></el-option>
<el-option v-for="(qitem,qindex) in ZaZhiList" :value="qitem.Id" :label="qitem.CName" :key="qindex">
</el-option>
</el-select>
</td>
<td>
<el-input v-model="childItem.USPrice" maxlength="10"
@keyup.native="checkPrice(childItem,'USPrice'),CalcFeeTotal()" placeholder="美金"></el-input>
</td>
<td>
<el-input v-model="childItem.VNDPrice" maxlength="10"
@keyup.native="checkPrice(childItem,'VNDPrice'),CalcFeeTotal()" placeholder="越盾">
</el-input>
</td>
<td>
{{childItem.DayNum}}
</td>
<td>
<el-input v-model="childItem.Times" @keyup.native="checkInteger(childItem,'Times'),CalcFeeTotal()"
placeholder="次/N數" maxlength="1"></el-input>
</td>
<td>
<el-input v-model="childItem.FOCNum" @keyup.native="checkInteger(childItem,'FOCNum'),CalcFeeTotal()"
placeholder="FOC" maxlength="1"></el-input>
</td>
<td>
{{childItem.USSubTotal}}
</td>
<td>
{{childItem.VNDSubTotal}}
</td>
</tr>
</template>
</tbody>
<tbody title="杂支合计">
<tr>
<td colspan="2">
</td>
<td>
D1
</td>
<td>
US合計:{{ZaZhiSum.USPriceSum}}
</td>
<td>
VND合計:{{ZaZhiSum.VNDPriceSum}}
</td>
<td>
</td>
<td>
</td>
<td>
</td>
<td>
{{ZaZhiSum.USTotalSum}}
</td>
<td>
{{ZaZhiSum.VNDTotalSum}}
</td>
</tr>
</tbody>
<tbody title="購物自費">
<tr>
<td colspan="10">
</td>
</tr>
<tr>
<td colspan="7">
購物自費 <a class="link" @click="AddBaoJiaConfigItem(2)">添加</a>
</td>
<td>
</td>
<td>
1
</td>
<td>
1
</td>
</tr>
<tr>
<td colspan="2">
</td>
<td class="ComTitle" colspan="2">
名称
</td>
<td class="ComTitle">
美金
</td>
<td class="ComTitle">
越南盾
</td>
<td class="ComTitle">
次/N數
</td>
<td class="ComTitle">
FOC
</td>
<td class="ComTitle" colspan="2">
合计
</td>
</tr>
<template v-for="(childItem,childIndex) in postData.SWTSelfFeeList">
<tr :key="childIndex">
<td colspan="2">
</td>
<td colspan="2">
0
<a class="link" @click="DeleteBaoJiaConfigItem(2,childIndex)">删除</a>
<el-select v-model="childItem.BaoJiaConfigId" class='w200' filterable :placeholder="$t('pub.pleaseSel')"
@change="GetConfigItem(childItem,2),CalcFeeTotal()">
<el-option :label="$t('pub.unlimitedSel')" :value='0'></el-option>
<el-option v-for="(qitem,qindex) in SelfFeeList" :value="qitem.Id" :label="qitem.CName" :key="qindex">
</el-option>
</el-select>
</td>
<td>
<el-input v-model="childItem.USPrice" maxlength="10"
@keyup.native="checkPrice(childItem,'USPrice'),CalcFeeTotal()" placeholder="美金"></el-input>
</td>
<td>
<el-input v-model="childItem.VNDPrice" maxlength="10"
@keyup.native="checkPrice(childItem,'VNDPrice'),CalcFeeTotal()" placeholder="越盾">
</el-input>
</td>
<td>
{{childItem.TotalNum}}
</td>
<td>
<el-input v-model="childItem.FOCNum" @keyup.native="checkInteger(childItem,'FOCNum'),CalcFeeTotal()"
placeholder="次/N數" maxlength="1"></el-input>
</td>
<td>
{{childItem.USSubTotal}}
</td>
<td>
{{childItem.VNDSubTotal}}
</td>
</tr>
</template>
</tbody>
</table>
</div>
</div>
</template>
<script>
export default {
data() {
return {
LineList: [], //线路列表
LineTeamList: [], //系列列表
DefaultCurrencyId: 17, //默认为越南盾
//基本配置
postData: {
Id: 0,
LineId: 0,
LineteamId: 0,
IsDirect: 1, //是否直采(0-否-1-是)【全部默认非直采】
TeamType: 3, //团队类型【默认地接团】
TravelState: 1, //团控状态(1-草稿,2-待审核,3-审核通过,4-审核拒绝,5已撤销)
Title: "", //团队标题
ConfigId: 0, //配置编号
DayNum: 0, //行程天数
StartDate: "", //出发日期
AirLineName: "", //航空公司名称
SWTFlightList: [], //航班列表
GuestNum: 0, //旅客人数
FocNum: 0, //Foc人数
SWTLeaderList: [], //领队信息
SWTGuideList: [], //导游信息
LocalTeamNum: "", //LOCAL團號
ValuationCode: "", //估價代號
OutTeamName: "", //出團名稱
AGTTeamName: "", //AGT團號
SURCHARGE: "", //SURCHARGE
HotelDisNum: 0, //酒店免人数
SWTHotelList: [], //酒店信息
DinnerDisNum: 0, //餐免人数
SWTDinnerList: [], //餐厅信息
TicketDisNum: 0, //景点免人数
SWTTicketList: [], //景点信息
BusPriceId: 0, //车辆报价编号
SWTBusList: [], //车资明细
SWTShipList: [], //船明细
SWTOtherPayList: [], //杂支信息
SWTSelfFeeList: [], //自费明细
SWTTipFeeList: [], //小费明细
},
BusTypeList: [], //车辆类型
//酒店统计
HotelSum: {
USPriceSum: 0, //美金单价统计
VNDPriceSum: 0, //越盾单价统计
USTotalSum: 0, //美金合计
VNDTotalSum: 0, //越盾合计
},
//餐厅统计
DinnerSum: {
USPriceSum: 0, //美金单价统计
VNDPriceSum: 0, //越盾单价统计
USTotalSum: 0, //美金合计
VNDTotalSum: 0, //越盾合计
},
//景点门票统计
TicketSum: {
USPriceSum: 0, //美金单价统计
VNDPriceSum: 0, //越盾单价统计
USTotalSum: 0, //美金合计
<tbody title="購物自費合计">
<tr>
<td colspan="2">
</td>
<td colspan="2">
</td>
<td>
US合計:{{SelfFeeSum.USPriceSum}}
</td>
<td>
VND合計:{{SelfFeeSum.VNDPriceSum}}
</td>
<td>
</td>
<td>
</td>
<td>
{{SelfFeeSum.USTotalSum}}
</td>
<td>
{{SelfFeeSum.VNDTotalSum}}
</td>
</tr>
</tbody>
<tbody title="小費">
<tr>
<td colspan="7">
小費 <a class="link" @click="AddBaoJiaConfigItem(3)">添加</a>
</td>
<td>
</td>
<td>
</td>
<td>
</td>
</tr>
<tr>
<td colspan="2">
</td>
<td class="ComTitle" colspan="2">
名称
</td>
<td class="ComTitle">
美金
</td>
<td class="ComTitle">
越南盾
</td>
<td class="ComTitle">
次/N數
</td>
<td class="ComTitle">
FOC
</td>
<td class="ComTitle" colspan="2">
合计
</td>
</tr>
<template v-for="(childItem,childIndex) in postData.SWTTipFeeList">
<tr :key="childIndex">
<td colspan="2">
</td>
<td colspan="2">
<a class="link" @click="DeleteBaoJiaConfigItem(3,childIndex)">删除</a>
<el-select v-model="childItem.BaoJiaConfigId" class='w200' filterable :placeholder="$t('pub.pleaseSel')"
@change="GetConfigItem(childItem,3),CalcFeeTotal()">
<el-option :label="$t('pub.unlimitedSel')" :value='0'></el-option>
<el-option v-for="(qitem,qindex) in TipFeeList" :value="qitem.Id" :label="qitem.CName" :key="qindex">
</el-option>
</el-select>
</td>
<td>
<el-input v-model="childItem.USPrice" maxlength="10"
@keyup.native="checkPrice(childItem,'USPrice'),CalcFeeTotal()" placeholder="美金"></el-input>
</td>
<td>
<el-input v-model="childItem.VNDPrice" maxlength="10"
@keyup.native="checkPrice(childItem,'VNDPrice'),CalcFeeTotal()" placeholder="越盾">
</el-input>
</td>
<td>
{{childItem.TotalNum}}
</td>
<td>
<el-input v-model="childItem.FOCNum" @keyup.native="checkInteger(childItem,'FOCNum'),CalcFeeTotal()"
placeholder="次/N數" maxlength="1"></el-input>
</td>
<td>
{{childItem.USSubTotal}}
</td>
<td>
{{childItem.VNDSubTotal}}
</td>
</tr>
</template>
</tbody>
<tbody title="小費合计">
<tr>
<td colspan="2">
</td>
<td colspan="2">
</td>
<td>
US合計:{{TipFeeSum.USPriceSum}}
</td>
<td>
VND合計:{{TipFeeSum.VNDPriceSum}}
</td>
<td>
</td>
<td>
</td>
<td>
{{TipFeeSum.USTotalSum}}
</td>
<td>
{{TipFeeSum.VNDTotalSum}}
</td>
</tr>
</tbody>
</table>
</div>
</div>
</template>
<script>
export default {
data() {
return {
Id: 0, //编号
LineList: [], //线路列表
LineTeamList: [], //系列列表
DefaultCurrencyId: 17, //默认为越南盾
//基本配置
postData: {
Id: 0,
LineId: 0,
LineteamId: 0,
IsDirect: 1, //是否直采(0-否-1-是)【全部默认非直采】
TeamType: 3, //团队类型【默认地接团】
TravelState: 1, //团控状态(1-草稿,2-待审核,3-审核通过,4-审核拒绝,5已撤销)
Title: "", //团队标题
ConfigId: 0, //配置编号
DayNum: 0, //行程天数
StartDate: "", //出发日期
AirLineName: "", //航空公司名称
SWTFlightList: [], //航班列表
GuestNum: 0, //旅客人数
FocNum: 0, //Foc人数
SWTLeaderList: [], //领队信息
SWTGuideList: [], //导游信息
LocalTeamNum: "", //LOCAL團號
ValuationCode: "", //估價代號
OutTeamName: "", //出團名稱
AGTTeamName: "", //AGT團號
SURCHARGE: "", //SURCHARGE
HotelDisNum: 0, //酒店免人数
SWTHotelList: [], //酒店信息
DinnerDisNum: 0, //餐免人数
SWTDinnerList: [], //餐厅信息
TicketDisNum: 0, //景点免人数
SWTTicketList: [], //景点信息
BusPriceId: 0, //车辆报价编号
SWTBusList: [], //车资明细
SWTShipList: [], //船明细
SWTOtherPayList: [], //杂支信息
SWTSelfFeeList: [], //自费明细
SWTTipFeeList: [], //小费明细
},
BusTypeList: [], //车辆类型
//酒店统计
HotelSum: {
USPriceSum: 0, //美金单价统计
VNDPriceSum: 0, //越盾单价统计
USTotalSum: 0, //美金合计
VNDTotalSum: 0, //越盾合计
},
//餐厅统计
DinnerSum: {
USPriceSum: 0, //美金单价统计
VNDPriceSum: 0, //越盾单价统计
USTotalSum: 0, //美金合计
VNDTotalSum: 0, //越盾合计
},
//景点门票统计
TicketSum: {
USPriceSum: 0, //美金单价统计
VNDPriceSum: 0, //越盾单价统计
USTotalSum: 0, //美金合计
VNDTotalSum: 0, //越盾合计
},
//车资统计
......@@ -899,10 +1240,51 @@
TotalKM: 0, //美金单价统计
VNDTotalSum: 0, //越盾合计
},
ZaZhiList: [], //杂支列表
ShipList: [], //船列表
SelfFeeList: [], //自费列表
TipFeeList: [], //小费列表
//杂支统计
ZaZhiSum: {
USPriceSum: 0, //美金单价统计
VNDPriceSum: 0, //越盾单价统计
USTotalSum: 0, //美金合计
VNDTotalSum: 0, //越盾合计
},
//船票统计
ShipSum: {
USPriceSum: 0, //美金单价统计
VNDPriceSum: 0, //越盾单价统计
USTotalSum: 0, //美金合计
VNDTotalSum: 0, //越盾合计
},
//自费统计
SelfFeeSum: {
USPriceSum: 0, //美金单价统计
VNDPriceSum: 0, //越盾单价统计
USTotalSum: 0, //美金合计
VNDTotalSum: 0, //越盾合计
},
//小费统计
TipFeeSum: {
USPriceSum: 0, //美金单价统计
VNDPriceSum: 0, //越盾单价统计
USTotalSum: 0, //美金合计
VNDTotalSum: 0, //越盾合计
},
loading: false,
};
},
methods: {
//航班Json格式
getflightJson() {
var obj = {
flightDate: "",
flightNum: "",
flightContent: ""
}
return obj;
},
//添加航班
AddFlight() {
if (this.postData.SWTFlightList.length <= 6) {
......@@ -938,15 +1320,6 @@
}
});
},
//航班Json格式
getflightJson() {
var obj = {
flightDate: "",
flightNum: "",
flightContent: ""
}
return obj;
},
//领队导游JSON格式
getLeaderGuideJson() {
var obj = {
......@@ -955,15 +1328,9 @@
return obj;
},
getData() {
let Id = 0;
if (this.$route.query.Id) {
Id = this.$route.query.Id;
}
Id = 3;
this.apipost("travel_get_GetBaoJiaDanSwtService", {
Id: Id,
Id: this.Id,
}, res => {
console.log("res.data", res.data);
if (res.data.resultCode == 1) {
var jsonData = res.data.data;
if (jsonData) {
......@@ -1010,34 +1377,54 @@
this.postData.HotelDisNum = jsonData.HotelDisNum;
if (jsonData.SWTHotelList) {
this.postData.SWTHotelList = jsonData.SWTHotelList;
this.GetHotelCalc();
} else {
this.createHotel();
}
//餐厅
this.postData.DinnerDisNum = jsonData.DinnerDisNum;
if (jsonData.SWTDinnerList) {
this.postData.SWTDinnerList = jsonData.SWTDinnerList;
this.GetDinnerCalc()
} else {
this.createDinner();
}
//景点
this.postData.TicketDisNum = jsonData.TicketDisNum;
if (jsonData.SWTTicketList) {
this.postData.SWTTicketList = jsonData.SWTTicketList;
this.GetScenicCalc();
} else {
this.createTicket();
}
//车资
this.postData.BusPriceId = jsonData.BusPriceId;
if (jsonData.SWTBusList) {
this.postData.SWTBusList = jsonData.SWTBusList;
this.GetBusCalc();
}
//生成酒店、餐、景点门票、车资
this.createHotelDinnerTicketBus();
//船
if (jsonData.SWTShipList) {
this.postData.SWTShipList = jsonData.SWTShipList;
} else {
this.createBus();
this.postData.SWTShipList.push(this.GetBaoJiaConfigItemJson());
}
//杂支
if (jsonData.SWTOtherPayList) {
this.postData.SWTOtherPayList = jsonData.SWTOtherPayList;
} else {
this.postData.SWTOtherPayList.push(this.GetBaoJiaConfigItemJson());
}
//自费
if (jsonData.SWTSelfFeeList) {
this.postData.SWTSelfFeeList = jsonData.SWTSelfFeeList;
} else {
var tempJson = this.GetBaoJiaConfigItemJson();
tempJson.FOCNum = this.getPeopleNum.focNum;
this.postData.SWTSelfFeeList.push(tempJson);
}
//小费
if (jsonData.SWTTipFeeList) {
this.postData.SWTTipFeeList = jsonData.SWTTipFeeList;
} else {
var tempJson = this.GetBaoJiaConfigItemJson();
tempJson.FOCNum = this.getPeopleNum.focNum;
this.postData.SWTTipFeeList.push(this.GetBaoJiaConfigItemJson());
}
//计算费用合计
this.CalcFeeTotal();
}
}
});
......@@ -1055,12 +1442,13 @@
},
//人数改变
GetPeople() {
//酒店
if (this.postData.SWTHotelList && this.postData.SWTHotelList.length > 0) {
this.postData.SWTHotelList.forEach(item => {
item.TotalNum = this.getPeopleNum.hotelNum;
});
this.GetHotelCalc()
}
//餐
if (this.postData.SWTDinnerList && this.postData.SWTDinnerList.length > 0) {
this.postData.SWTDinnerList.forEach(rootItem => {
rootItem.SubDinnerList.forEach(iten => {
......@@ -1068,8 +1456,8 @@
item.FOCNum = this.getPeopleNum.focNum;
})
});
this.GetDinnerCalc()
}
//景点门票
if (this.postData.SWTTicketList && this.postData.SWTTicketList.length > 0) {
this.postData.SWTTicketList.forEach(rootItem => {
rootItem.SubDinnerList.forEach(iten => {
......@@ -1077,8 +1465,22 @@
item.FOCNum = this.getPeopleNum.focNum;
})
});
this.GetScenicCalc()
}
//自费
if (this.postData.SWTSelfFeeList && this.postData.SWTSelfFeeList.length > 0) {
this.postData.SWTSelfFeeList.forEach(item => {
item.TotalNum = this.getPeopleNum.totalNum;
item.FOCNum = this.getPeopleNum.focNum;
})
}
//小费
if (this.postData.SWTTipFeeList && this.postData.SWTTipFeeList.length > 0) {
this.postData.SWTTipFeeList.forEach(item => {
item.TotalNum = this.getPeopleNum.totalNum;
item.FOCNum = this.getPeopleNum.focNum;
})
}
this.CalcFeeTotal();
},
//获取酒店列表
GetHotelList(event, item) {
......@@ -1124,8 +1526,9 @@
}
}
},
//计算费用
CalcFeeTotal() {
//酒店计算
GetHotelCalc() {
if (this.postData.SWTHotelList && this.postData.SWTHotelList.length > 0) {
var subUSPrice = 0;
var subVNDPrice = 0;
......@@ -1168,67 +1571,22 @@
this.HotelSum.USTotalSum = totalUSPrice.toFixed(2);
this.HotelSum.VNDTotalSum = totalVNDPrice.toFixed(2);
}
},
//获取餐厅列表
GetDinnerList(event, item, subitem) {
var newDate = "";
if (this.postData.StartDate) {
var newDay = Number(item.DayNum - 1);
newDate = this.$commonUtils.AddDay(this.postData.StartDate, newDay)
}
if (event) {
var hMsg = {
QCountrys: "1252",
StatisticsSTime: newDate
};
this.apipost("dining_post_GetSWTDinnerListService", hMsg, res => {
if (res.data.resultCode == 1) {
subitem.DinnerList = res.data.data;
//餐厅计算
if (this.postData.SWTDinnerList && this.postData.SWTDinnerList.length > 0) {
var subUSPrice = 0;
var subVNDPrice = 0;
var totalUSPrice = 0;
var totalVNDPrice = 0;
this.postData.SWTDinnerList.forEach(rootItem => {
rootItem.SubDinnerList.forEach(item => {
var c_usprice = 0;
if (item.USPrice) {
c_usprice = item.USPrice;
}
});
}
},
//获取选中的餐厅数据
GetDinnerItem(currentItem) {
var that = this;
if (currentItem.DinnerId != 0) {
//获取当前选中的对象
let obj = {};
obj = currentItem.DinnerList.find(item => {
return item.ID === currentItem.DinnerId; //筛选出匹配数据
});
if (obj != undefined) {
currentItem.VNDPrice = 0;
currentItem.USPrice = 0;
if (obj.CurrencyId == this.DefaultCurrencyId) {
if (obj.CostPrice) {
currentItem.VNDPrice = obj.CostPrice;
}
} else {
if (obj.CostPrice) {
currentItem.USPrice = obj.CostPrice;
}
}
currentItem.DinnerName = obj.Name;
}
}
},
//餐厅计算
GetDinnerCalc() {
if (this.postData.SWTDinnerList && this.postData.SWTDinnerList.length > 0) {
var subUSPrice = 0;
var subVNDPrice = 0;
var totalUSPrice = 0;
var totalVNDPrice = 0;
this.postData.SWTDinnerList.forEach(rootItem => {
rootItem.SubDinnerList.forEach(item => {
var c_usprice = 0;
if (item.USPrice) {
c_usprice = item.USPrice;
}
var c_vndprice = 0;
if (item.VNDPrice) {
c_vndprice = item.VNDPrice
var c_vndprice = 0;
if (item.VNDPrice) {
c_vndprice = item.VNDPrice
}
subUSPrice += Number(c_usprice);
subVNDPrice += Number(c_vndprice);
......@@ -1250,7 +1608,6 @@
2);
item.VNDSubTotal = (parseFloat(c_vndprice) * parseFloat(c_times) * (c_totalNum - c_DinnerDisNum))
.toFixed(2);
totalUSPrice += parseFloat(item.USSubTotal);
totalVNDPrice += parseFloat(item.VNDSubTotal);
})
......@@ -1260,61 +1617,8 @@
this.DinnerSum.USTotalSum = totalUSPrice.toFixed(2);
this.DinnerSum.VNDTotalSum = totalVNDPrice.toFixed(2);
}
},
//获取景点列表
GetScenicList(event, item, subitem) {
var newDate = "";
if (this.postData.StartDate) {
var newDay = Number(item.DayNum - 1);
newDate = this.$commonUtils.AddDay(this.postData.StartDate, newDay)
}
if (event) {
var hMsg = {
QCountrys: "1252",
StatisticsSTime: newDate
};
this.apipost("ticketcoupons_post_GetSWTScienListService", hMsg, res => {
if (res.data.resultCode == 1) {
subitem.TicketList = res.data.data;
}
});
}
},
//添加景点
AddTicket(item) {
item.SubTicketList.push(this.getTicketJson());
},
//删除景点
DeleteTicket(item, subIndex) {
item.SubTicketList.splice(subIndex, 1);
},
//获取选中的景点数据
GetScenicItem(currentItem) {
var that = this;
if (currentItem.CouponsId != 0) {
//获取当前选中的对象
let obj = {};
obj = currentItem.TicketList.find(item => {
return item.ID === currentItem.CouponsId; //筛选出匹配数据
});
if (obj != undefined) {
currentItem.VNDPrice = 0;
currentItem.USPrice = 0;
if (obj.CurrencyId == this.DefaultCurrencyId) {
if (obj.CostPrice) {
currentItem.VNDPrice = obj.CostPrice;
}
} else {
if (obj.CostPrice) {
currentItem.USPrice = obj.CostPrice;
}
}
currentItem.CouponsName = obj.Name;
}
}
},
//景点计算
GetScenicCalc() {
//景点门票计算
if (this.postData.SWTTicketList && this.postData.SWTTicketList.length > 0) {
var subUSPrice = 0;
var subVNDPrice = 0;
......@@ -1350,7 +1654,6 @@
2);
item.VNDSubTotal = (parseFloat(c_vndprice) * parseFloat(c_times) * (c_totalNum - c_DinnerDisNum))
.toFixed(2);
totalUSPrice += parseFloat(item.USSubTotal);
totalVNDPrice += parseFloat(item.VNDSubTotal);
})
......@@ -1360,9 +1663,8 @@
this.TicketSum.USTotalSum = totalUSPrice.toFixed(2);
this.TicketSum.VNDTotalSum = totalVNDPrice.toFixed(2);
}
},
//车资计算
GetBusCalc() {
if (this.postData.SWTBusList && this.postData.SWTBusList.length > 0) {
var subKMs = 0;
var totalVNDPrice = 0;
......@@ -1389,122 +1691,391 @@
this.BusSum.TotalKM = subKMs.toFixed(2);
this.BusSum.VNDTotalSum = totalVNDPrice.toFixed(2);
}
//船
if (this.postData.SWTShipList && this.postData.SWTShipList.length > 0) {
var subUSPrice = 0;
var subVNDPrice = 0;
var totalUSPrice = 0;
var totalVNDPrice = 0;
this.postData.SWTShipList.forEach(item => {
var c_usprice = 0;
if (item.USPrice) {
c_usprice = item.USPrice;
}
var c_vndprice = 0;
if (item.VNDPrice) {
c_vndprice = item.VNDPrice
}
subUSPrice += Number(c_usprice);
subVNDPrice += Number(c_vndprice);
var c_times = 0;
if (item.Times) {
c_times = item.Times;
}
item.USSubTotal = (parseFloat(c_usprice) * parseFloat(c_times)).toFixed(2);
item.VNDSubTotal = (parseFloat(c_vndprice) * parseFloat(c_times)).toFixed(2);
totalUSPrice += parseFloat(item.USSubTotal);
totalVNDPrice += parseFloat(item.VNDSubTotal);
});
this.ShipSum.USPriceSum = subUSPrice.toFixed(2);
this.ShipSum.VNDPriceSum = subVNDPrice.toFixed(2);
this.ShipSum.USTotalSum = totalUSPrice.toFixed(2);
this.ShipSum.VNDTotalSum = totalVNDPrice.toFixed(2);
}
//杂支
if (this.postData.SWTOtherPayList && this.postData.SWTOtherPayList.length > 0) {
var subUSPrice = 0;
var subVNDPrice = 0;
var totalUSPrice = 0;
var totalVNDPrice = 0;
this.postData.SWTOtherPayList.forEach(item => {
var c_usprice = 0;
if (item.USPrice) {
c_usprice = item.USPrice;
}
var c_vndprice = 0;
if (item.VNDPrice) {
c_vndprice = item.VNDPrice
}
subUSPrice += Number(c_usprice);
subVNDPrice += Number(c_vndprice);
var c_times = 0;
if (item.Times) {
c_times = item.Times;
}
var c_daynum = 0;
if (item.DayNum) {
c_daynum = item.DayNum;
}
var c_focnum = 0;
if (item.FOCNum) {
c_focnum = item.FOCNum;
}
item.USSubTotal = (parseFloat(c_usprice) * parseFloat(c_daynum) * (c_times - c_focnum)).toFixed(2);
item.VNDSubTotal = (parseFloat(c_vndprice) * parseFloat(c_daynum) * (c_times - c_focnum)).toFixed(2);
totalUSPrice += parseFloat(item.USSubTotal);
totalVNDPrice += parseFloat(item.VNDSubTotal);
});
this.ZaZhiSum.USPriceSum = subUSPrice.toFixed(2);
this.ZaZhiSum.VNDPriceSum = subVNDPrice.toFixed(2);
this.ZaZhiSum.USTotalSum = totalUSPrice.toFixed(2);
this.ZaZhiSum.VNDTotalSum = totalVNDPrice.toFixed(2);
}
//自费计算
if (this.postData.SWTSelfFeeList && this.postData.SWTSelfFeeList.length > 0) {
var subUSPrice = 0;
var subVNDPrice = 0;
var totalUSPrice = 0;
var totalVNDPrice = 0;
this.postData.SWTSelfFeeList.forEach(item => {
var c_usprice = 0;
if (item.USPrice) {
c_usprice = item.USPrice;
}
var c_vndprice = 0;
if (item.VNDPrice) {
c_vndprice = item.VNDPrice
}
subUSPrice += Number(c_usprice);
subVNDPrice += Number(c_vndprice);
var c_totalnum = 0;
if (item.TotalNum) {
c_totalnum = item.TotalNum;
}
var c_focnum = 0;
if (item.FOCNum) {
c_focnum = item.FOCNum;
}
item.USSubTotal = (parseFloat(c_usprice) * (c_totalnum - c_focnum)).toFixed(2);
item.VNDSubTotal = (parseFloat(c_vndprice) * (c_totalnum - c_focnum)).toFixed(2);
totalUSPrice += parseFloat(item.USSubTotal);
totalVNDPrice += parseFloat(item.VNDSubTotal);
});
this.SelfFeeSum.USPriceSum = subUSPrice.toFixed(2);
this.SelfFeeSum.VNDPriceSum = subVNDPrice.toFixed(2);
this.SelfFeeSum.USTotalSum = totalUSPrice.toFixed(2);
this.SelfFeeSum.VNDTotalSum = totalVNDPrice.toFixed(2);
}
//小费计算
if (this.postData.SWTTipFeeList && this.postData.SWTTipFeeList.length > 0) {
var subUSPrice = 0;
var subVNDPrice = 0;
var totalUSPrice = 0;
var totalVNDPrice = 0;
this.postData.SWTTipFeeList.forEach(item => {
var c_usprice = 0;
if (item.USPrice) {
c_usprice = item.USPrice;
}
var c_vndprice = 0;
if (item.VNDPrice) {
c_vndprice = item.VNDPrice
}
subUSPrice += Number(c_usprice);
subVNDPrice += Number(c_vndprice);
var c_totalnum = 0;
if (item.TotalNum) {
c_totalnum = item.TotalNum;
}
var c_focnum = 0;
if (item.FOCNum) {
c_focnum = item.FOCNum;
}
item.USSubTotal = (parseFloat(c_usprice) * (c_totalnum - c_focnum)).toFixed(2);
item.VNDSubTotal = (parseFloat(c_vndprice) * (c_totalnum - c_focnum)).toFixed(2);
totalUSPrice += parseFloat(item.USSubTotal);
totalVNDPrice += parseFloat(item.VNDSubTotal);
});
this.TipFeeSum.USPriceSum = subUSPrice.toFixed(2);
this.TipFeeSum.VNDPriceSum = subVNDPrice.toFixed(2);
this.TipFeeSum.USTotalSum = totalUSPrice.toFixed(2);
this.TipFeeSum.VNDTotalSum = totalVNDPrice.toFixed(2);
}
},
/*获取车辆类型列表*/
getBusTypeList() {
this.apipost(
"bus_get_GetBusTypePriceList", {
StartDate: this.postData.StartDate
},
res => {
//获取餐厅列表
GetDinnerList(event, item, subitem) {
var newDate = "";
if (this.postData.StartDate) {
var newDay = Number(item.DayNum - 1);
newDate = this.$commonUtils.AddDay(this.postData.StartDate, newDay)
}
if (event) {
var hMsg = {
QCountrys: "1252",
StatisticsSTime: newDate
};
this.apipost("dining_post_GetSWTDinnerListService", hMsg, res => {
if (res.data.resultCode == 1) {
this.BusTypeList = res.data.data;
this.BusTypeList.forEach(item => {
item['newName'] = item.AreaTypeStr + '-' + item.BusTypeStr
subitem.DinnerList = res.data.data;
}
});
}
},
null
);
//获取选中的餐厅数据
GetDinnerItem(currentItem) {
var that = this;
if (currentItem.DinnerId != 0) {
//获取当前选中的对象
let obj = {};
obj = currentItem.DinnerList.find(item => {
return item.ID === currentItem.DinnerId; //筛选出匹配数据
});
if (obj != undefined) {
currentItem.VNDPrice = 0;
currentItem.USPrice = 0;
if (obj.CurrencyId == this.DefaultCurrencyId) {
if (obj.CostPrice) {
currentItem.VNDPrice = obj.CostPrice;
}
} else {
if (obj.CostPrice) {
currentItem.USPrice = obj.CostPrice;
}
}
currentItem.DinnerName = obj.Name;
}
}
},
//生成酒店数据
createHotel() {
if (this.postData.DayNum > this.postData.SWTHotelList.length) {
for (
var i = this.postData.SWTHotelList.length; i < this.postData.DayNum; i++
) {
//去掉以前默认的交通
var dayItem = {
DayNum: i + 1,
HotelId: 0, //酒店变化
HotelName: "", //酒店名称
//景点JSON
getTicketJson() {
var obj = {
CouponsId: 0, //景点名称
CouponsName: "", //景点名称
USPrice: 0, //美元
VNDPrice: 0, //越南盾
TotalNum: this.getPeopleNum.hotelNum, //总房间数
TotalNum: this.getPeopleNum.totalNum, //总人数
FOCNum: this.getPeopleNum.focNum, //FOC人数
Times: 1, //次数
USSubTotal: 0, //美元小计
VNDSubTotal: 0, //越南盾小计
HotelDisNum: this.postData.HotelDisNum, //减免人数
HotelList: [],
TicketDisNum: this.postData.TicketDisNum, //减免人数
TicketList: [], //餐厅下拉列表[前台使用]
}
return obj;
},
//添加景点
AddTicket(item) {
item.SubTicketList.push(this.getTicketJson());
},
//删除景点
DeleteTicket(item, subIndex) {
item.SubTicketList.splice(subIndex, 1);
},
//获取景点列表
GetScenicList(event, item, subitem) {
var newDate = "";
if (this.postData.StartDate) {
var newDay = Number(item.DayNum - 1);
newDate = this.$commonUtils.AddDay(this.postData.StartDate, newDay)
}
if (event) {
var hMsg = {
QCountrys: "1252",
StatisticsSTime: newDate
};
this.postData.SWTHotelList.push(dayItem);
this.apipost("ticketcoupons_post_GetSWTScienListService", hMsg, res => {
if (res.data.resultCode == 1) {
subitem.TicketList = res.data.data;
}
});
}
},
//获取选中的景点数据
GetScenicItem(currentItem) {
var that = this;
if (currentItem.CouponsId != 0) {
//获取当前选中的对象
let obj = {};
obj = currentItem.TicketList.find(item => {
return item.ID === currentItem.CouponsId; //筛选出匹配数据
});
if (obj != undefined) {
currentItem.VNDPrice = 0;
currentItem.USPrice = 0;
if (obj.CurrencyId == this.DefaultCurrencyId) {
if (obj.CostPrice) {
currentItem.VNDPrice = obj.CostPrice;
}
} else {
this.postData.SWTHotelList.length = this.postData.DayNum;
if (obj.CostPrice) {
currentItem.USPrice = obj.CostPrice;
}
}
currentItem.CouponsName = obj.Name;
}
}
},
//生成餐厅
createDinner() {
if (this.postData.DayNum > this.postData.SWTDinnerList.length) {
for (
var i = this.postData.SWTDinnerList.length; i < this.postData.DayNum; i++
) {
//去掉以前默认的交通
var dayItem = {
DayNum: i + 1,
SubDinnerList: []
};
for (var j = 1; j <= 3; j++) {
dayItem.SubDinnerList.push({
DinnerType: j, //用餐类型[1-早餐,2-午餐,3-晚餐]
DinnerId: 0, //餐厅编号
DinnerName: "", //餐厅名称
//报价费用配置
GetBaoJiaConfigItemJson() {
var obj = {
BaoJiaConfigId: 0, //费用配置编号
BaoJiaConfigName: '', //费用配置名称
USPrice: 0, //美元
VNDPrice: 0, //越南盾
DayNum: this.postData.DayNum, //行程天数
TotalNum: this.getPeopleNum.totalNum, //总人数
FOCNum: this.getPeopleNum.focNum, //FOC人数
FOCNum: 0, //FOC人数
Times: 1, //次数
USSubTotal: 0, //美元小计
VNDSubTotal: 0, //越南盾小计
DinnerDisNum: this.postData.DinnerDisNum, //减免人数
DinnerList: [], //餐厅下拉列表[前台使用]
};
return obj;
},
//添加报价项
AddBaoJiaConfigItem(type) {
var tempJson = this.GetBaoJiaConfigItemJson();
switch (type) {
case 4: //船
this.postData.SWTShipList.push(tempJson);
break;
case 1: //杂支
this.postData.SWTOtherPayList.push(tempJson);
break;
case 2: //自费
tempJson.FOCNum = this.getPeopleNum.focNum;
this.postData.SWTSelfFeeList.push(tempJson);
break;
case 3: //小费
tempJson.FOCNum = this.getPeopleNum.focNum;
this.postData.SWTTipFeeList.push(tempJson);
break;
}
},
//删除报价项
DeleteBaoJiaConfigItem(type, index) {
switch (type) {
case 4: //船
this.postData.SWTShipList.splice(index, 1);
break;
case 1: //杂支
this.postData.SWTOtherPayList.splice(index, 1);
break;
case 2: //自费
this.postData.SWTSelfFeeList.splice(index, 1);
break;
case 3: //小费
this.postData.SWTTipFeeList.splice(index, 1);
break;
}
},
//获取报价配置项
GetConfigItem(currentItem, type) {
var that = this;
if (currentItem.BaoJiaConfigId != 0) {
//获取当前选中的对象
let obj = {};
switch (type) {
case 4: //船
obj = this.ShipList.find(item => {
return item.Id === currentItem.BaoJiaConfigId;
});
break;
case 1: //杂支
obj = this.ZaZhiList.find(item => {
return item.Id === currentItem.BaoJiaConfigId;
});
break;
case 2: //自费
obj = this.SelfFeeList.find(item => {
return item.Id === currentItem.BaoJiaConfigId;
});
break;
case 3: //小费
obj = this.TipFeeList.find(item => {
return item.Id === currentItem.BaoJiaConfigId;
});
break;
}
this.postData.SWTDinnerList.push(dayItem);
if (obj != undefined) {
currentItem.VNDPrice = obj.VNDPrice;
currentItem.USPrice = obj.USPrice;
currentItem.BaoJiaConfigName = obj.CName;
}
} else {
this.postData.SWTDinnerList.length = this.postData.DayNum;
}
},
getTicketJson() {
//获取车辆类型列表
getBusTypeList() {
this.apipost(
"bus_get_GetBusTypePriceList", {
StartDate: this.postData.StartDate
},
res => {
if (res.data.resultCode == 1) {
this.BusTypeList = res.data.data;
this.BusTypeList.forEach(item => {
item['newName'] = item.AreaTypeStr + '-' + item.BusTypeStr
});
}
},
null
);
},
//车资JSON
getBusJson() {
var obj = {
CouponsId: 0, //景点名称
CouponsName: "", //景点名称
USPrice: 0, //美元
BusConfigId: 0, //车资配置编号
Trip: "", //行程
Kilometre: 0, //公里数
VNDPrice: 0, //越南盾
TotalNum: this.getPeopleNum.totalNum, //总人数
FOCNum: this.getPeopleNum.focNum, //FOC人数
Times: 1, //次数
USSubTotal: 0, //美元小计
Price: 0, //单价
VNDSubTotal: 0, //越南盾小计
TicketDisNum: this.postData.TicketDisNum, //减免人数
TicketList: [], //餐厅下拉列表[前台使用]
BusList: [], //车下拉列表[前台使用]
}
return obj;
},
//生成景点
createTicket() {
if (this.postData.DayNum > this.postData.SWTTicketList.length) {
for (
var i = this.postData.SWTTicketList.length; i < this.postData.DayNum; i++
) {
//去掉以前默认的交通
var dayItem = {
DayNum: i + 1,
SubTicketList: []
};
dayItem.SubTicketList.push(this.getTicketJson());
this.postData.SWTTicketList.push(dayItem);
}
} else {
this.postData.SWTTicketList.length = this.postData.DayNum;
}
},
//添加用车
//添加车资
AddBus(item) {
item.SubBusList.push(this.getBusJson());
},
//删除用车
//删除车资
DeleteBus(item, subIndex) {
item.SubBusList.splice(subIndex, 1);
},
......@@ -1550,44 +2121,116 @@
}
}
},
//车资JSON
getBusJson() {
var obj = {
BusConfigId: 0, //车资配置编号
Trip: "", //行程
Kilometre: 0, //公里数
//生成酒店、餐、门票、车资
createHotelDinnerTicketBus() {
//生成景点
if (this.postData.DayNum > this.postData.SWTTicketList.length) {
for (
var i = this.postData.SWTTicketList.length; i < this.postData.DayNum; i++
) {
//景点
var ticketItem = {
DayNum: i + 1,
SubTicketList: []
};
ticketItem.SubTicketList.push(this.getTicketJson());
this.postData.SWTTicketList.push(ticketItem);
//车资
var busItem = {
DayNum: i + 1,
SubBusList: []
};
busItem.SubBusList.push(this.getBusJson());
this.postData.SWTBusList.push(busItem);
//餐厅
var dinnerItem = {
DayNum: i + 1,
SubDinnerList: []
};
for (var j = 1; j <= 3; j++) {
dinnerItem.SubDinnerList.push({
DinnerType: j, //用餐类型[1-早餐,2-午餐,3-晚餐]
DinnerId: 0, //餐厅编号
DinnerName: "", //餐厅名称
USPrice: 0, //美元
VNDPrice: 0, //越南盾
TotalNum: this.getPeopleNum.totalNum, //总人数
FOCNum: this.getPeopleNum.focNum, //FOC人数
Times: 1, //次数
Price: 0, //单价
USSubTotal: 0, //美元小计
VNDSubTotal: 0, //越南盾小计
BusList: [], //车下拉列表[前台使用]
DinnerDisNum: this.postData.DinnerDisNum, //减免人数
DinnerList: [], //餐厅下拉列表[前台使用]
});
}
return obj;
},
//车资部分
createBus() {
if (this.postData.DayNum > this.postData.SWTBusList.length) {
for (
var i = this.postData.SWTBusList.length; i < this.postData.DayNum; i++
) {
//去掉以前默认的交通
var dayItem = {
this.postData.SWTDinnerList.push(dinnerItem);
//酒店
var hotelItem = {
DayNum: i + 1,
SubBusList: []
HotelId: 0, //酒店变化
HotelName: "", //酒店名称
USPrice: 0, //美元
VNDPrice: 0, //越南盾
TotalNum: this.getPeopleNum.hotelNum, //总房间数
Times: 1, //次数
USSubTotal: 0, //美元小计
VNDSubTotal: 0, //越南盾小计
HotelDisNum: this.postData.HotelDisNum, //减免人数
HotelList: [],
};
dayItem.SubBusList.push(this.getBusJson());
this.postData.SWTBusList.push(dayItem);
this.postData.SWTHotelList.push(hotelItem);
}
} else {
//删除景点
this.postData.SWTTicketList.length = this.postData.DayNum;
//删除车资
this.postData.SWTBusList.length = this.postData.DayNum;
//删除餐厅
this.postData.SWTDinnerList.length = this.postData.DayNum;
//删除酒店
this.postData.SWTHotelList.length = this.postData.DayNum;
}
},
//获取船、自费、小费、杂支列表
GetBaoJiaFeeConfigList() {
this.apipost("travel_get_GetBaoJiaDanConfigSwtListService", {}, res => {
if (res.data.resultCode == 1) {
var tempJson = res.data.data;
if (tempJson) {
tempJson.forEach(item => {
//杂支
if (item.CType == 1) {
this.ZaZhiList = item.SubList;
}
//自费
if (item.CType == 2) {
this.SelfFeeList = item.SubList;
}
//小费
if (item.CType == 3) {
this.TipFeeList = item.SubList;
}
//船
if (item.CType == 4) {
this.ShipList = item.SubList;
}
});
}
}
});
},
},
created() {
},
mounted() {
if (this.$route.query.Id) {
this.Id = this.$route.query.Id;
}
this.GetBaoJiaFeeConfigList();
this.getBusTypeList();
this.getLineList();
this.getData();
......@@ -1618,10 +2261,7 @@
//监听天数变化
'postData.DayNum': {
handler(newVal, oldVal) {
this.createHotel();
this.createDinner();
this.createTicket();
this.createBus();
this.createHotelDinnerTicketBus();
},
deep: true
}
......
......@@ -62,7 +62,7 @@
<em>所属线路</em>
<el-select v-model="queryData.LineId" class='w200' filterable :placeholder="$t('pub.pleaseSel')"
@change="getLineTeamList()">
<el-option :label="$t('pub.unlimitedSel')" :value='noLimit'></el-option>
<el-option :label="$t('pub.unlimitedSel')" :value='0'></el-option>
<el-option v-for="item in LineList" :label='item.LineName' :value='item.LineID' :key='item.LineID'>
</el-option>
</el-select>
......@@ -72,23 +72,12 @@
<span>
<em>所属系列</em>
<el-select v-model="queryData.LineteamId" class='w200' filterable :placeholder="$t('pub.pleaseSel')">
<el-option :label="$t('pub.unlimitedSel')" :value='noLimit'></el-option>
<el-option :label="$t('pub.unlimitedSel')" :value='0'></el-option>
<el-option v-for="item in LineTeamList" :label='item.LtName' :value='item.LtID' :key='item.LtID'>
</el-option>
</el-select>
</span>
</li>
<li>
<span>
<em>开团状态</em>
<el-select v-model="queryData.OpenState" filterable :placeholder="$t('pub.pleaseSel')">
<el-option :label="$t('pub.unlimitedSel')" :value='noLimit'></el-option>
<el-option v-for='item in OpenStateList' :key="item.Id" :label="item.label" :value="item.Id">
</el-option>
</el-select>
</span>
</li>
<li>
<button class="hollowFixedBtn" @click="getList(),resetPageIndex()">查询</button>
<button class="hollowFixedBtn" @click="goMakeQuo('QuotationPrice_SWT',0)">新增</button>
......@@ -118,62 +107,13 @@
<p style="font-size:14px">
<el-tooltip popper-class="max-w250" effect="dark" :content="item.Title" placement="top-start">
<span>{{item.Title}}</span>
</el-tooltip>
</p>
<span>客户名称:{{item.CustomerName}}</span>
</div>
</div>
<div class="_cent">
<div style="margin: 0 13px 0 10px;" class="stayDays">
{{item.DayNum}}{{$t('hotel.hotel_day')}}</div>
<div class="">
{{$t('op.SalesPrice')}}
<el-popover popper-class="salsSetPrice" trigger="click">
<div class="priceContentDiv" v-if="item.QuotationPrice!=null">
<div>
<div>成人</div>
<div class="priceList">
<div>
<span class="pLeftPrice">销售价格:¥{{item.QuotationPrice.B2BMemberPrice}}</span>
</div>
</div>
<div>小孩</div>
<div class="priceList">
<div>
<span class="pLeftPrice">占床:¥{{item.QuotationPrice.ChildNeedPrice}}</span>
<span class="pRightPrice">不占床:¥{{item.QuotationPrice.ChildNoNeedPrice}}</span>
</div>
<div class="priceDivCon">
<span class="pLeftPrice">婴儿:¥{{item.QuotationPrice.BabyPrice}}</span>
<span class="pRightPrice">附加费:¥{{item.QuotationPrice.BabyChargePrice}}</span>
</div>
</div>
<div>老人</div>
<div class="priceList">
<div>
<span class="pLeftPrice">附加费:¥{{item.QuotationPrice.OldManChargePrice}}</span>
</div>
</div>
<div>杂费</div>
<div class="priceList">
<div>
<span class="pLeftPrice">签证:¥{{item.QuotationPrice.VisaPrice}}</span>
<span class="pRightPrice">单房差:¥{{item.QuotationPrice.SingleRoomPrice}}</span>
</div>
</div>
<div>单项报价</div>
<div class="priceList">
<div>
<span class="pLeftPrice">单地接:¥{{item.QuotationPrice.SingleDMCPrice}}</span>
</div>
</div>
</div>
</div>
<span slot="reference" class="diPrice">{{item.SalesPrice}}<span class="qi"></span></span>
</el-popover>
</div>
{{item.DayNum}} 天 出发日期 {{item.StartDateStr}}</div>
</div>
<div class="_right">
<div class="AuditUserInfo clearfix aa" style="margin-left:10px;">
......@@ -182,73 +122,24 @@
<img v-else src="../../../assets/img/default_head_img.jpg" alt="">
</div>
<div class="AU_creatName">
<div>{{item.CreateUserName}}</div>
</div>
</div>
<div class="AuditStatus" style="width:80px;">
<div v-if="item.TravelState==2">
<div>待审核</div>
</div>
<div v-if="item.TravelState==3">
<div class="Auditapproved">已通过</div>
<el-popover popper-class="salsSetPrice" trigger="click">
<div class="priceContentDiv">
<div>
<span>审批结果</span>
<span class="AuditDate">{{item.hours}}</span>
</div>
<div>{{item.AuditContent}}</div>
</div>
<div slot="reference" class="AuditLookDetail">查看说明</div>
</el-popover>
</div>
<div v-if="item.TravelState==4">
<div class="Auditrejected">已驳回</div>
<el-popover popper-class="salsSetPrice" trigger="click">
<div class="priceContentDiv">
<div>
<span>审批结果</span>
<span class="AuditDate">{{item.hours}}</span>
</div>
<div>{{item.AuditContent}}</div>
</div>
<div slot="reference" class="AuditLookDetail">查看说明</div>
</el-popover>
<div>{{item.CreateByName}}</div>
</div>
</div>
<div style="width:134px;">
<span class="openGroup newAopbdd" @click="goToOpenTravel(item)"
v-if="item.TravelState==3&&item.OpenState==2">
<el-tooltip class="item" effect="dark" content="开团" placement="top-start" popper-class="max-w250">
<i class="iconfont icon-nav-hangzheng"></i>
</el-tooltip>
</span>
<span v-if="EditBtn" class="bianji newAopbdd"
@click="goMakeQuo('QuotationPrice_SWT',item.ID)">
<el-tooltip class="item" effect="dark" :content="$t('pub.updateMsg')" placement="top-start"
popper-class="max-w250">
<i class="iconfont icon-bianji-smal"></i>
</el-tooltip>
</span>
<span class="bianji newAopbdd" @click="goMakeQuo('QuotationPrice_SWT',item.ID)"
v-if="item.TravelState==1||item.TravelState==4||item.TravelState==5">
<span class="bianji newAopbdd" @click="goMakeQuo('QuotationPrice_SWT',item.Id)">
<el-tooltip class="item" effect="dark" :content="$t('pub.updateMsg')" placement="top-start"
popper-class="max-w250">
<i class="iconfont icon-bianji-smal"></i>
</el-tooltip>
</span>
<span class="QT-delete newAopbdd" @click="delQuotation(item.ID)"
v-if="item.TravelState==1||item.TravelState==4||item.TravelState==5">
<span class="QT-delete newAopbdd" @click="delQuotation(item.Id)">
<el-tooltip class="item" effect="dark" :content="$t('system.table_delete')" placement="top-start"
popper-class="max-w250">
<i class="iconfont icon-shanchu"></i>
</el-tooltip>
</span>
<span style="background:#85ce61; " class="newAopbdd">
<el-tooltip class="item" effect="dark" content="查看" placement="top-start" popper-class="max-w250">
<i @click="goUrl('QuotationAduit',item.ID,1)" class="iconfont icon-view"></i>"></i>
</el-tooltip>
</span>
<span style="background:#85ce61; " class="newAopbdd" @click="showDownLoad(item)">
<el-tooltip class="item" effect="dark" content="下载" placement="top-start" popper-class="max-w250">
<i class="iconfont icon-bb-xiazai"></i>
......@@ -265,10 +156,6 @@
<el-pagination background @current-change="handleCurrentChange" :current-page.sync="queryData.currentPage"
layout="total,prev, pager, next, jumper" :page-size="queryData.pageSize" :total="queryData.total">
</el-pagination>
<el-dialog custom-class='ComTeamPlan_info_box' :title="tripTitle" :visible.sync="outerVisible" center>
<commonTeamInfo ref="comDialog"></commonTeamInfo>
</el-dialog>
<!-- 下载弹窗 -->
<el-dialog custom-class='w450' title="报价单下载" :visible.sync="downloadBill" center>
<div class="BilldownLoadCommon">
......@@ -320,69 +207,27 @@
</div>
</template>
<script>
import commonTeamInfo from "../../commonPage/commonTeamInfo.vue";
export default {
data() {
return {
EditBtn:false,//报价单修改权限
EditBtn: false, //报价单修改权限
userInfo: {},
queryData: {
LineId: 0,
LineteamId: 0,
TravelState: 0,
OpenState: 0,
PageIndex: 1,
PageSize: 10,
total: 0,
currentPage: 1,
TeamType: 0, //0常规,1-小包团,2-一日游,3-地接团
},
loading: true,
//报价单状态
TravelStateList: [{
Id: 1,
label: "草稿"
},
{
Id: 2,
label: "待审核"
},
{
Id: 3,
label: "审核通过"
},
{
Id: 4,
label: "审核拒绝"
},
{
Id: 5,
label: "已撤销"
}
],
//开团状态
OpenStateList: [{
Id: 1,
label: "已开团"
},
{
Id: 2,
label: "未开团"
}
],
//线路列表
LineList: "",
noLimit: 0,
//系列列表
LineTeamList: "",
//是否有数据
noData: false,
dataList: "",
SalesPriceList: [],
CostList: [],
outerVisible: false,
tripTitle: "",
downloadBill: false,
//下载参数
downLoadMsg: {
......@@ -401,26 +246,9 @@
};
},
components: {
commonTeamInfo: commonTeamInfo
},
methods: {
goUrl(path, configId, qType) {
if (configId > 0) {
this.$router.push({
name: path,
query: {
configId: configId,
Qtype: qType,
blank: 'y',
tab: '报价单查看'
}
});
} else {
this.$router.push({
name: path
});
}
},
handleCurrentChange(val) {
this.queryData.pageIndex = val;
this.getList();
......@@ -453,7 +281,7 @@
//初始化表格数据
getList() {
this.loading = true;
this.apipost("travel_get_GetTravelOfferPageList_V2", this.queryData, res => {
this.apipost("travel_get_GetBaoJiaDanSwtPageListService", this.queryData, res => {
this.loading = false;
if (res.data.resultCode == 1) {
this.queryData.total = res.data.data.count;
......@@ -462,96 +290,16 @@
}
});
},
//点击销售定价获取数据
getSalsPrice(ID) {
this.SalesPriceList = [];
this.apipost(
"travel_get_GetTravelQuotationPrice", {
ID: ID
},
res => {
if (res.data.resultCode == 1) {
this.SalesPriceList = res.data.data;
}
}
);
},
//点击地接成本获取数据
getCostPrice(ID) {
this.CostList = [];
this.apipost(
"travel_get_GetTravelOfferPrice", {
ID: ID
},
res => {
if (res.data.resultCode == 1) {
if (res.data.data[0] != undefined || res.data.data[0] != null) {
let cost = res.data.data[0];
let dayNum = 0;
cost.LocalOfferPriceList.forEach(x => {
if (x.DayNum > dayNum) {
dayNum = x.DayNum;
}
});
let offerPriceList = [];
for (let i = 1; i <= dayNum; i++) {
let dayOfferPriceList = [];
let totalPrice = 0;
cost.LocalOfferPriceList.forEach(x => {
if (x.DayNum == i) {
dayOfferPriceList.push(x);
totalPrice += x.OfferPrice;
}
});
let offerPrice = {
day: i,
dayOfferPriceList,
totalPrice
};
offerPriceList.push(offerPrice);
}
cost["offerPriceList"] = offerPriceList;
this.CostList.push(cost);
}
}
}
);
},
//撤回
revokeInfo(ID) {
let msg = {
ID: ID,
TravelState: 5
};
this.apipost("travel_post_UpdateTravelState", msg, res => {
if (res.data.resultCode == 1) {
this.Success(res.data.message);
this.getList();
}
});
},
//修改状态
changeState(ID) {
let msg = {
ID: ID,
TravelState: 2
};
this.apipost("travel_post_UpdateTravelState", msg, res => {
if (res.data.resultCode == 1) {
this.Success(res.data.message);
this.getList();
}
});
},
//删除报价单
delQuotation(ID) {
var that = this;
this.Confirm(this.$t('sm.schbnhfjscz'), function () {
let msg = {
ID: ID,
Id: ID,
Status: 1,
};
that.apipost(
"travel_post_RemoveConfig",
"travel_post_UpdateBaoJiaDanSwtService",
msg,
res => {
if (res.data.resultCode == 1) {
......@@ -565,22 +313,12 @@
);
});
},
getJourney(id, title) {
//根据ID 获取行程内容
var that = this;
this.tripTitle = title;
this.$nextTick(() => {
that.$refs.comDialog.GetTrip(id);
});
that.outerVisible = true;
},
//报价单跳转
goMakeQuo(path, configId) {
goMakeQuo(path, Id) {
this.$router.push({
path: path,
query: {
TeamType: this.queryData.TeamType,
configId: configId,
Id: Id,
blank: 'y',
tab: '报价单'
}
......@@ -604,7 +342,6 @@
openState: 1,
isOffer: 1,
offerId: item.OfferId,
blank: 'y'
}
});
......@@ -647,30 +384,11 @@
},
},
mounted() {
this.GetAuth();
var routeName = this.$route.name;
if (routeName == 'newQuotation') {
this.queryData.TeamType = 3;
}
if (routeName == 'newQuotation2') {
this.queryData.TeamType = 1;
}
this.userInfo = this.getLocalStorage();
this.getLineList();
this.getList();
let isNoOffer = this.$route.params.isNoOffer;
if (isNoOffer) {
this.Warning("行程中含有未完善的报价信息,请在需求中心查看!");
}
},
created() {
this.userInfo = this.getLocalStorage();
if (this.$route.query.hasOwnProperty("cache")) {
if (this.$store.state.pageCondition != null) {
this.queryData = this.$store.state.pageCondition;
}
}
this.getList();
}
created() {}
};
</script>
......@@ -33,7 +33,7 @@
</li>
<li>
<button class="hollowFixedBtn" @click="qMsg.pageIndex=1,getList()">{{$t('pub.searchBtn')}}</button>
<input type="button" class="normalBtn" @click="addAreaData()" value="新增费用">
<input type="button" class="normalBtn" @click="addBaoJiaData()" value="新增费用">
</li>
</ul>
</div>
......@@ -56,14 +56,14 @@
<td>{{item.UpdateByName}}</td>
<td>{{item.UpdateDateStr}}</td>
<td>
<el-button type="primary" icon="el-icon-edit" @click="getAreaUpdate(item.Id)" circle></el-button>
<el-button type="primary" icon="el-icon-edit" @click="getBaoJiaConfigUpdate(item.Id)" circle></el-button>
<el-tooltip class="item" effect="dark" content="删除" placement="top-start">
<el-button type="danger" icon="el-icon-delete" @click="delArea(item.Id)" circle></el-button>
<el-button type="danger" icon="el-icon-delete" @click="delBaoJiaConfig(item.Id)" circle></el-button>
</el-tooltip>
</td>
</tr>
</table>
<el-pagination background @current-change="AreaCurrentChange" :current-page.sync="qMsg.currentPage"
<el-pagination background @current-change="BaoJiaCurrentChange" :current-page.sync="qMsg.currentPage"
layout="total,prev, pager, next, jumper" :page-size="qMsg.pageSize" :total="qMsg.total"></el-pagination>
<el-dialog custom-class="w400" :title="dialogTitle" :visible.sync="dialogVisible" center
......@@ -90,14 +90,14 @@
<tr>
<td>
<el-form-item label="美元">
<el-input v-model="addMsg.USPrice" class="w217" @keyup.native="checkPrice(addMsg,'USPrice')" />
<el-input v-model="addMsg.USPrice" class="w217" @keyup.native="checkPrice(addMsg,'USPrice',true)" />
</el-form-item>
</td>
</tr>
<tr>
<td>
<el-form-item label="越南盾">
<el-input v-model="addMsg.VNDPrice" class="w217" @keyup.native="checkPrice(addMsg,'VNDPrice')" />
<el-input v-model="addMsg.VNDPrice" class="w217" @keyup.native="checkPrice(addMsg,'VNDPrice',true)" />
</el-form-item>
</td>
</tr>
......@@ -106,7 +106,7 @@
<div slot="footer" class="dialog-footer">
<button class="hollowFixedBtn" @click="dialogVisible = false,clearAddMsg()">{{$t('pub.cancelBtn')}}</button>
&nbsp;
<button class="normalBtn" @click="saveAreaInfo()">{{$t('pub.saveBtn')}}</button>
<button class="normalBtn" @click="SaveBaoJiaConfig()">{{$t('pub.saveBtn')}}</button>
</div>
</el-dialog>
</div>
......@@ -122,7 +122,7 @@
qMsg: {
CType: 0,
pageIndex: 1,
pageSize: 5,
pageSize: 15,
total: 0,
currentPage: 1,
CName: '', //项目名称
......@@ -137,33 +137,22 @@
VNDPrice: 0, //越南盾
},
//费用类型字符串
TypeList: [{
Id: 1,
Name: "杂支"
},
{
Id: 2,
Name: "自费"
},
{
Id: 3,
Name: "小费"
},
], //费用类型列表
TypeList: [], //费用类型列表
};
},
mounted() {
this.getConfigTypeList();
this.getList();
},
filters: {},
methods: {
//新增地区
addAreaData() {
addBaoJiaData() {
this.dialogVisible = true;
this.dialogTitle = '新增费用';
},
//翻页
AreaCurrentChange(val) {
BaoJiaCurrentChange(val) {
this.qMsg.pageIndex = val;
this.getList();
},
......@@ -192,7 +181,7 @@
)
},
//保存费用配置
saveAreaInfo() {
SaveBaoJiaConfig() {
if (this.addMsg.CName == '') {
this.Error('请填写名称');
return;
......@@ -215,7 +204,7 @@
)
},
//修改费用配置
getAreaUpdate(Id) {
getBaoJiaConfigUpdate(Id) {
this.dialogTitle = "修改费用"
this.dialogVisible = true;
let msg = {
......@@ -237,7 +226,7 @@
)
},
//删除费用配置
delArea(Id) {
delBaoJiaConfig(Id) {
var that = this;
this.Confirm("是否删除?", function () {
var msg = {
......@@ -259,7 +248,19 @@
);
});
},
//获取费用类型列表
getConfigTypeList() {
this.apipost(
"travel_post_GetBaoJiaDanConfigSwtTypeListService", {},
res => {
if (res.data.resultCode == 1) {
this.TypeList = res.data.data;
console.log("res", this.TypeList);
}
},
null
);
},
}
};
......
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