Commit 51af9f1e authored by zhengke's avatar zhengke

s

parent 7bfd23fb
......@@ -115,8 +115,8 @@
</td>
</tr>
</template>
<tr>
<td class="comTotal" colspan="4">合计:</td>
<tr v-if="dataList.ScenicList.length>0">
<td class="comTotal" colspan="4">合计:{{totalScenicPrice}}</td>
</tr>
<tr v-for="(item,index) in dataList.BusList">
<td v-if="index==0" :rowspan="dataList.BusList.length">交通</td>
......@@ -126,17 +126,17 @@
<span v-if='index==dataList.BusList.length-1'>送机</span>
</td>
<td>
{{item.TotalPrice}} {{subItem.CurrencyStr}}
{{item.TotalPrice}} {{item.CurrencyStr}}
</td>
<td>
{{item.Remarks}}
</td>
</tr>
<tr>
<tr v-if="dataList.BusList.length>0">
<td class="comTotal" colspan="4">合计:{{totalTrafficPrice}}</td>
</tr>
<template v-for='(item,index) in dataList.DiningList'>
<tr class="splitP ScenicTr" v-for='(titem,tindex) in item.DiningSummaryList'>
<tr class="splitP ScenicTr">
<td v-if="index==0" :rowspan="dataList.DiningList.length">餐饮</td>
<td>
<div class="itemName" v-for="subItem in item.DiningSummaryList">
......@@ -155,8 +155,8 @@
</td>
</tr>
</template>
<tr>
<td class="comTotal" colspan="4">合计:</td>
<tr v-if="dataList.DiningList.length>0">
<td class="comTotal" colspan="4">合计:{{totalDinnerPrice}}</td>
</tr>
<template v-for='(item,index) in dataList.HotelList'>
<tr>
......@@ -168,9 +168,12 @@
<td>{{item.Remarks}}</td>
</tr>
</template>
<tr>
<tr v-if="dataList.HotelList.length>0">
<td class="comTotal" colspan="4">合计:{{totalHotelPrice}}</td>
</tr>
<tr>
<td colspan="4">总计:{{allTotal}}</td>
</tr>
</tbody>
</table>
<input type="button" class="printBtn" value="打印" @click="printTable()">
......@@ -189,10 +192,16 @@ export default {
},
nav:[],
dataList:[],
//合计景点
totalScenicPrice:0,
//合计餐饮
totalDinnerPrice:0,
//合计酒店
totalHotelPrice:0,
//合计交通
totalTrafficPrice:0,
allTotal:0,
}
},
methods: {
......@@ -205,12 +214,18 @@ export default {
console.log(res.data.data,'ressssssss');
this.dataList = res.data.data;
this.dataList.HotelList.forEach(x=>{
this.totalHotelPrice+=x.TotalPrice
this.totalHotelPrice+=parseFloat(x.TotalPrice)
})
this.dataList.BusList.forEach(x=>{
this.totalTrafficPrice+=x.TotalPrice
this.totalTrafficPrice+=parseFloat(x.TotalPrice);
})
this.dataList.ScenicList.forEach(x=>{
this.totalScenicPrice+= parseFloat(x.ScenicStatisticsList[0].TotalPrice);
})
this.dataList.DiningList.forEach(x=>{
this.totalDinnerPrice+= parseFloat(x.DiningSummaryList[0].TotalPrice);
})
this.allTotal = (this.totalHotelPrice+this.totalTrafficPrice+this.totalScenicPrice+this.totalDinnerPrice).toFixed(2);
} else {
this.Error(res.data.message)
}
......@@ -223,6 +238,7 @@ export default {
}, res => {
if (res.data.resultCode == 1) {
this.nav = res.data.data;
console.log(this.nav,'navvvvvvv');
} else {
this.Error(res.data.message)
}
......
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