Qual: All call to dolibarr_ functions are made on dol_ functions.

This commit is contained in:
Laurent Destailleur
2009-02-20 22:53:15 +00:00
parent 68779862f1
commit 0823322ba1
742 changed files with 4472 additions and 4464 deletions

View File

@@ -175,7 +175,7 @@ for ($s = 0 ; $s < GEN_NUMBER_COMMANDE ; $s++)
$result=$com->add_product($prodids[$prodid],rand(1,11),rand(1,6),rand(0,20));
if ($result < 0)
{
dolibarr_print_error($db,$propal->error);
dol_print_error($db,$propal->error);
}
$xnbp++;
}
@@ -187,12 +187,12 @@ for ($s = 0 ; $s < GEN_NUMBER_COMMANDE ; $s++)
if ($result) print " OK";
else
{
dolibarr_print_error($db,$com->error);
dol_print_error($db,$com->error);
}
}
else
{
dolibarr_print_error($db,$facture->error);
dol_print_error($db,$facture->error);
}
print "\n";

View File

@@ -119,12 +119,12 @@ while ($i < GEN_NUMBER_FACTURE && $result >= 0)
if ($result) print " OK";
else
{
dolibarr_print_error($db,$facture->error);
dol_print_error($db,$facture->error);
}
}
else
{
dolibarr_print_error($db,$facture->error);
dol_print_error($db,$facture->error);
}
print "\n";

View File

@@ -149,7 +149,7 @@ while ($i < GEN_NUMBER_PROPAL && $result >= 0)
$result=$propal->addline($propal->id, 'Description '.$xnbp, '100', rand(1,5), '19.6', $prodids[$prodid], 0);
if ($result < 0)
{
dolibarr_print_error($db,$propal->error);
dol_print_error($db,$propal->error);
}
$xnbp++;
}
@@ -157,7 +157,7 @@ while ($i < GEN_NUMBER_PROPAL && $result >= 0)
}
else
{
dolibarr_print_error($db,$propal->error);
dol_print_error($db,$propal->error);
}
print "\n";

View File

