交通小程序bug修改

dev201310
jinna 2 years ago
parent b4b1fc4293
commit 6df32b403b
  1. 14
      pages/airport/airport-runData/form.vue
  2. 12
      pages/airport/airport-runStatus/form.vue
  3. 16
      pages/bus/busDataInfo/form.vue
  4. 30
      pages/highWay/runData/form.vue
  5. 12
      pages/highWay/runStatusData/form.vue
  6. 14
      pages/metro/subwayPage/form.vue
  7. 15
      pages/portShipping/pilotStation/form.vue
  8. 53
      pages/portShipping/waterInternational/form.vue
  9. 30
      pages/railway/railwayRunData/form.vue
  10. 12
      pages/railway/runStatus/form.vue
  11. 12
      pages/roadTransport/dataSubmission/form.vue
  12. 12
      pages/roadTransport/quantitySent/form.vue
  13. 64
      pages/roadTransport/transportData/form.vue
  14. 4
      pages/roadTransport/transportData/list.vue
  15. 12
      pages/water/TransportData/form.vue
  16. 12
      pages/water/transportation/form.vue
  17. 16
      pages/water/waterWay/form.vue

@ -530,15 +530,15 @@
let now = new Date(); let now = new Date();
//11:00-13:30 0-12 //11:00-13:30 0-12
let dateStr = getDateStr(now, 0).replaceAll('-','/'); let dateStr = getDateStr(now, 0).replaceAll('-','/');
if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < // if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() <
new Date(dateStr + // new Date(dateStr +
' 13:30').getTime()) { // ' 13:30').getTime()) {
this.form.statPeriod = '0012'; // this.form.statPeriod = '0012';
this.index = this.array.findIndex(item => item.dictValue == '0012'); // this.index = this.array.findIndex(item => item.dictValue == '0012');
} else { // } else {
this.form.statPeriod = '03'; //0-24 this.form.statPeriod = '03'; //0-24
this.index = this.array.findIndex(item => item.dictValue == '03'); this.index = this.array.findIndex(item => item.dictValue == '03');
} // }
} else { } else {
this.index = this.array.findIndex(item => item.dictValue == this.form.statPeriod); this.index = this.array.findIndex(item => item.dictValue == this.form.statPeriod);
} }

