Show Created At column for volume backups in v3

The change in [1] erroneously only added the
created_at column for volume v2 API and not
also for the volume v3 API.

[1] https://review.opendev.org/c/openstack/python-openstackclient/+/920003

Change-Id: Iae0b4f21cbc31ae7464a79c8f5e01446ca4ff098
This commit is contained in:
Tobias Urdin 2024-10-17 16:25:13 +02:00
parent 7c6b47b451
commit 695d025f00
3 changed files with 10 additions and 0 deletions

View File

@ -333,6 +333,7 @@ class TestBackupList(volume_fakes.TestVolume):
'Status', 'Status',
'Size', 'Size',
'Incremental', 'Incremental',
'Created At',
) )
columns_long = columns + ( columns_long = columns + (
'Availability Zone', 'Availability Zone',
@ -350,6 +351,7 @@ class TestBackupList(volume_fakes.TestVolume):
b.status, b.status,
b.size, b.size,
b.is_incremental, b.is_incremental,
b.created_at,
) )
) )
data_long = [] data_long = []
@ -362,6 +364,7 @@ class TestBackupList(volume_fakes.TestVolume):
b.status, b.status,
b.size, b.size,
b.is_incremental, b.is_incremental,
b.created_at,
b.availability_zone, b.availability_zone,
volume_backup.VolumeIdColumn(b.volume_id), volume_backup.VolumeIdColumn(b.volume_id),
b.container, b.container,

View File

@ -305,6 +305,7 @@ class ListVolumeBackup(command.Lister):
'status', 'status',
'size', 'size',
'is_incremental', 'is_incremental',
'created_at',
) )
column_headers = ( column_headers = (
'ID', 'ID',
@ -313,6 +314,7 @@ class ListVolumeBackup(command.Lister):
'Status', 'Status',
'Size', 'Size',
'Incremental', 'Incremental',
'Created At',
) )
if parsed_args.long: if parsed_args.long:
columns += ('availability_zone', 'volume_id', 'container') columns += ('availability_zone', 'volume_id', 'container')

View File

@ -0,0 +1,5 @@
---
features:
- |
Listing volume backups now shows the created_at column when
volume v3 API is used.