<?php

namespace App\Enums;

enum PaymentType: string
{
    case BookingAmount = 'BOOKING_AMOUNT';
    case DownPayment = 'DOWN_PAYMENT';
    case Other = 'OTHER';

    /**
     * @return list<string>
     */
    public static function values(): array
    {
        return array_column(self::cases(), 'value');
    }

    public function label(): string
    {
        return match ($this) {
            self::BookingAmount => 'Booking amount',
            self::DownPayment => 'Down payment',
            self::Other => 'Other',
        };
    }
}
