Do not show "os-volume-type-access:is_public" property of volume type
"os-volume-type-access:is_public" property is the same as "is_public" property in volume type object. So stop showing "os-volume-type-access:is_public" property and leave "is_public" property only. Change-Id: Ic78a9ee69b0ab356edff18cdb4c46fc24b495d2b Closes-Bug: #1620922
This commit is contained in:
		@@ -55,10 +55,9 @@ class CreateVolumeType(command.ShowOne):
 | 
			
		||||
        if parsed_args.property:
 | 
			
		||||
            result = volume_type.set_keys(parsed_args.property)
 | 
			
		||||
            volume_type._info.update({'properties': utils.format_dict(result)})
 | 
			
		||||
        volume_type._info.pop("os-volume-type-access:is_public", None)
 | 
			
		||||
 | 
			
		||||
        info = {}
 | 
			
		||||
        info.update(volume_type._info)
 | 
			
		||||
        return zip(*sorted(six.iteritems(info)))
 | 
			
		||||
        return zip(*sorted(six.iteritems(volume_type._info)))
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
class DeleteVolumeType(command.Command):
 | 
			
		||||
@@ -171,6 +170,7 @@ class ShowVolumeType(command.ShowOne):
 | 
			
		||||
            volume_client.volume_types, parsed_args.volume_type)
 | 
			
		||||
        properties = utils.format_dict(volume_type._info.pop('extra_specs'))
 | 
			
		||||
        volume_type._info.update({'properties': properties})
 | 
			
		||||
        volume_type._info.pop("os-volume-type-access:is_public", None)
 | 
			
		||||
        return zip(*sorted(six.iteritems(volume_type._info)))
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -110,6 +110,7 @@ class CreateVolumeType(command.ShowOne):
 | 
			
		||||
        if parsed_args.property:
 | 
			
		||||
            result = volume_type.set_keys(parsed_args.property)
 | 
			
		||||
            volume_type._info.update({'properties': utils.format_dict(result)})
 | 
			
		||||
        volume_type._info.pop("os-volume-type-access:is_public", None)
 | 
			
		||||
 | 
			
		||||
        return zip(*sorted(six.iteritems(volume_type._info)))
 | 
			
		||||
 | 
			
		||||
@@ -318,6 +319,7 @@ class ShowVolumeType(command.ShowOne):
 | 
			
		||||
                        '%(type)s: %(e)s')
 | 
			
		||||
                LOG.error(msg % {'type': volume_type.id, 'e': e})
 | 
			
		||||
        volume_type._info.update({'access_project_ids': access_project_ids})
 | 
			
		||||
        volume_type._info.pop("os-volume-type-access:is_public", None)
 | 
			
		||||
        return zip(*sorted(six.iteritems(volume_type._info)))
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										5
									
								
								releasenotes/notes/bug-1620922-7f27942dc00f7108.yaml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								releasenotes/notes/bug-1620922-7f27942dc00f7108.yaml
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,5 @@
 | 
			
		||||
---
 | 
			
		||||
fixes:
 | 
			
		||||
  - Do not show ``os-volume-type-access:is_public`` property which is the
 | 
			
		||||
    same as ``is_public`` property of volume type object.
 | 
			
		||||
    [Bug `1620922 <https://bugs.launchpad.net/python-openstackclient/+bug/1620922>`_]
 | 
			
		||||
		Reference in New Issue
	
	Block a user