This is an automated email from the ASF dual-hosted git repository.
dahn pushed a commit to branch 4.19
in repository https://gitbox.apache.org/repos/asf/cloudstack.git
The following commit(s) were added to refs/heads/4.19 by this push:
new a09c579b5b2 UI: Fixes and minor enhacements to the Public IP Addresses
section (#10351)
a09c579b5b2 is described below
commit a09c579b5b2102ba67de0b0bd668bd4315991c50
Author: Bernardo De Marco Gonçalves <[email protected]>
AuthorDate: Wed Feb 26 05:44:29 2025 -0300
UI: Fixes and minor enhacements to the Public IP Addresses section (#10351)
---
ui/src/components/view/ListView.vue | 8 ++++++--
ui/src/config/section/network.js | 12 +++++++++---
2 files changed, 15 insertions(+), 5 deletions(-)
diff --git a/ui/src/components/view/ListView.vue
b/ui/src/components/view/ListView.vue
index 0c19ea8edab..8f4e58e93c7 100644
--- a/ui/src/components/view/ListView.vue
+++ b/ui/src/components/view/ListView.vue
@@ -149,6 +149,10 @@
<a-tag>static-nat</a-tag>
</span>
+ <span v-if="record.issystem">
+
+ <a-tag>system</a-tag>
+ </span>
</template>
<template v-if="column.key === 'ip6address'" href="javascript:;">
<span>{{ ipV6Address(text, record) }}</span>
@@ -378,8 +382,8 @@
<status :text="record.enabled ? record.enabled.toString() : 'false'" />
{{ record.enabled ? 'Enabled' : 'Disabled' }}
</template>
- <template v-if="['created', 'sent'].includes(column.key)">
- {{ $toLocaleDate(text) }}
+ <template v-if="['created', 'sent', 'allocated'].includes(column.key)">
+ {{ text && $toLocaleDate(text) }}
</template>
<template v-if="['startdate', 'enddate'].includes(column.key) && ['vm',
'vnfapp'].includes($route.path.split('/')[1])">
{{ getDateAtTimeZone(text, record.timezone) }}
diff --git a/ui/src/config/section/network.js b/ui/src/config/section/network.js
index 6691afa247d..6ea495ec604 100644
--- a/ui/src/config/section/network.js
+++ b/ui/src/config/section/network.js
@@ -840,10 +840,13 @@ export default {
message: 'message.action.release.ip',
docHelp:
'adminguide/networking_and_traffic.html#releasing-an-ip-address-alloted-to-a-vpc',
dataView: true,
- show: (record) => { return record.state === 'Allocated' &&
!record.issourcenat },
+ show: (record) => { return record.state === 'Allocated' &&
!record.issourcenat && !record.issystem },
groupAction: true,
popup: true,
- groupMap: (selection) => { return selection.map(x => { return { id:
x } }) }
+ groupMap: (selection) => { return selection.map(x => { return { id:
x } }) },
+ groupShow: (selectedIps) => {
+ return selectedIps.every((ip) => ip.state === 'Allocated' &&
!ip.issourcenat && !ip.issystem)
+ }
},
{
api: 'reserveIpAddress',
@@ -863,7 +866,10 @@ export default {
show: (record) => { return record.state === 'Reserved' },
groupAction: true,
popup: true,
- groupMap: (selection) => { return selection.map(x => { return { id:
x } }) }
+ groupMap: (selection) => { return selection.map(x => { return { id:
x } }) },
+ groupShow: (selectedIps) => {
+ return selectedIps.every((ip) => ip.state === 'Reserved')
+ }
}
]
},