\Dewdrop\Admin\ComponentCrudInterface

Fulfilling this interface in your Component class has several benefits:

1) Combined with a \Dewdrop\PageFactory\Crud object, many admin pages can be automatically handled for you without writing any additional code.

2) Any pages you do write yourself will be cleaner. Having these core objects for your component defined centrally means that other pages can re-use them easily and avoid errors introduced by repetitive code.

3) Other parts of Dewdrop (not just pages in your admin component) could use the resources provided by this interface to provide additional services. The most important example of this is automated testing.

Providing a nice admin user experience can be very difficult. Your users want tools that are just as capable and pleasant as the tools that you enjoy using for your own work. But providing that level of quality and attention to detail is very challenging on the budget and timeline typically available for admin/backend work.

This interface and the related tools make that task much more manageable by turning what was a very detail-oriented task into a declaractive, configuration-driven task.

Summary

Methods
Constants
getPrimaryModel()
getListing()
getFields()
getFieldGroupsFilter()
getVisibilityFilter()
getRowEditor()
No constants found
No protected methods found
N/A
No private methods found
N/A

Methods

getPrimaryModel()

getPrimaryModel() : \Dewdrop\Db\Table

Get the primary model that is used by this component. This model will be used to provide page and button titles. By default, its primary key will also be used to filter the listing when needed (e.g. when viewing a single item rather than the full listing).

Returns

\Dewdrop\Db\Table

getListing()

getListing() : \Dewdrop\Fields\Listing

Get a \Dewdrop\Fields\Listing object that allows the component to retrieve records for viewing. The Listing handles applying user sorts and filters.

Returns

\Dewdrop\Fields\Listing

getFields()

getFields() : \Dewdrop\Fields

Get the \Dewdrop\Fields object that defines what fields are available to this component, what capabilities that each have, and how they should interact with various \Dewdrop\Fields\Helper objects.

Returns

\Dewdrop\Fields

getFieldGroupsFilter()

getFieldGroupsFilter() : \Dewdrop\Fields\Filter\Groups

Get a \Dewdrop\Fields\Filter\Groups object to allow the user to sort and group their fields.

Returns

\Dewdrop\Fields\Filter\Groups

getVisibilityFilter()

getVisibilityFilter() : \Dewdrop\Fields\Filter\Visibility

Get a \Dewdrop\Fields\Filter\Visibility object that allows the user to select which fields should be visible on listings.

Returns

\Dewdrop\Fields\Filter\Visibility

getRowEditor()

getRowEditor() : \Dewdrop\Fields\RowEditor

Get the \Dewdrop\Fields\RowEditor object that will assist with the editing of items in this component.

Returns

\Dewdrop\Fields\RowEditor