@ -140,15 +140,15 @@
let now = new Date(); let now = new Date();
//11:00-13:30 0-12 //11:00-13:30 0-12
let dateStr = getDateStr(now, 0).replaceAll('-','/'); 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()) { // if(new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < new Date(dateStr + ' 13:30').getTime()) {
this.form.statPeriod = '0012'; // this.form.statPeriod = '0012';
let idx = this.array.findIndex(item => item.dictValue == '0012'); // let idx = this.array.findIndex(item => item.dictValue == '0012');
this.index = idx > -1 ? idx : idx; // this.index = idx > -1 ? idx : idx;
}else{ // }else{
this.form.statPeriod = '03'; //0-24 this.form.statPeriod = '03'; //0-24
let idx = this.array.findIndex(item => item.dictValue == '03'); let idx = this.array.findIndex(item => item.dictValue == '03');
this.index = idx > -1 ? idx : idx; this.index = idx > -1 ? idx : idx;
} // }
}else{ }else{
let idx = this.array.findIndex(item => item.dictValue == this.form.statPeriod); let idx = this.array.findIndex(item => item.dictValue == this.form.statPeriod);
this.index = idx > -1 ? idx : idx; this.index = idx > -1 ? idx : idx;

@ -601,17 +601,17 @@
//11:00-13:30 0-12 //11:00-13:30 0-12
// let dateStr = getDateStr(now, 0); // let dateStr = getDateStr(now, 0);
let dateStr = getDateStr(now, 0).replaceAll('-','/'); let dateStr = getDateStr(now, 0).replaceAll('-','/');
if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < // if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() <
new Date(dateStr + // new Date(dateStr +
' 13:30').getTime()) { // ' 14:30').getTime()) {
this.form.statPeriod = '0012'; // this.form.statPeriod = '0012';
let idx = this.array.findIndex(item => item.dictValue == '0012'); // let idx = this.array.findIndex(item => item.dictValue == '0012');
this.index = idx > -1 ? idx : ''; // this.index = idx > -1 ? idx : '';
} else { // } else {
this.form.statPeriod = '03'; //0-24 this.form.statPeriod = '03'; //0-24
let idx = this.array.findIndex(item => item.dictValue == '03'); let idx = this.array.findIndex(item => item.dictValue == '03');
this.index = idx > -1 ? idx : ''; this.index = idx > -1 ? idx : '';
} // }
this.getDetail2(this.form.statDate, this.form.statPeriod); this.getDetail2(this.form.statDate, this.form.statPeriod);
} else { } else {
let idx = this.array.findIndex(item => item.dictValue == this.form.statPeriod); let idx = this.array.findIndex(item => item.dictValue == this.form.statPeriod);

@ -588,24 +588,24 @@
let now = new Date(); let now = new Date();
//11:00-13:30 0-12 //11:00-13:30 0-12
let dateStr = getDateStr(now, 0).replaceAll('-','/'); let dateStr = getDateStr(now, 0).replaceAll('-','/');
if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < // if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() <
new Date(dateStr + ' 13:30').getTime()) { // new Date(dateStr + ' 13:30').getTime()) {
this.form.statPeriod = '0012'; // this.form.statPeriod = '0012';
let idx = this.array.findIndex(item => item.dictValue == '0012'); // let idx = this.array.findIndex(item => item.dictValue == '0012');
this.index = idx > -1 ? idx : ''; // this.index = idx > -1 ? idx : '';
if(idx > -1) { // if(idx > -1) {
this.index = idx; // this.index = idx;
}else { // }else {
//0-12 0-24 // //0-12 0-24
this.form.statPeriod = '03'; //0-24 // this.form.statPeriod = '03'; //0-24
let _idx = this.array.findIndex(item => item.dictValue == '03'); // let _idx = this.array.findIndex(item => item.dictValue == '03');
this.index = _idx > -1 ? _idx : ''; // this.index = _idx > -1 ? _idx : '';
} // }
} else { // } else {
this.form.statPeriod = '03'; //0-24 this.form.statPeriod = '03'; //0-24
let idx = this.array.findIndex(item => item.dictValue == '03'); let idx = this.array.findIndex(item => item.dictValue == '03');
this.index = idx > -1 ? idx : ''; this.index = idx > -1 ? idx : '';
} // }
// - // -
this.$request(getApp().globalData.baseUrl + '/api/biz/highwayParentDataController/getSubData?statDate=' + this.form.statDate + '&statPeriod=' + this.form.statPeriod, {}, this.$request(getApp().globalData.baseUrl + '/api/biz/highwayParentDataController/getSubData?statDate=' + this.form.statDate + '&statPeriod=' + this.form.statPeriod, {},
'GET').then(res => { 'GET').then(res => {

@ -515,14 +515,14 @@
let now = new Date(); let now = new Date();
//11:00-13:30 0-12 //11:00-13:30 0-12
let dateStr = getDateStr(now, 0).replaceAll('-','/'); let dateStr = getDateStr(now, 0).replaceAll('-','/');
if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < new Date(dateStr + // if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < new Date(dateStr +
' 13:30').getTime()) { // ' 13:30').getTime()) {
this.form.statPeriod = '0012'; // this.form.statPeriod = '0012';
this.index = this.array.findIndex(item => item.dictValue == '0012'); // this.index = this.array.findIndex(item => item.dictValue == '0012');
} else { // } else {
this.form.statPeriod = '03'; //0-24 this.form.statPeriod = '03'; //0-24
this.index = this.array.findIndex(item => item.dictValue == '03'); this.index = this.array.findIndex(item => item.dictValue == '03');
} // }
}else{ }else{
this.index = this.array.findIndex(item => item.dictValue == this.form.statPeriod); this.index = this.array.findIndex(item => item.dictValue == this.form.statPeriod);
} }

@ -244,16 +244,16 @@
let now = new Date(); let now = new Date();
//11:00-13:30 0-12 //11:00-13:30 0-12
let dateStr = getDateStr(now, 0).replaceAll('-','/'); let dateStr = getDateStr(now, 0).replaceAll('-','/');
if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < // if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() <
new Date(dateStr + ' 13:30').getTime()) { // new Date(dateStr + ' 13:30').getTime()) {
this.form.statPeriod = '0012'; // this.form.statPeriod = '0012';
let idx = this.array.findIndex(item => item.dictValue == '0012'); // let idx = this.array.findIndex(item => item.dictValue == '0012');
this.index = idx > -1 ? idx : idx; // this.index = idx > -1 ? idx : idx;
} else { // } else {
this.form.statPeriod = '03'; //0-24 this.form.statPeriod = '03'; //0-24
let idx = this.array.findIndex(item => item.dictValue == '03'); let idx = this.array.findIndex(item => item.dictValue == '03');
this.index = idx > -1 ? idx : idx; this.index = idx > -1 ? idx : idx;
} // }
} else { } else {
let idx = this.array.findIndex(item => item.dictValue == this.form.statPeriod); let idx = this.array.findIndex(item => item.dictValue == this.form.statPeriod);
this.index = idx > -1 ? idx : idx; this.index = idx > -1 ? idx : idx;

@ -118,7 +118,8 @@
</view> </view>
</view> </view>
<view class="edit_item input"> <view class="edit_item input">
<p class="left">低能见度情况下完成船舶雾航(艘次):</p> <!-- <p class="left">低能见度情况下完成船舶雾航(艘次):</p> -->
<p class="left">低能见度集装箱班轮通航效率提升(艘次):</p>
<view class="right"> <view class="right">
<uni-easyinput type="number" v-model="form.shipFogNavigationCountUnderLowVisibility" placeholder="请输入" placeholderStyle="color:#d4d4d4;" maxlength="20"></uni-easyinput> <uni-easyinput type="number" v-model="form.shipFogNavigationCountUnderLowVisibility" placeholder="请输入" placeholderStyle="color:#d4d4d4;" maxlength="20"></uni-easyinput>
</view> </view>
@ -238,15 +239,15 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr } from '../../../common/uti
let now = new Date(); let now = new Date();
// let dateStr = getDateStr(now,0); // let dateStr = getDateStr(now,0);
let dateStr = getDateStr(now, 0).replaceAll('-','/'); 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()) { // if(new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < new Date(dateStr + ' 13:30').getTime()) {
this.form.statPeriod = "0012"; // this.form.statPeriod = "0012";
this.index = this.roadTime.findIndex(item => item.dictValue == "0012") // this.index = this.roadTime.findIndex(item => item.dictValue == "0012")
this.timeName = this.roadTime.find(item => item.dictValue == "0012").dictLabel // this.timeName = this.roadTime.find(item => item.dictValue == "0012").dictLabel
}else{ // }else{
this.form.statPeriod = "03"; this.form.statPeriod = "03";
this.index = this.roadTime.findIndex(item => item.dictValue == "03") this.index = this.roadTime.findIndex(item => item.dictValue == "03")
this.timeName = this.roadTime.find(item => item.dictValue == "03").dictLabel this.timeName = this.roadTime.find(item => item.dictValue == "03").dictLabel
} // }
this.getYoyMom() this.getYoyMom()
} }

