@extends('layouts.app') @section('content')

{{ $contractor ? 'Редактирование подрядчика' : 'Добавление подрядчика' }}

@if(session('success')) @endif @if(session('contractor_import_errors')) @endif @if($errors->any()) @endif
@csrf @include('partials.input', ['name' => 'name', 'title' => 'Наименование подрядчика', 'required' => true, 'value' => $contractor->name ?? '']) @include('partials.input', ['name' => 'legal_name', 'title' => 'Юридическое имя', 'required' => true, 'value' => $contractor->legal_name ?? '']) @include('partials.input', ['name' => 'contract_number', 'title' => '№ договора', 'required' => true, 'value' => $contractor->contract_number ?? '']) @include('partials.input', ['name' => 'contract_date', 'title' => 'Дата договора', 'type' => 'date', 'required' => true, 'value' => optional($contractor?->contract_date)->format('Y-m-d')]) @include('partials.input', ['name' => 'director_name', 'title' => 'ФИО руководителя', 'required' => true, 'value' => $contractor->director_name ?? '']) @include('partials.select', ['name' => 'organization_form', 'title' => 'Форма организации', 'required' => true, 'options' => $organizationForms, 'value' => $contractor->organization_form ?? null, 'first_empty' => true]) @include('partials.select', ['name' => 'tax_rate', 'title' => 'Налог', 'required' => true, 'options' => $taxRates, 'value' => $contractor->tax_rate ?? null, 'first_empty' => true]) @include('partials.textarea', ['name' => 'contract_header', 'title' => 'Шапка в договоре', 'required' => true, 'size' => 8, 'value' => $contractor->contract_header ?? ''])
hidden ?? false))>
@include('partials.submit', ['name' => 'Сохранить', 'back_url' => $back_url ?? route('contractors.index')])
@if($contractor)
Год каталога: {{ $catalogYear }}
@csrf
@foreach($priceRows as $row) @php $product = $row['product']; $price = $row['price']; @endphp @endforeach
Картинка МАФ Артикул МАФ Номер номенклатуры Наименование по спецификации Цена монтажа Статус
@if($product->image) @endif {{ $product->article }} {{ $product->nomenclature_number }} {{ $price?->name_in_spec }} {{ $price?->price_txt ?? '0.00₽' }} @if($row['available']) Доступен @else МАФ недоступен @endif
@endif
@endsection @push('scripts') @endpush