<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
use Illuminate\Database\Eloquent\SoftDeletes;

class PanelBoxValidation extends Model
{
    use SoftDeletes;

    protected $fillable = [
        'plant_id',
        'line_id',
        'sticker_master_id',
        'production_order',
        'serial_number',
        'serial_number_panel',
        'pack_slip_panel',
        'name_plate_panel',
        'tube_sticker_panel',
        'warranty_card_panel',
        'part_validation1',
        'part_validation2',
        'part_validation3',
        'part_validation4',
        'part_validation5',
        'panel_box_supplier',
        'panel_box_serial_number',
        'panel_box_code',
        'inspection_lot_number',
        'created_by',
        'updated_by'
    ];
    public function plant(): BelongsTo
    {
        return $this->belongsTo(Plant::class);
    }

    public function line(): BelongsTo
    {
        return $this->belongsTo(Line::class);
    }

    public function stickerMaster(): BelongsTo
    {
        return $this->belongsTo(StickerMaster::class);
    }
}
