|
|
|
|
@ -351,6 +351,7 @@ import { getDateStr, lastYearDate } from '../../../common/util' |
|
|
|
|
// this.roadData.reportingUnitId = '522' |
|
|
|
|
let now = new Date(); |
|
|
|
|
this.roadData.statisticalDate = getDateStr(now, -1);//默认前一天 |
|
|
|
|
this.getRatio() |
|
|
|
|
// console.log('lastyear ===>',lastYearDate(this.roadData.statisticalDate)) |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@ -359,9 +360,15 @@ import { getDateStr, lastYearDate } from '../../../common/util' |
|
|
|
|
getDetail(id){ |
|
|
|
|
this.$request(getApp().globalData.baseUrl + '/api/biz/roadtransport/road/find/' + id,{},"GET").then(res =>{ |
|
|
|
|
this.roadData = res.data; |
|
|
|
|
this.getRatio() |
|
|
|
|
// console.log('last==>',lastYearDate(this.roadData.statisticalDate)) |
|
|
|
|
}) |
|
|
|
|
}, |
|
|
|
|
getRatio(){ |
|
|
|
|
this.$request(getApp().globalData.baseUrl + '/api/biz/roadtransport/road/findByStatisticalDate/' + this.roadData.statisticalDate,{},"GET").then(res =>{ |
|
|
|
|
console.log('比例数据===>',res) |
|
|
|
|
}) |
|
|
|
|
}, |
|
|
|
|
//选择统计日期 |
|
|
|
|
bindDateChange(e) { |
|
|
|
|
this.roadData.statisticalDate = e.detail.value; |
|
|
|
|
|