@@ -94,7 +94,7 @@ class Skeleton_class // extends CommonObject
$this->db->begin();
dolibarr_syslog(get_class($this)."::create sql=".$sql, LOG_DEBUG);
dol_syslog(get_class($this)."::create sql=".$sql, LOG_DEBUG);
$resql=$this->db->query($sql);
if (! $resql) { $error++; $this->errors[]="Error ".$this->db->lasterror(); }
@@ -121,7 +121,7 @@ class Skeleton_class // extends CommonObject
{
foreach($this->errors as $errmsg)
{
dolibarr_syslog(get_class($this)."::create ".$errmsg, LOG_ERR);
dol_syslog(get_class($this)."::create ".$errmsg, LOG_ERR);
$this->error.=($this->error?', '.$errmsg:$errmsg);
}
$this->db->rollback();
@@ -151,7 +151,7 @@ class Skeleton_class // extends CommonObject
$sql.= " FROM ".MAIN_DB_PREFIX."mytable as t";
$sql.= " WHERE t.rowid = ".$id;
dolibarr_syslog(get_class($this)."::fetch sql=".$sql, LOG_DEBUG);
dol_syslog(get_class($this)."::fetch sql=".$sql, LOG_DEBUG);
$resql=$this->db->query($sql);
if ($resql)
{
@@ -171,7 +171,7 @@ class Skeleton_class // extends CommonObject
else
{
$this->error="Error ".$this->db->lasterror();
dolibarr_syslog(get_class($this)."::fetch ".$this->error, LOG_ERR);
dol_syslog(get_class($this)."::fetch ".$this->error, LOG_ERR);
return -1;
}
}
@@ -205,7 +205,7 @@ class Skeleton_class // extends CommonObject
$this->db->begin();
dolibarr_syslog(get_class($this)."::update sql=".$sql, LOG_DEBUG);
dol_syslog(get_class($this)."::update sql=".$sql, LOG_DEBUG);
$resql = $this->db->query($sql);
if (! $resql) { $error++; $this->errors[]="Error ".$this->db->lasterror(); }
@@ -230,7 +230,7 @@ class Skeleton_class // extends CommonObject
{
foreach($this->errors as $errmsg)
{
dolibarr_syslog(get_class($this)."::update ".$errmsg, LOG_ERR);
dol_syslog(get_class($this)."::update ".$errmsg, LOG_ERR);
$this->error.=($this->error?', '.$errmsg:$errmsg);
}
$this->db->rollback();
@@ -260,7 +260,7 @@ class Skeleton_class // extends CommonObject
$this->db->begin();
dolibarr_syslog(get_class($this)."::delete sql=".$sql);
dol_syslog(get_class($this)."::delete sql=".$sql);
$resql = $this->db->query($sql);
if (! $resql) { $error++; $this->errors[]="Error ".$this->db->lasterror(); }
@@ -285,7 +285,7 @@ class Skeleton_class // extends CommonObject
{
foreach($this->errors as $errmsg)
{
dolibarr_syslog(get_class($this)."::delete ".$errmsg, LOG_ERR);
dol_syslog(get_class($this)."::delete ".$errmsg, LOG_ERR);
$this->error.=($this->error?', '.$errmsg:$errmsg);
}
$this->db->rollback();

View File

@@ -70,37 +70,37 @@ $myobject=new Skeleton_class($db);
// Example for inserting creating object in database
/*
dolibarr_syslog($script_file." CREATE", LOG_DEBUG);
dol_syslog($script_file." CREATE", LOG_DEBUG);
$myobject->prop1='value_prop1';
$myobject->prop2='value_prop2';
$id=$myobject->create($user);
if ($id < 0) dolibarr_print_error($db,$myobject->error);
if ($id < 0) dol_print_error($db,$myobject->error);
else print "Object created with id=".$id."\n";
*/
// Example for reading object from database
/*
dolibarr_syslog($script_file." FETCH", LOG_DEBUG);
dol_syslog($script_file." FETCH", LOG_DEBUG);
$result=$myobject->fetch($id);
if ($result < 0) dolibarr_print_error($db,$myobject->error);
if ($result < 0) dol_print_error($db,$myobject->error);
else print "Object with id=".$id." loaded\n";
*/
// Example for updating object in database ($myobject must have been loaded by a fetch before)
/*
dolibarr_syslog($script_file." UPDATE", LOG_DEBUG);
dol_syslog($script_file." UPDATE", LOG_DEBUG);
$myobject->prop1='newvalue_prop1';
$myobject->prop2='newvalue_prop2';
$result=$myobject->update($user);
if ($result < 0) dolibarr_print_error($db,$myobject->error);
if ($result < 0) dol_print_error($db,$myobject->error);
else print "Object with id ".$myobject->id." updated\n";
*/
// Example for deleting object in database ($myobject must have been loaded by a fetch before)
/*
dolibarr_syslog($script_file." DELETE", LOG_DEBUG);
dol_syslog($script_file." DELETE", LOG_DEBUG);
$result=$myobject->delete($user);
if ($result < 0) dolibarr_print_error($db,$myobject->error);
if ($result < 0) dol_print_error($db,$myobject->error);
else print "Object with id ".$myobject->id." deleted\n";
*/
@@ -112,7 +112,7 @@ $sql.= " FROM ".MAIN_DB_PREFIX."c_pays";
$sql.= " WHERE field3 = 'xxx'";
$sql.= " ORDER BY field1 ASC";
dolibarr_syslog($script_file." sql=".$sql, LOG_DEBUG);
dol_syslog($script_file." sql=".$sql, LOG_DEBUG);
$resql=$db->query($sql);
if ($resql)
{
@@ -135,7 +135,7 @@ if ($resql)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
exit;
}
*/

View File

@@ -79,14 +79,14 @@ class AccountancyAccount
{
$result = -2;
$this->error="AccountancyAccount::Create Erreur $result";
dolibarr_syslog($this->error);
dol_syslog($this->error);
}
}
else
{
$result = -1;
$this->error="AccountancyAccount::Create Erreur $result";
dolibarr_syslog($this->error);
dol_syslog($this->error);
}
return $result;

View File

@@ -79,14 +79,14 @@ class AccountancySystem
{
$result = -2;
$this->error="AccountancySystem::Create Erreur $result";
dolibarr_syslog($this->error);
dol_syslog($this->error);
}
}
else
{
$result = -1;
$this->error="AccountancySystem::Create Erreur $result";
dolibarr_syslog($this->error);
dol_syslog($this->error);
}
return $result;

View File

@@ -173,7 +173,7 @@ class ActionComm
$sql.= ($this->orderrowid?$this->orderrowid:"null");
$sql.= ")";
dolibarr_syslog("ActionComm::add sql=".$sql);
dol_syslog("ActionComm::add sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
{
@@ -226,7 +226,7 @@ class ActionComm
$sql.= " FROM ".MAIN_DB_PREFIX."actioncomm as a, ".MAIN_DB_PREFIX."c_actioncomm as c";
$sql.= " WHERE a.id=".$id." AND a.fk_action=c.id";
dolibarr_syslog("ActionComm::fetch sql=".$sql);
dol_syslog("ActionComm::fetch sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
{
@@ -307,7 +307,7 @@ class ActionComm
$sql = "DELETE FROM ".MAIN_DB_PREFIX."actioncomm";
$sql.= " WHERE id=".$this->id;
dolibarr_syslog("ActionComm::delete sql=".$sql, LOG_DEBUG);
dol_syslog("ActionComm::delete sql=".$sql, LOG_DEBUG);
if ($this->db->query($sql))
{
return 1;
@@ -363,7 +363,7 @@ class ActionComm
$sql.= ", fk_user_done=".($this->userdone->id > 0 ? "'".$this->userdone->id."'":"null");
$sql.= " WHERE id=".$this->id;
dolibarr_syslog("ActionComm::update sql=".$sql);
dol_syslog("ActionComm::update sql=".$sql);
if ($this->db->query($sql))
{
return 1;
@@ -371,7 +371,7 @@ class ActionComm
else
{
$this->error=$this->db->error();
dolibarr_syslog("ActionComm::update ".$this->error,LOG_ERR);
dol_syslog("ActionComm::update ".$this->error,LOG_ERR);
return -1;
}
}
@@ -429,7 +429,7 @@ class ActionComm
$sql.= ' FROM '.MAIN_DB_PREFIX.'actioncomm as a';
$sql.= ' WHERE a.id = '.$id;
dolibarr_syslog("ActionComm::info sql=".$sql);
dol_syslog("ActionComm::info sql=".$sql);
$result=$this->db->query($sql);
if ($result)
{
@@ -457,7 +457,7 @@ class ActionComm
}
else
{
dolibarr_print_error($this->db);
dol_print_error($this->db);
}
}
@@ -546,7 +546,7 @@ class ActionComm
else
{
$libelle=$this->libelle;
$libelleshort=dolibarr_trunc($this->libelle,$maxlength);
$libelleshort=dol_trunc($this->libelle,$maxlength);
}
if ($withpicto) $result.=($lien.img_object($langs->trans("ShowAction").': '.$libelle,'task').$lienfin);
@@ -571,7 +571,7 @@ class ActionComm
require_once (DOL_DOCUMENT_ROOT ."/lib/xcal.lib.php");
dolibarr_syslog("ActionComm::build_exportfile Build export file format=".$format.", type=".$type.", cachedelay=".$cachedelay.", filename=".$filename.", filters size=".sizeof($filters), LOG_DEBUG);
dol_syslog("ActionComm::build_exportfile Build export file format=".$format.", type=".$type.", cachedelay=".$cachedelay.", filename=".$filename.", filters size=".sizeof($filters), LOG_DEBUG);
// Check parameters
if (empty($format)) return -1;
@@ -658,7 +658,7 @@ class ActionComm
//$sql.= " AND a.datep != 'null'"; // To exclude corrupted events and avoid errors in lightning/sunbird import
$sql.= " ORDER by datep";
dolibarr_syslog("ActionComm::build_exportfile select events sql=".$sql);
dol_syslog("ActionComm::build_exportfile select events sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
{
@@ -702,7 +702,7 @@ class ActionComm
else
{
$this->error=$this->db->lasterror();
dolibarr_syslog("ActionComm::build_exportfile ".$this->db->lasterror(), LOG_ERR);
dol_syslog("ActionComm::build_exportfile ".$this->db->lasterror(), LOG_ERR);
return -1;
}

View File

@@ -278,7 +278,7 @@ class Adherent extends CommonObject
$sql.= " '".$user->id."',null,null,'".$this->morphy."'";
$sql.= ")";
dolibarr_syslog("Adherent::create sql=".$sql);
dol_syslog("Adherent::create sql=".$sql);
$result = $this->db->query($sql);
if ($result)
{
@@ -348,7 +348,7 @@ class Adherent extends CommonObject
$nbrowsaffected=0;
$error=0;
dolibarr_syslog("Adherent::update notrigger=".$notrigger.", nosyncuser=".$nosyncuser.", email=".$this->email);
dol_syslog("Adherent::update notrigger=".$notrigger.", nosyncuser=".$nosyncuser.", email=".$this->email);
// Verification parametres
if ($conf->global->ADHERENT_MAIL_REQUIRED && ! ValidEMail($this->email))
@@ -385,7 +385,7 @@ class Adherent extends CommonObject
$sql.= ", fk_user_mod=".$user->id;
$sql.= " WHERE rowid = ".$this->id;
dolibarr_syslog("Adherent::update sql=".$sql);
dol_syslog("Adherent::update sql=".$sql);
$resql = $this->db->query($sql);
if ($resql)
{
@@ -394,7 +394,7 @@ class Adherent extends CommonObject
if (sizeof($this->array_options) > 0)
{
$sql_del = "DELETE FROM ".MAIN_DB_PREFIX."adherent_options WHERE adhid = ".$this->id;
dolibarr_syslog("Adherent::update sql=".$sql_del);
dol_syslog("Adherent::update sql=".$sql_del);
$this->db->query($sql_del);
$sql = "INSERT INTO ".MAIN_DB_PREFIX."adherent_options (adhid";
@@ -418,7 +418,7 @@ class Adherent extends CommonObject
}
$sql.=")";
dolibarr_syslog("Adherent::update sql=".$sql);
dol_syslog("Adherent::update sql=".$sql);
$resql = $this->db->query($sql);
if ($resql)
{
@@ -427,7 +427,7 @@ class Adherent extends CommonObject
else
{
$this->error=$this->db->error();
dolibarr_syslog("Adherent::update ".$this->error,LOG_ERR);
dol_syslog("Adherent::update ".$this->error,LOG_ERR);
$this->db->rollback();
return -2;
}
@@ -477,7 +477,7 @@ class Adherent extends CommonObject
if ($result < 0)
{
$this->error=$luser->error;
dolibarr_syslog("Adherent::update ".$this->error,LOG_ERR);
dol_syslog("Adherent::update ".$this->error,LOG_ERR);
$error++;
}
}
@@ -519,7 +519,7 @@ class Adherent extends CommonObject
$this->db->rollback();
$this->error=$this->db->lasterror();
dolibarr_syslog("Adherent::update ".$this->error,LOG_ERR);
dol_syslog("Adherent::update ".$this->error,LOG_ERR);
return -1;
}
}
@@ -544,7 +544,7 @@ class Adherent extends CommonObject
$sql.= " WHERE fk_adherent='".$this->id."'";
$sql.= " ORDER by dateadh DESC"; // Sort by start subscription date
dolibarr_syslog("Adherent::update_end_date sql=".$sql);
dol_syslog("Adherent::update_end_date sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
{
@@ -555,7 +555,7 @@ class Adherent extends CommonObject
$sql.= " datefin=".($datefin != '' ? "'".$this->db->idate($datefin)."'" : "null");
$sql.= " WHERE rowid = ".$this->id;
dolibarr_syslog("Adherent::update_end_date sql=".$sql);
dol_syslog("Adherent::update_end_date sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
{
@@ -571,7 +571,7 @@ class Adherent extends CommonObject
else
{
$this->error=$this->db->lasterror();
dolibarr_syslog("Adherent::update_end_date ".$this->error, LOG_ERR);
dol_syslog("Adherent::update_end_date ".$this->error, LOG_ERR);
$this->db->rollback();
return -1;
}
@@ -593,17 +593,17 @@ class Adherent extends CommonObject
// Suppression options
$sql = "DELETE FROM ".MAIN_DB_PREFIX."adherent_options WHERE adhid = ".$rowid;
dolibarr_syslog("Adherent::delete sql=".$sql);
dol_syslog("Adherent::delete sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
{
$sql = "DELETE FROM ".MAIN_DB_PREFIX."cotisation WHERE fk_adherent = ".$rowid;
dolibarr_syslog("Adherent::delete sql=".$sql);
dol_syslog("Adherent::delete sql=".$sql);
$resql=$this->db->query( $sql);
if ($resql)
{
$sql = "DELETE FROM ".MAIN_DB_PREFIX."adherent WHERE rowid = ".$rowid;
dolibarr_syslog("Adherent::delete sql=".$sql);
dol_syslog("Adherent::delete sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
{
@@ -669,7 +669,7 @@ class Adherent extends CommonObject
$error=0;
dolibarr_syslog("Adherent::Password user=".$user->id." password=".eregi_replace('.','*',$password)." isencrypted=".$isencrypted);
dol_syslog("Adherent::Password user=".$user->id." password=".eregi_replace('.','*',$password)." isencrypted=".$isencrypted);
// Si nouveau mot de passe non communique, on genere par module
if (! $password)
@@ -695,8 +695,8 @@ class Adherent extends CommonObject
$sql = "UPDATE ".MAIN_DB_PREFIX."adherent SET pass = '".addslashes($password_indatabase)."'";
$sql.= " WHERE rowid = ".$this->id;
//dolibarr_syslog("Adherent::Password sql=hidden");
dolibarr_syslog("Adherent::Password sql=".$sql);
//dol_syslog("Adherent::Password sql=hidden");
dol_syslog("Adherent::Password sql=".$sql);
$result = $this->db->query($sql);
if ($result)
{
@@ -723,7 +723,7 @@ class Adherent extends CommonObject
if ($result < 0)
{
$this->error=$luser->error;
dolibarr_syslog("Adherent::password ".$this->error,LOG_ERR);
dol_syslog("Adherent::password ".$this->error,LOG_ERR);
$error++;
}
}
@@ -753,7 +753,7 @@ class Adherent extends CommonObject
}
else
{
dolibarr_print_error($this->db);
dol_print_error($this->db);
return -1;
}
}
@@ -779,7 +779,7 @@ class Adherent extends CommonObject
}
else
{
dolibarr_print_error($this->db);
dol_print_error($this->db);
}
}
@@ -810,7 +810,7 @@ class Adherent extends CommonObject
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."user as u ON d.rowid = u.fk_member";
$sql.= " WHERE d.fk_adherent_type = t.rowid";
$sql.= " AND d.rowid = ".$rowid;
dolibarr_syslog("Adherent::fetch sql=".$sql);
dol_syslog("Adherent::fetch sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
@@ -898,7 +898,7 @@ class Adherent extends CommonObject
$sql.= " FROM ".MAIN_DB_PREFIX."cotisation as c";
$sql.= " WHERE c.fk_adherent = ".$this->id;
$sql.= " ORDER BY c.dateadh";
dolibarr_syslog("Adherent::fetch_subscriptions sql=".$sql);
dol_syslog("Adherent::fetch_subscriptions sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
@@ -939,7 +939,7 @@ class Adherent extends CommonObject
$sql.= " FROM ".MAIN_DB_PREFIX."adherent_options";
$sql.= " WHERE adhid=".$rowid;
dolibarr_syslog("Adherent::fetch_optionals sql=".$sql, LOG_DEBUG);
dol_syslog("Adherent::fetch_optionals sql=".$sql, LOG_DEBUG);
$result=$this->db->query( $sql);
if ($result)
{
@@ -959,7 +959,7 @@ class Adherent extends CommonObject
}
else
{
dolibarr_print_error($this->db);
dol_print_error($this->db);
}
}
@@ -1038,7 +1038,7 @@ class Adherent extends CommonObject
// Met a jour la table cotisation
$sql="UPDATE ".MAIN_DB_PREFIX."cotisation SET fk_bank=".$insertid." WHERE rowid=".$rowid;
dolibarr_syslog("Adherent::cotisation sql=".$sql);
dol_syslog("Adherent::cotisation sql=".$sql);
$resql = $this->db->query($sql);
if (! $resql)
{
@@ -1104,7 +1104,7 @@ class Adherent extends CommonObject
if ($this->statut == 1)
{
dolibarr_syslog("Adherent::validate statut of member does not allow this", LOG_WARNING);
dol_syslog("Adherent::validate statut of member does not allow this", LOG_WARNING);
return 0;
}
@@ -1115,7 +1115,7 @@ class Adherent extends CommonObject
$sql.= " fk_user_valid=".$user->id;
$sql.= " WHERE rowid = ".$this->id;
dolibarr_syslog("Adherent::validate sql=".$sql);
dol_syslog("Adherent::validate sql=".$sql);
$result = $this->db->query($sql);
if ($result)
{
@@ -1153,7 +1153,7 @@ class Adherent extends CommonObject
if ($this->statut == 0)
{
dolibarr_syslog("Adherent::resiliate statut of member does not allow this", LOG_WARNING);
dol_syslog("Adherent::resiliate statut of member does not allow this", LOG_WARNING);
return 0;
}
@@ -1276,7 +1276,7 @@ class Adherent extends CommonObject
{
require_once(DOL_DOCUMENT_ROOT.'/lib/security.lib.php');
dolibarr_syslog("Adherent::add_to_spip");
dol_syslog("Adherent::add_to_spip");
if (defined("ADHERENT_USE_SPIP") && ADHERENT_USE_SPIP ==1 &&
defined('ADHERENT_SPIP_SERVEUR') && ADHERENT_SPIP_SERVEUR != '' &&
@@ -1388,7 +1388,7 @@ class Adherent extends CommonObject
{
global $conf,$langs;
dolibarr_syslog("Adherent::add_to_mailman");
dol_syslog("Adherent::add_to_mailman");
if (! function_exists("curl_init"))
{
@@ -1437,7 +1437,7 @@ class Adherent extends CommonObject
//--- Start buffering
//ob_start();
$result=curl_exec ($ch);
dolibarr_syslog($result);
dol_syslog($result);
//--- End buffering and clean output
//ob_end_clean();
if (curl_error($ch) > 0)
@@ -1505,7 +1505,7 @@ class Adherent extends CommonObject
//--- Start buffering
//ob_start();
$result=curl_exec ($ch);
dolibarr_syslog($result);
dol_syslog($result);
//--- End buffering and clean output
//ob_end_clean();
if (curl_error($ch) > 0)
@@ -1567,7 +1567,7 @@ class Adherent extends CommonObject
if ($withpicto) $result.=($lien.img_object($label,$picto).$lienfin);
if ($withpicto && $withpicto != 2) $result.=' ';
$result.=$lien.($maxlen?dolibarr_trunc($this->ref,$maxlen):$this->ref).$lienfin;
$result.=$lien.($maxlen?dol_trunc($this->ref,$maxlen):$this->ref).$lienfin;
return $result;
}
@@ -1687,7 +1687,7 @@ class Adherent extends CommonObject
}
else
{
dolibarr_print_error($this->db);
dol_print_error($this->db);
$this->error=$this->db->error();
return -1;
}
@@ -1723,7 +1723,7 @@ class Adherent extends CommonObject
}
else
{
dolibarr_print_error($this->db);
dol_print_error($this->db);
$this->error=$this->db->error();
return -1;
}
@@ -1826,14 +1826,14 @@ class Adherent extends CommonObject
if ($this->phone_mobile && $conf->global->LDAP_FIELD_MOBILE) $info[$conf->global->LDAP_FIELD_MOBILE] = $this->phone_mobile;
if ($this->fax && $conf->global->LDAP_FIELD_FAX) $info[$conf->global->LDAP_FIELD_FAX] = $this->fax;
if ($this->note && $conf->global->LDAP_FIELD_DESCRIPTION) $info[$conf->global->LDAP_FIELD_DESCRIPTION] = $this->note;
if ($this->naiss && $conf->global->LDAP_FIELD_BIRTHDATE) $info[$conf->global->LDAP_FIELD_BIRTHDATE] = dolibarr_print_date($this->naiss,'dayhourldap');
if ($this->naiss && $conf->global->LDAP_FIELD_BIRTHDATE) $info[$conf->global->LDAP_FIELD_BIRTHDATE] = dol_print_date($this->naiss,'dayhourldap');
if (isset($this->statut) && $conf->global->LDAP_FIELD_MEMBER_STATUS) $info[$conf->global->LDAP_FIELD_MEMBER_STATUS] = $this->statut;
if ($this->datefin && $conf->global->LDAP_FIELD_MEMBER_END_LASTSUBSCRIPTION) $info[$conf->global->LDAP_FIELD_MEMBER_END_LASTSUBSCRIPTION] = dolibarr_print_date($this->datefin,'dayhourldap');
if ($this->datefin && $conf->global->LDAP_FIELD_MEMBER_END_LASTSUBSCRIPTION) $info[$conf->global->LDAP_FIELD_MEMBER_END_LASTSUBSCRIPTION] = dol_print_date($this->datefin,'dayhourldap');
// Subscriptions
if ($this->firstsubscription_date && $conf->global->LDAP_FIELD_MEMBER_FIRSTSUBSCRIPTION_DATE) $info[$conf->global->LDAP_FIELD_MEMBER_FIRSTSUBSCRIPTION_DATE] = dolibarr_print_date($this->firstsubscription_date,'dayhourldap');
if ($this->firstsubscription_date && $conf->global->LDAP_FIELD_MEMBER_FIRSTSUBSCRIPTION_DATE) $info[$conf->global->LDAP_FIELD_MEMBER_FIRSTSUBSCRIPTION_DATE] = dol_print_date($this->firstsubscription_date,'dayhourldap');
if (isset($this->firstsubscription_amount) && $conf->global->LDAP_FIELD_MEMBER_FIRSTSUBSCRIPTION_AMOUNT) $info[$conf->global->LDAP_FIELD_MEMBER_FIRSTSUBSCRIPTION_AMOUNT] = $this->firstsubscription_amount;
if ($this->lastsubscription_date && $conf->global->LDAP_FIELD_MEMBER_LASTSUBSCRIPTION_DATE) $info[$conf->global->LDAP_FIELD_MEMBER_LASTSUBSCRIPTION_DATE] = dolibarr_print_date($this->lastsubscription_date,'dayhourldap');
if ($this->lastsubscription_date && $conf->global->LDAP_FIELD_MEMBER_LASTSUBSCRIPTION_DATE) $info[$conf->global->LDAP_FIELD_MEMBER_LASTSUBSCRIPTION_DATE] = dol_print_date($this->lastsubscription_date,'dayhourldap');
if (isset($this->lastsubscription_amount) && $conf->global->LDAP_FIELD_MEMBER_LASTSUBSCRIPTION_AMOUNT) $info[$conf->global->LDAP_FIELD_MEMBER_LASTSUBSCRIPTION_AMOUNT] = $this->lastsubscription_amount;
return $info;
@@ -1853,7 +1853,7 @@ class Adherent extends CommonObject
$sql.= ' FROM '.MAIN_DB_PREFIX.'adherent as a';
$sql.= ' WHERE a.rowid = '.$id;
dolibarr_syslog("Adherent::info sql=".$sql, LOG_DEBUG);
dol_syslog("Adherent::info sql=".$sql, LOG_DEBUG);
$result=$this->db->query($sql);
if ($result)
{
@@ -1892,7 +1892,7 @@ class Adherent extends CommonObject
}
else
{
dolibarr_print_error($this->db);
dol_print_error($this->db);
}
}

View File

@@ -150,14 +150,14 @@ class AdherentOptions
break;
}
dolibarr_syslog("AdherentOptions::create sql=".$sql, LOG_DEBUG);
dol_syslog("AdherentOptions::create sql=".$sql, LOG_DEBUG);
if ($this->db->query($sql))
{
return 1;
}
else
{
dolibarr_print_error($this->db);
dol_print_error($this->db);
return 0;
}
}else{
@@ -182,14 +182,14 @@ class AdherentOptions
$sql .= " name='$attrname', label='".addslashes($label)."',";
$sql .= " type='".$type."', pos='".$pos."', size='".$size."'";
dolibarr_syslog("AdherentOptions::create_label sql=".$sql);
dol_syslog("AdherentOptions::create_label sql=".$sql);
if ($this->db->query($sql))
{
return 1;
}
else
{
print dolibarr_print_error($this->db);
print dol_print_error($this->db);
return 0;
}
}
@@ -207,7 +207,7 @@ class AdherentOptions
if ($result < 0)
{
$this->error=$this->db->lasterror();
dolibarr_syslog("AdherentOption::delete ".$this->error, LOG_ERR);
dol_syslog("AdherentOption::delete ".$this->error, LOG_ERR);
}
$result=$this->delete_label($attrname);
@@ -236,7 +236,7 @@ class AdherentOptions
}
else
{
print dolibarr_print_error($this->db);
print dol_print_error($this->db);
return 0;
}
}else{
@@ -277,7 +277,7 @@ class AdherentOptions
}
else
{
print dolibarr_print_error($this->db);
print dol_print_error($this->db);
return 0;
}
}else{
@@ -308,7 +308,7 @@ class AdherentOptions
}
else
{
print dolibarr_print_error($this->db);
print dol_print_error($this->db);
return 0;
}
}else{
@@ -336,7 +336,7 @@ class AdherentOptions
$sql = "SELECT name,label,type FROM ".MAIN_DB_PREFIX."adherent_options_label";
$sql.= " ORDER BY pos";
dolibarr_syslog("Adherent_options::fetch_name_optionals_label");
dol_syslog("Adherent_options::fetch_name_optionals_label");
$resql=$this->db->query($sql);
if ($resql)
{
@@ -354,7 +354,7 @@ class AdherentOptions
return array();
}
}else{
print dolibarr_print_error($this->db);
print dol_print_error($this->db);
return array() ;
}

View File

@@ -86,7 +86,7 @@ class AdherentType extends CommonObject
$sql = "INSERT INTO ".MAIN_DB_PREFIX."adherent_type (libelle)";
$sql.= " VALUES ('".addslashes($this->libelle)."')";
dolibarr_syslog("Adherent_type::create sql=".$sql);
dol_syslog("Adherent_type::create sql=".$sql);
$result = $this->db->query($sql);
if ($result)
{
@@ -170,7 +170,7 @@ class AdherentType extends CommonObject
$sql = "SELECT d.rowid, d.libelle, d.statut, d.cotisation, d.mail_valid, d.note, d.vote";
$sql .= " FROM ".MAIN_DB_PREFIX."adherent_type as d";
$sql .= " WHERE d.rowid = ".$rowid;
dolibarr_syslog("Adherent_type::fetch sql=".$sql);
dol_syslog("Adherent_type::fetch sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
@@ -255,7 +255,7 @@ class AdherentType extends CommonObject
if ($withpicto) $result.=($lien.img_object($label,$picto).$lienfin);
if ($withpicto && $withpicto != 2) $result.=' ';
$result.=$lien.($maxlen?dolibarr_trunc($this->libelle,$maxlen):$this->libelle).$lienfin;
$result.=$lien.($maxlen?dol_trunc($this->libelle,$maxlen):$this->libelle).$lienfin;
return $result;
}

View File

@@ -73,11 +73,11 @@ if ($user->rights->adherent->cotisation->creer && $_POST["action"] == 'cotisatio
$datesubend=0;
if ($_POST["reyear"] && $_POST["remonth"] && $_POST["reday"])
{
$datecotisation=dolibarr_mktime(0, 0, 0, $_POST["remonth"], $_POST["reday"], $_POST["reyear"]);
$datecotisation=dol_mktime(0, 0, 0, $_POST["remonth"], $_POST["reday"], $_POST["reyear"]);
}
if ($_POST["endyear"] && $_POST["endmonth"] && $_POST["endday"])
{
$datesubend=dolibarr_mktime(0, 0, 0, $_POST["endmonth"], $_POST["endday"], $_POST["endyear"]);
$datesubend=dol_mktime(0, 0, 0, $_POST["endmonth"], $_POST["endday"], $_POST["endyear"]);
}
$cotisation=$_POST["cotisation"]; // Amount of subscription
$label=$_POST["label"];
@@ -186,7 +186,7 @@ $adho->fetch_optionals();
*/
$head = member_prepare_head($adh);
dolibarr_fiche_head($head, 'subscription', $langs->trans("Member"));
dol_fiche_head($head, 'subscription', $langs->trans("Member"));
print '<form action="fiche.php" method="post">';
print '<table class="border" width="100%">';
@@ -310,8 +310,8 @@ if ($result)
$cotisationstatic->ref=$objp->crowid;
$cotisationstatic->id=$objp->crowid;
print '<td>'.$cotisationstatic->getNomUrl(1).'</td>';
print '<td align="center">'.dolibarr_print_date($objp->dateadh,'day')."</td>\n";
print '<td align="center">'.dolibarr_print_date($objp->datef,'day')."</td>\n";
print '<td align="center">'.dol_print_date($objp->dateadh,'day')."</td>\n";
print '<td align="center">'.dol_print_date($objp->datef,'day')."</td>\n";
print '<td align="right">'.price($objp->cotisation).'</td>';
if ($conf->banque->enabled && $conf->global->ADHERENT_BANK_USE)
{
@@ -335,7 +335,7 @@ if ($result)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
print '</td><td valign="top">';
@@ -350,12 +350,12 @@ if ($adh->datefin)
{
if ($adh->datefin < time())
{
print dolibarr_print_date($adh->datefin,'day');
print dol_print_date($adh->datefin,'day');
if ($adh->statut > 0) print " ".img_warning($langs->trans("Late")); // Affiche picto retard uniquement si non brouillon et non resilie
}
else
{
print dolibarr_print_date($adh->datefin,'day');
print dol_print_date($adh->datefin,'day');
}
}
else
@@ -392,7 +392,7 @@ if ($action == 'addsubscription' && $user->rights->adherent->cotisation->creer)
print '<tr><td>'.$langs->trans("DateSubscription").'</td><td>';
if ($_POST["reday"])
{
$datefrom=dolibarr_mktime(0,0,0,$_POST["remonth"],$_POST["reday"],$_POST["reyear"]);
$datefrom=dol_mktime(0,0,0,$_POST["remonth"],$_POST["reday"],$_POST["reyear"]);
}
if (! $datefrom)
{
@@ -411,7 +411,7 @@ if ($action == 'addsubscription' && $user->rights->adherent->cotisation->creer)
// Date end subscription
if ($_POST["endday"])
{
$dateto=dolibarr_mktime(0,0,0,$_POST["endmonth"],$_POST["endday"],$_POST["endyear"]);
$dateto=dol_mktime(0,0,0,$_POST["endmonth"],$_POST["endday"],$_POST["endyear"]);
}
if (! $dateto)
{
@@ -430,7 +430,7 @@ if ($action == 'addsubscription' && $user->rights->adherent->cotisation->creer)
// Label
print '<tr><td>'.$langs->trans("Label").'</td>';
print '<td><input name="label" type="text" size="32" value="'.$langs->trans("Subscription").' ';
print dolibarr_print_date(($datefrom?$datefrom:time()),"%Y").'" ></td></tr>';
print dol_print_date(($datefrom?$datefrom:time()),"%Y").'" ></td></tr>';
// Bank account
if ($conf->banque->enabled && $conf->global->ADHERENT_BANK_USE)

View File

@@ -146,7 +146,7 @@ if ($result)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
llxFooter('$Date$ - $Revision$');
}

View File

@@ -114,7 +114,7 @@ if ($result)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
llxFooter('$Date$ - $Revision$');
}

View File

@@ -76,7 +76,7 @@ class Cotisation extends CommonObject
$sql.= " ".$this->db->idate($this->datef).",";
$sql.= " ".$this->amount.",'".$this->note."')";
dolibarr_syslog("Cotisation::create sql=".$sql);
dol_syslog("Cotisation::create sql=".$sql);
$resql = $this->db->query($sql);
if ($resql)
{
@@ -85,7 +85,7 @@ class Cotisation extends CommonObject
else
{
$this->error=$this->db->error();
dolibarr_syslog($this->error);
dol_syslog($this->error);
return -1;
}
}
@@ -106,7 +106,7 @@ class Cotisation extends CommonObject
$sql.=" FROM ".MAIN_DB_PREFIX."cotisation";
$sql.=" WHERE rowid=".$rowid;
dolibarr_syslog("Cotisation::fetch sql=".$sql);
dol_syslog("Cotisation::fetch sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
{
@@ -160,7 +160,7 @@ class Cotisation extends CommonObject
$sql .= " fk_bank = ".($this->fk_bank ? $this->fk_bank : 'null');
$sql .= " WHERE rowid = ".$this->id;
dolibarr_syslog("Cotisation::update sql=".$sql);
dol_syslog("Cotisation::update sql=".$sql);
$resql = $this->db->query($sql);
if ($resql)
{
@@ -175,7 +175,7 @@ class Cotisation extends CommonObject
{
$this->db->rollback();
$this->error=$this->db->error();
dolibarr_syslog("Cotisation::update ".$this->error);
dol_syslog("Cotisation::update ".$this->error);
return -1;
}
}
@@ -198,7 +198,7 @@ class Cotisation extends CommonObject
$this->db->begin();
$sql = "DELETE FROM ".MAIN_DB_PREFIX."cotisation WHERE rowid = ".$this->id;
dolibarr_syslog("Cotisation::delete sql=".$sql);
dol_syslog("Cotisation::delete sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
{
@@ -293,7 +293,7 @@ class Cotisation extends CommonObject
}
else
{
dolibarr_print_error($this->db);
dol_print_error($this->db);
}
}
}

View File

@@ -100,7 +100,7 @@ if ($allowinsertbankafter && $_POST["action"] == '2bank' && $_POST["rowid"] !=''
$insertid=$acct->addline($dateop, $_POST["paymenttypeid"], $_POST["label"], $amount, $_POST["num_chq"],ADHERENT_BANK_CATEGORIE,$user);
if ($insertid < 0)
{
dolibarr_print_error($db,$acct->error);
dol_print_error($db,$acct->error);
}
else
{
@@ -111,7 +111,7 @@ if ($allowinsertbankafter && $_POST["action"] == '2bank' && $_POST["rowid"] !=''
$sql.=" SET fk_bank=".$insertid.",";
$sql.=" note='".addslashes($_POST["label"])."'";
$sql.=" WHERE rowid=".$_POST["rowid"];
dolibarr_syslog("cotisations sql=".$sql);
dol_syslog("cotisations sql=".$sql);
$result = $db->query($sql);
if ($result)
{
@@ -121,14 +121,14 @@ if ($allowinsertbankafter && $_POST["action"] == '2bank' && $_POST["rowid"] !=''
else
{
$db->rollback();
dolibarr_print_error($db);
dol_print_error($db);
}
}
}
else
{
$db->rollback();
dolibarr_print_error($db,$cotisation->error);
dol_print_error($db,$cotisation->error);
}
}
}
@@ -226,14 +226,14 @@ if ($result)
print '<td>';
if ($allowinsertbankafter && $user->rights->banque->modifier && ! $objp->fk_account && $conf->banque->enabled && $conf->global->ADHERENT_BANK_USE && $objp->cotisation)
{
print "<input name=\"label\" type=\"text\" class=\"flat\" size=\"30\" value=\"".$langs->trans("Subscriptions").' '.dolibarr_print_date($objp->dateadh,"%Y")."\" >\n";
print "<input name=\"label\" type=\"text\" class=\"flat\" size=\"30\" value=\"".$langs->trans("Subscriptions").' '.dol_print_date($objp->dateadh,"%Y")."\" >\n";
// print "<td><input name=\"debit\" type=\"text\" size=8></td>";
// print "<td><input name=\"credit\" type=\"text\" size=8></td>";
print '<input type="submit" class="button" value="'.$langs->trans("Save").'">';
}
else
{
print dolibarr_trunc($objp->note,32);
print dol_trunc($objp->note,32);
}
print '</td>';
@@ -269,10 +269,10 @@ if ($result)
}
// Date start
print '<td align="center">'.dolibarr_print_date($objp->dateadh,'day')."</td>\n";
print '<td align="center">'.dol_print_date($objp->dateadh,'day')."</td>\n";
// Date end
print '<td align="center">'.dolibarr_print_date($objp->datef,'day')."</td>\n";
print '<td align="center">'.dol_print_date($objp->datef,'day')."</td>\n";
// Price
print '<td align="right">'.price($objp->cotisation).'</td>';
@@ -308,7 +308,7 @@ if ($result)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}

View File

@@ -140,7 +140,7 @@ if ($_REQUEST["action"] == 'update' && ! $_POST["cancel"])
&& isset($_POST["naissmonth"]) && $_POST["naissmonth"]
&& isset($_POST["naissyear"]) && $_POST["naissyear"])
{
$datenaiss=dolibarr_mktime(12, 0, 0, $_POST["naissmonth"], $_POST["naissday"], $_POST["naissyear"]);
$datenaiss=dol_mktime(12, 0, 0, $_POST["naissmonth"], $_POST["naissday"], $_POST["naissyear"]);
}
//print $_POST["naissmonth"].", ".$_POST["naissday"].", ".$_POST["naissyear"]." ".$datenaiss." ".adodb_strftime('%Y-%m-%d %H:%M:%S',$datenaiss);
@@ -236,12 +236,12 @@ if ($user->rights->adherent->creer && $_POST["action"] == 'add')
&& isset($_POST["naissmonth"]) && $_POST["naissmonth"]
&& isset($_POST["naissyear"]) && $_POST["naissyear"])
{
$datenaiss=dolibarr_mktime(12, 0, 0, $_POST["naissmonth"], $_POST["naissday"], $_POST["naissyear"]);
$datenaiss=dol_mktime(12, 0, 0, $_POST["naissmonth"], $_POST["naissday"], $_POST["naissyear"]);
}
$datecotisation='';
if (isset($_POST["reday"]) && isset($_POST["remonth"]) && isset($_POST["reyear"]))
{
$datecotisation=dolibarr_mktime(12, 0 , 0, $_POST["remonth"], $_POST["reday"], $_POST["reyear"]);
$datecotisation=dol_mktime(12, 0 , 0, $_POST["remonth"], $_POST["reday"], $_POST["reyear"]);
}
$type=$_POST["type"];
@@ -352,7 +352,7 @@ if ($user->rights->adherent->creer && $_POST["action"] == 'add')
$insertid=$acct->addline($dateop, $_POST["operation"], $_POST["label"], $amount, $_POST["num_chq"], '', $user);
if ($insertid == '')
{
dolibarr_print_error($db);
dol_print_error($db);
}
else
{
@@ -366,7 +366,7 @@ if ($user->rights->adherent->creer && $_POST["action"] == 'add')
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
}
}
@@ -573,7 +573,7 @@ if ($action == 'edit')
*/
$head = member_prepare_head($adh);
dolibarr_fiche_head($head, 'general', $langs->trans("Member"));
dol_fiche_head($head, 'general', $langs->trans("Member"));
print '<form name="update" action="'.$_SERVER["PHP_SELF"].'" method="post" enctype="multipart/form-data">';
@@ -837,7 +837,7 @@ if ($rowid && $action != 'edit')
*/
$head = member_prepare_head($adh);
dolibarr_fiche_head($head, 'general', $langs->trans("Member"));
dol_fiche_head($head, 'general', $langs->trans("Member"));
if ($msg) print '<div class="error">'.$msg.'</div>';
@@ -1003,7 +1003,7 @@ if ($rowid && $action != 'edit')
print '<tr><td>'.$langs->trans("EMail").'</td><td class="valeur">'.dol_print_email($adh->email,0,$adh->fk_soc,1).'</td></tr>';
// Date naissance
print '<tr><td>'.$langs->trans("Birthday").'</td><td class="valeur">'.dolibarr_print_date($adh->naiss,'day').'</td></tr>';
print '<tr><td>'.$langs->trans("Birthday").'</td><td class="valeur">'.dol_print_date($adh->naiss,'day').'</td></tr>';
// Public
print '<tr><td>'.$langs->trans("Public").'</td><td class="valeur">'.yn($adh->public).'</td></tr>';

View File

@@ -72,8 +72,8 @@ if ($user->rights->adherent->cotisation->creer && $_REQUEST["action"] == 'update
}
else
{
$accountline->datev=dolibarr_mktime($_POST['datesubhour'], $_POST['datesubmin'], 0, $_POST['datesubmonth'], $_POST['datesubday'], $_POST['datesubyear']);
$accountline->dateo=dolibarr_mktime($_POST['datesubhour'], $_POST['datesubmin'], 0, $_POST['datesubmonth'], $_POST['datesubday'], $_POST['datesubyear']);
$accountline->datev=dol_mktime($_POST['datesubhour'], $_POST['datesubmin'], 0, $_POST['datesubmonth'], $_POST['datesubday'], $_POST['datesubyear']);
$accountline->dateo=dol_mktime($_POST['datesubhour'], $_POST['datesubmin'], 0, $_POST['datesubmonth'], $_POST['datesubday'], $_POST['datesubyear']);
$accountline->amount=$_POST["amount"];
$result=$accountline->update($user);
if ($result < 0)
@@ -86,8 +86,8 @@ if ($user->rights->adherent->cotisation->creer && $_REQUEST["action"] == 'update
if (! $errmsg)
{
// Modifie valeures
$subscription->dateh=dolibarr_mktime($_POST['datesubhour'], $_POST['datesubmin'], 0, $_POST['datesubmonth'], $_POST['datesubday'], $_POST['datesubyear']);
$subscription->datef=dolibarr_mktime($_POST['datesubendhour'], $_POST['datesubendmin'], 0, $_POST['datesubendmonth'], $_POST['datesubendday'], $_POST['datesubendyear']);
$subscription->dateh=dol_mktime($_POST['datesubhour'], $_POST['datesubmin'], 0, $_POST['datesubmonth'], $_POST['datesubday'], $_POST['datesubyear']);
$subscription->datef=dol_mktime($_POST['datesubendhour'], $_POST['datesubendmin'], 0, $_POST['datesubendmonth'], $_POST['datesubendday'], $_POST['datesubendyear']);
$subscription->note=$_POST["note"];
$subscription->amount=$_POST["amount"];
//print 'datef='.$subscription->datef.' '.$_POST['datesubendday'];
@@ -187,7 +187,7 @@ if ($user->rights->adherent->cotisation->creer && $action == 'edit')
$head[$h][2] = 'info';
$h++;
dolibarr_fiche_head($head, 'general', $langs->trans("Subscription"));
dol_fiche_head($head, 'general', $langs->trans("Subscription"));
print "\n";
print '<form name="update" action="'.$_SERVER["PHP_SELF"].'" method="post">';
@@ -286,7 +286,7 @@ if ($rowid && $action != 'edit')
$head[$h][2] = 'info';
$h++;
dolibarr_fiche_head($head, 'general', $langs->trans("Subscription"));
dol_fiche_head($head, 'general', $langs->trans("Subscription"));
if ($msg) print '<div class="error">'.$msg.'</div>';
@@ -318,12 +318,12 @@ if ($rowid && $action != 'edit')
// Date subscription
print '<tr>';
print '<td>'.$langs->trans("DateSubscription").'</td><td class="valeur" colspan="3">'.dolibarr_print_date($subscription->dateh,'dayhour').'</td>';
print '<td>'.$langs->trans("DateSubscription").'</td><td class="valeur" colspan="3">'.dol_print_date($subscription->dateh,'dayhour').'</td>';
print '</tr>';
// Date end subscription
print '<tr>';
print '<td>'.$langs->trans("DateEndSubscription").'</td><td class="valeur" colspan="3">'.dolibarr_print_date($subscription->datef,'day').'</td>';
print '<td>'.$langs->trans("DateEndSubscription").'</td><td class="valeur" colspan="3">'.dol_print_date($subscription->datef,'day').'</td>';
print '</tr>';
// Amount

View File

@@ -76,7 +76,7 @@ if ($resql)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}

View File

@@ -214,7 +214,7 @@ if ($resql)
$statictype->libelle=$obj->libelle;
print '<td>'.$staticmember->getNomUrl(1).'</td>';
print '<td>'.$statictype->getNomUrl(1).'</td>';
print '<td>'.dolibarr_print_date($obj->datem,'dayhour').'</td>';
print '<td>'.dol_print_date($obj->datem,'dayhour').'</td>';
print '<td align="right">'.$staticmember->LibStatut($obj->statut,($obj->cotisation=='yes'?1:0),$obj->date_end_subscription,5).'</td>';
print '</tr>';
$i++;
@@ -224,7 +224,7 @@ if ($resql)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
@@ -250,7 +250,7 @@ if ($result)
while ($i < $num)
{
$objp = $db->fetch_object($result);
$year=dolibarr_print_date($objp->dateadh,"%Y");
$year=dol_print_date($objp->dateadh,"%Y");
$Total[$year]=(isset($Total[$year])?$Total[$year]:0)+$objp->cotisation;
$Number[$year]=(isset($Number[$year])?$Number[$year]:0)+1;
$tot+=$objp->cotisation;

View File

@@ -55,7 +55,7 @@ $adh->info($_GET["id"]);
*/
$head = member_prepare_head($adh);
dolibarr_fiche_head($head, 'info', $langs->trans("Member"));
dol_fiche_head($head, 'info', $langs->trans("Member"));
print '<table width="100%"><tr><td>';

View File

@@ -68,7 +68,7 @@ $head[$h][2] = 'info';
$h++;
dolibarr_fiche_head($head, 'info', $langs->trans("Subscription"));
dol_fiche_head($head, 'info', $langs->trans("Subscription"));
$subscription->info($rowid);

View File

@@ -60,7 +60,7 @@ $adh->id = $rowid;
$result=$adh->fetch($rowid);
if (! $result)
{
dolibarr_print_error($db,"Failed to get adherent: ".$adh->error);
dol_print_error($db,"Failed to get adherent: ".$adh->error);
exit;
}
$adh->fetch_optionals($rowid);
@@ -69,7 +69,7 @@ $adht = new AdherentType($db);
$result=$adht->fetch($adh->typeid);
if (! $result)
{
dolibarr_print_error($db,"Failed to get type of adherent: ".$adht->error);
dol_print_error($db,"Failed to get type of adherent: ".$adht->error);
exit;
}
@@ -80,7 +80,7 @@ if (! $result)
*/
$head = member_prepare_head($adh);
dolibarr_fiche_head($head, 'ldap', $langs->trans("Member"));
dol_fiche_head($head, 'ldap', $langs->trans("Member"));
/*
@@ -190,7 +190,7 @@ if ($result > 0)
}
else
{
dolibarr_print_error('',$ldap->error);
dol_print_error('',$ldap->error);
}

View File

@@ -257,11 +257,11 @@ if ($resql)
print '<td align="center">';
if ($objp->datefin < time() && $objp->statut > 0)
{
print dolibarr_print_date($objp->datefin)." ".img_warning($langs->trans("SubscriptionLate"));
print dol_print_date($objp->datefin)." ".img_warning($langs->trans("SubscriptionLate"));
}
else
{
print dolibarr_print_date($objp->datefin);
print dol_print_date($objp->datefin);
}
print '</td>';
}
@@ -306,7 +306,7 @@ if ($resql)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}

View File

@@ -77,7 +77,7 @@ if ($id)
{
$head = member_prepare_head($adh);
dolibarr_fiche_head($head, 'note', $langs->trans("Member"));
dol_fiche_head($head, 'note', $langs->trans("Member"));
if ($msg) print '<div class="error">'.$msg.'</div>';

View File

@@ -161,7 +161,7 @@ if (! $rowid && $_GET["action"] != 'create' && $_GET["action"] != 'edit')
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
@@ -256,7 +256,7 @@ if ($rowid > 0)
$head[$h][2] = 'card';
$h++;
dolibarr_fiche_head($head, 'card', $langs->trans("MemberType"));
dol_fiche_head($head, 'card', $langs->trans("MemberType"));
print '<table class="border" width="100%">';
@@ -328,7 +328,7 @@ if ($rowid > 0)
$head[$h][2] = 'card';
$h++;
dolibarr_fiche_head($head, 'card', $langs->trans("MemberType"));
dol_fiche_head($head, 'card', $langs->trans("MemberType"));
print '<form method="post" action="'.$_SERVER["PHP_SELF"].'?rowid='.$rowid.'">';

View File

@@ -98,7 +98,7 @@ print "<br>\n";
$head=agenda_prepare_head();
dolibarr_fiche_head($head, 'autoactions', $langs->trans("Agenda"));
dol_fiche_head($head, 'autoactions', $langs->trans("Agenda"));
print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST">';

View File

@@ -76,7 +76,7 @@ print "<br>\n";
$head=agenda_prepare_head();
dolibarr_fiche_head($head, 'xcal', $langs->trans("Agenda"));
dol_fiche_head($head, 'xcal', $langs->trans("Agenda"));
print '<form name="agendasetupform" action="'.$_SERVER["PHP_SELF"].'" method="post">';

View File

@@ -41,7 +41,7 @@ if ($_POST["action"] == 'setvalue' && $user->admin)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
}

View File

@@ -51,7 +51,7 @@ if ($_POST["action"] == 'add')
$sql.= " FROM ".MAIN_DB_PREFIX."boxes";
$sql.= " WHERE fk_user=0 AND box_id=".$_POST["boxid"]." AND position=".$_POST["pos"];
$resql = $db->query($sql);
dolibarr_syslog("boxes.php::search if box active sql=".$sql);
dol_syslog("boxes.php::search if box active sql=".$sql);
if ($resql)
{
$num = $db->num_rows($resql);
@@ -61,13 +61,13 @@ if ($_POST["action"] == 'add')
// Si la boite n'est pas deja active, insert with box_order=''
$sql = "INSERT INTO ".MAIN_DB_PREFIX."boxes (box_id, position, box_order, fk_user) values (".$_POST["boxid"].",".$_POST["pos"].", '', 0)";
dolibarr_syslog("boxes.php activate box sql=".$sql);
dol_syslog("boxes.php activate box sql=".$sql);
$resql = $db->query($sql);
// Remove all personalized setup when a box is activated or disabled
$sql = "DELETE FROM ".MAIN_DB_PREFIX."user_param";
$sql.= " WHERE param like 'MAIN_BOXES_%'";
dolibarr_syslog("boxes.php delete user_param sql=".$sql);
dol_syslog("boxes.php delete user_param sql=".$sql);
$resql = $db->query($sql);
$db->commit();
@@ -78,7 +78,7 @@ if ($_POST["action"] == 'add')
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
}
@@ -114,11 +114,11 @@ if ($_GET["action"] == 'switch')
$sql="UPDATE ".MAIN_DB_PREFIX."boxes set box_order='".$objto->box_order."' WHERE rowid=".$objfrom->rowid;
//print "xx".$sql;
$resultupdatefrom = $db->query($sql);
if (! $resultupdatefrom) { dolibarr_print_error($db); }
if (! $resultupdatefrom) { dol_print_error($db); }
$sql="UPDATE ".MAIN_DB_PREFIX."boxes set box_order='".$objfrom->box_order."' WHERE rowid=".$objto->rowid;
//print "xx".$sql;
$resultupdateto = $db->query($sql);
if (! $resultupdateto) { dolibarr_print_error($db); }
if (! $resultupdateto) { dol_print_error($db); }
}
if ($resultupdatefrom && $resultupdateto)

View File

@@ -47,7 +47,7 @@ if ($_POST["action"] == 'set')
dolibarr_set_const($db,"CASHDESK_ID_BANKACCOUNT",$_POST["CASHDESK_ID_BANKACCOUNT"]);
dolibarr_set_const($db,"CASHDESK_ID_WAREHOUSE",$_POST["CASHDESK_ID_WAREHOUSE"]);
dolibarr_syslog("admin/cashdesk: level ".$_POST["level"]);
dol_syslog("admin/cashdesk: level ".$_POST["level"]);
}

View File

@@ -41,7 +41,7 @@ if ($_POST["action"] == 'setvalue' && $user->admin)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
}

View File

@@ -77,13 +77,13 @@ if ($_GET["action"] == 'specimen')
else
{
$mesg='<div class="error">'.$obj->error.'</div>';
dolibarr_syslog($obj->error, LOG_ERR);
dol_syslog($obj->error, LOG_ERR);
}
}
else
{
$mesg='<div class="error">'.$langs->trans("ErrorModuleNotFound").'</div>';
dolibarr_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
dol_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
}
}
@@ -302,7 +302,7 @@ if ($resql)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
$dir = "../includes/modules/commande/";

View File

@@ -62,7 +62,7 @@ if ( (isset($_POST["action"]) && $_POST["action"] == 'update')
$isimage=image_format_supported($original_file);
if ($isimage >= 0)
{
dolibarr_syslog("Move file ".$_FILES["logo"]["tmp_name"]." to ".$conf->societe->dir_logos.'/'.$original_file);
dol_syslog("Move file ".$_FILES["logo"]["tmp_name"]." to ".$conf->societe->dir_logos.'/'.$original_file);
if (! is_dir($conf->societe->dir_logos))
{
create_exdir($conf->societe->dir_logos);
@@ -82,7 +82,7 @@ if ( (isset($_POST["action"]) && $_POST["action"] == 'update')
$imgThumbSmall = $reg[1];
dolibarr_set_const($db, "MAIN_INFO_SOCIETE_LOGO_SMALL",$imgThumbSmall);
}
else dolibarr_syslog($imgThumbSmall);
else dol_syslog($imgThumbSmall);
// Cr<43>ation de la vignette de la page "Soci<63>t<EFBFBD>/Institution"
$imgThumbMini = vignette($conf->societe->dir_logos.'/'.$original_file, 100, 30, '_mini', $quality);
@@ -91,9 +91,9 @@ if ( (isset($_POST["action"]) && $_POST["action"] == 'update')
$imgThumbMini = $reg[1];
dolibarr_set_const($db, "MAIN_INFO_SOCIETE_LOGO_MINI",$imgThumbMini);
}
else dolibarr_syslog($imgThumbMini);
else dol_syslog($imgThumbMini);
}
else dolibarr_syslog($langs->trans("ErrorImageFormatNotSupported"),LOG_WARNING);
else dol_syslog($langs->trans("ErrorImageFormatNotSupported"),LOG_WARNING);
}
else
{
@@ -142,7 +142,7 @@ if ($_GET["action"] == 'addthumb')
$imgThumbSmall = $reg[1];
dolibarr_set_const($db, "MAIN_INFO_SOCIETE_LOGO_SMALL",$imgThumbSmall);
}
else dolibarr_syslog($imgThumbSmall);
else dol_syslog($imgThumbSmall);
// Cr<43>ation de la vignette de la page "Soci<63>t<EFBFBD>/Institution"
$imgThumbMini = vignette($conf->societe->dir_logos.'/'.$_GET["file"], 100, 30, '_mini',80);
@@ -151,7 +151,7 @@ if ($_GET["action"] == 'addthumb')
$imgThumbMini = $reg[1];
dolibarr_set_const($db, "MAIN_INFO_SOCIETE_LOGO_MINI",$imgThumbMini);
}
else dolibarr_syslog($imgThumbMini);
else dol_syslog($imgThumbMini);
Header("Location: ".$_SERVER["PHP_SELF"]);
exit;
@@ -159,13 +159,13 @@ if ($_GET["action"] == 'addthumb')
else
{
$message .= '<div class="error">'.$langs->trans("ErrorImageFormatNotSupported").'</div>';
dolibarr_syslog($langs->transnoentities("ErrorImageFormatNotSupported"),LOG_WARNING);
dol_syslog($langs->transnoentities("ErrorImageFormatNotSupported"),LOG_WARNING);
}
}
else
{
$message .= '<div class="error">'.$langs->trans("ErrorFileDoesNotExists",$_GET["file"]).'</div>';
dolibarr_syslog($langs->transnoentities("ErrorFileDoesNotExists",$_GET["file"]),LOG_WARNING);
dol_syslog($langs->transnoentities("ErrorFileDoesNotExists",$_GET["file"]),LOG_WARNING);
}
}
@@ -320,7 +320,7 @@ if ((isset($_GET["action"]) && $_GET["action"] == 'edit')
if ($obj->code) $code_pays=$obj->code;
}
else {
dolibarr_print_error($db);
dol_print_error($db);
}
}
@@ -579,7 +579,7 @@ else
if ($obj->code) $code_pays=$obj->code;
}
else {
dolibarr_print_error($db);
dol_print_error($db);
}
}

View File

@@ -95,7 +95,7 @@ if ($conf->global->MAIN_SUBMODULE_LIVRAISON)
$h++;
}
dolibarr_fiche_head($head, $hselected, $langs->trans("ModuleSetup"));
dol_fiche_head($head, $hselected, $langs->trans("ModuleSetup"));
/*
* Formulaire parametres divers

View File

@@ -277,7 +277,7 @@ if ($_POST["actionadd"] || $_POST["actionmodify"])
$newid=($obj->newid + 1);
} else {
dolibarr_print_error($db);
dol_print_error($db);
}
}
@@ -302,7 +302,7 @@ if ($_POST["actionadd"] || $_POST["actionmodify"])
}
$sql.=",1)";
dolibarr_syslog("dict actionadd sql=".$sql);
dol_syslog("dict actionadd sql=".$sql);
$result = $db->query($sql);
if (!$result)
{
@@ -310,7 +310,7 @@ if ($_POST["actionadd"] || $_POST["actionmodify"])
$msg=$langs->trans("ErrorRecordAlreadyExists").'<br>';
}
else {
dolibarr_print_error($db);
dol_print_error($db);
}
}
}
@@ -338,7 +338,7 @@ if ($_POST["actionadd"] || $_POST["actionmodify"])
}
$sql.= " WHERE ".$rowidcol." = '".$_POST["rowid"]."'";
dolibarr_syslog("dict actionmodify sql=".$sql);
dol_syslog("dict actionmodify sql=".$sql);
//print $sql;
$resql = $db->query($sql);
if (! $resql)
@@ -363,7 +363,7 @@ if ($_POST['action'] == 'confirm_delete' && $_POST['confirm'] == 'yes') //
$sql = "DELETE from ".$tabname[$_GET["id"]]." WHERE ".$rowidcol."='".$_GET["rowid"]."'";
dolibarr_syslog("dict delete sql=".$sql);
dol_syslog("dict delete sql=".$sql);
$result = $db->query($sql);
if (! $result)
{
@@ -373,7 +373,7 @@ if ($_POST['action'] == 'confirm_delete' && $_POST['confirm'] == 'yes') //
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
}
}
@@ -393,7 +393,7 @@ if ($_GET["action"] == $acts[0]) // activate
$result = $db->query($sql);
if (!$result)
{
dolibarr_print_error($db);
dol_print_error($db);
}
}
@@ -412,7 +412,7 @@ if ($_GET["action"] == $acts[1]) // disable
$result = $db->query($sql);
if (!$result)
{
dolibarr_print_error($db);
dol_print_error($db);
}
}
@@ -551,7 +551,7 @@ if ($_GET["id"])
}
// Affiche table des valeurs
dolibarr_syslog("htdocs/admin/dict sql=".$sql, LOG_DEBUG);
dol_syslog("htdocs/admin/dict sql=".$sql, LOG_DEBUG);
$resql=$db->query($sql);
if ($resql)
{
@@ -664,7 +664,7 @@ if ($_GET["id"])
}
}
else {
dolibarr_print_error($db);
dol_print_error($db);
}
print '</table>';

View File

@@ -63,13 +63,13 @@ if ($_GET["action"] == 'specimen')
else
{
$mesg='<div class="error">'.$obj->error.'</div>';
dolibarr_syslog($obj->error, LOG_ERR);
dol_syslog($obj->error, LOG_ERR);
}
}
else
{
$mesg='<div class="error">'.$langs->trans("ErrorModuleNotFound").'</div>';
dolibarr_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
dol_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
}
}
@@ -160,7 +160,7 @@ if ($resql)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
print '<table class="noborder" width=\"100%\">';

View File

@@ -112,7 +112,7 @@ print "<br>\n";
$head=security_prepare_head();
dolibarr_fiche_head($head, 'audit', $langs->trans("Security"));
dol_fiche_head($head, 'audit', $langs->trans("Security"));
print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST">';

View File

@@ -70,13 +70,13 @@ if ($_GET["action"] == 'specimen')
else
{
$mesg='<div class="error">'.$obj->error.'</div>';
dolibarr_syslog($obj->error, LOG_ERR);
dol_syslog($obj->error, LOG_ERR);
}
}
else
{
$mesg='<div class="error">'.$langs->trans("ErrorModuleNotFound").'</div>';
dolibarr_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
dol_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
}
}
@@ -172,7 +172,7 @@ if ($_GET["action"] == 'setmethod' || $_GET["action"] == 'setmod')
}
else
{
//dolibarr_print_error($db);
//dol_print_error($db);
$db->rollback();
}
}
@@ -241,7 +241,7 @@ if ($conf->global->MAIN_SUBMODULE_LIVRAISON)
$h++;
}
dolibarr_fiche_head($head, $hselected, $langs->trans("ModuleSetup"));
dol_fiche_head($head, $hselected, $langs->trans("ModuleSetup"));
@@ -270,7 +270,7 @@ if ($resql)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
print '<table class="noborder" width="100%">';

View File

@@ -51,7 +51,7 @@ if ($result)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
if ($_POST["action"] == 'add' || $_POST["modify"])
@@ -76,7 +76,7 @@ if ($_POST["action"] == 'add' || $_POST["modify"])
$resql=$db->query($sql);
if (! $resql)
{
dolibarr_print_error($db,"sql=$sql");
dol_print_error($db,"sql=$sql");
exit;
}
*/
@@ -88,7 +88,7 @@ if ($_POST["action"] == 'add' || $_POST["modify"])
$sql.= " VALUES ('box_external_rss.php','".addslashes($_POST["norss"].' ('.$_POST[$external_rss_title]).")')";
if (! $db->query($sql))
{
dolibarr_print_error($db);
dol_print_error($db);
$err++;
}
}
@@ -106,7 +106,7 @@ if ($_POST["action"] == 'add' || $_POST["modify"])
else
{
$db->rollback();
dolibarr_print_error($db);
dol_print_error($db);
}
}
}
@@ -141,7 +141,7 @@ if ($_POST["delete"])
if (! $resql)
{
$db->rollback();
dolibarr_print_error($db,"sql=$sql");
dol_print_error($db,"sql=$sql");
exit;
}
@@ -153,7 +153,7 @@ if ($_POST["delete"])
else
{
$db->rollback();
dolibarr_print_error($db,"sql=$sql");
dol_print_error($db,"sql=$sql");
exit;
}
@@ -171,7 +171,7 @@ if ($_POST["delete"])
else
{
$db->rollback();
dolibarr_print_error($db);
dol_print_error($db);
}
}
}
@@ -227,7 +227,7 @@ $sql ="select rowid, file, note from ".MAIN_DB_PREFIX."boxes_def";
$sql.=" WHERE file = 'box_external_rss.php'";
$sql.=" ORDER BY note";
dolibarr_syslog("external_rss select rss boxes sql=".$sql,LOG_DEBUG);
dol_syslog("external_rss select rss boxes sql=".$sql,LOG_DEBUG);
$resql=$db->query($sql);
if ($resql)
{
@@ -311,7 +311,7 @@ if ($resql)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
?>

View File

@@ -81,13 +81,13 @@ if ($_GET["action"] == 'specimen')
else
{
$mesg='<div class="error">'.$obj->error.'</div>';
dolibarr_syslog($obj->error, LOG_ERR);
dol_syslog($obj->error, LOG_ERR);
}
}
else
{
$mesg='<div class="error">'.$langs->trans("ErrorModuleNotFound").'</div>';
dolibarr_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
dol_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
}
}
@@ -181,7 +181,7 @@ if ($_POST["action"] == 'update' || $_POST["action"] == 'add')
{
if (! dolibarr_set_const($db, $_POST["constname"],$_POST["constvalue"],$typeconst[$_POST["consttype"]],0,isset($_POST["constnote"])?$_POST["constnote"]:''));
{
dolibarr_print_error($db);
dol_print_error($db);
}
}
@@ -189,7 +189,7 @@ if ($_GET["action"] == 'delete')
{
if (! dolibarr_del_const($db, $_GET["rowid"]));
{
dolibarr_print_error($db);
dol_print_error($db);
}
}
@@ -223,7 +223,7 @@ $head[$h][1] = $langs->trans("Invoices");
$hselected=$h;
$h++;
dolibarr_fiche_head($head, $hselected, $langs->trans("ModuleSetup"));
dol_fiche_head($head, $hselected, $langs->trans("ModuleSetup"));
/*
* Module numerotation
@@ -358,7 +358,7 @@ if ($resql)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
print '<table class="noborder" width="100%">';

View File

@@ -81,13 +81,13 @@ if ($_GET["action"] == 'specimen')
else
{
$mesg='<div class="error">'.$obj->error.'</div>';
dolibarr_syslog($obj->error, LOG_ERR);
dol_syslog($obj->error, LOG_ERR);
}
}
else
{
$mesg='<div class="error">'.$langs->trans("ErrorModuleNotFound").'</div>';
dolibarr_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
dol_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
}
}
@@ -272,7 +272,7 @@ if ($resql)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}

View File

@@ -77,13 +77,13 @@ if ($_GET["action"] == 'specimen')
else
{
$mesg='<div class="error">'.$obj->error.'</div>';
dolibarr_syslog($obj->error, LOG_ERR);
dol_syslog($obj->error, LOG_ERR);
}
}
else
{
$mesg='<div class="error">'.$langs->trans("ErrorModuleNotFound").'</div>';
dolibarr_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
dol_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
}
}
@@ -289,7 +289,7 @@ if ($resql)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
print "<table class=\"noborder\" width=\"100%\">\n";
@@ -419,7 +419,7 @@ print '</table><br/>';
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
*/

View File

@@ -46,7 +46,7 @@ class DolibarrImport
$this->nb_import_ko = 0;
$this->nb_import = 0;
dolibarr_syslog("DolibarrImport::ImportClients($file)", LOG_DEBUG);
dol_syslog("DolibarrImport::ImportClients($file)", LOG_DEBUG);
$this->ReadFile($file);
@@ -65,12 +65,12 @@ class DolibarrImport
if ( $societe->create($user) == 0)
{
dolibarr_syslog("DolibarrImport::ImportClients ".$societe->nom." SUCCESS", LOG_DEBUG);
dol_syslog("DolibarrImport::ImportClients ".$societe->nom." SUCCESS", LOG_DEBUG);
$this->nb_import_ok++;
}
else
{
dolibarr_syslog("DolibarrImport::ImportClients ".$societe->nom." ERROR", LOG_ERR);
dol_syslog("DolibarrImport::ImportClients ".$societe->nom." ERROR", LOG_ERR);
$this->nb_import_ko++;
}
}
@@ -106,7 +106,7 @@ class DolibarrImport
if (is_readable($file))
{
dolibarr_syslog("DolibarrImport::ReadFile Lecture du fichier $file", LOG_DEBUG);
dol_syslog("DolibarrImport::ReadFile Lecture du fichier $file", LOG_DEBUG);
$line = 0;
$hf = fopen ($file, "r");
@@ -150,7 +150,7 @@ class DolibarrImport
umask(0);
if (! mkdir($upload_dir, 0755))
{
dolibarr_syslog("DolibarrImport::ReadFile Impossible de cr<63>er $upload_dir",LOG_ERR);
dol_syslog("DolibarrImport::ReadFile Impossible de cr<63>er $upload_dir",LOG_ERR);
}
}
@@ -161,7 +161,7 @@ class DolibarrImport
umask(0);
if (! mkdir($upload_dir, 0755))
{
dolibarr_syslog("DolibarrImport::ReadFile Impossible de cr<63>er $upload_dir",LOG_ERR);
dol_syslog("DolibarrImport::ReadFile Impossible de cr<63>er $upload_dir",LOG_ERR);
}
}
@@ -172,7 +172,7 @@ class DolibarrImport
umask(0);
if (! mkdir($upload_dir, 0755))
{
dolibarr_syslog("DolibarrImport::ReadFile Impossible de cr<63>er $upload_dir",LOG_ERR);
dol_syslog("DolibarrImport::ReadFile Impossible de cr<63>er $upload_dir",LOG_ERR);
}
}

View File

@@ -64,7 +64,7 @@ if ($_GET["action"] == 'setvalue' && $user->admin)
if ($error)
{
dolibarr_print_error($db->error());
dol_print_error($db->error());
}
}
@@ -89,7 +89,7 @@ if ($mesg) print '<div class="error">'.$mesg.'</div>';
dolibarr_fiche_head($head, 'ldap', $langs->trans("LDAPSetup"));
dol_fiche_head($head, 'ldap', $langs->trans("LDAPSetup"));
$var=true;
$html=new Form($db);

View File

@@ -67,7 +67,7 @@ if ($_GET["action"] == 'setvalue' && $user->admin)
if ($error)
{
dolibarr_print_error($db->error());
dol_print_error($db->error());
}
}
@@ -90,7 +90,7 @@ if (! function_exists("ldap_connect"))
if ($mesg) print '<div class="error">'.$mesg.'</div>';
dolibarr_fiche_head($head, 'contacts', $langs->trans("LDAPSetup"));
dol_fiche_head($head, 'contacts', $langs->trans("LDAPSetup"));
print $langs->trans("LDAPDescContact").'<br>';

View File

@@ -58,7 +58,7 @@ if ($_GET["action"] == 'setvalue' && $user->admin)
if ($error)
{
dolibarr_print_error($db->error());
dol_print_error($db->error());
}
}
@@ -81,7 +81,7 @@ if (! function_exists("ldap_connect"))
if ($mesg) print '<div class="error">'.$mesg.'</div>';
dolibarr_fiche_head($head, 'groups', $langs->trans("LDAPSetup"));
dol_fiche_head($head, 'groups', $langs->trans("LDAPSetup"));
print $langs->trans("LDAPDescGroups").'<br>';

