setForm(); } /** * Return form elements. * * @return array. */ public function form($element = 'fields', $grouped = true) { $item = collect($this->form->get($element)); if ($element == 'fields' && $grouped == true) { return $item->groupBy(['group', 'section']); } return $item; } /** * Sets the form and form elements. * @return null. */ public function setForm() { $this->form = collect([ 'form' => [ 'store' => [], 'update' => [], ], 'groups' => [ 'main' => 'Main', ], 'fields' => [ 'name' => [ "type" => 'text', "label" => trans('eurolloyds::object.label.name'), "placeholder" => trans('eurolloyds::object.placeholder.name'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'title' => [ "type" => 'text', "label" => trans('eurolloyds::object.label.title'), "placeholder" => trans('eurolloyds::object.placeholder.title'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'type' => [ "type" => 'numeric', "label" => trans('eurolloyds::object.label.type'), "placeholder" => trans('eurolloyds::object.placeholder.type'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'organizer' => [ "type" => 'text', "label" => trans('eurolloyds::object.label.organizer'), "placeholder" => trans('eurolloyds::object.placeholder.organizer'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'brand_id' => [ "type" => 'numeric', "label" => trans('eurolloyds::object.label.brand_id'), "placeholder" => trans('eurolloyds::object.placeholder.brand_id'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'attributes' => [ "type" => 'numeric', "label" => trans('eurolloyds::object.label.attributes'), "placeholder" => trans('eurolloyds::object.placeholder.attributes'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'categories' => [ "type" => 'numeric', "label" => trans('eurolloyds::object.label.categories'), "placeholder" => trans('eurolloyds::object.placeholder.categories'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'stars' => [ "type" => 'numeric', "label" => trans('eurolloyds::object.label.stars'), "placeholder" => trans('eurolloyds::object.placeholder.stars'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'booking_link' => [ "type" => 'text', "label" => trans('eurolloyds::object.label.booking_link'), "placeholder" => trans('eurolloyds::object.placeholder.booking_link'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'duration' => [ "type" => 'text', "label" => trans('eurolloyds::object.label.duration'), "placeholder" => trans('eurolloyds::object.placeholder.duration'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'price' => [ "type" => 'numeric', "label" => trans('eurolloyds::object.label.price'), "placeholder" => trans('eurolloyds::object.placeholder.price'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'flights_details' => [ "type" => 'text', "label" => trans('eurolloyds::object.label.flights_details'), "placeholder" => trans('eurolloyds::object.placeholder.flights_details'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'country' => [ "type" => 'numeric', "label" => trans('eurolloyds::object.label.country'), "placeholder" => trans('eurolloyds::object.placeholder.country'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'region_city_spot' => [ "type" => 'text', "label" => trans('eurolloyds::object.label.region_city_spot'), "placeholder" => trans('eurolloyds::object.placeholder.region_city_spot'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'degree' => [ "type" => 'package::package.formcontrols.of', "label" => trans('eurolloyds::object.label.degree'), "placeholder" => trans('eurolloyds::object.placeholder.degree'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], '11)' => [ "type" => 'package::package.formcontrols.DEFAULT', "label" => trans('eurolloyds::object.label.11)'), "placeholder" => trans('eurolloyds::object.placeholder.11)'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'degree' => [ "type" => 'package::package.formcontrols.of', "label" => trans('eurolloyds::object.label.degree'), "placeholder" => trans('eurolloyds::object.placeholder.degree'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], '11)' => [ "type" => 'package::package.formcontrols.DEFAULT', "label" => trans('eurolloyds::object.label.11)'), "placeholder" => trans('eurolloyds::object.placeholder.11)'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'zoom' => [ "type" => 'numeric', "label" => trans('eurolloyds::object.label.zoom'), "placeholder" => trans('eurolloyds::object.placeholder.zoom'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'club_details' => [ "type" => 'text', "label" => trans('eurolloyds::object.label.club_details'), "placeholder" => trans('eurolloyds::object.placeholder.club_details'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'leisure' => [ "type" => 'package::package.formcontrols.offers', "label" => trans('eurolloyds::object.label.leisure'), "placeholder" => trans('eurolloyds::object.placeholder.leisure'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'our_privileges' => [ "type" => 'text', "label" => trans('eurolloyds::object.label.our_privileges'), "placeholder" => trans('eurolloyds::object.placeholder.our_privileges'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'image' => [ "type" => 'text', "label" => trans('eurolloyds::object.label.image'), "placeholder" => trans('eurolloyds::object.placeholder.image'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'description' => [ "type" => 'text', "label" => trans('eurolloyds::object.label.description'), "placeholder" => trans('eurolloyds::object.placeholder.description'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'keywords' => [ "type" => 'text', "label" => trans('eurolloyds::object.label.keywords'), "placeholder" => trans('eurolloyds::object.placeholder.keywords'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], ] ); } }