<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;

class Seats extends Model
{
    public $table = 'seats';

    public $fillable = [
        'name',
        'branch_id',
        'status'
    ];

    protected $casts = [
        'name' => 'string',
    ];

    public static array $rules = [
        'name' => 'required|string|max:255',
        'branch_id' => 'nullable',
        'created_at' => 'nullable',
        'updated_at' => 'nullable'
    ];

    public function branch()
  {
    return $this->belongsTo(Branches::class, 'branch_id', 'id');
  }
}
