diff --git a/Thermo.Active/wwwroot/src/app_modules_thermo/components/combo.ts b/Thermo.Active/wwwroot/src/app_modules_thermo/components/combo.ts index 7a418107..e071b357 100644 --- a/Thermo.Active/wwwroot/src/app_modules_thermo/components/combo.ts +++ b/Thermo.Active/wwwroot/src/app_modules_thermo/components/combo.ts @@ -12,13 +12,14 @@ export default class Combo extends Vue { get options() { let result: { id: number, text: string, anim: string }[] = []; - for (const key in this.value.enumVal) { - if (this.value.enumVal.hasOwnProperty(key)) { - const element = this.value.enumVal[key]; + if (this.value.enumVal) + for (const key in this.value.enumVal) { + if (this.value.enumVal.hasOwnProperty(key)) { + const element = this.value.enumVal[key]; - result.push({ id: parseInt(key), text: element.text, anim: element.anim }) + result.push({ id: parseInt(key), text: element.text, anim: element.anim }) + } } - } return result; } diff --git a/Thermo.Active/wwwroot/src/app_modules_thermo/components/svgChart.ts b/Thermo.Active/wwwroot/src/app_modules_thermo/components/svgChart.ts index 333a1eef..d0cacea4 100644 --- a/Thermo.Active/wwwroot/src/app_modules_thermo/components/svgChart.ts +++ b/Thermo.Active/wwwroot/src/app_modules_thermo/components/svgChart.ts @@ -12,7 +12,7 @@ export default class SVGChart extends Vue { @Prop({ default: [] }) bars: svg.BarChartInfo[]; - @Prop({ default: [] }) + @Prop({ default: function () { return [] } }) lines: svg.LineChartInfo[] @Prop()