diff --git a/lib/hammer_cli_foreman/smart_proxy.rb b/lib/hammer_cli_foreman/smart_proxy.rb index 675bee0e..cab75653 100644 --- a/lib/hammer_cli_foreman/smart_proxy.rb +++ b/lib/hammer_cli_foreman/smart_proxy.rb @@ -13,6 +13,7 @@ class ListCommand < HammerCLIForeman::ListCommand field :status, _("Status") field :url, _("URL") field :_features, _( "Features"), Fields::List, :hide_blank => true + field :unrecognized_features, _("Unrecognized features"), Fields::List, :hide_blank => true end def extend_data(proxy) @@ -31,10 +32,18 @@ class InfoCommand < HammerCLIForeman::InfoCommand field :name, _('Name') field :version, _('Version') end + collection :_unrecognized_features, _("Unrecognized features"), :hide_blank => true do + field :name, _('Name') + end HammerCLIForeman::References.taxonomies(self) HammerCLIForeman::References.timestamps(self) end + def extend_data(proxy) + proxy['_unrecognized_features'] = proxy.delete('unrecognized_features').map { |f| { 'name' => f } } if proxy['unrecognized_features'] + proxy + end + build_options end