Uniformize code and doxygen
This commit is contained in:
parent
40a4bcec04
commit
b81938fe95
@ -42,12 +42,25 @@ class mailing_contacts1 extends MailingTargets
|
|||||||
var $db;
|
var $db;
|
||||||
|
|
||||||
|
|
||||||
function mailing_contacts1($DB)
|
/**
|
||||||
|
* Constructor
|
||||||
|
*
|
||||||
|
* @param DoliDB $db Database handler
|
||||||
|
*/
|
||||||
|
function mailing_contacts1($db)
|
||||||
{
|
{
|
||||||
$this->db=$DB;
|
$this->db=$db;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* On the main mailing area, there is a box with statistics.
|
||||||
|
* If you want to add a line in this report you must provide an
|
||||||
|
* array of SQL request that returns two field:
|
||||||
|
* One called "label", One called "nb".
|
||||||
|
*
|
||||||
|
* @return array Array with SQL requests
|
||||||
|
*/
|
||||||
function getSqlArrayForStats()
|
function getSqlArrayForStats()
|
||||||
{
|
{
|
||||||
global $conf, $langs;
|
global $conf, $langs;
|
||||||
|
|||||||
@ -41,9 +41,14 @@ class mailing_contacts2 extends MailingTargets
|
|||||||
var $db;
|
var $db;
|
||||||
|
|
||||||
|
|
||||||
function mailing_contacts2($DB)
|
/**
|
||||||
|
* Constructor
|
||||||
|
*
|
||||||
|
* @param DoliDB $db Database handler
|
||||||
|
*/
|
||||||
|
function mailing_contacts2($db)
|
||||||
{
|
{
|
||||||
$this->db=$DB;
|
$this->db=$db;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -113,7 +118,8 @@ class mailing_contacts2 extends MailingTargets
|
|||||||
* If you want to add a line in this report you must provide an
|
* If you want to add a line in this report you must provide an
|
||||||
* array of SQL request that returns two field:
|
* array of SQL request that returns two field:
|
||||||
* One called "label", One called "nb".
|
* One called "label", One called "nb".
|
||||||
* @return array
|
*
|
||||||
|
* @return array Array with SQL requests
|
||||||
*/
|
*/
|
||||||
function getSqlArrayForStats()
|
function getSqlArrayForStats()
|
||||||
{
|
{
|
||||||
|
|||||||
@ -41,12 +41,16 @@ class mailing_contacts3 extends MailingTargets
|
|||||||
var $db;
|
var $db;
|
||||||
|
|
||||||
|
|
||||||
function mailing_contacts3($DB)
|
/**
|
||||||
|
* Constructor
|
||||||
|
*
|
||||||
|
* @param DoliDB $db Database handler
|
||||||
|
*/
|
||||||
|
function mailing_contacts3($db)
|
||||||
{
|
{
|
||||||
$this->db=$DB;
|
$this->db=$db;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \brief Renvoie url lien vers fiche de la source du destinataire du mailing
|
* \brief Renvoie url lien vers fiche de la source du destinataire du mailing
|
||||||
* \return string Url lien
|
* \return string Url lien
|
||||||
@ -118,7 +122,8 @@ class mailing_contacts3 extends MailingTargets
|
|||||||
* If you want to add a line in this report you must provide an
|
* If you want to add a line in this report you must provide an
|
||||||
* array of SQL request that returns two field:
|
* array of SQL request that returns two field:
|
||||||
* One called "label", One called "nb".
|
* One called "label", One called "nb".
|
||||||
* @return array
|
*
|
||||||
|
* @return array Array with SQL requests
|
||||||
*/
|
*/
|
||||||
function getSqlArrayForStats()
|
function getSqlArrayForStats()
|
||||||
{
|
{
|
||||||
|
|||||||
@ -51,10 +51,11 @@ class mailing_example extends MailingTargets
|
|||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \brief This is the main function that returns the array of emails
|
* This is the main function that returns the array of emails
|
||||||
* \param mailing_id Id of mailing. No need to use it.
|
*
|
||||||
* \param filterarray If you used the formFilter function. Empty otherwise.
|
* @param mailing_id Id of mailing. No need to use it.
|
||||||
* \return int <0 if error, number of emails added if ok
|
* @param filterarray If you used the formFilter function. Empty otherwise.
|
||||||
|
* @return int <0 if error, number of emails added if ok
|
||||||
*/
|
*/
|
||||||
function add_to_target($mailing_id,$filtersarray=array())
|
function add_to_target($mailing_id,$filtersarray=array())
|
||||||
{
|
{
|
||||||
@ -77,11 +78,12 @@ class mailing_example extends MailingTargets
|
|||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \brief On the main mailing area, there is a box with statistics.
|
* On the main mailing area, there is a box with statistics.
|
||||||
* If you want to add a line in this report you must provide an
|
* If you want to add a line in this report you must provide an
|
||||||
* array of SQL request that returns two field:
|
* array of SQL request that returns two field:
|
||||||
* One called "label", One called "nb".
|
* One called "label", One called "nb".
|
||||||
* \return array
|
*
|
||||||
|
* @return array Array with SQL requests
|
||||||
*/
|
*/
|
||||||
function getSqlArrayForStats()
|
function getSqlArrayForStats()
|
||||||
{
|
{
|
||||||
@ -93,11 +95,12 @@ class mailing_example extends MailingTargets
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/**
|
||||||
* \brief Return here number of distinct emails returned by your selector.
|
* Return here number of distinct emails returned by your selector.
|
||||||
* For example if this selector is used to extract 500 different
|
* For example if this selector is used to extract 500 different
|
||||||
* emails from a text file, this function must return 500.
|
* emails from a text file, this function must return 500.
|
||||||
* \return int
|
*
|
||||||
|
* @return int
|
||||||
*/
|
*/
|
||||||
function getNbOfRecipients()
|
function getNbOfRecipients()
|
||||||
{
|
{
|
||||||
@ -109,9 +112,10 @@ class mailing_example extends MailingTargets
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \brief This is to add a form filter to provide variant of selector
|
* This is to add a form filter to provide variant of selector
|
||||||
* If used, the HTML select must be called "filter"
|
* If used, the HTML select must be called "filter"
|
||||||
* \return string A html select zone
|
*
|
||||||
|
* @return string A html select zone
|
||||||
*/
|
*/
|
||||||
function formFilter()
|
function formFilter()
|
||||||
{
|
{
|
||||||
@ -123,9 +127,10 @@ class mailing_example extends MailingTargets
|
|||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \brief Can include an URL link on each record provided by selector
|
* Can include an URL link on each record provided by selector
|
||||||
* shown on target page.
|
* shown on target page.
|
||||||
* \return string Url link
|
*
|
||||||
|
* @return string Url link
|
||||||
*/
|
*/
|
||||||
function url($id)
|
function url($id)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -47,12 +47,25 @@ class mailing_fraise extends MailingTargets
|
|||||||
var $db;
|
var $db;
|
||||||
|
|
||||||
|
|
||||||
function mailing_fraise($DB)
|
/**
|
||||||
|
* Constructor
|
||||||
|
*
|
||||||
|
* @param DoliDB $db Database handler
|
||||||
|
*/
|
||||||
|
function mailing_fraise($db)
|
||||||
{
|
{
|
||||||
$this->db=$DB;
|
$this->db=$db;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* On the main mailing area, there is a box with statistics.
|
||||||
|
* If you want to add a line in this report you must provide an
|
||||||
|
* array of SQL request that returns two field:
|
||||||
|
* One called "label", One called "nb".
|
||||||
|
*
|
||||||
|
* @return array Array with SQL requests
|
||||||
|
*/
|
||||||
function getSqlArrayForStats()
|
function getSqlArrayForStats()
|
||||||
{
|
{
|
||||||
global $langs;
|
global $langs;
|
||||||
|
|||||||
@ -40,11 +40,11 @@ class mailing_framboise extends MailingTargets
|
|||||||
/**
|
/**
|
||||||
* Constructor
|
* Constructor
|
||||||
*
|
*
|
||||||
* @param DoliDB $DB Database handler
|
* @param DoliDB $db Database handler
|
||||||
*/
|
*/
|
||||||
function mailing_framboise($DB)
|
function mailing_framboise($db)
|
||||||
{
|
{
|
||||||
$this->db=$DB;
|
$this->db=$db;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -118,11 +118,12 @@ class mailing_framboise extends MailingTargets
|
|||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \brief On the main mailing area, there is a box with statistics.
|
* On the main mailing area, there is a box with statistics.
|
||||||
* If you want to add a line in this report you must provide an
|
* If you want to add a line in this report you must provide an
|
||||||
* array of SQL request that returns two field:
|
* array of SQL request that returns two field:
|
||||||
* One called "label", One called "nb".
|
* One called "label", One called "nb".
|
||||||
* \return array
|
*
|
||||||
|
* @return array Array with SQL requests
|
||||||
*/
|
*/
|
||||||
function getSqlArrayForStats()
|
function getSqlArrayForStats()
|
||||||
{
|
{
|
||||||
|
|||||||
@ -39,11 +39,11 @@ class MailingTargets // This can't be abstract as it is used for some method
|
|||||||
/**
|
/**
|
||||||
* Constructor
|
* Constructor
|
||||||
*
|
*
|
||||||
* @param DoliDB $DB Database handler
|
* @param DoliDB $db Database handler
|
||||||
*/
|
*/
|
||||||
function MailingTargets($DB)
|
function MailingTargets($db)
|
||||||
{
|
{
|
||||||
$this->db = $DB;
|
$this->db = $db;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@ -40,12 +40,25 @@ class mailing_peche extends MailingTargets
|
|||||||
var $db;
|
var $db;
|
||||||
|
|
||||||
|
|
||||||
function mailing_peche($DB)
|
/**
|
||||||
|
* Constructor
|
||||||
|
*
|
||||||
|
* @param DoliDB $db Database handler
|
||||||
|
*/
|
||||||
|
function mailing_peche($db)
|
||||||
{
|
{
|
||||||
$this->db=$DB;
|
$this->db=$db;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* On the main mailing area, there is a box with statistics.
|
||||||
|
* If you want to add a line in this report you must provide an
|
||||||
|
* array of SQL request that returns two field:
|
||||||
|
* One called "label", One called "nb".
|
||||||
|
*
|
||||||
|
* @return array Array with SQL requests
|
||||||
|
*/
|
||||||
function getSqlArrayForStats()
|
function getSqlArrayForStats()
|
||||||
{
|
{
|
||||||
global $langs;
|
global $langs;
|
||||||
|
|||||||
@ -40,12 +40,25 @@ class mailing_pomme extends MailingTargets
|
|||||||
var $db;
|
var $db;
|
||||||
|
|
||||||
|
|
||||||
function mailing_pomme($DB)
|
/**
|
||||||
|
* Constructor
|
||||||
|
*
|
||||||
|
* @param DoliDB $db Database handler
|
||||||
|
*/
|
||||||
|
function mailing_pomme($db)
|
||||||
{
|
{
|
||||||
$this->db=$DB;
|
$this->db=$db;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* On the main mailing area, there is a box with statistics.
|
||||||
|
* If you want to add a line in this report you must provide an
|
||||||
|
* array of SQL request that returns two field:
|
||||||
|
* One called "label", One called "nb".
|
||||||
|
*
|
||||||
|
* @return array Array with SQL requests
|
||||||
|
*/
|
||||||
function getSqlArrayForStats()
|
function getSqlArrayForStats()
|
||||||
{
|
{
|
||||||
global $conf, $langs;
|
global $conf, $langs;
|
||||||
|
|||||||
@ -37,9 +37,14 @@ class mailing_thirdparties extends MailingTargets
|
|||||||
var $db;
|
var $db;
|
||||||
|
|
||||||
|
|
||||||
function mailing_thirdparties($DB)
|
/**
|
||||||
|
* Constructor
|
||||||
|
*
|
||||||
|
* @param DoliDB $DB Database handler
|
||||||
|
*/
|
||||||
|
function mailing_thirdparties($db)
|
||||||
{
|
{
|
||||||
$this->db=$DB;
|
$this->db=$db;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -113,11 +118,12 @@ class mailing_thirdparties extends MailingTargets
|
|||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \brief On the main mailing area, there is a box with statistics.
|
* On the main mailing area, there is a box with statistics.
|
||||||
* If you want to add a line in this report you must provide an
|
* If you want to add a line in this report you must provide an
|
||||||
* array of SQL request that returns two field:
|
* array of SQL request that returns two field:
|
||||||
* One called "label", One called "nb".
|
* One called "label", One called "nb".
|
||||||
* \return array
|
*
|
||||||
|
* @return array Array with SQL requests
|
||||||
*/
|
*/
|
||||||
function getSqlArrayForStats()
|
function getSqlArrayForStats()
|
||||||
{
|
{
|
||||||
|
|||||||
@ -36,12 +36,11 @@ class mailing_thirdparties_services_expired extends MailingTargets
|
|||||||
/**
|
/**
|
||||||
* Constructor
|
* Constructor
|
||||||
*
|
*
|
||||||
* @param DoliDB $DB Database handler
|
* @param DoliDB $db Database handler
|
||||||
* @return mailing_thirdparties_services_expired
|
|
||||||
*/
|
*/
|
||||||
function mailing_thirdparties_services_expired($DB)
|
function mailing_thirdparties_services_expired($db)
|
||||||
{
|
{
|
||||||
$this->db=$DB;
|
$this->db=$db;
|
||||||
|
|
||||||
$this->arrayofproducts=array();
|
$this->arrayofproducts=array();
|
||||||
|
|
||||||
@ -152,11 +151,12 @@ class mailing_thirdparties_services_expired extends MailingTargets
|
|||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \brief On the main mailing area, there is a box with statistics.
|
* On the main mailing area, there is a box with statistics.
|
||||||
* If you want to add a line in this report you must provide an
|
* If you want to add a line in this report you must provide an
|
||||||
* array of SQL request that returns two field:
|
* array of SQL request that returns two field:
|
||||||
* One called "label", One called "nb".
|
* One called "label", One called "nb".
|
||||||
* \return array
|
*
|
||||||
|
* @return array Array with SQL requests
|
||||||
*/
|
*/
|
||||||
function getSqlArrayForStats()
|
function getSqlArrayForStats()
|
||||||
{
|
{
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user