Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/4497 #34

Merged
merged 3 commits into from
Jun 14, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
103 changes: 67 additions & 36 deletions html/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -425,28 +425,40 @@ <h3>{{ i18n.groups }}</h3>
<template v-slot:item="{ item, index }">
<tr>
<td>
<v-btn id="alertButton" v-if="ackEnabled && item['event.severity_label']" class="mx-2" icon x-small
@click="ack($event, item, index, !isFilterToggleEnabled('acknowledged'))"
:title="isFilterToggleEnabled('acknowledged') ? i18n.alertUndoAcknowledge : i18n.alertAcknowledge"
:color="item['event.severity_label'] + '_' + isFilterToggleEnabled('acknowledged') | colorSeverity">
<v-icon>fa-bell</v-icon>
</v-btn>
<v-btn id="escalateButton" v-if="escalateEnabled" class="mx-2" icon x-small
@click="ack($event, item, index, true, true)"
:title="isFilterToggleEnabled('escalated') || item['event.escalated'] == true ? i18n.alertEscalated : i18n.escalate"
:color="isFilterToggleEnabled('escalated') || item['event.escalated'] == true ? 'secondary' : 'primary'">
<v-icon>fa-exclamation-triangle</v-icon>
</v-btn>
<v-tooltip bottom v-if="ackEnabled && item['event.severity_label']">
<template v-slot:activator="{ on, attrs }">
<span v-bind="attrs" v-on="on">
<v-btn id="alertButton" v-if="ackEnabled && item['event.severity_label']" class="mx-2" icon x-small
@click="ack($event, item, index, !isFilterToggleEnabled('acknowledged'))"
:color="item['event.severity_label'] + '_' + isFilterToggleEnabled('acknowledged') | colorSeverity">
<v-icon>fa-bell</v-icon>
</v-btn>
</span>
</template>
<span>{{ isFilterToggleEnabled('acknowledged') ? i18n.alertUndoAcknowledge : i18n.alertAcknowledge }}</span>
</v-tooltip>
<v-tooltip bottom v-if="escalateEnabled">
<template v-slot:activator="{ on, attrs }">
<span v-bind="attrs" v-on="on">
<v-btn id="escalateButton" v-if="escalateEnabled" class="mx-2" icon x-small
@click="ack($event, item, index, true, true)"
:color="isFilterToggleEnabled('escalated') || item['event.escalated'] == true ? 'secondary' : 'primary'">
<v-icon>fa-exclamation-triangle</v-icon>
</v-btn>
</span>
</template>
<span>{{ isFilterToggleEnabled('escalated') || item['event.escalated'] == true ? i18n.alertEscalated : i18n.escalate }}</span>
</v-tooltip>
</td>
<td>
<v-tooltip bottom v-if="loaded && eventsEnabled && metricsEnabled && ( (groupByHeaders.length==3 && groupByHeaders[1]['value']=='count' ) || (groupByHeaders.length==5 && groupByHeaders[1]['value']=='count' && groupByHeaders[2]['value']=='rule.name' && groupByHeaders[3]['value']=='event.module' && groupByHeaders[4]['value']=='event.severity_label') ) ">
<template v-slot:activator="{ on, attrs }">
<span v-bind="attrs" v-on="on">
<div class="count-drilldown d-inline-block" v-text="item.count.toLocaleString()" v-bind="attrs" @click="countDrilldown(item)"></div>
</span>
</template>
<span>{{ i18n.quickDrilldown }}</span>
</v-tooltip>
<v-tooltip bottom v-if="loaded && eventsEnabled && metricsEnabled && ( (groupByHeaders.length==3 && groupByHeaders[1]['value']=='count' ) || (groupByHeaders.length==5 && groupByHeaders[1]['value']=='count' && groupByHeaders[2]['value']=='rule.name' && groupByHeaders[3]['value']=='event.module' && groupByHeaders[4]['value']=='event.severity_label') ) ">
<template v-slot:activator="{ on, attrs }">
<span v-bind="attrs" v-on="on">
<div class="count-drilldown d-inline-block" v-text="item.count.toLocaleString()" v-bind="attrs" @click="countDrilldown(item)"></div>
</span>
</template>
<span>{{ i18n.quickDrilldown }}</span>
</v-tooltip>
<div v-else class="count-drilldown d-inline-block" v-text="item.count.toLocaleString()"></div>
</td>
<td v-for="field in groupByHeaders.slice(2)" :key="field.value">
Expand Down Expand Up @@ -480,22 +492,41 @@ <h3>{{ i18n.events }}</h3>
<template v-slot:item="{ item, index }">
<tr>
<td>
<v-btn id="expandEvent" icon small @click="expand(item)">
<v-icon v-if="isExpanded(item)" :alt="i18n.eventExpand" :title="i18n.eventExpandHelp">fa-angle-down</v-icon>
<v-icon v-if="!isExpanded(item)" :alt="i18n.eventExpand" :title="i18n.eventExpandHelp">fa-angle-right</v-icon>
</v-btn>
<v-btn id="alertButton" v-if="ackEnabled && item['event.severity_label']" class="mx-2" icon x-small
@click="ack($event, item, index, !isFilterToggleEnabled('acknowledged'))"
:title="isFilterToggleEnabled('acknowledged') ? i18n.alertUndoAcknowledge : i18n.alertAcknowledge"
:color="item['event.severity_label'] + '_' + isFilterToggleEnabled('acknowledged') | colorSeverity">
<v-icon>fa-bell</v-icon>
</v-btn>
<v-btn id="escalateButton" v-if="escalateEnabled" class="mx-2" icon x-small
@click="ack($event, item, index, true, true)"
:title="isFilterToggleEnabled('escalated') || item['event.escalated'] == true ? i18n.alertEscalated : i18n.escalate"
:color="isFilterToggleEnabled('escalated') || item['event.escalated'] == true ? 'secondary' : 'primary'">
<v-icon>fa-exclamation-triangle</v-icon>
</v-btn>
<v-tooltip bottom>
<template v-slot:activator="{ on, attrs }">
<span v-bind="attrs" v-on="on">
<v-btn id="expandEvent" icon small @click="expand(item)">
<v-icon v-if="isExpanded(item)" :alt="i18n.eventExpand">fa-angle-down</v-icon>
<v-icon v-if="!isExpanded(item)" :alt="i18n.eventExpand">fa-angle-right</v-icon>
</v-btn>
</span>
</template>
<span>{{ i18n.eventExpandHelp }}</span>
</v-tooltip>
<v-tooltip bottom v-if="ackEnabled && item['event.severity_label']">
<template v-slot:activator="{ on, attrs }">
<span v-bind="attrs" v-on="on">
<v-btn id="alertButton" v-if="ackEnabled && item['event.severity_label']" class="mx-2" icon x-small
@click="ack($event, item, index, !isFilterToggleEnabled('acknowledged'))"
:color="item['event.severity_label'] + '_' + isFilterToggleEnabled('acknowledged') | colorSeverity">
<v-icon>fa-bell</v-icon>
</v-btn>
</span>
</template>
<span>{{ isFilterToggleEnabled('acknowledged') ? i18n.alertUndoAcknowledge : i18n.alertAcknowledge }}</span>
</v-tooltip>
<v-tooltip bottom v-if="escalateEnabled">
<template v-slot:activator="{ on, attrs }">
<span v-bind="attrs" v-on="on">
<v-btn id="escalateButton" v-if="escalateEnabled" class="mx-2" icon x-small
@click="ack($event, item, index, true, true)"
:color="isFilterToggleEnabled('escalated') || item['event.escalated'] == true ? 'secondary' : 'primary'">
<v-icon>fa-exclamation-triangle</v-icon>
</v-btn>
</span>
</template>
<span>{{ isFilterToggleEnabled('escalated') || item['event.escalated'] == true ? i18n.alertEscalated : i18n.escalate }}</span>
</v-tooltip>
</td>
<td v-for="field in eventHeaders" :key="field.value">
<div class="quick-action-trigger d-inline-block" v-text="item[field.value]" @click="toggleQuickAction($event, item, field.value, item[field.value])"></div>
Expand Down