dolibarr  20.0.0-alpha
Functions
eldy.lib.php File Reference

Library for file eldy menus. More...

Go to the source code of this file.

Functions

 print_eldy_menu ($db, $atarget, $type_user, &$tabMenu, &$menu, $noout=0, $mode='')
 Core function to output top menu eldy. More...
 
 print_start_menu_array ()
 Output start menu array. More...
 
 print_start_menu_entry ($idsel, $classname, $showmode)
 Output start menu entry. More...
 
 print_text_menu_entry ($text, $showmode, $url, $id, $idsel, $classname, $atarget, $menuval=array())
 Output menu entry. More...
 
 print_end_menu_entry ($showmode)
 Output end menu entry. More...
 
 print_end_menu_array ()
 Output menu array. More...
 
 print_left_eldy_menu ($db, $menu_array_before, $menu_array_after, &$tabMenu, &$menu, $noout=0, $forcemainmenu='', $forceleftmenu='', $moredata=null, $type_user=0)
 Core function to output left menu eldy Fill &$menu (example with $forcemainmenu='home' $forceleftmenu='all', return left menu tree of Home) More...
 
 get_left_menu_home ($mainmenu, &$newmenu, $usemenuhider=1, $leftmenu='none', $type_user=0)
 Get left Menu HOME. More...
 
 get_left_menu_thridparties ($mainmenu, &$newmenu, $usemenuhider=1, $leftmenu='none', $type_user=0)
 Get left Menu THIRDPARTIES. More...
 
 get_left_menu_commercial ($mainmenu, &$newmenu, $usemenuhider=1, $leftmenu='none', $type_user=0)
 Get left Menu COMMERCIAL (propal, commande, supplier_proposal, supplier_order, contrat, ficheinter) More...
 
 get_left_menu_billing ($mainmenu, &$newmenu, $usemenuhider=1, $leftmenu='none', $type_user=0)
 Get left COMPTA-FINANCIAL. More...
 
 get_left_menu_accountancy ($mainmenu, &$newmenu, $usemenuhider=1, $leftmenu='none', $type_user=0)
 Get left COMPTA-FINANCIAL (accountancy) More...
 
 get_left_menu_bank ($mainmenu, &$newmenu, $usemenuhider=1, $leftmenu='none', $type_user=0)
 Get left Menu BANK. More...
 
 get_left_menu_products ($mainmenu, &$newmenu, $usemenuhider=1, $leftmenu='none', $type_user=0)
 Get left Menu PRODUCTS-SERVICES. More...
 
 get_left_menu_mrp ($mainmenu, &$newmenu, $usemenuhider=1, $leftmenu='none', $type_user=0)
 Get left Menu PRODUCTS-SERVICES MRP - GPAO. More...
 
 get_left_menu_projects ($mainmenu, &$newmenu, $usemenuhider=1, $leftmenu='none', $type_user=0)
 Get left Menu PROJECTS. More...
 
 get_left_menu_hrm ($mainmenu, &$newmenu, $usemenuhider=1, $leftmenu='none', $type_user=0)
 Get left Menu HRM. More...
 
 get_left_menu_tools ($mainmenu, &$newmenu, $usemenuhider=1, $leftmenu='none', $type_user=0)
 Get left Menu TOOLS. More...
 
 get_left_menu_members ($mainmenu, &$newmenu, $usemenuhider=1, $leftmenu='none', $type_user=0)
 Get left Menu MEMBERS. More...
 

Detailed Description

Library for file eldy menus.

Definition in file eldy.lib.php.

Function Documentation

◆ get_left_menu_accountancy()

get_left_menu_accountancy (   $mainmenu,
$newmenu,
  $usemenuhider = 1,
  $leftmenu = 'none',
  $type_user = 0 
)

Get left COMPTA-FINANCIAL (accountancy)

Parameters
string$mainmenuMain menu
Menu$newmenuObject Menu to return back list of menu entries
int$usemenuhiderUse menu hider
string$leftmenuLeft menu
int$type_userType of targeted user for menu
Returns
void

Definition at line 1656 of file eldy.lib.php.

◆ get_left_menu_bank()

get_left_menu_bank (   $mainmenu,
$newmenu,
  $usemenuhider = 1,
  $leftmenu = 'none',
  $type_user = 0 
)

Get left Menu BANK.

Parameters
string$mainmenuMain menu
Menu$newmenuObject Menu to return back list of menu entries
int$usemenuhiderUse menu hider
string$leftmenuLeft menu
int$type_userType of targeted user for menu
Returns
void

Definition at line 1982 of file eldy.lib.php.

◆ get_left_menu_billing()

get_left_menu_billing (   $mainmenu,
$newmenu,
  $usemenuhider = 1,
  $leftmenu = 'none',
  $type_user = 0 
)

Get left COMPTA-FINANCIAL.

