Browse Source

fix: use the correct query builder

pull/6982/head
Pranav C 1 year ago
parent
commit
e37d64d8d2
  1. 2
      packages/nocodb/src/services/api-docs/swaggerV2/getPaths.ts
  2. 3
      packages/nocodb/src/services/api-docs/swaggerV2/getSwaggerJSONV2.ts
  3. 4
      packages/nocodb/src/services/api-docs/swaggerV2/templates/paths.ts

2
packages/nocodb/src/services/api-docs/swaggerV2/getPaths.ts

@ -1,5 +1,5 @@
import { getModelPaths } from './templates/paths'; import { getModelPaths } from './templates/paths';
import type { Base, Model } from '~/models'; import type { Model } from '~/models';
import type { SwaggerColumn } from './getSwaggerColumnMetas'; import type { SwaggerColumn } from './getSwaggerColumnMetas';
import type { SwaggerView } from './getSwaggerJSONV2'; import type { SwaggerView } from './getSwaggerJSONV2';
import Noco from '~/Noco'; import Noco from '~/Noco';

3
packages/nocodb/src/services/api-docs/swaggerV2/getSwaggerJSONV2.ts

@ -49,8 +49,7 @@ export default async function getSwaggerJSONV2(
} }
// skip mm tables // skip mm tables
if (!model.mm) if (!model.mm) paths = await getPaths({ model, columns, views }, ncMeta);
paths = await getPaths({ model, columns, views }, ncMeta);
const schemas = await getSchemas({ base, model, columns, views }, ncMeta); const schemas = await getSchemas({ base, model, columns, views }, ncMeta);

4
packages/nocodb/src/services/api-docs/swaggerV2/templates/paths.ts

@ -328,9 +328,7 @@ export const getModelPaths = async (ctx: {
}, },
description: description:
'This API endpoint allows you to link records to a specific `Link field` and `Record ID`. The request payload is an array of record-ids from the adjacent table for linking purposes. Note that any existing links, if present, will be unaffected during this operation.', 'This API endpoint allows you to link records to a specific `Link field` and `Record ID`. The request payload is an array of record-ids from the adjacent table for linking purposes. Note that any existing links, if present, will be unaffected during this operation.',
parameters: [ parameters: [recordIdParam],
recordIdParam,
],
}, },
delete: { delete: {
summary: 'Unlink Records', summary: 'Unlink Records',

Loading…
Cancel
Save