672367 lte gte fxx3
This commit is contained in:
parent
20ecd3edad
commit
7487f2c341
|
|
@ -115,14 +115,13 @@ public function getCanExtendLegalNumberAttribute()
|
|||
$month = Config::get('settings.legalization_extend') ?? 1;
|
||||
|
||||
if($application = $this->last_application()){
|
||||
Log::info($application);
|
||||
return $application->state == 'approved' && $this->expires_at->gte(Carbon::now()->subMonths($month));
|
||||
}
|
||||
if($this->expires_at->gte(Carbon::now()->subMonths($month))){
|
||||
Log::info($this->expires_at);
|
||||
}else{
|
||||
Log::info(Carbon::now()->subMonths($month));
|
||||
return $application->state == 'approved' && $this->expires_at->lte(Carbon::now()->subMonths($month));
|
||||
}
|
||||
// if($this->expires_at->gte(Carbon::now()->subMonths($month))){
|
||||
// Log::info($this->expires_at);
|
||||
// }else{
|
||||
// Log::info(Carbon::now()->subMonths($month));
|
||||
// }
|
||||
|
||||
return !empty($this->legalization_number) && !empty( $this->expires_at) && $this->expires_at->gte(Carbon::now()->subMonths($month));
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue