Maslosoft Framework Logo Maslosoft Framework Documentation
Flexible Application Foundation


Enum Buttons Renderer

Enum buttons renderer allow displaying button based on value of field. This will result in proper label in buttons list in form field.

If the EnumClass have iconsCss method, this will also add icons to buttons.

It is recommended to use IconEnum trait to provide icons.

This will also use cssClasses method from enum class to provide extra CSS classes for each button.

Usage:

@FormRenderer(EnumButtons, EnumClass)