refs #5541 NPM upgraded, created date UTC fix
gitea/mylogger/pipeline/head This commit looks good
Details
gitea/mylogger/pipeline/head This commit looks good
Details
This commit is contained in:
parent
16e15e739b
commit
8be905fea9
|
@ -13,7 +13,7 @@ RUN apt-get update \
|
|||
&& curl -fsSL https://deb.nodesource.com/setup_14.x | bash - \
|
||||
&& apt-get install -y --no-install-recommends nodejs \
|
||||
&& rm -rf /var/lib/apt/lists/* \
|
||||
&& npm i -g npm@9.5.0
|
||||
&& npm i -g npm@9.6.4
|
||||
|
||||
# MyLogger
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
code: mylogger
|
||||
debug: false
|
||||
testMode: false
|
||||
pingInterval: 3600
|
||||
pingInterval: 300
|
||||
flushInterval: 30
|
||||
restartTimeout: 30
|
||||
queueFlushDelay: 200
|
||||
|
|
11
mylogger.js
11
mylogger.js
|
@ -613,12 +613,21 @@ module.exports = class MyLogger {
|
|||
break;
|
||||
}
|
||||
|
||||
let created = new Date(evt.timestamp);
|
||||
created = Date.UTC(
|
||||
created.getFullYear(),
|
||||
created.getMonth(),
|
||||
created.getDate(),
|
||||
created.getHours(),
|
||||
created.getMinutes(),
|
||||
created.getSeconds()
|
||||
);
|
||||
|
||||
const modelName = tableInfo.modelName;
|
||||
const modelId = row[tableInfo.idName];
|
||||
const modelValue = tableInfo.showField
|
||||
? row[tableInfo.showField] || null
|
||||
: null;
|
||||
const created = new Date(evt.timestamp);
|
||||
const oldInstance = oldI ? JSON.stringify(oldI) : null;
|
||||
const originFk = !tableInfo.isMain
|
||||
? row[tableInfo.relation]
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "mylogger",
|
||||
"version": "0.1.2",
|
||||
"version": "0.1.3",
|
||||
"author": "Verdnatura Levante SL",
|
||||
"description": "MySQL and MariaDB logger using binary log",
|
||||
"license": "GPL-3.0",
|
||||
|
|
Loading…
Reference in New Issue