From 37970c5c91faa672d8b6132c03bd9f10a888dc01 Mon Sep 17 00:00:00 2001 From: Surya Paolo Date: Sun, 12 Jan 2025 21:29:16 +0100 Subject: [PATCH] piccole modifiche... --- src/common/shared_vuejs.ts | 10 +++++++--- src/components/CGridTableRec/CGridTableRec.ts | 7 +++++++ 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/src/common/shared_vuejs.ts b/src/common/shared_vuejs.ts index a9c400c9..3008ce1e 100755 --- a/src/common/shared_vuejs.ts +++ b/src/common/shared_vuejs.ts @@ -210,6 +210,7 @@ export const shared_consts = { FILTER_USER_SENZA_PROVINCE: 33554432, FILTER_USER_SENZA_CIRCUITO: 67108864, FILTER_USER_CON_CIRCUITO: 134217728, + FILTER_USER_ONLINE_6_MESI: 268435456, OPTIONS_SEARCH_ONLY_FULL_WORDS: 1, OPTIONS_SEARCH_USER_ONLY_FULL_WORDS: 2, @@ -296,8 +297,12 @@ export const shared_consts = { RECFILTRI_UTENTE: [ { label: '[Tutti]', - value: 0 + value: -100, }, + // { + // label: 'Online almeno da 6 mesi', + // value: 268435456, // FILTER_USER_ONLINE_6_MESI: 268435456, + // }, { label: 'Senza Provincia', value: 33554432, // FILTER_USER_SENZA_PROVINCE @@ -327,11 +332,10 @@ export const shared_consts = { value: 8388608, // shared_consts.FILTER_USER_WITHOUT_USERNAME_TELEGRAM }, { - label: 'Telegram BOT Rimosso', + label: 'Chat "BOT RISO" eliminata', value: 1024, //shared_consts.FILTER_USER_TELEGRAM_BLOCKED }, - ], MYTABS: [{ id: 0, table: 'none' }, diff --git a/src/components/CGridTableRec/CGridTableRec.ts b/src/components/CGridTableRec/CGridTableRec.ts index 2c738cde..38c963ad 100755 --- a/src/components/CGridTableRec/CGridTableRec.ts +++ b/src/components/CGridTableRec/CGridTableRec.ts @@ -945,6 +945,13 @@ export default defineComponent({ filtercustom.push({ 'profile.mycircuits': { $exists: true, $ne: [] } }); + } else if (item.value === shared_consts.FILTER_USER_ONLINE_6_MESI) { + const numgiorni_attivi = 30 * 6 + let daytocheck = new Date(); + daytocheck.setDate(daytocheck.getDate() - numgiorni_attivi); + daytocheck.setHours(0, 0, 0, 0) + + filtercustom.push({ lasttimeonline: { $gt: daytocheck } }) } else if (item.value === shared_consts.FILTER_USER_SENZA_CIRCUITO) { filtercustom.push({ $or: [