View File

@@ -81,7 +81,7 @@ if ($_GET["action"] == 'setvalue' && $user->admin)
if ($error)
{
dolibarr_print_error($db->error());
dol_print_error($db->error());
}
}
@@ -104,7 +104,7 @@ if (! function_exists("ldap_connect"))
if ($mesg) print '<div class="error">'.$mesg.'</div>';
dolibarr_fiche_head($head, 'members', $langs->trans("LDAPSetup"));
dol_fiche_head($head, 'members', $langs->trans("LDAPSetup"));
print $langs->trans("LDAPDescMembers").'<br>';

View File

@@ -69,7 +69,7 @@ if ($_GET["action"] == 'setvalue' && $user->admin)
if ($error)
{
dolibarr_print_error($db->error());
dol_print_error($db->error());
}
}
@@ -92,7 +92,7 @@ if (! function_exists("ldap_connect"))
if ($mesg) print '<div class="error">'.$mesg.'</div>';
dolibarr_fiche_head($head, 'users', $langs->trans("LDAPSetup"));
dol_fiche_head($head, 'users', $langs->trans("LDAPSetup"));
print $langs->trans("LDAPDescUsers").'<br>';

View File

@@ -77,13 +77,13 @@ if ($_GET["action"] == 'specimen')
else
{
$mesg='<div class="error">'.$obj->error.'</div>';
dolibarr_syslog($obj->error, LOG_ERR);
dol_syslog($obj->error, LOG_ERR);
}
}
else
{
$mesg='<div class="error">'.$langs->trans("ErrorModuleNotFound").'</div>';
dolibarr_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
dol_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
}
}
@@ -181,7 +181,7 @@ $hselected=$h;
$h++;
dolibarr_fiche_head($head, $hselected, $langs->trans("ModuleSetup"));
dol_fiche_head($head, $hselected, $langs->trans("ModuleSetup"));
/*
* Module numerotation
@@ -299,7 +299,7 @@ if ($resql)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
print '<table class="noborder" width="100%">';

View File

@@ -43,7 +43,7 @@ if ($_POST["action"] == 'setvalue' && $user->admin)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
}

View File

@@ -107,7 +107,7 @@ $head[$h][2] = 'editor';
$h++;
dolibarr_fiche_head($head, 'handler', $langs->trans("Menus"));
dol_fiche_head($head, 'handler', $langs->trans("Menus"));
if (isset($_GET["action"]) && $_GET["action"] == 'edit')

View File

@@ -477,7 +477,7 @@ elseif (isset($_GET["action"]) && $_GET["action"] == 'edit')
$sql.= ' WHERE c.rowid = mc.fk_constraint';
$sql.= ' AND mc.fk_menu = '.$_GET['menuId'];
dolibarr_syslog("Edit: sql=".$sql, LOG_DEBUG);
dol_syslog("Edit: sql=".$sql, LOG_DEBUG);
$resql = $db->query($sql);
if ($resql)
{
@@ -542,7 +542,7 @@ elseif (isset($_GET["action"]) && $_GET["action"] == 'edit')
while ($i < $num)
{
$objc = $db->fetch_object($resql);
print '<option value="'.$objc->rowid.'">'.dolibarr_trunc($objc->action,70).'</option>';
print '<option value="'.$objc->rowid.'">'.dol_trunc($objc->action,70).'</option>';
$i++;
}

View File

@@ -212,7 +212,7 @@ $head[$h][1] = $langs->trans("MenuAdmin");
$head[$h][2] = 'editor';
$h++;
dolibarr_fiche_head($head, 'editor', $langs->trans("Menus"));
dol_fiche_head($head, 'editor', $langs->trans("Menus"));
// Confirmation de la suppression menu
if ($_GET["action"] == 'delete')

View File

@@ -161,7 +161,7 @@ function UnActivate($value,$requiredby=1)
$genericMod->style_sheet=1;
$genericMod->rights_class=strtolower(eregi_replace('^mod','',$modName));
$genericMod->const_name='MAIN_MODULE_'.strtoupper(eregi_replace('^mod','',$modName));
dolibarr_syslog("modules::UnActivate Failed to find module file, we use generic function with name ".$genericMod->name);
dol_syslog("modules::UnActivate Failed to find module file, we use generic function with name ".$genericMod->name);
$genericMod->_remove();
}
}
@@ -308,7 +308,7 @@ if (! empty($categ[$categidx]))
$h++;
}
dolibarr_fiche_head($head, $tagmode, $langs->trans("Modules"));
dol_fiche_head($head, $tagmode, $langs->trans("Modules"));
if ($mesg) print '<div class="error">'.$mesg.'</div>';

View File

@@ -45,7 +45,7 @@ if ($_POST["action"] == 'setvalue' && $user->admin)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
}

View File

@@ -52,7 +52,7 @@ if ($_POST["action"] == 'setvalue' && $user->admin)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
}

View File

@@ -59,7 +59,7 @@ print "<br>\n";
$head=security_prepare_head();
dolibarr_fiche_head($head, 'default', $langs->trans("Security"));
dol_fiche_head($head, 'default', $langs->trans("Security"));
print info_admin($langs->trans("WarningOnlyPermissionOfActivatedModules"));

View File

@@ -59,7 +59,7 @@ if ($_POST["action"] == 'multiprix')
// on ajoute le champ price_level dans la table societe
if ($db->DDLAddField(MAIN_DB_PREFIX."societe","price_level",$field_desc) < 0)
{
dolibarr_print_error($db);
dol_print_error($db);
exit;
}
}
@@ -68,7 +68,7 @@ if ($_POST["action"] == 'multiprix')
}
else
{
dolibarr_syslog("Table definition for ".MAIN_DB_PREFIX."societe already ok");
dol_syslog("Table definition for ".MAIN_DB_PREFIX."societe already ok");
dolibarr_set_const($db, "PRODUIT_MULTIPRICES", $_POST["activate_multiprix"]);
dolibarr_set_const($db, "PRODUIT_MULTIPRICES_LIMIT", "6");
}
@@ -86,7 +86,7 @@ else if ($_POST["action"] == 'sousproduits')
$keys['idx_product_association_fk_product_fils'] = "fk_product_fils" ;
if ($db->DDLCreateTable($table,$fields,"","InnoDB","","",$keys) < 0)
{
dolibarr_print_error($db);
dol_print_error($db);
exit;
}
else
@@ -96,7 +96,7 @@ else if ($_POST["action"] == 'sousproduits')
}
else
{
dolibarr_syslog("Table definition already ok");
dol_syslog("Table definition already ok");
dolibarr_set_const($db, "PRODUIT_SOUSPRODUITS", $_POST["activate_sousproduits"]);
}
}

View File

@@ -78,13 +78,13 @@ if ($_GET["action"] == 'specimen')
else
{
$mesg='<div class="error">'.$module->error.'</div>';
dolibarr_syslog($module->error, LOG_ERR);
dol_syslog($module->error, LOG_ERR);
}
}
else
{
$mesg='<div class="error">'.$langs->trans("ErrorModuleNotFound").'</div>';
dolibarr_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
dol_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
}
}
@@ -318,7 +318,7 @@ if ($resql)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
$dir = "../includes/modules/propale/";

View File

@@ -47,7 +47,7 @@ if ($_GET["action"] == 'setgeneraterule')
{
if (! dolibarr_set_const($db, 'USER_PASSWORD_GENERATED',$_GET["value"]))
{
dolibarr_print_error($db);
dol_print_error($db);
}
else
{
@@ -78,7 +78,7 @@ if ($_GET["action"] == 'activate_encrypt')
else
{
$db->rollback();
dolibarr_print_error($db,'');
dol_print_error($db,'');
}
}
else if ($_GET["action"] == 'disable_encrypt')
@@ -169,7 +169,7 @@ print "<br>\n";
$head=security_prepare_head();
dolibarr_fiche_head($head, 'passwords', $langs->trans("Security"));
dol_fiche_head($head, 'passwords', $langs->trans("Security"));
$var=false;

View File

@@ -40,7 +40,7 @@ if ($_GET["action"] == 'set_main_upload_doc')
{
if (! dolibarr_set_const($db, 'MAIN_UPLOAD_DOC',$_POST["MAIN_UPLOAD_DOC"]))
{
dolibarr_print_error($db);
dol_print_error($db);
}
else
{
@@ -104,7 +104,7 @@ print "<br>\n";
$head=security_prepare_head();
dolibarr_fiche_head($head, 'misc', $langs->trans("Security"));
dol_fiche_head($head, 'misc', $langs->trans("Security"));
$var=false;

View File

@@ -47,7 +47,7 @@ if ($_GET["action"] == 'setcodeclient')
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
}
@@ -60,7 +60,7 @@ if ($_GET["action"] == 'setcodecompta')
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
}
@@ -73,7 +73,7 @@ if ($_POST["action"] == 'usesearchtoselectcompany')
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
}

View File

@@ -76,7 +76,7 @@ if ($_POST["action"] == 'STOCK_CALCULATE_ON_BILL'
else
{
$db->rollback();
dolibarr_print_error("Error in some requests", LOG_ERR);
dol_print_error("Error in some requests", LOG_ERR);
}
}
// Mode of stock decrease
@@ -98,7 +98,7 @@ if ($_POST["action"] == 'STOCK_CALCULATE_ON_SUPPLIER_BILL'
else
{
$db->rollback();
dolibarr_print_error("Error in some requests", LOG_ERR);
dol_print_error("Error in some requests", LOG_ERR);
}
}

View File

@@ -40,7 +40,7 @@ $langs->load("other");
if (! empty($_POST["action"]) && $_POST["action"] == 'setlevel')
{
dolibarr_set_const($db,"SYSLOG_LEVEL",$_POST["level"]);
dolibarr_syslog("admin/syslog: level ".$_POST["level"]);
dol_syslog("admin/syslog: level ".$_POST["level"]);
}
if (! empty($_POST["action"]) && $_POST["action"] == 'set')
@@ -55,7 +55,7 @@ if (! empty($_POST["action"]) && $_POST["action"] == 'set')
dolibarr_del_const($db,"SYSLOG_FILE");
dolibarr_set_const($db,"SYSLOG_FACILITY",$_POST["facility"]);
dolibarr_syslog("admin/syslog: facility ".$_POST["facility"]);
dol_syslog("admin/syslog: facility ".$_POST["facility"]);
}
else
{
@@ -72,7 +72,7 @@ if (! empty($_POST["action"]) && $_POST["action"] == 'set')
fclose($file);
dolibarr_del_const($db,"SYSLOG_FACILITY");
dolibarr_set_const($db,"SYSLOG_FILE",$_POST["filename"]);
dolibarr_syslog("admin/syslog: file ".$_POST["filename"]);
dol_syslog("admin/syslog: file ".$_POST["filename"]);
}
else
{

View File

@@ -133,9 +133,9 @@ if (function_exists('date_default_timezone_get'))
print "</td></tr>\n"; // value defined in http://fr3.php.net/manual/en/timezones.europe.php
}
$var=!$var;
print "<tr ".$bc[$var]."><td width=\"300\">=> ".$langs->trans("PHPServerOffsetWithGreenwich")."</td><td>".(- dolibarr_mktime(0,0,0,1,1,1970))."</td></tr>\n";
print "<tr ".$bc[$var]."><td width=\"300\">=> ".$langs->trans("PHPServerOffsetWithGreenwich")."</td><td>".(- dol_mktime(0,0,0,1,1,1970))."</td></tr>\n";
$var=!$var;
print "<tr ".$bc[$var]."><td width=\"300\">=> ".$langs->trans("CurrentHour")."</td><td>".dolibarr_print_date(time(),'dayhour')."</td></tr>\n";
print "<tr ".$bc[$var]."><td width=\"300\">=> ".$langs->trans("CurrentHour")."</td><td>".dol_print_date(time(),'dayhour')."</td></tr>\n";
$var=!$var;
print "<tr ".$bc[$var].'><td width="300">=> dol_print_date(0,"dayhourtext")</td><td>'.dol_print_date(0,"dayhourtext")."</td>";
print '</table>';

View File

@@ -67,7 +67,7 @@ if (isset($_POST['caching'])) {
}
$info = eaccelerator_info();
if (!is_array($info)) {
dolibarr_print_error('','An error occured getting eAccelerator information, this is caused if eAccelerator isn\'t initalised properly');
dol_print_error('','An error occured getting eAccelerator information, this is caused if eAccelerator isn\'t initalised properly');
exit;
}
@@ -151,8 +151,8 @@ function revcompare($x, $y)
foreach($list as $script) { ?>
<tr <?php $var = ! $var; print $bc[$var]; ?>>
<td><?php print dolibarr_trunc($script['file'],80,'left'); ?></td>
<td align="center" nowrap="nowrap"><?php print dolibarr_print_date($script['mtime'],'dayhour'); ?></td>
<td><?php print dol_trunc($script['file'],80,'left'); ?></td>
<td align="center" nowrap="nowrap"><?php print dol_print_date($script['mtime'],'dayhour'); ?></td>
<td align="right" nowrap="nowrap"><?php print number_format($script['size'] / 1024, 2); ?> KB</td>
<td align="right" nowrap="nowrap"><?php print $script['reloads']; ?> (<?php print $script['usecount']; ?>)</td>
<td align="right" nowrap="nowrap"><?php print $script['hits']; ?></td>
@@ -180,8 +180,8 @@ function create_key_table($list)
foreach($list as $key) {
?>
<tr <?php $var = ! $var; print $bc[$var]; ?>>
<td><?php print dolibarr_trunc($key['name'],80,'left'); ?></td>
<td align="center" nowrap="nowrap"><?php dolibarr_print_date($key['created'],'dayhour'); ?></td>
<td><?php print dol_trunc($key['name'],80,'left'); ?></td>
<td align="center" nowrap="nowrap"><?php dol_print_date($key['created'],'dayhour'); ?></td>
<td align="right" nowrap="nowrap"><?php print number_format($key['size']/1024, 3); ?> KB</td>
<td align="right" nowrap="nowrap"><?php
if ($key['ttl'] == -1) {
@@ -189,7 +189,7 @@ function create_key_table($list)
} elseif ($key['ttl'] == 0) {
print 'none';
} else {
print dolibarr_print_date($key['ttl'],'dayhour');
print dol_print_date($key['ttl'],'dayhour');
}
?></td>
</tr>

View File

@@ -160,7 +160,7 @@ if ($what == 'mysql')
if ($handle)
{
dolibarr_syslog("Run command ".$fullcommandcrypted);
dol_syslog("Run command ".$fullcommandcrypted);
$handlein = popen($fullcommandclear, 'r');
while (!feof($handlein))
{
@@ -179,7 +179,7 @@ if ($what == 'mysql')
else
{
$langs->load("errors");
dolibarr_syslog("Failed to open file $outputfile",LOG_ERR);
dol_syslog("Failed to open file $outputfile",LOG_ERR);
$errormsg=$langs->trans("ErrorFailedToWriteInDir");
}
// Get errorstring

View File

@@ -155,7 +155,7 @@ if ($result)
print "<tr $bc[$var]>";
// Date
print '<td align="left" nowrap="nowrap">'.dolibarr_print_date($obj->dateevent,'%Y-%m-%d %H:%M:%S').'</td>';
print '<td align="left" nowrap="nowrap">'.dol_print_date($obj->dateevent,'%Y-%m-%d %H:%M:%S').'</td>';
// Code
print '<td>'.$obj->type.'</td>';
@@ -208,7 +208,7 @@ if ($result)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
$db->close();

View File

@@ -36,7 +36,7 @@ require_once(DOL_DOCUMENT_ROOT."/boxes.php");
// Enregistrement de la position des boxes
if((isset($_GET['boxorder']) && !empty($_GET['boxorder'])) && (isset($_GET['userid']) && !empty($_GET['userid'])))
{
dolibarr_syslog("AjaxBox boxorder=".$_GET['boxorder']." userid=".$_GET['userid'], LOG_DEBUG);
dol_syslog("AjaxBox boxorder=".$_GET['boxorder']." userid=".$_GET['userid'], LOG_DEBUG);
$infobox=new InfoBox($db);
$result=$infobox->saveboxorder("0",$_GET['boxorder'],$_GET['userid']);

View File

@@ -67,7 +67,7 @@ class Bookmark
$sql.= " FROM ".MAIN_DB_PREFIX."bookmark";
$sql.= " WHERE rowid = ".$id;
dolibarr_syslog("Bookmark::fetch sql=".$sql, LOG_DEBUG);
dol_syslog("Bookmark::fetch sql=".$sql, LOG_DEBUG);
$resql = $this->db->query ($sql);
if ($resql)
{
@@ -88,7 +88,7 @@ class Bookmark
}
else
{
dolibarr_print_error($this->db);
dol_print_error($this->db);
return -1;
}
}
@@ -116,7 +116,7 @@ class Bookmark
if ($this->fk_soc) $sql.=",".$this->fk_soc;
$sql.= ")";
dolibarr_syslog("Bookmark::update sql=".$sql, LOG_DEBUG);
dol_syslog("Bookmark::update sql=".$sql, LOG_DEBUG);
$resql = $this->db->query ($sql);
if ($resql)
{
@@ -163,7 +163,7 @@ class Bookmark
$sql.= " ,favicon = '".$this->favicon."'";
$sql.= " WHERE rowid = ".$this->id;
dolibarr_syslog("Bookmark::update sql=".$sql, LOG_DEBUG);
dol_syslog("Bookmark::update sql=".$sql, LOG_DEBUG);
if ($this->db->query ($sql))
{
return 1;
@@ -185,7 +185,7 @@ class Bookmark
$sql = "DELETE FROM ".MAIN_DB_PREFIX."bookmark";
$sql .= " WHERE rowid = ".$id;
dolibarr_syslog("Bookmark::remove sql=".$sql, LOG_DEBUG);
dol_syslog("Bookmark::remove sql=".$sql, LOG_DEBUG);
$resql=$this->db->query ($sql);
if ($resql)
{

View File

@@ -73,13 +73,13 @@ function printBookmarksList ($aDb, $aLangs)
{
$ret.='<div class="menu_contenu"><a class="vsmenu" title="'.$obj->title.'" href="'.$obj->url.'"'.($obj->target == 1?' target="_blank"':'').'>';
$ret.=' '.img_object($langs->trans("BookmarkThisPage"),'bookmark').' ';
$ret.= dolibarr_trunc($obj->title, 20).'</a><br></div>';
$ret.= dol_trunc($obj->title, 20).'</a><br></div>';
$i++;
}
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}
}

View File

@@ -175,7 +175,7 @@ if ($_GET["id"] > 0 && ! eregi('^add',$_GET["action"]))
$bookmark->fetch($_GET["id"]);
dolibarr_fiche_head($head, $hselected, $langs->trans("Bookmark"));
dol_fiche_head($head, $hselected, $langs->trans("Bookmark"));
if ($_GET["action"] == 'edit')
{
@@ -234,7 +234,7 @@ if ($_GET["id"] > 0 && ! eregi('^add',$_GET["action"]))
}
print '</td></tr>';
print '<tr><td>'.$langs->trans("DateCreation").'</td><td>'.dolibarr_print_date($bookmark->datec,'dayhour').'</td></tr>';
print '<tr><td>'.$langs->trans("DateCreation").'</td><td>'.dol_print_date($bookmark->datec,'dayhour').'</td></tr>';
if ($_GET["action"] == 'edit') print '<tr><td colspan="2" align="center"><input class="button" type="submit" name="save" value="'.$langs->trans("Save").'"> &nbsp; &nbsp; <input class="button" type="submit" name="cancel" value="'.$langs->trans("Cancel").'"></td></tr>';

View File

@@ -112,8 +112,8 @@ if ($resql)
print '</td>';
$lieninterne=0;
$title=dolibarr_trunc($obj->title,24);
$lien=dolibarr_trunc($obj->url,24);
$title=dol_trunc($obj->title,24);
$lien=dol_trunc($obj->url,24);
// Title
print "<td>";
@@ -165,7 +165,7 @@ if ($resql)
print "</td>\n";
// Date creation
print '<td align="center">'.dolibarr_print_date($obj->dateb,'day') ."</td>";
print '<td align="center">'.dol_print_date($obj->dateb,'day') ."</td>";
// Actions
print "<td>";
@@ -186,7 +186,7 @@ if ($resql)
}
else
{
dolibarr_print_error($db);
dol_print_error($db);
}

View File

@@ -80,7 +80,7 @@ if ($_GET['id'])
print '<td><a href="'.DOL_URL_ROOT.'/boutique/commande/fiche.php?id='.$objp->orders_id.'"><img src="/theme/'.$conf->theme.'/img/filenew.png" border="0" alt="Fiche">&nbsp;';
print dolibarr_print_date($objp->date_purchased,'dayhour')."</a>\n";
print dol_print_date($objp->date_purchased,'dayhour')."</a>\n";
print $objp->total . "</a></TD>\n";
print "</tr>\n";
$i++;
@@ -91,14 +91,14 @@ if ($_GET['id'])
else
{
print "<p>ERROR 1</p>\n";
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
}
else
{
print "<p>ERROR 1</p>\n";
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}

View File

@@ -80,7 +80,7 @@ if ( $dbosc->query($sql) )
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
$dbosc->close();

View File

@@ -75,7 +75,7 @@ if ( $dbosc->query($sql) )
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
$sql = "SELECT sum(t.value) as value";
@@ -101,7 +101,7 @@ if ( $dbosc->query($sql) )
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}

View File

@@ -75,7 +75,7 @@ class Commande
$this->payment_method = stripslashes($array["payment_method"]);
$this->date = dolibarr_print_date($array["date_purchased"],'dayhour');
$this->date = dol_print_date($array["date_purchased"],'dayhour');
$this->delivery_adr->name = stripslashes($array["delivery_name"]);
$this->delivery_adr->street = stripslashes($array["delivery_street_address"]);

View File

@@ -73,7 +73,7 @@ if ( $dbosc->query($sql) )
print '<td><a href="fiche.php?id='.$objp->orders_id.'"><img src="/theme/'.$conf->theme.'/img/filenew.png" border="0" alt="Fiche">&nbsp;';
print $objp->orders_id ."</a></td><td>";
print dolibarr_print_date($objp->date_purchased,'dayhour').'</td>';
print dol_print_date($objp->date_purchased,'dayhour').'</td>';
print '<td><a href="../client/fiche.php?id='.$objp->customers_id.'">'.$objp->customers_name."</a></TD>\n";
print '<td align="right">'.price($objp->value).'</td>';
print "</tr>\n";
@@ -84,7 +84,7 @@ if ( $dbosc->query($sql) )
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
$dbosc->close();

View File

@@ -85,7 +85,7 @@ if ($resql)
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
print "</TABLE>";

View File

@@ -79,7 +79,7 @@ if ($resql) {
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
print "</TABLE>";

View File

@@ -84,7 +84,7 @@ if ($result)
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
/* mensuel
@@ -113,7 +113,7 @@ if ( $dbosc->query($sql) )
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
*/
@@ -155,7 +155,7 @@ if ( $dbosc->query($sql) )
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
/*
@@ -189,7 +189,7 @@ if ( $dbosc->query($sql) )
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
/*
@@ -223,7 +223,7 @@ if ( $dbosc->query($sql) )
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
@@ -260,7 +260,7 @@ if ( $dbosc->query($sql) )
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
print '</tr></table>';

View File

@@ -81,7 +81,7 @@ if ( $dbosc->query($sql) )
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
$dbosc->close();

View File

@@ -85,7 +85,7 @@ if ($resql)
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
$dbosc->close();

View File

@@ -30,7 +30,7 @@ require_once(DOL_DOCUMENT_ROOT ."/lib/databases/".$conf->db->type.".lib.php");
$dbosc = new DoliDb($conf->db->type,$conf->global->OSC_DB_HOST,$conf->global->OSC_DB_USER,$conf->global->OSC_DB_PASS,$conf->global->OSC_DB_NAME,$conf->global->OSC_DB_PORT);
if (! $dbosc->connected)
{
dolibarr_syslog($dbosc,"host=".$conf->global->OSC_DB_HOST.", user=".$conf->global->OSC_DB_USER.", databasename=".$conf->global->OSC_DB_NAME.", ".$db->error,LOG_ERR);
dol_syslog($dbosc,"host=".$conf->global->OSC_DB_HOST.", user=".$conf->global->OSC_DB_USER.", databasename=".$conf->global->OSC_DB_NAME.", ".$db->error,LOG_ERR);
llxHeader("",$langs->trans("OSCommerceShop"),"");
print '<div class="error">Failed to connect to oscommerce database. Check your module setup</div>';

View File

@@ -79,7 +79,7 @@ if ( $dbosc->query($sql) )
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
$dbosc->close();

View File

@@ -92,7 +92,7 @@ if ($resql)
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
print "</TABLE>";

View File

@@ -103,7 +103,7 @@ if ($resql)
print '<img src="/theme/'.$conf->theme.'/img/icon_status_green_light.png" border="0"></a></td>';
print '<td align="center"><img src="/theme/'.$conf->theme.'/img/icon_status_red.png" border="0" alt="inactif"></td>';
}
print "<td>".dolibarr_print_date($objp->fin,'day')."</td>";
print "<td>".dol_print_date($objp->fin,'day')."</td>";
print '<td align="right">'.price($objp->products_price)."</td>";
print '<td align="right">'.price($objp->specials_new_products_price)."</td>";
print "</tr>";
@@ -114,7 +114,7 @@ if ($resql)
}
else
{
dolibarr_print_error($dbosc);
dol_print_error($dbosc);
}
$dbosc->close();

View File

@@ -73,7 +73,7 @@ class InfoBox
$sql.= " AND b.fk_user = ".$user->id;
$sql.= " ORDER BY b.box_order";
dolibarr_syslog("InfoBox::listBoxes get user box list sql=".$sql, LOG_DEBUG);
dol_syslog("InfoBox::listBoxes get user box list sql=".$sql, LOG_DEBUG);
$result = $this->db->query($sql);
if ($result)
{
@@ -105,7 +105,7 @@ class InfoBox
}
else {
$this->error=$this->db->error();
dolibarr_syslog("InfoBox::listBoxes Error ".$this->error, LOG_ERR);
dol_syslog("InfoBox::listBoxes Error ".$this->error, LOG_ERR);
return array();
}
}
@@ -120,7 +120,7 @@ class InfoBox
$sql.= " AND b.fk_user = 0";
$sql.= " ORDER BY b.box_order";
dolibarr_syslog("InfoBox::listBoxes get default box list sql=".$sql, LOG_DEBUG);
dol_syslog("InfoBox::listBoxes get default box list sql=".$sql, LOG_DEBUG);
$result = $this->db->query($sql);
if ($result)
{
@@ -152,7 +152,7 @@ class InfoBox
}
else {
$this->error=$this->db->error();
dolibarr_syslog("InfoBox::listBoxes Error ".$this->error, LOG_ERR);
dol_syslog("InfoBox::listBoxes Error ".$this->error, LOG_ERR);
return array();
}
}
@@ -172,7 +172,7 @@ class InfoBox
{
require_once(DOL_DOCUMENT_ROOT."/lib/functions2.lib.php");
dolibarr_syslog("InfoBoxes::saveboxorder zone=".$zone." user=".$userid);
dol_syslog("InfoBoxes::saveboxorder zone=".$zone." user=".$userid);
if (! $userid || $userid == 0) return 0;
@@ -194,7 +194,7 @@ class InfoBox
$sql.=" WHERE fk_user = ".$userid;
$sql.=" AND position = ".$zone;
dolibarr_syslog("InfoBox::saveboxorder sql=".$sql);
dol_syslog("InfoBox::saveboxorder sql=".$sql);
$result = $this->db->query($sql);
if ($result)
{
@@ -204,7 +204,7 @@ class InfoBox
$part=split(':',$collist);
$colonne=$part[0];
$list=$part[1];
dolibarr_syslog('InfoBox::saveboxorder colonne='.$colonne.' list='.$list);
dol_syslog('InfoBox::saveboxorder colonne='.$colonne.' list='.$list);
$i=0;
$listarray=split(',',$list);
@@ -212,7 +212,7 @@ class InfoBox
{
if (is_numeric($id))
{
//dolibarr_syslog("aaaaa".sizeof($listarray));
//dol_syslog("aaaaa".sizeof($listarray));
$i++;
$ii=sprintf('%02d',$i);
$sql = "INSERT INTO ".MAIN_DB_PREFIX."boxes";
@@ -224,7 +224,7 @@ class InfoBox
$sql.= " ".$userid;
$sql.= ")";
dolibarr_syslog("InfoBox::saveboxorder sql=".$sql);
dol_syslog("InfoBox::saveboxorder sql=".$sql);
$result = $this->db->query($sql);
if ($result < 0)
{

View File

@@ -115,7 +115,7 @@ class CActionComm {
$sql.=" WHERE active=".$active;
}
dolibarr_syslog("CActionComm::liste_array sql=".$sql);
dol_syslog("CActionComm::liste_array sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
{

View File

@@ -52,7 +52,7 @@ class Sql implements intSql {
* @return Ressource vers la requ<71>te venant d'<27>tre effectu<74>e
*/
public function query ($aRequete) {
dolibarr_syslog("cashdesk query sql=".$aRequete, LOG_DEBUG);
dol_syslog("cashdesk query sql=".$aRequete, LOG_DEBUG);
return mysql_query($aRequete);
}

