Skip to content

Commit 8ef252a

Browse files
authored
FIX: Hot fix for KPI not having dataProperties.
Added logic to check if KPI have dataProperties.
1 parent 1bf79c7 commit 8ef252a

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

MDX2JSON/Dashboard.cls

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,8 +115,10 @@ ClassMethod WidgetToProxyObject(Widget As %DeepSee.Dashboard.Widget, CubeName As
115115
if $piece(Widget.dataSource, ".", *) = "kpi" {
116116
set kpiClass = ##class(%DeepSee.Utils).%GetKPIClass(Widget.dataSource)
117117
set obj.kpitype = $classmethod(kpiClass, "%GetSourceType")
118-
set widgetData = Widget.dataProperties.GetAt(1)
119-
set obj.format = widgetData.format // duplicating format data in case of incompatible widget
118+
if (Widget.dataProperties.GetAt(1)) { // check if KPI have dataProperies
119+
set widgetData = Widget.dataProperties.GetAt(1)
120+
set obj.format = widgetData.format // duplicating format data in case of KPI
121+
}
120122
}
121123

122124
// Widget is a portlet

0 commit comments

Comments
 (0)