- "La Mia Lavagna" ora è visibile il numero di Invitati che hanno i requisiti, dei propri invitati.

- Sistemato la funzione di poter Donare un invitato a qualcun'altro.
 - Aggiornati testi sul BOT.

 Per Staff Admin:
 - Notifica sul BOT per ogni modifica dell'invitante o eliminazione di un invitato.
This commit is contained in:
Paolo Arena
2020-02-05 00:39:25 +01:00
parent e386d2550b
commit a8bec7686a
4 changed files with 153 additions and 54 deletions

View File

@@ -316,6 +316,8 @@ UserSchema.statics.findByCredentials = function (idapp, username, password) {
UserSchema.statics.findByUsername = function (idapp, username) {
const User = this;
// /^bar$/i
return User.findOne({
'idapp': idapp,
'username': username,
@@ -336,6 +338,9 @@ UserSchema.statics.getUserShortDataByUsername = function (idapp, username) {
verified_email: 1,
'profile.teleg_id': 1,
'profile.saw_zoom_presentation': 1,
'profile.email_paypal': 1,
'profile.my_dream': 1,
'profile.paymenttypes': 1,
made_gift: 1,
email: 1,
date_reg: 1,
@@ -365,11 +370,19 @@ UserSchema.statics.getDownlineByUsername = function (idapp, username) {
verified_email: 1,
'profile.teleg_id': 1,
'profile.saw_zoom_presentation': 1,
'profile.email_paypal': 1,
'profile.my_dream': 1,
'profile.paymenttypes': 1,
made_gift: 1,
email: 1,
date_reg: 1,
img: 1
}, (err, arrrec) => {
for (const rec of arrrec) {
rec.numinvitatiattivi = User.getnumInvitatiAttivi(idapp, rec.username);
}
return arrrec
});
};