12 ] ); } } )->daily(); /** * Will execute here recurring transaction * based on a cron configuration */ if ( Helper::installed() ) { /** * This will check if cron jobs are correctly configured * and delete the generated notification if it was disabled. */ Schedule::call( fn() => ns()->setLastCronActivity() )->everyMinute(); /** * This will check every minutes if the symbolic link is * broken to the storage folder. */ Schedule::call( fn() => ns()->checkSymbolicLinks() )->hourly(); /** * Will execute scheduled transactions * every minutes */ Schedule::job( DetectScheduledTransactionsJob::class )->everyFiveMinutes(); /** * Will check procurement awaiting automatic * stocking to update their status. */ Schedule::job( new StockProcurementJob )->dailyAt( '00:05' ); /** * Will purge stoarge orders daily. */ Schedule::job( new PurgeOrderStorageJob )->dailyAt( '15:00' ); /** * Will clear hold orders that has expired. */ Schedule::job( new ClearHoldOrdersJob )->dailyAt( '14:00' ); /** * Will detect products that has reached the threashold of * low inventory to trigger a notification and an event. */ Schedule::job( new DetectLowStockProductsJob )->dailyAt( '00:02' ); /** * Will track orders saved with instalment and * trigger relevant notifications. */ Schedule::job( new TrackLaidAwayOrdersJob )->dailyAt( '13:00' ); /** * We'll check if there is a ProductHistoryCombined that was generated * during the current day. If it's not the case, we'll create one. */ Schedule::job( new EnsureCombinedProductHistoryExistsJob )->hourly(); /** * We'll clear temporary files weekly. This will erase folder that * hasn't been deleted after a module installation. */ Schedule::job( new ClearModuleTempJob )->weekly(); if ( ! in_array( env( 'QUEUE_CONNECTION' ), [ 'sync' ] ) ) { Schedule::job( new DeleteExpiredOptionsJob )->daily()->withoutOverlapping(); } /** * Will check daily if a new NexoPOS version is available * on GitHub and store the result as an option. */ Schedule::job( new CheckForUpdatesJob )->dailyAt( '08:00' ); include_once __DIR__ . '/console/transactions.php'; }