File: /var/www/ivs.kaunokolegija.lt/laravel/storage/framework/views/d16c8e0004e7c0eba5f0d5c1132ae62a.php
<div class="form-group">
<label class="required" for="name"><?php echo e(trans('cruds.departmentSubsection.fields.name')); ?></label>
<input class="form-control <?php echo e($errors->has('name') ? 'is-invalid' : ''); ?>" type="text" name="name" id="name" value="<?php echo e(old('name', '')); ?>" required>
<?php if($errors->has('name')): ?>
<span class="text-danger"><?php echo e($errors->first('name')); ?></span>
<?php endif; ?>
<span class="help-block"><?php echo e(trans('cruds.departmentSubsection.fields.name_helper')); ?></span>
</div>
<div class="form-group">
<label for="department_id"><?php echo e(trans('cruds.departmentSubsection.fields.department')); ?></label>
<div class="d-flex align-items-center">
<select class="form-control select2 <?php echo e($errors->has('department') ? 'is-invalid' : ''); ?>" name="department_id" id="department_id">
<?php $__currentLoopData = $departments; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $id => $entry): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
<option value="<?php echo e($entry->id); ?>" <?php echo e(old('department_id') == $id ? 'selected' : ''); ?>><?php echo e(is_object($entry) ? $entry->name : $entry); ?></option>
<?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
</select>
<?php if (app(\Illuminate\Contracts\Auth\Access\Gate::class)->check('department_create')): ?>
<?php if($nameModal): ?>
<?php if (isset($component)) { $__componentOriginal863456d2b7044be7ea705fd9162e9dfc = $component; } ?>
<?php if (isset($attributes)) { $__attributesOriginal863456d2b7044be7ea705fd9162e9dfc = $attributes; } ?>
<?php $component = App\View\Components\Modal\CreateNameModal::resolve(['compName' => 'Department','name' => 'name','label' => ''.e(trans('cruds.department.fields.name')).'','route' => ''.e(route('admin.departments.store')).''] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?>
<?php $component->withName('modal.create-name-modal'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Modal\CreateNameModal::class))->getConstructor()): ?>
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
<?php endif; ?>
<?php $component->withAttributes([]); ?>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__attributesOriginal863456d2b7044be7ea705fd9162e9dfc)): ?>
<?php $attributes = $__attributesOriginal863456d2b7044be7ea705fd9162e9dfc; ?>
<?php unset($__attributesOriginal863456d2b7044be7ea705fd9162e9dfc); ?>
<?php endif; ?>
<?php if (isset($__componentOriginal863456d2b7044be7ea705fd9162e9dfc)): ?>
<?php $component = $__componentOriginal863456d2b7044be7ea705fd9162e9dfc; ?>
<?php unset($__componentOriginal863456d2b7044be7ea705fd9162e9dfc); ?>
<?php endif; ?>
<?php endif; ?>
<?php if($modalBtn): ?>
<button type="button" data-select-id="department_id" class="btn btn-outline-primary ms-2" id="openDepartmentModal">
<i class="fa fa-plus"></i>
</button>
<?php endif; ?>
<?php endif; ?>
<?php if($errors->has('department')): ?>
<span class="text-danger"><?php echo e($errors->first('department')); ?></span>
<?php endif; ?>
<span class="help-block"><?php echo e(trans('cruds.departmentSubsection.fields.department_helper')); ?></span>
</div>
</div> <?php /**PATH /var/www/ivs.kaunokolegija.lt/laravel/resources/views/admin/departmentSubsections/departament-subsection-fields.blade.php ENDPATH**/ ?>