Show Created At column for backups table

The backups tables does not show the created_at
field today and to find the one you need by
date you need to open all backup to figure out
what date you want, this is not optimal since
the whole point of backups is to jump back to
a date as quick as possible.

Change-Id: Ie68e54d41b0ad919ecc468e162b4939eac3ae4b3
This commit is contained in:
Tobias Urdin 2024-04-26 21:03:38 +02:00
parent dbdd376462
commit 0ffd5c7ae1
2 changed files with 4 additions and 1 deletions

View File

@ -117,6 +117,7 @@ class AdminBackupsTable(project_tables.BackupsTable):
snapshot = AdminSnapshotColumn("snapshot", snapshot = AdminSnapshotColumn("snapshot",
verbose_name=_("Snapshot"), verbose_name=_("Snapshot"),
link="horizon:admin:snapshots:detail") link="horizon:admin:snapshots:detail")
created_at = tables.Column("created_at", verbose_name=_("Created At"))
class Meta(object): class Meta(object):
name = "volume_backups" name = "volume_backups"
@ -128,4 +129,5 @@ class AdminBackupsTable(project_tables.BackupsTable):
row_actions = (AdminRestoreBackup, ForceDeleteBackup, row_actions = (AdminRestoreBackup, ForceDeleteBackup,
AdminDeleteBackup, UpdateVolumeBackupStatusAction,) AdminDeleteBackup, UpdateVolumeBackupStatusAction,)
columns = ('project', 'name', 'description', 'size', 'status', columns = ('project', 'name', 'description', 'size', 'status',
'availability_zone', 'volume_name', 'snapshot',) 'availability_zone', 'volume_name', 'snapshot',
'created_at')

View File

@ -189,6 +189,7 @@ class BackupsTable(tables.DataTable):
snapshot = SnapshotColumn("snapshot", snapshot = SnapshotColumn("snapshot",
verbose_name=_("Snapshot"), verbose_name=_("Snapshot"),
link="horizon:project:snapshots:detail") link="horizon:project:snapshots:detail")
created_at = tables.Column("created_at", verbose_name=_("Created At"))
def current_page(self): def current_page(self):
return self._meta.current_page() return self._meta.current_page()