我想绘制折线图,但是我的日期从sql-server数据中获取包括时间在内的值 我该如何节省时间
Sensor
console.log(json) 这是结果
console.log(json);
if (json.length > 0) {
var datagraph = [];
datagraph.push(['Date', 'Point']);
for (i = 0; i < json.length; i++) {
var smalldata = [];
var date = json[i].Date;
var point = json[i].Point;
smalldata.push(date, point);
datagraph.push(smalldata);
}
}
答案 0 :(得分:0)
使用函数“ split”将字符串除以字符“ T”
<div style="position: relative; width: 100px; height: 100px; display: flex; align-items: center; justify-content: center;">
<mat-progress-spinner style="width: 100px;height: 100px;position: absolute;top: 0;left: 0;" [color]="'primary'" [mode]="'determinate'" [value]="60">
</mat-progress-spinner>
<h1 >69%</h1>
</div>