27 lines
513 B
PHP
27 lines
513 B
PHP
<?php
|
|
|
|
namespace App\Models\Materials;
|
|
|
|
use Illuminate\Database\Eloquent\Model;
|
|
use Illuminate\Database\Eloquent\SoftDeletes;
|
|
|
|
/**
|
|
* @mixin IdeHelperMaterialInspection
|
|
*/
|
|
class MaterialInspection extends Model
|
|
{
|
|
use SoftDeletes;
|
|
|
|
// 입고 내역
|
|
public function receipt()
|
|
{
|
|
return $this->belongsTo(MaterialReceipt::class, 'receipt_id');
|
|
}
|
|
|
|
// 검사 항목
|
|
public function items()
|
|
{
|
|
return $this->hasMany(MaterialInspectionItem::class, 'inspection_id');
|
|
}
|
|
}
|