@ -87,6 +87,14 @@
</uni-easyinput> </uni-easyinput>
</view> </view>
</view> </view>
<view class="form_item">
<view class="form_item_label">方向</view>
<view class="form_item_input form_input">
<uni-easyinput v-model="item.direction" placeholderStyle="color: #D4D4D4;font-size:28rpx;" placeholder="请输入"
maxlength="20" disabled>
</uni-easyinput>
</view>
</view>
<view class="form_item"> <view class="form_item">
<view class="form_item_label">航次数</view> <view class="form_item_label">航次数</view>
<view class="form_item_input form_input"> <view class="form_item_input form_input">
@ -193,6 +201,14 @@
</uni-easyinput> </uni-easyinput>
</view> </view>
</view> </view>
<view class="form_item">
<view class="form_item_label">方向</view>
<view class="form_item_input form_input">
<uni-easyinput v-model="item.direction" placeholderStyle="color: #D4D4D4;font-size:28rpx;" placeholder="请输入"
maxlength="20">
</uni-easyinput>
</view>
</view>
<view class="form_item"> <view class="form_item">
<view class="form_item_label">航次数</view> <view class="form_item_label">航次数</view>
<view class="form_item_input form_input"> <view class="form_item_input form_input">
@ -222,7 +238,8 @@
</view> </view>
</view> --> </view> -->
<view class="form_item"> <view class="form_item">
<view class="form_item_label">{{item.direction == '1' ? '入青' : item.direction == '2' ? '出青' : ''}}旅客人数</view> <!-- {{item.direction == '1' ? '入青' : item.direction == '2' ? '出青' : ''}} -->
<view class="form_item_label">旅客人数</view>
<view class="form_item_input form_input"> <view class="form_item_input form_input">
<uni-easyinput @blur="calcYoyMom(2,index)" @clear="calcYoyMom(2,index)" v-model="item.passengerCount" <uni-easyinput @blur="calcYoyMom(2,index)" @clear="calcYoyMom(2,index)" v-model="item.passengerCount"
type="number" placeholderStyle="color: #D4D4D4;font-size:28rpx;" placeholder="请输入" maxlength="20"> type="number" placeholderStyle="color: #D4D4D4;font-size:28rpx;" placeholder="请输入" maxlength="20">
@ -232,8 +249,9 @@
<!-- 同比环比 --> <!-- 同比环比 -->
<view class="form_item_rate" :class="item.passengerDod === 0 ? 'danger' : '' "> <view class="form_item_rate" :class="item.passengerDod === 0 ? 'danger' : '' ">
<view class="rate_item"> <view class="rate_item">
<!-- {{item.direction == '1' ? '入青' : item.direction == '2' ? '出青' : ''}} -->
<view class="rate_item_label" :style="item.passengerDod === 0 ? 'color: #EB4747' : ''"> <view class="rate_item_label" :style="item.passengerDod === 0 ? 'color: #EB4747' : ''">
{{item.direction == '1' ? '入青' : item.direction == '2' ? '出青' : ''}}旅客人数环比 旅客人数环比
</view> </view>
<view class="rate_item_input" :style="item.passengerDod === 0 ? 'color: #EB4747' : ''"> <view class="rate_item_input" :style="item.passengerDod === 0 ? 'color: #EB4747' : ''">
{{formatDigit(form.passengerDod)}}% {{formatDigit(form.passengerDod)}}%
@ -241,7 +259,8 @@
</view> </view>
<view class="line"></view> <view class="line"></view>
<view class="rate_item"> <view class="rate_item">
<view class="rate_item_label">{{item.direction == '1' ? '入青' : item.direction == '2' ? '出青' : ''}}旅客人数同比 <!-- {{item.direction == '1' ? '入青' : item.direction == '2' ? '出青' : ''}} -->
<view class="rate_item_label">旅客人数同比
</view> </view>
<view class="rate_item_input"> <view class="rate_item_input">
{{formatDigit(item.passengerYoy)}}% {{formatDigit(item.passengerYoy)}}%
@ -417,7 +436,8 @@
this.getDept(); this.getDept();
} else if (options.id) { } else if (options.id) {
this.btnText = '修改并保存'; this.btnText = '修改并保存';
this.$request(getApp().globalData.baseUrl + '/api/biz/internationalPassengerTransport/selectById/' + options // this.$request(getApp().globalData.baseUrl + '/api/biz/internationalPassengerTransport/selectById/' + options
this.$request(getApp().globalData.baseUrl + '/api/biz/internationalPassengerTransport/selectByIdV2/' + options
.id, {}, "GET").then( .id, {}, "GET").then(
res => { res => {
this.form = res.data; this.form = res.data;
@ -600,7 +620,6 @@
}, },
// //
calcYoyMom(type, index) { calcYoyMom(type, index) {
console.log('同比环比计算')
let _voyage = type == 1 ? this.form.passengerShipDTOList[index].voyage : this.form.internationalCruiseDTOList[ let _voyage = type == 1 ? this.form.passengerShipDTOList[index].voyage : this.form.internationalCruiseDTOList[
index].voyage; index].voyage;
this.$request(getApp().globalData.baseUrl + '/api/biz/internationalPassengerTransport/getYoYAndMoM?statDate=' + this.$request(getApp().globalData.baseUrl + '/api/biz/internationalPassengerTransport/getYoYAndMoM?statDate=' +
@ -639,7 +658,7 @@
.value ? '' : this.form.passengerShipDTOList[index].voyage; .value ? '' : this.form.passengerShipDTOList[index].voyage;
this.form.passengerShipDTOList[index].routeIndex = e.detail.value; this.form.passengerShipDTOList[index].routeIndex = e.detail.value;
this.form.passengerShipDTOList[index].route = this.shipRouteList[e.detail.value].route; this.form.passengerShipDTOList[index].route = this.shipRouteList[e.detail.value].route;
this.form.passengerShipDTOList[index].direction = this.shipRouteList[e.detail.value].direction; this.form.passengerShipDTOList[index].direction = this.shipRouteList[e.detail.value].direction == 1 ? '入青' : this.shipRouteList[e.detail.value].direction == 2 ? '出青' : '';
} else { } else {
// //
this.form.internationalCruiseDTOList[index].voyageIndex = this.form.internationalCruiseDTOList[index] this.form.internationalCruiseDTOList[index].voyageIndex = this.form.internationalCruiseDTOList[index]
@ -698,7 +717,6 @@
.voyageInfoVOList[e.detail.value].voyageCode; .voyageInfoVOList[e.detail.value].voyageCode;
} }
} }
console.log('航次选择', this.form)
}, },
// //
changeStatPeriod(e) { changeStatPeriod(e) {
@ -722,17 +740,17 @@
let now = new Date(); let now = new Date();
//11:00-13:30 0-12 //11:00-13:30 0-12
let dateStr = getDateStr(now, 0).replaceAll('-', '/'); let dateStr = getDateStr(now, 0).replaceAll('-', '/');
if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < // if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() <
new Date(dateStr + // new Date(dateStr +
' 13:30').getTime()) { // ' 13:30').getTime()) {
this.form.statPeriod = '0012'; // this.form.statPeriod = '0012';
let idx = this.array.findIndex(item => item.dictValue == '0012'); // let idx = this.array.findIndex(item => item.dictValue == '0012');
this.index = idx > -1 ? idx : ''; // this.index = idx > -1 ? idx : '';
} else { // } else {
this.form.statPeriod = '03'; //0-24 this.form.statPeriod = '03'; //0-24
let idx = this.array.findIndex(item => item.dictValue == '03'); let idx = this.array.findIndex(item => item.dictValue == '03');
this.index = idx > -1 ? idx : ''; this.index = idx > -1 ? idx : '';
} // }
} else { } else {
let idx = this.array.findIndex(item => item.dictValue == this.form.statPeriod); let idx = this.array.findIndex(item => item.dictValue == this.form.statPeriod);
this.index = idx > -1 ? idx : ''; this.index = idx > -1 ? idx : '';
@ -782,6 +800,7 @@
content: this.form.id == undefined ? '您确认提交该条报送数据?' : '您确认将该条数据进行修改?', content: this.form.id == undefined ? '您确认提交该条报送数据?' : '您确认将该条数据进行修改?',
success: (res) => { success: (res) => {
if (res.confirm) { if (res.confirm) {
console.log('form =====>',this.form)
this.submitForm(); this.submitForm();
} }
} }
@ -980,6 +999,10 @@
text-align: right; text-align: right;
} }
} }
/deep/.is-disabled{
background: transparent !important;
color:#333;
}
} }
} }
} }

