Skip to content

Commit 73f41d6

Browse files
shwstpprdhslove
authored andcommitted
ui: show multiple domains as links in list view (apache#11536)
* ui: show multiple domains as links in list view Currently, when resources are linked to multiple domains and they are shown in the list view, they are not clickable. This PR fixes it. Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com> * fix Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com> --------- Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
1 parent a90422a commit 73f41d6

1 file changed

Lines changed: 8 additions & 4 deletions

File tree

ui/src/components/view/ListView.vue

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -680,10 +680,14 @@
680680
/>
681681
</template>
682682
<template v-if="column.key === 'domain'">
683-
<router-link
684-
v-if="record.domainid && !record.domainid.toString().includes(',') && $store.getters.userInfo.roletype !== 'User'"
685-
:to="{ path: '/domain/' + record.domainid, query: { tab: 'details' } }"
686-
>{{ text }}</router-link>
683+
<span v-if="record.domainid && $store.getters.userInfo.roletype !== 'User'">
684+
<template v-for="(id, idx) in record.domainid.split(',')" :key="id">
685+
<router-link :to="{ path: '/domain/' + id, query: { tab: 'details' } }">
686+
{{ record.domain.split(',')[idx] || id }}
687+
</router-link>
688+
<span v-if="idx < record.domainid.split(',').length - 1">, </span>
689+
</template>
690+
</span>
687691
<span v-else>{{ text }}</span>
688692
</template>
689693
<template v-if="column.key === 'domainpath'">

0 commit comments

Comments
 (0)