<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;

class App extends Model
{
    use HasFactory;

    protected $fillable = [
        'app_key', 'display_name', 'description', 'icon', 'color',
        'category', 'page_link', 'is_paid', 'price', 'currency', 'is_active',
    ];

    protected function casts(): array
    {
        return [
            'is_paid'   => 'boolean',
            'is_active' => 'boolean',
            'price'     => 'decimal:2',
        ];
    }
}
