Commit 75a8781e authored by huangyuanyuan's avatar huangyuanyuan

update

parent 3620f990
...@@ -463,6 +463,11 @@ ...@@ -463,6 +463,11 @@
height: 100%; height: 100%;
} }
/* 列表页样式 */ /* 列表页样式 */
.LocalTourList .item-pager .el-pagination__editor, .LocalTourList .item-pager .el-pager li, .LocalTourList .el-pagination .btn-next, .LocalTourList .el-pagination .btn-prev{
width: 30px;
height: 30px;
line-height: 30px;
}
.LocalTourList .tab{ .LocalTourList .tab{
border-bottom:2px solid #4CB960; border-bottom:2px solid #4CB960;
} }
...@@ -1023,7 +1028,7 @@ ...@@ -1023,7 +1028,7 @@
} }
.Appointment .payMoney p>span{ .Appointment .payMoney p>span{
display: inline-block; display: inline-block;
width: 100px; min-width: 100px;
margin-right:10px; margin-right:10px;
} }
...@@ -1042,6 +1047,7 @@ ...@@ -1042,6 +1047,7 @@
font-size:14px; font-size:14px;
line-height: 32px; line-height: 32px;
margin-left:15px; margin-left:15px;
cursor: pointer;
} }
.Appointment .Rotate .icon-more{ .Appointment .Rotate .icon-more{
......
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
</p> </p>
</div> </div>
<div class="threeDiv"> <div class="threeDiv">
<p><span style="color:#FDAC11;font-size:22px">{{item.b2bPrice}}</span></p> <p><span style="color:#FDAC11;font-size:22px">{{item.b2bPrice | NoDesnum}}</span></p>
</div> </div>
</li> </li>
<ul class="ticketDiv"> <ul class="ticketDiv">
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
<span class="ticketdes">{{item.name}} {{ticket.ticketDesc}}门票></span> <span class="ticketdes">{{item.name}} {{ticket.ticketDesc}}门票></span>
<span class="peopleType">{{ticket.ticketName}}</span></span> <span class="peopleType">{{ticket.ticketName}}</span></span>
<span class="SecondSpan"> <span class="SecondSpan">
<span class="price">{{ticket.b2bPrice}}</span> <span class="price">{{ticket.b2bPrice | NoDesnum}}</span>
<!-- <span style="color:#999999;font-size:12px;margin-left:7px;text-decoration: line-through">原价:¥300</span> --> <!-- <span style="color:#999999;font-size:12px;margin-left:7px;text-decoration: line-through">原价:¥300</span> -->
</span> </span>
<span class="ThreeSpan"> <span class="ThreeSpan">
...@@ -113,6 +113,7 @@ export default { ...@@ -113,6 +113,7 @@ export default {
height:24px; height:24px;
background:rgba(238,68,84,1); background:rgba(238,68,84,1);
color:#fff; color:#fff;
cursor: pointer;
} }
.AdmissionTicket .ticketDiv li .SecondSpan .price{ .AdmissionTicket .ticketDiv li .SecondSpan .price{
color: #FDAC11; color: #FDAC11;
......
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
</div> </div>
<div class="form"> <div class="form">
<el-form ref="form" :model="form" label-width="80px"> <el-form :rules="rules" ref="ruleForm" :model="form" label-width="80px">
<el-form-item class="formline" label="使用日期"> <el-form-item class="formline" label="使用日期">
<el-popover popper-class="calendarPopover" v-model="visible" <el-popover popper-class="calendarPopover" v-model="visible"
placement="bottom-start" placement="bottom-start"
...@@ -46,21 +46,21 @@ ...@@ -46,21 +46,21 @@
</el-form-item> </el-form-item>
<el-form-item label="购买数量"> <el-form-item label="购买数量">
<el-input-number size="small" v-model="form.purchaseQuantity" :min="1" :max="10" label="描述文字"></el-input-number> <el-input-number size="small" v-model="form.purchaseQuantity" :min="1" :max="10" @change="PurchaseQuantity"></el-input-number>
</el-form-item> </el-form-item>
<div class="fg"></div> <div class="fg"></div>
<div style="padding:0 20px"> <div style="padding:0 20px">
<p class="pfR" style="color:#000000;margin:30px 0">取票人/出行人信息</p> <p class="pfR" style="color:#000000;margin:30px 0">取票人/出行人信息</p>
<el-form-item class="formline" label="中文姓名"> <el-form-item class="formline" label="中文姓名" prop="contactCNName">
<el-input size="small" v-model="form.contactCNName"></el-input> <el-input size="small" v-model="form.contactCNName"></el-input>
</el-form-item> </el-form-item>
<el-form-item class="formline" label="英文姓名"> <el-form-item class="formline" label="英文姓名">
<el-input size="small" v-model="form.contactENName"></el-input> <el-input size="small" v-model="form.contactENName"></el-input>
</el-form-item> </el-form-item>
<el-form-item class="formline" label="手机号"> <el-form-item class="formline" label="手机号" prop="contactMobile">
<el-input size="small" v-model="form.contactMobile"></el-input> <el-input size="small" v-model="form.contactMobile"></el-input>
</el-form-item> </el-form-item>
<el-form-item class="formline" label="E-mail"> <el-form-item class="formline" label="E-mail" prop="contactEmail">
<el-input size="small" v-model="form.contactEmail"></el-input> <el-input size="small" v-model="form.contactEmail"></el-input>
</el-form-item> </el-form-item>
</div> </div>
...@@ -72,31 +72,38 @@ ...@@ -72,31 +72,38 @@
<div class="Yhq"> <div class="Yhq">
<p class="pfR" style="color:#000000;padding-left:20px">优惠券使用</p> <p class="pfR" style="color:#000000;padding-left:20px">优惠券使用</p>
<ul class="yhqUl"> <ul class="yhqUl">
<li v-for="(item,index) in CouponsList" :key="index+5000" class="sawtooth"> <li v-for="(item,index) in UserCanUseCouponList" :key="index+5000" class="sawtooth">
<span class="kdj" v-if="item.overlapUse==1">可叠加</span> <span class="kdj">
<span v-if="item.overlapUse==1">可叠加</span>
<span v-else>不可叠加</span>
</span>
<p style="margin-top:10px"><span>{{item.denomination}}</span></p> <p style="margin-top:10px"><span>{{item.denomination}}</span></p>
<p style="font-size:14px">{{item.useCondition}}使用</p> <p style="font-size:14px">{{item.useCondition}}使用</p>
<p style="font-size:12px;color:#4C58A4"> <p style="font-size:12px;color:#4C58A4;margin-top:6px">
有效期:{{item.effectDate | YMD}}-{{item.expirationDate | YMD}} 有效期:{{item.effectDate | YMD}}-{{item.expirationDate | YMD}}
<input class="input" type="checkbox" value="1" name="" />
</p> </p>
<div @click="clickCoupon(item)" class="_choice_box">
<span v-if="!item.active"></span>
<span v-else class="iconfont icon-xuanzhong2"></span>
</div>
</li> </li>
</ul> </ul>
<div style="border-bottom:1px dashed #E5E5E5"></div> <div style="border-bottom:1px dashed #E5E5E5"></div>
<div class="basefix" style="padding-right:20px"> <div class="basefix" style="padding-right:20px">
<div style="text-align:right"> <div style="text-align:right">
<div class="payMoney basefix"> <div class="payMoney basefix">
<p style="font-size:12px;margin-top:20px">小计:<span>2500</span></p> <p style="font-size:12px;margin-top:20px">小计:<span>{{price}}</span></p>
<p style="margin:7px 0">优惠:<span class="pfR">-¥2500</span></p> <p style="margin:7px 0">优惠:<span class="pfR">-¥{{form.discountMoney}}</span></p>
<p class="pfR">实付款:<span style="color:#AAAAAA;font-size:24px"><span style="color:#E95252;font-size:24px">2500</span></span></p> <p class="pfR">实付款:<span style="color:#AAAAAA;font-size:24px"><span style="color:#E95252;font-size:24px">{{SettlementPrice}}</span></span></p>
</div> </div>
</div> </div>
<div class="orderOk"> <div class="orderOk">
我已阅读并同意 我已阅读并同意
<span style="color:#39B372">预订须知、旅游合同、特别预订提示、安全提示</span> <span style="color:#39B372">预订须知、旅游合同、特别预订提示、安全提示</span>
<span class="orderPay">确认订单</span> <span @click="SaveOrder('ruleForm')" class="orderPay">确认订单</span>
</div> </div>
</div> </div>
</div> </div>
...@@ -117,7 +124,12 @@ export default { ...@@ -117,7 +124,12 @@ export default {
form:{ form:{
useDate:'', useDate:'',
purchaseQuantity:1, purchaseQuantity:1,
contactEmail:'',
discountMoney:0,
orderSource:2,
orderForm:1,
couponAllotIds:"",
customerId:0,
}, },
show:false, show:false,
idDes:0, idDes:0,
...@@ -131,11 +143,35 @@ export default { ...@@ -131,11 +143,35 @@ export default {
CouponsList:[], CouponsList:[],
Ticketinfo:{}, Ticketinfo:{},
dataDes:{}, dataDes:{},
rules: {
contactCNName: [
{ required: true, message: '请输入姓名', trigger: 'blur' }
],
contactMobile: [
{ required: true, message: '请输入联系电话', trigger: 'blur' },
{ required: true, trigger: 'blur', pattern: /^1[3|4|5|7|8][0-9]\d{8}$/ ,message: '请填写正确的手机号'}
],
contactEmail:[
{ type: 'email', message: '请输入正确的邮箱地址', trigger: ['blur', 'change'] }
]
},
CouponList:[],
UserCanUseCouponList:[],
CouponIds: '',
SettlementPrice:0,
price:0,
CheckedId:[],
} }
}, },
created(){ created(){
let userInfo=JSON.parse(localStorage.userInfo);
this.form.customerId=userInfo.customerId;
// console.log("StorageInfo.customerId",userInfo.customerId);
this.dataDes=JSON.parse(sessionStorage.dataDes); this.dataDes=JSON.parse(sessionStorage.dataDes);
this.Ticketinfo=JSON.parse(sessionStorage.Ticketinfo); this.Ticketinfo=JSON.parse(sessionStorage.Ticketinfo);
this.price=(this.Ticketinfo.b2bPrice*this.form.purchaseQuantity).toFixed(2);
this.SettlementPrice=this.price;
}, },
mounted() { mounted() {
this.idDes=decodeURIComponent(this.$route.query.idDes); this.idDes=decodeURIComponent(this.$route.query.idDes);
...@@ -143,9 +179,136 @@ export default { ...@@ -143,9 +179,136 @@ export default {
this.GetCoupons(); this.GetCoupons();
}, },
watch:{
price:{
handler(n, o){
if (n!==o && this.CouponList.length>0 ) {
this.SettlementPrice=n;
this.filterCoupon()
}
},
deep: true
},
},
methods: { methods: {
PurchaseQuantity(val){
this.price=(this.Ticketinfo.b2bPrice*val).toFixed(2);
},
clickCoupon: function (item) {
let list = [];
if (!item.active) { // 是否选中
if (item.overlapUse === 1) { // 1允许叠加使用
this.CouponList.forEach(x=>{
if (x.overlapUse === 1 && x.couponsType === item.couponsType) { // 优惠券列表筛选出允许叠加并且type相同的
list.push(x)
}
})
item.active = !item.active
this.UserCanUseCouponList = list
} else { // 不允许叠加使用
this.CouponList.forEach(x=>{ // 筛选掉其他
if (x.id === item.id) {
list.push(x)
}
})
item.active = !item.active
this.UserCanUseCouponList = list
}
} else {
item.active = !item.active
if (this.UserCanUseCouponList.length===1) { // 取消优惠券选中状态 之前直选择了一个优惠券
this.UserCanUseCouponList = this.CouponList
} else { //... 之前选择了多个优惠券 循环判断是否已全部取消
let num = 0
this.UserCanUseCouponList.forEach(x=>{
if (x.active)
num +=1
})
if (num===0) {
this.CouponList.forEach(x=>{
x.active = false
})
this.UserCanUseCouponList = this.CouponList
}
}
}
if (this.UserCanUseCouponList.length>0) {
let CouponIds = ''
let CouponMoney = 0
let CouponSale = 1
let type = 0
this.UserCanUseCouponList.forEach(x=>{
if (x.active) {
type = x.couponsType
CouponIds = CouponIds + x.id + ','
if (x.couponsType === 1) {
CouponMoney = CouponMoney + x.denomination
} else {
CouponSale = CouponSale * (x.denomination/10)
}
}
})
this.CouponIds = CouponIds
if (type === 1) {
this.SettlementPrice = this.price - CouponMoney
} else if (type === 2) {
this.SettlementPrice = this.price * CouponSale
} else if (type === 0) {
this.SettlementPrice = this.price
}
} else {
this.SettlementPrice = this.price
}
console.log("SettlementPrice",this.SettlementPrice)
// this.SettlementPrice=parseInt(this.SettlementPrice).toFixed(2);
let allmonney=this.price - this.SettlementPrice;
this.form.discountMoney = (this.price - this.SettlementPrice).toFixed(2);
this.CouponIds=this.CouponIds.substring(0,this.CouponIds.length-1)
this.form.couponAllotIds=this.CouponIds;
},
filterCoupon() {
let list = []
this.CouponList.forEach(x=>{
if (this.price>x.useCondition) {
x.active = false
list.push(x)
}
})
this.UserCanUseCouponList = list
},
SaveOrder(formName){
this.form.preferPrice=this.SettlementPrice;
if(this.form.useDate==""){
this.Error("请选择使用日期!")
return;
}
this.$refs[formName].validate((valid) => {
if (valid) {
this.apiJavaPost("/api/b2b/scenic/setTicketOrder",this.form,res => {
if(res.data.resultCode==1){
this.Success(res.data.message);
}else{
this.Error(res.data.message)
}
},
null
);
} else {
return false;
}
});
},
SelectChild(item) { SelectChild(item) {
console.log(item); console.log(item);
this.form.useDate=item.date_str; this.form.useDate=item.date_str;
this.form.couponsId=item.couponsId; this.form.couponsId=item.couponsId;
this.form.ticketId=item.ticketId; this.form.ticketId=item.ticketId;
...@@ -162,9 +325,12 @@ export default { ...@@ -162,9 +325,12 @@ export default {
}; };
this.apiJavaPost("/api/b2b/user/getUserCanUseCouponList",msg, this.apiJavaPost("/api/b2b/user/getUserCanUseCouponList",msg,
res => { res => {
console.log(res);
if(res.data.resultCode==1){ if(res.data.resultCode==1){
this.CouponsList=res.data.data; this.CouponList=res.data.data;
this.CouponList.forEach(item=>{
item.active=false;
})
this.filterCoupon();
} }
}, },
null null
...@@ -203,7 +369,7 @@ export default { ...@@ -203,7 +369,7 @@ export default {
let msg={ let msg={
price:time.b2bPrice, price:time.b2bPrice,
couponsId:time.couponsId, couponsId:time.couponsId,
id:time.id, priceId:time.id,
idDes:time.idDes, idDes:time.idDes,
ticketId:time.ticketId, ticketId:time.ticketId,
dateStr:item.dateStr, dateStr:item.dateStr,
...@@ -301,5 +467,23 @@ export default { ...@@ -301,5 +467,23 @@ export default {
<style scoped> <style scoped>
@import "../../assets/css/localtourhome.css"; @import "../../assets/css/localtourhome.css";
.Appointment ._choice_box{
height: 19px;
position: absolute;
right: 10px;
bottom: 8px;
}
.Appointment ._choice_box span{
width: 16px;
height: 16px;
border-radius: 50%;
line-height: 16px;
text-align: center;
background-color: white;
display: inline-block;
font-size: 12px !important;
}
.Appointment .icon-xuanzhong2{
color: #31AA21;
}
</style> </style>
...@@ -42,11 +42,12 @@ ...@@ -42,11 +42,12 @@
线路 线路
</div> </div>
<div class="tabRight spanMargin"> <div class="tabRight spanMargin">
<span @click="SelectLineId(0)" :class="msg.lineId==0?'spanActive':''">不限</span>
<span @click="SelectLineId(item.lineId)" :class="msg.lineId==item.lineId?'spanActive':''" v-for="(item,index) in lineTeamList" :key="index">{{item.lineShortName}}</span> <span @click="SelectLineId(item.lineId)" :class="msg.lineId==item.lineId?'spanActive':''" v-for="(item,index) in lineTeamList" :key="index">{{item.lineShortName}}</span>
</div> </div>
</li> </li>
<li v-if="tab==1"> <li v-if="tab==1 && lineList.length>0">
<div class="tabLeft"> <div class="tabLeft">
系列 系列
</div> </div>
...@@ -186,6 +187,16 @@ ...@@ -186,6 +187,16 @@
<OnedayList :onelist="onelist" v-show="tab==1"></OnedayList> <OnedayList :onelist="onelist" v-show="tab==1"></OnedayList>
<AdmissionTicket :ticketList="ticketList" v-show="tab==2"></AdmissionTicket> <AdmissionTicket :ticketList="ticketList" v-show="tab==2"></AdmissionTicket>
</div> </div>
<div style="text-align:right;width:950px;margin-top:15px">
<el-pagination
:page-size="msg.pageSize"
:current-page.sync="CurrentPage"
layout="total, prev, pager, next"
:total="totalCount"
@current-change="handleCurrentChange"
></el-pagination>
</div>
</div> </div>
</div> </div>
</template> </template>
...@@ -202,7 +213,11 @@ export default { ...@@ -202,7 +213,11 @@ export default {
maxPrice:"", maxPrice:"",
startDate:"", startDate:"",
endDate:"", endDate:"",
totalCount:0,
CurrentPage:1,
msg:{ msg:{
pageIndex:1,
pageSize:5,
lineId:0, lineId:0,
lineTeamId:0, lineTeamId:0,
startDate:"", startDate:"",
...@@ -259,23 +274,36 @@ export default { ...@@ -259,23 +274,36 @@ export default {
this.GetLine(); this.GetLine();
if(this.$route.query.tab){ if(this.$route.query.tab){
this.tab= this.$route.query.tab; this.tab= this.$route.query.tab;
if(this.tab==1){
this.GetList();
}else{
this.GetTicketList();
}
} }
}, },
mounted() { mounted() {
this.CountryCity(); this.CountryCity();
this.GetList();
this.GetTicketList();
}, },
methods: { methods: {
handleCurrentChange(val){
this.msg.pageIndex=val;
if(this.tab==1){
this.GetList();
}
if(this.tab==2){
this.GetTicketList();
}
},
GetTicketList(){ GetTicketList(){
this.Loading=true; this.Loading=true;
this.apiJavaPost('/api/b2b/scenic/getScenicTicketList',this.msg,res=>{ this.apiJavaPost('/api/b2b/scenic/getScenicTicketList',this.msg,res=>{
this.Loading=false; this.Loading=false;
if(res.data.resultCode==1){ if(res.data.resultCode==1){
this.ticketList=res.data.data.pageData; this.ticketList=res.data.data.pageData;
this.totalCount=res.data.data.count;
}else{ }else{
this.Error(res.data.message); this.Error(res.data.message);
...@@ -350,7 +378,7 @@ export default { ...@@ -350,7 +378,7 @@ export default {
if(this.maxPrice==""){ if(this.maxPrice==""){
this.msg.maxPrice=-1; this.msg.maxPrice=-1;
}else{ }else{
this.msg.minPrice=this.maxPrice; this.msg.maxPrice=this.maxPrice;
} }
if(!this.msg.startDate){ if(!this.msg.startDate){
this.msg.startDate=""; this.msg.startDate="";
...@@ -358,8 +386,10 @@ export default { ...@@ -358,8 +386,10 @@ export default {
if(!this.msg.endDate){ if(!this.msg.endDate){
this.msg.endDate=""; this.msg.endDate="";
} }
this.Loading=true; this.Loading=true;
this.apiJavaPost('/api/b2b/dayTrip/getDayTripProductList',this.msg,res=>{ this.apiJavaPost('/api/b2b/dayTrip/getDayTripProductList',this.msg,res=>{
this.totalCount=res.data.data.count;
this.Loading=false; this.Loading=false;
if(res.data.resultCode==1){ if(res.data.resultCode==1){
...@@ -410,16 +440,26 @@ export default { ...@@ -410,16 +440,26 @@ export default {
this.GetList(); this.GetList();
}, },
SelectLineId(lineId){ SelectLineId(lineId){
this.msg.lineId=lineId; this.msg.lineId=lineId;
this.lineTeamList.forEach(item=>{ if(lineId==0){
this.lineList=[];
this.msg.lineTeamId=0;
this.GetList();
}else{
this.lineTeamList.forEach(item=>{
if(lineId==item.lineId){ if(lineId==item.lineId){
this.lineList=item.lineTeamList; this.lineList=item.lineTeamList;
} }
}) })
}
}, },
ChangeTab(num){ ChangeTab(num){
this.tab=num; this.tab=num;
this.msg.pageIndex=1;
this.CurrentPage=1;
if(this.tab==1){ if(this.tab==1){
this.GetList(); this.GetList();
} }
...@@ -439,12 +479,12 @@ export default { ...@@ -439,12 +479,12 @@ export default {
if(this.$route.query.ltId){ if(this.$route.query.ltId){
this.msg.lineTeamId= this.$route.query.ltId this.msg.lineTeamId= this.$route.query.ltId
} }
if(this.msg.lineId==0){ // if(this.msg.lineId==0){
this.msg.lineId=this.lineTeamList[0].lineId; // this.msg.lineId=this.lineTeamList[0].lineId;
if(this.lineTeamList.length>0){ // if(this.lineTeamList.length>0){
this.lineList=this.lineTeamList[0].lineTeamList; // this.lineList=this.lineTeamList[0].lineTeamList;
} // }
} // }
}else{ }else{
this.Error(res.data.message); this.Error(res.data.message);
......
...@@ -150,7 +150,7 @@ ...@@ -150,7 +150,7 @@
</div> --> </div> -->
<div class="bottom"> <div class="bottom">
<span>{{item.name}}</span> <span>{{item.name}}</span>
<span class="font12 textHidden1">¥<a class="font14">{{item.b2bPrice | priceFormat}}</a>起/人</span> <span class="font12 textHidden1">¥<a class="font14">{{item.b2bPrice | NoDesnum}}</a>起/人</span>
</div> </div>
</li> </li>
</ul> </ul>
......
<template> <template>
<div class="OnedayList"> <div class="OnedayList">
<ul class="oneList"> <ul class="oneList">
<li v-for="(item,index) in dataList" :key="index+200"> <li @click="goOneDayDetail(item)" v-for="(item,index) in dataList" :key="index+200">
<div> <div>
<img style="width:199px;height:148px;" :src="item.imgCover[0].url" alt=""> <img style="width:199px;height:148px;" :src="item.imgCover[0].url" alt="">
</div> </div>
<div class="secondDiv"> <div class="secondDiv">
<p style="font-size:16px;color:#2A5532">{{item.title}}</p> <p style="font-size:16px;color:#2A5532">{{item.title}}</p>
<p class="taglist" style="margin-top:18px;"> <p class="taglist" style="margin-top:18px;">
<span>明日可订</span> <!-- <span>明日可订</span>
<span>明日可订</span> <span>明日可订</span> -->
</p> </p>
<p style="margin-top:14px;" class="font12"> <p style="margin-top:14px;" class="font12">
<i class="iconfont icon-bb-chufadi"></i> <i class="iconfont icon-bb-chufadi"></i>
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
</p> </p>
</div> </div>
<div class="threeDiv"> <div class="threeDiv">
<p><span style="color:#FDAC11;font-size:22px">{{item.b2BPrice}}</span></p> <p><span style="color:#FDAC11;font-size:22px">{{item.b2BPrice | NoDesnum}}</span></p>
<p style="margin-top:80px"><span class="ckxq" @click="GetDes(item)">查看详情</span></p> <p style="margin-top:80px"><span class="ckxq" @click="GetDes(item)">查看详情</span></p>
</div> </div>
</li> </li>
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
</ul> </ul>
<ul class="hottour_ul"> <ul class="hottour_ul">
<p class="pfR font14" style="margin-bottom:8px">历史浏览</p> <p class="pfR font14" style="margin-bottom:8px">历史浏览</p>
<li v-for="(item,index) in Historylist" :key="index+2000"> <li @click="goOneDayDetail(item)" v-for="(item,index) in Historylist" :key="index+2000">
<img :src="item.imgCover[0].url" alt=""> <img :src="item.imgCover[0].url" alt="">
<div class="hotcontent"> <div class="hotcontent">
<span class="textHidden font12">{{item.title}}</span> <span class="textHidden font12">{{item.title}}</span>
...@@ -63,6 +63,11 @@ export default { ...@@ -63,6 +63,11 @@ export default {
this.Historylist=arr; this.Historylist=arr;
}, },
methods: { methods: {
goOneDayDetail(item){
let path = 'OneDayDetailTwo';
path=`${path}/${encodeURIComponent(item.idDes)}/${item.tcid}`;
this.$router.push({ path })
},
GetDes(item){ GetDes(item){
if(this.Historylist.length>4 || this.Historylist.length==4){ if(this.Historylist.length>4 || this.Historylist.length==4){
this.Historylist.pop(); this.Historylist.pop();
...@@ -120,6 +125,7 @@ export default { ...@@ -120,6 +125,7 @@ export default {
.OnedayList .hottour_ul li{ .OnedayList .hottour_ul li{
position: relative; position: relative;
margin-bottom:14px; margin-bottom:14px;
cursor: pointer;
} }
.OnedayList .hottour_ul{ .OnedayList .hottour_ul{
width: 228px; width: 228px;
......
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
<p class="pfR" style="color:#2A5532;font-size:20px;">{{dataDes.name}}</p> <p class="pfR" style="color:#2A5532;font-size:20px;">{{dataDes.name}}</p>
<!-- <p style="margin-top:20px" class="ticketSpan">票类包括:<span>大小同价</span><span>大小价</span></p> --> <!-- <p style="margin-top:20px" class="ticketSpan">票类包括:<span>大小同价</span><span>大小价</span></p> -->
<div class="price"> <div class="price">
{{dataDes.minPrice | priceFormat}}~¥{{dataDes.maxPrice | priceFormat}} {{dataDes.minPrice | NoDesnum}}~¥{{dataDes.maxPrice | NoDesnum}}
</div> </div>
<p> <p>
<span style="color:#666666">景点地址:</span> <span style="color:#666666">景点地址:</span>
...@@ -76,7 +76,7 @@ ...@@ -76,7 +76,7 @@
<!-- <span class="colorG">可订今日</span> <!-- <span class="colorG">可订今日</span>
<span class="colorG">可订今日</span> --> <span class="colorG">可订今日</span> -->
</el-col> </el-col>
<el-col class="pfR" :span="3" style="color:#FDAC11"><span class="font22">{{item.b2bPrice | priceFormat}}</span></el-col> <el-col class="pfR" :span="3" style="color:#FDAC11"><span class="font22">{{item.b2bPrice | NoDesnum}}</span></el-col>
<el-col :span="2"> <el-col :span="2">
<span @click="YdUrl(dataDes,item)" class="ydBtn">预定</span> <span @click="YdUrl(dataDes,item)" class="ydBtn">预定</span>
</el-col> </el-col>
......
...@@ -163,7 +163,7 @@ export default { ...@@ -163,7 +163,7 @@ export default {
// dayDict.price = price.price; // dayDict.price = price.price;
dayDict.date_str=price.dateStr; dayDict.date_str=price.dateStr;
dayDict.couponsId=price.couponsId; dayDict.couponsId=price.couponsId;
dayDict.id=price.id; dayDict.priceId=price.priceId;
dayDict.ticketId=price.ticketId; dayDict.ticketId=price.ticketId;
if(dayIndex<strDate&&strMonth==currentMonth){ if(dayIndex<strDate&&strMonth==currentMonth){
dayDict.price=''; dayDict.price='';
......
...@@ -112,6 +112,22 @@ Vue.filter('priceFormat', function (value) { ...@@ -112,6 +112,22 @@ Vue.filter('priceFormat', function (value) {
x1 = x1.replace(rgx, '$1' + ',' + '$2'); x1 = x1.replace(rgx, '$1' + ',' + '$2');
} }
return x1 + x2; return x1 + x2;
})
// 不要小数点
Vue.filter('NoDesnum', function (value) {
if (value == null) {
return 0.00;
}
let nStr = value.toFixed(0)
nStr += '';
let x = nStr.split('.');
let x1 = x[0];
let x2 = x.length > 1 ? '.' + x[1] : '';
var rgx = /(\d+)(\d{3})/;
while (rgx.test(x1)) {
x1 = x1.replace(rgx, '$1' + ',' + '$2');
}
return x1 + x2;
}) })
// 时间格式YYYY-MM-DD // 时间格式YYYY-MM-DD
Vue.filter("YMD", function (date) { Vue.filter("YMD", function (date) {
......
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