From f480b3b0dc69885233aa52b3a3da0c3379f4aa74 Mon Sep 17 00:00:00 2001 From: Wing-Kam Wong Date: Sat, 4 Mar 2023 00:23:01 +0800 Subject: [PATCH] feat(nocodb): add getAjvValidatorMw on view update --- packages/nocodb/src/lib/meta/api/viewApis.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/nocodb/src/lib/meta/api/viewApis.ts b/packages/nocodb/src/lib/meta/api/viewApis.ts index b062a2b2ef..73c72546a3 100644 --- a/packages/nocodb/src/lib/meta/api/viewApis.ts +++ b/packages/nocodb/src/lib/meta/api/viewApis.ts @@ -14,6 +14,7 @@ import View from '../../models/View'; import ncMetaAclMw from '../helpers/ncMetaAclMw'; import { xcVisibilityMetaGet } from './modelVisibilityApis'; import { metaApiMetrics } from '../helpers/apiMetrics'; +import { getAjvValidatorMw } from './helpers'; // @ts-ignore export async function viewGet(req: Request, res: Response) {} @@ -109,6 +110,7 @@ router.get( ); router.patch( '/api/v1/db/meta/views/:viewId', + getAjvValidatorMw('swagger.json#/components/schemas/ViewReq'), metaApiMetrics, ncMetaAclMw(viewUpdate, 'viewUpdate') );