-Poter entrare nel login anche con l'username Telegram !
- Se clicchi sulla foto, mi apre il profilo anzichè l'invio dei RIS - ++ Filtro sulle ricerche: Scegliere un Circuito specifico. - Nella lista iscritti compaiono anche i cancellati... - n "Attività" si vede tutto allargato, non sta nella dimensione della pagina. - Nelle notifiche della campanellina non si vede più il titolo... (è vuoto). - Non funziona il Filtro per Settore (nella Home sugli Eventi) - Filtri avanzati da mostrare solo se clicco sul bottone. - I menu in basso non funzionano ! - Nel menu "Iscritti" del circuito, non compare più la ricerca ! Riattivarla - Opzione di mandare una email quando uno si registra al Circuito - ++ Opzione per il Circuito: Chiedi di entrare agli admin (e non in automatico).
This commit is contained in:
@@ -1185,6 +1185,9 @@ module.exports = {
|
||||
|
||||
let arrris = [];
|
||||
|
||||
const userOrig = await User.findOne({ idapp, username: usernameOrig },
|
||||
{ _id: 1, lang: 1, aportador_solidario: 1, name: 1, surname: 1, username: 1 });
|
||||
|
||||
const user = await User.findOne({ idapp, username: usernameDest },
|
||||
{ _id: 1, lang: 1 });
|
||||
|
||||
@@ -1238,9 +1241,31 @@ module.exports = {
|
||||
if (mycircuit && mycircuit.askManagerToEnter) {
|
||||
cmdrichiesta = shared_consts.CallFunz.RICHIESTA_CIRCUIT;
|
||||
}
|
||||
|
||||
|
||||
telegrambot.askConfirmationUser(idapp, cmdrichiesta, myuserdata, usernameDest, circuitname,
|
||||
myreccircuit._id, '', extrarec.groupname);
|
||||
|
||||
if (mycircuit.sendEmailAfterAskingToEnter) {
|
||||
const { Circuit } = require('../models/circuit');
|
||||
|
||||
const path = await Circuit.getPathByCircuitName(idapp, circuitname);
|
||||
let myapp = this.getHostByIdApp(idapp);
|
||||
let linkcirc = myapp + path;
|
||||
let messaggio = '';
|
||||
let mytitle = i18n.__('CIRCUIT_REQUEST_TO_ENTER_ASKMANAGER_TITLE', usernameOrig);
|
||||
messaggio = i18n.__('CIRCUIT_REQUEST_TO_ENTER_ASKMANAGER_SHORT', usernameOrig, '<strong>' + circuitname + '</strong>', numuserincircuit, userOrig.aportador_solidario);
|
||||
messaggio += '\n\n';
|
||||
messaggio += '<a href="' + linkcirc + '" target="_blank">Clicca qui per entrare sul Circuito</a>\n';
|
||||
|
||||
const sendemail = require('../sendemail');
|
||||
|
||||
const email = myuserdata.email;
|
||||
|
||||
sendemail.sendEmail_ByText(lang, email, myuserdata, idapp, {
|
||||
emailbody: messaggio,
|
||||
emailtitle: mytitle,
|
||||
})
|
||||
}
|
||||
onlysave = false;
|
||||
} else if (cmd === shared_consts.CIRCUITCMD.ADDADMIN) {
|
||||
typeid = shared_consts.TypeNotifs.ID_CIRCUIT_ADDED_ADMIN;
|
||||
@@ -4950,10 +4975,12 @@ module.exports = {
|
||||
return '🗓 ' + mystr;
|
||||
},
|
||||
|
||||
getDoveStrByEvent(myrec) {
|
||||
getDoveStrByAnnuncio(myrec) {
|
||||
let dove = '🏠 ';
|
||||
if (myrec.mycities && myrec.mycities.length > 0) {
|
||||
dove += myrec.mycities[0].comune + ' (' + myrec.mycities[0].prov + ')'
|
||||
dove += myrec.mycities.map(city => {
|
||||
return `${city.comune} (${city.prov})`;
|
||||
}).join(', ');
|
||||
}
|
||||
return dove;
|
||||
},
|
||||
@@ -4971,7 +4998,7 @@ module.exports = {
|
||||
async getEventForTelegram(myrec, mydescr, userorig) {
|
||||
try {
|
||||
let datastr = this.getstrDateTimeEvent(myrec);
|
||||
let dovestr = this.getDoveStrByEvent(myrec);
|
||||
let dovestr = this.getDoveStrByAnnuncio(myrec);
|
||||
let descrestesa = await this.getDescrEstesaStrByEvent(myrec);
|
||||
let organizedby = myrec.organisedBy;
|
||||
let contributo = myrec.contribstr;
|
||||
@@ -5259,6 +5286,8 @@ module.exports = {
|
||||
|
||||
let img = '';
|
||||
|
||||
let descrperNotif = '';
|
||||
|
||||
if ((tablerec === shared_consts.TABLES_MYGOODS) || (tablerec === shared_consts.TABLES_MYSKILLS)) {
|
||||
iconascambio = this.getIconByAdType(myrec.adType);
|
||||
if (myrec.adType === shared_consts.AdType.OFFRO)
|
||||
@@ -5284,12 +5313,20 @@ module.exports = {
|
||||
|
||||
if (tablerec === shared_consts.TABLES_MYGOODS) {
|
||||
newdescr = i18n.__('Good', userorig, mydescr);
|
||||
descrperNotif = i18n.__('Good: %', mydescr);
|
||||
} else if (tablerec === shared_consts.TABLES_MYSKILLS) {
|
||||
newdescr = i18n.__('Service', userorig, mydescr);
|
||||
descrperNotif = i18n.__('Service: %', mydescr);
|
||||
} else if (tablerec === shared_consts.TABLES_MYHOSPS) {
|
||||
newdescr = i18n.__('Hosp', userorig, mydescr);
|
||||
descrperNotif = i18n.__('Hosp %s', userorig, mydescr);
|
||||
} else if (tablerec === shared_consts.TABLES_MYBACHECAS) {
|
||||
newdescr = i18n.__('Event', userorig, mydescr);
|
||||
let dovestr = this.getDoveStrByAnnuncio(myrec);
|
||||
descrperNotif = i18n.__('NEW_EVENT', userorig, datastr, mydescr, dovestr);
|
||||
}
|
||||
|
||||
|
||||
let contatto = userorig;
|
||||
let contatto_telegram = '';
|
||||
try {
|
||||
@@ -5422,7 +5459,7 @@ module.exports = {
|
||||
|
||||
// out += i18n.__('ADDED_FROM', );
|
||||
|
||||
return { newdescr, newdescrtelegram: out, img };
|
||||
return { newdescr, newdescrtelegram: out, img, descrperNotif };
|
||||
} catch (e) {
|
||||
console.error('Error', e);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user