View File

@@ -22,14 +22,14 @@ $sessionname="DOLSESSID_".$dolibarr_main_db_name;
if (! empty($conf->global->MAIN_SESSION_TIMEOUT)) ini_set('session.gc_maxlifetime',$conf->global->MAIN_SESSION_TIMEOUT);
session_name($sessionname);
session_start();
dolibarr_syslog("Start session name=".$sessionname." Session id()=".session_id().", _SESSION['dol_login']=".$_SESSION["dol_login"].", ".ini_get("session.gc_maxlifetime"));
dol_syslog("Start session name=".$sessionname." Session id()=".session_id().", _SESSION['dol_login']=".$_SESSION["dol_login"].", ".ini_get("session.gc_maxlifetime"));
// Destroy session
$sessionname="DOLSESSID_".$dolibarr_main_db_name;
if (! empty($conf->global->MAIN_SESSION_TIMEOUT)) ini_set('session.gc_maxlifetime',$conf->global->MAIN_SESSION_TIMEOUT);
session_name($sessionname);
session_destroy();
dolibarr_syslog("End session in DOLSESSID_".$dolibarr_main_db_name);
dol_syslog("End session in DOLSESSID_".$dolibarr_main_db_name);
header ('Location: index.php');

View File

@@ -21,7 +21,7 @@ $sessionname="DOLSESSID_".$dolibarr_main_db_name;
if (! empty($conf->global->MAIN_SESSION_TIMEOUT)) ini_set('session.gc_maxlifetime',$conf->global->MAIN_SESSION_TIMEOUT);
session_name($sessionname);
session_start();
dolibarr_syslog("Start session name=".$sessionname." Session id()=".session_id().", _SESSION['dol_login']=".$_SESSION["dol_login"].", ".ini_get("session.gc_maxlifetime"));
dol_syslog("Start session name=".$sessionname." Session id()=".session_id().", _SESSION['dol_login']=".$_SESSION["dol_login"].", ".ini_get("session.gc_maxlifetime"));
$conf_db_type = $dolibarr_main_db_type;
@@ -43,9 +43,9 @@ $conf_fkaccount = $conf->global->CASHDESK_ID_BANKACCOUNT > 0?$conf->global->CASH
$conf_fkentrepot = $conf->global->CASHDESK_ID_WAREHOUSE > 0?$conf->global->CASHDESK_ID_WAREHOUSE:$_SESSION["CASHDESK_ID_WAREHOUSE"];
// Check if setup ok
if (empty($conf_fksoc)) dolibarr_print_error("Setup of CashDesk module not complete. Third party not defined.");
if ($conf->bank->enabled && empty($conf_fkaccount)) dolibarr_print_error("Setup of CashDesk module not complete. Bank account not defined.");
if ($conf->stock->enabled && empty($conf_fkentrepot)) dolibarr_print_error("Setup of CashDesk module not complete. Warehous not defined.");
if (empty($conf_fksoc)) dol_print_error("Setup of CashDesk module not complete. Third party not defined.");
if ($conf->bank->enabled && empty($conf_fkaccount)) dol_print_error("Setup of CashDesk module not complete. Bank account not defined.");
if ($conf->stock->enabled && empty($conf_fkentrepot)) dol_print_error("Setup of CashDesk module not complete. Warehous not defined.");
// Parametres d'affichage
$conf_taille_listes = 200; // Nombre max de lignes a afficher dans les listes

