@php if (empty($product)) { $product_id = ''; $product_code = ''; $product_name = ''; $product_price = ''; $product_weight = ''; $product_quantity = ''; $product_type = ''; $product_description = ''; $product_stock = ''; $product_status = ''; $product_image = ''; } else { $product_id = $product->product_id; $product_code = $product->product_code; $product_name = $product->product_name; $product_price = $product->product_price; $product_weight = $product->product_weight ?? ''; $product_quantity = $product->product_quantity; $product_type = $product->product_type; $product_description = $product->product_description; $product_stock = $product->product_stock; $product_status = $product->product_status; $product_image = $product->product_image; } @endphp @extends('layouts.master') @section('title', 'Product Add/Edit') @section('style') @endsection @section('script') @endsection @section('content') @include('layouts.header') @include('layouts.title')
@yield('title')
@if ($errors->any())
    @foreach ($errors->all() as $error)
  • {{ $error }}
  • @endforeach
@endif
@csrf
@if (!empty($product_image))

Current Image:

Product Image
@endif


* These fields are required.
{{--
@csrf
@php $studentTypes = explode(',', $student->student_type ?? ''); $studentScholarshipPrograms = explode( ',', $student->student_scholarship_program ?? '', ); $typeNames = $type ->whereIn('type_id', $studentTypes) ->pluck('type_name_en') ->implode(', '); @endphp
THB


* These fields are required.
--}}
@include('layouts.footer') @endsection