Documentation

CollectionField
in package
implements FieldInterface Uses FieldTrait

FinalYes
Tags
author

Javier Eguiluz javier.eguiluz@gmail.com

Table of Contents

Interfaces

FieldInterface

Constants

OPTION_ALLOW_ADD  = 'allowAdd'
OPTION_ALLOW_DELETE  = 'allowDelete'
OPTION_ENTRY_CRUD_CONTROLLER_FQCN  = 'entryCrudControllerFqcn'
OPTION_ENTRY_CRUD_EDIT_PAGE_NAME  = 'entryCrudEditPageName'
OPTION_ENTRY_CRUD_NEW_PAGE_NAME  = 'entryCrudNewPageName'
OPTION_ENTRY_IS_COMPLEX  = 'entryIsComplex'
OPTION_ENTRY_TYPE  = 'entryType'
OPTION_ENTRY_USES_CRUD_FORM  = 'entryUsesCrudController'
OPTION_RENDER_EXPANDED  = 'renderExpanded'
OPTION_SHOW_ENTRY_LABEL  = 'showEntryLabel'

Properties

$dto  : FieldDto

Methods

addCssClass()  : self
addCssFiles()  : self
addFormTheme()  : self
addHtmlContentsToBody()  : self
addHtmlContentsToHead()  : self
addJsFiles()  : self
addWebpackEncoreEntries()  : self
allowAdd()  : self
allowDelete()  : self
formatValue()  : self
getAsDto()  : FieldDto
hideOnDetail()  : self
hideOnForm()  : self
hideOnIndex()  : self
hideWhenCreating()  : self
hideWhenUpdating()  : self
new()  : self
onlyOnDetail()  : self
onlyOnForms()  : self
onlyOnIndex()  : self
onlyWhenCreating()  : self
onlyWhenUpdating()  : self
renderExpanded()  : self
setColumns()  : self
setCssClass()  : self
setCustomOption()  : self
setCustomOptions()  : self
setDisabled()  : self
setEmptyData()  : self
setEntryIsComplex()  : self
Set this option to TRUE if the collection items are complex form types composed of several form fields (EasyAdmin applies a special rendering to make them look better).
setEntryType()  : self
setFieldFqcn()  : self
setFormattedValue()  : self
setFormType()  : self
setFormTypeOption()  : self
setFormTypeOptionIfNotSet()  : self
setFormTypeOptions()  : self
setHelp()  : self
setLabel()  : self
setPermission()  : self
setProperty()  : self
setRequired()  : self
setSortable()  : self
setTemplateName()  : self
setTemplatePath()  : self
setTextAlign()  : self
setTranslationParameters()  : self
setValue()  : self
setVirtual()  : self
showEntryLabel()  : self
useEntryCrudForm()  : self
__construct()  : mixed

Constants

OPTION_ALLOW_DELETE

public mixed OPTION_ALLOW_DELETE = 'allowDelete'

OPTION_ENTRY_CRUD_CONTROLLER_FQCN

public mixed OPTION_ENTRY_CRUD_CONTROLLER_FQCN = 'entryCrudControllerFqcn'

OPTION_ENTRY_CRUD_EDIT_PAGE_NAME

public mixed OPTION_ENTRY_CRUD_EDIT_PAGE_NAME = 'entryCrudEditPageName'

OPTION_ENTRY_CRUD_NEW_PAGE_NAME

public mixed OPTION_ENTRY_CRUD_NEW_PAGE_NAME = 'entryCrudNewPageName'

OPTION_ENTRY_IS_COMPLEX

public mixed OPTION_ENTRY_IS_COMPLEX = 'entryIsComplex'

OPTION_ENTRY_USES_CRUD_FORM

public mixed OPTION_ENTRY_USES_CRUD_FORM = 'entryUsesCrudController'

OPTION_RENDER_EXPANDED

public mixed OPTION_RENDER_EXPANDED = 'renderExpanded'

OPTION_SHOW_ENTRY_LABEL

public mixed OPTION_SHOW_ENTRY_LABEL = 'showEntryLabel'

Properties

Methods

addCssClass()

public addCssClass(string $cssClass) : self
Parameters
$cssClass : string
Return values
self

addCssFiles()

public addCssFiles(Asset|string ...$pathsOrAssets) : self
Parameters
$pathsOrAssets : Asset|string
Return values
self

addFormTheme()

public addFormTheme(string ...$formThemePaths) : self
Parameters
$formThemePaths : string
Return values
self

addHtmlContentsToBody()

public addHtmlContentsToBody(string ...$contents) : self
Parameters
$contents : string
Return values
self

addHtmlContentsToHead()

public addHtmlContentsToHead(string ...$contents) : self
Parameters
$contents : string
Return values
self

addJsFiles()

public addJsFiles(Asset|string ...$pathsOrAssets) : self
Parameters
$pathsOrAssets : Asset|string
Return values
self

addWebpackEncoreEntries()

public addWebpackEncoreEntries(Asset|string ...$entryNamesOrAssets) : self
Parameters
$entryNamesOrAssets : Asset|string
Return values
self

allowAdd()

