Browse Source

refactor: use a generic boolean type which could be number, null or boolean

- In databases boolean is stored as 0/1 so all boolean field could be number as well

Signed-off-by: Pranav C <pranavxc@gmail.com>
pull/5174/head
Pranav C 2 years ago
parent
commit
b54d2d22a4
  1. 159
      packages/nocodb-sdk/src/lib/Api.ts
  2. 3
      packages/nocodb/src/lib/meta/api/formViewColumnApis.ts
  3. 2
      packages/nocodb/src/lib/meta/api/gridViewColumnApis.ts
  4. 6
      packages/nocodb/src/lib/meta/api/helpers/columnHelpers.ts
  5. 6
      packages/nocodb/src/lib/models/Base.ts
  6. 3
      packages/nocodb/src/lib/models/LinkToAnotherRecordColumn.ts
  7. 15
      packages/nocodb/src/lib/models/Model.ts
  8. 4
      packages/nocodb/src/lib/models/Project.ts
  9. 265
      scripts/sdk/swagger.json

159
packages/nocodb-sdk/src/lib/Api.ts

@ -58,10 +58,10 @@ export interface ProjectType {
description?: string;
meta?: string | object;
color?: string;
deleted?: string | boolean;
deleted?: NcBoolType;
order?: number;
bases?: BaseType[];
is_meta?: boolean;
is_meta?: NcBoolType;
prefix?: string;
created_at?: any;
updated_at?: any;
@ -78,14 +78,14 @@ export interface BaseType {
project_id?: string;
alias?: string;
type?: string;
is_meta?: boolean;
is_meta?: NcBoolType;
config?: any;
created_at?: any;
updated_at?: any;
inflection_column?: string;
inflection_table?: string;
order?: number;
enabled?: boolean;
enabled?: NcBoolType;
}
export interface BaseReqType {
@ -113,30 +113,30 @@ export interface TableType {
table_name: string;
title: string;
type?: string;
enabled?: boolean;
enabled?: NcBoolType;
parent_id?: string;
show_as?: string;
tags?: string;
pinned?: boolean;
deleted?: boolean;
pinned?: NcBoolType;
deleted?: NcBoolType;
order?: number;
columns?: ColumnType[];
columnsById?: object;
slug?: string;
mm?: boolean | number;
mm?: NcBoolType;
meta?: any;
}
export interface ViewType {
id?: string;
title: string;
deleted?: boolean;
deleted?: NcBoolType;
order?: number;
fk_model_id?: string;
slug?: string;
uuid?: string;
meta?: any;
show_system_fields?: boolean;
show_system_fields?: NcBoolType;
lock_type?: 'collaborative' | 'locked' | 'personal';
type?: number;
view?:
@ -159,8 +159,8 @@ export interface TableInfoType {
parent_id?: string;
show_as?: string;
tags?: string;
pinned?: boolean;
deleted?: boolean;
pinned?: NcBoolType;
deleted?: NcBoolType;
order?: number;
column?: ColumnType[];
filters?: FilterType[];
@ -178,10 +178,10 @@ export interface TableReqType {
parent_id?: string;
show_as?: string;
tags?: string;
pinned?: boolean;
deleted?: boolean;
pinned?: NcBoolType;
deleted?: NcBoolType;
order?: number;
mm?: boolean;
mm?: NcBoolType;
columns: NormalColumnRequestType[];
meta?: any;
}
@ -197,7 +197,7 @@ export interface FilterType {
fk_column_id?: string;
logical_op?: string;
comparison_op?: string;
value?: string | number | boolean | null;
value?: any;
is_group?: boolean | number | null;
children?: FilterType[];
project_id?: string;
@ -213,7 +213,7 @@ export interface FilterReqType {
fk_column_id?: string;
logical_op?: string;
comparison_op?: string;
value?: string | number | boolean | null;
value?: any;
is_group?: boolean | number | null;
children?: FilterType[];
project_id?: string;
@ -261,25 +261,25 @@ export interface ColumnType {
ns?: string | number | null;
clen?: string | number | null;
cop?: string;
pk?: boolean;
pv?: boolean;
rqd?: boolean | number | null;
pk?: NcBoolType;
pv?: NcBoolType;
rqd?: NcBoolType;
column_name?: string;
un?: boolean | number | null;
un?: NcBoolType;
ct?: string;
ai?: boolean;
unique?: boolean;
ai?: NcBoolType;
unique?: NcBoolType;
cdf?: string;
cc?: string;
csn?: string;
dtx?: string;
dtxp?: string | number | null;
dtxs?: string | number | null;
au?: boolean;
deleted?: boolean;
visible?: boolean;
au?: NcBoolType;
deleted?: NcBoolType;
visible?: NcBoolType;
order?: number;
system?: number | boolean;
system?: NcBoolType;
meta?: any;
colOptions?:
| LinkToAnotherRecordType
@ -305,7 +305,7 @@ export interface ColumnListType {
export interface LinkToAnotherRecordType {
id?: string;
type?: string;
virtual?: boolean;
virtual?: NcBoolType;
fk_column_id?: string;
fk_child_column_id?: string;
fk_parent_column_id?: string;
@ -323,7 +323,7 @@ export interface LinkToAnotherRecordType {
export interface LookupType {
id?: string;
type?: string;
virtual?: boolean;
virtual?: NcBoolType;
fk_column_id?: string;
fk_relation_column_id?: string;
fk_lookup_column_id?: string;
@ -334,7 +334,7 @@ export interface LookupType {
export interface RollupType {
id?: string;
type?: string;
virtual?: boolean;
virtual?: NcBoolType;
fk_column_id?: string;
fk_relation_column_id?: string;
fk_rollup_column_id?: string;
@ -346,7 +346,7 @@ export interface RollupType {
export interface FormulaType {
id?: string;
type?: string;
virtual?: boolean;
virtual?: NcBoolType;
fk_column_id?: string;
formula?: string;
formula_raw?: string;
@ -370,7 +370,7 @@ export interface GridType {
id?: string;
title?: string;
alias?: string;
deleted?: boolean;
deleted?: NcBoolType;
order?: number;
lock_type?: 'collaborative' | 'locked' | 'personal';
row_height?: number;
@ -387,10 +387,10 @@ export interface GalleryType {
fk_view_id?: string;
title?: string;
alias?: string;
deleted?: boolean;
deleted?: NcBoolType;
order?: number;
next_enabled?: boolean;
prev_enabled?: boolean;
next_enabled?: NcBoolType;
prev_enabled?: NcBoolType;
cover_image_idx?: number;
cover_image?: string;
restrict_types?: string;
@ -404,8 +404,8 @@ export interface GalleryType {
export interface GalleryReqType {
title: string;
next_enabled?: boolean;
prev_enabled?: boolean;
next_enabled?: NcBoolType;
prev_enabled?: NcBoolType;
cover_image_idx?: number;
cover_image?: string;
restrict_types?: string;
@ -423,6 +423,14 @@ export interface GalleryColumnType {
fk_gallery_id?: string;
}
export interface GridColumnReqType {
label?: string;
help?: string;
fk_column_id?: string;
fk_gallery_id?: string;
width?: string;
}
export interface GridColumnType {
id?: string;
label?: string;
@ -502,8 +510,8 @@ export interface FormType {
email?: string;
banner_image_url?: string;
logo_url?: string;
submit_another_form?: boolean;
show_blank_form?: boolean;
submit_another_form?: NcBoolType;
show_blank_form?: NcBoolType;
columns?: FormColumnType[];
fk_model_id?: string;
lock_type?: 'collaborative' | 'locked' | 'personal';
@ -520,8 +528,8 @@ export interface FormReqType {
email?: string;
banner_image_url?: string;
logo_url?: string;
submit_another_form?: boolean;
show_blank_form?: boolean;
submit_another_form?: NcBoolType;
show_blank_form?: NcBoolType;
fk_model_id?: string;
lock_type?: 'collaborative' | 'locked' | 'personal';
meta?: any;
@ -534,8 +542,8 @@ export interface FormColumnType {
uuid?: any;
label?: string;
help?: any;
required?: boolean;
show?: boolean;
required?: NcBoolType;
show?: NcBoolType;
order?: number;
created_at?: string;
updated_at?: string;
@ -543,6 +551,17 @@ export interface FormColumnType {
meta?: any;
}
export interface FormColumnReqType {
uuid?: any;
label?: string;
help?: any;
required?: NcBoolType;
show?: NcBoolType;
order?: number;
description?: string;
meta?: any;
}
export interface PaginatedType {
pageSize?: number;
totalRows?: number;
@ -614,16 +633,12 @@ export interface HookType {
type?: string;
event?: 'after' | 'before';
operation?: 'insert' | 'delete' | 'update';
async?: boolean;
payload?: any;
url?: string;
headers?: string;
condition?: boolean;
async?: NcBoolType;
notification?: string;
retries?: number;
retry_interval?: number;
timeout?: number;
active?: boolean;
active?: NcBoolType;
}
export interface HookReqType {
@ -635,15 +650,11 @@ export interface HookReqType {
event: 'after' | 'before';
operation: 'insert' | 'delete' | 'update';
async?: string | number | null;
payload?: any;
url?: string | null;
headers?: string | null;
condition?: boolean | null;
notification: object;
retries?: number;
retry_interval?: number;
timeout?: number;
active?: boolean;
active?: NcBoolType;
}
export interface HookTestReqType {
@ -682,7 +693,7 @@ export interface PluginType {
id?: string;
title?: string;
description?: string;
active?: boolean;
active?: NcBoolType;
rating?: number;
version?: string;
docs?: string;
@ -706,7 +717,7 @@ export interface ModelRoleVisibilityType {
fk_model_id?: string;
fk_view_id?: string;
role?: string;
disabled?: boolean;
disabled?: NcBoolType;
}
export interface ApiTokenType {
@ -726,7 +737,7 @@ export interface HookLogType {
type?: string;
event?: string;
operation?: string;
test_call?: boolean;
test_call?: NcBoolType;
payload?: any;
conditions?: string;
notifications?: string;
@ -780,27 +791,27 @@ export interface NormalColumnRequestType {
dt?: string;
np?: string | number | null;
ns?: string | number | null;
pk?: boolean;
pv?: boolean;
rqd?: number | null | boolean;
pk?: NcBoolType;
pv?: NcBoolType;
rqd?: number | null | NcBoolType;
column_name?: string;
un?: boolean | number | null;
un?: NcBoolType;
ct?: string;
ai?: boolean;
unique?: boolean;
ai?: NcBoolType;
unique?: NcBoolType;
cdf?: string | null;
cc?: string;
csn?: string;
dtx?: string;
dtxp?: string | number | null;
dtxs?: string | number | null;
au?: boolean;
au?: NcBoolType;
}
export interface LinkToAnotherColumnReqType {
uidt: 'LinkToAnotherRecord';
title: string;
virtual?: boolean;
virtual?: NcBoolType;
parentId: string;
childId: string;
type: 'hm' | 'bt' | 'mm';
@ -859,15 +870,17 @@ export interface UserInfoType {
export type VisibilityRuleReqType = {
disabled?: {
commenter?: boolean;
creator?: boolean;
editor?: boolean;
guest?: boolean;
owner?: boolean;
viewer?: boolean;
commenter?: NcBoolType;
creator?: NcBoolType;
editor?: NcBoolType;
guest?: NcBoolType;
owner?: NcBoolType;
viewer?: NcBoolType;
};
}[];
export type NcBoolType = boolean | number | null;
import axios, { AxiosInstance, AxiosRequestConfig, ResponseType } from 'axios';
export type QueryParamsType = Record<string | number, any>;
@ -2661,7 +2674,7 @@ export class Api<
*/
formColumnUpdate: (
formViewColumnId: string,
data: FormColumnType,
data: FormColumnReqType,
params: RequestParams = {}
) =>
this.request<any, any>({
@ -2717,7 +2730,7 @@ export class Api<
*/
gridColumnUpdate: (
columnId: string,
data: GridColumnType,
data: GridColumnReqType,
params: RequestParams = {}
) =>
this.request<any, any>({

3
packages/nocodb/src/lib/meta/api/formViewColumnApis.ts

@ -3,6 +3,7 @@ import FormViewColumn from '../../models/FormViewColumn';
import { Tele } from 'nc-help';
import ncMetaAclMw from '../helpers/ncMetaAclMw';
import { metaApiMetrics } from '../helpers/apiMetrics';
import { getAjvValidatorMw } from './helpers'
// import { getAjvValidatorMw } from './helpers'
export async function columnUpdate(req: Request, res: Response) {
@ -14,7 +15,7 @@ const router = Router({ mergeParams: true });
router.patch(
'/api/v1/db/meta/form-columns/:formViewColumnId',
metaApiMetrics,
// getAjvValidatorMw('swagger.json#/components/schemas/FormViewColumnReq'),
getAjvValidatorMw('swagger.json#/components/schemas/FormViewColumnReq'),
ncMetaAclMw(columnUpdate, 'columnUpdate')
);
export default router;

2
packages/nocodb/src/lib/meta/api/gridViewColumnApis.ts

@ -23,7 +23,7 @@ router.get(
router.patch(
'/api/v1/db/meta/grid-columns/:gridViewColumnId',
metaApiMetrics,
getAjvValidatorMw('swagger.json#/components/schemas/GridViewColumnReq'),
getAjvValidatorMw('swagger.json#/components/schemas/GridColumnReq'),
ncMetaAclMw(gridColumnUpdate, 'gridColumnUpdate')
);
export default router;

6
packages/nocodb/src/lib/meta/api/helpers/columnHelpers.ts

@ -2,12 +2,12 @@ import { customAlphabet } from 'nanoid';
import {
ColumnReqType,
LinkToAnotherRecordType,
LookupColumnReqType,
LookupColumnReqType, NcBoolType,
RelationTypes,
RollupColumnReqType,
TableType,
UITypes,
} from 'nocodb-sdk';
} from 'nocodb-sdk'
import Column from '../../../models/Column';
import LinkToAnotherRecordColumn from '../../../models/LinkToAnotherRecordColumn';
import LookupColumn from '../../../models/LookupColumn';
@ -27,7 +27,7 @@ export async function createHmAndBtColumn(
type?: RelationTypes,
alias?: string,
fkColName?: string,
virtual = false,
virtual: NcBoolType = false,
isSystemCol = false
) {
// save bt column

6
packages/nocodb/src/lib/models/Base.ts

@ -7,7 +7,7 @@ import {
MetaTable,
} from '../utils/globals';
import Model from './Model';
import { BaseType, UITypes } from 'nocodb-sdk';
import { BaseType, NcBoolType, UITypes } from 'nocodb-sdk'
import NocoCache from '../cache/NocoCache';
import CryptoJS from 'crypto-js';
import { extractProps } from '../meta/helpers/extractProps';
@ -20,14 +20,14 @@ export default class Base implements BaseType {
project_id?: string;
alias?: string;
type?: string;
is_meta?: boolean;
is_meta?: NcBoolType;
config?: any;
created_at?: any;
updated_at?: any;
inflection_column?: string;
inflection_table?: string;
order?: number;
enabled?: boolean;
enabled?: NcBoolType;
constructor(base: Partial<Base>) {
Object.assign(this, base);

3
packages/nocodb/src/lib/models/LinkToAnotherRecordColumn.ts

@ -1,3 +1,4 @@
import { NcBoolType } from 'nocodb-sdk'
import Noco from '../Noco';
import Column from './Column';
import Model from './Model';
@ -19,7 +20,7 @@ export default class LinkToAnotherRecordColumn {
fk_index_name?: string;
type: 'hm' | 'bt' | 'mm';
virtual = false;
virtual: NcBoolType = false;
mmModel?: Model;
relatedTable?: Model;

15
packages/nocodb/src/lib/models/Model.ts

@ -7,6 +7,7 @@ import { BaseModelSqlv2 } from '../db/sql-data-mapper/lib/sql/BaseModelSqlv2';
import {
isVirtualCol,
ModelTypes,
NcBoolType,
TableReqType,
TableType,
UITypes,
@ -25,17 +26,17 @@ import { sanitize } from '../db/sql-data-mapper/lib/sql/helpers/sanitize';
import { extractProps } from '../meta/helpers/extractProps';
export default class Model implements TableType {
copy_enabled: boolean;
copy_enabled: NcBoolType;
created_at: Date | number | string;
base_id: 'db' | string;
deleted: boolean;
enabled: boolean;
export_enabled: boolean;
deleted: NcBoolType;
enabled: NcBoolType;
export_enabled: NcBoolType;
id: string;
order: number;
parent_id: string;
password: string;
pin: boolean;
pin: NcBoolType;
project_id: string;
schema: any;
show_all_fields: boolean;
@ -46,7 +47,7 @@ export default class Model implements TableType {
table_name: string;
title: string;
mm: boolean;
mm: NcBoolType;
uuid: string;
@ -98,7 +99,7 @@ export default class Model implements TableType {
projectId,
baseId,
model: Partial<TableReqType> & {
mm?: boolean;
mm?: NcBoolType;
created_at?: any;
updated_at?: any;
},

4
packages/nocodb/src/lib/models/Project.ts

@ -1,6 +1,6 @@
import Base from './/Base';
import Noco from '../Noco';
import { ProjectType } from 'nocodb-sdk';
import { NcBoolType, ProjectType } from 'nocodb-sdk'
import {
CacheDelDirection,
CacheGetType,
@ -18,7 +18,7 @@ export default class Project implements ProjectType {
public description: string;
public meta: string;
public color: string;
public deleted: string;
public deleted: NcBoolType;
public order: number;
public is_meta = false;
public bases?: Base[];

265
scripts/sdk/swagger.json

@ -2984,7 +2984,7 @@
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/FormColumn"
"$ref": "#/components/schemas/FormColumnReq"
}
}
}
@ -3094,7 +3094,7 @@
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/GridColumn"
"$ref": "#/components/schemas/GridColumnReq"
}
}
}
@ -7304,10 +7304,7 @@
"type": "string"
},
"deleted": {
"type": [
"string",
"boolean"
]
"$ref": "#/components/schemas/NcBool"
},
"order": {
"type": "number"
@ -7319,7 +7316,7 @@
}
},
"is_meta": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"prefix": {
"type": "string"
@ -7394,8 +7391,7 @@
"type": "string"
},
"is_meta": {
"type": "boolean",
"readOnly": true
"$ref": "#/components/schemas/NcBool"
},
"config": {},
"created_at": {},
@ -7410,7 +7406,7 @@
"type": "number"
},
"enabled": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
}
}
},
@ -7590,7 +7586,7 @@
"type": "string"
},
"enabled": {
"type": "boolean"
"$ref" : "#/components/schemas/NcBool"
},
"parent_id": {
"type": "string"
@ -7602,10 +7598,10 @@
"type": "string"
},
"pinned": {
"type": "boolean"
"$ref" : "#/components/schemas/NcBool"
},
"deleted": {
"type": "boolean"
"$ref" : "#/components/schemas/NcBool"
},
"order": {
"type": "number"
@ -7623,10 +7619,7 @@
"type": "string"
},
"mm": {
"type": [
"boolean",
"number"
]
"$ref": "#/components/schemas/NcBool"
},
"meta": {}
},
@ -7712,7 +7705,7 @@
"type": "string"
},
"deleted": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"order": {
"type": "number"
@ -7728,7 +7721,7 @@
},
"meta": {},
"show_system_fields": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"lock_type": {
"type": "string",
@ -7888,10 +7881,10 @@
"type": "string"
},
"pinned": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"deleted": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"order": {
"type": "number"
@ -7955,16 +7948,16 @@
"type": "string"
},
"pinned": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"deleted": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"order": {
"type": "number"
},
"mm": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"columns": {
"type": "array",
@ -8048,15 +8041,7 @@
"comparison_op": {
"type": "string"
},
"value": {
"type": [
"string",
"number",
"integer",
"boolean",
"null"
]
},
"value": { },
"is_group": {
"oneOf": [
{
@ -8129,15 +8114,7 @@
"comparison_op": {
"type": "string"
},
"value": {
"type": [
"string",
"number",
"integer",
"boolean",
"null"
]
},
"value": { },
"is_group": {
"oneOf": [
{
@ -8406,48 +8383,28 @@
"type": "string"
},
"pk": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"pv": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"rqd": {
"oneOf": [
{
"type": "boolean"
},
{
"type": "integer"
},
{
"type": "null"
}
]
"$ref": "#/components/schemas/NcBool"
},
"column_name": {
"type": "string"
},
"un": {
"oneOf": [
{
"type": "boolean"
},
{
"type": "integer"
},
{
"type": "null"
}
]
"$ref": "#/components/schemas/NcBool"
},
"ct": {
"type": "string"
},
"ai": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"unique": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"cdf": {
"type": "string"
@ -8488,22 +8445,19 @@
]
},
"au": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"deleted": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"visible": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"order": {
"type": "number"
},
"system": {
"type": [
"number",
"boolean"
]
"$ref": "#/components/schemas/NcBool"
},
"meta": {},
"colOptions": {
@ -8595,7 +8549,7 @@
"type": "string"
},
"virtual": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"fk_column_id": {
"type": "string"
@ -8646,7 +8600,7 @@
"type": "string"
},
"virtual": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"fk_column_id": {
"type": "string"
@ -8676,7 +8630,7 @@
"type": "string"
},
"virtual": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"fk_column_id": {
"type": "string"
@ -8709,7 +8663,7 @@
"type": "string"
},
"virtual": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"fk_column_id": {
"type": "string"
@ -8800,7 +8754,7 @@
"type": "string"
},
"deleted": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"order": {
"type": "number"
@ -8861,16 +8815,16 @@
"type": "string"
},
"deleted": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"order": {
"type": "number"
},
"next_enabled": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"prev_enabled": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"cover_image_idx": {
"type": "integer"
@ -8918,10 +8872,10 @@
"type": "string"
},
"next_enabled": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"prev_enabled": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"cover_image_idx": {
"type": "integer"
@ -8976,6 +8930,28 @@
}
}
},
"GridColumnReq": {
"title": "GridColumn",
"type": "object",
"description": "",
"properties": {
"label": {
"type": "string"
},
"help": {
"type": "string"
},
"fk_column_id": {
"type": "string"
},
"fk_gallery_id": {
"type": "string"
},
"width": {
"type": "string"
}
}
},
"GridColumn": {
"title": "GridColumn",
"type": "object",
@ -9249,10 +9225,10 @@
"type": "string"
},
"submit_another_form": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"show_blank_form": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"columns": {
"type": "array",
@ -9307,10 +9283,10 @@
"type": "string"
},
"submit_another_form": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"show_blank_form": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"fk_model_id": {
"type": "string"
@ -9370,10 +9346,10 @@
},
"help": {},
"required": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"show": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"order": {
"type": "number"
@ -9393,6 +9369,50 @@
"meta": {}
}
},
"FormColumnReq": {
"description": "",
"type": "object",
"x-examples": {
"example-1": {
"_cn": "first_name",
"alias": "first_name",
"fk_column_id": "cl_yvyhsl9u81tokc",
"id": "fvc_8z1i7t8aswkqxx",
"fk_view_id": "vw_s1pf4umdnikoyn",
"uuid": null,
"label": "dsdsds",
"help": null,
"required": false,
"show": 1,
"order": 1,
"created_at": "2022-02-15 12:39:04",
"updated_at": "2022-02-15 12:39:16",
"description": "dsdsdsdsd"
}
},
"properties": {
"uuid": {},
"label": {
"type": "string",
"minLength": 1
},
"help": {},
"required": {
"$ref": "#/components/schemas/NcBool"
},
"show": {
"$ref": "#/components/schemas/NcBool"
},
"order": {
"type": "number"
},
"description": {
"type": "string",
"minLength": 1
},
"meta": {}
}
},
"Paginated": {
"title": "Paginated",
"type": "object",
@ -9705,7 +9725,7 @@
]
},
"async": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"notification": {
"type": "string"
@ -9720,7 +9740,7 @@
"type": "number"
},
"active": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
}
}
},
@ -9791,7 +9811,7 @@
"type": "number"
},
"active": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
}
},
"required": [
@ -9905,7 +9925,7 @@
"type": "string"
},
"active": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"rating": {
"type": "number"
@ -9984,7 +10004,7 @@
"type": "string"
},
"disabled": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
}
}
},
@ -10041,7 +10061,7 @@
"type": "string"
},
"test_call": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"payload": {},
"conditions": {
@ -10156,10 +10176,10 @@
]
},
"pk": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"pv": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"rqd": {
"oneOf": [
@ -10170,7 +10190,7 @@
"type": "null"
},
{
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
}
]
},
@ -10178,26 +10198,16 @@
"type": "string"
},
"un": {
"oneOf": [
{
"type": "boolean"
},
{
"type": "integer"
},
{
"type": "null"
}
]
"$ref": "#/components/schemas/NcBool"
},
"ct": {
"type": "string"
},
"ai": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"unique": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"cdf": {
"oneOf": [
@ -10245,7 +10255,7 @@
]
},
"au": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
}
}
},
@ -10262,7 +10272,7 @@
"type": "string"
},
"virtual": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"parentId": {
"type": "string"
@ -10424,27 +10434,40 @@
"type": "object",
"properties": {
"commenter": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"creator": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"editor": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"guest": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"owner": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
},
"viewer": {
"type": "boolean"
"$ref": "#/components/schemas/NcBool"
}
}
}
}
}
},
"NcBool": {
"oneOf": [
{
"type": "boolean"
},
{
"type": "integer"
},
{
"type": "null"
}
]
}
},
"requestBodies": {

Loading…
Cancel
Save