tethys/app/Models/HashValue.php

23 lines
462 B
PHP
Raw Permalink Normal View History

2018-08-29 15:18:15 +00:00
<?php
namespace App\Models;
use App\Models\File;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\Factories\HasFactory;
2018-08-29 15:18:15 +00:00
class HashValue extends Model
{
use HasFactory;
2018-08-29 15:18:15 +00:00
protected $table = 'file_hashvalues';
public $timestamps = false;
protected $primaryKey = ['file_id', 'type'];
public $incrementing = false;
2018-08-29 15:18:15 +00:00
public function file()
{
return $this->belongsTo(File::class, 'file_id', 'id');
}
}