<?php

namespace App\Models;

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

class Etapa extends Model
{
    /** @use HasFactory<EtapaFactory> */
    use HasFactory;

    protected static function newFactory(): EtapaFactory
    {
        return EtapaFactory::new();
    }

    protected $table = 'etapas';

    protected $fillable = [
        'code',
        'name',
        'sort_order',
    ];

    protected $casts = [
        'sort_order' => 'integer',
    ];

    public const CODE_LAVADO = 'lavado';

    public const CODE_PLANCHADO = 'planchado';

    public const CODE_COMPLETO = 'completo';

    /** Productos de mostrador / retail en POS (sin flujo de lavado). */
    public const CODE_VENTA = 'venta';
}
