Renamed id routes for API.

This commit is contained in:
Mike Cao 2024-01-31 22:08:48 -08:00
parent 53a991176b
commit 4429198397
42 changed files with 154 additions and 170 deletions

View file

@ -9,9 +9,9 @@ import * as yup from 'yup';
export interface UsersRequestQuery extends SearchFilter {}
export interface UsersRequestBody {
userId: string;
username: string;
password: string;
id: string;
role: Role;
}
@ -20,9 +20,9 @@ const schema = {
...pageInfo,
}),
POST: yup.object().shape({
userId: yup.string().uuid(),
username: yup.string().max(255).required(),
password: yup.string().required(),
id: yup.string().uuid(),
role: yup
.string()
.matches(/admin|user|view-only/i)