<?php

namespace App;

use Illuminate\Database\Eloquent\Model;

use App\Traits\ModelLogChanging;

class InventoryDailyLog extends Model
{
    use ModelLogChanging;

    public $timestamps=false;
    protected $fillable=[
        'owner_id','created_at','commodity_id','amount','volumn_occupied','gross_weight','depository_id'
    ];

    public function owner(){
        return $this->hasOne('App\Owner','id','owner_id')->select('id','name');
    }
    public function commodity(){
        return $this->hasOne('App\Commodity','id','commodity_id');
    }
    public function depository(){
        return $this->hasOne('App\Depository','id','depository_id');
    }
}
