@extends('admin.layout.base') @section('content') @php $form = new \App\Http\Controllers\FormCtrl(); @endphp

@if($object == NULL) Crea @else Modifica @endif Unity

  TORNA ALL'ELENCO @if($object != NULL && isset($object->path)) PAGINA PUBBLICA @endif @if($object != NULL)   GESTIONE CONTENUTI @endif
@if(isset($_REQUEST['error']))
Attenzione Il titolo della unity è già stato utilizzato.
@endif @if(count($languages) > 0) @if(count($languages) > 1) @endif @for($l = 0; $l < count($languages); $l++) @php $lang_id = $languages[$l]->id; $boxlang = NULL; if($object != NULL && $l > 0) { $boxlang = isset($object->translations[$lang_id]) ? $object->translations[$lang_id] : NULL; } else if($object != NULL) $boxlang = $object; $boxClass = (!$languages[$l]->selected ? " displaynone" : ""); @endphp @if(count($languages) > 1)
@endif @php $value = str_replace('"', '"', ($boxlang != NULL ? $boxlang->title : '')); echo $form->insertTextInputField("Titolo", "title_".$lang_id, $value, "", "#555", ($l == 0), 0, 0, 255); $value = str_replace('"', '"', ($boxlang != NULL ? $boxlang->didascalia : '')); echo $form->insertTextareaInputField("Didascalia", "didascalia_".$lang_id, $value, "", "#666666", ($l == 0), 0, 0, 1000, false, false, false); $value = str_replace('"', '"', (($boxlang != NULL) ? $boxlang->alt_cover : '')); echo $form->insertTextInputField("Alt cover", "alt_cover_".$lang_id, $value, "", "#555", false, 0, 0, 155); @endphp @if(count($languages) > 1)
@endif @endfor @endif
@include('admin.page.form.file', array( 'index' => 1, 'placeholder' => 'Cover', 'field' => 'cover', 'base_img_url' => asset('img/unity/cover/'), 'singleimage' => true, 'dimension' => 'W: 800', 'extensions' => 'jpg, jpeg, gif, png' ))
@include('admin.page.form.file', array( 'index' => 2, 'placeholder' => 'Loghi', 'field' => 'loghi', 'direct_filelist' => $object != NULL ? $object->loghi : array(), 'base_img_url' => asset('img/unity/loghi/'), 'singleimage' => false, 'dimension' => 'W: 200', 'extensions' => 'jpg, jpeg, gif, png', 'fieldstatus' => 0, ))
@php $element = array(); $obj = (object)[]; $obj->checked = ($object == NULL || ($object != NULL && $object->published == 1)); $obj->value = 1; $obj->text = "Selezione per abilitare la visualizzazione della unity"; array_push($element, $obj); echo $form->insertCheckboxGroup(" ", "published", $element, 0, count($element), 0, false, true, true, true); @endphp
@stop