Compare commits
5 Commits
1ace049687
...
renovate/a
| Author | SHA1 | Date | |
|---|---|---|---|
| e6d99ba9d6 | |||
| e20915ca82 | |||
|
|
5f4494f5aa | ||
| 58e6cbfac0 | |||
|
|
9fa73b2ecc |
@@ -48,11 +48,10 @@ class InvoiceDataMail extends Mailable
|
|||||||
$greeting = 'Dear Sir/Madam,<br><br>We are sending here with list of "Despatch pending sale invoice & STO invoice as on date"';
|
$greeting = 'Dear Sir/Madam,<br><br>We are sending here with list of "Despatch pending sale invoice & STO invoice as on date"';
|
||||||
|
|
||||||
if ($this->scheduleType == 'Daily') {
|
if ($this->scheduleType == 'Daily') {
|
||||||
$firstRecord = InvoiceDataValidation::orderBy('document_date', 'asc')->first();
|
$firstRecord = InvoiceDataValidation::orderBy('document_date', 'asc')->first(); // 'desc'
|
||||||
// $lastRecord = InvoiceDataValidation::orderBy('document_date', 'desc')->first();
|
|
||||||
|
|
||||||
$startDate = null;
|
$startDate = null;
|
||||||
if ($firstRecord && $firstRecord->document_date != null && $firstRecord->document_date != '') {
|
if ($firstRecord && $firstRecord?->document_date != null && $firstRecord?->document_date != '') {
|
||||||
$startDate = \Carbon\Carbon::parse($firstRecord->document_date)->startOfDay();
|
$startDate = \Carbon\Carbon::parse($firstRecord->document_date)->startOfDay();
|
||||||
// $endDate = \Carbon\Carbon::parse($lastRecord->document_date)->endOfDay();
|
// $endDate = \Carbon\Carbon::parse($lastRecord->document_date)->endOfDay();
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"require": {
|
"require": {
|
||||||
"php": "^8.2",
|
"php": "^8.2",
|
||||||
"alperenersoy/filament-export": "^3.0",
|
"alperenersoy/filament-export": "^4.0",
|
||||||
"althinect/filament-spatie-roles-permissions": "^2.3",
|
"althinect/filament-spatie-roles-permissions": "^2.3",
|
||||||
"erag/laravel-pwa": "^1.9",
|
"erag/laravel-pwa": "^1.9",
|
||||||
"filament/filament": "^3.3",
|
"filament/filament": "^3.3",
|
||||||
|
|||||||
@@ -2,6 +2,10 @@
|
|||||||
|
|
||||||
use Illuminate\Foundation\Inspiring;
|
use Illuminate\Foundation\Inspiring;
|
||||||
use Illuminate\Support\Facades\Artisan;
|
use Illuminate\Support\Facades\Artisan;
|
||||||
|
use App\Models\AlertMailRule;
|
||||||
|
use Illuminate\Console\Scheduling\Schedule;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Artisan::command('inspire', function () {
|
Artisan::command('inspire', function () {
|
||||||
$this->comment(Inspiring::quote());
|
$this->comment(Inspiring::quote());
|
||||||
@@ -14,9 +18,6 @@ app()->booted(function () {
|
|||||||
$schedule = app(Schedule::class);
|
$schedule = app(Schedule::class);
|
||||||
|
|
||||||
// $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')
|
||||||
@@ -93,5 +94,4 @@ app()->booted(function () {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user