*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -42,11 +42,13 @@ class Notify
var $fk_project;
// Les codes actions sont definis dans la table llx_notify_def
+ // \todo utiliser des codes texte plutot que numerique
+ // 1 = Validation fiche inter
+ // 2 = Validation facture
/**
- * Constructor
- *
- * @param DoliDB $DB Database handler
+ * \brief Constructeur
+ * \param DB Handler acces base
*/
function Notify($DB)
{
diff --git a/htdocs/core/class/rssparser.class.php b/htdocs/core/class/rssparser.class.php
index fbe033ec3a6..6b61cedc60a 100755
--- a/htdocs/core/class/rssparser.class.php
+++ b/htdocs/core/class/rssparser.class.php
@@ -448,10 +448,10 @@ class RssParser
* Triggered when CDATA is found
*
* @param $p
- * @param $text Tag
+ * @param $element Tag
+ * @param $attrs Attributes of tags
*/
- function feed_cdata($p, $text)
- {
+ function feed_cdata ($p, $text) {
if ($this->_format == 'atom' and $this->incontent)
{
$this->append_content( $text );
@@ -466,10 +466,9 @@ class RssParser
* Triggered when closed tag is found
*
* @param $p
- * @param $el Tag
+ * @param $element Tag
*/
- function feed_end_element($p, $el)
- {
+ function feed_end_element ($p, $el) {
$el = strtolower($el);
if ( $el == 'item' or $el == 'entry' )
@@ -521,8 +520,7 @@ class RssParser
* @param $str1
* @param $str2
*/
- function concat(&$str1, $str2="")
- {
+ function concat (&$str1, $str2="") {
if (!isset($str1) ) {
$str1="";
}
@@ -531,8 +529,7 @@ class RssParser
/**
*/
- function append_content($text)
- {
+ function append_content($text) {
if ( $this->initem ) {
$this->concat( $this->current_item[ $this->incontent ], $text );
}
@@ -544,8 +541,7 @@ class RssParser
/**
* smart append - field and namespace aware
*/
- function append($el, $text)
- {
+ function append($el, $text) {
if (!$el) {
return;
}
diff --git a/htdocs/core/class/smtps.class.php b/htdocs/core/class/smtps.php
similarity index 98%
rename from htdocs/core/class/smtps.class.php
rename to htdocs/core/class/smtps.php
index f4a8c4008a8..d4d37affff1 100755
--- a/htdocs/core/class/smtps.class.php
+++ b/htdocs/core/class/smtps.php
@@ -2103,7 +2103,7 @@ class SMTPs
* @return void
*
*/
- function setAttachment($strContent, $strFileName = 'unknown', $strMimeType = 'unknown')
+ function setAttachment ( $strContent, $strFileName = 'unknown', $strMimeType = 'unknown' )
{
if ( $strContent )
{
@@ -2120,23 +2120,21 @@ class SMTPs
// DOL_CHANGE LDR
-
/**
- * Method public void setImageInline( string )
- *
- * Image attachments are added to the content array as sub-arrays,
- * allowing for multiple images for each outbound email
- *
- * @param string $strContent Image data to attach to message
- * @param string $strImageName Image Name to give to attachment
- * @param string $strMimeType Image Mime Type of attachment
- * @param string $strImageCid CID
- * @return void
- *
- */
- function setImageInline($strContent, $strImageName = 'unknown', $strMimeType = 'unknown', $strImageCid = 'unknown')
+ * Method public void setImageInline( string )
+ *
+ * Image attachments are added to the content array as sub-arrays,
+ * allowing for multiple images for each outbound email
+ *
+ * @param string $strContent Image data to attach to message
+ * @param string $strImageName Image Name to give to attachment
+ * @param string $strMimeType Image Mime Type of attachment
+ * @return void
+ *
+ */
+ function setImageInline ( $strContent, $strImageName = 'unknown', $strMimeType = 'unknown', $strImageCid = 'unknown' )
{
- if ($strContent)
+ if ( $strContent )
{
$this->_msgContent['image'][$strImageName]['mimeType'] = $strMimeType;
$this->_msgContent['image'][$strImageName]['imageName'] = $strImageName;
@@ -2172,7 +2170,7 @@ class SMTPs
* @return void
*
*/
- function setSensitivity($_value = 0)
+ function setSensitivity ( $_value = 0 )
{
if ( ( is_numeric ($_value) ) &&
( ( $_value >= 0 ) && ( $_value <= 3 ) ) )
@@ -2518,10 +2516,7 @@ class SMTPs
// ** CSV Version Control Info
/**
- * $Log: smtps.class.php,v $
- * Revision 1.1 2011/09/03 00:14:27 eldy
- * Doxygen
- *
+ * $Log: smtps.php,v $
* Revision 1.4 2011/08/28 14:24:23 eldy
* Doxygen
*
diff --git a/htdocs/install/check.php b/htdocs/install/check.php
index 44369ab7634..bbcdfc2ff5b 100644
--- a/htdocs/install/check.php
+++ b/htdocs/install/check.php
@@ -193,7 +193,7 @@ else
else
{
# If failed, we try to create an empty file
- dolibarr_install_syslog("failed to copy file ".$conffile.".example into ".$conffile.". We try to create it.", LOG_WARNING);
+ dolibarr_install_syslog("failed to copy file ".$conffile.".example into ".$conffile.". We try to create it.");
$fp = @fopen($conffile, "w");
if ($fp)
@@ -203,7 +203,6 @@ else
@fputs($fp,"?>");
fclose($fp);
}
- else dolibarr_install_syslog("failed to create a new file ".$conffile." into current dir ".getcwd().". Check permission.", LOG_ERR);
}
// First install, on ne peut pas upgrader
diff --git a/htdocs/lib/CMailFile.class.php b/htdocs/lib/CMailFile.class.php
index 307c2f7391c..2a719fc4085 100644
--- a/htdocs/lib/CMailFile.class.php
+++ b/htdocs/lib/CMailFile.class.php
@@ -234,7 +234,7 @@ class CMailFile
// Use SMTPS library
// ------------------------------------------
- require_once(DOL_DOCUMENT_ROOT."/core/class/smtps.class.php");
+ require_once(DOL_DOCUMENT_ROOT."/core/class/smtps.php");
$smtps = new SMTPs();
$smtps->setCharSet($conf->file->character_set_client);
diff --git a/htdocs/lib/functions.lib.php b/htdocs/lib/functions.lib.php
index c5f2144ce8c..afb4aea298c 100644
--- a/htdocs/lib/functions.lib.php
+++ b/htdocs/lib/functions.lib.php
@@ -2572,70 +2572,78 @@ function print_liste_field_titre($name, $file="", $field="", $begin="", $morepar
/**
* Get title line of an array
- *
* @param name Label of field
* @param thead For thead format
* @param file Url used when we click on sort picto
* @param field Field to use for new sorting
* @param begin ("" by defaut)
* @param moreparam Add more parameters on sort url links ("" by default)
- * @param moreattrib Add more attributes on th ("" by defaut)
+ * @param td Options of attribute td ("" by defaut)
* @param sortfield Current field used to sort
* @param sortorder Current sort order
*/
-function getTitleFieldOfList($name, $thead=0, $file="", $field="", $begin="", $moreparam="", $moreattrib="", $sortfield="", $sortorder="")
+function getTitleFieldOfList($name, $thead=0, $file="", $field="", $begin="", $moreparam="", $td="", $sortfield="", $sortorder="")
{
global $conf;
- //print "$name, $file, $field, $begin, $options, $moreattrib, $sortfield, $sortorder
\n";
+ //print "$name, $file, $field, $begin, $options, $td, $sortfield, $sortorder
\n";
$out='';
- // If field is used as sort criteria we use a specific class
- // Example if (sortfield,field)=("nom","xxx.nom") or (sortfield,field)=("nom","nom")
- if ($field && ($sortfield == $field || $sortfield == preg_replace("/^[^\.]+\./","",$field)))
+
+ if ($thead)
{
- $out.= '';
+ $out.= ' | '.$name.' | ';
}
else
{
- $out.= '';
- }
- $out.=$name;
+ // Le champ de tri est mis en evidence.
+ // Exemple si (sortfield,field)=("nom","xxx.nom") ou (sortfield,field)=("nom","nom")
+ if ($field && ($sortfield == $field || $sortfield == preg_replace("/^[^\.]+\./","",$field)))
+ {
+ $out.= ' | ';
+ }
+ else
+ {
+ $out.= ' | ';
+ }
+ $out.= $name;
- if (empty($thead) && $field) // If this is a sort field
- {
- $options=preg_replace('/sortfield=([a-zA-Z0-9,\s\.]+)/i','',$moreparam);
- $options=preg_replace('/sortorder=([a-zA-Z0-9,\s\.]+)/i','',$options);
- $options=preg_replace('/&+/i','&',$options);
- if (! preg_match('/^&/',$options)) $options='&'.$options;
+ // If this is a sort field
+ if ($field)
+ {
+ $options=preg_replace('/sortfield=([a-zA-Z0-9,\s\.]+)/i','',$moreparam);
+ $options=preg_replace('/sortorder=([a-zA-Z0-9,\s\.]+)/i','',$options);
+ $options=preg_replace('/&+/i','&',$options);
+ if (! preg_match('/^&/',$options)) $options='&'.$options;
- //print " ";
- $out.= ' ';
- if (! $sortorder)
- {
- $out.= ''.img_down("A-Z",0).'';
- $out.= ''.img_up("Z-A",0).'';
- }
- else
- {
- if ($field != $sortfield)
- {
- $out.= ''.img_down("A-Z",0).'';
- $out.= ''.img_up("Z-A",0).'';
- }
- else {
- $sortorder=strtoupper($sortorder);
- if ($sortorder == 'DESC' ) {
- $out.= ''.img_down("A-Z",0).'';
- $out.= ''.img_up("Z-A",1).'';
- }
- if ($sortorder == 'ASC' ) {
- $out.= ''.img_down("A-Z",1).'';
- $out.= ''.img_up("Z-A",0).'';
- }
- }
- }
+ //print " ";
+ $out.= ' ';
+ if (! $sortorder)
+ {
+ $out.= ''.img_down("A-Z",0).'';
+ $out.= ''.img_up("Z-A",0).'';
+ }
+ else
+ {
+ if ($field != $sortfield)
+ {
+ $out.= ''.img_down("A-Z",0).'';
+ $out.= ''.img_up("Z-A",0).'';
+ }
+ else {
+ $sortorder=strtoupper($sortorder);
+ if ($sortorder == 'DESC' ) {
+ $out.= ''.img_down("A-Z",0).'';
+ $out.= ''.img_up("Z-A",1).'';
+ }
+ if ($sortorder == 'ASC' ) {
+ $out.= ''.img_down("A-Z",1).'';
+ $out.= ''.img_up("Z-A",0).'';
+ }
+ }
+ }
+ }
+ $out.= " | ";
}
- $out.='';
return $out;
}
@@ -2664,7 +2672,6 @@ function print_fiche_titre($titre, $mesg='', $picto='title.png', $pictoisfullpat
/**
* Load a title with picto
- *
* @param titre Title to show
* @param mesg Added message to show on right
* @param picto Icon to use before title (should be a 32x32 transparent png file)
@@ -2697,7 +2704,6 @@ function load_fiche_titre($titre, $mesg='', $picto='title.png', $pictoisfullpath
/**
* Print a title with navigation controls for pagination
- *
* @param titre Title to show (required)
* @param page Numero of page (required)
* @param file Url of page (required)
@@ -2807,7 +2813,6 @@ function print_barre_liste($titre, $page, $file, $options='', $sortfield='', $so
/**
* Fonction servant a afficher les fleches de navigation dans les pages de listes
- *
* @param page Numero of page
* @param file Lien
* @param options Autres parametres d'url a propager dans les liens ("" par defaut)
@@ -2832,7 +2837,6 @@ function print_fleche_navigation($page,$file,$options='',$nextpage,$betweenarrow
/**
* Fonction qui retourne un taux de tva formate pour visualisation
* Utilisee dans les pdf et les pages html
- *
* @param rate Rate value to format (19.6 19,6 19.6% 19,6%,...)
* @param addpercent Add a percent % sign in output
* @param info_bits Miscellanous information on vat
@@ -2861,7 +2865,6 @@ function vatrate($rate,$addpercent=false,$info_bits=0)
/**
* Fonction qui formate un montant pour visualisation
* Fonction utilisee dans les pdf et les pages html
- *
* @param amount Montant a formater
* @param html Type de formatage, html ou pas (par defaut)
* @param outlangs Objet langs pour formatage text
@@ -2934,8 +2937,7 @@ function price($amount, $html=0, $outlangs='', $trunc=1, $rounding=-1, $forcerou
/**
* Function that return a number with universal decimal format (decimal separator is '.') from
* an amount typed by a user.
- * Function to use on each input amount before any numeric test or database insert
- *
+ * Function to use on each input amount before any numeric test or database insert.
* @param amount Amount to convert/clean
* @param rounding ''=No rounding
* 'MU'=Round to Max unit price (MAIN_MAX_DECIMALS_UNIT)
@@ -3020,7 +3022,6 @@ function price2num($amount,$rounding='',$alreadysqlnb=0)
/**
* Return localtaxe rate for a particular tva
- *
* @param tva Vat taxe
* @param local Local taxe to search and return
* @param societe_acheteuse Object of buying third party
@@ -3059,8 +3060,7 @@ function get_localtax($tva, $local, $societe_acheteuse="")
/**
* Return vat rate of a product in a particular selling country or default country
- * vat if product is unknown
- *
+ * vat if product is unknown.
* @param idprod Id of product or 0 if not a predefined product
* @param countrycode Country code (FR, US, IT, ...)
* @return int <0 if KO, Vat rate if OK
@@ -3119,7 +3119,6 @@ function get_product_vat_for_country($idprod, $countrycode)
/**
* Return localtax rate of a product in a particular selling country
- *
* @param idprod Id of product
* @package local 1 for localtax1, 2 for localtax 2
* @param countrycode Country code (FR, US, IT, ...)
@@ -3277,7 +3276,6 @@ function get_default_localtax($societe_vendeuse, $societe_acheteuse, $local, $id
/**
* Return yes or no in current language
- *
* @param yesno Value to test (1, 'yes', 'true' or 0, 'no', 'false')
* @param case 1=Yes/No, 0=yes/no
* @param color 0=texte only, 1=Text is formated with a color font style ('ok' or 'error'), 2=Text is formated with 'ok' color.
@@ -3306,7 +3304,6 @@ function yn($yesno, $case=1, $color=0)
* Return a path to have a directory according to an id
* Examples: '001' with level 3->"0/0/1/", '015' with level 3->"0/1/5/"
* Examples: 'ABC-1' with level 3 ->"0/0/1/", '015' with level 1->"5/"
- *
* @param $num Id to develop
* @param $level Level of development (1, 2 or 3 level)
* @param $alpha Use alpha ref
@@ -3333,7 +3330,6 @@ function create_exdir($dir)
/**
* Creation of a directory (recursive)
- *
* @param $dir Directory to create
* @return int < 0 if KO, 0 = already exists, > 0 if OK
*/
@@ -3395,7 +3391,6 @@ function dol_mkdir($dir)
/**
* Return picto saying a field is required
- *
* @return string Chaine avec picto obligatoire
*/
function picto_required()
@@ -3406,7 +3401,6 @@ function picto_required()
/**
* Clean a string from all HTML tags and entities
- *
* @param StringHtml String to clean
* @param removelinefeed Replace also all lines feeds by a space
* @return string String cleaned
@@ -3431,8 +3425,7 @@ function dol_string_nohtmltag($StringHtml,$removelinefeed=1)
/**
- * Replace CRLF in string with a HTML BR tag
- *
+ * Replace CRLF in string with a HTML BR tag.
* @param stringtoencode String to encode
* @param nl2brmode 0=Adding br before \n, 1=Replacing \n by br
* @param forxml false=Use
, true=Use
@@ -3462,8 +3455,7 @@ function dol_nl2br($stringtoencode,$nl2brmode=0,$forxml=false)
* - writeHTMLCell -> param must be encoded into HTML.
* - MultiCell -> param must not be encoded into HTML.
* Because writeHTMLCell convert also \n into
, if function
- * is used to build PDF, nl2brmode must be 1
- *
+ * is used to build PDF, nl2brmode must be 1.
* @param stringtoencode String to encode
* @param nl2brmode 0=Adding br before \n, 1=Replacing \n by br (for use with FPDF writeHTMLCell function for example)
* @param pagecodefrom Pagecode stringtoencode is encoded
@@ -3490,7 +3482,6 @@ function dol_htmlentitiesbr($stringtoencode,$nl2brmode=0,$pagecodefrom='UTF-8')
/**
* This function is called to decode a HTML string (it decodes entities and br tags)
- *
* @param stringtodecode String to decode
* @param pagecodeto Page code for result
*/
@@ -3506,7 +3497,6 @@ function dol_htmlentitiesbr_decode($stringtodecode,$pagecodeto='UTF-8')
/**
* This function remove all ending \n and br at end
- *
* @param stringtodecode String to decode
*/
function dol_htmlcleanlastbr($stringtodecode)
@@ -3517,7 +3507,6 @@ function dol_htmlcleanlastbr($stringtodecode)
/**
* This function is called to decode a string with HTML entities (it decodes entities tags)
- *
* @param stringhtml stringhtml
* @param pagecodeto Encoding of input string
* @return string decodestring
@@ -3530,7 +3519,6 @@ function dol_entity_decode($stringhtml,$pagecodeto='UTF-8')
/**
* Replace html_entity_decode functions to manage errors
- *
* @param a
* @param b
* @param c
@@ -3545,7 +3533,6 @@ function dol_html_entity_decode($a,$b,$c)
/**
* Replace htmlentities functions to manage errors
- *
* @param a
* @param b
* @param c
@@ -3562,8 +3549,7 @@ function dol_htmlentities($a,$b,$c)
/**
* Check if a string is a correct iso string
* If not, it will we considered not HTML encoded even if it is by FPDF.
- * Example, if string contains euro symbol that has ascii code 128
- *
+ * Example, if string contains euro symbol that has ascii code 128.
* @param s String to check
* @return int 0 if bad iso, 1 if good iso
*/
@@ -3584,7 +3570,6 @@ function dol_string_is_good_iso($s)
/**
* Return nb of lines of a clear text
- *
* @param s String to check
* @param maxchar Not yet used
* @return int Number of lines
@@ -3601,7 +3586,6 @@ function dol_nboflines($s,$maxchar=0)
/**
* Return nb of lines of a formated text with \n and
- *
* @param text Text
* @param maxlinesize Largeur de ligne en caracteres (ou 0 si pas de limite - defaut)
* @param charset Give the charset used to encode the $text variable in memory.
@@ -3638,7 +3622,6 @@ function dol_nboflines_bis($text,$maxlinesize=0,$charset='UTF-8')
/**
* Same function than microtime in PHP 5 but compatible with PHP4
- *
* @return float Time (millisecondes) with microsecondes in decimal part
*/
function dol_microtime_float()
@@ -3649,7 +3632,6 @@ function dol_microtime_float()
/**
* Return if a text is a html content
- *
* @param msg Content to check
* @param option 0=Full detection, 1=Fast check
* @return boolean true/false
@@ -4112,8 +4094,7 @@ function verifCond($strRights)
/**
* Replace eval function to add more security.
- * This function is called by verifCond()
- *
+ * This function is called by verifCond().
* @param string $s
*/
function dol_eval($s)
diff --git a/htdocs/lib/tax.lib.php b/htdocs/lib/tax.lib.php
index 29bf272ebd6..1cd19bc8765 100644
--- a/htdocs/lib/tax.lib.php
+++ b/htdocs/lib/tax.lib.php
@@ -64,7 +64,7 @@ function vat_by_thirdparty($db, $y, $date_start, $date_end, $modetax, $direction
// If vat paid on due invoices (non draft)
if ($conf->global->MAIN_MODULE_ACCOUNTING)
{
- // TODO a ce jour on se sait pas la compter car le montant tva d'un payment
+ // \todo a ce jour on se sait pas la compter car le montant tva d'un payment
// n'est pas stocke dans la table des payments.
// Seul le module compta expert peut resoudre ce probleme.
// (Il faut quand un payment a lieu, stocker en plus du montant du paiement le
@@ -102,7 +102,7 @@ function vat_by_thirdparty($db, $y, $date_start, $date_end, $modetax, $direction
if ($conf->global->MAIN_MODULE_ACCOUNTING)
{
// If vat paid on payments
- // TODO a ce jour on se sait pas la compter car le montant tva d'un payment
+ // \todo a ce jour on se sait pas la compter car le montant tva d'un payment
// n'est pas stocke dans la table des payments.
// Seul le module compta expert peut resoudre ce probleme.
// (Il faut quand un payment a lieu, stocker en plus du montant du paiement le
@@ -215,7 +215,7 @@ function vat_by_date($db, $y, $q, $date_start, $date_end, $modetax, $direction,
{
if ($conf->global->MAIN_MODULE_ACCOUNTING)
{
- // TODO a ce jour on se sait pas la compter car le montant tva d'un payment
+ // \todo a ce jour on se sait pas la compter car le montant tva d'un payment
// n'est pas stocke dans la table des payments.
// Seul le module compta expert peut resoudre ce probleme.
// (Il faut quand un payment a lieu, stocker en plus du montant du paiement le
@@ -261,7 +261,7 @@ function vat_by_date($db, $y, $q, $date_start, $date_end, $modetax, $direction,
{
if ($conf->global->MAIN_MODULE_ACCOUNTING)
{
- // TODO a ce jour on se sait pas la compter car le montant tva d'un payment
+ // \todo a ce jour on se sait pas la compter car le montant tva d'un payment
// n'est pas stocke dans la table des payments.
// Seul le module compta expert peut resoudre ce probleme.
// (Il faut quand un payment a lieu, stocker en plus du montant du paiement le
@@ -376,7 +376,7 @@ function vat_by_date($db, $y, $q, $date_start, $date_end, $modetax, $direction,
if ($conf->global->MAIN_MODULE_ACCOUNTING)
{
// Count on invoice date
- // TODO a ce jour on se sait pas la compter car le montant tva d'un payment
+ // \todo a ce jour on se sait pas la compter car le montant tva d'un payment
// n'est pas stocke dans la table des payments.
// Seul le module compta expert peut resoudre ce probleme.
// (Il faut quand un payment a lieu, stocker en plus du montant du paiement le
@@ -423,7 +423,7 @@ function vat_by_date($db, $y, $q, $date_start, $date_end, $modetax, $direction,
if ($conf->global->MAIN_MODULE_ACCOUNTING)
{
// Count on payments date
- // TODO a ce jour on se sait pas la compter car le montant tva d'un payment
+ // \todo a ce jour on se sait pas la compter car le montant tva d'un payment
// n'est pas stocke dans la table des payments.
// Seul le module compta expert peut resoudre ce probleme.
// (Il faut quand un paiement a lieu, stocker en plus du montant du paiement le
diff --git a/htdocs/product/canvas/service/actions_card_service.class.php b/htdocs/product/canvas/service/actions_card_service.class.php
index 225eeca5f29..ad9f1cb5666 100755
--- a/htdocs/product/canvas/service/actions_card_service.class.php
+++ b/htdocs/product/canvas/service/actions_card_service.class.php
@@ -16,7 +16,7 @@
*/
/**
- * \file htdocs/product/canvas/service/actions_card_service.class.php
+ * \file htdocs/product/canvas/service/product.service.class.php
* \ingroup service
* \brief Fichier de la classe des services par defaut
*/
diff --git a/htdocs/product/class/product.class.php b/htdocs/product/class/product.class.php
index 1babd5f2e19..b803dce5844 100644
--- a/htdocs/product/class/product.class.php
+++ b/htdocs/product/class/product.class.php
@@ -2485,7 +2485,7 @@ class Product extends CommonObject
if (file_exists($dir_osencoded))
{
// Cree fichier en taille vignette
- // TODO A faire
+ // \todo A faire
// Cree fichier en taille origine
$content = @file_get_contents($file);
diff --git a/htdocs/societe/class/companybankaccount.class.php b/htdocs/societe/class/companybankaccount.class.php
index fcb39a66b56..dd149caf89a 100644
--- a/htdocs/societe/class/companybankaccount.class.php
+++ b/htdocs/societe/class/companybankaccount.class.php
@@ -17,7 +17,7 @@
*/
/**
- * \file htdocs/societe/class/companybankaccount.class.php
+ * \files htdocs/societe/class/companybankaccount.class.php
* \ingroup societe
* \brief File of class to manage bank accounts description of third parties
*/
@@ -26,159 +26,159 @@ require_once(DOL_DOCUMENT_ROOT ."/compta/bank/class/account.class.php");
/**
- * \brief Class to manage bank accounts description of third parties
+ * \brief Class to manage bank accounts description of third parties
*/
class CompanyBankAccount extends Account
{
- var $rowid;
- var $socid;
+ var $rowid;
+ var $socid;
- var $bank;
- var $courant;
- var $clos;
- var $code_banque;
- var $code_guichet;
- var $number;
- var $cle_rib;
- var $bic;
- var $iban;
- var $iban_prefix; // deprecated
- var $proprio;
- var $adresse_proprio;
+ var $bank;
+ var $courant;
+ var $clos;
+ var $code_banque;
+ var $code_guichet;
+ var $number;
+ var $cle_rib;
+ var $bic;
+ var $iban;
+ var $iban_prefix; // deprecated
+ var $proprio;
+ var $adresse_proprio;
- /**
- * Constructor
- */
- function CompanyBankAccount($DB)
- {
- $this->db = $DB;
+ /**
+ * Constructor
+ */
+ function CompanyBankAccount($DB)
+ {
+ $this->db = $DB;
- $this->socid = 0;
- $this->clos = 0;
- $this->solde = 0;
- $this->error_number = 0;
- return 1;
- }
+ $this->socid = 0;
+ $this->clos = 0;
+ $this->solde = 0;
+ $this->error_number = 0;
+ return 1;
+ }
- /**
- * Create bank information record
- *
- */
- function create()
- {
- $sql = "INSERT INTO ".MAIN_DB_PREFIX."societe_rib (fk_soc, datec) values ($this->socid, ".$this->db->idate(mktime()).")";
+ /**
+ * Create bank information record
+ *
+ */
+ function create()
+ {
+ $sql = "INSERT INTO ".MAIN_DB_PREFIX."societe_rib (fk_soc, datec) values ($this->socid, ".$this->db->idate(mktime()).")";
$resql=$this->db->query($sql);
- if ($resql)
- {
- if ($this->db->affected_rows($resql))
- {
- return 1;
- }
- }
- else
- {
- print $this->db->error();
- return 0;
- }
- }
+ if ($resql)
+ {
+ if ($this->db->affected_rows($resql))
+ {
+ return 1;
+ }
+ }
+ else
+ {
+ print $this->db->error();
+ return 0;
+ }
+ }
- /**
- *
- *
- */
- function update($user='')
- {
+ /**
+ *
+ *
+ */
+ function update($user='')
+ {
- $sql = "SELECT fk_soc FROM ".MAIN_DB_PREFIX."societe_rib";
- $sql .= " WHERE fk_soc = ".$this->socid;
+ $sql = "SELECT fk_soc FROM ".MAIN_DB_PREFIX."societe_rib";
+ $sql .= " WHERE fk_soc = ".$this->socid;
- $result = $this->db->query($sql);
- if ($result)
- {
- if ($this->db->num_rows($result) == 0)
- {
- $this->create();
- }
- }
- else
- {
- dol_print_error($this->db);
- return 0;
- }
+ $result = $this->db->query($sql);
+ if ($result)
+ {
+ if ($this->db->num_rows($result) == 0)
+ {
+ $this->create();
+ }
+ }
+ else
+ {
+ dol_print_error($this->db);
+ return 0;
+ }
- $sql = "UPDATE ".MAIN_DB_PREFIX."societe_rib SET ";
- $sql .= " bank = '" .$this->db->escape($this->bank)."'";
- $sql .= ",code_banque='".$this->code_banque."'";
- $sql .= ",code_guichet='".$this->code_guichet."'";
- $sql .= ",number='".$this->number."'";
- $sql .= ",cle_rib='".$this->cle_rib."'";
- $sql .= ",bic='".$this->bic."'";
- $sql .= ",iban_prefix = '".$this->iban_prefix."'";
- $sql .= ",domiciliation='".$this->db->escape($this->domiciliation)."'";
- $sql .= ",proprio = '".$this->db->escape($this->proprio)."'";
- $sql .= ",adresse_proprio = '".$this->db->escape($this->adresse_proprio)."'";
- $sql .= " WHERE fk_soc = ".$this->socid;
+ $sql = "UPDATE ".MAIN_DB_PREFIX."societe_rib SET ";
+ $sql .= " bank = '" .$this->db->escape($this->bank)."'";
+ $sql .= ",code_banque='".$this->code_banque."'";
+ $sql .= ",code_guichet='".$this->code_guichet."'";
+ $sql .= ",number='".$this->number."'";
+ $sql .= ",cle_rib='".$this->cle_rib."'";
+ $sql .= ",bic='".$this->bic."'";
+ $sql .= ",iban_prefix = '".$this->iban_prefix."'";
+ $sql .= ",domiciliation='".$this->db->escape($this->domiciliation)."'";
+ $sql .= ",proprio = '".$this->db->escape($this->proprio)."'";
+ $sql .= ",adresse_proprio = '".$this->db->escape($this->adresse_proprio)."'";
+ $sql .= " WHERE fk_soc = ".$this->socid;
- $result = $this->db->query($sql);
- if ($result)
- {
- return 1;
- }
- else
- {
- dol_print_error($this->db);
- return 0;
- }
- }
+ $result = $this->db->query($sql);
+ if ($result)
+ {
+ return 1;
+ }
+ else
+ {
+ dol_print_error($this->db);
+ return 0;
+ }
+ }
- /**
- * Load record from database
- * @param id Id of record
- * @param socid Id of company
- */
- function fetch($id,$socid=0)
- {
- if (empty($id) && empty($socid)) return -1;
+ /**
+ * Load record from database
+ * @param id Id of record
+ * @param socid Id of company
+ */
+ function fetch($id,$socid=0)
+ {
+ if (empty($id) && empty($socid)) return -1;
- $sql = "SELECT rowid, fk_soc, bank, number, code_banque, code_guichet, cle_rib, bic, iban_prefix as iban, domiciliation, proprio, adresse_proprio";
- $sql.= " FROM ".MAIN_DB_PREFIX."societe_rib";
- if ($id) $sql.= " WHERE rowid = ".$id;
- if ($socid) $sql.= " WHERE fk_soc = ".$socid;
+ $sql = "SELECT rowid, fk_soc, bank, number, code_banque, code_guichet, cle_rib, bic, iban_prefix as iban, domiciliation, proprio, adresse_proprio";
+ $sql.= " FROM ".MAIN_DB_PREFIX."societe_rib";
+ if ($id) $sql.= " WHERE rowid = ".$id;
+ if ($socid) $sql.= " WHERE fk_soc = ".$socid;
- $resql = $this->db->query($sql);
- if ($resql)
- {
- if ($this->db->num_rows($resql))
- {
- $obj = $this->db->fetch_object($resql);
+ $resql = $this->db->query($sql);
+ if ($resql)
+ {
+ if ($this->db->num_rows($resql))
+ {
+ $obj = $this->db->fetch_object($resql);
- $this->id = $obj->rowid;
+ $this->id = $obj->rowid;
$this->socid = $obj->fk_soc;
- $this->bank = $obj->bank;
- $this->courant = $obj->courant;
- $this->clos = $obj->clos;
- $this->code_banque = $obj->code_banque;
- $this->code_guichet = $obj->code_guichet;
- $this->number = $obj->number;
- $this->cle_rib = $obj->cle_rib;
- $this->bic = $obj->bic;
- $this->iban = $obj->iban;
- $this->iban_prefix = $obj->iban; // deprecated
- $this->domiciliation = $obj->domiciliation;
- $this->proprio = $obj->proprio;
- $this->adresse_proprio = $obj->adresse_proprio;
- }
- $this->db->free($resql);
+ $this->bank = $obj->bank;
+ $this->courant = $obj->courant;
+ $this->clos = $obj->clos;
+ $this->code_banque = $obj->code_banque;
+ $this->code_guichet = $obj->code_guichet;
+ $this->number = $obj->number;
+ $this->cle_rib = $obj->cle_rib;
+ $this->bic = $obj->bic;
+ $this->iban = $obj->iban;
+ $this->iban_prefix = $obj->iban; // deprecated
+ $this->domiciliation = $obj->domiciliation;
+ $this->proprio = $obj->proprio;
+ $this->adresse_proprio = $obj->adresse_proprio;
+ }
+ $this->db->free($resql);
- return 1;
- }
- else
- {
- dol_print_error($this->db);
- return -1;
- }
- }
+ return 1;
+ }
+ else
+ {
+ dol_print_error($this->db);
+ return -1;
+ }
+ }
}
diff --git a/htdocs/societe/class/societe.class.php b/htdocs/societe/class/societe.class.php
index b766c82ac11..348d1d3255d 100644
--- a/htdocs/societe/class/societe.class.php
+++ b/htdocs/societe/class/societe.class.php
@@ -1545,16 +1545,14 @@ class Societe extends CommonObject
/**
* Return list of contacts emails existing for third party
- *
- * @param int $addthirdparty 1=Add also a record for thirdparty email
- * @return array Array of contacts emails
+ * @return array Array of contacts emails
*/
- function thirdparty_and_contact_email_array($addthirdparty=0)
+ function thirdparty_and_contact_email_array()
{
global $langs;
$contact_emails = $this->contact_property_array('email');
- if ($this->email && $addthirdparty)
+ if ($this->email)
{
if (empty($this->name)) $this->name=$this->nom;
// TODO: Tester si email non deja present dans tableau contact
@@ -1565,7 +1563,6 @@ class Societe extends CommonObject
/**
* Return list of contacts mobile phone existing for third party
- *
* @return array Array of contacts emails
*/
function thirdparty_and_contact_phone_array()
@@ -1584,7 +1581,6 @@ class Societe extends CommonObject
/**
* Return list of contacts emails or mobile existing for third party
- *
* @param mode 'email' or 'mobile'
* @return array Array of contacts emails or mobile
*/
@@ -1595,7 +1591,6 @@ class Societe extends CommonObject
$sql = "SELECT rowid, email, phone_mobile, name, firstname";
$sql.= " FROM ".MAIN_DB_PREFIX."socpeople";
$sql.= " WHERE fk_soc = '".$this->id."'";
-
$resql=$this->db->query($sql);
if ($resql)
{
@@ -1622,9 +1617,8 @@ class Societe extends CommonObject
/**
- * Renvoie la liste des contacts de cette societe
- *
- * @return array tableau des contacts
+ * \brief Renvoie la liste des contacts de cette societe
+ * \return array tableau des contacts
*/
function contact_array()
{
@@ -1655,7 +1649,6 @@ class Societe extends CommonObject
/**
* Return property of contact from its id
- *
* @param rowid id of contact
* @param mode 'email' or 'mobile'
* @return string email of contact
@@ -1691,9 +1684,7 @@ class Societe extends CommonObject
/**
- * Return bank number property of thirdparty
- *
- * @return string Bank number
+ * \brief Affiche le rib
*/
function display_rib()
{
diff --git a/htdocs/societe/notify/fiche.php b/htdocs/societe/notify/fiche.php
index 13f9dd0dcc0..4cd8d8b046f 100644
--- a/htdocs/societe/notify/fiche.php
+++ b/htdocs/societe/notify/fiche.php
@@ -33,12 +33,8 @@ $langs->load("mails");
$langs->load("admin");
$langs->load("other");
-$socid = GETPOST("socid",'int');
-$action = GETPOST('action');
-$contactid=GETPOST('contactid'); // May be an int or 'thirdparty'
-$actionid=GETPOST('actionid');
-
// Security check
+$socid = isset($_GET["socid"])?$_GET["socid"]:'';
if ($user->societe_id) $socid=$user->societe_id;
$result = restrictedArea($user, 'societe','','');
@@ -52,71 +48,41 @@ $pagenext = $page + 1;
if (! $sortorder) $sortorder="ASC";
if (! $sortfield) $sortfield="c.name";
-$now=dol_now();
-
/*
- * Actions
+ * Action
*/
// Add a notification
-if ($action == 'add')
+if ($_POST["action"] == 'add')
{
- $error=0;
+ $sql = "DELETE FROM ".MAIN_DB_PREFIX."notify_def";
+ $sql .= " WHERE fk_soc=".$socid." AND fk_contact=".$_POST["contactid"]." AND fk_action=".$_POST["actionid"];
+ if ($db->query($sql))
+ {
+ $sql = "INSERT INTO ".MAIN_DB_PREFIX."notify_def (datec,fk_soc, fk_contact, fk_action)";
+ $sql .= " VALUES (".$db->idate(mktime()).",".$socid.",".$_POST["contactid"].",".$_POST["actionid"].")";
- if (empty($contactid))
- {
- $mesg=''.$langs->trans("ErrorFieldRequired",$langs->transnoentitiesnoconv("Contact")).'
';
- $error++;
- }
- if ($actionid <= 0)
- {
- $mesg=''.$langs->trans("ErrorFieldRequired",$langs->transnoentitiesnoconv("Action")).'
';
- $error++;
- }
+ if ($db->query($sql))
+ {
- if (! $error)
- {
- $db->begin();
-
- $sql = "DELETE FROM ".MAIN_DB_PREFIX."notify_def";
- $sql .= " WHERE fk_soc=".$socid." AND fk_contact=".$contactid." AND fk_action=".$actionid;
- if ($db->query($sql))
- {
- $sql = "INSERT INTO ".MAIN_DB_PREFIX."notify_def (datec,fk_soc, fk_contact, fk_action)";
- $sql .= " VALUES ('".$db->idate($now)."',".$socid.",".$contactid.",".$actionid.")";
-
- if ($db->query($sql))
- {
-
- }
- else
- {
- $error++;
- dol_print_error($db);
- }
- }
- else
- {
- dol_print_error($db);
- }
-
- if (! $error)
- {
- $db->commit();
- }
- else
- {
- $db->rollback();
- }
- }
+ }
+ else
+ {
+ dol_print_error($db);
+ }
+ }
+ else
+ {
+ dol_print_error($db);
+ }
}
// Remove a notification
-if ($action == 'delete')
+if ($_GET["action"] == 'delete')
{
- $sql = "DELETE FROM ".MAIN_DB_PREFIX."notify_def where rowid=".$_GET["actid"].";";
- $db->query($sql);
+ $sql = "DELETE FROM ".MAIN_DB_PREFIX."notify_def where rowid=".$_GET["actid"].";";
+ $db->query($sql);
}
@@ -129,106 +95,79 @@ $form = new Form($db);
llxHeader();
-$object = new Societe($db);
-$result=$object->fetch($socid);
+$soc = new Societe($db);
+$soc->id = $socid;
-if ($result > 0)
+if ( $soc->fetch($soc->id) )
{
- $html = new Form($db);
- $langs->load("other");
+ $html = new Form($db);
+ $langs->load("other");
- $head = societe_prepare_head($object);
+ $head = societe_prepare_head($soc);
- dol_fiche_head($head, 'notify', $langs->trans("ThirdParty"),0,'company');
+ dol_fiche_head($head, 'notify', $langs->trans("ThirdParty"),0,'company');
- print '';
+ print '';
- print '| '.$langs->trans("ThirdPartyName").' | ';
- print $form->showrefnav($object,'socid','',($user->societe_id?0:1),'rowid','nom');
- print ' |
';
+ print '| '.$langs->trans("ThirdPartyName").' | ';
+ print $form->showrefnav($soc,'socid','',($user->societe_id?0:1),'rowid','nom');
+ print ' |
';
- // Prefix
- if (! empty($conf->global->SOCIETE_USEPREFIX)) // Old not used prefix field
- {
- print '| '.$langs->trans('Prefix').' | '.$object->prefix_comm.' |
';
- }
+ print '| '.$langs->trans("NbOfActiveNotifications").' | ';
+ print '';
+ $sql = "SELECT COUNT(n.rowid) as nb";
+ $sql.= " FROM ".MAIN_DB_PREFIX."notify_def as n";
+ $sql.= " WHERE fk_soc = ".$soc->id;
+ $resql=$db->query($sql);
+ if ($resql)
+ {
+ $num = $db->num_rows($resql);
+ $i = 0;
+ while ($i < $num)
+ {
+ $obj = $db->fetch_object($resql);
+ $nb=$obj->nb;
+ $i++;
+ }
+ }
+ else {
+ dol_print_error($db);
+ }
+ print $nb;
+ print ' |
';
+ print '
';
- if ($object->client)
- {
- print '| ';
- print $langs->trans('CustomerCode').' | ';
- print $object->code_client;
- if ($object->check_codeclient() <> 0) print ' ('.$langs->trans("WrongCustomerCode").')';
- print ' |
';
- }
-
- if ($object->fournisseur)
- {
- print '| ';
- print $langs->trans('SupplierCode').' | ';
- print $object->code_fournisseur;
- if ($object->check_codefournisseur() <> 0) print ' ('.$langs->trans("WrongSupplierCode").')';
- print ' |
';
- }
-
- print '| '.$langs->trans("NbOfActiveNotifications").' | ';
- print '';
- $sql = "SELECT COUNT(n.rowid) as nb";
- $sql.= " FROM ".MAIN_DB_PREFIX."notify_def as n";
- $sql.= " WHERE fk_soc = ".$object->id;
- $resql=$db->query($sql);
- if ($resql)
- {
- $num = $db->num_rows($resql);
- $i = 0;
- while ($i < $num)
- {
- $obj = $db->fetch_object($resql);
- $nb=$obj->nb;
- $i++;
- }
- }
- else {
- dol_print_error($db);
- }
- print $nb;
- print ' |
';
- print '
';
-
- // Help
- print '
'.$langs->trans("NotificationsDesc").'
';
+ print '';
- dol_fiche_end();
+ // Help
+ print $langs->trans("NotificationsDesc").'
';
- print "\n";
+ print "\n";
- // Add notification form
- print_fiche_titre($langs->trans("AddNewNotification"),'','');
+ // Add notification form
+ print_fiche_titre($langs->trans("AddNewNotification"),'','');
- print '';
- print '
';
+ print '';
+ print '
';
- dol_htmloutput_mesg($mesg);
- // List of active notifications
- print_fiche_titre($langs->trans("ListOfActiveNotifications"),'','');
- $var=true;
+ // List of active notifications
+ print_fiche_titre($langs->trans("ListOfActiveNotifications"),'','');
+ $var=true;
- // Line with titles
- print '';
- print '';
- print_liste_field_titre($langs->trans("Contact"),"fiche.php","c.name",'',$param,'"width="45%"',$sortfield,$sortorder);
- print_liste_field_titre($langs->trans("Action"),"fiche.php","a.titre",'',$param,'"width="35%"',$sortfield,$sortorder);
+ // Line with titles
+ print '';
+ print '';
+ print_liste_field_titre($langs->trans("Contact"),"fiche.php","c.name",'',$param,'"width="45%"',$sortfield,$sortorder);
+ print_liste_field_titre($langs->trans("Action"),"fiche.php","a.titre",'',$param,'"width="35%"',$sortfield,$sortorder);
print_liste_field_titre($langs->trans("Type"),"fiche.php","",'',$param,'"width="10%"',$sortfield,$sortorder);
- print_liste_field_titre('','','');
- print '
';
+ print_liste_field_titre('','','');
+ print '';
- // List of notifications for contacts
- $sql = "SELECT n.rowid, n.type,";
- $sql.= " a.code, a.label,";
+ // List of notifications for contacts
+ $sql = "SELECT n.rowid, n.type,";
+ $sql.= " a.code, a.label,";
$sql.= " c.rowid as contactid, c.name, c.firstname, c.email";
- $sql.= " FROM ".MAIN_DB_PREFIX."c_action_trigger as a,";
- $sql.= " ".MAIN_DB_PREFIX."notify_def as n,";
- $sql.= " ".MAIN_DB_PREFIX."socpeople c";
- $sql.= " WHERE a.rowid = n.fk_action";
- $sql.= " AND c.rowid = n.fk_contact";
- $sql.= " AND c.fk_soc = ".$object->id;
+ $sql.= " FROM ".MAIN_DB_PREFIX."c_action_trigger as a,";
+ $sql.= " ".MAIN_DB_PREFIX."notify_def as n,";
+ $sql.= " ".MAIN_DB_PREFIX."socpeople c";
+ $sql.= " WHERE a.rowid = n.fk_action";
+ $sql.= " AND c.rowid = n.fk_contact";
+ $sql.= " AND c.fk_soc = ".$soc->id;
- $resql=$db->query($sql);
- if ($resql)
- {
- $num = $db->num_rows($resql);
- $i = 0;
+ $resql=$db->query($sql);
+ if ($resql)
+ {
+ $num = $db->num_rows($resql);
+ $i = 0;
- $contactstatic=new Contact($db);
+ $contactstatic=new Contact($db);
- while ($i < $num)
- {
- $var = !$var;
+ while ($i < $num)
+ {
+ $var = !$var;
- $obj = $db->fetch_object($resql);
+ $obj = $db->fetch_object($resql);
- $contactstatic->id=$obj->contactid;
- $contactstatic->name=$obj->name;
- $contactstatic->firstname=$obj->firstname;
- print '| '.$contactstatic->getNomUrl(1);
- if ($obj->type == 'email')
- {
- if (isValidEmail($obj->email))
- {
- print ' <'.$obj->email.'>';
- }
- else
- {
- $langs->load("errors");
- print ' '.img_warning().' '.$langs->trans("ErrorBadEMail",$obj->email);
- }
- }
- print ' | ';
- print '';
- $label=($langs->trans("Notify_".$obj->code)!="Notify_".$obj->code?$langs->trans("Notify_".$obj->code):$obj->label);
- print $label;
- print ' | ';
+ $contactstatic->id=$obj->contactid;
+ $contactstatic->name=$obj->name;
+ $contactstatic->firstname=$obj->firstname;
+ print '
| '.$contactstatic->getNomUrl(1);
+ if ($obj->type == 'email')
+ {
+ if (isValidEmail($obj->email))
+ {
+ print ' <'.$obj->email.'>';
+ }
+ else
+ {
+ $langs->load("errors");
+ print ' '.img_warning().' '.$langs->trans("ErrorBadEMail",$obj->email);
+ }
+ }
+ print ' | ';
+ print '';
+ $label=($langs->trans("Notify_".$obj->code)!="Notify_".$obj->code?$langs->trans("Notify_".$obj->code):$obj->label);
+ print $label;
+ print ' | ';
print '';
if ($obj->type == 'email') print $langs->trans("Email");
if ($obj->type == 'sms') print $langs->trans("SMS");
print ' | ';
print ''.img_delete().' | ';
- print '
';
- $i++;
- }
- $db->free($resql);
- }
- else
- {
- dol_print_error($db);
- }
+ print '';
+ $i++;
+ }
+ $db->free($resql);
+ }
+ else
+ {
+ dol_print_error($db);
+ }
- print '
';
- print '
';
+ print '
';
+ print '
';
- // List of notifications done
- print_fiche_titre($langs->trans("ListOfNotificationsDone"),'','');
- $var=true;
+ // List of notifications done
+ print_fiche_titre($langs->trans("ListOfNotificationsDone"),'','');
+ $var=true;
- // Line with titles
- print '';
- print '';
- print_liste_field_titre($langs->trans("Contact"),"fiche.php","c.name",'',$param,'',$sortfield,$sortorder);
- print_liste_field_titre($langs->trans("Action"),"fiche.php","a.titre",'',$param,'',$sortfield,$sortorder);
- print_liste_field_titre($langs->trans("Date"),"fiche.php","a.daten",'',$param,'align="right"',$sortfield,$sortorder);
- print '
';
+ // Line with titles
+ print '';
+ print '';
+ print_liste_field_titre($langs->trans("Contact"),"fiche.php","c.name",'',"&socid=$socid",'',$sortfield,$sortorder);
+ print_liste_field_titre($langs->trans("Action"),"fiche.php","a.titre",'',"&socid=$socid",'',$sortfield,$sortorder);
+ print_liste_field_titre($langs->trans("Date"),"fiche.php","a.titre",'',"&socid=$socid",'align="right"',$sortfield,$sortorder);
+ print '
';
- // List
- $sql = "SELECT n.rowid, n.daten, n.email, n.objet_type, n.objet_id,";
- $sql.= " c.rowid as id, c.name, c.firstname, c.email,";
- $sql.= " a.code, a.label";
- $sql.= " FROM ".MAIN_DB_PREFIX."c_action_trigger as a,";
- $sql.= " ".MAIN_DB_PREFIX."notify as n, ";
+ // List
+ $sql = "SELECT n.rowid, n.daten, n.email, n.objet_type, n.objet_id,";
+ $sql.= " c.rowid as id, c.name, c.firstname, c.email,";
+ $sql.= " a.code, a.label";
+ $sql.= " FROM ".MAIN_DB_PREFIX."c_action_trigger as a,";
+ $sql.= " ".MAIN_DB_PREFIX."notify as n, ";
$sql.= " ".MAIN_DB_PREFIX."socpeople as c";
$sql.= " WHERE a.rowid = n.fk_action";
$sql.= " AND c.rowid = n.fk_contact";
- $sql.= " AND c.fk_soc = ".$object->id;
+ $sql.= " AND c.fk_soc = ".$soc->id;
- $resql=$db->query($sql);
- if ($resql)
- {
- $num = $db->num_rows($resql);
- $i = 0;
+ $resql=$db->query($sql);
+ if ($resql)
+ {
+ $num = $db->num_rows($resql);
+ $i = 0;
- $contactstatic=new Contact($db);
+ $contactstatic=new Contact($db);
- while ($i < $num)
- {
- $var = !$var;
+ while ($i < $num)
+ {
+ $var = !$var;
- $obj = $db->fetch_object($resql);
+ $obj = $db->fetch_object($resql);
- $contactstatic->id=$obj->id;
- $contactstatic->name=$obj->name;
- $contactstatic->firstname=$obj->firstname;
- print '| '.$contactstatic->getNomUrl(1);
- print $obj->email?' <'.$obj->email.'>':$langs->trans("NoMail");
- print ' | ';
- print '';
- $label=($langs->trans("Notify_".$obj->code)!="Notify_".$obj->code?$langs->trans("Notify_".$obj->code):$obj->label);
- print $label;
- print ' | ';
- // TODO Add link to object here
- // print
- print''.dol_print_date($db->jdate($obj->daten), 'dayhour').' | ';
- print '
';
- $i++;
- }
- $db->free($resql);
- }
- else
- {
- dol_print_error($db);
- }
+ $contactstatic->id=$obj->id;
+ $contactstatic->name=$obj->name;
+ $contactstatic->firstname=$obj->firstname;
+ print '| '.$contactstatic->getNomUrl(1);
+ print $obj->email?' <'.$obj->email.'>':$langs->trans("NoMail");
+ print ' | ';
+ print '';
+ $label=($langs->trans("Notify_".$obj->code)!="Notify_".$obj->code?$langs->trans("Notify_".$obj->code):$obj->label);
+ print $label;
+ print ' | ';
+ // TODO Add link to object here
+ // print
+ print''.dol_print_date($db->jdate($obj->daten), 'dayhour').' | ';
+ print '
';
+ $i++;
+ }
+ $db->free($resql);
+ }
+ else
+ {
+ dol_print_error($db);
+ }
- print '
';
+ print '
';
}
-else dol_print_error('','RecordNotFound');
$db->close();
diff --git a/htdocs/theme/auguria/style.css.php b/htdocs/theme/auguria/style.css.php
index fb0d19d721c..e8c7b805f8f 100644
--- a/htdocs/theme/auguria/style.css.php
+++ b/htdocs/theme/auguria/style.css.php
@@ -1200,68 +1200,64 @@ padding: 0px 0px;
/* For lists */
table.liste {
- width: 100%;
- border-collapse: collapse;
- border-top-color: #FEFEFE;
+width: 100%;
+border-collapse: collapse;
+border-top-color: #FEFEFE;
- border-left-width: 1px;
- border-left-color: #BBBBBB;
- border-left-style: solid;
+border-left-width: 1px;
+border-left-color: #BBBBBB;
+border-left-style: solid;
- border-right-width: 1px;
- border-right-color: #BBBBBB;
- border-right-style: solid;
+border-right-width: 1px;
+border-right-color: #BBBBBB;
+border-right-style: solid;
- border-bottom-width: 1px;
- border-bottom-color: #BBBBBB;
- border-bottom-style: solid;
+border-bottom-width: 1px;
+border-bottom-color: #BBBBBB;
+border-bottom-style: solid;
- margin-bottom: 2px;
- margin-top: 0px;
+margin-bottom: 2px;
+margin-top: 0px;
- -moz-box-shadow: 4px 4px 4px #CCC;
- -webkit-box-shadow: 4px 4px 4px #CCC;
- box-shadow: 4px 4px 4px #CCC;
+-moz-box-shadow: 4px 4px 4px #CCC;
+-webkit-box-shadow: 4px 4px 4px #CCC;
+box-shadow: 4px 4px 4px #CCC;
}
table.liste td {
- padding-right: 2px;
+padding-right: 2px;
}
-tr.liste_titre
-{
- height: 24px;
- background: #7699A9;
- background-image: url();
- background-repeat: repeat-x;
- color: #FFFFFF;
- font-family: ;
- /* border-bottom: 1px solid #FDFFFF; */
- white-space: nowrap;
+tr.liste_titre {
+height: 24px;
+background: #7699A9;
+background-image: url();
+background-repeat: repeat-x;
+color: #FFFFFF;
+font-family: ;
+/* border-bottom: 1px solid #FDFFFF; */
+white-space: nowrap;
}
-th.liste_titre, td.liste_titre
-{
- background: #7699A9;
- background-image: url();
- background-repeat: repeat-x;
- color: #FFFFFF;
- font-family: ;
- font-weight: normal;
- /* border-bottom: 1px solid #FDFFFF; */
- white-space: nowrap;
- text-align: ;
+td.liste_titre {
+background: #7699A9;
+background-image: url();
+background-repeat: repeat-x;
+color: #FFFFFF;
+font-family: ;
+font-weight: normal;
+/* border-bottom: 1px solid #FDFFFF; */
+white-space: nowrap;
}
-th.liste_titre_sel, td.liste_titre_sel
+td.liste_titre_sel
{
- background: #7699A9;
- background-image: url();
- background-repeat: repeat-x;
- color: #FFFFFF;
- font-family: ;
- font-weight: normal;
- /* text-decoration: underline; */
- /* border-bottom: 1px solid #FDFFFF; */
- white-space: nowrap;
- text-align: ;
+background: #7699A9;
+background-image: url();
+background-repeat: repeat-x;
+color: #FFFFFF;
+font-family: ;
+font-weight: normal;
+/* text-decoration: underline; */
+/* border-bottom: 1px solid #FDFFFF; */
+white-space: nowrap;
}
input.liste_titre {
background: transparent;
@@ -1278,6 +1274,19 @@ font-weight: normal;
white-space: nowrap;
}
+th {
+/* background: #7699A9; */
+background: #91ABB3;
+color: #334444;
+font-family: ;
+font-weight: bold;
+border-left: 1px solid #FFFFFF;
+border-right: 1px solid #FFFFFF;
+border-top: 1px solid #FFFFFF;
+border-bottom: 1px solid #FFFFFF;
+white-space: nowrap;
+}
+
.impair {
/* background: #d0d4d7; */
background: #eaeaea;
diff --git a/htdocs/theme/bureau2crea/style.css.php b/htdocs/theme/bureau2crea/style.css.php
index 7312b757d11..4aa1e974344 100644
--- a/htdocs/theme/bureau2crea/style.css.php
+++ b/htdocs/theme/bureau2crea/style.css.php
@@ -1402,8 +1402,8 @@ tr.liste_titre:first-child {
background-position: top right;
}
-th.liste_titre_sel, td.liste_titre_sel,
-tr.liste_titre:first-child td {
+td.liste_titre_sel,
+tr.liste_titre:first-child td {
color: #FFFFFF !important;
}
@@ -1430,8 +1430,7 @@ tr.liste_titre td {
background: none !important;
}
-th.liste_titre, td.liste_titre
-{
+td.liste_titre {
background-repeat: repeat-x;
color: #333333;
font-family: ;
@@ -1439,7 +1438,6 @@ th.liste_titre, td.liste_titre
white-space: nowrap;
background-image: none;
background: none;
- text-align: ;
}
/*tr.liste_titre select.flat {
@@ -1455,8 +1453,7 @@ tr.liste_titre input.button {
/*margin: 30px 10px 10px 0px;*/
}
-th.liste_titre_sel, td.liste_titre_sel
-{
+td.liste_titre_sel {
background: #505050;
background-repeat: repeat-x;
color: #FFFFFF;
@@ -1465,7 +1462,6 @@ th.liste_titre_sel, td.liste_titre_sel
/* text-decoration: underline; */
/* border-bottom: 1px solid #FDFFFF; */
white-space: nowrap;
- text-align: ;
}
input.liste_titre {
@@ -1485,6 +1481,19 @@ white-space: nowrap;
padding: 5px;
}
+th {
+/* background: #7699A9; */
+background: #91ABB3;
+color: #334444;
+font-family: ;
+font-weight: bold;
+border-left: 1px solid #FFFFFF;
+border-right: 1px solid #FFFFFF;
+border-top: 1px solid #FFFFFF;
+border-bottom: 1px solid #FFFFFF;
+white-space: nowrap;
+}
+
.impair {
/* background: #d0d4d7; */
background: #eaeaea;
@@ -2212,7 +2221,7 @@ a.cke_dialog_ui_button
margin-left: -240px;
margin-bottom: 30px;
}
-
+
div#infoVersion {
position: relative;
width: 100%;
@@ -2222,14 +2231,14 @@ div#infoVersion {
font-size: 10px;
background-color: #D6D6D6;
}
-
+
div#logoBox {
position: relative;
width: 100%;
height: auto;
margin-top: 30px;
}
-
+
div#parameterBox {
position: relative;
width: 100%;
@@ -2240,14 +2249,14 @@ div#parameterBox {
background-repeat: no-repeat;
background-position: top center;
}
-
+
div#parameterBox div {
width: 100%;
height: 20px;
position: relative;
line-height: 20px;
}
-
+
div#parameterBox div label {
width: 190px;
text-align: right;
@@ -2255,7 +2264,7 @@ div#parameterBox div label {
float: left;
margin-right: 10px;
}
-
+
div#parameterBox div input[type="text"],
div#parameterBox div input[type="password"] {
width: 180px;
@@ -2263,12 +2272,12 @@ div#parameterBox div input[type="password"] {
font-size: 10px;
margin-top: 2px;
}
-
+
div#connectionLine {
margin: 10px 0px;
text-align: center;
}
-
+
div#logBox {
margin-top: 25px;
}
@@ -2276,7 +2285,7 @@ margin-top: 25px;
div.captchaBox {
margin-top: 10px;
}
-
+
div.captchaImg {
margin-bottom: 10px;
margin-top: 5px;
@@ -2286,7 +2295,7 @@ div.captchaImg {
img#captcha {
margin-left: 200px;
}
-
+
div#infoLogin {
width: 100%;
height: auto;
@@ -2305,11 +2314,11 @@ div.other {
left: 50%;
margin-left: -240px;
}
-
+
form.listactionsfilter img {
display: none;
}
-
+
form.listactionsfilter input[type="submit"] {
margin: 2px 0px;
}
diff --git a/htdocs/theme/cameleo/style.css.php b/htdocs/theme/cameleo/style.css.php
index 42f43efc8c8..4af783fde2d 100644
--- a/htdocs/theme/cameleo/style.css.php
+++ b/htdocs/theme/cameleo/style.css.php
@@ -1339,31 +1339,30 @@ table.liste td {
}
tr.liste_titre {
- height: 20px;
- color: #842F00;
- font-weight: bold;
- font-family: "Trebuchet MS",Arial,Helvetica,sans-serif;
- /*border-bottom: 1px solid #FDFFFF;*/
- border-radius: 8px;
- line-height: 18px;
- padding-left: 10px;
- padding-right: 10px;
- white-space: nowrap;
+height: 20px;
+color: #842F00;
+font-weight: bold;
+font-family: "Trebuchet MS",Arial,Helvetica,sans-serif;
+/*border-bottom: 1px solid #FDFFFF;*/
+border-radius: 8px;
+line-height: 18px;
+padding-left: 10px;
+padding-right: 10px;
+white-space: nowrap;
}
-th.liste_titre, td.liste_titre
-{
+
+tr.liste_titre td {
padding-left: 6px;
- padding-right: 6px;
- /*vertical-align: text-top;*/
- text-align: ;
+ padding-right: 6px;
+ /*vertical-align: text-top;*/
}
-th.liste_titre_sel, td.liste_titre_sel
+
+td.liste_titre_sel
{
- background-position: top right;
- color: #A51B00;
- font-weight: bold;
- white-space: nowrap;
- text-align: ;
+background-position: top right;
+color: #A51B00;
+font-weight: bold;
+white-space: nowrap;
}
input.liste_titre {
@@ -1384,6 +1383,19 @@ font-weight: normal;
white-space: nowrap;
}
+th {
+/* background: #7699A9; */
+background: #91ABB3;
+color: #334444;
+font-family: ;
+font-weight: bold;
+border-left: 1px solid #FFFFFF;
+border-right: 1px solid #FFFFFF;
+border-top: 1px solid #FFFFFF;
+border-bottom: 1px solid #FFFFFF;
+white-space: nowrap;
+}
+
.impair {
/* background: #d0d4d7; */
background: #eaeaea;
diff --git a/htdocs/theme/eldy/style.css.php b/htdocs/theme/eldy/style.css.php
index 58e2ced4c1e..9de61eaaa77 100644
--- a/htdocs/theme/eldy/style.css.php
+++ b/htdocs/theme/eldy/style.css.php
@@ -228,12 +228,12 @@ div.fichecenter {
div.fichethirdleft {
browser->phone)) { print "float: ".$left.";\n"; } ?>
browser->phone)) { print "width: 35%;\n"; } ?>
- browser->phone)) { print "padding-bottom: 6px;\n"; } ?>
+ browser->phone)) { print "padding-bottom: 6px;\n"; } ?>
}
div.fichetwothirdright {
browser->phone)) { print "float: ".$left.";\n"; } ?>
browser->phone)) { print "width: 65%;\n"; } ?>
- browser->phone)) { print "padding-bottom: 6px\n"; } ?>
+ browser->phone)) { print "padding-bottom: 6px\n"; } ?>
}
div.fichehalfleft {
browser->phone)) { print "float: ".$left.";\n"; } ?>
@@ -1222,63 +1222,59 @@ padding: 0px 0px;
/* For lists */
table.liste {
- width: 100%;
- border-collapse: collapse;
- border-top-color: #FEFEFE;
+width: 100%;
+border-collapse: collapse;
+border-top-color: #FEFEFE;
- border-right-width: 1px;
- border-right-color: #BBBBBB;
- border-right-style: solid;
+border-right-width: 1px;
+border-right-color: #BBBBBB;
+border-right-style: solid;
- border-bottom-width: 1px;
- border-bottom-color: #BBBBBB;
- border-bottom-style: solid;
+border-bottom-width: 1px;
+border-bottom-color: #BBBBBB;
+border-bottom-style: solid;
- margin-bottom: 2px;
- margin-top: 0px;
+margin-bottom: 2px;
+margin-top: 0px;
- -moz-box-shadow: 4px 4px 4px #CCC;
- -webkit-box-shadow: 4px 4px 4px #CCC;
- box-shadow: 4px 4px 4px #CCC;
+-moz-box-shadow: 4px 4px 4px #CCC;
+-webkit-box-shadow: 4px 4px 4px #CCC;
+box-shadow: 4px 4px 4px #CCC;
}
table.liste td {
- padding-right: 2px;
+padding-right: 2px;
}
-tr.liste_titre
-{
- height: 20px !important;
- background: #7699A9;
- background-image: url();
- background-repeat: repeat-x;
- color: #334444;
- font-family: ;
- border-bottom: 1px solid #FDFFFF;
- white-space: nowrap;
+tr.liste_titre {
+height: 20px !important;
+background: #7699A9;
+background-image: url();
+background-repeat: repeat-x;
+color: #334444;
+font-family: ;
+border-bottom: 1px solid #FDFFFF;
+white-space: nowrap;
}
-th.liste_titre, td.liste_titre
-{
- background: #7699A9;
- background-image: url();
- background-repeat: repeat-x;
- color: #334444;
- font-family: ;
- font-weight: normal;
- border-bottom: 1px solid #FDFFFF;
- white-space: nowrap;
- text-align: ;
+td.liste_titre {
+background: #7699A9;
+background-image: url();
+background-repeat: repeat-x;
+color: #334444;
+font-family: ;
+font-weight: normal;
+border-bottom: 1px solid #FDFFFF;
+white-space: nowrap;
}
-th.liste_titre_sel, td.liste_titre_sel
+td.liste_titre_sel
{
- background: #7699A9;
- background-image: url();
- background-repeat: repeat-x;
- color: #F5FFFF;
- font-family: ;
- font-weight: normal;
- border-bottom: 1px solid #FDFFFF;
- white-space: nowrap;
- text-align: ;
+background: #7699A9;
+background-image: url();
+background-repeat: repeat-x;
+color: #F5FFFF;
+font-family: ;
+font-weight: normal;
+border-bottom: 1px solid #FDFFFF;
+white-space: nowrap;
}
input.liste_titre {
background: #7699A9;
@@ -1296,6 +1292,18 @@ font-weight: normal;
white-space: nowrap;
}
+th {
+/* background: #7699A9; */
+background: #91ABB3;
+color: #334444;
+font-family: ;
+font-weight: bold;
+border-left: 1px solid #FFFFFF;
+border-right: 1px solid #FFFFFF;
+border-top: 1px solid #FFFFFF;
+border-bottom: 1px solid #FFFFFF;
+white-space: nowrap;
+}
.impair {
/* background: #d0d4d7; */
diff --git a/htdocs/theme/phones/smartphone/theme/default/default.css.php b/htdocs/theme/phones/smartphone/theme/default/default.css.php
index fc8f9494057..89048687034 100644
--- a/htdocs/theme/phones/smartphone/theme/default/default.css.php
+++ b/htdocs/theme/phones/smartphone/theme/default/default.css.php
@@ -127,8 +127,8 @@ input.ui-input-text, textarea.ui-input-text {
/* ============================================================================== */
div.fiche {
- margin-: browser->phone)?'10':'2'); ?>px;
- margin-: browser->phone)?'6':''); ?>px;
+ margin-: browser->phone)?'10':'2'; ?>px;
+ margin-: browser->phone)?'6':''; ?>px;
}
div.fichecenter {
@@ -316,37 +316,33 @@ padding: 0px 0px;
-tr.liste_titre
-{
- height: 24px;
- background: -moz-linear-gradient(center top , #81A8CE, #5E87B0) repeat scroll 0 0 #5E87B0;
- border: 1px solid #456F9A;
- color: #FFFFFF;
- font-family: ;
- /* border-bottom: 1px solid #FDFFFF; */
- white-space: nowrap;
+tr.liste_titre {
+height: 24px;
+background: -moz-linear-gradient(center top , #81A8CE, #5E87B0) repeat scroll 0 0 #5E87B0;
+border: 1px solid #456F9A;
+color: #FFFFFF;
+font-family: ;
+/* border-bottom: 1px solid #FDFFFF; */
+white-space: nowrap;
}
-th.liste_titre, td.liste_titre
-{
- background: -moz-linear-gradient(center top , #81A8CE, #5E87B0) repeat scroll 0 0 #5E87B0;
- border: 1px solid #456F9A;
- color: #FFFFFF;
- font-family: ;
- font-weight: normal;
- /* border-bottom: 1px solid #FDFFFF; */
- white-space: nowrap;
- text-align: ;
+td.liste_titre {
+background: -moz-linear-gradient(center top , #81A8CE, #5E87B0) repeat scroll 0 0 #5E87B0;
+border: 1px solid #456F9A;
+color: #FFFFFF;
+font-family: ;
+font-weight: normal;
+/* border-bottom: 1px solid #FDFFFF; */
+white-space: nowrap;
}
-th.liste_titre_sel, td.liste_titre_sel
+td.liste_titre_sel
{
- background: -moz-linear-gradient(center top , #81A8CE, #5E87B0) repeat scroll 0 0 #5E87B0;
- color: #FFFFFF;
- font-family: ;
- font-weight: normal;
- /* text-decoration: underline; */
- /* border-bottom: 1px solid #FDFFFF; */
- white-space: nowrap;
- text-align: ;
+background: -moz-linear-gradient(center top , #81A8CE, #5E87B0) repeat scroll 0 0 #5E87B0;
+color: #FFFFFF;
+font-family: ;
+font-weight: normal;
+/* text-decoration: underline; */
+/* border-bottom: 1px solid #FDFFFF; */
+white-space: nowrap;
}
input.liste_titre {
background: transparent;