Commit 9983a514 authored by xxx's avatar xxx

修改绩效统计接口

parent ea0dc6f8
...@@ -1238,7 +1238,7 @@ var HttpReq = function(){ ...@@ -1238,7 +1238,7 @@ var HttpReq = function(){
data:data, data:data,
}) })
}, },
//车辆产量,司机产量,车辆班次,司机班次总的年月日 //车辆产量,车辆班次总的年月日
apiManmadesCheDayQueryDay: function(param){ apiManmadesCheDayQueryDay: function(param){
return request({ return request({
url: '/api/Manmades/CheDay', url: '/api/Manmades/CheDay',
...@@ -1260,6 +1260,14 @@ var HttpReq = function(){ ...@@ -1260,6 +1260,14 @@ var HttpReq = function(){
params:param, params:param,
}) })
}, },
//司机产量,司机班次总的年月日
apiManmadesSijiQueryDay: function(param){
return request({
url: '/api/Manmades/Siji',
method: 'get',
params:param,
})
},
//绩效统计——日报——车辆产量报表 //绩效统计——日报——车辆产量报表
carOutputQueryDay: function(param){ carOutputQueryDay: function(param){
return request({ return request({
...@@ -1447,6 +1455,14 @@ var HttpReq = function(){ ...@@ -1447,6 +1455,14 @@ var HttpReq = function(){
}) })
}, },
//绩效统计——月报——区域产量报表采区 //绩效统计——月报——区域产量报表采区
apiPlanNewZhouQuery: function(param){
return request({
url: '/api/PlanNew/Zhou',
method: 'get',
params:param,
})
},
//绩效统计——月报——区域产量报表采区
caiquAreaQueryMonth: function(param){ caiquAreaQueryMonth: function(param){
return request({ return request({
url: '/api/PlanNew/Month', url: '/api/PlanNew/Month',
......
...@@ -49,47 +49,56 @@ export default { ...@@ -49,47 +49,56 @@ export default {
this.yearCurrentTimeFn(); this.yearCurrentTimeFn();
//装卸点平均时长 //装卸点平均时长
if(this.loadAndUnloadListData.selectTimeText == 'day'){ if(this.loadAndUnloadListData.selectTimeText == 'day'){
HttpReq.truckDispatching.xiequAreaQueryDay({createTime:this.currentTime.day}).then((res) => { HttpReq.truckDispatching.xiequAreaQueryDay({createTime:this.currentTime.day}).then((res1) => {
if(res.code == 200){ if(res1.code == 200){
HttpReq.truckDispatching.caiquAreaQueryDay({createTime:this.currentTime.day}).then((res2) => {
let lastData1 = [...res1.data, ...res2];
let caiquName = []; let caiquName = [];
let workTime = []; let workTime = [];
res.data.forEach((item,index)=>{ lastData1.forEach((item,index)=>{
caiquName.push(item.name); caiquName.push(item.name);
workTime.push(item.worktime); workTime.push(item.worktime);
}) })
this.loadAndUnloadListData.caiquName = caiquName; this.loadAndUnloadListData.caiquName = caiquName;
this.loadAndUnloadListData.timeData = workTime; this.loadAndUnloadListData.timeData = workTime;
this.echarts4Fn(); this.echarts4Fn();
})
} }
}) })
} }
if(this.loadAndUnloadListData.selectTimeText == 'week'){ if(this.loadAndUnloadListData.selectTimeText == 'week'){
HttpReq.truckDispatching.xiequAreaQueryMonth({createTime:this.currentTime.month}).then((res) => { HttpReq.truckDispatching.xiequAreaQueryMonth({createTime:this.currentTime.month}).then((res1) => {
if(res.code == 200){ if(res1.code == 200){
HttpReq.truckDispatching.apiPlanNewZhouQuery().then((res2) => {
let lastData1 = [...res1.data, ...res2];
let caiquName = []; let caiquName = [];
let workTime = []; let workTime = [];
res.data.forEach((item,index)=>{ lastData1.forEach((item,index)=>{
caiquName.push(item.name); caiquName.push(item.name);
workTime.push(item.worktime); workTime.push(item.worktime);
}) })
this.loadAndUnloadListData.caiquName = caiquName; this.loadAndUnloadListData.caiquName = caiquName;
this.loadAndUnloadListData.timeData = workTime; this.loadAndUnloadListData.timeData = workTime;
this.echarts4Fn(); this.echarts4Fn();
})
} }
}) })
} }
if(this.loadAndUnloadListData.selectTimeText == 'month'){ if(this.loadAndUnloadListData.selectTimeText == 'month'){
HttpReq.truckDispatching.xiequAreaQueryYear({createTime:this.currentTime.year}).then((res) => { HttpReq.truckDispatching.xiequAreaQueryYear({createTime:this.currentTime.year}).then((res1) => {
if(res.code == 200){ if(res1.code == 200){
HttpReq.truckDispatching.caiquAreaQueryMonth({createTime:this.currentTime.month}).then((res2) => {
let lastData1 = [...res1.data, ...res2];
let caiquName = []; let caiquName = [];
let workTime = []; let workTime = [];
res.data.forEach((item,index)=>{ lastData1.forEach((item,index)=>{
caiquName.push(item.name); caiquName.push(item.name);
workTime.push(item.worktime); workTime.push(item.worktime);
}) })
this.loadAndUnloadListData.caiquName = caiquName; this.loadAndUnloadListData.caiquName = caiquName;
this.loadAndUnloadListData.timeData = workTime; this.loadAndUnloadListData.timeData = workTime;
this.echarts4Fn(); this.echarts4Fn();
})
} }
}) })
} }
...@@ -97,98 +106,116 @@ export default { ...@@ -97,98 +106,116 @@ export default {
this.DPcomputer25BoxTimer = setInterval(() => { this.DPcomputer25BoxTimer = setInterval(() => {
//装卸点平均时长 //装卸点平均时长
if(this.loadAndUnloadListData.selectTimeText == 'day'){ if(this.loadAndUnloadListData.selectTimeText == 'day'){
HttpReq.truckDispatching.xiequAreaQueryDay({createTime:this.currentTime.day}).then((res) => { HttpReq.truckDispatching.xiequAreaQueryDay({createTime:this.currentTime.day}).then((res1) => {
if(res.code == 200){ if(res1.code == 200){
HttpReq.truckDispatching.caiquAreaQueryDay({createTime:this.currentTime.day}).then((res2) => {
let lastData1 = [...res1.data, ...res2];
let caiquName = []; let caiquName = [];
let workTime = []; let workTime = [];
res.data.forEach((item,index)=>{ lastData1.forEach((item,index)=>{
caiquName.push(item.name); caiquName.push(item.name);
workTime.push(item.worktime); workTime.push(item.worktime);
}) })
this.loadAndUnloadListData.caiquName = caiquName; this.loadAndUnloadListData.caiquName = caiquName;
this.loadAndUnloadListData.timeData = workTime; this.loadAndUnloadListData.timeData = workTime;
this.echarts4Fn(); this.echarts4Fn();
})
} }
}) })
} }
if(this.loadAndUnloadListData.selectTimeText == 'week'){ if(this.loadAndUnloadListData.selectTimeText == 'week'){
HttpReq.truckDispatching.xiequAreaQueryMonth({createTime:this.currentTime.month}).then((res) => { HttpReq.truckDispatching.xiequAreaQueryMonth({createTime:this.currentTime.month}).then((res1) => {
if(res.code == 200){ if(res1.code == 200){
HttpReq.truckDispatching.apiPlanNewZhouQuery().then((res2) => {
let lastData1 = [...res1.data, ...res2];
let caiquName = []; let caiquName = [];
let workTime = []; let workTime = [];
res.data.forEach((item,index)=>{ lastData1.forEach((item,index)=>{
caiquName.push(item.name); caiquName.push(item.name);
workTime.push(item.worktime); workTime.push(item.worktime);
}) })
this.loadAndUnloadListData.caiquName = caiquName; this.loadAndUnloadListData.caiquName = caiquName;
this.loadAndUnloadListData.timeData = workTime; this.loadAndUnloadListData.timeData = workTime;
this.echarts4Fn(); this.echarts4Fn();
})
} }
}) })
} }
if(this.loadAndUnloadListData.selectTimeText == 'month'){ if(this.loadAndUnloadListData.selectTimeText == 'month'){
HttpReq.truckDispatching.xiequAreaQueryYear({createTime:this.currentTime.year}).then((res) => { HttpReq.truckDispatching.xiequAreaQueryYear({createTime:this.currentTime.year}).then((res1) => {
if(res.code == 200){ if(res1.code == 200){
HttpReq.truckDispatching.caiquAreaQueryMonth({createTime:this.currentTime.month}).then((res2) => {
let lastData1 = [...res1.data, ...res2];
let caiquName = []; let caiquName = [];
let workTime = []; let workTime = [];
res.data.forEach((item,index)=>{ lastData1.forEach((item,index)=>{
caiquName.push(item.name); caiquName.push(item.name);
workTime.push(item.worktime); workTime.push(item.worktime);
}) })
this.loadAndUnloadListData.caiquName = caiquName; this.loadAndUnloadListData.caiquName = caiquName;
this.loadAndUnloadListData.timeData = workTime; this.loadAndUnloadListData.timeData = workTime;
this.echarts4Fn(); this.echarts4Fn();
})
} }
}) })
} }
},20000) },60000)
}, },
//装卸点平均时长切换 //装卸点平均时长切换
loadAndUnloadChangeTime(text){ loadAndUnloadChangeTime(text){
this.loadAndUnloadListData.selectTimeText = text; this.loadAndUnloadListData.selectTimeText = text;
if(text == 'day'){ if(this.loadAndUnloadListData.selectTimeText == 'day'){
HttpReq.truckDispatching.xiequAreaQueryDay({createTime:this.currentTime.day}).then((res) => { HttpReq.truckDispatching.xiequAreaQueryDay({createTime:this.currentTime.day}).then((res1) => {
if(res.code == 200){ if(res1.code == 200){
HttpReq.truckDispatching.caiquAreaQueryDay({createTime:this.currentTime.day}).then((res2) => {
let lastData1 = [...res1.data, ...res2];
let caiquName = []; let caiquName = [];
let workTime = []; let workTime = [];
res.data.forEach((item,index)=>{ lastData1.forEach((item,index)=>{
caiquName.push(item.name); caiquName.push(item.name);
workTime.push(item.worktime); workTime.push(item.worktime);
}) })
this.loadAndUnloadListData.caiquName = caiquName; this.loadAndUnloadListData.caiquName = caiquName;
this.loadAndUnloadListData.timeData = workTime; this.loadAndUnloadListData.timeData = workTime;
this.echarts4Fn(); this.echarts4Fn();
})
} }
}) })
} }
if(text == 'week'){ if(this.loadAndUnloadListData.selectTimeText == 'week'){
HttpReq.truckDispatching.xiequAreaQueryMonth({createTime:this.currentTime.month}).then((res) => { HttpReq.truckDispatching.xiequAreaQueryMonth({createTime:this.currentTime.month}).then((res1) => {
if(res.code == 200){ if(res1.code == 200){
HttpReq.truckDispatching.apiPlanNewZhouQuery().then((res2) => {
let lastData1 = [...res1.data, ...res2];
let caiquName = []; let caiquName = [];
let workTime = []; let workTime = [];
res.data.forEach((item,index)=>{ lastData1.forEach((item,index)=>{
caiquName.push(item.name); caiquName.push(item.name);
workTime.push(item.worktime); workTime.push(item.worktime);
}) })
this.loadAndUnloadListData.caiquName = caiquName; this.loadAndUnloadListData.caiquName = caiquName;
this.loadAndUnloadListData.timeData = workTime; this.loadAndUnloadListData.timeData = workTime;
this.echarts4Fn(); this.echarts4Fn();
})
} }
}) })
} }
if(text == 'month'){ if(this.loadAndUnloadListData.selectTimeText == 'month'){
HttpReq.truckDispatching.xiequAreaQueryYear({createTime:this.currentTime.year}).then((res) => { HttpReq.truckDispatching.xiequAreaQueryYear({createTime:this.currentTime.year}).then((res1) => {
if(res.code == 200){ if(res1.code == 200){
HttpReq.truckDispatching.caiquAreaQueryMonth({createTime:this.currentTime.month}).then((res2) => {
let lastData1 = [...res1.data, ...res2];
let caiquName = []; let caiquName = [];
let workTime = []; let workTime = [];
res.data.forEach((item,index)=>{ lastData1.forEach((item,index)=>{
caiquName.push(item.name); caiquName.push(item.name);
workTime.push(item.worktime); workTime.push(item.worktime);
}) })
this.loadAndUnloadListData.caiquName = caiquName; this.loadAndUnloadListData.caiquName = caiquName;
this.loadAndUnloadListData.timeData = workTime; this.loadAndUnloadListData.timeData = workTime;
this.echarts4Fn(); this.echarts4Fn();
})
} }
}) })
} }
...@@ -201,8 +228,8 @@ export default { ...@@ -201,8 +228,8 @@ export default {
trigger: 'axis' trigger: 'axis'
}, },
grid: { grid: {
left: '3%', left: '0%',
right: '4%', right: '0%',
bottom: '3%', bottom: '3%',
containLabel: true containLabel: true
}, },
......
...@@ -76,13 +76,13 @@ export default { ...@@ -76,13 +76,13 @@ export default {
} }
this.$nextTick(()=>{ this.$nextTick(()=>{
HttpReq.truckDispatching.apiManmadesCheDayQueryDay(param).then((res) => { HttpReq.truckDispatching.apiManmadesSijiQueryDay(param).then((res) => {
if(res.code == 200){ if(res.code == 200){
this.loading = false; this.loading = false;
this.tableData = res.data; this.tableData = res.data;
} }
}) })
HttpReq.truckDispatching.apiManmadesCheDayQueryDay({createTime:param.createTime,size:9999,page:0}).then((res) => { HttpReq.truckDispatching.apiManmadesSijiQueryDay({createTime:param.createTime,size:9999,page:0}).then((res) => {
if(res.code == 200){ if(res.code == 200){
this.total = res.data.length; this.total = res.data.length;
} }
......
...@@ -76,13 +76,13 @@ export default { ...@@ -76,13 +76,13 @@ export default {
} }
this.$nextTick(()=>{ this.$nextTick(()=>{
HttpReq.truckDispatching.apiManmadesCheMonthQueryMonth(param).then((res) => { HttpReq.truckDispatching.apiManmadesSijiQueryDay(param).then((res) => {
if(res.code == 200){ if(res.code == 200){
this.loading = false; this.loading = false;
this.tableData = res.data; this.tableData = res.data;
} }
}) })
HttpReq.truckDispatching.apiManmadesCheMonthQueryMonth({createTime:param.createTime,size:9999,page:0}).then((res) => { HttpReq.truckDispatching.apiManmadesSijiQueryDay({createTime:param.createTime,size:9999,page:0}).then((res) => {
if(res.code == 200){ if(res.code == 200){
this.total = res.data.length; this.total = res.data.length;
} }
......
...@@ -76,13 +76,13 @@ export default { ...@@ -76,13 +76,13 @@ export default {
} }
this.$nextTick(()=>{ this.$nextTick(()=>{
HttpReq.truckDispatching.apiManmadesCheYearQueryYear(param).then((res) => { HttpReq.truckDispatching.apiManmadesSijiQueryDay(param).then((res) => {
if(res.code == 200){ if(res.code == 200){
this.loading = false; this.loading = false;
this.tableData = res.data; this.tableData = res.data;
} }
}) })
HttpReq.truckDispatching.apiManmadesCheYearQueryYear({createTime:param.createTime,size:9999,page:0}).then((res) => { HttpReq.truckDispatching.apiManmadesSijiQueryDay({createTime:param.createTime,size:9999,page:0}).then((res) => {
if(res.code == 200){ if(res.code == 200){
this.total = res.data.length; this.total = res.data.length;
} }
......
...@@ -75,13 +75,13 @@ export default { ...@@ -75,13 +75,13 @@ export default {
} }
this.$nextTick(()=>{ this.$nextTick(()=>{
HttpReq.truckDispatching.apiManmadesCheDayQueryDay(param).then((res) => { HttpReq.truckDispatching.apiManmadesSijiQueryDay(param).then((res) => {
if(res.code == 200){ if(res.code == 200){
this.loading = false; this.loading = false;
this.tableData = res.data; this.tableData = res.data;
} }
}) })
HttpReq.truckDispatching.apiManmadesCheDayQueryDay({createTime:param.createTime,size:9999,page:0}).then((res) => { HttpReq.truckDispatching.apiManmadesSijiQueryDay({createTime:param.createTime,size:9999,page:0}).then((res) => {
if(res.code == 200){ if(res.code == 200){
this.total = res.data.length; this.total = res.data.length;
} }
......
...@@ -75,13 +75,13 @@ export default { ...@@ -75,13 +75,13 @@ export default {
} }
this.$nextTick(()=>{ this.$nextTick(()=>{
HttpReq.truckDispatching.apiManmadesCheMonthQueryMonth(param).then((res) => { HttpReq.truckDispatching.apiManmadesSijiQueryDay(param).then((res) => {
if(res.code == 200){ if(res.code == 200){
this.loading = false; this.loading = false;
this.tableData = res.data; this.tableData = res.data;
} }
}) })
HttpReq.truckDispatching.apiManmadesCheMonthQueryMonth({createTime:param.createTime,size:9999,page:0}).then((res) => { HttpReq.truckDispatching.apiManmadesSijiQueryDay({createTime:param.createTime,size:9999,page:0}).then((res) => {
if(res.code == 200){ if(res.code == 200){
this.total = res.data.length; this.total = res.data.length;
} }
......
...@@ -75,13 +75,13 @@ export default { ...@@ -75,13 +75,13 @@ export default {
} }
this.$nextTick(()=>{ this.$nextTick(()=>{
HttpReq.truckDispatching.apiManmadesCheYearQueryYear(param).then((res) => { HttpReq.truckDispatching.apiManmadesSijiQueryDay(param).then((res) => {
if(res.code == 200){ if(res.code == 200){
this.loading = false; this.loading = false;
this.tableData = res.data; this.tableData = res.data;
} }
}) })
HttpReq.truckDispatching.apiManmadesCheYearQueryYear({createTime:param.createTime,size:9999,page:0}).then((res) => { HttpReq.truckDispatching.apiManmadesSijiQueryDay({createTime:param.createTime,size:9999,page:0}).then((res) => {
if(res.code == 200){ if(res.code == 200){
this.total = res.data.length; this.total = res.data.length;
} }
......
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