- versione: 1.2.77
- aggiustamenti e miglioramenti estetici
This commit is contained in:
@@ -488,7 +488,8 @@ CircuitSchema.statics.getCircuitsByUsername = async function (idapp, username, u
|
|||||||
{ deleted: { $exists: true, $eq: false } }],
|
{ deleted: { $exists: true, $eq: false } }],
|
||||||
}, whatToShow_Unknown).sort({ status: -1 }).lean();
|
}, whatToShow_Unknown).sort({ status: -1 }).lean();
|
||||||
|
|
||||||
const last_my_transactions = await Movement.getLastN_Transactions(idapp, nummovTodownload, username, '');
|
const last_my_transactions = await Movement.getLastN_Transactions(idapp, nummovTodownload, nummovTodownload, username, '');
|
||||||
|
const total_transactions = await Movement.getNumTotalTransactions(idapp, username, '');
|
||||||
|
|
||||||
return {
|
return {
|
||||||
listcircuits,
|
listcircuits,
|
||||||
@@ -497,6 +498,7 @@ CircuitSchema.statics.getCircuitsByUsername = async function (idapp, username, u
|
|||||||
manage_mycircuits,
|
manage_mycircuits,
|
||||||
mycircuits: user.profile.mycircuits,
|
mycircuits: user.profile.mycircuits,
|
||||||
last_my_transactions,
|
last_my_transactions,
|
||||||
|
total_transactions
|
||||||
};
|
};
|
||||||
|
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -68,7 +68,7 @@ const StatSchema = new Schema({
|
|||||||
|
|
||||||
StatSchema.statics.updateStats = async function (idapp, datastat) {
|
StatSchema.statics.updateStats = async function (idapp, datastat) {
|
||||||
|
|
||||||
datastat.last_transactions = await Movement.getLastN_Transactions(idapp, 5);
|
datastat.last_transactions = await Movement.getLastN_Transactions(idapp, 5, 5);
|
||||||
|
|
||||||
return datastat;
|
return datastat;
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -427,13 +427,14 @@ router.patch('/:id', authenticate, (req, res) => {
|
|||||||
|
|
||||||
router.post('/lastmovs', authenticate, async (req, res) => {
|
router.post('/lastmovs', authenticate, async (req, res) => {
|
||||||
const nummov = req.body.nummov;
|
const nummov = req.body.nummov;
|
||||||
|
const nummov_uscita = req.body.nummov_uscita;
|
||||||
const idapp = req.body.idapp;
|
const idapp = req.body.idapp;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
const { Movement } = require('../models/movement');
|
const { Movement } = require('../models/movement');
|
||||||
|
|
||||||
if (nummov) {
|
if (nummov) {
|
||||||
last_transactions = await Movement.getLastN_Transactions(idapp, nummov);
|
last_transactions = await Movement.getLastN_Transactions(idapp, nummov, nummov_uscita);
|
||||||
}
|
}
|
||||||
|
|
||||||
res.send({ code: server_constants.RIS_CODE_OK, last_transactions });
|
res.send({ code: server_constants.RIS_CODE_OK, last_transactions });
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
1.2.76
|
1.2.77
|
||||||
Reference in New Issue
Block a user