Skip to content

Commit

Permalink
Clean up comments and unused code
Browse files Browse the repository at this point in the history
  • Loading branch information
jtomasek committed Jul 7, 2023
1 parent 9825b8a commit 81ac694
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 156 deletions.
4 changes: 2 additions & 2 deletions pkg/kubevirt/components/console/SerialConsole.vue
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ export default {
</script>
<template>
<div class="harvester-shell-container">
<div class="console-shell-container">
<div ref="xterm" class="shell-body" />
<resize-observer @notify="fit" />
</div>
Expand All @@ -260,7 +260,7 @@ MAIN {
height: 100%;
}
.harvester-shell-container {
.console-shell-container {
height: 100%;
overflow: hidden;
Expand Down
50 changes: 0 additions & 50 deletions pkg/kubevirt/formatters/NodeName.vue

This file was deleted.

105 changes: 1 addition & 104 deletions pkg/kubevirt/product.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { IPlugin } from '@shell/core/types';
// import { STATE, NAME, NAMESPACE, AGE, STATUS } from '@shell/config/table-headers';
import {
KUBEVIRT_RESOURCE_NAME,
PRODUCT_NAME,
Expand All @@ -8,115 +7,13 @@ import {
} from './constants';

export function init(plugin: IPlugin, store: any) {
const { basicType, product, mapGroup } = plugin.DSL(store, PRODUCT_NAME);
const { basicType, product } = plugin.DSL(store, PRODUCT_NAME);

// top level product
// product({
// icon: 'gear',
// inStore: 'management',
// weight: 100,
// });

// cluster level product
product({
inStore: 'cluster',
showNamespaceFilter: true,
ifHaveType: KUBEVIRT_RESOURCE_NAME,
});

// basicType([KUBEVIRT_RESOURCE_NAME, VM_RESOURCE_NAME, VMI_RESOURCE_NAME], 'workload');
basicType([KUBEVIRT_RESOURCE_NAME, VM_RESOURCE_NAME, VMI_RESOURCE_NAME]);

// configureType(KUBEVIRT_RESOURCE_NAME, {
// displayName: 'Virtual Machines',
// isCreatable: true,
// isRemovable: true,
// showAge: true,
// showState: true,
// canYaml: true,
// customRoute: {
// name: `${YOUR_PRODUCT_NAME}-c-cluster-resource`,
// params: {
// product: YOUR_PRODUCT_NAME,
// cluster: BLANK_CLUSTER,
// resource: YOUR_K8S_RESOURCE_NAME,
// },
// },
// });

// const UI_PLUGIN = 'catalog.cattle.io.uiplugin';

// mapGroup('workload', 'Workloads'); // the label should be translated
mapGroup('kubevirt', 'Virtual Machines');

// headers(VM_RESOURCE_NAME, [
// STATE,
// {
// ...NAME,
// width: 300,
// },
// NAMESPACE,
// {
// name: 'CPU',
// label: 'CPU',
// sort: ['spec.template.spec.domain.cpu.cores'],
// value: 'spec.template.spec.domain.cpu.cores',
// align: 'center',
// dashIfEmpty: true,
// },
// {
// name: 'Memory',
// value: 'displayMemory',
// sort: ['memorySort'],
// align: 'center',
// labelKey: 'tableHeaders.memory',
// formatter: 'Si',
// formatterOpts: {
// opts: {
// increment: 1024,
// addSuffix: true,
// maxExponent: 3,
// minExponent: 3,
// suffix: 'i',
// },
// needParseSi: true,
// },
// },
// {
// name: 'ip',
// label: 'IP Address',
// value: 'id',
// formatter: 'HarvesterIpAddress',
// labelKey: 'tableHeaders.ipAddress',
// },
// {
// name: 'node',
// label: 'Node',
// value: 'id',
// sort: ['realAttachNodeName'],
// formatter: 'NodeName',
// labelKey: 'tableHeaders.node',
// },
// {
// ...AGE,
// sort: 'metadata.creationTimestamp:desc',
// },
// STATE,
// NAME,
// NAMESPACE,
// STATUS,
// // READY,
// {
// name: 'run-strategy',
// label: 'Run strategy',
// value: 'runStrategyLabel',
// sort: ['runStrategyLabel'],
// getValue: (row: VirtualMachine) => {
// console.log('row', row);
// // return row.runStrategyLabel;
// return row.isPaused;
// },
// },
// AGE,
// ]);
}

0 comments on commit 81ac694

Please sign in to comment.