Skip to content
Snippets Groups Projects

Issue #3264410: Add entity list views for OpenStack in SPA

All threads resolved!
All threads resolved!
Files
6
@@ -30,6 +30,11 @@ const K8S_LAUNCH_TEMPLATE_LIST: EntityColumn[] = [
const DEFAULT_K8S_LAUNCH_TEMPLATE: EntityColumn = { labelName: 'Cloud Service Provider ID', name: 'cloud_context', type: 'default' };
// Template for displaying the Launch template in OpenStack.
const OPENSTACK_LAUNCH_TEMPLATE_LIST: EntityColumn[] = [];
const DEFAULT_OPENSTACK_LAUNCH_TEMPLATE: EntityColumn = { labelName: 'Cloud Service Provider ID', name: 'cloud_context', type: 'default' };
/**
* Get LaunchTemplateColumnList by cloud_context.
*
@@ -52,8 +57,13 @@ const getLaunchTemplateColumnList = (cloudContext: CloudContext): EntityColumn[]
DEFAULT_K8S_LAUNCH_TEMPLATE,
...K8S_LAUNCH_TEMPLATE_LIST
];
default:
throw new Error('It is an unknown Cloud Context.');
case 'openstack':
return cloudContext.name !== 'ALL'
? OPENSTACK_LAUNCH_TEMPLATE_LIST
: [
DEFAULT_OPENSTACK_LAUNCH_TEMPLATE,
...OPENSTACK_LAUNCH_TEMPLATE_LIST
];
}
};
Loading