Files
online.tbbank.gov.tm-larave…/app/Repos/Order/Card/CardStateRepo.php
2025-04-21 10:39:02 +05:00

24 lines
486 B
PHP

<?php
namespace App\Repos\Order\Card;
use App\Models\Order\Card\CardState;
use Illuminate\Support\Collection;
class CardStateRepo
{
/**
* Card state values
*
* @return \Illuminate\Support\Collection<int, string>|array<int, string>
*/
public static function values(): Collection|array
{
return cached(
'card-states',
fn () => CardState::where('active', true)->pluck('name', 'id'),
60 * 60
);
}
}