mirror of
https://github.com/portainer/portainer.git
synced 2025-07-20 05:49:40 +02:00
refactor(containers): migrate create view to react [EE-2307] (#9175)
This commit is contained in:
parent
bc0050a7b4
commit
d970f0e2bc
71 changed files with 2612 additions and 1399 deletions
|
@ -2,10 +2,10 @@ import { bool, number, object, SchemaOf, string } from 'yup';
|
|||
|
||||
import { Values } from './types';
|
||||
|
||||
export function validation(): SchemaOf<Values> {
|
||||
export function validation(rateLimitExceeded: boolean): SchemaOf<Values> {
|
||||
return object({
|
||||
image: string().required('Image is required'),
|
||||
registryId: number().default(0),
|
||||
useRegistry: bool().default(false),
|
||||
});
|
||||
}).test('rate-limits', 'Rate limit exceeded', () => !rateLimitExceeded);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue