new Menu(app, ui, view)
- Description:
Main menu rendering
Parameters:
Name | Type | Description |
---|---|---|
app |
Simplicite.Ajax | Ajax service |
ui |
Simplicite.UI.Engine | Main UI controller |
view |
Simplicite.UI.View.Main | View services |
Methods
focus()
- Description:
Focus the last selected item or first item
getMenu()
- Description:
Main menu
hover(b)
- Description:
hover effect when minified
Parameters:
Name | Type | Description |
---|---|---|
b |
boolean | false to remove effect |
init()
- Description:
Init the main menu, use the ui.clickMenu handler
isMenuMax()
- Description:
Is menu maximized on the left side ?
isMenuMin()
- Description:
Is menu minimized on the left side ?
menuMax()
- Description:
Maximize the menu on the left side
- displays domain icons and labels
- accordion sub-menus
menuMin()
- Description:
Minimize the menu on the left side
- displays only domain icons
- popup the sub-menus over the screen
menuToggle(e, sign)
- Description:
Toggle the main menu on the left side
Parameters:
Name | Type | Description |
---|---|---|
e |
Object | optional event |
sign |
number | positive:show, negative:hide |
selectMenu()
- Description:
Select one menu item
startRefreshStatus()
- Description:
Start a timer to update enum counters
stopRefreshStatus()
- Description:
Stop the timer to update visible status counters
subMenuMax(m)
- Description:
Show a sub-menu
Parameters:
Name | Type | Description |
---|---|---|
m |
jQuery | menu item (li element with .sub-menu child) |
subMenuMin(m)
- Description:
Hide a sub-menu
Parameters:
Name | Type | Description |
---|---|---|
m |
jQuery | menu item (li element with .sub-menu child) |
updateStatusBadge(object, field, code)
- Description:
Update the visible enum counter
Parameters:
Name | Type | Description |
---|---|---|
object |
string | jquery | object name or menu item |
field |
string | enum field name |
code |
string | enum code |
updateStatusBadges(m)
- Description:
Update all status and enum counters of a given menu
Parameters:
Name | Type | Description |
---|---|---|
m |
jQuery | sub menu |