<?php

return [
    "type"           => "city",
    "model"          => App\Models\City::class,
    "label"          => "Cities",
    "label_singular" => "City",
    "group"          => "locations",
    "order"          => FALSE,
    "fields"         => [
        [
            "name"          => "title",
            "label"         => "City Name",
            "type"          => "textBox",
            "maxLength"     => 150,
            "multiLanguage" => TRUE,
            "preValidation" => "strip_tags|xss_clean|trim",
            "validation"    => "required|max:150",
            "inList"        => TRUE,
            "search"        => TRUE,
            "sort"          => TRUE
        ],
        [
            "name"          => "description",
            "label"         => "Description",
            "type"          => "editor",
            "multiLanguage" => TRUE,
            "preValidation" => "xss_clean|trim",
            "validation"    => ""
        ],
        [
            "name" => "country_id",
            "label" => "Country",
            "type" => "selectBox",
            "contentType" => "country",
            "labelField" => "title",
            "validation" => "required",
            "inList"        => TRUE,
        ],
        [
            "name"  => "map_position",
            "label" => "Map position",
            "type"  => "location"
        ],
    ],
    "actions"        => [
        "edit", "order", "insert", "delete"
    ]
];
