wip
This commit is contained in:
@@ -14,7 +14,11 @@ class LoanTypeRepo
|
||||
*/
|
||||
public static function values(): Collection|array
|
||||
{
|
||||
return LoanType::where('active', true)->pluck('name', 'id');
|
||||
return cached(
|
||||
'loan-types-plucked',
|
||||
LoanType::where('active', true)->pluck('name', 'id'),
|
||||
60 * 60,
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -24,7 +28,11 @@ class LoanTypeRepo
|
||||
*/
|
||||
public static function onlyGuarantor(): Collection|array
|
||||
{
|
||||
return LoanType::where('active', true)->where('id', static::loanTypeGuarantorId())->pluck('name', 'id');
|
||||
return cached(
|
||||
'only-guarantor-plucked',
|
||||
LoanType::where('active', true)->where('id', static::loanTypeGuarantorId())->pluck('name', 'id'),
|
||||
60 * 60,
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user