summaryrefslogtreecommitdiff
path: root/app/assets/javascripts/alert_management
diff options
context:
space:
mode:
Diffstat (limited to 'app/assets/javascripts/alert_management')
-rw-r--r--app/assets/javascripts/alert_management/components/alert_management_table.vue20
1 files changed, 15 insertions, 5 deletions
diff --git a/app/assets/javascripts/alert_management/components/alert_management_table.vue b/app/assets/javascripts/alert_management/components/alert_management_table.vue
index dd702c4a5d3..79a6bac3ba7 100644
--- a/app/assets/javascripts/alert_management/components/alert_management_table.vue
+++ b/app/assets/javascripts/alert_management/components/alert_management_table.vue
@@ -42,6 +42,7 @@ export default {
"AlertManagement|There was an error displaying the alerts. Confirm your endpoint's configuration details to ensure alerts appear.",
),
unassigned: __('Unassigned'),
+ closed: __('closed'),
},
fields: [
{
@@ -75,7 +76,7 @@ export default {
{
key: 'issue',
label: s__('AlertManagement|Incident'),
- thClass: 'gl-w-12 gl-pointer-events-none',
+ thClass: 'gl-w-15p gl-pointer-events-none',
tdClass,
},
{
@@ -221,8 +222,11 @@ export default {
hasAssignees(assignees) {
return Boolean(assignees.nodes?.length);
},
- getIssueLink(item) {
- return joinPaths('/', this.projectPath, '-', 'issues', item.issueIid);
+ getIssueMeta({ issue: { iid, state } }) {
+ return {
+ state: state === 'closed' ? `(${this.$options.i18n.closed})` : '',
+ link: joinPaths('/', this.projectPath, '-', 'issues/incident', iid),
+ };
},
tbodyTrClass(item) {
return {
@@ -343,8 +347,14 @@ export default {
</template>
<template #cell(issue)="{ item }">
- <gl-link v-if="item.issueIid" data-testid="issueField" :href="getIssueLink(item)">
- #{{ item.issueIid }}
+ <gl-link
+ v-if="item.issue"
+ v-gl-tooltip
+ :title="item.issue.title"
+ data-testid="issueField"
+ :href="getIssueMeta(item).link"
+ >
+ #{{ item.issue.iid }} {{ getIssueMeta(item).state }}
</gl-link>
<div v-else data-testid="issueField">{{ s__('AlertManagement|None') }}</div>
</template>