visualmap折线图_Echarts---折线图--柱状图

该博客展示了如何使用Echarts创建心率和力竭状态的图表。通过心率折线图和力竭状态的柱状图,实时呈现运动员的训练数据。数据包括心率次数和配速时长,便于理解训练状况。
摘要由CSDN通过智能技术生成

{ { username }}

心率

{ { xinludata }}

力竭状态

{ {status}}

{ {widthData}}%

{ { peisudata }}

返回

import moment from 'moment'

import { STable } from '@/components'

import { getRoleList } from '@/api/manage'

import { getTrainingRecordPrecise } from '@/api/training'

export default {

name: 'TrainingStatus',

components: {

STable,

},

data() {

return {

dateList: [],

valueList: [],

peopleparameterdata: [],//原生跑后台数据

sourceData2:[], //原生化跑整理数据

keydata:[],

widthData: 0,//力竭状态数据

status: '',

xinludata: '',

peisudata: '',

username: '' // 队员名字

}

},

props: ['record'],

created () {

// console.log('record是个啥:' + JSON.stringify(this.record))

const getparam = {

course_training_id: this.record.course_training_id,

kind: 1

}

getRoleList({ t: new Date() })

// console.log('向后台传递的参数' + JSON.stringify(getparam))

getTrainingRecordPrecise(getparam).then(res => {

// console.log('返回的状态数据' + JSON.stringify(res))

this.username = res.data[0].name

if (res.data[0].status == 0) {

this.status = '暂无状态数据!'

} else {

this.widthData = res.data[0].status

}

if (res.data[0].heart_rate.xaxis.length !== 0) {

// this.trainingdata = res.data[0].heart_rate

this.dateList = res.data[0].heart_rate.xaxis

this.valueList = res.data[0].heart_rate.data

this.drawLine()

} else {

this.xinludata = '暂无心率数据'<

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值