mirror of
https://github.com/umami-software/umami.git
synced 2026-02-10 07:37:11 +01:00
DataTable refactor.
This commit is contained in:
parent
92ccc64e47
commit
6846355c63
17 changed files with 94 additions and 114 deletions
|
|
@ -7,7 +7,7 @@ import { methodNotAllowed, ok, unauthorized } from 'next-basics';
|
|||
import { createWebsite } from 'queries';
|
||||
import userWebsites from 'pages/api/users/[id]/websites';
|
||||
import * as yup from 'yup';
|
||||
import { getFilterValidation } from 'lib/yup';
|
||||
import { pageInfo } from 'lib/schema';
|
||||
|
||||
export interface WebsitesRequestQuery extends SearchFilter<WebsiteSearchFilterType> {}
|
||||
|
||||
|
|
@ -19,7 +19,7 @@ export interface WebsitesRequestBody {
|
|||
|
||||
const schema = {
|
||||
GET: yup.object().shape({
|
||||
...getFilterValidation(/All|Name|Domain/i),
|
||||
...pageInfo,
|
||||
}),
|
||||
POST: yup.object().shape({
|
||||
name: yup.string().max(100).required(),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue