Add null guard for performanceData before accessing time properties
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -919,6 +919,10 @@ function getAvgWaitingTimeLineChart(chartData, content, yUnit) {
|
||||
|
||||
// 取得 Performance Data
|
||||
await performanceStore.getPerformance(type, id);
|
||||
if(!performanceData.value?.time) {
|
||||
isLoading.value = false;
|
||||
return;
|
||||
}
|
||||
avgProcessTimeByTaskHeight.value = await getHorizontalBarHeight(performanceData.value.time.avg_process_time_by_task);
|
||||
if(performanceData.value.time.avg_waiting_time_by_edge !== null) {
|
||||
avgWaitingTimeByEdgeHeight.value = await getHorizontalBarHeight(performanceData.value.time.avg_waiting_time_by_edge);
|
||||
|
||||
Reference in New Issue
Block a user