View File

@@ -22,7 +22,7 @@ $sessionname="DOLSESSID_".$dolibarr_main_db_name;
if (! empty($conf->global->MAIN_SESSION_TIMEOUT)) ini_set('session.gc_maxlifetime',$conf->global->MAIN_SESSION_TIMEOUT);
session_name($sessionname);
session_start();
dolibarr_syslog("Start session name=".$sessionname." Session id()=".session_id().", _SESSION['dol_login']=".$_SESSION["dol_login"].", ".ini_get("session.gc_maxlifetime"));
dol_syslog("Start session name=".$sessionname." Session id()=".session_id().", _SESSION['dol_login']=".$_SESSION["dol_login"].", ".ini_get("session.gc_maxlifetime"));
if ( $_SESSION['uid'] > 0 ) {

View File

@@ -76,7 +76,7 @@ class Categorie
$sql.= " FROM ".MAIN_DB_PREFIX."categorie";
$sql.= " WHERE rowid = ".$id;
dolibarr_syslog("Categorie::fetch sql=".$sql);
dol_syslog("Categorie::fetch sql=".$sql);
$resql = $this->db->query ($sql);
if ($resql)
{
@@ -93,7 +93,7 @@ class Categorie
}
else
{
dolibarr_print_error ($this->db);
dol_print_error ($this->db);
return -1;
}
@@ -101,7 +101,7 @@ class Categorie
$sql.= " FROM ".MAIN_DB_PREFIX."categorie_association";
$sql.= " WHERE fk_categorie_fille = '".$id."'";
dolibarr_syslog("Categorie::fetch sql=".$sql);
dol_syslog("Categorie::fetch sql=".$sql);
$resql = $this->db->query ($sql);
if ($resql)
{
@@ -111,7 +111,7 @@ class Categorie
}
else
{
dolibarr_print_error ($this->db);
dol_print_error ($this->db);
return -1;
}
}
@@ -174,7 +174,7 @@ class Categorie
}
else
{
dolibarr_print_error ($this->db);
dol_print_error ($this->db);
return -1;
}
}
@@ -198,11 +198,11 @@ class Categorie
$sql = 'delete from '.MAIN_DB_PREFIX.'categorie_association';
$sql .= ' WHERE fk_categorie_fille = "'.$this->id.'"';
dolibarr_syslog("Categorie::update sql=".$sql);
dol_syslog("Categorie::update sql=".$sql);
if (! $this->db->query($sql))
{
$this->db->rollback();
dolibarr_print_error($this->db);
dol_print_error($this->db);
return -1;
}
@@ -211,11 +211,11 @@ class Categorie
$sql = 'insert into '.MAIN_DB_PREFIX.'categorie_association(fk_categorie_mere,fk_categorie_fille)';
$sql .= ' VALUES ("'.$this->id_mere.'","'.$this->id.'")';
dolibarr_syslog("Categorie::update sql=".$sql);
dol_syslog("Categorie::update sql=".$sql);
if (! $this->db->query($sql))
{
$this->db->rollback();
dolibarr_print_error($this->db);
dol_print_error($this->db);
return -1;
}
}
@@ -233,7 +233,7 @@ class Categorie
$sql .= ", visible = '".$this->visible."'";
$sql .= " WHERE rowid = ".$this->id;
dolibarr_syslog("Categorie::update sql=".$sql);
dol_syslog("Categorie::update sql=".$sql);
if ($this->db->query($sql))
{
$this->db->commit();
@@ -242,7 +242,7 @@ class Categorie
else
{
$this->db->rollback();
dolibarr_print_error($this->db);
dol_print_error($this->db);
return -1;
}
}
@@ -260,7 +260,7 @@ class Categorie
if (!$this->db->query($sql))
{
dolibarr_print_error($this->db);
dol_print_error($this->db);
return -1;
}
@@ -270,7 +270,7 @@ class Categorie
if (!$this->db->query($sql))
{
dolibarr_print_error($this->db);
dol_print_error($this->db);
return -1;
}
@@ -279,7 +279,7 @@ class Categorie
if (!$this->db->query($sql))
{
dolibarr_print_error($this->db);
dol_print_error($this->db);
return -1;
}
else
@@ -309,7 +309,7 @@ class Categorie
}
else
{
dolibarr_print_error($this->db);
dol_print_error($this->db);
return -1;
}
}
@@ -416,7 +416,7 @@ class Categorie
$sql = "SELECT fk_".$field." FROM ".MAIN_DB_PREFIX."categorie_".$table;
$sql .= " WHERE fk_categorie = ".$this->id;
dolibarr_syslog("Categorie::get_type sql=".$sql);
dol_syslog("Categorie::get_type sql=".$sql);
$res = $this->db->query($sql);
if ($res)
{
@@ -431,7 +431,7 @@ class Categorie
else
{
$this->error=$this->db->error().' sql='.$sql;
dolibarr_syslog("Categorie::get_type ".$this->error, LOG_ERR);
dol_syslog("Categorie::get_type ".$this->error, LOG_ERR);
return -1;
}
}
@@ -461,7 +461,7 @@ class Categorie
}
else
{
dolibarr_print_error ($this->db);
dol_print_error ($this->db);
return -1;
}
}
@@ -518,7 +518,7 @@ class Categorie
$sql = "SELECT fk_categorie_mere as id_mere, fk_categorie_fille as id_fille";
$sql.= " FROM ".MAIN_DB_PREFIX."categorie_association";
dolibarr_syslog("Categorie::get_full_arbo build motherof array sql=".$sql, LOG_DEBUG);
dol_syslog("Categorie::get_full_arbo build motherof array sql=".$sql, LOG_DEBUG);
$resql = $this->db->query($sql);
if ($resql)
{
@@ -529,7 +529,7 @@ class Categorie
}
else
{
dolibarr_print_error ($this->db);
dol_print_error ($this->db);
return -1;
}
@@ -541,7 +541,7 @@ class Categorie
$sql.= " WHERE c.type = ".$type;
$sql.= " ORDER BY c.label, c.rowid";
dolibarr_syslog("Categorie::get_full_arbo get category list sql=".$sql, LOG_DEBUG);
dol_syslog("Categorie::get_full_arbo get category list sql=".$sql, LOG_DEBUG);
$resql = $this->db->query($sql);
if ($resql)
{
@@ -562,19 +562,19 @@ class Categorie
}
else
{
dolibarr_print_error ($this->db);
dol_print_error ($this->db);
return -1;
}
// We add the fulpath property to each elements of first level (no parent exists)
dolibarr_syslog("Categorie::get_full_arbo call to build_path_from_id_categ", LOG_DEBUG);
dol_syslog("Categorie::get_full_arbo call to build_path_from_id_categ", LOG_DEBUG);
foreach($this->cats as $key => $val)
{
if (isset($this->motherof[$key])) continue;
$this->build_path_from_id_categ($key,0); // Process a path of a root category (no parent exists)
}
dolibarr_syslog("Categorie::get_full_arbo dol_sort_array", LOG_DEBUG);
dol_syslog("Categorie::get_full_arbo dol_sort_array", LOG_DEBUG);
$this->cats=dol_sort_array($this->cats, 'fulllabel', 'asc', true, false);
//$this->debug_cats();
@@ -589,12 +589,12 @@ class Categorie
*/
function build_path_from_id_categ($id_categ,$protection=0)
{
dolibarr_syslog("Categorie::build_path_from_id_categ id_categ=".$id_categ." protection=".$protection, LOG_DEBUG);
dol_syslog("Categorie::build_path_from_id_categ id_categ=".$id_categ." protection=".$protection, LOG_DEBUG);
//if (! empty($this->cats[$id_categ]['fullpath']))
//{
// Already defined
// dolibarr_syslog("Categorie::build_path_from_id_categ fullpath and fulllabel already defined", LOG_WARNING);
// dol_syslog("Categorie::build_path_from_id_categ fullpath and fulllabel already defined", LOG_WARNING);
// return;
//}
@@ -623,7 +623,7 @@ class Categorie
// Protection when a category has itself as a child (should not happen)
if ($idchild == $id_categ)
{
dolibarr_syslog("Categorie::build_path_from_id_categ bad couple (".$idchild.",".$id_categ.") in association table: An entry should not have itself has child", LOG_WARNING);
dol_syslog("Categorie::build_path_from_id_categ bad couple (".$idchild.",".$id_categ.") in association table: An entry should not have itself has child", LOG_WARNING);
continue;
}
@@ -673,7 +673,7 @@ class Categorie
}
else
{
dolibarr_print_error ($this->db);
dol_print_error ($this->db);
return -1;
}
}
@@ -694,7 +694,7 @@ class Categorie
}
else
{
dolibarr_print_error ($this->db);
dol_print_error ($this->db);
return -1;
}
}
@@ -724,7 +724,7 @@ class Categorie
}
else
{
dolibarr_print_error ($this->db);
dol_print_error ($this->db);
return -1;
}
@@ -856,7 +856,7 @@ class Categorie
}
else
{
dolibarr_print_error ($this->db);
dol_print_error ($this->db);
return -1;
}
}
@@ -914,7 +914,7 @@ class Categorie
}
else
{
dolibarr_print_error ($this->db);
dol_print_error ($this->db);
return -1;
}
}
@@ -957,8 +957,8 @@ class Categorie
else
{
$this->error=$this->db->error().' sql='.$sql;
//dolibarr_syslog($this->error);
dolibarr_print_error('',$this->error);
//dol_syslog($this->error);
dol_print_error('',$this->error);
return -1;
}
}

