@extends('admins.layouts.index') @section('content') {!! Form::model($model, ['method'=>'post','class'=>'form-horizontal','files'=>true]) !!}
@foreach(App\Translation::get_lang_array() as $index => $row) @php $data = $model->getFormTranslation($row->lang); @endphp
{{ __('Basic Information') }}
{!! Form::label('locale['.$row->lang.'][title]', __('Title'), ['class'=>'col-sm-3 col-form-label text-right']) !!}
{!! Form::text('locale['.$row->lang.'][title]', $model->id ? (isset($data['title']) ? $data['title']:null):null, ['id'=>'locale['.$row->lang.'][title]','class'=>'form-control '.($errors->first('locale.*.title') ? 'is-invalid' : ''), $index == 0 ? 'autofocus':'']) !!} {!!$errors->first('locale.*.title', ':message')!!}
{!! Form::label('locale['.$row->lang.'][description]', __('Description'), ['class'=>'col-sm-2 col-form-label text-right']) !!}
{!! Form::text('locale['.$row->lang.'][description]', $model->id ? (isset($data['description']) ? $data['description']:null):null, ['id'=>'locale['.$row->lang.'][description]','class'=>'form-control '.($errors->first('locale.*.description') ? 'is-invalid' : ''), $index == 0 ? 'autofocus':'']) !!} {!!$errors->first('locale.*.description', ':message')!!}
{!! Form::label('locale['.$row->lang.'][link_url]', __('Link Url'), ['class'=>'col-sm-3 col-form-label text-right']) !!}
{!! Form::text('locale['.$row->lang.'][link_url]', $model->id ? (isset($data['link_url']) ? $data['link_url']:null):null, ['id'=>'locale['.$row->lang.'][link_url]','class'=>'form-control '.($errors->first('locale.*.link_url') ? 'is-invalid' : ''), $index == 0 ? 'autofocus':'']) !!} {!!$errors->first('locale.*.link_url', ':message')!!}
@endforeach

{{__('Basic Information')}}

@if($model->image_path)
@endif
{!! Form::label('image_path', __('Image'), ['class'=>'col-sm-4 col-form-label text-right']) !!}
{!! Form::file('image_path', ['id'=>'image_path','class'=>'form-control '.($errors->first('image_path') ? 'is-invalid' : ''),'placeholder'=>__('Image')]) !!} {!!$errors->first('image_path', ':message')!!}
{{ __('Text Align') }}
{!! Form::radio('text_align', App\Banner::text_align_left, true, ['id'=>'left','class'=>'form-check-input']) !!}
{!! Form::radio('text_align', App\Banner::text_align_center, false, ['id'=>'center','class'=>'form-check-input']) !!}
{!! Form::radio('text_align', App\Banner::text_align_right, false, ['id'=>'right','class'=>'form-check-input']) !!}
{{ __('Status') }}
{!! Form::radio('status', 1, true, ['id'=>'yes','class'=>'form-check-input']) !!}
{!! Form::radio('status', 0, false, ['id'=>'no','class'=>'form-check-input']) !!}
{!! Form::close() !!} @endsection @section('script') @endsection