Commit e9918a92 by 成立

fix

parent f249ecff
正在显示 包含 15 行增加20 行删除
...@@ -48,6 +48,7 @@ ...@@ -48,6 +48,7 @@
}); });
var apiUrl = 'http://47.92.120.206:18080/wedo-fit'; var apiUrl = 'http://47.92.120.206:18080/wedo-fit';
var id = '8353714658471936'; var id = '8353714658471936';
var arr = [];
$.ajax({ $.ajax({
url: apiUrl + '/wedofit/class/group/intro/' + id, url: apiUrl + '/wedofit/class/group/intro/' + id,
type: 'GET', type: 'GET',
...@@ -58,32 +59,25 @@ ...@@ -58,32 +59,25 @@
$('.trainingEffect').text(resp.data.trainingEffect); $('.trainingEffect').text(resp.data.trainingEffect);
$('.suitableFor').text(resp.data.suitableFor); $('.suitableFor').text(resp.data.suitableFor);
$('.attention').text(resp.data.attention); $('.attention').text(resp.data.attention);
} arr = [resp.data.consumeLevel,resp.data.coordinationLevel,resp.data.pliableLevel,resp.data.strengthLevel,resp.data.heartbeatLevel];
});
var myChart = echarts.init(document.getElementById('main'));
// 指定图表的配置项和数据
var option = { var option = {
title: {
text: '多雷达图'
},
tooltip: { tooltip: {
trigger: 'axis' trigger: 'axis'
}, },
legend: { textStyle: {
x: 'center', fontSize : 50
data:['某软件','某主食手机','某水果手机','降水量','蒸发量']
}, },
radar: [ radar: [
{ {
indicator: [ indicator: [
{text: '品牌', max: 100}, {text: '消耗分值', max: 5},
{text: '内容', max: 100}, {text: '协调分值', max: 5},
{text: '可用性', max: 100}, {text: '柔韧分值', max: 5},
{text: '功能', max: 100} {text: '力量分值', max: 5},
{text: '心肺分值', max: 5}
], ],
center: ['50%','50%'], center: ['50%','50%'],
radius: 80 radius: 200
} }
], ],
series: [ series: [
...@@ -95,17 +89,18 @@ ...@@ -95,17 +89,18 @@
itemStyle: {normal: {areaStyle: {type: 'default'}}}, itemStyle: {normal: {areaStyle: {type: 'default'}}},
data: [ data: [
{ {
value: [60,73,85,40], value: arr
name: '某软件'
} }
] ]
} }
] ]
}; };
// 使用刚指定的配置项和数据显示图表。
myChart.setOption(option); myChart.setOption(option);
}
});
var myChart = echarts.init(document.getElementById('main'));
}) })
</script> </script>
</body> </body>
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此消息的编辑!
注册登录 后发表评论