fixed Bug that caused an error when switching between categories in the speed flowchart

This commit is contained in:
Dorian Zedler 2019-07-14 12:48:49 +02:00
parent aaff46e582
commit 0dabf8d576

View file

@ -104,7 +104,7 @@ DataListView {
onWidgetDataChanged: { onWidgetDataChanged: {
console.log("widget data changed") console.log("widget data changed")
if(control.widgetData['discipline'] === 'speed'){ if(control.widgetData['discipline'] === 'speed' && control.widgetData['route_order'] === "-1" && Object.keys(control.widgetData['route_names']).length > 2){
speedFlowChart.flowchartData = ({}) speedFlowChart.flowchartData = ({})
speedFlowChart.enabled = true speedFlowChart.enabled = true
speedFlowChart.flowchartData = control.widgetData speedFlowChart.flowchartData = control.widgetData