List of all members.

Public Member Functions

 defineTabs ($options=array())
 Define tabs to display.
 showForm ($ID, $options=array())
 getSearchOptions ()
 Get the Search options for the given Type.
 canViewItem ()
 Have I the right to "view" the Object May be overloaded if needed.
 canCreateItem ()
 Is the current user have right to update the current notification ?
 cleanDBonPurge ()
 Actions done when item is deleted from the database.

Static Public Member Functions

static getTypeName ($nb=0)
 Return the localized name of the current Type Should be overloaded in each new class.
static getSpecificValueToDisplay ($field, $values, array $options=array())
static getSpecificValueToSelect ($field, $name='', $values='', array $options=array())
static canCreate ()
 Have I the global right to "create" the Object May be overloaded if needed (ex KnowbaseItem)
static canView ()
 Have I the global right to "view" the Object.
static dropdownMode ($options)
 Display a dropdown with all the available notification modes.
static getMode ($mode)
 Get notification method label (email only for the moment)
static getModes ()
 Get notification method label (email only for the moment)
static send ($mailing_options)
static getMailingSignature ($entity)
 Get the mailing signature for the entity.
static getNotificationsByEventAndType ($event, $itemtype, $entity)

Public Attributes

const USER_TYPE = 1
const PROFILE_TYPE = 2
const GROUP_TYPE = 3
const MAILING_TYPE = 4
const SUPERVISOR_GROUP_TYPE = 5
const GLOBAL_ADMINISTRATOR = 1
const ASSIGN_TECH = 2
const AUTHOR = 3
const OLD_TECH_IN_CHARGE = 4
const ITEM_TECH_IN_CHARGE = 5
const ITEM_USER = 6
const RECIPIENT = 7
const SUPPLIER = 8
const ASSIGN_GROUP = 9
const SUPERVISOR_ASSIGN_GROUP = 10
const ENTITY_ADMINISTRATOR = 11
const SUPERVISOR_REQUESTER_GROUP = 12
const REQUESTER_GROUP = 13
const VALIDATION_APPROVER = 14
const VALIDATION_REQUESTER = 15
const TASK_ASSIGN_TECH = 16
const TASK_AUTHOR = 17
const FOLLOWUP_AUTHOR = 18
const USER = 19
const OBSERVER_GROUP = 20
const OBSERVER = 21
const SUPERVISOR_OBSERVER_GROUP = 22
const ITEM_TECH_GROUP_IN_CHARGE = 23
 $dohistory = true
 Make an history of the changes.

Detailed Description

Definition at line 39 of file notification.class.php.


Member Function Documentation

static canCreate ( ) [static]

Have I the global right to "create" the Object May be overloaded if needed (ex KnowbaseItem)

Returns:
booleen

Reimplemented from CommonDBTM.

Definition at line 308 of file notification.class.php.

References haveRight().

Is the current user have right to update the current notification ?

Returns:
boolean

Reimplemented from CommonDBTM.

Definition at line 334 of file notification.class.php.

References CommonDBTM\getEntityID(), Session\haveAccessToEntity(), and Session\haveRight().

static canView ( ) [static]

Have I the global right to "view" the Object.

Default is true and check entity if the objet is entity assign

May be overloaded if needed

Returns:
booleen

Reimplemented from CommonDBTM.

Definition at line 313 of file notification.class.php.

References haveRight().

Have I the right to "view" the Object May be overloaded if needed.

Returns:
booleen

Reimplemented from CommonDBTM.

Definition at line 318 of file notification.class.php.

References CommonDBTM\getEntityID(), Session\haveAccessToEntity(), Session\haveRight(), and CommonDBTM\isRecursive().

Actions done when item is deleted from the database.

Returns:
nothing

Reimplemented from CommonDBTM.

Definition at line 394 of file notification.class.php.

References $DB, and $query.

defineTabs ( options = array())

Define tabs to display.

NB : Only called for existing object

Parameters:
$optionsarray
  • withtemplate is a template view ?
Returns:
array containing the onglets

Reimplemented from CommonGLPI.

Definition at line 112 of file notification.class.php.

References $options, and CommonGLPI\addStandardTab().

static dropdownMode ( options) [static]

Display a dropdown with all the available notification modes.

Parameters:
$optionsarray of options

Definition at line 350 of file notification.class.php.

References $options, $val, and Dropdown\showFromArray().

Referenced by getSpecificValueToSelect(), and showForm().

static getMailingSignature ( entity) [static]

Get the mailing signature for the entity.

Parameters:
$entity

Definition at line 420 of file notification.class.php.

References $CFG_GLPI, $DB, and $entity.

Referenced by NotificationEvent\raiseEvent(), and NotificationTemplateTranslation\showDebug().

static getMode ( mode) [static]

Get notification method label (email only for the moment)

Parameters:
$modethe mode to use
Returns:
the mode's label

Definition at line 373 of file notification.class.php.

References getModes().

Referenced by getSpecificValueToDisplay(), and Search\giveItem().

static getModes ( ) [static]

Get notification method label (email only for the moment)

Since:
versin 0.84
Returns:
the mode's label

Definition at line 389 of file notification.class.php.

References __().

Referenced by getMode().

static getNotificationsByEventAndType ( event,
itemtype,
entity 
) [static]
Parameters:
$event
$itemtype
$entity

Definition at line 437 of file notification.class.php.

References $DB, $entity, $query, and getEntitiesRestrictRequest().

Referenced by NotificationEvent\raiseEvent().

Get the Search options for the given Type.

This should be overloaded in Class

Returns:
an array of search options More information on https://forge.indepnet.net/wiki/glpi/SearchEngine

Reimplemented from CommonDBTM.

Definition at line 247 of file notification.class.php.

References __(), _n(), and CommonDBTM\getTable().

static getSpecificValueToDisplay ( field,
values,
array $  options = array() 
) [static]
Since:
version 0.84
Parameters:
$field
$values
$optionsarray

Reimplemented from CommonDBTM.

Definition at line 195 of file notification.class.php.

References $field, $options, $values, NotificationEvent\getEventName(), and getMode().

static getSpecificValueToSelect ( field,
name = '',
values = '',
array $  options = array() 
) [static]
Since:
version 0.84
Parameters:
$field
$name(default '')
$values(default '')
$optionsarray

Reimplemented from CommonDBTM.

Definition at line 222 of file notification.class.php.

References $field, $name, $options, $values, NotificationEvent\dropdownEvents(), and dropdownMode().

static getTypeName ( nb = 0) [static]

Return the localized name of the current Type Should be overloaded in each new class.

Returns:
string

Reimplemented from CommonGLPI.

Definition at line 107 of file notification.class.php.

References $nb, and _n().

Referenced by NotificationTarget\getTabNameForItem(), and showForm().

static send ( mailing_options) [static]
Parameters:
$mailing_options

Definition at line 407 of file notification.class.php.

Referenced by NotificationEvent\raiseEvent().


Member Data Documentation

$dohistory = true

Make an history of the changes.

Reimplemented from CommonDBTM.

Definition at line 104 of file notification.class.php.

const MAILING_TYPE = 4

Definition at line 49 of file notification.class.php.


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