mirror of
https://github.com/portainer/portainer.git
synced 2025-07-20 13:59:40 +02:00
fix(namespace): create ns qa feedback [EE-2226] (#10474)
This commit is contained in:
parent
bcb3f918d1
commit
07ec2ffe5e
11 changed files with 34 additions and 43 deletions
|
@ -1,12 +1,14 @@
|
|||
import { CreateNamespaceFormValues, CreateNamespacePayload } from './types';
|
||||
|
||||
export function transformFormValuesToNamespacePayload(
|
||||
createNamespaceFormValues: CreateNamespaceFormValues
|
||||
createNamespaceFormValues: CreateNamespaceFormValues,
|
||||
owner: string
|
||||
): CreateNamespacePayload {
|
||||
const memoryInBytes =
|
||||
Number(createNamespaceFormValues.resourceQuota.memory) * 10 ** 6;
|
||||
return {
|
||||
Name: createNamespaceFormValues.name,
|
||||
Owner: owner,
|
||||
ResourceQuota: {
|
||||
enabled: createNamespaceFormValues.resourceQuota.enabled,
|
||||
cpu: createNamespaceFormValues.resourceQuota.cpu,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue