@extends('layouts.publicador.novo_padrao') @section('content')

@lang('labels.escola_legislativo') / @choice('labels.noticias', 0) {{ empty($model->id) ? __('labels.acoes.adicionar') : __('labels.acoes.alterar') }}

@if ($errors->any())
@lang('labels.msg.verifique')
@endif @if (empty($model)) {!! Form::open(['route' => ['publicador.escola.noticias.salvar'], 'class' => 'form form-edit']) !!} @else {!! Form::model($model, ['route' => ['publicador.escola.noticias.salvar'], 'method' => 'put']) !!} {{ Form::hidden('id') }} @endif
{{-- DESTAQUE --}}
{{ Form::label('destaque', trans_choice('labels.destaques', 1)) }}
{{ Form::select('destaque', \Config::get('constants.boolean'), null, ['class' => ' form-control border-left-0 ' . ($errors->has('destaque') ? 'is-invalid' : ''), 'placeholder' => __('labels.acoes.selecione')]) }} @if ($errors->has('destaque'))
{{ $errors->first('destaque') }}
@endif
{{-- PUBLICADO --}}
{{ Form::label('publicado', __('labels.publicado')) }}
{{ Form::select('publicado', \Config::get('constants.boolean'), null, ['class' => ' form-control border-left-0 ' . ($errors->has('publicado') ? 'is-invalid' : ''), 'placeholder' => __('labels.acoes.selecione')]) }} @if ($errors->has('publicado'))
{{ $errors->first('publicado') }}
@endif
{{-- DATA PUBLICACAO --}}
{{ Form::label('data_publicacao', __('labels.data_publicacao')) }}
{{ Form::text('data_publicacao', empty($model) ? \Carbon\Carbon::now()->format('d/m/Y H:i') : $model->data_publicacao->format('d/m/Y H:i'), ['class' => 'data_publicacao form-control border-left-0 ' . ($errors->has('data_publicacao') ? 'is-invalid' : ''), 'placeholder' => __('labels.data_publicacao')]) }} @if ($errors->has('data_publicacao'))
{{ $errors->first('data_publicacao') }}
@endif
{{-- TITULO --}}
{{ Form::label('titulo', __('labels.titulo')) }}
{{ Form::text('titulo', null, ['class' => 'form-control border-left-0 ' . ($errors->has('titulo') ? 'is-invalid' : ''), 'maxlength' => 250, 'placeholder' => __('labels.titulo')]) }} @if ($errors->has('titulo'))
{{ $errors->first('titulo') }}
@endif
{{-- IMAGEM DESTAQUE --}}
{{ Form::label('imagem_id', sprintf('%s %s', trans_choice('labels.imagens', 1), trans_choice('labels.destaques', 1))) }}
{{ Form::select('imagem_id', $imagens, null, ['class' => 'form-control border-left-0 ' . ($errors->has('imagem_id') ? 'is-invalid' : ''), 'placeholder' => __('labels.acoes.selecione')]) }} @if ($errors->has('imagem_id'))
{{ $errors->first('imagem_id') }}
@endif
{{-- IMAGEM REDE SOCIAIS --}}
{{ Form::label('imagem_redes', sprintf('%s %s', trans_choice('labels.imagens', 1), __('labels.redes_sociais'))) }}
{{ Form::select('imagem_redes', $imagens, null, ['class' => 'form-control border-left-0 ' . ($errors->has('imagem_redes') ? 'is-invalid' : ''), 'placeholder' => __('labels.acoes.selecione')]) }} @if ($errors->has('imagem_redes'))
{{ $errors->first('imagem_redes') }}
@endif
{{-- TEXTO --}}
{{ Form::label('texto', __('labels.texto')) }} {{ Form::textarea('texto', null, ['style' => 'height: 500px', 'class' => 'form-control border-left-0 ' . ($errors->has('texto') ? 'is-invalid' : ''), 'placeholder' => __('labels.texto')]) }} @if ($errors->has('texto'))
{{ $errors->first('texto') }}
@endif
{{-- PALAVRA CHAVE --}}
{{ Form::label('tags', __('labels.tags')) }}
{{ Form::text('tags', null, ['class' => 'form-control border-left-0 ' . ($errors->has('tags') ? 'is-invalid' : ''), 'maxlength' => 150, 'placeholder' => __('labels.tags')]) }} @if ($errors->has('tags'))
{{ $errors->first('tags') }}
@endif

@lang('labels.msg.separe_virgulas')

{{-- AUTOR --}}
{{ Form::label('autor', __('labels.autor')) }}
{{ Form::text('autor', null, ['class' => 'form-control border-left-0 ' . ($errors->has('autor') ? 'is-invalid' : ''), 'maxlength' => 150, 'placeholder' => __('labels.autor')]) }} @if ($errors->has('autor'))
{{ $errors->first('autor') }}
@endif
{{-- FONTE --}}
{{ Form::label('fonte', __('labels.fonte')) }}
{{ Form::text('fonte', null, ['class' => 'form-control border-left-0 ' . ($errors->has('fonte') ? 'is-invalid' : ''), 'maxlength' => 150, 'placeholder' => __('labels.fonte')]) }} @if ($errors->has('fonte'))
{{ $errors->first('fonte') }}
@endif

@lang('labels.acoes.cancelar') {{ Form::submit(__('labels.acoes.salvar'), ['class' => 'btn btn-success']) }}

{!! Form::close() !!}
@include('layouts.publicador.tinymce') @endsection