Commit 18e3dcc6 authored by Fatih Acet's avatar Fatih Acet

Merge branch 'alerts-dropdown-to-modal-ce' into 'master'

Alerts dropdown to modal - CE1

See merge request gitlab-org/gitlab-ce!31036
parents 7395831d d770171d
...@@ -369,7 +369,7 @@ export default { ...@@ -369,7 +369,7 @@ export default {
</div> </div>
<div v-if="!showEmptyState"> <div v-if="!showEmptyState">
<graph-group <graph-group
v-for="groupData in groups" v-for="(groupData, index) in groups"
:key="`${groupData.group}.${groupData.priority}`" :key="`${groupData.group}.${groupData.priority}`"
:name="groupData.group" :name="groupData.group"
:show-panels="showPanels" :show-panels="showPanels"
...@@ -381,6 +381,7 @@ export default { ...@@ -381,6 +381,7 @@ export default {
:key="`panel-type-${graphIndex}`" :key="`panel-type-${graphIndex}`"
:graph-data="graphData" :graph-data="graphData"
:dashboard-width="elWidth" :dashboard-width="elWidth"
:index="`${index}-${graphIndex}`"
/> />
</template> </template>
<template v-else> <template v-else>
...@@ -399,6 +400,7 @@ export default { ...@@ -399,6 +400,7 @@ export default {
:alerts-endpoint="alertsEndpoint" :alerts-endpoint="alertsEndpoint"
:relevant-queries="graphData.queries" :relevant-queries="graphData.queries"
:alerts-to-manage="getGraphAlerts(graphData.queries)" :alerts-to-manage="getGraphAlerts(graphData.queries)"
:modal-id="`alert-modal-${index}-${graphIndex}`"
@setAlerts="setAlerts" @setAlerts="setAlerts"
/> />
</monitor-area-chart> </monitor-area-chart>
......
...@@ -20,6 +20,11 @@ export default { ...@@ -20,6 +20,11 @@ export default {
type: Number, type: Number,
required: true, required: true,
}, },
index: {
type: String,
required: false,
default: '',
},
}, },
computed: { computed: {
...mapState('monitoringDashboard', ['deploymentData', 'projectPath']), ...mapState('monitoringDashboard', ['deploymentData', 'projectPath']),
...@@ -64,6 +69,7 @@ export default { ...@@ -64,6 +69,7 @@ export default {
:alerts-endpoint="alertsEndpoint" :alerts-endpoint="alertsEndpoint"
:relevant-queries="graphData.queries" :relevant-queries="graphData.queries"
:alerts-to-manage="getGraphAlerts(graphData.queries)" :alerts-to-manage="getGraphAlerts(graphData.queries)"
:modal-id="`alert-modal-${index}`"
@setAlerts="setAlerts" @setAlerts="setAlerts"
/> />
</monitor-area-chart> </monitor-area-chart>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment