fix:任务统计页面的请求报错
This commit is contained in:
parent
12abe192ad
commit
5487e1f74d
|
|
@ -637,13 +637,18 @@ export default {
|
|||
that.query.start_date = that.query.querys[0][0].value = first.toISOString().split('T')[0];
|
||||
that.query.end_date = that.query.querys[1][0].value = last.toISOString().split('T')[0];
|
||||
that.options.forEach((item,index)=>{
|
||||
that.getData(item.id,item.name,index);
|
||||
console.log('item',item);
|
||||
setTimeout(()=>{
|
||||
that.getData(item.id,item.name,index);
|
||||
},500)
|
||||
|
||||
})
|
||||
|
||||
},
|
||||
getMgroup(){
|
||||
let that = this;
|
||||
that.options = [];
|
||||
that.$API.mtm.mgroup.list.req({ page: 0}).then((res) => {
|
||||
// that.options = res.slice(21);
|
||||
that.options = res;
|
||||
let nowDate = new Date();
|
||||
that.getWeekDate(nowDate);
|
||||
|
|
@ -669,18 +674,19 @@ export default {
|
|||
getData(mgroup_id,mgroup_name,mgroup_index) {
|
||||
let that = this;
|
||||
that.tableData1 = [];
|
||||
that.query.querys[0][1].value = null;
|
||||
that.query.querys[1][1].value = null;
|
||||
let option = deepCopy(that.basicOption);
|
||||
option.title.text = mgroup_name+"任务进度";
|
||||
option.series.data[0].value = 0;
|
||||
option.series.data[1].value = 0;
|
||||
|
||||
that.query.querys[0][1].value = mgroup_id;
|
||||
that.query.querys[1][1].value = mgroup_id;
|
||||
that.$API.pm.mtask.cquery.req(that.query).then((res) => {
|
||||
let names = 'tableData'+mgroup_index;
|
||||
that[names] = res;
|
||||
console.log('names',names);
|
||||
console.log('that[names]',that[names]);
|
||||
// console.log('names',names);
|
||||
// console.log('that[names]',that[names]);
|
||||
let count_jh = 0,count_ok = 0,count_diff = 0;
|
||||
if (res.length > 0) {
|
||||
res.forEach((item) => {
|
||||
|
|
@ -696,7 +702,6 @@ export default {
|
|||
let chartId = 'linechart'+mgroup_index;
|
||||
that.setChart(chartId, option);
|
||||
}
|
||||
|
||||
});
|
||||
},
|
||||
handleQuery(){
|
||||
|
|
@ -715,7 +720,9 @@ export default {
|
|||
that.query.querys[1][0].value = that.end_date;
|
||||
}
|
||||
that.options.forEach((item,index)=>{
|
||||
that.getData(item.id,item.name,index);
|
||||
setTimeout(()=>{
|
||||
that.getData(item.id,item.name,index);
|
||||
},500)
|
||||
})
|
||||
},
|
||||
handleExport(val) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue