Browse Source

调整部分函数引用模式

lite
453530270@qq.com 3 years ago
parent
commit
4cccc8cbee
  1. 31
      src/views/ty/index.vue

31
src/views/ty/index.vue

@ -236,7 +236,6 @@ export default {
this.ty_pieDo()//
this.ty_bar3()//
}, 200);
// this.ty_bar2()
})
@ -612,9 +611,9 @@ export default {
function run(myChart){
let that = this;
// -
that.getGcgNumDatas();
// that.getGcgNumDatas();
setTimeout(() => {
var xData = this.rsqsXData;
// var xData = this.rsqsXData;
var data = this.rsqsDataAll;
var series = [];
@ -696,7 +695,7 @@ export default {
var myChart3 = echarts.init(pieDom3);
function run(){
that.gethomeBarData();
// that.gethomeBarData();
setTimeout(() => {
myChart1.clear();
that.ty_pie(myChart1,that.groupsData[0]);
@ -711,9 +710,9 @@ export default {
}, 1500);
}
run();
// setInterval(function () {
// run();
// }, 3000);
setInterval(function () {
run();
}, 3000);
},
ty_pie(myChart,DD){
let that = this;
@ -842,10 +841,10 @@ export default {
}
// 使
// setTimeout(()=>{
setTimeout(()=>{
// var myChart = echarts.init(Element);
option && myChart.setOption(option);
// }, 200)
}, 200)
},
// 24
@ -870,17 +869,22 @@ export default {
//
gethomeBarData(){
let that = this;
// |
let idArr = "";
homeApi.getID().then(res=>{
// console.log(res, '=====');
let idArr = "";
// let idArr = "";
res.data.data.map(item=>{
if(item.type==1){
idArr += "|"+item.groupId;
}
})
that.groupsData = [];
//
homeApi.homeBarData({groupsId:idArr}).then(res=>{
// that.groupsData = [];
});
//
homeApi.homeBarData({groupsId:idArr}).then(res=>{
// console.log(res, '==');
res.data.data.groupsData.forEach(item=>{
that.groupsData.push(item);
@ -895,7 +899,6 @@ export default {
that.cgn_3 = that.groupsData[2].groupName;
that.cgv_2 = that.groupsData[1].noRepeatInNum;
that.cgp_3 = that.groupsData[2]?that.groupsData[2].proportion:'';
});
});
},

Loading…
Cancel
Save