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' => [ 'category_id' => [ "type" => 'numeric', "label" => trans('listing::listing.label.category_id'), "placeholder" => trans('listing::listing.placeholder.category_id'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'contact_id' => [ "type" => 'numeric', "label" => trans('listing::listing.label.contact_id'), "placeholder" => trans('listing::listing.placeholder.contact_id'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'agent_id' => [ "type" => 'numeric', "label" => trans('listing::listing.label.agent_id'), "placeholder" => trans('listing::listing.placeholder.agent_id'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'teamlead_id' => [ "type" => 'numeric', "label" => trans('listing::listing.label.teamlead_id'), "placeholder" => trans('listing::listing.placeholder.teamlead_id'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'hot' => [ "type" => 'checkboxes', "label" => trans('listing::listing.label.hot'), "placeholder" => trans('listing::listing.placeholder.hot'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'exclusive' => [ "type" => 'checkboxes', "label" => trans('listing::listing.label.exclusive'), "placeholder" => trans('listing::listing.placeholder.exclusive'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'name' => [ "type" => 'text', "label" => trans('listing::listing.label.name'), "placeholder" => trans('listing::listing.placeholder.name'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'ref' => [ "type" => 'text', "label" => trans('listing::listing.label.ref'), "placeholder" => trans('listing::listing.placeholder.ref'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'unit' => [ "type" => 'text', "label" => trans('listing::listing.label.unit'), "placeholder" => trans('listing::listing.placeholder.unit'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'roi' => [ "type" => 'decimal', "label" => trans('listing::listing.label.roi'), "placeholder" => trans('listing::listing.placeholder.roi'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'roi_aed' => [ "type" => 'decimal', "label" => trans('listing::listing.label.roi_aed'), "placeholder" => trans('listing::listing.placeholder.roi_aed'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'country_id' => [ "type" => 'numeric', "label" => trans('listing::listing.label.country_id'), "placeholder" => trans('listing::listing.placeholder.country_id'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'state_id' => [ "type" => 'numeric', "label" => trans('listing::listing.label.state_id'), "placeholder" => trans('listing::listing.placeholder.state_id'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'location_id' => [ "type" => 'numeric', "label" => trans('listing::listing.label.location_id'), "placeholder" => trans('listing::listing.placeholder.location_id'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'sublocation_id' => [ "type" => 'numeric', "label" => trans('listing::listing.label.sublocation_id'), "placeholder" => trans('listing::listing.placeholder.sublocation_id'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'property_id' => [ "type" => 'numeric', "label" => trans('listing::listing.label.property_id'), "placeholder" => trans('listing::listing.placeholder.property_id'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'beds' => [ "type" => 'text', "label" => trans('listing::listing.label.beds'), "placeholder" => trans('listing::listing.placeholder.beds'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'fitted' => [ "type" => 'numeric', "label" => trans('listing::listing.label.fitted'), "placeholder" => trans('listing::listing.placeholder.fitted'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'building_type' => [ "type" => 'text', "label" => trans('listing::listing.label.building_type'), "placeholder" => trans('listing::listing.placeholder.building_type'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'handover_date' => [ "type" => 'date_picker', "label" => trans('listing::listing.label.handover_date'), "placeholder" => trans('listing::listing.placeholder.handover_date'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'baths' => [ "type" => 'text', "label" => trans('listing::listing.label.baths'), "placeholder" => trans('listing::listing.placeholder.baths'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'furnished' => [ "type" => 'text', "label" => trans('listing::listing.label.furnished'), "placeholder" => trans('listing::listing.placeholder.furnished'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'view' => [ "type" => 'text', "label" => trans('listing::listing.label.view'), "placeholder" => trans('listing::listing.placeholder.view'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'bua' => [ "type" => 'numeric', "label" => trans('listing::listing.label.bua'), "placeholder" => trans('listing::listing.placeholder.bua'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'price' => [ "type" => 'numeric', "label" => trans('listing::listing.label.price'), "placeholder" => trans('listing::listing.placeholder.price'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'interest_rate' => [ "type" => 'numeric', "label" => trans('listing::listing.label.interest_rate'), "placeholder" => trans('listing::listing.placeholder.interest_rate'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'down_payment' => [ "type" => 'decimal', "label" => trans('listing::listing.label.down_payment'), "placeholder" => trans('listing::listing.placeholder.down_payment'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'emi_years' => [ "type" => 'numeric', "label" => trans('listing::listing.label.emi_years'), "placeholder" => trans('listing::listing.placeholder.emi_years'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'emi' => [ "type" => 'decimal', "label" => trans('listing::listing.label.emi'), "placeholder" => trans('listing::listing.placeholder.emi'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'est_rental' => [ "type" => 'decimal', "label" => trans('listing::listing.label.est_rental'), "placeholder" => trans('listing::listing.placeholder.est_rental'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'original_price' => [ "type" => 'text', "label" => trans('listing::listing.label.original_price'), "placeholder" => trans('listing::listing.placeholder.original_price'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'plot' => [ "type" => 'text', "label" => trans('listing::listing.label.plot'), "placeholder" => trans('listing::listing.placeholder.plot'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'units' => [ "type" => 'select', "label" => trans('listing::listing.label.units'), "placeholder" => trans('listing::listing.placeholder.units'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'currency' => [ "type" => 'text', "label" => trans('listing::listing.label.currency'), "placeholder" => trans('listing::listing.placeholder.currency'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'poa' => [ "type" => 'numeric', "label" => trans('listing::listing.label.poa'), "placeholder" => trans('listing::listing.placeholder.poa'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'frequency' => [ "type" => 'select', "label" => trans('listing::listing.label.frequency'), "placeholder" => trans('listing::listing.placeholder.frequency'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'cheques' => [ "type" => 'numeric', "label" => trans('listing::listing.label.cheques'), "placeholder" => trans('listing::listing.placeholder.cheques'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'parking' => [ "type" => 'numeric', "label" => trans('listing::listing.label.parking'), "placeholder" => trans('listing::listing.placeholder.parking'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'description' => [ "type" => 'text', "label" => trans('listing::listing.label.description'), "placeholder" => trans('listing::listing.placeholder.description'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'documents' => [ "type" => 'files', "label" => trans('listing::listing.label.documents'), "placeholder" => trans('listing::listing.placeholder.documents'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'photos' => [ "type" => 'images', "label" => trans('listing::listing.label.photos'), "placeholder" => trans('listing::listing.placeholder.photos'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'floor_plans' => [ "type" => 'text', "label" => trans('listing::listing.label.floor_plans'), "placeholder" => trans('listing::listing.placeholder.floor_plans'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'commission' => [ "type" => 'decimal', "label" => trans('listing::listing.label.commission'), "placeholder" => trans('listing::listing.placeholder.commission'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'commission_aed' => [ "type" => 'decimal', "label" => trans('listing::listing.label.commission_aed'), "placeholder" => trans('listing::listing.placeholder.commission_aed'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'deposit' => [ "type" => 'decimal', "label" => trans('listing::listing.label.deposit'), "placeholder" => trans('listing::listing.placeholder.deposit'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'deposit_aed' => [ "type" => 'decimal', "label" => trans('listing::listing.label.deposit_aed'), "placeholder" => trans('listing::listing.placeholder.deposit_aed'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'portals' => [ "type" => 'text', "label" => trans('listing::listing.label.portals'), "placeholder" => trans('listing::listing.placeholder.portals'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'other_medias' => [ "type" => 'text', "label" => trans('listing::listing.label.other_medias'), "placeholder" => trans('listing::listing.placeholder.other_medias'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'features' => [ "type" => 'text', "label" => trans('listing::listing.label.features'), "placeholder" => trans('listing::listing.placeholder.features'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'amenities' => [ "type" => 'text', "label" => trans('listing::listing.label.amenities'), "placeholder" => trans('listing::listing.placeholder.amenities'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'area_informations' => [ "type" => 'text', "label" => trans('listing::listing.label.area_informations'), "placeholder" => trans('listing::listing.placeholder.area_informations'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'featured' => [ "type" => 'select', "label" => trans('listing::listing.label.featured'), "placeholder" => trans('listing::listing.placeholder.featured'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'dewa_no' => [ "type" => 'text', "label" => trans('listing::listing.label.dewa_no'), "placeholder" => trans('listing::listing.placeholder.dewa_no'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'str' => [ "type" => 'text', "label" => trans('listing::listing.label.str'), "placeholder" => trans('listing::listing.placeholder.str'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'source_listing' => [ "type" => 'text', "label" => trans('listing::listing.label.source_listing'), "placeholder" => trans('listing::listing.placeholder.source_listing'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'next_available' => [ "type" => 'date_picker', "label" => trans('listing::listing.label.next_available'), "placeholder" => trans('listing::listing.placeholder.next_available'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'notes' => [ "type" => 'text', "label" => trans('listing::listing.label.notes'), "placeholder" => trans('listing::listing.placeholder.notes'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'additional_info' => [ "type" => 'text', "label" => trans('listing::listing.label.additional_info'), "placeholder" => trans('listing::listing.placeholder.additional_info'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'key_location' => [ "type" => 'text', "label" => trans('listing::listing.label.key_location'), "placeholder" => trans('listing::listing.placeholder.key_location'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'tenanted' => [ "type" => 'select', "label" => trans('listing::listing.label.tenanted'), "placeholder" => trans('listing::listing.placeholder.tenanted'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'rented_at' => [ "type" => 'text', "label" => trans('listing::listing.label.rented_at'), "placeholder" => trans('listing::listing.placeholder.rented_at'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'rented_until' => [ "type" => 'date_picker', "label" => trans('listing::listing.label.rented_until'), "placeholder" => trans('listing::listing.placeholder.rented_until'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'maintenance_fee' => [ "type" => 'text', "label" => trans('listing::listing.label.maintenance_fee'), "placeholder" => trans('listing::listing.placeholder.maintenance_fee'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'price_sqft' => [ "type" => 'decimal', "label" => trans('listing::listing.label.price_sqft'), "placeholder" => trans('listing::listing.placeholder.price_sqft'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'meta_keyword' => [ "type" => 'text', "label" => trans('listing::listing.label.meta_keyword'), "placeholder" => trans('listing::listing.placeholder.meta_keyword'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'meta_description' => [ "type" => 'text', "label" => trans('listing::listing.label.meta_description'), "placeholder" => trans('listing::listing.placeholder.meta_description'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'viewings' => [ "type" => 'numeric', "label" => trans('listing::listing.label.viewings'), "placeholder" => trans('listing::listing.placeholder.viewings'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'published' => [ "type" => 'select', "label" => trans('listing::listing.label.published'), "placeholder" => trans('listing::listing.placeholder.published'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'owner_signed' => [ "type" => 'select', "label" => trans('listing::listing.label.owner_signed'), "placeholder" => trans('listing::listing.placeholder.owner_signed'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'property_type' => [ "type" => 'text', "label" => trans('listing::listing.label.property_type'), "placeholder" => trans('listing::listing.placeholder.property_type'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'distributed_area' => [ "type" => 'select', "label" => trans('listing::listing.label.distributed_area'), "placeholder" => trans('listing::listing.placeholder.distributed_area'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'property_status' => [ "type" => 'select', "label" => trans('listing::listing.label.property_status'), "placeholder" => trans('listing::listing.placeholder.property_status'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'rera' => [ "type" => 'text', "label" => trans('listing::listing.label.rera'), "placeholder" => trans('listing::listing.placeholder.rera'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'referal_agents' => [ "type" => 'text', "label" => trans('listing::listing.label.referal_agents'), "placeholder" => trans('listing::listing.placeholder.referal_agents'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'referal_percentage' => [ "type" => 'numeric', "label" => trans('listing::listing.label.referal_percentage'), "placeholder" => trans('listing::listing.placeholder.referal_percentage'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'property_use' => [ "type" => 'select', "label" => trans('listing::listing.label.property_use'), "placeholder" => trans('listing::listing.placeholder.property_use'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'developer_unit' => [ "type" => 'text', "label" => trans('listing::listing.label.developer_unit'), "placeholder" => trans('listing::listing.placeholder.developer_unit'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'published_date' => [ "type" => 'date_picker', "label" => trans('listing::listing.label.published_date'), "placeholder" => trans('listing::listing.placeholder.published_date'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'lat' => [ "type" => 'text', "label" => trans('listing::listing.label.lat'), "placeholder" => trans('listing::listing.placeholder.lat'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], 'lng' => [ "type" => 'text', "label" => trans('listing::listing.label.lng'), "placeholder" => trans('listing::listing.placeholder.lng'), "rules" => '', "group" => "main", "section" => "first", "attributes" => [ 'wrapper' => [], "label" => [], "input" => [], ], ], ] ); } }