Aggiornamenti 2
This commit is contained in:
@@ -10,6 +10,8 @@ const { authenticate } = require('../middleware/authenticate');
|
||||
const mongoose = require('mongoose');
|
||||
|
||||
const { User } = require('../models/user');
|
||||
const { Nave } = require('../models/nave');
|
||||
const { ListaIngresso } = require('../models/listaingresso');
|
||||
|
||||
const _ = require('lodash');
|
||||
|
||||
@@ -24,6 +26,8 @@ router.post('/load', async (req, res) => {
|
||||
|
||||
let datastat = {
|
||||
num_reg: await User.getUsersRegistered(idapp),
|
||||
num_passeggeri: await Nave.getTotInLista(idapp) + await ListaIngresso.getTotInLista(idapp),
|
||||
num_imbarcati: await ListaIngresso.getTotInLista(idapp),
|
||||
email_non_verif: await User.getEmailNotVerified(idapp),
|
||||
num_teleg_attivo: await User.getUsersTelegramAttivo(idapp),
|
||||
num_teleg_pending: await User.getUsersTelegramPending(idapp),
|
||||
@@ -35,8 +39,11 @@ router.post('/load', async (req, res) => {
|
||||
arr_nations: await User.findAllDistinctNationality(idapp),
|
||||
numreg_untilday: await User.calcnumRegUntilDay(idapp),
|
||||
reg_daily: await User.calcRegDaily(idapp),
|
||||
reg_weekly: await User.calcRegWeekly(idapp),
|
||||
lastsreg: await User.getLastUsers(idapp),
|
||||
checkuser: await User.checkUser(idapp, username),
|
||||
// navi_partite: await Nave.getNaviPartite(idapp),
|
||||
// navi_in_partenza: await Nave.getNaviInPartenza(idapp),
|
||||
};
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user