Parameters
string$mainmenuMain menu
Menu$newmenuObject Menu to return back list of menu entries
int$usemenuhiderUse menu hider
string$leftmenuLeft menu
int$type_userType of targeted user for menu
Returns
void

Definition at line 1473 of file eldy.lib.php.

◆ get_left_menu_commercial()

get_left_menu_commercial (   $mainmenu,
$newmenu,
  $usemenuhider = 1,
  $leftmenu = 'none',
  $type_user = 0 
)

Get left Menu COMMERCIAL (propal, commande, supplier_proposal, supplier_order, contrat, ficheinter)

Parameters
string$mainmenuMain menu
Menu$newmenuObject Menu to return back list of menu entries
int$usemenuhiderUse menu hider
string$leftmenuLeft menu
int$type_userType of targeted user for menu
Returns
void

Definition at line 1347 of file eldy.lib.php.

◆ get_left_menu_home()

get_left_menu_home (   $mainmenu,
$newmenu,
  $usemenuhider = 1,
  $leftmenu = 'none',
  $type_user = 0 
)

Get left Menu HOME.

Parameters
string$mainmenuMain menu
Menu$newmenuObject Menu to return back list of menu entries
int$usemenuhiderUse menu hider
string$leftmenuLeft menu
int$type_userType of user
Returns
void

Definition at line 1114 of file eldy.lib.php.

◆ get_left_menu_hrm()

get_left_menu_hrm (   $mainmenu,
$newmenu,
  $usemenuhider = 1,
  $leftmenu = 'none',
  $type_user = 0 
)

Get left Menu HRM.

Parameters
string$mainmenuMain menu
Menu$newmenuObject Menu to return back list of menu entries
int$usemenuhiderUse menu hider
string$leftmenuLeft menu
int$type_userType of targeted user for menu
Returns
void

Definition at line 2318 of file eldy.lib.php.

◆ get_left_menu_members()

get_left_menu_members (   $mainmenu,
$newmenu,
  $usemenuhider = 1,
  $leftmenu = 'none',
  $type_user = 0 
)

Get left Menu MEMBERS.

Parameters
string$mainmenuMain menu
Menu$newmenuObject Menu to return back list of menu entries
int$usemenuhiderUse menu hider
string$leftmenuLeft menu
int$type_userType of targeted user for menu
Returns
void

Definition at line 2474 of file eldy.lib.php.

◆ get_left_menu_mrp()

get_left_menu_mrp (   $mainmenu,
$newmenu,
  $usemenuhider = 1,
  $leftmenu = 'none',
  $type_user = 0 
)

Get left Menu PRODUCTS-SERVICES MRP - GPAO.

Parameters
string$mainmenuMain menu
Menu$newmenuObject Menu to return back list of menu entries
int$usemenuhiderUse menu hider
string$leftmenuLeft menu
int$type_userType of targeted user for menu
Returns
void

Definition at line 2209 of file eldy.lib.php.

◆ get_left_menu_products()

get_left_menu_products (   $mainmenu,
$newmenu,
  $usemenuhider = 1,
  $leftmenu = 'none',
  $type_user = 0 
)

Get left Menu PRODUCTS-SERVICES.

Parameters
string$mainmenuMain menu
Menu$newmenuObject Menu to return back list of menu entries
int$usemenuhiderUse menu hider
string$leftmenuLeft menu
int$type_userType of targeted user for menu
Returns
void

Definition at line 2065 of file eldy.lib.php.

◆ get_left_menu_projects()

get_left_menu_projects (   $mainmenu,
$newmenu,
  $usemenuhider = 1,
  $leftmenu = 'none',
  $type_user = 0 
)

Get left Menu PROJECTS.

Parameters
string$mainmenuMain menu
Menu$newmenuObject Menu to return back list of menu entries
int$usemenuhiderUse menu hider
string$leftmenuLeft menu
int$type_userType of targeted user for menu
Returns
void

Definition at line 2243 of file eldy.lib.php.

◆ get_left_menu_thridparties()

get_left_menu_thridparties (   $mainmenu,
$newmenu,
  $usemenuhider = 1,
  $leftmenu = 'none',
  $type_user = 0 
)

Get left Menu THIRDPARTIES.

Parameters
string$mainmenuMain menu
Menu$newmenuObject Menu to return back list of menu entries
int$usemenuhiderUse menu hider
string$leftmenuLeft menu
int$type_userType of targeted user for menu
Returns
void

Definition at line 1242 of file eldy.lib.php.

◆ get_left_menu_tools()

get_left_menu_tools (   $mainmenu,
$newmenu,
  $usemenuhider = 1,
  $leftmenu = 'none',
  $type_user = 0 
)

Get left Menu TOOLS.

Parameters
string$mainmenuMain menu
Menu$newmenuObject Menu to return back list of menu entries
int$usemenuhiderUse menu hider
string$leftmenuLeft menu
int$type_userType of targeted user for menu
Returns
void