@ -200,7 +200,7 @@
<view class="form_item"> <view class="form_item">
<view class="form_item_label">车站名称</view> <view class="form_item_label">车站名称</view>
<view class="form_item_input"> <view class="form_item_input">
{{form.bizRailwayRunDataSaveOrUpdateDTOList[railwayNameIndex].railwayName}} {{form.bizRailwayRunDataSaveOrUpdateDTOList[railwayNameIndex].railwayName ? form.bizRailwayRunDataSaveOrUpdateDTOList[railwayNameIndex].railwayName : ''}}
</view> </view>
</view> </view>
<view class="form_item"> <view class="form_item">
@ -402,7 +402,7 @@
"inRailwayMomDo": '', "inRailwayMomDo": '',
"inRailwayYomDo": '', "inRailwayYomDo": '',
"inboundPassengersDo": '', "inboundPassengersDo": '',
"inboundRailwayDo": '', "inboundRailwayDo": 0,
"isHoliday": "", "isHoliday": "",
"outMark": "", "outMark": "",
"outPepole": '', "outPepole": '',
@ -411,7 +411,7 @@
"outRailwayMomDo": '', "outRailwayMomDo": '',
"outRailwayYomDo": '', "outRailwayYomDo": '',
"outboundPassengersDo": '', "outboundPassengersDo": '',
"outboundRailwayDo": '', "outboundRailwayDo": 0,
"railwayName": "", "railwayName": "",
}], }],
@ -593,7 +593,7 @@
"inRailwayMomDo": '', "inRailwayMomDo": '',
"inRailwayYomDo": '', "inRailwayYomDo": '',
"inboundPassengersDo": '', "inboundPassengersDo": '',
"inboundRailwayDo": '', "inboundRailwayDo": 0,
"isHoliday": "", "isHoliday": "",
"outMark": "", "outMark": "",
"outPepole": '', "outPepole": '',
@ -602,7 +602,7 @@
"outRailwayMomDo": '', "outRailwayMomDo": '',
"outRailwayYomDo": '', "outRailwayYomDo": '',
"outboundPassengersDo": '', "outboundPassengersDo": '',
"outboundRailwayDo": '', "outboundRailwayDo": 0,
"railwayName": item.railwayName, "railwayName": item.railwayName,
}) })
}) })
@ -626,7 +626,7 @@
"inRailwayMomDo": '', "inRailwayMomDo": '',
"inRailwayYomDo": '', "inRailwayYomDo": '',
"inboundPassengersDo": '', "inboundPassengersDo": '',
"inboundRailwayDo": '', "inboundRailwayDo": 0,
"isHoliday": "", "isHoliday": "",
"outMark": "", "outMark": "",
"outPepole": '', "outPepole": '',
@ -635,7 +635,7 @@
"outRailwayMomDo": '', "outRailwayMomDo": '',
"outRailwayYomDo": '', "outRailwayYomDo": '',
"outboundPassengersDo": '', "outboundPassengersDo": '',
"outboundRailwayDo": '', "outboundRailwayDo":0,
"railwayName": item.railwayName, "railwayName": item.railwayName,
}) })
} }
@ -691,17 +691,17 @@
let now = new Date(); let now = new Date();
//11:00-13:30 0-12 //11:00-13:30 0-12
let dateStr = getDateStr(now, 0).replaceAll('-','/'); let dateStr = getDateStr(now, 0).replaceAll('-','/');
if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < // if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() <
new Date(dateStr + // new Date(dateStr +
' 13:30').getTime()) { // ' 13:30').getTime()) {
this.form.statPeriod = '0012'; // this.form.statPeriod = '0012';
let idx = this.array.findIndex(item => item.dictValue == '0012'); // let idx = this.array.findIndex(item => item.dictValue == '0012');
this.index = idx > -1 ? idx : ''; // this.index = idx > -1 ? idx : '';
} else { // } else {
this.form.statPeriod = '03'; //0-24 this.form.statPeriod = '03'; //0-24
let idx = this.array.findIndex(item => item.dictValue == '03'); let idx = this.array.findIndex(item => item.dictValue == '03');
this.index = idx > -1 ? idx : ''; this.index = idx > -1 ? idx : '';
} // }
this.queryDetail(this.form.statDate, this.form.statPeriod); this.queryDetail(this.form.statDate, this.form.statPeriod);
} else { } else {
let idx = this.array.findIndex(item => item.dictValue == this.form.statPeriod); let idx = this.array.findIndex(item => item.dictValue == this.form.statPeriod);

@ -171,15 +171,15 @@
let now = new Date(); let now = new Date();
//11:00-13:30 0-12 //11:00-13:30 0-12
let dateStr = getDateStr(now, 0).replaceAll('-','/'); 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()) { // if(new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < new Date(dateStr + ' 13:30').getTime()) {
this.form.statPeriod = '0012'; // this.form.statPeriod = '0012';
let idx = this.array.findIndex(item => item.dictValue == '0012'); // let idx = this.array.findIndex(item => item.dictValue == '0012');
this.index = idx > -1 ? idx : idx; // this.index = idx > -1 ? idx : idx;
}else{ // }else{
this.form.statPeriod = '03'; //0-24 this.form.statPeriod = '03'; //0-24
let idx = this.array.findIndex(item => item.dictValue == '03'); let idx = this.array.findIndex(item => item.dictValue == '03');
this.index = idx > -1 ? idx : idx; this.index = idx > -1 ? idx : idx;
} // }
}else{ }else{
let idx = this.array.findIndex(item => item.dictValue == this.form.statPeriod); let idx = this.array.findIndex(item => item.dictValue == this.form.statPeriod);
this.index = idx > -1 ? idx : idx; this.index = idx > -1 ? idx : idx;

@ -164,15 +164,15 @@
let now = new Date(); let now = new Date();
// let dateStr = getDateStr(now,0); // let dateStr = getDateStr(now,0);
let dateStr = getDateStr(now, 0).replaceAll('-','/'); 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()){ // if(new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < new Date(dateStr + ' 14:30').getTime()){
this.synthData.reportPhase = "0012"; // this.synthData.reportPhase = "0012";
this.index = this.roadTime.findIndex(item => item.dictValue == "0012") // this.index = this.roadTime.findIndex(item => item.dictValue == "0012")
this.timeName = this.roadTime.find(item => item.dictValue == "0012").dictLabel // this.timeName = this.roadTime.find(item => item.dictValue == "0012").dictLabel
}else{ // }else{
this.synthData.reportPhase = "03"; this.synthData.reportPhase = "03";
this.index = this.roadTime.findIndex(item => item.dictValue == "03") this.index = this.roadTime.findIndex(item => item.dictValue == "03")
this.timeName = this.roadTime.find(item => item.dictValue == "03").dictLabel this.timeName = this.roadTime.find(item => item.dictValue == "03").dictLabel
} // }
} }
}) })
}, },

