@extends('layouts.app')

@section('content')

    <div class="px-3">

        <form class="row" action="{{ route('product_sku.update', $product_sku) }}" method="post">
            <div class="col-xxl-6">
                <h4>МАФ на складе</h4>
                @csrf

                <input type="hidden" id="product_id" name="product_id" value="{{ $product_sku->product_id }}">

                @include('partials.input', ['name' => 'order_name', 'title' => 'Площадка', 'disabled' => true, 'value' => $product_sku->order->common_name])
                @include('partials.input', ['name' => 'product_name', 'title' => 'МАФ', 'disabled' => true, 'value' => $product_sku->product->common_name])
                @include('partials.input', ['name' => 'rfid', 'title' => 'RFID', 'required' => true, 'value' => $product_sku->rfid])
                @include('partials.input', ['name' => 'factory_number', 'title' => 'Номер фабрики', 'required' => true, 'value' => $product_sku->factory_number])
                @include('partials.input', ['name' => 'manufacture_date', 'title' => 'Дата производства', 'type' => 'date', 'required' => true, 'value' => $product_sku->manufacture_date])
                @include('partials.input', ['name' => 'service_life', 'title' => 'Срок службы', 'required' => true, 'type' => 'number', 'value' => $product_sku->service_life])
                @include('partials.input', ['name' => 'certificate_number', 'title' => 'Номер сертификата', 'required' => true, 'value' => $product_sku->certificate_number])
                @include('partials.input', ['name' => 'certificate_date', 'title' => 'Дата сертификата', 'type' => 'date', 'required' => true, 'value' => $product_sku->certificate_date])
                @include('partials.input', ['name' => 'certificate_issuer', 'title' => 'Орган сертификации', 'required' => true, 'value' => $product_sku->certificate_issuer])
                @include('partials.input', ['name' => 'certificate_type', 'title' => 'Вид сертификации', 'required' => true, 'value' => $product_sku->certificate_type])
                @include('partials.input', ['name' => 'statement_number', 'title' => 'Номер ведомости', 'required' => true, 'value' => $product_sku->statement_number])
                @include('partials.input', ['name' => 'statement_date', 'title' => 'Дата ведомости', 'type' => 'date', 'required' => true, 'value' => $product_sku->statement_date])
                @include('partials.input', ['name' => 'upd_number', 'title' => 'Номер УПД', 'required' => true, 'value' => $product_sku->upd_number])
                @include('partials.textarea', ['name' => 'comment', 'title' => 'Примечания', 'required' => false, 'size' => 10, 'value' => $product_sku->comment])


                <input type="hidden" name="redirect_url" value="{{ url()->previous() }}">
                @include('partials.submit', ['name' => 'Сохранить'])
            </div>
        </form>
@endsection

