按照表格添加道路运输页面字段计算,修改列表查询样式,统一字段格式

main
jinna 3 years ago
parent b8d39386b2
commit ecd599f6f7
  1. 12
      pages.json
  2. 33
      pages/bus/busDataInfo/form.vue
  3. 42
      pages/bus/busDataInfo/list.vue
  4. 5
      pages/portShipping/pilotStation/form.vue
  5. 43
      pages/portShipping/pilotStation/list.vue
  6. 3
      pages/roadTransport/dataSubmission/form.vue
  7. 44
      pages/roadTransport/dataSubmission/list.vue
  8. 110
      pages/roadTransport/transportData/form.vue
  9. 26
      pages/roadTransport/transportData/list.vue

@ -177,7 +177,8 @@
{
"path": "pages/roadTransport/dataSubmission/list",
"style": {
"navigationBarTitleText": "综合运输数据报送"
"navigationBarTitleText": "综合运输数据报送",
"enablePullDownRefresh": true
}
},
{
@ -189,7 +190,8 @@
{
"path": "pages/roadTransport/quantitySent/list",
"style": {
"navigationBarTitleText": "道路运输发送量"
"navigationBarTitleText": "道路运输发送量",
"enablePullDownRefresh": true
}
},
{
@ -207,7 +209,8 @@
{
"path": "pages/bus/busDataInfo/list",
"style": {
"navigationBarTitleText": "公交投入数据"
"navigationBarTitleText": "公交投入数据",
"enablePullDownRefresh": true
}
}
,{
@ -219,7 +222,8 @@
{
"path": "pages/portShipping/pilotStation/list",
"style": {
"navigationBarTitleText": "引航站"
"navigationBarTitleText": "引航站",
"enablePullDownRefresh": true
}
},
{

@ -47,7 +47,7 @@
<view v-if='item.isFinish' class="tag">
<uni-icons type="checkmarkempty" color="#fff" size="12"></uni-icons>
</view>
{{item.stationId || ''}}
{{item.stationName || ''}}
</view>
<view v-if="index >= 9 && showLand" :style="(index+1)%3 == 0 ? 'margin-right:0;':''"
@click="changeLandNameIndex(index)" class="station_item"
@ -56,7 +56,7 @@
<view v-if='item.isFinish' class="tag">
<uni-icons type="checkmarkempty" color="#fff" size="12"></uni-icons>
</view>
{{item.stationId || ''}}
{{item.stationName || ''}}
</view>
</view>
<view v-if="landList.length > 9" class="station_act" @click="showLand = !showLand">
@ -112,9 +112,9 @@
</view>
</view>
<view class="form_item">
<view class="form_item_label">人数()</view>
<view class="form_item_label">人数()</view>
<view class="form_item_input form_input">
<uni-easyinput @blur="calcYoyMom(landNameIndex)" @clear="calcYoyMom(landNameIndex)" type="digit"
<uni-easyinput @blur="calcYoyMom(landNameIndex)" @clear="calcYoyMom(landNameIndex)" type="number"
v-model="form.bizBusDataDetailVOList[landNameIndex].passengerCount"
placeholderStyle="color: #D4D4D4;font-size:28rpx;" placeholder="请输入" maxlength="20">
</uni-easyinput>
@ -275,7 +275,7 @@
this.landList.map(item => {
item.isFinish = false;
this.form.bizBusDataDetailVOList.push({
// "landName": item.stationId,
// "landName": item.stationName,
// "lastYearpassengerCount": '',
// "lastYearvehicleInput": '',
// "passengerCount": '',
@ -286,7 +286,7 @@
// "vehicleInputYearOnYear": '',
// "yestPassengerCount": '',
// "yesterdayvehicleInput": '',
busUnit:item.stationId,
busUnit:item.stationName,
// busIndex:'',
vehicleInput:'',
vehicleInputMom:0,
@ -306,14 +306,14 @@
})
} else {
// this.landList = [
// {stationId: ""},
// {stationId: ""},
// {stationId: ""},
// {stationName: ""},
// {stationName: ""},
// {stationName: ""},
// ]
let arr = JSON.parse(JSON.stringify(this.form.bizBusDataDetailVOList));
this.form.bizBusDataDetailVOList = [];
this.landList.map(item => {
let idx = arr.findIndex(item2 => item2.busUnit == item.stationId);
let idx = arr.findIndex(item2 => item2.busUnit == item.stationName);
console.log(idx)
if (idx > -1) {
item.isFinish = checkNotEmpty(arr[idx].passengerCount) && checkNotEmpty(arr[idx].vehicleInput) ? true :
@ -322,7 +322,7 @@
} else {
item.isFinish = false;
this.form.bizBusDataDetailVOList.push({
"busUnit": item.stationId,
"busUnit": item.stationName,
"lastYearpassengerCount": '',
"lastYearvehicleInput": '',
"passengerCount": '',
@ -411,14 +411,16 @@
// .vehicleInput) === 0 ? 0 : lastYearData.vehicleInput === 0 && parseInt(obj.vehicleInput) > 0 ? 100 : (parseInt(obj
// .vehicleInput) - lastYearData.vehicleInput) / lastYearData.vehicleInput * 100;
this.form.bizBusDataDetailVOList[landNameIndex].passengerCountMom = calcMom(checkNotEmpty(obj.passengerCount) ? obj.passengerCount * 10000 : obj.passengerCount,checkNotEmpty(yesterdayData.passengerCount) ? yesterdayData.passengerCount * 10000 : yesterdayData.passengerCount)
// passengerCount
// this.form.bizBusDataDetailVOList[landNameIndex].passengerCountMom = calcMom(checkNotEmpty(obj.passengerCount) ? obj.passengerCount * 10000 : obj.passengerCount,checkNotEmpty(yesterdayData.passengerCount) ? yesterdayData.passengerCount * 10000 : yesterdayData.passengerCount)
this.form.bizBusDataDetailVOList[landNameIndex].passengerCountMom = calcMom(obj.passengerCount,res.data.lastYearData.passengerCount)
// !checkNotEmpty(obj
// .passengerCount) ? '' : !checkNotEmpty(yesterdayData.passengerCount) ? '' : yesterdayData
// .passengerCount === 0 && parseInt(obj.passengerCount) === 0 ? 0 : yesterdayData.passengerCount === 0 &&
// parseInt(obj.passengerCount) > 0 ? 100 : (parseInt(obj.passengerCount) - yesterdayData.passengerCount) /
// yesterdayData.passengerCount * 100;
console.log('check ==>',yesterdayData.passengerCount,checkNotEmpty(yesterdayData.passengerCount))
this.form.bizBusDataDetailVOList[landNameIndex].passengerCountYoy = calcYoy(checkNotEmpty(obj.passengerCount) ? obj.passengerCount * 10000 : obj.passengerCount, checkNotEmpty(res.data.lastYearData.passengerCount) ? res.data.lastYearData.passengerCount * 10000 : res.data.lastYearData.passengerCount)
// this.form.bizBusDataDetailVOList[landNameIndex].passengerCountYoy = calcYoy(checkNotEmpty(obj.passengerCount) ? obj.passengerCount * 10000 : obj.passengerCount, checkNotEmpty(res.data.lastYearData.passengerCount) ? res.data.lastYearData.passengerCount * 10000 : res.data.lastYearData.passengerCount)
this.form.bizBusDataDetailVOList[landNameIndex].passengerCountYoy = calcYoy(obj.passengerCount,res.data.lastYearData.passengerCount)
// !checkNotEmpty(obj
// .passengerCount) ? '' : !checkNotEmpty(lastYearData.passengerCount) ? '' : lastYearData
// .passengerCount === 0 && parseInt(obj.passengerCount) === 0 ? 0 : lastYearData.passengerCount === 0 &&
@ -470,7 +472,8 @@
if (this.pageType == 'add') {
let now = new Date();
//11:00-13:30 0-12
let dateStr = getDateStr(now, 0);
// let dateStr = getDateStr(now, 0);
let dateStr = getDateStr(now, 0).replaceAll('-','/');
if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() <
new Date(dateStr +
' 13:30').getTime()) {

@ -26,7 +26,7 @@
</view>
</view>
<view class="pop_conbox">
<uni-popup ref="popup" style="width: 100%;" background-color="#fff">
<uni-popup ref="popup" style="width: 100%;">
<view class="pop_box">
<view class="pop_title">
查询条件
@ -39,7 +39,7 @@
<view class="time_box">
<uni-datetime-picker v-model="timeRange" type="daterange" />
</view>
<!-- <view class="cont_tit picker">
<view class="cont_tit picker">
<view>统计时段</view>
<view class="picker_select">
<picker @change="bindPickerChange" :value="index" :range="timeArray" range-key="dictLabel">
@ -48,7 +48,7 @@
<uni-icons type="right" size="16" color="#D4D4D4"></uni-icons>
</picker>
</view>
</view> -->
</view>
</view>
<view class="btn_box">
<p class="btn" @click="searchReset">重置</p>
@ -75,6 +75,9 @@
contentnomore: "没有更多数据了",
},
status: '',
timeArray:[],
timeName:'',
reportPhase:'',
}
},
@ -82,6 +85,14 @@
this.page = 0;
this.hasMore = true;
this.listData = [];
this.queryTime();
this.loadMore()
},
onPullDownRefresh() {
this.page = 0;
this.hasMore = true;
this.listData = [];
this.queryTime();
this.loadMore()
},
methods: {
@ -94,7 +105,8 @@
pageSize:this.pageSize,
reportDateStart:this.timeRange.length !== 0 ? this.timeRange[0] : '',
reportDateEnd:this.timeRange.length !== 0 ? this.timeRange[1] : '',
_t:Date.parse(new Date())
_t:Date.parse(new Date()),
statPeriod:this.reportPhase
}
this.$request(getApp().globalData.baseUrl + '/api/biz/busdata/list',params,"GET").then(res =>{
console.log(res)
@ -117,6 +129,13 @@
handleSearch(){
this.$refs.popup.open('bottom')
},
//
queryTime() {
this.$request(getApp().globalData.baseUrl + '/api/dict/dictList?dictType=airport_time' + '&_t=' + Date.parse(
new Date()), {}, 'GET').then(res => {
this.timeArray = res.data;
})
},
//
searchList(){
this.hasMore = true;
@ -128,12 +147,23 @@
//
searchReset(){
this.timeRange = [];
this.timeName = '';
this.reportPhase = ''
this.listData = [];
this.hasMore = true;
this.page = 0;
this.$refs.popup.close()
this.loadMore();
},
//
bindPickerChange(e){
let index = e.target.value //
var selected = this.timeArray[index] //
console.log(selected)
this.timeName = selected.dictLabel
this.reportPhase = selected.dictValue;
// this.timeName = this.timeArray[index].dictLabel)
},
//
editItem(row){
uni.navigateTo({
@ -299,10 +329,8 @@
left: 0;
right: 0;
bottom: 0;
display: flex;
justify-content: space-around;
background-color: #F8F8F8;
padding: 20px 30rpx;
padding: 20px 30rpx 40px;
.act_btn {
width: 690rpx;

@ -231,10 +231,11 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr } from '../../../common/uti
this.timeName = item.dictLabel
}
})
// this.getRatio()
this.getYoyMom()
}else if(this.pageType == 'add'){
let now = new Date();
let dateStr = getDateStr(now,0);
// let dateStr = getDateStr(now,0);
let dateStr = getDateStr(now, 0).replaceAll('-','/');
if(new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < new Date(dateStr + ' 13:30').getTime()) {
this.form.statPeriod = "0012";
this.index = this.roadTime.findIndex(item => item.dictValue == "0012")

@ -26,7 +26,7 @@
</view>
</view>
<view class="pop_conbox">
<uni-popup ref="popup" style="width: 100%;" background-color="#fff">
<uni-popup ref="popup" style="width: 100%;">
<view class="pop_box">
<view class="pop_title">
查询条件
@ -39,7 +39,7 @@
<view class="time_box">
<uni-datetime-picker v-model="timeRange" type="daterange" />
</view>
<!-- <view class="cont_tit picker">
<view class="cont_tit picker">
<view>统计时段</view>
<view class="picker_select">
<picker @change="bindPickerChange" :value="index" :range="timeArray" range-key="dictLabel">
@ -48,7 +48,7 @@
<uni-icons type="right" size="16" color="#D4D4D4"></uni-icons>
</picker>
</view>
</view> -->
</view>
</view>
<view class="btn_box">
<p class="btn" @click="searchReset">重置</p>
@ -75,13 +75,23 @@
contentnomore: "没有更多数据了",
},
status: '',
timeArray:[],
timeName:'',
reportPhase:'',
}
},
onShow() {
this.page = 0;
this.hasMore = true;
this.listData = [];
this.queryTime();
this.loadMore()
},
onPullDownRefresh() {
this.page = 0;
this.hasMore = true;
this.listData = [];
this.queryTime();
this.loadMore()
},
methods: {
@ -94,7 +104,8 @@
pageSize:this.pageSize,
reportDateStart:this.timeRange.length !== 0 ? this.timeRange[0] : '',
reportDateEnd:this.timeRange.length !== 0 ? this.timeRange[1] : '',
_t:Date.parse(new Date())
_t:Date.parse(new Date()),
statPeriod:this.reportPhase
}
this.$request(getApp().globalData.baseUrl + '/api/biz/bizPilotData/list',params,"GET").then(res =>{
console.log(res)
@ -125,15 +136,33 @@
this.$refs.popup.close()
this.loadMore()
},
//
queryTime() {
this.$request(getApp().globalData.baseUrl + '/api/dict/dictList?dictType=airport_time' + '&_t=' + Date.parse(
new Date()), {}, 'GET').then(res => {
this.timeArray = res.data;
})
},
//
searchReset(){
this.timeRange = [];
this.timeName = '';
this.reportPhase = ''
this.listData = [];
this.hasMore = true;
this.page = 0;
this.$refs.popup.close()
this.loadMore();
},
//
bindPickerChange(e){
let index = e.target.value //
var selected = this.timeArray[index] //
console.log(selected)
this.timeName = selected.dictLabel
this.reportPhase = selected.dictValue;
// this.timeName = this.timeArray[index].dictLabel)
},
//
editItem(row){
uni.navigateTo({
@ -300,10 +329,8 @@
left: 0;
right: 0;
bottom: 0;
display: flex;
justify-content: space-around;
background-color: #F8F8F8;
padding: 20px 30rpx;
padding: 20px 30rpx 40px;
.act_btn {
width: 690rpx;

@ -159,7 +159,8 @@
this.timeName = this.roadTime.find(item => item.dictValue == this.synthData.reportPhase).dictLabel
}else if(this.pageType == 'add'){
let now = new Date();
let dateStr = getDateStr(now,0);
// let dateStr = getDateStr(now,0);
let dateStr = getDateStr(now, 0).replaceAll('-','/');
if(new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < new Date(dateStr + ' 13:30').getTime()){
this.synthData.reportPhase = "0012";
this.index = this.roadTime.findIndex(item => item.dictValue == "0012")

@ -37,7 +37,7 @@
</view>
</view>
<view class="pop_conbox">
<uni-popup ref="popup" style="width: 100%;" background-color="#fff">
<uni-popup ref="popup" style="width: 100%;" >
<view class="pop_box">
<view class="pop_title">
查询条件
@ -50,7 +50,7 @@
<view class="time_box">
<uni-datetime-picker v-model="timeRange" type="daterange" />
</view>
<!-- <view class="cont_tit picker">
<view class="cont_tit picker">
<view>统计时段</view>
<view class="picker_select">
<picker @change="bindPickerChange" :value="index" :range="timeArray" range-key="dictLabel">
@ -59,7 +59,7 @@
<uni-icons type="right" size="16" color="#D4D4D4"></uni-icons>
</picker>
</view>
</view> -->
</view>
</view>
<view class="btn_box">
<p class="btn" @click="searchReset">重置</p>
@ -87,12 +87,23 @@
contentnomore: "没有更多数据了",
},
status: '',
reportPhase:'',
timeArray:[],
timeName:'',
}
},
onShow(){
this.page = 0;
this.hasMore = true;
this.synthData = []
this.synthData = [];
this.queryTime()
this.loadMore()
},
onPullDownRefresh() {
this.page = 0;
this.hasMore = true;
this.synthData = [];
this.queryTime()
this.loadMore()
},
methods: {
@ -107,7 +118,8 @@
_t:Date.parse(new Date()),
reportDatetimeStart:this.timeRange.length != 0 ? this.timeRange[0] : '',
reportDatetimeEnd:this.timeRange.length != 0 ? this.timeRange[1] : '',
departmentId:this.unit ? this.unit : ''
departmentId:this.unit ? this.unit : '',
statPeriod:this.reportPhase
}
this.$request(getApp().globalData.baseUrl + '/api/biz/roadtransport/operation/list',params,"GET").then(res =>{
console.log(res)
@ -124,6 +136,13 @@
})
}
},
//
queryTime() {
this.$request(getApp().globalData.baseUrl + '/api/dict/dictList?dictType=airport_time' + '&_t=' + Date.parse(
new Date()), {}, 'GET').then(res => {
this.timeArray = res.data;
})
},
//
editItem(row){
@ -159,9 +178,20 @@
this.$refs.popup.close()
this.loadMore()
},
//
bindPickerChange(e){
let index = e.target.value //
var selected = this.timeArray[index] //
console.log(selected)
this.timeName = selected.dictLabel
this.reportPhase = selected.dictValue;
// this.timeName = this.timeArray[index].dictLabel)
},
//
searchReset(){
this.timeRange = [];
this.timeName = '';
this.reportPhase = ''
this.hasMore = true;
this.synthData = [];
this.page = 0;
@ -314,10 +344,8 @@
left: 0;
right: 0;
bottom: 0;
display: flex;
justify-content: space-around;
background-color: #F8F8F8;
padding: 20px 30rpx;
padding: 20px 30rpx 40px;
.act_btn {
width: 690rpx;

@ -76,37 +76,39 @@
<view class="edit_item input">
<p class="left">投放运力-班车数</p>
<view class="right">
<uni-easyinput v-model="roadData.capacityShuttle" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<uni-easyinput @blur="calcBusNum" @clear="calcBusNum" type="number" v-model="roadData.capacityShuttle" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view>
</view>
<view class="edit_item input">
<p class="left">投放运力-定线通勤包车()</p>
<view class="right">
<uni-easyinput v-model="roadData.regularCommuteCharter" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<uni-easyinput @blur="calcBusNum" @clear="calcBusNum" type="number" v-model="roadData.regularCommuteCharter" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view>
</view>
<view class="edit_item input">
<p class="left">运送农民工报()</p>
<p class="left">投放运力-运送农民工包()</p>
<view class="right">
<uni-easyinput v-model="roadData.migrantWorkersCharter" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<uni-easyinput @blur="calcBusNum" @clear="calcBusNum" type="number" v-model="roadData.migrantWorkersCharter" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view>
</view>
<view class="edit_item input">
<p class="left">投放运力-除定线农民工包车()</p>
<p class="left">投放运力-除定线通勤农民工包车()</p>
<view class="right">
<uni-easyinput type="number" v-model="roadData.otherCharter" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<uni-easyinput @blur="calcBusNum" @clear="calcBusNum" type="number" v-model="roadData.otherCharter" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view>
</view>
<view class="edit_item input">
<p class="left">投放运力-包车数</p>
<view class="right">
<uni-easyinput v-model="roadData.capacityCharter" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<p>{{roadData.capacityCharter}}</p>
<!-- <uni-easyinput v-model="roadData.capacityCharter" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput> -->
</view>
</view>
<view class="edit_item input">
<p class="left">投放运力-总客车数</p>
<view class="right">
<uni-easyinput @blur="getRatio" @clear="getRatio" v-model="roadData.capacityTotalBus" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<!-- <uni-easyinput @blur="getRatio" @clear="getRatio" v-model="roadData.capacityTotalBus" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput> -->
<p>{{roadData.capacityTotalBus}}</p>
</view>
</view>
<view class="per_con"
@ -126,73 +128,83 @@
<view class="edit_item input">
<p class="left">投放运力-加班数</p>
<view class="right">
<uni-easyinput v-model="roadData.overtimeTrips" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<uni-easyinput type="number" v-model="roadData.overtimeTrips" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view>
</view>
<view class="edit_item input">
<p class="left">投放运力-班车班次</p>
<view class="right">
<uni-easyinput v-model="roadData.capacityShuttleTrips" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<uni-easyinput @blur="calcTotalTrips" @clear="calcTotalTrips" type="number" v-model="roadData.capacityShuttleTrips" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view>
</view>
<view class="edit_item input">
<p class="left">投放运力-定线通勤班次</p>
<view class="right">
<uni-easyinput v-model="roadData.regularCommuteTrips" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<uni-easyinput @blur="calcTotalTrips" @clear="calcTotalTrips" type="number" v-model="roadData.regularCommuteTrips" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view>
</view>
<view class="edit_item input">
<p class="left">投放运力-运送农民工班次</p>
<view class="right">
<uni-easyinput v-model="roadData.migrantWorkersTrips" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<uni-easyinput @blur="calcTotalTrips" @clear="calcTotalTrips" type="number" v-model="roadData.migrantWorkersTrips" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view>
</view>
<view class="edit_item input">
<p class="left">投放运力-除定线通勤包车农民工包车班次</p>
<view class="right">
<uni-easyinput v-model="roadData.otherTrips" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<uni-easyinput @blur="calcTotalTrips" @clear="calcTotalTrips" type="number" v-model="roadData.otherTrips" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view>
</view>
<view class="edit_item input">
<p class="left">投放运力-包车班次</p>
<view class="right">
<uni-easyinput v-model="roadData.capacityCharterTrips" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<p>{{roadData.capacityCharterTrips}}</p>
<!-- <uni-easyinput v-model="roadData.capacityCharterTrips" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput> -->
</view>
</view>
<view class="edit_item input">
<p class="left">投放运力-班次</p>
<view class="right">
<uni-easyinput v-model="roadData.capacityTotalTrips" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<p>{{roadData.capacityTotalTrips}}</p>
<!-- <uni-easyinput v-model="roadData.capacityTotalTrips" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput> -->
</view>
</view>
<view class="edit_item input">
<p class="left">班车客运量()</p>
<view class="right">
<uni-easyinput v-model="roadData.shuttlePassengerVolume" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<uni-easyinput @blur="calctotalPassenger" @clear="calctotalPassenger" type="digit" v-model="roadData.shuttlePassengerVolume" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view>
</view>
<view class="edit_item input">
<p class="left">定线通勤包车客运量()</p>
<view class="right">
<uni-easyinput v-model="roadData.regularCommutePassengerVolume" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<uni-easyinput @blur="calctotalPassenger" @clear="calctotalPassenger" type="digit" v-model="roadData.regularCommutePassengerVolume" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view>
</view>
<view class="edit_item input">
<p class="left">运送农民工包车客运量()</p>
<view class="right">
<uni-easyinput @blur="calctotalPassenger" @clear="calctotalPassenger" type="digit" v-model="roadData.migrantWorkersPassengerVolume" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view>
</view>
<view class="edit_item input">
<p class="left">除定线通勤包车农民工包车以外的客运量()</p>
<view class="right">
<uni-easyinput v-model="roadData.otherPassengerVolume" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<uni-easyinput @blur="calctotalPassenger" @clear="calctotalPassenger" type="digit" v-model="roadData.otherPassengerVolume" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view>
</view>
<view class="edit_item input">
<p class="left">包车客运量()</p>
<view class="right">
<uni-easyinput v-model="roadData.charterPassengerVolume" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<p>{{roadData.charterPassengerVolume}}</p>
<!-- <uni-easyinput v-model="roadData.charterPassengerVolume" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput> -->
</view>
</view>
<view class="edit_item input">
<p class="left">完成客运量()</p>
<view class="right">
<uni-easyinput @blur="getRatio" @clear="getRatio" v-model="roadData.totalPassengerVolume" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
<p>{{roadData.totalPassengerVolume}}</p>
<!-- <uni-easyinput @blur="getRatio" @clear="getRatio" v-model="roadData.totalPassengerVolume" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput> -->
</view>
</view>
<view class="per_con">
@ -225,12 +237,6 @@
<uni-easyinput v-model="roadData.onlineTicketSales" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view>
</view>
<view class="edit_item input">
<p class="left">运送农民工包车客运量()</p>
<view class="right">
<uni-easyinput v-model="roadData.migrantWorkersPassengerVolume" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view>
</view>
<view class="edit_item input">
<p class="left">定制客运量(万人)</p>
<view class="right">
@ -411,7 +417,7 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
return {
roadTime:[],
unitData:[],
personData:[],
// personData:[],
isShowTitle:false,
timeName:'',
pageType:'',
@ -427,21 +433,21 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
regularCommuteCharter:'',//线
migrantWorkersCharter:'',//
otherCharter:'',//线
capacityCharter:'', //
capacityCharter:0, //
capacityShuttle:'', //
capacityTotalBus:"", //
capacityTotalBus:0, //
regularCommuteTrips:"", //线
migrantWorkersTrips:"", //
otherTrips:"", //线
capacityCharterTrips:"", //
capacityCharterTrips:0, //
capacityShuttleTrips:"", //
capacityTotalTrips:"", //
capacityTotalTrips:0, //
regularCommutePassengerVolume:"", //线()
migrantWorkersPassengerVolume:"", //()
otherPassengerVolume:"", //线()
charterPassengerVolume:"", //()
charterPassengerVolume:0, //()
shuttlePassengerVolume:"", //()
totalPassengerVolume:"", //()
totalPassengerVolume:0, //()
totalSeatCapacity:"", //()
passengerVolumeLastYear:"", //()
totalBusLastYear:"", //()
@ -554,7 +560,7 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
}else if(options.type == 'add'){
this.pageType = 'add';
this.getDept()
this.getRoadTime()
let now = new Date();
this.roadData.statisticalDate = getDateStr(now, -1);//
}
@ -566,6 +572,35 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
phoneNumber: tel
});
},
//
calcBusNum(){
let capacityShuttle = checkNotEmpty(this.roadData.capacityShuttle) ? parseInt(this.roadData.capacityShuttle) : 0;
let regularCommuteCharter = checkNotEmpty(this.roadData.regularCommuteCharter) ? parseInt(this.roadData.regularCommuteCharter) : 0;
let migrantWorkersCharter = checkNotEmpty(this.roadData.migrantWorkersCharter) ? parseInt(this.roadData.migrantWorkersCharter) : 0;
let otherCharter = checkNotEmpty(this.roadData.otherCharter) ? parseInt(this.roadData.otherCharter) : 0;
this.roadData.capacityCharter = regularCommuteCharter + migrantWorkersCharter + otherCharter
this.roadData.capacityTotalBus = this.roadData.capacityCharter + capacityShuttle;
this.getRatio()
},
//
calcTotalTrips(){
let capacityShuttleTrips = checkNotEmpty(this.roadData.capacityShuttleTrips) ? parseInt(this.roadData.capacityShuttleTrips) : 0;
let regularCommuteTrips = checkNotEmpty(this.roadData.regularCommuteTrips) ? parseInt(this.roadData.regularCommuteTrips) : 0;
let migrantWorkersTrips = checkNotEmpty(this.roadData.migrantWorkersTrips) ? parseInt(this.roadData.migrantWorkersTrips) : 0;
let otherTrips = checkNotEmpty(this.roadData.otherTrips) ? parseInt(this.roadData.otherTrips) : 0;
this.roadData.capacityCharterTrips = regularCommuteTrips + migrantWorkersTrips + otherTrips;
this.roadData.capacityTotalTrips = this.roadData.capacityCharterTrips + capacityShuttleTrips
},
//
calctotalPassenger(){
let shuttlePassengerVolume = checkNotEmpty(this.roadData.shuttlePassengerVolume) ? parseInt(this.roadData.shuttlePassengerVolume) : 0;
let regularCommutePassengerVolume = checkNotEmpty(this.roadData.regularCommutePassengerVolume) ? parseInt(this.roadData.regularCommutePassengerVolume) : 0;
let otherPassengerVolume = checkNotEmpty(this.roadData.otherPassengerVolume) ? parseInt(this.roadData.otherPassengerVolume) : 0;
let migrantWorkersPassengerVolume = checkNotEmpty(this.roadData.migrantWorkersPassengerVolume) ? parseInt(this.roadData.migrantWorkersPassengerVolume) : 0;
this.roadData.charterPassengerVolume = regularCommutePassengerVolume + migrantWorkersPassengerVolume + otherPassengerVolume;
this.roadData.totalPassengerVolume = this.roadData.charterPassengerVolume + shuttlePassengerVolume
this.getRatio()
},
showPop(){
this.selectId = this.selectId1;
this.$refs.unitPopup.open('bottom')
@ -632,6 +667,7 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
this.roadData.reportingUnitId = this.deptNameList.length > 0 ? this.deptNameList[0].deptName : '';
this.roadData.reportingUnitIdIndex = this.deptNameList.length > 0 ? 0 : '';
this.selectId1 = this.unitId;
this.getRoadTime()
this.getPeople()
}else if(this.pageType == 'edit'){
console.log('reportingUnitId===>',this.roadData.reportingUnitId)
@ -654,7 +690,8 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
getRatio(){
let params = {
statisticalDate:this.roadData.statisticalDate,
reportPhase:this.roadData.reportPhase
reportPhase:this.roadData.reportPhase,
reportUnit:this.roadData.reportingUnitId
}
this.$request(getApp().globalData.baseUrl + '/api/biz/roadtransport/road/findByStatisticalDate',params,"GET").then(res =>{
this.lastData = res.data;
@ -778,7 +815,8 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
this.getRatio()
}else if(this.pageType == 'add'){
let now = new Date();
let dateStr = getDateStr(now,0);
// let dateStr = getDateStr(now,0);
let dateStr = getDateStr(now, 0).replaceAll('-','/');
if(new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < new Date(dateStr + ' 13:30').getTime()) {
this.roadData.reportPhase = "0012";
this.index = this.roadTime.findIndex(item => item.dictValue == "0012")

@ -8,6 +8,7 @@
<view class="unit_tags">报送时间</view>
<view class="unit_name">{{item.statisticalDate || ''}}<text style="margin-left:16rpx;">{{item.reportPhaseValue || ''}}</text></view>
</view>
<view class="unit_station">{{item.reportingUnitId || ''}}</view>
<!-- <view class="report_time">{{item.statisticalDate || ''}}<text style="margin-left:16rpx;">{{item.reportPhaseValue || ''}}</text></view> -->
<!-- <view class="item">
<view class="item_line" @click="showDetail(index,true)">
@ -72,7 +73,7 @@
</view>
</view>
<view class="pop_conbox">
<uni-popup ref="popup" style="width: 100%;" background-color="#fff">
<uni-popup ref="popup" style="width: 100%;">
<view class="pop_box">
<view class="pop_title">
查询条件
@ -85,7 +86,7 @@
<view class="time_box">
<uni-datetime-picker v-model="timeRange" type="daterange" />
</view>
<!-- <view class="cont_tit picker">
<view class="cont_tit picker">
<view>统计时段</view>
<view class="picker_select">
<picker @change="bindPickerChange" :value="index" :range="timeArray" range-key="dictLabel">
@ -94,7 +95,7 @@
<uni-icons type="right" size="16" color="#D4D4D4"></uni-icons>
</picker>
</view>
</view> -->
</view>
</view>
<view class="btn_box">
<p class="btn" @click="searchReset">重置</p>
@ -125,6 +126,7 @@
size:10,
timeArray:[],
timeName:'',
reportPhase:'',
}
},
onShow(){
@ -184,7 +186,7 @@
var selected = this.timeArray[index] //
console.log(selected)
this.timeName = selected.dictLabel
// this.roadData.reportPhase = selected.dictValue;
this.reportPhase = selected.dictValue;
// this.timeName = this.timeArray[index].dictLabel)
},
//
@ -198,6 +200,8 @@
//
searchReset(){
this.unit = '';
this.timeName = '';
this.reportPhase = ''
this.timeRange = [];
this.listData = [];
this.hasMore = true;
@ -215,7 +219,8 @@
pageSize:this.size,
statisticalDateStart:this.timeRange.length !== 0 ? this.timeRange[0] : '',
statisticalDateEnd:this.timeRange.length !== 0 ? this.timeRange[1] : '',
_t:Date.parse(new Date())
_t:Date.parse(new Date()),
statPeriod:this.reportPhase
}
this.$request(getApp().globalData.baseUrl + '/api/biz/roadtransport/road/list',params,"GET").then(res =>{
console.log(res)
@ -339,6 +344,13 @@
text-align: center;
margin-bottom: 30rpx;
}
.unit_station {
color: #666;
font-size: 24rpx;
font-family: PingFang SC-Regular, PingFang SC;
font-weight: 400;
text-align: right;
}
.item{
width: 570rpx;
@ -440,10 +452,8 @@
left: 0;
right: 0;
bottom: 0;
display: flex;
justify-content: space-around;
background-color: #F8F8F8;
padding: 20px 30rpx;
padding: 20px 30rpx 40px;
.act_btn {
width: 690rpx;

Loading…
Cancel
Save