@ -166,15 +166,15 @@
let now = new Date(); let now = new Date();
let dateStr = getDateStr(now,0); let dateStr = getDateStr(now,0);
console.log(new Date().getTime()) console.log(new Date().getTime())
if(new Date(dateStr + ' 11:00').getTime() < new Date().getTime() < new Date(dateStr + ' 13:30').getTime()){ // if(new Date(dateStr + ' 11:00').getTime() < new Date().getTime() < new Date(dateStr + ' 14:30').getTime()){
this.roadData.reportPhase = "0012"; // this.roadData.reportPhase = "0012";
this.index = this.roadTime.findIndex(item => item.dictValue == "0012") // this.index = this.roadTime.findIndex(item => item.dictValue == "0012")
this.timeName = this.roadTime.find(item => item.dictValue == "0012").dictLabel // this.timeName = this.roadTime.find(item => item.dictValue == "0012").dictLabel
}else{ // }else{
this.roadData.reportPhase = "03"; this.roadData.reportPhase = "03";
this.index = this.roadTime.findIndex(item => item.dictValue == "03") this.index = this.roadTime.findIndex(item => item.dictValue == "03")
this.timeName = this.roadTime.find(item => item.dictValue == "03").dictLabel this.timeName = this.roadTime.find(item => item.dictValue == "03").dictLabel
} // }
} }
}) })
}, },

