fix daily chart

main
Giò Diani 2025-01-09 18:49:09 +01:00
parent 3b935a4d20
commit 774e30c945
1 changed files with 7 additions and 2 deletions

View File

@ -156,7 +156,7 @@ const cCapacityDailyOptions = {
}, },
series: [{ series: [{
type: 'bar', type: 'bar',
data: {!! json_encode($cM['capacities']) !!} data: {!! json_encode($cD['capacities']) !!}
}] }]
}, },
@endforeach @endforeach
@ -309,13 +309,18 @@ cTimeline.on('timelinechanged', (e) => {
// Set markpoint on linechart // Set markpoint on linechart
let x = cCapacityOptions.xAxis.data[e.currentIndex]; let x = cCapacityOptions.xAxis.data[e.currentIndex];
let y = cCapacityOptions.series.data[e.currentIndex]; let y = cCapacityOptions.series[0].data[e.currentIndex];
cCapacityMonthly.dispatchAction({ cCapacityMonthly.dispatchAction({
type: 'timelineChange', type: 'timelineChange',
currentIndex: e.currentIndex currentIndex: e.currentIndex
}); });
cCapacityDaily.dispatchAction({
type: 'timelineChange',
currentIndex: e.currentIndex
});
cCalendar.dispatchAction({ cCalendar.dispatchAction({
type: 'timelineChange', type: 'timelineChange',
currentIndex: e.currentIndex currentIndex: e.currentIndex