New decorator for multiselect form elements to support ordering.
Centurion provides a mechanism to save the order in relation, and return it in front, but no provide element in form to allow user to order elements. This patch provides a new decorator for multiselect to allow this :
To use the multiselect with ordering
Add a trait on your form to support decorator provided by Core
class myForm
extends Centurion_Form_Model_Abstract
implements Core_Traits_Decorators_Form_Model_Interface
overload the method render and add these lines before calls to method render of parent :
(because Centurion_Form_Model reset elements decorators).
@Todo : add a system allows developer to defines new paths in Decorator PluginLoader in the configuration, and remove the trait Core_Traits_Decorators_Form_Model_Interface
New decorator for multiselect form elements to support ordering.
Centurion provides a mechanism to save the order in relation, and return it in front, but no provide element in form to allow user to order elements. This patch provides a new decorator for multiselect to allow this :
To use the multiselect with ordering
Add a trait on your form to support decorator provided by Core
overload the method
render
and add these lines before calls to methodrender
of parent : (because Centurion_Form_Model reset elements decorators).@Todo : add a system allows developer to defines new paths in Decorator PluginLoader in the configuration, and remove the trait Core_Traits_Decorators_Form_Model_Interface