<?php

namespace Modules\WarehouseCategory\Models;

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

class WarehouseCategory extends Model
{
    //use soft delete
    use SoftDeletes;

    protected $fillable =
    [
        'id'
    ];

    /**
     * Get current description of the the Room
     * @return HasOne
     */
    public function currentDescription() :HasOne
    {
        return $this->hasOne(WarehouseCategoryDescription::class)->where('language_id', config('current_language_id'));
    }
}