View File

@@ -136,7 +136,7 @@ if ($_GET["socid"])
*/
$head = societe_prepare_head($soc);
dolibarr_fiche_head($head, 'category', $langs->trans("ThirdParty"));
dol_fiche_head($head, 'category', $langs->trans("ThirdParty"));
print '<table class="border" width="100%">';
@@ -214,7 +214,7 @@ else if ($_GET["id"] || $_GET["ref"])
$head=product_prepare_head($product, $user);
$titre=$langs->trans("CardProduct".$product->type);
dolibarr_fiche_head($head, 'category', $titre);
dol_fiche_head($head, 'category', $titre);
print '<table class="border" width="100%">';

View File

@@ -249,14 +249,14 @@ foreach($fulltree as $key => $val)
// Show link
print '<td valign="middle">';
if ($section == $val['id']) print ' <u>';
print dolibarr_trunc($val['label'],28);
print dol_trunc($val['label'],28);
if ($section == $val['id']) print '</u>';
print '</td>';
print '</tr></table>';
print "</td>\n";
print '<td>';
print dolibarr_trunc($categstatic->get_desc($val['id']),48);
print dol_trunc($categstatic->get_desc($val['id']),48);
print '</td>';
// Edit link

View File

@@ -56,7 +56,7 @@ if ($cats != -1)
$var = ! $var;
print "\t<tr ".$bc[$var].">\n";
print "\t\t<td><a href='viewcat.php?id=".$cat->id."'>".$cat->label."</a></td>\n";
print "\t\t<td>".dolibarr_trunc($cat->description,36)."</td>\n";
print "\t\t<td>".dol_trunc($cat->description,36)."</td>\n";
print '<td align="right">';
if ($cat->type == 0) print $langs->trans("Product");
elseif ($cat->type == 1) print $langs->trans("Supplier");
@@ -69,7 +69,7 @@ if ($cats != -1)
}
else
{
dolibarr_print_error();
dol_print_error();
}
print '</td></tr></table>';

