aggiornamenti vari. prima di VITE

This commit is contained in:
Surya Paolo
2025-02-25 18:13:01 +01:00
parent f8de205cf6
commit 57679fe649
25 changed files with 1595 additions and 708 deletions

View File

@@ -142,6 +142,7 @@ myLoad().then(ris => {
const mygoods_router = require('./router/mygoods_router');
const mygen_router = require('./router/mygen_router');
const aitools_router = require('./router/aitools_router');
const article_router = require('./router/articleRoutes');
const { MyEvent } = require('./models/myevent');
@@ -262,6 +263,7 @@ myLoad().then(ris => {
app.use('/mygoods', mygoods_router);
app.use('/mygen', mygen_router);
app.use('/aitools', aitools_router);
app.use('/apisqlsrv', article_router);
mystart();
@@ -302,7 +304,7 @@ async function mystart() {
}
mycron();
if (!process.env.DEBUG) {
if (!process.env.VITE_DEBUG) {
mycron();
}
}
@@ -427,14 +429,14 @@ function testmsgwebpush() {
// Cron every X minutes
cron.schedule('*/1 * * * *', () => {
// console.log('Running Cron Job');
// if (!process.env.DEBUG) {
// if (!process.env.VITE_DEBUG) {
mycron();
// }
});
// Cron every X minutes
cron.schedule('*/60 * * * *', async () => {
if (!process.env.DEBUG) {
if (!process.env.VITE_DEBUG) {
mycron_30min();
}
});