Commit 9b25b30b authored by youjie's avatar youjie

no message

parent f91bbce8
......@@ -126,8 +126,8 @@ export default {
new Date(this.prices[0].startDate),
"YYYY/MM"
);
this.currentMonth =
this.months.findIndex((x) => x.monthValue == firstMonth) ?? 0;
let current = this.months.findIndex((x) => x.monthValue == firstMonth)
this.currentMonth = current>-1?current:0;
this.changeMonthHandler();
},
createChosenDateHandler() {
......
......@@ -72,7 +72,7 @@ export default {
x.title = y.childItem.title;
} else if (y.type == 1) {
y.subtitle =
y.childItem.subTraffic[0].startTime +
y.childItem.subTraffic.length>0&&y.childItem.subTraffic[0].startTime +
" - " +
y.childItem.subTraffic[y.childItem.subTraffic.length - 1]
.endTime;
......@@ -109,7 +109,7 @@ export default {
}
},
formatTraffice(tras) {
let txt = "從" + tras[0].startCityName;
let txt = "從" + tras.length>0&&tras[0].startCityName;
tras.forEach((z, i) => {
if (i > 0) {
txt = ";再";
......
......@@ -336,7 +336,7 @@ export default {
x.title = y.childItem.title;
} else if (y.type == 1) {
y.subtitle =
y.childItem.subTraffic[0].startTime +
y.childItem.subTraffic.length>0&&y.childItem.subTraffic[0].startTime +
" - " +
y.childItem.subTraffic[y.childItem.subTraffic.length - 1]
.endTime;
......@@ -352,7 +352,7 @@ export default {
}
},
formatTraffice(tras) {
let txt = "從" + tras[0].startCityName;
let txt = "從" + tras.length>0&&tras[0].startCityName;
tras.forEach((z, i) => {
if (i > 0) {
txt = ";再";
......
......@@ -758,9 +758,9 @@ export default {
if (localStorage.baseifo) {
this.TripConfig = JSON.parse(window.localStorage.getItem("baseifo"));
}
// this.getData();
this.getData();
window.addEventListener("scroll", this.menu);
this.getCarData();
// this.getCarData();
},
methods: {
getTopNum(x) {
......@@ -860,7 +860,9 @@ export default {
changeChosenDateHandler(val) {
val.price.version = new Date().getTime();
this.currentPrice = JSON.parse(JSON.stringify(val.price));
this.$refs.qDateProxy.hide();
if(this.$q.platform.is.mobile){
this.$refs.qDateProxy.hide();
}
},
showDialog() {
this.isShowDialog = true;
......
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