public allowAdd([bool $allow = true ]) : self
Parameters
$allow : bool = true
Return values
self

allowDelete()

public allowDelete([bool $allow = true ]) : self
Parameters
$allow : bool = true
Return values
self

formatValue()

public formatValue(callable|null $callable) : self
Parameters
$callable : callable|null
Return values
self

hideOnDetail()

public hideOnDetail() : self
Return values
self

hideOnForm()

public hideOnForm() : self
Return values
self

hideOnIndex()

public hideOnIndex() : self
Return values
self

hideWhenCreating()

public hideWhenCreating() : self
Return values
self

hideWhenUpdating()

public hideWhenUpdating() : self
Return values
self

onlyOnDetail()

public onlyOnDetail() : self
Return values
self

onlyOnForms()

public onlyOnForms() : self
Return values
self

onlyOnIndex()

public onlyOnIndex() : self
Return values
self

onlyWhenCreating()

public onlyWhenCreating() : self
Return values
self

onlyWhenUpdating()

public onlyWhenUpdating() : self
Return values
self

renderExpanded()

public renderExpanded([bool $renderExpanded = true ]) : self
Parameters
$renderExpanded : bool = true
Return values
self

setColumns()

public setColumns(int|string $cols) : self
Parameters
$cols : int|string

An integer with the number of columns that this field takes (e.g. 6), or a string with responsive col CSS classes (e.g. 'col-6 col-sm-4 col-lg-3')

Return values
self

setCssClass()

public setCssClass(string $cssClass) : self
Parameters
$cssClass : string
Return values
self

setCustomOption()

public setCustomOption(string $optionName, mixed $optionValue) : self
Parameters
$optionName : string
$optionValue : mixed
Return values
self

setCustomOptions()

public setCustomOptions(array<string|int, mixed> $options) : self
Parameters
$options : array<string|int, mixed>
Return values
self

setDisabled()

public setDisabled([bool $disabled = true ]) : self
Parameters
$disabled : bool = true
Return values
self

setEmptyData()

public setEmptyData([mixed $emptyData = null ]) : self
Parameters
$emptyData : mixed = null
Return values
self

setEntryIsComplex()

Set this option to TRUE if the collection items are complex form types composed of several form fields (EasyAdmin applies a special rendering to make them look better).

public setEntryIsComplex([bool $isComplex = true ]) : self
Parameters
$isComplex : bool = true
Return values
self

setEntryType()

public setEntryType(string $formTypeFqcn) : self
Parameters
$formTypeFqcn : string
Return values
self

setFieldFqcn()

public setFieldFqcn(string $fieldFqcn) : self
Parameters
$fieldFqcn : string
Return values
self

setFormattedValue()

public setFormattedValue(mixed $value) : self
Parameters
$value : mixed
Return values
self

setFormType()

public setFormType(string $formTypeFqcn) : self
Parameters
$formTypeFqcn : string
Return values
self

setFormTypeOption()

public setFormTypeOption(string $optionName, mixed $optionValue) : self
Parameters
$optionName : string

You can use "dot" notation to set nested options (e.g. 'attr.class')

$optionValue : mixed
Return values
self

setFormTypeOptionIfNotSet()

public setFormTypeOptionIfNotSet(string $optionName, mixed $optionValue) : self
Parameters
$optionName : string

You can use "dot" notation to set nested options (e.g. 'attr.class')

$optionValue : mixed
Return values
self

setFormTypeOptions()

public setFormTypeOptions(array<string|int, mixed> $options) : self
Parameters
$options : array<string|int, mixed>
Return values
self

setPermission()

public setPermission(string $permission) : self
Parameters
$permission : string
Return values
self

setProperty()

public setProperty(string $propertyName) : self
Parameters
$propertyName : string
Return values
self

setRequired()

public setRequired(bool $isRequired) : self
Parameters
$isRequired : bool
Return values
self

setSortable()

public setSortable(bool $isSortable) : self
Parameters
$isSortable : bool
Return values
self

setTemplateName()

public setTemplateName(string $name) : self
Parameters
$name : string
Return values
self

setTemplatePath()

public setTemplatePath(string $path) : self
Parameters
$path : string
Return values
self

setTextAlign()

public setTextAlign(string $textAlign) : self
Parameters
$textAlign : string

It can be 'left', 'center' or 'right'

Return values
self

setTranslationParameters()

public setTranslationParameters(array<string|int, mixed> $parameters) : self
Parameters
$parameters : array<string|int, mixed>
Return values
self

setValue()

public setValue(mixed $value) : self
Parameters
$value : mixed
Return values
self

setVirtual()

public setVirtual(bool $isVirtual) : self
Parameters
$isVirtual : bool
Return values
self

showEntryLabel()

public showEntryLabel([bool $showLabel = true ]) : self
Parameters
$showLabel : bool = true
Return values
self

useEntryCrudForm()

public useEntryCrudForm([string|null $crudControllerFqcn = null ][, string|null $crudNewPageName = null ][, string|null $crudEditPageName = null ]) : self
Parameters
$crudControllerFqcn : string|null = null
$crudNewPageName : string|null = null
$crudEditPageName : string|null = null
Return values
self

        
On this page

Search results