View File

@@ -30,7 +30,7 @@ require("./pre.inc.php");
if ($_REQUEST['id'] == "")
{
dolibarr_print_error('','Missing parameter id');
dol_print_error('','Missing parameter id');
exit();
}
@@ -92,7 +92,7 @@ if ($type == 0) $title=$langs->trans("ProductsCategoryShort");
if ($type == 1) $title=$langs->trans("SuppliersCategoryShort");
if ($type == 2) $title=$langs->trans("CustomersCategoryShort");
dolibarr_fiche_head($head, 'card', $title);
dol_fiche_head($head, 'card', $title);
/*
@@ -138,7 +138,7 @@ if ($type == 0 && $conf->global->CATEGORY_ASSIGNED_TO_A_CUSTOMER)
if ($catsMeres < 0)
{
dolibarr_print_error();
dol_print_error();
}
else if (count($catsMeres) > 0)
{
@@ -194,7 +194,7 @@ print "</div>";
$cats = $c->get_filles ();
if ($cats < 0)
{
dolibarr_print_error();
dol_print_error();
}
else
{
@@ -255,7 +255,7 @@ if ($c->type == 0)
$prods = $c->get_type ("product","Product");
if ($prods < 0)
{
dolibarr_print_error();
dol_print_error();
}
else
{
@@ -294,7 +294,7 @@ if ($c->type == 1)
$socs = $c->get_type ("societe","Fournisseur","fournisseur");
if ($socs < 0)
{
dolibarr_print_error();
dol_print_error();
}
else
{
@@ -331,7 +331,7 @@ if($c->type == 2)
$socs = $c->get_type ("societe","Societe");
if ($socs < 0)
{
dolibarr_print_error();
dol_print_error();
}
else
{

View File

@@ -68,7 +68,7 @@ class ChargeSociales extends CommonObject
$sql.= " WHERE cs.fk_type = c.id";
$sql.= " AND cs.rowid = ".$id;
dolibarr_syslog("ChargesSociales::fetch sql=".$sql);
dol_syslog("ChargesSociales::fetch sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
{
@@ -126,13 +126,13 @@ class ChargeSociales extends CommonObject
$sql.= " ".price2num($newamount);
$sql.= ")";
dolibarr_syslog("ChargesSociales::create sql=".$sql);
dol_syslog("ChargesSociales::create sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
{
$this->id=$this->db->last_insert_id(MAIN_DB_PREFIX."chargesociales");
//dolibarr_syslog("ChargesSociales::create this->id=".$this->id);
//dol_syslog("ChargesSociales::create this->id=".$this->id);
$this->db->commit();
return $this->id;
}
@@ -154,7 +154,7 @@ class ChargeSociales extends CommonObject
{
$sql = "DELETE FROM ".MAIN_DB_PREFIX."chargesociales where rowid='".$this->id."'";
dolibarr_syslog("ChargesSociales::delete sql=".$sql);
dol_syslog("ChargesSociales::delete sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
{
@@ -183,7 +183,7 @@ class ChargeSociales extends CommonObject
$sql.= " periode='".$this->periode."'";
$sql.= " WHERE rowid=".$this->id;
dolibarr_syslog("ChargesSociales::update sql=".$sql);
dol_syslog("ChargesSociales::update sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
{
@@ -309,7 +309,7 @@ class ChargeSociales extends CommonObject
if ($withpicto) $result.=($lien.img_object($langs->trans("ShowSocialContribution"),'bill').$lienfin.' ');
if ($withpicto && $withpicto != 2) $result.=' ';
if ($withpicto != 2) $result.=$lien.($maxlen?dolibarr_trunc($this->lib,$maxlen):$this->lib).$lienfin;
if ($withpicto != 2) $result.=$lien.($maxlen?dol_trunc($this->lib,$maxlen):$this->lib).$lienfin;
return $result;
}
@@ -326,7 +326,7 @@ class ChargeSociales extends CommonObject
$sql.= ' FROM '.MAIN_DB_PREFIX.$table;
$sql.= ' WHERE '.$field.' = '.$this->id;
dolibarr_syslog("ChargeSociales::getSommePaiement sql=".$sql, LOG_DEBUG);
dol_syslog("ChargeSociales::getSommePaiement sql=".$sql, LOG_DEBUG);
$resql=$this->db->query($sql);
if ($resql)
{
@@ -401,7 +401,7 @@ class PaiementCharge
$sql.= ", ".$this->paiementtype.", '".$this->num_paiement."', '".addslashes($this->note)."', ".$user->id.",";
$sql.= "0)";
dolibarr_syslog("PaiementCharge::create sql=".$sql);
dol_syslog("PaiementCharge::create sql=".$sql);
$resql=$this->db->query($sql);
if ($resql)
{
@@ -422,7 +422,7 @@ class PaiementCharge
else
{
$this->error=$this->db->error();
dolibarr_syslog("PaiementCharges::create ".$this->error, LOG_ERR);
dol_syslog("PaiementCharges::create ".$this->error, LOG_ERR);
$this->db->rollback();
return -1;
}
@@ -437,7 +437,7 @@ class PaiementCharge
{
$sql = "UPDATE llx_paiementcharge set fk_bank = ".$id_bank." where rowid = ".$this->id;
dolibarr_syslog("PaiementCharge::update_fk_bank sql=".$sql);
dol_syslog("PaiementCharge::update_fk_bank sql=".$sql);
$result = $this->db->query($sql);
if ($result)
{
@@ -446,7 +446,7 @@ class PaiementCharge
else
{
$this->error=$this->db->error();
dolibarr_syslog("PaiementCharges::update_fk_bank ".$this->error, LOG_ERR);
dol_syslog("PaiementCharges::update_fk_bank ".$this->error, LOG_ERR);
return 0;
}
}

Some files were not shown because too many files have changed in this diff Show More