dolibarr  7.0.0-beta
Static Public Member Functions | List of all members
InfoBox Class Reference

Class to manage boxes on pages. More...

Static Public Member Functions

static getListOfPagesForBoxes ()
 Name of positions 0=Home, 1=... More...
 
static listBoxes ($db, $mode, $zone, $user=null, $excludelist=array(), $includehidden=1)
 Return array of boxes qualified for area and user. More...
 
static saveboxorder ($db, $zone, $boxorder, $userid=0)
 Save order of boxes for area and user. More...
 

Detailed Description

Class to manage boxes on pages.

This is an utility class (all is static)

Definition at line 28 of file infobox.class.php.

Member Function Documentation

static InfoBox::getListOfPagesForBoxes ( )
static

Name of positions 0=Home, 1=...

Returns
string[] Array with list of zones

Definition at line 35 of file infobox.class.php.

Referenced by DolibarrModules\insert_boxes().

static InfoBox::listBoxes (   $db,
  $mode,
  $zone,
  $user = null,
  $excludelist = array(),
  $includehidden = 1 
)
static

Return array of boxes qualified for area and user.

Parameters
DoliDB$dbDatabase handler
string$mode'available' or 'activated'
string$zoneName or area (-1 for all, 0 for Homepage, 1 for xxx, ...)
User | null$userObject user to filter
array$excludelistArray of box id (box.box_id = boxes_def.rowid) to exclude
int$includehiddenInclude also hidden boxes
Returns
array Array of boxes

Definition at line 51 of file infobox.class.php.

References $resql, dol_include_once(), and dol_syslog().

Referenced by FormOther\getBoxesArea().

static InfoBox::saveboxorder (   $db,
  $zone,
  $boxorder,
  $userid = 0 
)
static

Save order of boxes for area and user.

Parameters
DoliDB$dbDatabase handler
string$zoneName of area (0 for Homepage, ...)
string$boxorderList of boxes with correct order 'A:123,456,...-B:789,321...'
int$useridId of user
Returns
int <0 if KO, 0=Nothing done, > 0 if OK

Definition at line 189 of file infobox.class.php.

References dol_set_user_param(), and dol_syslog().


The documentation for this class was generated from the following file: