fix: MES 모델 및 서비스 개선
- WorkOrderItem 모델 관계 정의 추가 - InspectionService, WorkResultService 로직 개선 - ItemReceipt, Inspection 모델 수정 - work_order_items 테이블에 options 컬럼 추가 마이그레이션 Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -3,8 +3,8 @@
|
||||
namespace App\Models\Qualitys;
|
||||
|
||||
use App\Models\Items\Item;
|
||||
use App\Models\Scopes\BelongsToTenant;
|
||||
use App\Models\Tenants\User;
|
||||
use App\Models\Members\User;
|
||||
use App\Traits\BelongsToTenant;
|
||||
use Illuminate\Database\Eloquent\Casts\Attribute;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\SoftDeletes;
|
||||
@@ -32,7 +32,7 @@
|
||||
*/
|
||||
class Inspection extends Model
|
||||
{
|
||||
use SoftDeletes;
|
||||
use BelongsToTenant, SoftDeletes;
|
||||
|
||||
protected $table = 'inspections';
|
||||
|
||||
@@ -89,11 +89,6 @@ class Inspection extends Model
|
||||
|
||||
public const RESULT_FAIL = 'fail';
|
||||
|
||||
protected static function booted(): void
|
||||
{
|
||||
static::addGlobalScope(new BelongsToTenant);
|
||||
}
|
||||
|
||||
// ===== Relationships =====
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user