Revert "Merge pull request 'feat: refs #6449 addSummaryId' (#3) from 6449-addSummaryId into master"
gitea/mylogger/pipeline/head This commit looks good Details

This reverts commit 1e2948506e, reversing
changes made to 2bb99bf093.
This commit is contained in:
Guillermo Bonet 2024-07-23 11:41:50 +02:00
parent 1e2948506e
commit 217e1cc177
2 changed files with 4 additions and 9 deletions

View File

@ -23,7 +23,6 @@ logs:
- itemTag - itemTag
- name: item - name: item
showField: name showField: name
showId: id
logFields: logFields:
- size - size
exclude: exclude:

View File

@ -80,8 +80,7 @@ module.exports = class MyLogger {
oldInstance = ?, oldInstance = ?,
newInstance = ?, newInstance = ?,
changedModelId = ?, changedModelId = ?,
changedModelValue = ?, changedModelValue = ?`
summaryId = ?`
); );
logInfo.fetchStmt = await db.prepare( logInfo.fetchStmt = await db.prepare(
`SELECT id FROM ${sqlTable} `SELECT id FROM ${sqlTable}
@ -96,8 +95,7 @@ module.exports = class MyLogger {
SET originFk = ?, SET originFk = ?,
creationDate = ?, creationDate = ?,
oldInstance = ?, oldInstance = ?,
changedModelValue = ?, changedModelValue = ?
summaryId = ?
WHERE id = ?` WHERE id = ?`
); );
} }
@ -514,7 +512,7 @@ module.exports = class MyLogger {
oldI = change.instance; oldI = change.instance;
break; break;
} }
const summaryId = row[tableInfo.conf.showId];
const modelId = row[tableInfo.idName]; const modelId = row[tableInfo.idName];
const modelValue = change.modelValue ?? null; const modelValue = change.modelValue ?? null;
const oldInstance = oldI ? JSON.stringify(oldI) : null; const oldInstance = oldI ? JSON.stringify(oldI) : null;
@ -540,7 +538,6 @@ module.exports = class MyLogger {
created, created,
oldInstance, oldInstance,
modelValue, modelValue,
summaryId,
deleteRow.id deleteRow.id
]); ]);
} }
@ -556,8 +553,7 @@ module.exports = class MyLogger {
oldInstance, oldInstance,
newI ? JSON.stringify(newI) : null, newI ? JSON.stringify(newI) : null,
modelId, modelId,
modelValue, modelValue
summaryId
]); ]);
} }