new Menu(app, engine, view)
- Description:
Main menu rendering
Parameters:
Name | Type | Description |
---|---|---|
app |
Simplicite.Ajax | Ajax service |
engine |
Simplicite.UI.Engine | Main controller |
view |
Simplicite.UI.View.Main | View services |
Methods
getMenu()
- Description:
Main menu
init()
- Description:
Init the main menu, use the engine.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 |
startRefreshStatus()
- Description:
Start a timer to update status 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, state)
- Description:
Update the visible status counter
Parameters:
Name | Type | Description |
---|---|---|
object |
string | jquery | object name or menu item |
field |
string | status field name |
state |
string | object state code |
updateStatusBadges(m)
- Description:
Update all status counters of a given menu
Parameters:
Name | Type | Description |
---|---|---|
m |
jQuery | sub menu |