From 160eb1fd62aa9f7e575f507e66793bc908a92fe0 Mon Sep 17 00:00:00 2001 From: Daniel Spaude Date: Thu, 27 Oct 2022 17:52:21 +0400 Subject: [PATCH] qrcode: add missing logic to columnApis#columnAdd --- .../src/lib/db/sql-data-mapper/lib/sql/BaseModelSqlv2.ts | 1 - packages/nocodb/src/lib/meta/api/columnApis.ts | 6 ++++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/packages/nocodb/src/lib/db/sql-data-mapper/lib/sql/BaseModelSqlv2.ts b/packages/nocodb/src/lib/db/sql-data-mapper/lib/sql/BaseModelSqlv2.ts index b3be7eba73..fbef3b8a67 100644 --- a/packages/nocodb/src/lib/db/sql-data-mapper/lib/sql/BaseModelSqlv2.ts +++ b/packages/nocodb/src/lib/db/sql-data-mapper/lib/sql/BaseModelSqlv2.ts @@ -1436,7 +1436,6 @@ class BaseModelSqlv2 { break; } } - console.debug('qb.toQuery(): ', qb.toQuery()); qb.select(res); } diff --git a/packages/nocodb/src/lib/meta/api/columnApis.ts b/packages/nocodb/src/lib/meta/api/columnApis.ts index b1433dffbe..b07da041c4 100644 --- a/packages/nocodb/src/lib/meta/api/columnApis.ts +++ b/packages/nocodb/src/lib/meta/api/columnApis.ts @@ -490,6 +490,12 @@ export async function columnAdd(req: Request, res: Response) { Tele.emit('evt', { evt_type: 'relation:created' }); break; + case UITypes.QrCode: + await Column.insert({ + ...colBody, + fk_model_id: table.id, + }); + break; case UITypes.Formula: colBody.formula = await substituteColumnAliasWithIdInFormula( colBody.formula_raw || colBody.formula,