Commit e84663fb authored by Mac's avatar Mac

修改领队报账

parent 1b036994
<style>
.leaderPayTable {
width: 100%;
margin: 10px auto;
text-align: center;
font-size: 12px;
color: #333;
border-collapse: collapse;
background-color: #fff;
border: 1px solid #d1d1d1;
}
width: 100%;
margin: 10px auto;
text-align: center;
font-size: 12px;
color: #333;
border-collapse: collapse;
background-color: #fff;
border: 1px solid #d1d1d1;
}
.leaderPayTable th {
background: #e6e6e6;
padding: 8px 0;
......@@ -22,6 +23,16 @@
height: 32px;
border: 1px solid #d1d1d1;
}
.leaderPayTable2 tr td{
border: 1px solid #ccc;
line-height: 17px;
height: 25px;
font-size: 12px;
background: #fff;
text-align: center;
padding: 0;;
margin: 0;
}
.LeaderPrintDiv .LeaderTitle {
padding: 10px;
text-align: left;
......@@ -72,7 +83,7 @@ input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
-webkit-appearance: none;
}
input[type="number"] {
-moz-appearance: textfield;
}
......@@ -82,7 +93,7 @@ input[type="number"] {
</style>
<template>
<div class="LeaderPrintDiv">
<div class="LeaderPrintDiv" >
<div class="childDiv">
<table border="0" cellspacing="1" class="leaderPayTable">
<tr>
......@@ -113,92 +124,220 @@ input[type="number"] {
<td colspan="10">暂无数据</td>
</tr>
</table>
<table border="0" cellspacing="1" class="leaderPayTable">
<tbody>
<tr>
<th>项目类型</th>
<th>项目内容</th>
<th>实付金额</th>
<th>备注</th>
</tr>
<template v-for="(item,index) in dataList.ScenicList">
<tr>
<td v-if="index==0" :rowspan="dataList.ScenicList.length">景点门票</td>
<table border="0" cellspacing="1" class="leaderPayTable leaderPayTable2">
<tr>
<th colspan="8" class="bgwhite">门票使用</th>
</tr>
<tr>
<th width="180">景点名称</th>
<th width="">门票类型</th>
<th width="">单价</th>
<th width="">付款方式 </th>
<th width="">金额小计</th>
<th width="">预计总金额</th>
<th width="">实付金额</th>
<th width="100">备注</th>
</tr>
<template v-for='(item,index) in list.ScenicList'>
<template v-for="(subItem,subIndex) in item.ScenicStatisticsList">
<tr v-for="(childItem,childIndex) in subItem.TicketPriceList">
<td v-if="childIndex==0" :rowspan="subItem.TicketPriceList.length">
{{subItem.ScenicName}}
</td>
<td>
<div
class="itemName"
v-for="subItem in item.ScenicStatisticsList"
>{{subItem.ScenicName}}</div>
{{peopleStrToWord(childItem.PeopleType)}}:{{childItem.PeopleNum}}
</td>
<td>
<div
v-for="subItem in item.ScenicStatisticsList"
>{{subItem.TotalPrice}} {{subItem.CurrencyStr}}</div>
<p>
{{subItem.PayStyle === 1 ? moneyFormat(childItem.PeoplePrice) : 0}}
</p>
</td>
<td v-if="childIndex==0" :rowspan="subItem.TicketPriceList.length">
<span v-if="subItem.PayStyle === 1">现付</span>
<span v-else-if="subItem.PayStyle === 2">公司结算</span>
<span v-else-if="subItem.PayStyle === 3">预付</span>
<span v-else-if="subItem.PayStyle === 6">公司合团支付</span>
<span v-else></span>
</br>
<span v-show="subItem.PayStyle==6">付款团号:{{subItem.PayTypeTCNUM}}</span>
</td>
<td>
<template v-for="(sitem,sindex) in item.ScenicStatisticsList">{{sitem.Remarks}}</template>
{{subItem.PayStyle === 1 ? moneyFormat((childItem.UsePeopleNum-childItem.Discount)*childItem.PeoplePrice) : 0}}
</td>
<td v-if="childIndex==0" :rowspan="subItem.TicketPriceList.length">
{{scenicTotalPrice(subItem, subItem.TicketPriceList)}}
</td>
<td v-if="childIndex==0" :rowspan="subItem.TicketPriceList.length">
{{subItem.TradingTotalPrice}}
</td>
<td v-if="childIndex==0" :rowspan="subItem.TicketPriceList.length">
{{subItem.Remarks}}
</td>
</tr>
</template>
<tr v-for="(item,index) in dataList.BusList">
<td v-if="index==0" :rowspan="dataList.BusList.length">交通</td>
<td>
{{item.ParkExplain}}
<!-- <span v-if='index==0'>接机</span>
<span v-if='index!=0&&index!=dataList.BusList.length-1'>{{item.AirportPickUpStr}}</span>
<span v-if='index==dataList.BusList.length-1'>送机</span>-->
</td>
<td>{{moneyFormat(item.TotalPrice)}} {{item.CurrencyStr}}</td>
<td>{{item.Remarks}}</td>
</tr>
<template v-for="(item,index) in dataList.DiningList">
<tr class="splitP ScenicTr">
<td v-if="index==0" :rowspan="dataList.DiningList.length">餐饮</td>
</template>
</table>
<table border="0" cellspacing="1" class="leaderPayTable leaderPayTable2">
<tr>
<th colspan="5" class="bgwhite">车辆使用</th>
</tr>
<tr>
<th width="">高速公路费</th>
<!-- <th width="">预计总金额</th>-->
<th width="">实付金额</th>
<th width="">备注</th>
</tr>
<tr v-for='(item,index) in list.BusList'>
<td>
{{item.HighSpeedPrice >= 0 && item.HighSpeedPrice !== null && item.HighSpeedPayType > 0 ? (item.HighSpeedPayType === 1 ? moneyFormat(item.HighSpeedPrice) : 0) : ''}}
</td>
<!-- <td v-if='index==0' :rowspan='list.BusList.length'>-->
<!-- {{busTotalPrice(list.BusList)}}-->
<!-- </td>-->
<td>
{{item.TotalPrice}}
</td>
<td>
{{item.Remarks}}
</td>
</tr>
</table>
<table border="0" cellspacing="1" class="leaderPayTable leaderPayTable2">
<tr>
<th colspan="9" class="bgwhite">餐食使用</th>
</tr>
<tr>
<th width="180">餐厅名称</th>
<th width="">类别</th>
<th width="">用餐人数</th>
<th width="">单价</th>
<th width="">付款方式</th>
<th width="">金额小计</th>
<th width="">预计总金额</th>
<th width="">实付金额</th>
<th width="100">备注</th>
</tr>
<template v-for='(item,index) in list.DiningList'>
<template v-for="(subItem,subIndex) in item.DiningSummaryList">
<tr v-for="(childItem,childIndex) in subItem.DiningPriceList">
<td v-if="childIndex==0" :rowspan="subItem.DiningPriceList.length">
{{subItem.RealName? subItem.RealName : subItem.DiningName}}
</td>
<td v-if="childIndex==0" :rowspan="subItem.DiningPriceList.length">
{{subItem.UseDinnerTypeStr}}
</td>
<td>
<div
class="itemName"
v-for="subItem in item.DiningSummaryList"
>{{subItem.NewDiningName}}</div>
{{peopleStrToWord(childItem.PeopleType)}}:{{childItem.PeopleNum}}
</td>
<td>
<div
v-for="subItem in item.DiningSummaryList"
>{{subItem.TotalPrice}} {{subItem.CurrencyStr}}</div>
<p>
{{subItem.PayStyle === 1 ? moneyFormat(childItem.PeoplePrice) : 0}}
</p>
</td>
<td v-if="childIndex==0" :rowspan="subItem.DiningPriceList.length">
<span v-if="subItem.PayStyle === 1">现付</span>
<span v-else-if="subItem.PayStyle === 2">公司结算</span>
<span v-else-if="subItem.PayStyle === 3">预付</span>
<span v-else-if="subItem.PayStyle === 6">公司合团支付</span>
<span v-else></span>
</br>
<span v-show="subItem.PayStyle==6">付款团号:{{subItem.PayTypeTCNUM}}</span>
</td>
<td>
<template v-for="(sitem,sindex) in item.DiningSummaryList">{{sitem.Remarks}}</template>
{{subItem.PayStyle === 1 ? moneyFormat((childItem.PeopleNum-childItem.Discount)*childItem.PeoplePrice) : 0}}
</td>
<td v-if="childIndex==0" :rowspan="subItem.DiningPriceList.length">
{{diningTotalPrice(subItem, subItem.DiningPriceList)}}
</td>
<td v-if="childIndex==0" :rowspan="subItem.DiningPriceList.length">{{subItem.TradingTotalPrice}}</td>
<td v-if="childIndex==0" :rowspan="subItem.DiningPriceList.length">
{{subItem.Remarks}}
</td>
</tr>
</template>
<template v-for="(item,index) in dataList.HotelList">
<tr>
<td v-if="index==0" :rowspan="dataList.HotelList.length">酒店</td>
<td width="30%">
<div class="itemName">{{item.NewHotelName}}</div>
</template>
</table>
<table border="0" cellspacing="1" class="leaderPayTable leaderPayTable2">
<tr>
<th colspan="9" class="bgwhite">酒店使用</th>
</tr>
<tr>
<th width="180">酒店名称</th>
<th width="">房间类型</th>
<th width="">预定人数 </th>
<th width="">单价/人</th>
<th width="">付款方式</th>
<th width="">金额小计</th>
<th width="">预计总金额</th>
<th width="">实付金额</th>
<th width="100">备注</th>
</tr>
<template v-for='(outItem,outIndex) in list.HotelOrderListReport'>
<template v-for="(subItem,subIndex) in outItem.HotelOrderList">
<tr v-for="(childItem,childIndex) in subItem.OrderDetailsList">
<td v-if="childIndex==0" :rowspan="subItem.OrderDetailsList.length">
{{subItem.HotelName}}
</td>
<td>
<span v-if="childItem.HouseType === 1">单间</span>
<span v-if="childItem.HouseType === 2">标准双人间</span>
<span v-if="childItem.HouseType === 3">大床房</span>
<span v-if="childItem.HouseType === 4">三人间</span>
<span v-if="childItem.HouseType === 5">司导间</span>
</td>
<td>
{{childItem.BookNum}}
</td>
<td>
<p>
{{subItem.PayStyle === 1 ? moneyFormat(childItem.UnitPrice) : 0}}
</p>
</td>
<td v-if="childIndex==0" :rowspan="subItem.OrderDetailsList.length">
<span v-if="subItem.PayStyle === 1">现付</span>
<span v-else-if="subItem.PayStyle === 2">签单</span>
<span v-else-if="subItem.PayStyle === 4">预付</span>
<span v-else-if="subItem.PayStyle === 5">实物抵扣</span>
<span v-else-if="subItem.PayStyle === 6">公司合团支付</span>
<span v-else></span>
</br>
<span v-show="subItem.PayStyle==6">付款团号:{{subItem.PayTypeTCNUM}}</span>
</td>
<td>
{{moneyFormat(childItem.UnitPrice*(childItem.BookNum-childItem.HotelDiscount))}}
</td>
<td v-if="childIndex==0" :rowspan="subItem.OrderDetailsList.length">
{{hotelTotalPrice(subItem.OrderDetailsList)}}
</td>
<td v-if="childIndex==0" :rowspan="subItem.OrderDetailsList.length">{{subItem.TradingTotalPrice}}</td>
<td v-if="childIndex==0" :rowspan="subItem.OrderDetailsList.length">
{{subItem.Remarks}}
</td>
<td>{{item.TotalPrice}} {{item.CurrencyStr}}</td>
<td>{{item.Remarks}}</td>
</tr>
</template>
<tr v-if="(dataList.ScenicList && !dataList.ScenicList.length) ||
(dataList.BusList && !dataList.BusList.length) ||
(dataList.DiningList && !dataList.DiningList.length) ||
(dataList.HotelList && !dataList.HotelList.length)">
<td colspan="4">暂无数据</td>
</tr>
</tbody>
</template>
</table>
<table border="0" cellspacing="1" class="leaderPayTable">
<tr>
<th>类型</th>
<th>预计总金额</th>
<th>金额</th>
</tr>
<tr v-show="totalList.SelfPayingExpendTotalPrice>0">
<td>自费支出</td>
<td>0</td>
<td>{{moneyFormat(totalList.SelfPayingExpendTotalPrice)}}</td>
</tr>
<tr v-show="totalList.SelfPayingIncomeTotalPrice>0">
<td>自费收入</td>
<td>0</td>
<td>{{moneyFormat(totalList.SelfPayingIncomeTotalPrice)}}</td>
</tr>
<!-- <tr v-show="totalList.IncomeTotalPrice>0">
......@@ -209,22 +348,27 @@ input[type="number"] {
v-show="(totalList.ExpendTotalPrice-totalScenicPrice-totalTrafficPrice-totalDinnerPrice-totalHotelPrice)>0"
>
<td>其他费用</td>
<td>0</td>
<td>{{moneyFormat(totalList.ExpendTotalPrice-totalScenicPrice-totalTrafficPrice-totalDinnerPrice-totalHotelPrice)}}</td>
</tr>
<tr v-show="totalScenicPrice>0">
<td>景点门票</td>
<td>{{moneyFormat(OtherTotalPrice)}}</td>
<td>{{moneyFormat(totalScenicPrice)}}</td>
</tr>
<tr v-show="totalTrafficPrice>0">
<td>交通</td>
<td>{{moneyFormat(SelfPayingExpendTotalPrice)}}</td>
<td>{{moneyFormat(totalTrafficPrice)}}</td>
</tr>
<tr v-show="totalDinnerPrice>0">
<td>餐饮</td>
<td>{{moneyFormat(IncomeTotalPrice)}}</td>
<td>{{moneyFormat(totalDinnerPrice)}}</td>
</tr>
<tr v-show="totalHotelPrice>0">
<td>酒店</td>
<td>{{moneyFormat(ExpendTotalPrice)}}</td>
<td>{{moneyFormat(totalHotelPrice)}}</td>
</tr>
</table>
......@@ -235,7 +379,7 @@ input[type="number"] {
<th>实际领款</th>
<th>实付合计</th>
<th>领队退款</th>
</tr>
</tr>
<tr
v-for="item in TotalPriceData"
v-if="item.PlanPrice > 0 || item.PlanTotalPrice > 0 || item.ExpendTotalPrice > 0"
......@@ -289,7 +433,7 @@ input[type="number"] {
<td colspan="7">暂无数据</td>
</tr>
</table>
<table class="leaderPayTable" border="0" cellspacing="1" cellpadding="0">
<table class="leaderPayTable" border="0" cellspacing="1" cellpadding="0" >
<tr>
<th width="140">团号</th>
<th width="200">实际领款</th>
......@@ -421,6 +565,11 @@ export default {
blankUrl: "",
TotalNav: [],
TimeXiao: false,
list:[],
OtherTotalPrice:0,
SelfPayingExpendTotalPrice:0,
IncomeTotalPrice:0,
ExpendTotalPrice:0,
};
},
methods: {
......@@ -436,7 +585,7 @@ export default {
TCIDList: TCIDARR,
Money: obj.LeaderGetPriceT,
TCNUMS: obj.TCNUMS
};
};
let fullPath = `/ChoiceAddFinancialDocuments?Type=${2}&templateID=${JSON.stringify(id)}&companyID=${obj.OutBranchId}&orderObj=${JSON.stringify(orderObj)}&blank=y&tab=领队报账`;
let dom = document.querySelector("#blankLink");
dom.href = `http://${window.location.host}/#${fullPath}`;
......@@ -458,8 +607,8 @@ export default {
if (res.data.resultCode == 1) {
let TotalNav = res.data.data;
TotalNav.forEach(x => {
TotalNav.LeaderGetPriceT = 0;
});
TotalNav.LeaderGetPriceT = 0;
});
this.TotalNav = TotalNav;
} else {
this.$message.error(res.data.message);
......@@ -501,6 +650,7 @@ export default {
this.totalDinnerPrice
).toFixed(2);
this.isShowRemark = true;
console.log(this.dataList)
} else {
this.Error(res.data.message);
}
......@@ -618,17 +768,100 @@ export default {
// tab: '领队报账'
// }
// })
},
getnewList(){
this.loading = true;
this.apipost('dmcstatistics_post_GetNewLeaderPayStatics_V1', this.msg, res => {
this.loading = false;
if (res.data.resultCode == 1) {
this.list = res.data.data;
// this.UseCount = this.list.UseCount;
// if (this.list.OtherOrderReportList.OtherList && this.list.OtherOrderReportList.OtherList.length > 0) {
// this.list.OtherOrderReportList.OtherList.forEach(x => {
// x.CostProject = x.CostProject.toString();
// });
// }
} else {
this.$message.error(res.data.message);
}
}, err => {})
},
peopleStrToWord(str) {
if (str == '1')
return '成人'
if (str == '2')
return '儿童'
if (str == '3')
return '小人'
},
scenicTotalPrice(sObj, obj) {
let totalPrice = 0
obj.forEach(x => {
totalPrice += x.PeoplePrice * (x.UsePeopleNum - x.Discount) * (1 - x.DiscountPrice / 100)
})
if (sObj.PayStyle !== 1) {
totalPrice = 0
}
return this.moneyFormat(totalPrice)
},
busTotalPrice(obj) {
let totalPrice = 0
obj.forEach(item => {
totalPrice += (item.PayType === 1 ? Number(item.CostPrice) : 0) + (item.HighSpeedPayType === 1 ? Number(
item.HighSpeedPrice) : 0) + Number(item.StopPrice)
})
return this.moneyFormat(totalPrice)
},
diningTotalPrice(sObj, obj) {
let totalPrice = 0
obj.forEach(x => {
totalPrice += x.PeoplePrice * (x.PeopleNum - x.Discount) * (1 - x.DiscountPrice / 100)
})
if (sObj.PayStyle !== 1) {
totalPrice = 0
}
return this.moneyFormat(totalPrice)
},
hotelTotalPrice(obj) {
let totalPrice = 0
obj.forEach(x => {
if (x.PayStyle === 1) {
totalPrice += x.UnitPrice * (x.BookNum - x.HotelDiscount) * (1 - x.RebateRatio / 100)
} else {
totalPrice += 0
}
})
return this.moneyFormat(totalPrice)
},
getzongJE(){
this.apipost('dmcstatistics_post_GetNewPlanTotalPrice', {
TCIDs: this.msg.TCIDs
}, res => {
if (res.data.resultCode == 1) {
let data = res.data.data.reimburseTotalPrice;
this.OtherTotalPrice = data.OtherTotalPrice
this.SelfPayingExpendTotalPrice = data.SelfPayingExpendTotalPrice
this.IncomeTotalPrice = data.IncomeTotalPrice
this.ExpendTotalPrice = data.ExpendTotalPrice
} else {
this.$message.error(res.data.message);
}
}, err => {})
}
},
created() {},
mounted() {
this.isUpdate = this.$route.query.isUpdate;
this.msg.TCIDs = this.$route.query.id;
this.getzongJE()
this.getNav();
this.getList();
this.getTotalMoney();
this.getTotalPrice();
this.getNavT();
this.getnewList()
this.getzongJE()
}
};
</script>
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