mirror of
https://github.com/harvester/harvester-ui-extension.git
synced 2026-08-16 04:39:15 +00:00
refactor: rename pod network to management network (#992)
This commit is contained in:
parent
41cf44d231
commit
219f39ae52
@ -9,6 +9,7 @@ import { randomStr } from '@shell/utils/string';
|
|||||||
import { HCI } from '../../types';
|
import { HCI } from '../../types';
|
||||||
import { FORKLIFT_NAMESPACE } from '../../config/harvester-map';
|
import { FORKLIFT_NAMESPACE } from '../../config/harvester-map';
|
||||||
import { buildNetworkMapEntries, buildStorageMapEntries } from '../../utils/forklift';
|
import { buildNetworkMapEntries, buildStorageMapEntries } from '../../utils/forklift';
|
||||||
|
import { isInternalStorageClass } from '../../utils/storage-class';
|
||||||
import MappingColumn from './MappingColumn.vue';
|
import MappingColumn from './MappingColumn.vue';
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
@ -56,10 +57,22 @@ const harvesterNetworkOptions = computed(() => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
const storageClassOptions = computed(() => {
|
const storageClassOptions = computed(() => {
|
||||||
const options = storageClasses.value.map((sc) => ({
|
const options = storageClasses.value.filter((s) => !s.parameters?.backingImage).map((sc) => {
|
||||||
label: sc.metadata?.name || sc.id,
|
const value = sc.name;
|
||||||
value: sc.metadata?.name || sc.id,
|
let label = sc.isDefault ? `${ value } (${ t('generic.default') })` : value;
|
||||||
}));
|
let disabled = false;
|
||||||
|
|
||||||
|
if (isInternalStorageClass(value)) {
|
||||||
|
label += ` (${ t('harvester.storage.internal.label') })`;
|
||||||
|
disabled = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
label,
|
||||||
|
value,
|
||||||
|
disabled,
|
||||||
|
};
|
||||||
|
});
|
||||||
|
|
||||||
if (!options.find((o) => o.value === 'harvester-longhorn')) {
|
if (!options.find((o) => o.value === 'harvester-longhorn')) {
|
||||||
options.unshift({ label: 'harvester-longhorn', value: 'harvester-longhorn' });
|
options.unshift({ label: 'harvester-longhorn', value: 'harvester-longhorn' });
|
||||||
|
|||||||
@ -1967,7 +1967,7 @@ harvester:
|
|||||||
placeholder: Choose a Harvester network
|
placeholder: Choose a Harvester network
|
||||||
template: Use existing network mapping as template
|
template: Use existing network mapping as template
|
||||||
options:
|
options:
|
||||||
podNetworking: Pod Networking
|
podNetworking: Management Network
|
||||||
ignored: Ignored
|
ignored: Ignored
|
||||||
storageMapping:
|
storageMapping:
|
||||||
title: Storage Mapping
|
title: Storage Mapping
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user