[ 'model' => \Litecms\Contact\Models\Vendor::class, 'table' => 'litecms_contact_vendors', 'hidden'=> [], 'visible' => [], 'guarded' => ['*'], 'slugs' => ['slug' => 'name'], 'dates' => ['deleted_at', 'created_at', 'updated_at'], 'appends' => [], 'fillable' => ['name', 'contact_person', 'email', 'phone', 'fax', 'website', 'address', 'status', 'services', 'tax_registration', 'notes', 'documents', 'user_id', 'user_type'], 'translatables' => [], 'upload_folder' => 'contact/vendor', 'uploads' => [ /* 'images' => [ 'count' => 10, 'type' => 'image', ], 'file' => [ 'count' => 1, 'type' => 'file', ], */ ], 'casts' => [ 'marking' => 'array', /* 'images' => 'array', 'file' => 'array', */ ], 'revision' => [], 'perPage' => '20', 'search' => [ 'name' => 'like', 'status', ] ], 'search' => [ ], 'list' => [ [ "key" => "name", "type" => "text", "label" => 'contact::vendor.label.name', 'sort' => true, 'roles' => [], ], [ "key" => "contact_person", "type" => "text", "label" => 'contact::vendor.label.contact_person', 'sort' => true, 'roles' => [], ], [ "key" => "email", "type" => "text", "label" => 'contact::vendor.label.email', 'sort' => true, 'roles' => [], ], [ "key" => "phone", "type" => "text", "label" => 'contact::vendor.label.phone', 'sort' => true, 'roles' => [], ], [ "key" => "fax", "type" => "text", "label" => 'contact::vendor.label.fax', 'sort' => true, 'roles' => [], ], [ "key" => "website", "type" => "text", "label" => 'contact::vendor.label.website', 'sort' => true, 'roles' => [], ], [ "key" => "address", "type" => "text", "label" => 'contact::vendor.label.address', 'sort' => true, 'roles' => [], ], [ "key" => "services", "type" => "text", "label" => 'contact::vendor.label.services', 'sort' => true, 'roles' => [], ], [ "key" => "tax_registration", "type" => "text", "label" => 'contact::vendor.label.tax_registration', 'sort' => true, 'roles' => [], ], [ "key" => "notes", "type" => "text", "label" => 'contact::vendor.label.notes', 'sort' => true, 'roles' => [], ], [ "key" => "documents", "type" => "text", "label" => 'contact::vendor.label.documents', 'sort' => true, 'roles' => [], ], ], 'form' => [ [ "key" => 'name', "element" => 'text', "type" => 'text', "label" => 'contact::vendor.label.name', "placeholder" => 'contact::vendor.placeholder.name', "rules" => '', "group" => "main.main", "col" => "6", "append" => null, "prepend" => null, "roles" => [], "attributes" => [ 'wrapper' => [], "label" => [], "element" => [], ], ], [ "key" => 'contact_person', "element" => 'text', "type" => 'text', "label" => 'contact::vendor.label.contact_person', "placeholder" => 'contact::vendor.placeholder.contact_person', "rules" => '', "group" => "main.main", "col" => "6", "append" => null, "prepend" => null, "roles" => [], "attributes" => [ 'wrapper' => [], "label" => [], "element" => [], ], ], [ "key" => 'email', "element" => 'text', "type" => 'text', "label" => 'contact::vendor.label.email', "placeholder" => 'contact::vendor.placeholder.email', "rules" => '', "group" => "main.main", "col" => "6", "append" => null, "prepend" => null, "roles" => [], "attributes" => [ 'wrapper' => [], "label" => [], "element" => [], ], ], [ "key" => 'phone', "element" => 'text', "type" => 'text', "label" => 'contact::vendor.label.phone', "placeholder" => 'contact::vendor.placeholder.phone', "rules" => '', "group" => "main.main", "col" => "6", "append" => null, "prepend" => null, "roles" => [], "attributes" => [ 'wrapper' => [], "label" => [], "element" => [], ], ], [ "key" => 'fax', "element" => 'text', "type" => 'text', "label" => 'contact::vendor.label.fax', "placeholder" => 'contact::vendor.placeholder.fax', "rules" => '', "group" => "main.main", "col" => "6", "append" => null, "prepend" => null, "roles" => [], "attributes" => [ 'wrapper' => [], "label" => [], "element" => [], ], ], [ "key" => 'website', "element" => 'text', "type" => 'text', "label" => 'contact::vendor.label.website', "placeholder" => 'contact::vendor.placeholder.website', "rules" => '', "group" => "main.main", "col" => "6", "append" => null, "prepend" => null, "roles" => [], "attributes" => [ 'wrapper' => [], "label" => [], "element" => [], ], ], [ "key" => 'address', "element" => 'text', "type" => 'text', "label" => 'contact::vendor.label.address', "placeholder" => 'contact::vendor.placeholder.address', "rules" => '', "group" => "main.main", "col" => "6", "append" => null, "prepend" => null, "roles" => [], "attributes" => [ 'wrapper' => [], "label" => [], "element" => [], ], ], [ "key" => 'services', "element" => 'text', "type" => 'text', "label" => 'contact::vendor.label.services', "placeholder" => 'contact::vendor.placeholder.services', "rules" => '', "group" => "main.main", "col" => "6", "append" => null, "prepend" => null, "roles" => [], "attributes" => [ 'wrapper' => [], "label" => [], "element" => [], ], ], [ "key" => 'tax_registration', "element" => 'text', "type" => 'text', "label" => 'contact::vendor.label.tax_registration', "placeholder" => 'contact::vendor.placeholder.tax_registration', "rules" => '', "group" => "main.main", "col" => "6", "append" => null, "prepend" => null, "roles" => [], "attributes" => [ 'wrapper' => [], "label" => [], "element" => [], ], ], [ "key" => 'notes', "element" => 'text', "type" => 'text', "label" => 'contact::vendor.label.notes', "placeholder" => 'contact::vendor.placeholder.notes', "rules" => '', "group" => "main.main", "col" => "6", "append" => null, "prepend" => null, "roles" => [], "attributes" => [ 'wrapper' => [], "label" => [], "element" => [], ], ], [ "key" => 'documents', "element" => 'text', "type" => 'text', "label" => 'contact::vendor.label.documents', "placeholder" => 'contact::vendor.placeholder.documents', "rules" => '', "group" => "main.main", "col" => "6", "append" => null, "prepend" => null, "roles" => [], "attributes" => [ 'wrapper' => [], "label" => [], "element" => [], ], ], ], 'urls' => [ 'new' => [ 'url' => 'contact/vendor/new', 'method' => 'GET', ], 'create' => [ 'url' => 'contact/vendor/create', 'method' => 'GET', ], 'store' => [ 'url' => 'contact/vendor', 'method' => 'POST', ], 'update' => [ 'url' => 'contact/vendor', 'method' => 'PUT', ], 'list' => [ 'url' => 'contact/vendor', 'method' => 'GET', ], 'delete' => [ 'url' => 'contact/vendor', 'method' => 'DELETE', ], ], 'order' => [ 'created_at' => 'contact::vendor.label.created_at', 'name' => 'contact::vendor.label.name', 'status' => 'contact::vendor.label.status', ], 'groups' => [ [ 'icon' => "mdi:account-supervisor-outline", 'name' => "contact::vendor.groups.main", 'group' => "main.main", 'title' => "contact::vendor.groups.main", ], [ 'icon' => "fe:home", 'name' => "contact::vendor.groups.details", 'group' => "main.details", 'title' => "contact::vendor.groups.details", ], 'images' => [ 'icon' => "fe:home", 'name' => "contact::vendor.groups.images", 'group' => "main.images", 'title' => "contact::vendor.groups.images", ], 'settings' => [ 'icon' => "fe:home", 'name' => "contact::vendor.groups.settings", 'group' => "main.settings", 'title' => "contact::vendor.groups.settings", ] ], 'controller' => [ 'provider' => 'Litecms', 'package' => 'Contact', 'module' => 'Vendor', ], 'workflow' => [ 'type' => 'workflow', 'marking_store' => [ 'type' => 'multiple_state', 'arguments' => ['status'], // 'property' => 'status' ], 'supports' => [ \Litecms\Contact\Models\Vendor::class, ], 'places' => [ 'Draft', 'Pending', 'Approved', 'Closed', 'Published', 'Archived', 'Unpublished', ], 'initial_places' => ['Draft'], 'transitions' => [ 'submit' => [ 'from' => 'Draft', 'to' => 'Pending', 'metadata' => [ 'roles' => [ 'user' => ['*'], ], 'rules' => [ 'name' => 'required', ] ], ], 'reject' => [ 'from' => 'Pending', 'to' => 'Draft', 'metadata' => [ 'roles' => [ 'user' => ['superuser'], 'team' => ['admin', 'manager'], ], 'form' => [ 'title' => 'Reject', 'button' => [ 'cancel' > [ 'icon' > '', 'varient' > '', 'label' > 'Cancel' ], 'submit' > [ 'icon' > '', 'varient' > 'primary', 'label' > 'Reject' ] ], 'fields' => [ 'count' => [ "element" => 'select', "type" => 'select', "label" => 'advert::advert.label.count', "placeholder" => 'advert::advert.placeholder.count', "options" => call_user_func(function () { return [ 1 => ['value' => 1, 'text' => 1], 2 => ['value' => 2, 'text' => 2], 3 => ['value' => 3, 'text' => 3], 4 => ['value' => 4, 'text' => 4], ]; }), "col" => "12", ], 'comment' => [ "element" => 'textarea', "type" => 'text', "required" => 'required', "label" => 'advert::advert.label.comment', "placeholder" => 'advert::advert.placeholder.comment', "col" => "12", ], ], ], ], ], 'approve' => [ 'from' => 'Pending', 'to' => 'Approved', 'metadata' => [ 'roles' => [ 'user' => ['superuser'], 'team' => ['admin', 'manager'], ] ], ], 'publish' => [ 'from' => ['Approved', 'Unpublished'], 'to' => 'Published', 'metadata' => [ 'roles' => [ 'user' => ['superuser'], 'team' => ['admin'], ] ], ], 'unpublish' => [ 'from' => ['Published'], 'to' => 'Unpublished', 'metadata' => [ 'roles' => [ 'user' => ['superuser', 'admin'], 'team' => ['admin'], ] ], ], 'archive' => [ 'from' => ['Published', 'Unpublished'], 'to' => 'Archived', 'metadata' => [ 'roles' => [ 'user' => ['superuser', 'admin'], 'team' => ['admin'], ] ], ], 'unarchive' => [ 'from' => ['Archived'], 'to' => 'Draft', 'metadata' => [ 'roles' => [ 'user' => ['superuser', 'admin'], 'team' => ['admin'], ] ], ], ], ], 'actions' => [ 'copy' => [ 'type' => ['Details', 'List'], 'label' => 'contact::vendor.action.copy', 'roles' => [ 'user' => ['superuser', 'admin'], 'team' => ['admin'], 'permission' => ['contact.vendor.copy', 'contact.vendor.duplicate'], ], 'form' => [ 'count' => [ "element" => 'select', "type" => 'select', "label" => 'contact::vendor.label.count', "placeholder" => 'contact::vendor.placeholder.count', "options" => call_user_func(function () { return [ 1 => ['value' => 1, 'text' => 1], 2 => ['value' => 2, 'text' => 2], 3 => ['value' => 3, 'text' => 3], 4 => ['value' => 4, 'text' => 4], ]; }), "col" => "12", ], 'comment' => [ "element" => 'textarea', "type" => 'text', "required" => 'required', "label" => 'contact::vendor.label.comment', "placeholder" => 'contact::vendor.placeholder.comment', "col" => "12", ], ], ], 'empty' => [ 'type' => ['List', 'Details'], 'label' => 'contact::vendor.action.empty', 'roles' => [ 'user' => ['superuser'], ], ], 'section' => [ 'type' => ['Group'], 'api_url' => '', 'action' => 'list', 'label' => 'contact::vendor.action.section', 'store' => 'main.units', 'group' => 'main.units' ], ] ];