@extends('layouts.app') @section('title', ($mode === 'create' ? '기초자료 등록' : ($mode === 'edit' ? '기초자료 수정' : '기초자료 상세'))) @section('content') @php $opt = is_array($item) ? $item : ($item?->options ?? []); $isView = $mode === 'view'; $isCreate = $mode === 'create'; $bendingData = $opt['bendingData'] ?? []; $itemId = is_array($item) ? ($item['id'] ?? null) : $item?->id; $itemCode = is_array($item) ? ($item['code'] ?? '') : ($itemCode ?? ''); $itemName = is_array($item) ? ($item['name'] ?? '') : ($itemName ?? ''); $itemBending = $opt['item_bending'] ?? ''; $isCase = in_array($itemBending, ['케이스']); @endphp
{{-- 헤더 --}}

{{ $mode === 'create' ? '기초자료 등록' : ($mode === 'edit' ? '기초자료 수정' : '기초자료 상세') }} @if($item) {{ $itemCode }} @endif

@if(!$isCreate) @endif @if($isView) 수정 @endif @if(!$isCreate)
@csrf @method('DELETE')
@endif
@if(session('success')) @endif @if($errors->any())
@endif
@csrf @if(!$isCreate) @method('PUT') @endif
{{-- 좌: 기본정보 + 케이스 전용 + 절곡 테이블 --}}
{{-- 기본 정보 --}}

기본 정보

{{-- 케이스 전용 필드 --}}

케이스 전용

{{-- 절곡 입력 테이블 --}}

절곡 입력 테이블

@if(!$isView)
@endif
구분
입력
연신율
연신율후
합계
음영
A각
폭합계: 0 | 절곡횟수: 0
{{-- 우: 이미지 + 메모 --}}

형상 이미지

@if(!empty($imageFile)) 전개도 @else 이미지 없음 @endif
@if(!$isView)

Ctrl+V로 붙여넣기 가능

@endif

비고

@if(!$isView)
@endif
{{-- 절곡 데이터 hidden --}}
@if(!$isView) @include('components.canvas-editor') @endif {{-- 이력 모달 --}} @if(!$isCreate)

수정 이력

@if(!empty($opt['change_log'])) @endif
코드{{ $itemCode }}
등록일{{ $opt['registration_date'] ?? '-' }}
작성자{{ $opt['author'] ?? '-' }}
최종수정자{{ $opt['modified_by'] ?? '-' }}
현재 수정자{{ Auth::user()?->name ?? '-' }}
생성일시{{ is_array($item) ? ($item['created_at'] ?? '-') : '-' }}
수정일시{{ is_array($item) ? ($item['updated_at'] ?? '-') : '-' }}
변경 기록
@foreach(array_reverse($opt['change_log']) as $log)
{{ $log['date'] ?? '' }} {{ $log['memo'] ?? '' }}
@endforeach
@endif
@push('scripts') @endpush @endsection