Commit 4ff844c4 authored by huangyuanyuan's avatar huangyuanyuan
parents bb8d5eba 5c12f061
...@@ -400,5 +400,23 @@ var commonUtils = { ...@@ -400,5 +400,23 @@ var commonUtils = {
} }
return dateStr; return dateStr;
}, },
/**
* 增加减少天数
* date:可以不传
* day:正数
*/
AddDay(date, day) {
var myDate = "";
if (date) {
myDate = new Date(date);
} else {
myDate = new Date();
}
myDate = myDate.setDate(myDate.getDate() + day);
myDate = new Date(myDate);
//返回年月日
return myDate.getFullYear() + '-' + parseInt(myDate.getMonth() + 1) + "-" + myDate.getDate()
}
} }
export default commonUtils export default commonUtils
...@@ -433,11 +433,11 @@ ...@@ -433,11 +433,11 @@
</div> </div>
</div> </div>
<div class="w890px"> <div class="w890px">
<my-HB-Bill v-if="GetDetail.Is_Merge===1" :GetDetail="GetDetail" :isPrintPage="false" :width="widthSon" :color="colorSon"></my-HB-Bill> <my-HB-Bill v-if="GetDetail.Is_Merge===1" :ID="FrID" :FrID='FrID' :GetDetail="GetDetail" :isPrintPage="false" :width="widthSon" :color="colorSon"></my-HB-Bill>
</div> </div>
<p class="_splic">///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////</p> <p class="_splic">///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////</p>
<div class="_tit _tit2 w890px"> <div class="_tit _tit2 w890px">
<myGuanBill :FrID='FrID' :TemplateId='GetDetail.TemplateId' v-if="(GetDetail.TemplateId === 63 || GetDetail.TemplateId === 59 || GetDetail.TemplateId === 43 || GetDetail.TemplateId === 48 || GetDetail.TemplateId === 53 || GetDetail.TemplateId === 56) && showModel" /> <myGuanBill :ID="FrID" :FrID='FrID' :TemplateId='GetDetail.TemplateId' v-if="(GetDetail.TemplateId === 63 || GetDetail.TemplateId === 59 || GetDetail.TemplateId === 43 || GetDetail.TemplateId === 48 || GetDetail.TemplateId === 53 || GetDetail.TemplateId === 56) && showModel" />
</div> </div>
<template v-if="sonTCIDList"> <template v-if="sonTCIDList">
<div class="w890px"> <div class="w890px">
......
...@@ -441,7 +441,7 @@ ...@@ -441,7 +441,7 @@
</div> </div>
</div> </div>
</div> </div>
<my-HB-Bill v-if="GetDetail.Is_Merge===1 && ZhiDanRen!==bossID" :GetDetail="GetDetail" :isPrintPage="false" :width="widthSon" :color="colorSon"></my-HB-Bill> <my-HB-Bill v-if="GetDetail.Is_Merge===1 && ZhiDanRen!==bossID" :ID="FrID" :FrID='FrID' :GetDetail="GetDetail" :isPrintPage="false" :width="widthSon" :color="colorSon"></my-HB-Bill>
<!-- <myDJieBill v-if="GetDetail.DijieBathFinanceList && GetDetail.DijieBathFinanceList.length" :ID="GetDetail.FrID" :isPrintPage="false" :width="widthSon" :color="colorSon"/> --> <!-- <myDJieBill v-if="GetDetail.DijieBathFinanceList && GetDetail.DijieBathFinanceList.length" :ID="GetDetail.FrID" :isPrintPage="false" :width="widthSon" :color="colorSon"/> -->
<!--<my-C-Bill v-if="GetDetail.CashierDetail&&GetDetail.CashierDetail.length&&GetDetail.Type!=1" :ID="GetDetail.FrID" :width="widthSon" :color="colorSon"></my-C-Bill>--> <!--<my-C-Bill v-if="GetDetail.CashierDetail&&GetDetail.CashierDetail.length&&GetDetail.Type!=1" :ID="GetDetail.FrID" :width="widthSon" :color="colorSon"></my-C-Bill>-->
<div class="_fujian_box" v-if="(GetDetail.VorcherInos&&GetDetail.VorcherInos.length>0) || saveMsg.length>0"> <div class="_fujian_box" v-if="(GetDetail.VorcherInos&&GetDetail.VorcherInos.length>0) || saveMsg.length>0">
...@@ -523,7 +523,7 @@ ...@@ -523,7 +523,7 @@
</div> </div>
<p class="_splic">///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////</p> <p class="_splic">///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////</p>
<div class="_tit _tit2 w890px"> <div class="_tit _tit2 w890px">
<myGuanBill :FrID='FrID' :TemplateId='GetDetail.TemplateId' v-if="(GetDetail.TemplateId === 63 || GetDetail.TemplateId === 59 || GetDetail.TemplateId === 43 || GetDetail.TemplateId === 48 || GetDetail.TemplateId === 53 || GetDetail.TemplateId === 56) && showModel" /> <myGuanBill :ID="FrID" :FrID='FrID' :TemplateId='GetDetail.TemplateId' v-if="(GetDetail.TemplateId === 63 || GetDetail.TemplateId === 59 || GetDetail.TemplateId === 43 || GetDetail.TemplateId === 48 || GetDetail.TemplateId === 53 || GetDetail.TemplateId === 56) && showModel" />
</div> </div>
<template v-if="sonTCIDList"> <template v-if="sonTCIDList">
<div class="w890px"> <div class="w890px">
......
...@@ -121,7 +121,7 @@ ...@@ -121,7 +121,7 @@
</template> </template>
<script> <script>
export default { export default {
props:["ID","width","color","GetDetail"], //接收参数 ID width color props:["ID","width","color"], //接收参数 ID width color
data(){ data(){
return{ return{
picObj:[], picObj:[],
...@@ -129,6 +129,7 @@ export default { ...@@ -129,6 +129,7 @@ export default {
picIsShow:false, picIsShow:false,
allMoney:0, allMoney:0,
cnAllMoney:'', cnAllMoney:'',
GetDetail: {}
} }
},methods:{ },methods:{
showImg(obj){ showImg(obj){
...@@ -136,11 +137,11 @@ export default { ...@@ -136,11 +137,11 @@ export default {
this.picIsShow= true; this.picIsShow= true;
}, },
Financial_post_GetDetail(id){ //获取单据详情 Financial_post_GetDetail(id){ //获取单据详情
// if(!id) return if(!id) return
this.loading = true; this.loading = true;
// this.apipost('Financial_post_GetDetail',{ID:id}, res => { this.apipost('Financial_post_GetDetail',{ID:id}, res => {
// if(res.data.resultCode == 1) { if(res.data.resultCode == 1) {
let data= this.GetDetail; let data= res.data.data;
let Money = 0; let Money = 0;
data.DetailList.forEach(x=>{ data.DetailList.forEach(x=>{
x.UnitPrice = this.$commonUtils.addCommas(Math.round(x.UnitPrice * 100) / 100); x.UnitPrice = this.$commonUtils.addCommas(Math.round(x.UnitPrice * 100) / 100);
...@@ -158,26 +159,26 @@ export default { ...@@ -158,26 +159,26 @@ export default {
data.AuditSteps.reverse(); data.AuditSteps.reverse();
this.GetDetail = data; this.GetDetail = data;
this.loading=false; this.loading=false;
// } }
// }, err => {}) }, err => {})
}, },
},mounted(){ },mounted(){
this.Financial_post_GetDetail() this.Financial_post_GetDetail(this.ID)
},watch: { // 监听参数变化 },watch: { // 监听参数变化
// GetDetail: { GetDetail: {
// handler: function(val, oldVal) { handler: function(val, oldVal) {
// // console.log(val) // console.log(val)
// // console.log(oldVal) // console.log(oldVal)
// }, },
// deep: true deep: true
// }, },
// ID:{ ID:{
// handler: function(val, oldVal) { handler: function(val, oldVal) {
// this.ID = val this.ID = val
// this.Financial_post_GetDetail(this.ID) this.Financial_post_GetDetail(this.ID)
// }, },
// deep: true deep: true
// } }
} }
} }
</script> </script>
...@@ -277,7 +277,7 @@ ...@@ -277,7 +277,7 @@
</template> </template>
<script> <script>
export default { export default {
props:["ID","width","color","isPrintPage","name","GetDetail"], //接收参数 ID width color props:["ID","width","color","isPrintPage","name"], //接收参数 ID width color
data(){ data(){
return{ return{
loading:true, loading:true,
...@@ -290,6 +290,7 @@ ...@@ -290,6 +290,7 @@
}, },
images: [], images: [],
moneyObj: {}, moneyObj: {},
GetDetail: {}
} }
},methods:{ },methods:{
inited (viewer){ inited (viewer){
...@@ -337,7 +338,7 @@ ...@@ -337,7 +338,7 @@
this.loading = true; this.loading = true;
this.apipost('Financial_post_GetDetail',{ID:id}, res => { this.apipost('Financial_post_GetDetail',{ID:id}, res => {
if(res.data.resultCode == 1) { if(res.data.resultCode == 1) {
let data= this.GetDetail; let data= res.data.data;
data.DetailList.forEach(x=>{ data.DetailList.forEach(x=>{
x.UnitPrice = this.$commonUtils.addCommas(Math.round(x.UnitPrice * 100) / 100) x.UnitPrice = this.$commonUtils.addCommas(Math.round(x.UnitPrice * 100) / 100)
x.Money = Math.round(x.Money * 100) / 100 x.Money = Math.round(x.Money * 100) / 100
......
...@@ -324,7 +324,7 @@ ...@@ -324,7 +324,7 @@
</template> </template>
<script> <script>
export default { export default {
props:["ID","width","color","isPrintPage","name","OrderSource","GetDetail"], //接收参数 ID width color props:["ID","width","color","isPrintPage","name","OrderSource"], //接收参数 ID width color
data(){ data(){
return{ return{
loading:true, loading:true,
...@@ -334,6 +334,7 @@ export default { ...@@ -334,6 +334,7 @@ export default {
printTime:'', printTime:'',
currentMoney:0, currentMoney:0,
benMoney:0, benMoney:0,
GetDetail: {}
} }
},created(){ },created(){
let date = new Date(), let date = new Date(),
...@@ -377,7 +378,7 @@ export default { ...@@ -377,7 +378,7 @@ export default {
this.loading = true; this.loading = true;
this.apipost('Financial_post_GetDetail',{ID:id}, res => { this.apipost('Financial_post_GetDetail',{ID:id}, res => {
if(res.data.resultCode == 1) { if(res.data.resultCode == 1) {
let data= this.GetDetail; let data= res.data.data;
data.DetailList.forEach(x=>{ data.DetailList.forEach(x=>{
x.UnitPrice = this.$commonUtils.addCommas(Math.round(x.UnitPrice * 100) / 100) x.UnitPrice = this.$commonUtils.addCommas(Math.round(x.UnitPrice * 100) / 100)
x.Money = Math.round(x.Money * 100) / 100 x.Money = Math.round(x.Money * 100) / 100
......
...@@ -249,7 +249,7 @@ ...@@ -249,7 +249,7 @@
</template> </template>
<script> <script>
export default { export default {
props:["ID","width","color","isPrintPage","name","GetDetail"], //接收参数 ID width color props:["ID","width","color","isPrintPage","name"], //接收参数 ID width color
data(){ data(){
return{ return{
loading:false, loading:false,
...@@ -257,6 +257,7 @@ ...@@ -257,6 +257,7 @@
EmployeeId:'', EmployeeId:'',
EndDate:'', EndDate:'',
StartDate:'', StartDate:'',
GetDetail: {}
} }
},methods:{ },methods:{
jumpPage(path,id,type){ jumpPage(path,id,type){
...@@ -282,12 +283,12 @@ ...@@ -282,12 +283,12 @@
}) })
} }
}, },
Financial_post_GetDetail(){ //获取单据详情 Financial_post_GetDetail(id){ //获取单据详情
// if(!id) return if(!id) return
// this.loading = true; this.loading = true;
// this.apipost('Financial_post_GetDetail',{ID:id}, res => { this.apipost('Financial_post_GetDetail',{ID:id}, res => {
// if(res.data.resultCode == 1) { if(res.data.resultCode == 1) {
let data= this.GetDetail; let data= res.data.data;
data.DetailList.forEach(x=>{ data.DetailList.forEach(x=>{
x.UnitPrice = this.$commonUtils.addCommas(Math.round(x.UnitPrice * 100) / 100) x.UnitPrice = this.$commonUtils.addCommas(Math.round(x.UnitPrice * 100) / 100)
x.Money = Math.round(x.Money * 100) / 100 x.Money = Math.round(x.Money * 100) / 100
...@@ -300,10 +301,10 @@ ...@@ -300,10 +301,10 @@
data.AuditSteps.reverse() data.AuditSteps.reverse()
this.GetDetail = data; this.GetDetail = data;
this.loading=false this.loading=false
// this.$set(this.$data,"GetDetail",data); this.$set(this.$data,"GetDetail",data);
// console.log(this.GetDetail) console.log(this.GetDetail)
// } }
// }, err => {}) }, err => {})
}, },
},mounted(){ },mounted(){
console.log(this.GetDetail,"mounted") console.log(this.GetDetail,"mounted")
...@@ -315,23 +316,23 @@ ...@@ -315,23 +316,23 @@
this.EndDate = yaer + '-' + month + '-' + dateS; this.EndDate = yaer + '-' + month + '-' + dateS;
let userInfo = this.getLocalStorage(); let userInfo = this.getLocalStorage();
this.EmployeeId = userInfo.EmployeeId; this.EmployeeId = userInfo.EmployeeId;
this.Financial_post_GetDetail(); this.Financial_post_GetDetail(this.ID);
},watch: { // 监听参数变化 },watch: { // 监听参数变化
// GetDetail: { GetDetail: {
// handler: function(val, oldVal) { handler: function(val, oldVal) {
// // console.log(val) // console.log(val)
// // console.log(oldVal) // console.log(oldVal)
// }, },
// deep: true deep: true
// }, },
// ID:{ ID:{
// handler: function(val, oldVal) { handler: function(val, oldVal) {
// this.ID = val this.ID = val
// this.Financial_post_GetDetail(this.ID) this.Financial_post_GetDetail(this.ID)
// // console.log(val) // console.log(val)
// }, },
// deep: true deep: true
// } }
} }
} }
</script> </script>
...@@ -284,16 +284,17 @@ ...@@ -284,16 +284,17 @@
</template> </template>
<script> <script>
export default { export default {
props:[" ","width","color","isPrintPage","name","Num","OrderSource","GetDetail"], //接收参数 ID width color isPrintPage props:["ID","width","color","isPrintPage","name","Num","OrderSource"], //接收参数 ID width color isPrintPage
data(){ data(){
return{ return{
loading:false, loading: false,
EmployeeId:'', EmployeeId:'',
EndDate:'', EndDate:'',
StartDate:'', StartDate:'',
printTime:'', printTime:'',
currentMoney:0, currentMoney:0,
benMoney:0, benMoney:0,
GetDetail: {}
} }
},created(){ },created(){
let date = new Date(), let date = new Date(),
......
...@@ -716,23 +716,14 @@ ...@@ -716,23 +716,14 @@
calculationPrice(obj) { calculationPrice(obj) {
let totalPrice = 0; let totalPrice = 0;
obj.OrderDetailsList.forEach((item, index) => { obj.OrderDetailsList.forEach((item, index) => {
//税别 var tempPrice=0;
if (obj.TaxType == 2) { //税别 && item.RebateRatio>0
if (index == 4) { if (obj.TaxType == 2 ) {
if (obj.DriverGuideIsRebate == 1) { tempPrice= item.UnitPrice * (item.BookNum - item.HotelDiscount) * (1 + 0.08 - item.RebateRatio / 100);
totalPrice += item.UnitPrice * (item.BookNum - item.HotelDiscount) * (1 + 0.08 - item.RebateRatio /
100);
} else { } else {
totalPrice += item.UnitPrice * (item.BookNum - item.HotelDiscount) * (1 - item.RebateRatio / 100); tempPrice= item.UnitPrice * (item.BookNum - item.HotelDiscount) * (1 - item.RebateRatio / 100);
}
} else {
totalPrice += item.UnitPrice * (item.BookNum - item.HotelDiscount) * (1 + 0.08 - item.RebateRatio /
100);
}
} else {
totalPrice += item.UnitPrice * (item.BookNum - item.HotelDiscount) * (1 - item.RebateRatio / 100);
} }
totalPrice+=tempPrice;
}) })
totalPrice += obj.ParkFee + obj.CityTax + obj.InTangTax; totalPrice += obj.ParkFee + obj.CityTax + obj.InTangTax;
obj.TotalPrice = totalPrice.toFixed(2); obj.TotalPrice = totalPrice.toFixed(2);
......
...@@ -410,7 +410,7 @@ ...@@ -410,7 +410,7 @@
{{subItem.UseAccount}} {{subItem.UseAccount}}
</td> </td>
<td> <td>
{{peopleStrToWord(childItem.PeopleType)}}:{{childItem.PeopleNum}} {{peopleStrToWord(childItem.PeopleType)}}:{{childItem.UsePeopleNum}}
</td> </td>
<td> <td>
{{childItem.Discount}} {{childItem.Discount}}
...@@ -730,19 +730,9 @@ ...@@ -730,19 +730,9 @@
let totalPrice = 0; let totalPrice = 0;
obj.OrderDetailsList.forEach((item, index) => { obj.OrderDetailsList.forEach((item, index) => {
if (obj.PayStyle === 1) { if (obj.PayStyle === 1) {
//税别 //税别 && item.RebateRatio>0
if (obj.TaxType == 2) { if (obj.TaxType == 2) {
if (index == 4) { totalPrice += item.UnitPrice * (item.BookNum - item.HotelDiscount) * (1 + 0.08 - item.RebateRatio / 100);
if (obj.DriverGuideIsRebate == 1) {
totalPrice += item.UnitPrice * (item.BookNum - item.HotelDiscount) * (1 + 0.08 - item
.RebateRatio / 100);
} else {
totalPrice += item.UnitPrice * (item.BookNum - item.HotelDiscount) * (1 - item.RebateRatio / 100);
}
} else {
totalPrice += item.UnitPrice * (item.BookNum - item.HotelDiscount) * (1 + 0.08 - item.RebateRatio /
100);
}
//税入 //税入
} else { } else {
totalPrice += item.UnitPrice * (item.BookNum - item.HotelDiscount) * (1 - item.RebateRatio / 100); totalPrice += item.UnitPrice * (item.BookNum - item.HotelDiscount) * (1 - item.RebateRatio / 100);
......
...@@ -1191,7 +1191,7 @@ ...@@ -1191,7 +1191,7 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="成交单价" prop="Unit_Price" v-else> <el-form-item label="成交单价" prop="Unit_Price" v-else>
<el-input v-model='addMsg.Unit_Price' @change="getTotalPrice(3)"></el-input> <el-input v-model='addMsg.Unit_Price' @change="getTotalPrice(3)" ></el-input><!--:disabled="addMsg.GroupType==4" -->
</el-form-item> </el-form-item>
</template> </template>
<el-form-item label="高于本团单价" v-show="addMsg.GroupType != 4"> <el-form-item label="高于本团单价" v-show="addMsg.GroupType != 4">
...@@ -1206,7 +1206,7 @@ ...@@ -1206,7 +1206,7 @@
<el-col :span="5" v-else> <el-col :span="5" v-else>
<el-form-item label="成交单价" prop="Unit_Price"> <el-form-item label="成交单价" prop="Unit_Price">
<el-input v-model='addMsg.Unit_Price' class="w210" <el-input v-model='addMsg.Unit_Price' class="w210"
@keyup.native="checkPrice(addMsg,'Unit_Price');getTotalPrice()"></el-input> @keyup.native="checkPrice(addMsg,'Unit_Price');getTotalPrice()" ></el-input>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<p style="line-height: 18px; color: #E95252;">注:如果超出本团的最低让价,差价将由你来承担</p> <p style="line-height: 18px; color: #E95252;">注:如果超出本团的最低让价,差价将由你来承担</p>
...@@ -3248,6 +3248,7 @@ ...@@ -3248,6 +3248,7 @@
}, },
// 点击弹出下拉框 // 点击弹出下拉框
getDetail(obj) { getDetail(obj) {
console.log(obj)
this.Ysze = false; this.Ysze = false;
this.starTime = obj.StartDate; this.starTime = obj.StartDate;
this.endTime = obj.BackDate; this.endTime = obj.BackDate;
...@@ -3845,13 +3846,14 @@ ...@@ -3845,13 +3846,14 @@
} }
}, },
getTotalPrice(t) { getTotalPrice(t) {
console.log(t)
if (t === 3) { if (t === 3) {
if (parseFloat(this.addMsg.Unit_Price).toString() === "NaN") { if (parseFloat(this.addMsg.Unit_Price).toString() === "NaN") {
this.$message.error('请输入正确的价格!') this.$message.error('请输入正确的价格!')
this.addMsg.Unit_Price = this.addMsg.TC_Price this.addMsg.Unit_Price = this.addMsg.TC_Price
return return
} }
if (this.addMsg.Unit_Price < this.addMsg.TC_Price) { if (this.addMsg.Unit_Price < this.addMsg.TC_Price && this.addMsg.GroupType!=4) {
this.$message.error('成交单价必须大于等于本团单价!') this.$message.error('成交单价必须大于等于本团单价!')
this.addMsg.Unit_Price = this.addMsg.TC_Price this.addMsg.Unit_Price = this.addMsg.TC_Price
return return
...@@ -4966,7 +4968,7 @@ ...@@ -4966,7 +4968,7 @@
gettypechange(type) { gettypechange(type) {
//切换参团类型时 把值初始化 //切换参团类型时 把值初始化
if (type == 4) { if (type == 4) {
this.addMsg.Unit_Price = this.Unit_Price; //成交单价 this.addMsg.Unit_Price = this.addObj.SingleDMCPrice; //成交单价
this.HightUnitPrice = '1'; this.HightUnitPrice = '1';
this.addMsg.AirticketNum = 0; this.addMsg.AirticketNum = 0;
this.addMsg.ManNum = 0; this.addMsg.ManNum = 0;
......
<!--第三方酒店信息-->
<style>
.comCheckHotelV2 .comCheckHotelV2 {
width: 100%;
height: 150px;
overflow: auto
}
.comCheckHotelV2 .comCk_list {
padding: 0 20px;
margin: 0 15px 5px 0;
}
.comCheckHotelV2 .cm_Inventory {
margin-left: 20px;
color: red;
display: inline-block;
}
.comCheckHotelV2 .cm_hotelTitle {
width: 100%;
text-align: center;
margin-bottom: 20px;
border-bottom: 1px solid #d1d1d1;
padding: 0 20px 10px 20px;
}
.comCheckHotelV2 .com_SaveBtn {
margin: 10px 20px 0 45%;
}
.comCheckHotelV2 .ckedList {
background-color: #E95252;
color: #fff;
}
.comCheckHotelV2 .Ck_hotelInfo {
width: 100%;
height: 40px;
background-color: #F6F8FB;
text-align: center;
line-height: 40px;
margin-bottom: 10px;
}
.comCheckHotelV2 .ck_goUrl {
color: blue;
cursor: pointer;
margin-left: 10px;
}
.comCheckHotelV2 .tdLeft {
text-align: left;
}
.comCheckHotelV2 .tdRight {
text-align: right;
}
</style>
<template>
<div class="comCheckHotelV2">
<div class="Ck_hotelInfo">
酒店库存信息
</div>
<div class="cm_hotelTitle clearfix">
<table>
<tr>
<td class="tdRight">
类型:
</td>
<td class="tdLeft">
<el-select filterable v-model="qHotelType" class="w120" :placeholder="$t('pub.pleaseSel')">
<el-option label="地接酒店" :value='1'></el-option>
<el-option label="第三方酒店" :value='2'></el-option>
</el-select>
</td>
<td class="tdRight">
地区:
</td>
<td colspan="2" class="tdLeft">
<el-select filterable v-model="qMsg.ProvinceId" class="w120" :placeholder="$t('pub.pleaseSel')">
<el-option label="不限" :value='0'></el-option>
<el-option v-for="item in ProvinceList" :label='item.Name' :value='item.ID' :key='item.ID'>
</el-option>
</el-select>
</td>
</tr>
<tr>
<td class="tdRight">
入住时间:
</td>
<td class="tdLeft">
<el-date-picker v-model='qMsg.UseDate' class="w120" value-format="yyyy-MM-dd" type="date"
placeholder="入住时间">
</el-date-picker>
</td>
<td class="tdRight">
酒店名称/电话:
</td>
<td class="tdLeft">
<el-input type="text" v-model="qMsg.Name" class="w120" @keyup.native.enter="getCheckHotel()"
placeholder="酒店名称或电话"></el-input>
</td>
<td>
<input type="button" class="normalBtn" value="查询" @click="getCheckHotel()" />
</td>
</tr>
</table>
</div>
<div>
<el-tabs type="border-card" v-loading="loading" v-if="IsShow">
<el-tab-pane :label="item.ProvinceName" v-for="(item,index) in dataList" :key="item.subCode">
<div class="clearfix comCheckHotelV2">
<div class="comCk_list" v-for="(subItem,subIndex) in item.HotelList">
<input :id="'H'+index+'_'+subIndex" type="checkbox" v-model="subItem.isChecked"
@click="getCheck(item.HotelList,subIndex)" />
<label :for="'H'+index+'_'+subIndex" style="cursor: pointer">{{subItem.Name}}</label>
<span class="cm_Inventory">{{subItem.Inventory}}</span>
<span class="cm_Inventory">剩余:{{subItem.RemainingInventory}}</span>
<span class="ck_goUrl" @click="goUrl(subItem.ID)">新增库存</span>
</div>
</div>
</el-tab-pane>
</el-tabs>
</div>
<input type="button" class="normalBtn com_SaveBtn" @click="sendCkedHotel()" value="保存" />
</div>
</template>
<script>
export default {
props: [""],
data() {
return {
loading: false,
dataList: [],
ProvinceList: [],
qHotelType: 1, //酒店查询类型
qMsg: {
ProvinceId: 0, //选择个省份编号
Name: "", //酒店名称
UseDate: "", //入住时间
},
IsShow: false,
ckedHotel: {}
};
},
methods: {
getCheckHotel() {
this.loading = true;
this.IsShow = false;
this.dataList = [];
this.HotelList = [];
//地接酒店
if (this.qHotelType == 1) {
this.apipost('hotel_post_GetHasStockHotelList_V2', {
//1-只查询有库存的酒店
IsMoreThanZero: 0,
Country: "651",
IsAllHotel: 1,
Province: this.qMsg.ProvinceId,
Name: this.qMsg.Name,
sDate: this.qMsg.UseDate
}, res => {
this.loading = false;
this.IsShow = true;
if (res.data.resultCode == 1) {
this.dataList = res.data.data;
this.dataList.forEach(x => {
x.HotelList.forEach(y => {
y.isChecked = false;
})
})
} else {
this.Error(res.data.message)
}
}, err => {})
}
//第三方酒店
else {
var nQMsg = {
displayFrom: "1", //当前页
numberOfResults: "10", //每页条数
arrivalDate: this.qMsg.UseDate, //入住时间
departureDate: "", //离店时间
//房间信息列表
searchroomGroup: {
numberOfAdults: 2, //大人数,
numberOfChildren: 0, //儿童数
childAges: 0, //儿童年龄
},
searchHotelIdList:[],//酒店id,[1,2,3]
freeword:this.qMsg.Name,//关键字
//类型 1,地区,2-酒店名称
freewordType:0,
reviewRatingUpperLimits:0,//指定评论分数的上限
reviewRatingLowerLimits:0,//指定评论分数的下限
searchHotelCategory:[],//酒店分类
searchHotelFeatures:[],//酒店的特征
searchRoomType:[],//类型的房间
searchMealType:[],//饮食条件搜索
searchMinRate:0,//検索最小金額,
searchMinRate:100000,//検索最大金額
sort:0,//排序
};
if(nQMsg.arrivalDate=="")
{
this.Info("请选择入住时间!");
return;
}
else
{
nQMsg.departureDate=this.$commonUtils.AddDay(nQMsg.arrivalDate,1);
}
if(nQMsg.freeword!="")
{
nQMsg.freewordType=1;
}
else
{
nQMsg.freewordType=2;
nQMsg.freeword="";
}
console.log("nQMsg",nQMsg);
//多了一个参数调用线上的就酒店数据
this.apipost('dmc_post_Get_GetJAPAN_HotelList', nQMsg, res => {
this.loading = false;
this.IsShow = true;
if (res.data.resultCode == 1) {
console.log("res.data",res.data);
} else {
this.Error(res.data.message)
}
}, err => {},true)
}
},
getCheck(hotelList, index) {
hotelList.forEach((x, subIndex) => {
if (index == subIndex) {
x.isChecked = !x.isChecked;
this.ckedHotel = x;
} else {
x.isChecked = false;
}
})
this.$forceUpdate();
},
//向父组件传递选中酒店
sendCkedHotel() {
var ckHotelObj = {};
if (this.ckedHotel) {
ckHotelObj.ID = this.ckedHotel.ID;
ckHotelObj.Address = this.ckedHotel.Address;
ckHotelObj.Inventory = this.ckedHotel.Inventory;
ckHotelObj.Name = this.ckedHotel.Name;
ckHotelObj.PayStyle = this.ckedHotel.PayStyle;
ckHotelObj.Tel = this.ckedHotel.Tel;
ckHotelObj.RebateRatio = this.ckedHotel.RebateRatio;
ckHotelObj.RebateCount = this.ckedHotel.RebateCount;
ckHotelObj.CostPrice = this.ckedHotel.CostPrice;
}
this.$emit("childHotel", ckHotelObj);
},
//获取日本下面的市->下拉框用
getProvinceList() {
let msg = {
Id: 651
};
this.apipost("dict_post_Destination_GetChildList", msg, res => {
if (res.data.resultCode == 1) {
this.ProvinceList = res.data.data;
} else {
this.Error(res.data.message);
}
},
err => {}
);
},
goUrl(ID) {
this.$router.push({
path: 'HotelProductManage2',
query: {
id: ID,
Country: 651,
IsSelfBook: 1,
blank: 'y',
tab: '报价详情'
}
});
}
},
mounted() {
this.getProvinceList();
}
};
</script>
...@@ -109,10 +109,13 @@ ...@@ -109,10 +109,13 @@
<span v-if="IsDirect==1"> <span v-if="IsDirect==1">
<hotelTrip v-bind:subItemObj="subItem" v-bind:DefaultList="hotelSameList" v-bind:subIndex="subIndex" <hotelTrip v-bind:subItemObj="subItem" v-bind:DefaultList="hotelSameList" v-bind:subIndex="subIndex"
v-bind:DinnerList="DinnerList" v-bind:index="index" :isOpenGroup="isOpenGroup" v-bind:DinnerList="DinnerList" v-bind:index="index" :isOpenGroup="isOpenGroup"
v-bind:subTotalIndex="item.dayArray.length"></hotelTrip> v-bind:subTotalIndex="item.dayArray.length" ></hotelTrip>
<hotelTripV2 v-bind:subItemObj="subItem" v-bind:DefaultList="hotelSameList" v-bind:subIndex="subIndex"
v-bind:DinnerList="DinnerList" v-bind:index="index" :isOpenGroup="isOpenGroup"
v-bind:subTotalIndex="item.dayArray.length" style="display:none;"></hotelTripV2>
</span> </span>
<span v-else> <span v-else>
</span> </span>
</div> </div>
<div v-if="subItem.Type==$tripUtils.TypeKey.scenic"> <div v-if="subItem.Type==$tripUtils.TypeKey.scenic">
...@@ -120,7 +123,6 @@ ...@@ -120,7 +123,6 @@
<scienTrip v-bind:subItemObj="subItem" v-bind:DefaultList="scenicSameList" v-bind:subIndex="subIndex" <scienTrip v-bind:subItemObj="subItem" v-bind:DefaultList="scenicSameList" v-bind:subIndex="subIndex"
v-bind:index="index" :isOpenGroup="isOpenGroup" v-bind:subTotalIndex="item.dayArray.length"></scienTrip> v-bind:index="index" :isOpenGroup="isOpenGroup" v-bind:subTotalIndex="item.dayArray.length"></scienTrip>
</span> </span>
</div> </div>
<div v-if="subItem.Type==$tripUtils.TypeKey.dinner"> <div v-if="subItem.Type==$tripUtils.TypeKey.dinner">
<span v-if="IsDirect==1"> <span v-if="IsDirect==1">
...@@ -163,6 +165,7 @@ ...@@ -163,6 +165,7 @@
import trifficTrip from "../oldTravelGroupControl/trifficTrip"; import trifficTrip from "../oldTravelGroupControl/trifficTrip";
import scienTrip from "../oldTravelGroupControl/scienTrip_Direct"; import scienTrip from "../oldTravelGroupControl/scienTrip_Direct";
import hotelTrip from "../oldTravelGroupControl/hotelTrip_Direct"; import hotelTrip from "../oldTravelGroupControl/hotelTrip_Direct";
import hotelTripV2 from "../oldTravelGroupControl/hotelTrip_Direct_V2";
import dinnerTrip from "../oldTravelGroupControl/dinnerTrip_Direct"; import dinnerTrip from "../oldTravelGroupControl/dinnerTrip_Direct";
import freedomTrip from "../oldTravelGroupControl/freedomTrip"; import freedomTrip from "../oldTravelGroupControl/freedomTrip";
import warmtipTrip from "../oldTravelGroupControl/warmtipTrip"; import warmtipTrip from "../oldTravelGroupControl/warmtipTrip";
...@@ -270,16 +273,10 @@ export default { ...@@ -270,16 +273,10 @@ export default {
}, },
components: { components: {
trifficTrip: trifficTrip, trifficTrip: trifficTrip,
scienTrip: scienTrip, scienTrip: scienTrip,
hotelTrip: hotelTrip, hotelTrip: hotelTrip,
hotelTripV2: hotelTripV2,
dinnerTrip: dinnerTrip, dinnerTrip: dinnerTrip,
freedomTrip: freedomTrip, freedomTrip: freedomTrip,
warmtipTrip: warmtipTrip, warmtipTrip: warmtipTrip,
titleTrip: titleTrip titleTrip: titleTrip
......
...@@ -31,7 +31,6 @@ ...@@ -31,7 +31,6 @@
<div class="TDLeftPlan"> <div class="TDLeftPlan">
<span>入住酒店</span> <span>入住酒店</span>
<span> <span>
<el-form-item :prop="'DayList.'+index+'.dayArray.'+subIndex+'.childItem.HotelId'" :rules="hotelTripRules.HotelId"> <el-form-item :prop="'DayList.'+index+'.dayArray.'+subIndex+'.childItem.HotelId'" :rules="hotelTripRules.HotelId">
<el-select :disabled="isOpenGroup" class='w160' :placeholder="$t('pub.pleaseSel')" filterable v-model="subItemObj.childItem.HotelId" <el-select :disabled="isOpenGroup" class='w160' :placeholder="$t('pub.pleaseSel')" filterable v-model="subItemObj.childItem.HotelId"
@visible-change="getHotelList($event)" @change="changeHotelList()"> @visible-change="getHotelList($event)" @change="changeHotelList()">
......
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