diff --git a/pages/commercialBI/specialCase.vue b/pages/commercialBI/specialCase.vue index b96e90f..88563e2 100644 --- a/pages/commercialBI/specialCase.vue +++ b/pages/commercialBI/specialCase.vue @@ -280,10 +280,13 @@ export default { this.handleTab(this.selectTab) }, handleBack(){ - uni.navigateBack({ - delta: 1 - }); - }, + uni.switchTab({ + url: '/pages/index/index' + }); + // uni.navigateBack({ + // delta: 1 + // }); + }, // 拿到服务区列表的方法 async handleGetServiceList(){ const req = { diff --git a/pages/index/index.vue b/pages/index/index.vue index bc8cb5a..8035b20 100644 --- a/pages/index/index.vue +++ b/pages/index/index.vue @@ -1611,6 +1611,7 @@ export default { showMoreFixed:false,// 显示悬浮框 profitSharingList:[],// 分润占比旁边的list isShowFestival:'qm',// 显示的节日 + oldSwiperIndex: 0,// 移动swiper 等待1秒钟 如果保持一致就请求 不一致就return } }, watch:{ @@ -2432,63 +2433,70 @@ export default { console.log('1') console.log('this.stopSwiper',this.stopSwiper) console.log('e',e.detail.current) - this.showRateChart = false - if (!this.stopSwiper){ - this.selectMonth = e.detail.current>11?(e.detail.current + 1)%12===0?12:(e.detail.current + 1)%12:e.detail.current + 1 + this.oldSwiperIndex = e.detail.current + setTimeout(()=>{ + if (this.oldSwiperIndex === e.detail.current){ + this.showRateChart = false + if (!this.stopSwiper){ + this.selectMonth = e.detail.current>11?(e.detail.current + 1)%12===0?12:(e.detail.current + 1)%12:e.detail.current + 1 + + this.selectMonthIndex = e.detail.current + this.selectDetail = e.detail.current + console.log('this.selectMonth',this.selectMonth) + console.log('this.selectDetail',this.selectDetail) + let y = e.detail.current>11? Math.floor((e.detail.current + 1)%12===0?(e.detail.current + 1)/12-1:(e.detail.current + 1)/12) : 0 + let m = e.detail.current>11?(e.detail.current + 1)%12===0?12:(e.detail.current + 1)%12:e.detail.current + 1 + const date = new Date(this.lastDay) + // let y = date.getFullYear() + // let m = e.detail.current + 1 + if(m<10){ + m='0'+m + } + this.single = `${2023+y}-${m}` + this.showTableData = null + this.currentPeriodData = null + // this.yesObj = null + this.typeList = [] + this.revenueMoney = '' + this.externalMoney = '' + this.carInfo = null + this.examineObj = null + this.trafficCurrentObj = null + this.trafficeUnit = null + this.trafficYOYObj = null + this.trafficQOQObj = null + this.dailyExamineObj = null + this.monthAdd = null + console.log('this.typeList',this.typeList) + // 月份详情卡片的详情 + this.initYesterdayData(this.selectMonth!==date.getMonth()+1) + // 自营计划 + // this.monthYearPlan() + // 切换月份的车流量变化 + // 是当前月份传入日期 不是当前日期传入月份 + let carDate + if (this.selectMonth === date.getMonth()+1){ + carDate = this.lastDay + }else{ + carDate = `${2023+y}-${m}` + } + this.getCarInfo(carDate) + // 切换考核的数据 + // this.handleGetExamine() + // 切换日常巡检数据 + // this.handleGetDailyPatrol() + // 获取全省平均车流量 + this.handleGetAllCarTraffic() + + }else{ + setTimeout(()=>{ + this.showRateChart = true + },1500) + } + } + },1000) - this.selectMonthIndex = e.detail.current - this.selectDetail = e.detail.current - console.log('this.selectMonth',this.selectMonth) - console.log('this.selectDetail',this.selectDetail) - let y = e.detail.current>11? Math.floor((e.detail.current + 1)%12===0?(e.detail.current + 1)/12-1:(e.detail.current + 1)/12) : 0 - let m = e.detail.current>11?(e.detail.current + 1)%12===0?12:(e.detail.current + 1)%12:e.detail.current + 1 - const date = new Date(this.lastDay) - // let y = date.getFullYear() - // let m = e.detail.current + 1 - if(m<10){ - m='0'+m - } - this.single = `${2023+y}-${m}` - this.showTableData = null - this.currentPeriodData = null - // this.yesObj = null - this.typeList = [] - this.revenueMoney = '' - this.externalMoney = '' - this.carInfo = null - this.examineObj = null - this.trafficCurrentObj = null - this.trafficeUnit = null - this.trafficYOYObj = null - this.trafficQOQObj = null - this.dailyExamineObj = null - this.monthAdd = null - console.log('this.typeList',this.typeList) - // 月份详情卡片的详情 - this.initYesterdayData(this.selectMonth!==date.getMonth()+1) - // 自营计划 - this.monthYearPlan() - // 切换月份的车流量变化 - // 是当前月份传入日期 不是当前日期传入月份 - let carDate - if (this.selectMonth === date.getMonth()+1){ - carDate = this.lastDay - }else{ - carDate = `${2023+y}-${m}` - } - this.getCarInfo(carDate) - // 切换考核的数据 - this.handleGetExamine() - // 切换日常巡检数据 - this.handleGetDailyPatrol() - // 获取全省平均车流量 - this.handleGetAllCarTraffic() - }else{ - setTimeout(()=>{ - this.showRateChart = true - },1500) - } }, handleShowYDModal(){ this.ydModal = !this.ydModal diff --git a/pages/nationalPage/testPage.vue b/pages/nationalPage/testPage.vue index 259517c..771a3bd 100644 --- a/pages/nationalPage/testPage.vue +++ b/pages/nationalPage/testPage.vue @@ -354,7 +354,7 @@ export default { data: [ { min: 0, - max:3000 + max: this.selectFestival===0?3000:1500 } ] },