Add Larastan configuration and dependencies for static analysis #9

Merged
jothi merged 8 commits from ranjith-dev into master 2025-11-26 09:11:37 +00:00
Showing only changes of commit 346aaf1438 - Show all commits

View File

@@ -4,6 +4,7 @@ use App\Models\AlertMailRule;
use Illuminate\Foundation\Inspiring; use Illuminate\Foundation\Inspiring;
use Illuminate\Support\Facades\Artisan; use Illuminate\Support\Facades\Artisan;
use Illuminate\Console\Scheduling\Schedule; use Illuminate\Console\Scheduling\Schedule;
use Illuminate\Support\Facades\Schema;
Artisan::command('inspire', function () { Artisan::command('inspire', function () {
$this->comment(Inspiring::quote()); $this->comment(Inspiring::quote());
@@ -20,6 +21,8 @@ Artisan::command('inspire', function () {
//$schedule->command('report:send-daily-production')->dailyAt('07:59'); //$schedule->command('report:send-daily-production')->dailyAt('07:59');
if (Schema::hasTable('alert_mail_rules')) {
//Production report scheduling //Production report scheduling
$productionRules = AlertMailRule::where('module', 'ProductionQuantities') $productionRules = AlertMailRule::where('module', 'ProductionQuantities')
->where('rule_name', 'ProductionMail') ->where('rule_name', 'ProductionMail')
@@ -31,8 +34,8 @@ Artisan::command('inspire', function () {
$type = $rule->schedule_type; $type = $rule->schedule_type;
$plantId = $rule->plant; $plantId = $rule->plant;
$command = $schedule->command('send:production-report', [$type, $plantId]) $command = $schedule->command('send:production-report', [$type, $plantId]);
->appendOutputTo(storage_path('logs/scheduler.log')); //->appendOutputTo(storage_path('logs/scheduler.log'));
switch ($type) { switch ($type) {
case 'Live': case 'Live':
@@ -72,7 +75,7 @@ Artisan::command('inspire', function () {
} }
} }
//Invoice Data report scheduling //Invoice Data Report Scheduling
$invoiceDataRules = AlertMailRule::where('module', 'InvoiceDataReport') $invoiceDataRules = AlertMailRule::where('module', 'InvoiceDataReport')
->select('plant', 'schedule_type') ->select('plant', 'schedule_type')
->distinct() ->distinct()
@@ -96,6 +99,7 @@ Artisan::command('inspire', function () {
break; break;
} }
} }
}
}); });