@extends('admin.layouts.master') @section('content')

{{ trans('quickadmin::qa.menus-createCrud-create_new_crud') }}

@if ($errors->any())
    {!! implode('', $errors->all('
  • :message
  • ')) !!}
@endif
{!! Form::open(['class' => 'form-horizontal']) !!}
{!! Form::label('parent_id', trans('quickadmin::qa.menus-createCrud-crud_parent'), ['class'=>'col-sm-2 control-label']) !!}
{!! Form::select('parent_id', $parentsSelect, old('parent_id'), ['class'=>'form-control']) !!}
{!! Form::label('name', trans('quickadmin::qa.menus-createCrud-crud_name'), ['class'=>'col-sm-2 control-label']) !!}
{!! Form::text('name', old('name'), ['class'=>'form-control', 'placeholder'=> trans('quickadmin::qa.menus-createCrud-crud_name_placeholder')]) !!}
{!! Form::label('title', trans('quickadmin::qa.menus-createCrud-crud_title'), ['class'=>'col-sm-2 control-label']) !!}
{!! Form::text('title', old('title'), ['class'=>'form-control', 'placeholder'=> trans('quickadmin::qa.menus-createCrud-crud_title_placeholder')]) !!}
{!! Form::label('roles', trans('quickadmin::qa.menus-createCrud-roles'), ['class'=>'col-sm-2 control-label']) !!}
@foreach($roles as $role)
@endforeach
{!! Form::label('soft', trans('quickadmin::qa.menus-createCrud-soft_delete'), ['class'=>'col-sm-2 control-label']) !!}
{!! Form::select('soft', [1 => trans('quickadmin::strings.yes'), 0 => trans('quickadmin::strings.no')], old('soft'), ['class' => 'form-control']) !!}
{!! Form::label('icon', trans('quickadmin::qa.menus-createCrud-icon'), ['class'=>'col-sm-2 control-label']) !!}
{!! Form::text('icon', old('icon','fa-database'), ['class'=>'form-control', 'placeholder'=> trans('quickadmin::qa.menus-createCrud-icon_placeholder')]) !!}

{{ trans('quickadmin::qa.menus-createCrud-add_fields') }}

@if(old('f_type')) @foreach(old('f_type') as $index => $fieldName) @include('tpl::menu_field_line', ['index' => $index]) @endforeach @else @include('tpl::menu_field_line', ['index' => '']) @endif
{{ trans('quickadmin::qa.menus-createCrud-show_in_list') }}

{!! Form::submit(trans('quickadmin::qa.menus-createCrud-create_crud'), ['class' => 'btn btn-primary']) !!}
{!! Form::close() !!}
@include('tpl::menu_field_line', ['index' => ''])
@foreach($models as $key => $model) @endforeach
@endsection @section('javascript') @stop