++ aggiunta la prenotazione negli eventi. con la lista degli utenti.
This commit is contained in:
@@ -156,12 +156,7 @@ MySkillSchema.statics.getMyRecById = function(idapp, idSkill) {
|
||||
let query = [
|
||||
{
|
||||
'$match': {
|
||||
'_id': idSkill,
|
||||
},
|
||||
},
|
||||
{
|
||||
'$match': {
|
||||
'idapp': idapp,
|
||||
'_id': idSkill, idapp
|
||||
},
|
||||
},
|
||||
{
|
||||
@@ -312,11 +307,11 @@ MySkillSchema.statics.getMyRecById = function(idapp, idSkill) {
|
||||
const objadd = tools.addNumFavoriteAndBookmarkToQuery(idapp, numtab);
|
||||
query = [...query, ...objadd.query];
|
||||
|
||||
query = [...query,
|
||||
{
|
||||
$project: this.getProject(objadd.proj),
|
||||
}
|
||||
];
|
||||
const toadd = {
|
||||
$project: this.getProject(objadd.proj),
|
||||
};
|
||||
|
||||
query = [...query, {...toadd}];
|
||||
|
||||
return MySkill.aggregate(query).then((rec) => {
|
||||
return rec ? rec[0] : null;
|
||||
|
||||
Reference in New Issue
Block a user