Customizing the menu
Create a configuration, add custom pages and fill more details for your module
Setting up
By setting the MODULE.menu
, you will be able to customize your module's menu.
The setup should looks like this:
Adding configuration
TODO
Adding pages
To do so, you need to specify the pages
table variable.
Each 'page' element must be a function( DForm )
which will modify its own form as you want it to be.
Example
Adding details
By default, these module properties will show in the sidebar, such as:
the author name
the local version
the remote version (if
MODULE.version_url
was set and the request was successful)
If you want to customize your module's sidebar such as adding informations & links, you have to specify the details
table variable and add all the content you want.
Each string element will show as a category in the sidebar. You can also give a structured table to create links, actions or texts:
Structure
string
text
Text of the label
(optional)
string
icon=nil
(optional)
string
url=nil
URL to open when the user clicks on this detail. NOT compatible with the callback
property.
(optional)
function
callback=nil
Custom callback to run when the user clicks on this detail. NOT compatible with the url
property.
Example
Last updated