Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 5342-monitor.tickets_isFragile
gitea/salix/pipeline/head There was a failure building this commit
Details
gitea/salix/pipeline/head There was a failure building this commit
Details
This commit is contained in:
commit
46e61543a8
|
@ -82,6 +82,11 @@
|
||||||
"type": "hasMany",
|
"type": "hasMany",
|
||||||
"model": "ClaimDms",
|
"model": "ClaimDms",
|
||||||
"foreignKey": "claimFk"
|
"foreignKey": "claimFk"
|
||||||
|
},
|
||||||
|
"lines": {
|
||||||
|
"type": "hasMany",
|
||||||
|
"model": "ClaimBeginning",
|
||||||
|
"foreignKey": "claimFk"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,7 +3,8 @@
|
||||||
"base": "Loggable",
|
"base": "Loggable",
|
||||||
"log": {
|
"log": {
|
||||||
"model": "EntryLog",
|
"model": "EntryLog",
|
||||||
"relation": "entry"
|
"relation": "entry",
|
||||||
|
"grabUser": true
|
||||||
},
|
},
|
||||||
"options": {
|
"options": {
|
||||||
"mysql": {
|
"mysql": {
|
||||||
|
|
|
@ -2,7 +2,8 @@
|
||||||
"name": "Entry",
|
"name": "Entry",
|
||||||
"base": "Loggable",
|
"base": "Loggable",
|
||||||
"log": {
|
"log": {
|
||||||
"model":"EntryLog"
|
"model":"EntryLog",
|
||||||
|
"grabUser": true
|
||||||
},
|
},
|
||||||
"options": {
|
"options": {
|
||||||
"mysql": {
|
"mysql": {
|
||||||
|
|
|
@ -3,7 +3,8 @@
|
||||||
"base": "Loggable",
|
"base": "Loggable",
|
||||||
"log": {
|
"log": {
|
||||||
"model": "ItemLog",
|
"model": "ItemLog",
|
||||||
"showField": "id"
|
"showField": "id",
|
||||||
|
"grabUser": true
|
||||||
},
|
},
|
||||||
"options": {
|
"options": {
|
||||||
"mysql": {
|
"mysql": {
|
||||||
|
|
|
@ -2,7 +2,8 @@
|
||||||
"name": "Route",
|
"name": "Route",
|
||||||
"base": "Loggable",
|
"base": "Loggable",
|
||||||
"log": {
|
"log": {
|
||||||
"model":"RouteLog"
|
"model":"RouteLog",
|
||||||
|
"grabUser": true
|
||||||
},
|
},
|
||||||
"options": {
|
"options": {
|
||||||
"mysql": {
|
"mysql": {
|
||||||
|
|
|
@ -127,19 +127,6 @@ module.exports = Self => {
|
||||||
], myOptions);
|
], myOptions);
|
||||||
|
|
||||||
const ticket = await models.Ticket.findById(result[1][0].newTicketId, null, myOptions);
|
const ticket = await models.Ticket.findById(result[1][0].newTicketId, null, myOptions);
|
||||||
const cleanInstance = JSON.parse(JSON.stringify(ticket));
|
|
||||||
|
|
||||||
const logRecord = {
|
|
||||||
originFk: cleanInstance.id,
|
|
||||||
userFk: myUserId,
|
|
||||||
action: 'insert',
|
|
||||||
changedModel: 'Ticket',
|
|
||||||
changedModelId: cleanInstance.id,
|
|
||||||
oldInstance: {},
|
|
||||||
newInstance: cleanInstance
|
|
||||||
};
|
|
||||||
|
|
||||||
await models.TicketLog.create(logRecord, myOptions);
|
|
||||||
|
|
||||||
if (tx) await tx.commit();
|
if (tx) await tx.commit();
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,8 @@
|
||||||
"log": {
|
"log": {
|
||||||
"model": "TicketLog",
|
"model": "TicketLog",
|
||||||
"relation": "ticket",
|
"relation": "ticket",
|
||||||
"showField": "concept"
|
"showField": "concept",
|
||||||
|
"grabUser": true
|
||||||
},
|
},
|
||||||
"options": {
|
"options": {
|
||||||
"mysql": {
|
"mysql": {
|
||||||
|
|
|
@ -3,7 +3,8 @@
|
||||||
"base": "Loggable",
|
"base": "Loggable",
|
||||||
"log": {
|
"log": {
|
||||||
"model":"TicketLog",
|
"model":"TicketLog",
|
||||||
"showField": "id"
|
"showField": "id",
|
||||||
|
"grabUser": true
|
||||||
},
|
},
|
||||||
"options": {
|
"options": {
|
||||||
"mysql": {
|
"mysql": {
|
||||||
|
|
|
@ -3,7 +3,8 @@
|
||||||
"base": "Loggable",
|
"base": "Loggable",
|
||||||
"log": {
|
"log": {
|
||||||
"model":"TravelLog",
|
"model":"TravelLog",
|
||||||
"showField": "ref"
|
"showField": "ref",
|
||||||
|
"grabUser": true
|
||||||
},
|
},
|
||||||
"options": {
|
"options": {
|
||||||
"mysql": {
|
"mysql": {
|
||||||
|
|
Loading…
Reference in New Issue