[fix] missing visible -> visibleIf

This commit is contained in:
ljf 2021-09-06 17:22:07 +02:00
parent 575ece31ab
commit 7fdceaf5bb

View file

@ -20,7 +20,7 @@
</template> </template>
<template v-for="section in sections"> <template v-for="section in sections">
<div :key="section.id" class="mb-5" v-if="isVisible(section.visibleIf)"> <div :key="section.id" class="mb-5" v-if="isVisible(section.visible)">
<b-card-title v-if="section.name" title-tag="h3"> <b-card-title v-if="section.name" title-tag="h3">
{{ section.name }} <small v-if="section.help">{{ section.help }}</small> {{ section.name }} <small v-if="section.help">{{ section.help }}</small>
</b-card-title> </b-card-title>
@ -89,7 +89,11 @@ export default {
context[shortname] = args[shortname] context[shortname] = args[shortname]
} }
} }
try {
return evaluate(context, expression) return evaluate(context, expression)
} catch (error) {
return false
}
}, },
onQueriesResponse (data) { onQueriesResponse (data) {
if (!data.panels || data.panels.length === 0) { if (!data.panels || data.panels.length === 0) {