mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-18 10:31:15 +00:00
feat(core): Optionally return updated/upserted Data Table rows (no-changelog) (#18735)
This commit is contained in:
@@ -274,7 +274,12 @@ export class DataStoreController {
|
||||
@Body dto: UpsertDataStoreRowsDto,
|
||||
) {
|
||||
try {
|
||||
return await this.dataStoreService.upsertRows(dataStoreId, req.params.projectId, dto);
|
||||
return await this.dataStoreService.upsertRows(
|
||||
dataStoreId,
|
||||
req.params.projectId,
|
||||
dto,
|
||||
dto.returnData,
|
||||
);
|
||||
} catch (e: unknown) {
|
||||
if (e instanceof DataStoreNotFoundError) {
|
||||
throw new NotFoundError(e.message);
|
||||
@@ -297,7 +302,12 @@ export class DataStoreController {
|
||||
@Body dto: UpdateDataStoreRowDto,
|
||||
) {
|
||||
try {
|
||||
return await this.dataStoreService.updateRow(dataStoreId, req.params.projectId, dto);
|
||||
return await this.dataStoreService.updateRow(
|
||||
dataStoreId,
|
||||
req.params.projectId,
|
||||
dto,
|
||||
dto.returnData,
|
||||
);
|
||||
} catch (e: unknown) {
|
||||
if (e instanceof DataStoreNotFoundError) {
|
||||
throw new NotFoundError(e.message);
|
||||
|
||||
Reference in New Issue
Block a user