İlk temizlik tamamlandı bir önceki projeden
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class Spool extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $table = 'pdfm_spools';
|
||||
|
||||
protected $fillable = [
|
||||
'spool_no',
|
||||
'description',
|
||||
'material',
|
||||
'diameter',
|
||||
'thickness',
|
||||
'length',
|
||||
'classification',
|
||||
'status'
|
||||
];
|
||||
|
||||
// Relationships
|
||||
public function joints()
|
||||
{
|
||||
return $this->hasMany(Joint::class, 'spool_no', 'spool_no');
|
||||
}
|
||||
|
||||
public function annotations()
|
||||
{
|
||||
return $this->hasMany(Annotation::class, 'spool_no', 'spool_no');
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user