@ -75,7 +75,7 @@
<view class="edit_item input"> <view class="edit_item input">
<p class="left">投放运力-班车数</p> <p class="left">投放运力-班车数</p>
<view class="right"> <view class="right">
<uni-easyinput maxlength="20" @blur="calcBusNum" @clear="calcBusNum" type="number" v-model="roadData.capacityShuttle" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput> <uni-easyinput :disabled="isEdit" length="20" @blur="calcBusNum" @clear="calcBusNum" type="number" v-model="roadData.capacityShuttle" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view> </view>
</view> </view>
<view class="edit_item input"> <view class="edit_item input">
@ -133,7 +133,7 @@
<view class="edit_item input"> <view class="edit_item input">
<p class="left">投放运力-班车班次</p> <p class="left">投放运力-班车班次</p>
<view class="right"> <view class="right">
<uni-easyinput @blur="calcTotalTrips" @clear="calcTotalTrips" type="number" v-model="roadData.capacityShuttleTrips" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput> <uni-easyinput :disabled="isEdit" @blur="calcTotalTrips" @clear="calcTotalTrips" type="number" v-model="roadData.capacityShuttleTrips" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view> </view>
</view> </view>
<view class="edit_item input"> <view class="edit_item input">
@ -171,7 +171,7 @@
<view class="edit_item input"> <view class="edit_item input">
<p class="left">班车客运量()</p> <p class="left">班车客运量()</p>
<view class="right"> <view class="right">
<uni-easyinput maxlength="20" @blur="calctotalPassenger" @clear="calctotalPassenger" type="number" v-model="roadData.shuttlePassengerVolume" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput> <uni-easyinput :disabled="isEdit" maxlength="20" @blur="calctotalPassenger" @clear="calctotalPassenger" type="number" v-model="roadData.shuttlePassengerVolume" placeholder="请输入" placeholderStyle="color:#d4d4d4;"></uni-easyinput>
</view> </view>
</view> </view>
<view class="edit_item input"> <view class="edit_item input">
@ -497,6 +497,7 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
mobile: getApp().globalData.mobile, mobile: getApp().globalData.mobile,
unitName:'', unitName:'',
peopleNumber:'', peopleNumber:'',
isEdit:false,
} }
}, },
onLoad(options){ onLoad(options){
@ -511,8 +512,9 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
}else if(options.type == 'add'){ }else if(options.type == 'add'){
this.pageType = 'add'; this.pageType = 'add';
let now = new Date(); let now = new Date();
this.roadData.statisticalDate = getDateStr(now, -1);// this.roadData.statisticalDate = getDateStr(now, 0);//
this.getDept(); // this.getDept();
this.getDict();
} }
}, },
@ -522,6 +524,12 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
phoneNumber: tel phoneNumber: tel
}); });
}, },
getDict(){
this.$request(getApp().globalData.baseUrl + '/api/dict/dictList?dictType=industry',"GET").then(res =>{
let code = res.data.find(item => item.dictLabel == '道路运输').dictValue
this.getDept(code)
})
},
getDataDetail(reportPhase,reportUnit,statisticalDate){ getDataDetail(reportPhase,reportUnit,statisticalDate){
this.$request(getApp().globalData.baseUrl + '/api/biz/roadtransport/road/getDetail?reportPhase=' + reportPhase + '&reportUnit=' + reportUnit + '&statisticalDate=' + statisticalDate,{},"GET").then(res =>{ this.$request(getApp().globalData.baseUrl + '/api/biz/roadtransport/road/getDetail?reportPhase=' + reportPhase + '&reportUnit=' + reportUnit + '&statisticalDate=' + statisticalDate,{},"GET").then(res =>{
res.data.reportPhase = this.roadData.reportPhase; res.data.reportPhase = this.roadData.reportPhase;
@ -539,6 +547,11 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
this.peopleName = tmp ? tmp.people.split(',')[0] : '' this.peopleName = tmp ? tmp.people.split(',')[0] : ''
this.peopleNumber = tmp ? tmp.people.split(',')[1] : this.roadData.contactNumber this.peopleNumber = tmp ? tmp.people.split(',')[1] : this.roadData.contactNumber
} }
if(this.isEdit){
this.roadData.capacityShuttle = this.roadData.capacityShuttle ? this.roadData.capacityShuttle : 0
this.roadData.capacityShuttleTrips = this.roadData.capacityShuttleTrips ? this.roadData.capacityShuttleTrips : 0
this.roadData.shuttlePassengerVolume = this.roadData.shuttlePassengerVolume ? this.roadData.shuttlePassengerVolume : 0
}
this.getRatio(); this.getRatio();
}) })
}, },
@ -641,11 +654,11 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
}) })
}, },
getDept(){ getDept(code){
// this.$request(getApp().globalData.baseUrl + '/api/dict/dictList?dictType=industry',{},"GET").then(res =>{ // this.$request(getApp().globalData.baseUrl + '/api/dict/dictList?dictType=industry',{},"GET").then(res =>{
// console.log('code===>',res) // console.log('code===>',res)
// }) // })
this.$request(getApp().globalData.baseUrl + '/api/dept/getCurrentAndSubordinateDept?tradeCode=09&deptName=',{},"GET").then(res =>{ this.$request(getApp().globalData.baseUrl + '/api/dept/getCurrentAndSubordinateDept?tradeCode='+ code +'&deptName=',{},"GET").then(res =>{
console.log('单位===>',res) console.log('单位===>',res)
this.treeData = res.data; this.treeData = res.data;
if(this.pageType == 'add'){ if(this.pageType == 'add'){
@ -654,6 +667,11 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
this.roadData.reportingUnitId = this.deptNameList.length > 0 ? this.deptNameList[0].deptName : ''; this.roadData.reportingUnitId = this.deptNameList.length > 0 ? this.deptNameList[0].deptName : '';
this.roadData.reportingUnitIdIndex = this.deptNameList.length > 0 ? 0 : ''; this.roadData.reportingUnitIdIndex = this.deptNameList.length > 0 ? 0 : '';
this.selectId1 = this.unitId; this.selectId1 = this.unitId;
if(res.data[0].children.length == 0){
this.isEdit = true
}else{
this.isEdit = false
}
this.getRoadTime() this.getRoadTime()
}else if(this.pageType == 'edit'){ }else if(this.pageType == 'edit'){
console.log('reportingUnitId===>',this.roadData.reportingUnitId) console.log('reportingUnitId===>',this.roadData.reportingUnitId)
@ -661,6 +679,14 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
this.unitId = this.roadData.responsiblePersonId; this.unitId = this.roadData.responsiblePersonId;
this.unitName = this.roadData.reportingUnitId; this.unitName = this.roadData.reportingUnitId;
this.selectId1 = this.unitId; this.selectId1 = this.unitId;
if(res.data[0].children.length == 0){
this.isEdit = true
this.roadData.capacityShuttle = this.roadData.capacityShuttle ? this.roadData.capacityShuttle : 0
this.roadData.capacityShuttleTrips = this.roadData.capacityShuttleTrips ? this.roadData.capacityShuttleTrips : 0
this.roadData.shuttlePassengerVolume = this.roadData.shuttlePassengerVolume ? this.roadData.shuttlePassengerVolume : 0
}else{
this.isEdit = false
}
this.getPeople() this.getPeople()
} }
}) })
@ -669,7 +695,8 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
this.$request(getApp().globalData.baseUrl + '/api/biz/roadtransport/road/getDataByTime?reportPhase=' + reportPhase + '&reportUnit=' + reportUnit + '&statisticalDate=' + statisticalDate,{},"GET").then(res =>{ this.$request(getApp().globalData.baseUrl + '/api/biz/roadtransport/road/getDataByTime?reportPhase=' + reportPhase + '&reportUnit=' + reportUnit + '&statisticalDate=' + statisticalDate,{},"GET").then(res =>{
this.roadData = res.data; this.roadData = res.data;
this.getRoadTime(); this.getRoadTime();
this.getDept(); this.getDict()
// this.getDept();
// console.log('last==>',lastYearDate(this.roadData.statisticalDate)) // console.log('last==>',lastYearDate(this.roadData.statisticalDate))
}) })
}, },
@ -814,21 +841,25 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
let now = new Date(); let now = new Date();
// let dateStr = getDateStr(now,0); // let dateStr = getDateStr(now,0);
let dateStr = getDateStr(now, 0).replaceAll('-','/'); 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()) { // if(new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < new Date(dateStr + ' 13:30').getTime()) {
this.roadData.reportPhase = "0012"; // this.roadData.reportPhase = "0012";
this.index = this.roadTime.findIndex(item => item.dictValue == "0012") // this.index = this.roadTime.findIndex(item => item.dictValue == "0012")
this.timeName = this.roadTime.find(item => item.dictValue == "0012").dictLabel // this.timeName = this.roadTime.find(item => item.dictValue == "0012").dictLabel
}else{ // }else{
this.roadData.reportPhase = "03"; this.roadData.reportPhase = "03";
this.index = this.roadTime.findIndex(item => item.dictValue == "03") this.index = this.roadTime.findIndex(item => item.dictValue == "03")
this.timeName = this.roadTime.find(item => item.dictValue == "03").dictLabel this.timeName = this.roadTime.find(item => item.dictValue == "03").dictLabel
} // }
// - // -
this.$request(getApp().globalData.baseUrl + '/api/biz/roadtransport/road/getDetail?reportPhase=' + this.roadData.reportPhase + '&reportUnit=' + this.roadData.reportingUnitId + '&statisticalDate=' + this.roadData.statisticalDate,{},"GET").then(res =>{ this.$request(getApp().globalData.baseUrl + '/api/biz/roadtransport/road/getDetail?reportPhase=' + this.roadData.reportPhase + '&reportUnit=' + this.roadData.reportingUnitId + '&statisticalDate=' + this.roadData.statisticalDate,{},"GET").then(res =>{
res.data.reportPhase = this.roadData.reportPhase; res.data.reportPhase = this.roadData.reportPhase;
res.data.reportingUnitId = this.roadData.reportingUnitId; res.data.reportingUnitId = this.roadData.reportingUnitId;
res.data.statisticalDate = this.roadData.statisticalDate; res.data.statisticalDate = this.roadData.statisticalDate;
this.roadData = res.data; this.roadData = res.data;
console.log('roadData ====>',this.roadData.capacityShuttle)
this.roadData.capacityShuttle = this.roadData.capacityShuttle ? this.roadData.capacityShuttle : 0
this.roadData.capacityShuttleTrips = this.roadData.capacityShuttleTrips ? this.roadData.capacityShuttleTrips : 0
this.roadData.shuttlePassengerVolume = this.roadData.shuttlePassengerVolume ? this.roadData.shuttlePassengerVolume : 0
this.getPeople() this.getPeople()
}) })
this.getRatio() this.getRatio()
@ -1027,6 +1058,11 @@ import { calcMom, calcYoy, checkNotEmpty, getDateStr, lastYearDate } from '../..
/deep/ .content-clear-icon{ /deep/ .content-clear-icon{
padding: 0 !important; padding: 0 !important;
} }
/deep/.is-disabled{
background: transparent !important;
color:#333;
}
} }
} }