Definition at line 2426 of file eldy.lib.php.

◆ print_eldy_menu()

print_eldy_menu (   $db,
  $atarget,
  $type_user,
$tabMenu,
$menu,
  $noout = 0,
  $mode = '' 
)

Core function to output top menu eldy.

Parameters
DoliDB$dbDatabase handler
string$atargetTarget (Example: '' or '_top')
int$type_user0=Menu for backoffice, 1=Menu for front office
array<array{rowid:string,fk_menu:string,langs:string,enabled:int<0,2>,type:string,fk_mainmenu:string,fk_leftmenu:string,url:string,titre:string,perms:string,target:string,mainmenu:string,leftmenu:string,position:int,level?:int,prefix:string}>$tabMenu If array with menu entries already loaded, we put this array here (in most cases, it's empty). For eldy menu, it contains menu entries loaded from database.
Menu$menuObject Menu to return back list of menu entries
int$noout1=Disable output (Initialise &$menu only).
string$mode'top', 'topnb', 'left', 'jmobile'
Returns
int 0

Definition at line 46 of file eldy.lib.php.

◆ print_end_menu_array()

print_end_menu_array ( )

Output menu array.

Returns
void

Definition at line 712 of file eldy.lib.php.

◆ print_end_menu_entry()

print_end_menu_entry (   $showmode)

Output end menu entry.

Parameters
int$showmode0 = hide, 1 = allowed or 2 = not allowed
Returns
void

Definition at line 699 of file eldy.lib.php.

◆ print_left_eldy_menu()

print_left_eldy_menu (   $db,
  $menu_array_before,
  $menu_array_after,
$tabMenu,
$menu,
  $noout = 0,
  $forcemainmenu = '',
  $forceleftmenu = '',
  $moredata = null,
  $type_user = 0 
)

Core function to output left menu eldy Fill &$menu (example with $forcemainmenu='home' $forceleftmenu='all', return left menu tree of Home)

Parameters
DoliDB$dbDatabase handler
array<array{rowid:string,fk_menu:string,langs:string,enabled:int<0,2>,type:string,fk_mainmenu:string,fk_leftmenu:string,url:string,titre:string,perms:string,target:string,mainmenu:string,leftmenu:string,position:int,level?:int,prefix:string}>$menu_array_before Table of menu entries to show before entries of menu handler (menu->liste filled with menu->add)
array<array{rowid:string,fk_menu:string,langs:string,enabled:int<0,2>,type:string,fk_mainmenu:string,fk_leftmenu:string,url:string,titre:string,perms:string,target:string,mainmenu:string,leftmenu:string,position:int,level?:int,prefix:string}>$menu_array_after Table of menu entries to show after entries of menu handler (menu->liste filled with menu->add)
array<array{rowid:string,fk_menu:string,langs:string,enabled:int<0,2>,type:string,fk_mainmenu:string,fk_leftmenu:string,url:string,titre:string,perms:string,target:string,mainmenu:string,leftmenu:string,position:int,level?:int,prefix:string}>$tabMenu If array with menu entries already loaded, we put this array here (in most cases, it's empty)
Menu$menuObject Menu to return back list of menu entries
int$nooutDisable output (Initialise &$menu only).
string$forcemainmenu'x'=Force mainmenu to mainmenu='x'
string$forceleftmenu'all'=Force leftmenu to '' (= all). If value come being '', we change it to value in session and 'none' if not defined in session.
array$moredataAn array with more data to output
int$type_user0=Menu for backoffice, 1=Menu for front office
Returns
int Nb of menu entries

We update newmenu with entries found into database

Definition at line 735 of file eldy.lib.php.

◆ print_start_menu_array()

print_start_menu_array ( )

Output start menu array.

Returns
void

Definition at line 610 of file eldy.lib.php.

◆ print_start_menu_entry()

print_start_menu_entry (   $idsel,
  $classname,
  $showmode 
)

Output start menu entry.

Parameters
string$idselText
string$classnameString to add a css class
int$showmode0 = hide, 1 = allowed or 2 = not allowed
Returns
void

Definition at line 624 of file eldy.lib.php.

◆ print_text_menu_entry()

print_text_menu_entry (   $text,
  $showmode,
  $url,
  $id,
  $idsel,
  $classname,
  $atarget,
  $menuval = array() 
)

Output menu entry.

Parameters
string$textText
int$showmode0 = hide, 1 = allowed or 2 = not allowed
string$urlUrl
string$idId
string$idselId sel
string$classnameClass name
string$atargetTarget
array{}|array{rowid:string,fk_menu:string,langs:string,enabled:int<0,2>,type:string,fk_mainmenu:string,fk_leftmenu:string,url:string,titre:string,perms:string,target:string,mainmenu:string,leftmenu:string,position:int,level?:int,prefix:string}$menuval All the $menuval array
Returns
void

Definition at line 646 of file eldy.lib.php.