Montrer/cacher l'archétype

This commit is contained in:
Vincent Vandemeulebrouck
2021-01-03 19:19:02 +01:00
parent 3211c30519
commit 0072861c3f
3 changed files with 69 additions and 52 deletions

View File

@ -611,6 +611,18 @@ export class RdDActor extends Actor {
console.log("Competence not found", compName);
}
}
/* -------------------------------------------- */
async updateCompetenceArchetype( compName, compValue )
{
let comp = this.getCompetence(compName);
if ( comp ) {
const update = {_id: comp._id, 'data.niveau_archetype': compValue };
const updated = await this.updateEmbeddedEntity("OwnedItem", update); // Updates one EmbeddedEntity
} else {
console.log("Competence not found", compName);
}
}
/* -------------------------------------------- */
async updateCompteurValue( fieldName, fieldValue )