@ -207,13 +207,15 @@
} }
console.log('params ===>',params) console.log('params ===>',params)
this.$request(getApp().globalData.baseUrl + '/api/biz/roadtransport/road/getTimeList',params,"GET").then(res =>{ this.$request(getApp().globalData.baseUrl + '/api/biz/roadtransport/road/getTimeList',params,"GET").then(res =>{
// this.$request(getApp().globalData.baseUrl + '/api/biz/roadtransport/road/list',params,"GET").then(res =>{
console.log(res) console.log(res)
if(res.code == 200){ if(res.code == 200){
res.data.list.map(item =>{ res.data.list.map(item =>{
item.show = false; item.show = false;
}) })
this.listData = this.listData.concat(res.data.list); this.listData = this.listData.concat(res.data.list);
if(res.data.list.length == 0 || res.data.list.length < this.size){ // if(res.data.list.length == 0 || res.data.list.length < this.size){
if(res.data.list.length == 0){
this.hasMore = false; this.hasMore = false;
this.status = 'nomore'; this.status = 'nomore';
}else{ }else{

@ -217,14 +217,14 @@
let now = new Date(); let now = new Date();
//11:00-13:30 0-12 //11:00-13:30 0-12
let dateStr = getDateStr(now, 0); let dateStr = getDateStr(now, 0);
if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < new Date(dateStr + // if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < new Date(dateStr +
' 13:30').getTime()) { // ' 14:30').getTime()) {
this.form.statPeriod = '0012'; // this.form.statPeriod = '0012';
this.index = this.array.findIndex(item => item.dictValue == '0012'); // this.index = this.array.findIndex(item => item.dictValue == '0012');
} else { // } else {
this.form.statPeriod = '03'; //0-24 this.form.statPeriod = '03'; //0-24
this.index = this.array.findIndex(item => item.dictValue == '03'); this.index = this.array.findIndex(item => item.dictValue == '03');
} // }
}else{ }else{
this.index = this.array.findIndex(item => item.dictValue == this.form.statPeriod); this.index = this.array.findIndex(item => item.dictValue == this.form.statPeriod);
} }

@ -255,14 +255,14 @@
let now = new Date(); let now = new Date();
//11:00-13:30 0-12 //11:00-13:30 0-12
let dateStr = getDateStr(now, 0).replaceAll('-','/'); let dateStr = getDateStr(now, 0).replaceAll('-','/');
if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < new Date(dateStr + // if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < new Date(dateStr +
' 13:30').getTime()) { // ' 14:30').getTime()) {
this.form.statPeriod = '0012'; // this.form.statPeriod = '0012';
this.index = this.array.findIndex(item => item.dictValue == '0012'); // this.index = this.array.findIndex(item => item.dictValue == '0012');
} else { // } else {
this.form.statPeriod = '03'; //0-24 this.form.statPeriod = '03'; //0-24
this.index = this.array.findIndex(item => item.dictValue == '03'); this.index = this.array.findIndex(item => item.dictValue == '03');
} // }
}else{ }else{
this.index = this.array.findIndex(item => item.dictValue == this.form.statPeriod); this.index = this.array.findIndex(item => item.dictValue == this.form.statPeriod);
} }

@ -493,17 +493,17 @@
let now = new Date(); let now = new Date();
//11:00-13:30 0-12 //11:00-13:30 0-12
let dateStr = getDateStr(now, 0).replaceAll('-', '/'); let dateStr = getDateStr(now, 0).replaceAll('-', '/');
if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() < // if (new Date(dateStr + ' 11:00').getTime() < new Date().getTime() && new Date().getTime() <
new Date(dateStr + // new Date(dateStr +
' 13:30').getTime()) { // ' 14:30').getTime()) {
this.form.statPeriod = '0012'; // this.form.statPeriod = '0012';
let idx = this.array.findIndex(item => item.dictValue == '0012'); // let idx = this.array.findIndex(item => item.dictValue == '0012');
this.index = idx > -1 ? idx : ''; // this.index = idx > -1 ? idx : '';
} else { // } else {
this.form.statPeriod = '03'; //0-24 this.form.statPeriod = '03'; //0-24
let idx = this.array.findIndex(item => item.dictValue == '03'); let idx = this.array.findIndex(item => item.dictValue == '03');
this.index = idx > -1 ? idx : ''; this.index = idx > -1 ? idx : '';
} // }
this.queryDetailInfo2(this.form.reportDate, this.form.statPeriod); this.queryDetailInfo2(this.form.reportDate, this.form.statPeriod);
} else { } else {
let idx = this.array.findIndex(item => item.dictValue == this.form.statPeriod); let idx = this.array.findIndex(item => item.dictValue == this.form.statPeriod);

Loading…
Cancel
Save