diff --git a/build/phpstan/README b/build/phpstan/README
index b289eefc1c6..097aac0d3c4 100644
--- a/build/phpstan/README
+++ b/build/phpstan/README
@@ -18,4 +18,4 @@ mv /tmp/custom htdocs
Build HTML report from Cron:
Example of line to add into a cron to generate a HTML report:
-0 1 5 * * cd /home/dolibarr/preview.dolibarr.org/dolibarr; chmod -R u+w /home/dolibarr/preview.dolibarr.org/dolibarr; git pull; /home/dolibarr/phpstan/vendor/bin/phpstan -v analyze -a build/phpstan/bootstrap.php --memory-limit 4G --error-format=github | awk ' BEGIN { print "Date "strftime("%Y-%m-%d")"
" } { print $0"
" } ' > /home/dolibarr/doxygen.dolibarr.org/phpstan/index.html
+0 1 5 * * cd /home/dolibarr/preview.dolibarr.org/dolibarr; chmod -R u+w /home/dolibarr/preview.dolibarr.org/dolibarr; git pull; /home/dolibarr/phpstan/vendor/bin/phpstan -v analyze -a build/phpstan/bootstrap.php --memory-limit 4G --error-format=github | awk ' BEGIN{ print "Date "strftime("%Y-%m-%d")"
" } { print $0"
" } END{ print NR } ' > /home/dolibarr/doxygen.dolibarr.org/phpstan/index.html
diff --git a/htdocs/accountancy/class/accountingaccount.class.php b/htdocs/accountancy/class/accountingaccount.class.php
index 160383ce5c2..6405a55c689 100644
--- a/htdocs/accountancy/class/accountingaccount.class.php
+++ b/htdocs/accountancy/class/accountingaccount.class.php
@@ -734,7 +734,7 @@ class AccountingAccount extends CommonObject
* @param FactureLigne|SupplierInvoiceLine $factureDet Facture Det
* @param array $accountingAccount Array of Accounting account
* @param string $type Customer / Supplier
- * @return array|int Accounting accounts suggested or < 0 if technical error.
+ * @return array|int Array of accounting accounts suggested or < 0 if technical error.
* 'suggestedaccountingaccountbydefaultfor'=>Will be used for the label to show on tooltip for account by default on any product
* 'suggestedaccountingaccountfor'=>Is the account suggested for this product
*/
@@ -941,5 +941,7 @@ class AccountingAccount extends CommonObject
return $hookmanager->resArray;
}
}
+
+ return -1;
}
}
diff --git a/htdocs/adherents/class/adherent.class.php b/htdocs/adherents/class/adherent.class.php
index 7ba43bff572..151480533db 100644
--- a/htdocs/adherents/class/adherent.class.php
+++ b/htdocs/adherents/class/adherent.class.php
@@ -133,79 +133,11 @@ class Adherent extends CommonObject
*/
public $socid;
- /**
- * @var string Address
- */
- public $address;
-
- /**
- * @var string zipcode
- */
- public $zip;
-
- /**
- * @var string town
- */
- public $town;
-
- /**
- * @var int Id of state
- */
- public $state_id;
-
- /**
- * @var string Code of state
- */
- public $state_code;
-
- /**
- * @var string Label of state
- */
- public $state;
-
- /**
- * @var string email
- */
- public $email;
-
- /**
- * @var string url
- */
- public $url;
-
/**
* @var array array of socialnetworks
*/
public $socialnetworks;
- /**
- * @var string skype account
- * @deprecated
- * @see $socialnetworks
- */
- public $skype;
-
- /**
- * @var string twitter account
- * @deprecated
- * @see $socialnetworks
- */
- public $twitter;
-
- /**
- * @var string facebook account
- * @deprecated
- * @see $socialnetworks
- */
- public $facebook;
-
- /**
- * @var string linkedin account
- * @deprecated
- * @see $socialnetworks
- */
- public $linkedin;
-
/**
* @var string Phone number
*/
@@ -337,16 +269,11 @@ class Adherent extends CommonObject
public $partnerships = array();
-
/**
- * @var Adherent To contains a clone of this when we need to save old properties of object
+ * @var Facture To store the created invoice into subscriptionComplementaryActions()
*/
- public $oldcopy;
+ public $invoice;
- /**
- * @var int Entity
- */
- public $entity;
/**
* @var array fields
diff --git a/htdocs/adherents/list.php b/htdocs/adherents/list.php
index 52ef9109f9c..014448a5a95 100644
--- a/htdocs/adherents/list.php
+++ b/htdocs/adherents/list.php
@@ -143,9 +143,6 @@ $fieldstosearchall = array(
'd.note_public'=>'NotePublic',
'd.note_private'=>'NotePrivate',
);
-if ($db->type == 'pgsql') {
- unset($fieldstosearchall['d.rowid']);
-}
$arrayfields = array(
'd.ref'=>array('label'=>"Ref", 'checked'=>1),
diff --git a/htdocs/admin/fckeditor.php b/htdocs/admin/fckeditor.php
index 1a1e582cbee..2b5644a0642 100644
--- a/htdocs/admin/fckeditor.php
+++ b/htdocs/admin/fckeditor.php
@@ -94,10 +94,8 @@ $picto = array(
foreach ($modules as $const => $desc) {
if ($action == 'enable_'.strtolower($const)) {
-
-
dolibarr_set_const($db, "FCKEDITOR_ENABLE_".$const, "1", 'chaine', 0, '', $conf->entity);
-
+
// If fckeditor is active in the product/service description, it is activated in the forms
if ($const == 'PRODUCTDESC' && getDolGlobalInt('PRODUIT_DESC_IN_FORM_ACCORDING_TO_DEVICE')) {
dolibarr_set_const($db, "FCKEDITOR_ENABLE_DETAILS", "1", 'chaine', 0, '', $conf->entity);
@@ -106,7 +104,6 @@ foreach ($modules as $const => $desc) {
exit;
}
if ($action == 'disable_'.strtolower($const)) {
-
dolibarr_set_const($db, "FCKEDITOR_ENABLE_".$const, "0", 'chaine', 0, '', $conf->entity);
header("Location: ".$_SERVER["PHP_SELF"]);
exit;
diff --git a/htdocs/admin/security.php b/htdocs/admin/security.php
index e30e50769bb..166d8d420dc 100644
--- a/htdocs/admin/security.php
+++ b/htdocs/admin/security.php
@@ -130,7 +130,8 @@ if ($action == 'activate_encryptdbpassconf') {
header("Location: security.php");
exit;
} else {
- setEventMessages($langs->trans('InstrucToClearPass', $dolibarr_main_db_pass), null, 'warnings');
+ //setEventMessages($langs->trans('InstrucToClearPass', $dolibarr_main_db_pass), null, 'warnings');
+ setEventMessages($langs->trans('InstrucToClearPass', $langs->transnoentitiesnoconv("DatabasePassword")), null, 'warnings');
}
}
diff --git a/htdocs/compta/facture/card.php b/htdocs/compta/facture/card.php
index 6b8fb22de79..e09a57972c4 100644
--- a/htdocs/compta/facture/card.php
+++ b/htdocs/compta/facture/card.php
@@ -1040,6 +1040,7 @@ if (empty($reshook)) {
$object->note_public = trim(GETPOST('note_public', 'restricthtml'));
$object->note_private = trim(GETPOST('note_private', 'restricthtml'));
$object->ref_client = GETPOST('ref_client', 'alphanohtml');
+ $object->ref_customer = GETPOST('ref_client', 'alphanohtml');
$object->model_pdf = GETPOST('model', 'alphanohtml');
$object->fk_project = GETPOST('projectid', 'int');
$object->cond_reglement_id = GETPOST('cond_reglement_id', 'int');
@@ -1092,7 +1093,8 @@ if (empty($reshook)) {
$object->date_pointoftax = $date_pointoftax;
$object->note_public = trim(GETPOST('note_public', 'restricthtml'));
$object->note_private = trim(GETPOST('note_private', 'restricthtml'));
- $object->ref_client = GETPOST('ref_client');
+ $object->ref_client = GETPOST('ref_client', 'alphanohtml');
+ $object->ref_customer = GETPOST('ref_client', 'alphanohtml');
$object->model_pdf = GETPOST('model');
$object->fk_project = GETPOST('projectid', 'int');
$object->cond_reglement_id = 0; // No payment term for a credit note
@@ -1662,6 +1664,10 @@ if (empty($reshook)) {
if ($lines[$i]->subprice < 0 && empty($conf->global->INVOICE_KEEP_DISCOUNT_LINES_AS_IN_ORIGIN)) {
// Negative line, we create a discount line
+ if (empty($desc)) {
+ $desc = $label ? $label : $langs->trans('Discount');
+ }
+
$discount = new DiscountAbsolute($db);
$discount->fk_soc = $object->socid;
$discount->amount_ht = abs($lines[$i]->total_ht);
diff --git a/htdocs/compta/paiement/card.php b/htdocs/compta/paiement/card.php
index 2912650cc1f..262205fd36b 100644
--- a/htdocs/compta/paiement/card.php
+++ b/htdocs/compta/paiement/card.php
@@ -421,7 +421,7 @@ print '';
if (!empty($object->ext_payment_id)) {
// External payment ID
- print '
| '.$langs->trans("StripePaymentId").' | ';
if (isModEnabled('stripe') && in_array($object->ext_payment_site, array('Stripe', 'StripeLive'))) {
$tmp1 = explode('@', $object->ext_payment_id);
if (!empty($tmp1[1])) {
diff --git a/htdocs/compta/prelevement/class/bonprelevement.class.php b/htdocs/compta/prelevement/class/bonprelevement.class.php
index ba2e28e3ac7..cc4b44da05e 100644
--- a/htdocs/compta/prelevement/class/bonprelevement.class.php
+++ b/htdocs/compta/prelevement/class/bonprelevement.class.php
@@ -840,7 +840,7 @@ class BonPrelevement extends CommonObject
* @param string $executiondate Date to execute the transfer
* @param int $notrigger Disable triggers
* @param string $type 'direct-debit' or 'bank-transfer'
- * @param int $did ID of an existing payment request. If $did is defined, no entry
+ * @param int $did ID of an existing payment request. If $did is defined, we use the existing payment request.
* @param int $fk_bank_account Bank account ID the receipt is generated for. Will use the ID into the setup of module Direct Debit or Credit Transfer if 0.
* @return int <0 if KO, No of invoice included into file if OK
*/
diff --git a/htdocs/core/actions_addupdatedelete.inc.php b/htdocs/core/actions_addupdatedelete.inc.php
index 958a87b401e..bd102f3d7bb 100644
--- a/htdocs/core/actions_addupdatedelete.inc.php
+++ b/htdocs/core/actions_addupdatedelete.inc.php
@@ -109,8 +109,6 @@ if ($action == 'add' && !empty($permissiontoadd)) {
if (!empty($values_arr)) {
$value = implode(',', $values_arr);
}
- var_dump($value);
- exit;
} else {
if ($key == 'lang') {
$value = GETPOST($key, 'aZ09') ?GETPOST($key, 'aZ09') : "";
diff --git a/htdocs/core/class/commondocgenerator.class.php b/htdocs/core/class/commondocgenerator.class.php
index d852c1391a1..fb2d329c505 100644
--- a/htdocs/core/class/commondocgenerator.class.php
+++ b/htdocs/core/class/commondocgenerator.class.php
@@ -109,6 +109,9 @@ abstract class CommonDocGenerator
public $option_escompte;
public $option_credit_note;
+ /**
+ * @var Societe Issuer of document
+ */
public $emetteur;
/**
@@ -127,6 +130,12 @@ abstract class CommonDocGenerator
*/
public $result;
+ public $posxref;
+ public $posxpicture; // For picture
+ public $posxdesc; // For description
+ public $posxqty;
+ public $posxpuht;
+
/**
* Constructor
diff --git a/htdocs/core/class/commoninvoice.class.php b/htdocs/core/class/commoninvoice.class.php
index 48358f123e6..c0381d0542f 100644
--- a/htdocs/core/class/commoninvoice.class.php
+++ b/htdocs/core/class/commoninvoice.class.php
@@ -776,7 +776,7 @@ abstract class CommonInvoice extends CommonObject
* @param float $amount Amount we request direct debit or credit transfer for. If 0, the remain to pay will be calculated and used.
* @param string $type 'direct-debit' or 'bank-transfer'
* @param string $sourcetype Source ('facture' or 'supplier_invoice')
- * @return int <0 if KO, >0 if OK
+ * @return int <0 if KO, 0 if a request already exists, >0 if OK
*/
public function demande_prelevement($fuser, $amount = 0, $type = 'direct-debit', $sourcetype = 'facture')
{
@@ -787,7 +787,7 @@ abstract class CommonInvoice extends CommonObject
dol_syslog(get_class($this)."::demande_prelevement", LOG_DEBUG);
- if ($this->statut > self::STATUS_DRAFT && $this->paye == 0) {
+ if ($this->status > self::STATUS_DRAFT && $this->paye == 0) {
require_once DOL_DOCUMENT_ROOT.'/societe/class/companybankaccount.class.php';
$bac = new CompanyBankAccount($this->db);
$bac->fetch(0, $this->socid);
@@ -870,17 +870,17 @@ abstract class CommonInvoice extends CommonObject
return 1;
} else {
$this->error = "A request already exists";
- dol_syslog(get_class($this).'::demandeprelevement Impossible de creer une demande, demande deja en cours');
+ dol_syslog(get_class($this).'::demandeprelevement Can t create a request to generate a direct debit, a request already exists.');
return 0;
}
} else {
$this->error = $this->db->error();
- dol_syslog(get_class($this).'::demandeprelevement Erreur -2');
+ dol_syslog(get_class($this).'::demandeprelevement Error -2');
return -2;
}
} else {
$this->error = "Status of invoice does not allow this";
- dol_syslog(get_class($this)."::demandeprelevement ".$this->error." $this->statut, $this->paye, $this->mode_reglement_id");
+ dol_syslog(get_class($this)."::demandeprelevement ".$this->error." $this->status, $this->paye, $this->mode_reglement_id");
return -3;
}
}
@@ -927,7 +927,7 @@ abstract class CommonInvoice extends CommonObject
dol_syslog(get_class($this)."::makeStripeSepaRequest start", LOG_DEBUG);
- if ($this->statut > self::STATUS_DRAFT && $this->paye == 0) {
+ if ($this->status > self::STATUS_DRAFT && $this->paye == 0) {
// Get the default payment mode for BAN payment of the third party
require_once DOL_DOCUMENT_ROOT.'/societe/class/companybankaccount.class.php';
$bac = new CompanyBankAccount($this->db); // table societe_rib
@@ -939,7 +939,7 @@ abstract class CommonInvoice extends CommonObject
return -1;
}
- // Load the pending payment requests to process
+ // Load the pending payment request to process (with rowid=$did)
$sql = "SELECT rowid, date_demande, amount, fk_facture, fk_facture_fourn, fk_prelevement_bons";
$sql .= " FROM ".$this->db->prefix()."prelevement_demande";
$sql .= " WHERE rowid = ".((int) $did);
@@ -1022,7 +1022,7 @@ abstract class CommonInvoice extends CommonObject
$bon = new BonPrelevement($this->db);
if (!$error) {
if (empty($obj->fk_prelevement_bons)) {
- // This create record into llx_prelevment_bons and update link with llx_prelevement_demande
+ // This creates a record into llx_prelevement_bons and updates link with llx_prelevement_demande
$nbinvoices = $bon->create(0, 0, 'real', 'ALL', '', 0, $type, $did, $fk_bank_account);
if ($nbinvoices <= 0) {
$error++;
diff --git a/htdocs/core/class/commonobject.class.php b/htdocs/core/class/commonobject.class.php
index 9ea509677f1..9d119536ced 100644
--- a/htdocs/core/class/commonobject.class.php
+++ b/htdocs/core/class/commonobject.class.php
@@ -1029,7 +1029,7 @@ abstract class CommonObject
* @param int|string $type_contact Type of contact (code or id). Must be id or code found into table llx_c_type_contact. For example: SALESREPFOLL
* @param string $source external=Contact extern (llx_socpeople), internal=Contact intern (llx_user)
* @param int $notrigger Disable all triggers
- * @return int <0 if KO, 0 if already added, >0 if OK
+ * @return int <0 if KO, 0 if already added or code not valid, >0 if OK
*/
public function add_contact($fk_socpeople, $type_contact, $source = 'external', $notrigger = 0)
{
@@ -1074,9 +1074,8 @@ abstract class CommonObject
}
if ($id_type_contact == 0) {
- $this->error = 'CODE_NOT_VALID_FOR_THIS_ELEMENT';
dol_syslog("CODE_NOT_VALID_FOR_THIS_ELEMENT: Code type of contact '".$type_contact."' does not exists or is not active for element ".$this->element.", we can ignore it");
- return -3;
+ return 0;
}
$datecreate = dol_now();
diff --git a/htdocs/core/class/commonpeople.class.php b/htdocs/core/class/commonpeople.class.php
index 7eecbfc5f9e..8ec59be05c7 100644
--- a/htdocs/core/class/commonpeople.class.php
+++ b/htdocs/core/class/commonpeople.class.php
@@ -49,6 +49,16 @@ trait CommonPeople
public $state_code;
public $state;
+ /**
+ * @var string email
+ */
+ public $email;
+
+ /**
+ * @var string url
+ */
+ public $url;
+
/**
* Return full name (civility+' '+name+' '+lastname)
diff --git a/htdocs/core/class/discount.class.php b/htdocs/core/class/discount.class.php
index c66bd73b96e..dd5c4451b60 100644
--- a/htdocs/core/class/discount.class.php
+++ b/htdocs/core/class/discount.class.php
@@ -254,7 +254,7 @@ class DiscountAbsolute
// Check parameters
if (empty($this->description)) {
- $this->error = 'BadValueForPropertyDescription';
+ $this->error = 'BadValueForPropertyDescriptionOfDiscount';
dol_syslog(get_class($this)."::create ".$this->error, LOG_ERR);
return -1;
}
diff --git a/htdocs/core/class/doleditor.class.php b/htdocs/core/class/doleditor.class.php
index f3531f2cb12..8483aedfa38 100644
--- a/htdocs/core/class/doleditor.class.php
+++ b/htdocs/core/class/doleditor.class.php
@@ -163,7 +163,7 @@ class DolEditor
$pluginstodisable = 'elementspath,save,flash,div,anchor';
if (!getDolGlobalString('FCKEDITOR_ENABLE_SPECIALCHAR')) {
$pluginstodisable .= ',specialchar';
- }
+ }
if (!empty($conf->dol_optimize_smallscreen)) {
$pluginstodisable .= ',scayt,wsc,find,undo';
}
diff --git a/htdocs/core/class/extrafields.class.php b/htdocs/core/class/extrafields.class.php
index 69a6ff82424..a7d19d6b4e2 100644
--- a/htdocs/core/class/extrafields.class.php
+++ b/htdocs/core/class/extrafields.class.php
@@ -2124,6 +2124,7 @@ class ExtraFields
) {
continue;
}
+
$visibility_abs = abs($visibility);
// not modify if extra field is not in update form (0 : never, 2 or -2 : list only, 5 or - 5 : list and view only)
if (empty($visibility_abs) || $visibility_abs == 2 || $visibility_abs == 5) {
diff --git a/htdocs/core/modules/asset/doc/doc_generic_asset_odt.modules.php b/htdocs/core/modules/asset/doc/doc_generic_asset_odt.modules.php
index 15d95bde92e..e5bd7efb971 100644
--- a/htdocs/core/modules/asset/doc/doc_generic_asset_odt.modules.php
+++ b/htdocs/core/modules/asset/doc/doc_generic_asset_odt.modules.php
@@ -40,12 +40,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/doc.lib.php';
*/
class doc_generic_asset_odt extends ModelePDFAsset
{
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
/**
* @var string Dolibarr version of the loaded document
*/
diff --git a/htdocs/core/modules/asset/doc/pdf_standard_asset.modules.php b/htdocs/core/modules/asset/doc/pdf_standard_asset.modules.php
index 56057582d11..525a1a7eccc 100644
--- a/htdocs/core/modules/asset/doc/pdf_standard_asset.modules.php
+++ b/htdocs/core/modules/asset/doc/pdf_standard_asset.modules.php
@@ -74,53 +74,11 @@ class pdf_standard_asset extends ModelePDFAsset
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
-
/**
* @var bool Situation invoice type
*/
public $situationinvoice;
-
/**
* @var array of document table columns
*/
diff --git a/htdocs/core/modules/bank/doc/pdf_ban.modules.php b/htdocs/core/modules/bank/doc/pdf_ban.modules.php
index 37d9913a953..9e200690dc7 100644
--- a/htdocs/core/modules/bank/doc/pdf_ban.modules.php
+++ b/htdocs/core/modules/bank/doc/pdf_ban.modules.php
@@ -35,11 +35,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
class pdf_ban extends ModeleBankAccountDoc
{
- /**
- * @var Societe Issuer
- */
- public $emetteur;
-
/**
* @var string Dolibarr version of the loaded document
*/
diff --git a/htdocs/core/modules/bank/doc/pdf_sepamandate.modules.php b/htdocs/core/modules/bank/doc/pdf_sepamandate.modules.php
index fa83bed0a49..83e66baa3d6 100644
--- a/htdocs/core/modules/bank/doc/pdf_sepamandate.modules.php
+++ b/htdocs/core/modules/bank/doc/pdf_sepamandate.modules.php
@@ -36,12 +36,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
class pdf_sepamandate extends ModeleBankAccountDoc
{
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
/**
* Dolibarr version of the loaded document
* @var string
diff --git a/htdocs/core/modules/bom/doc/doc_generic_bom_odt.modules.php b/htdocs/core/modules/bom/doc/doc_generic_bom_odt.modules.php
index 1fcc55446a8..7ec4266b9d4 100644
--- a/htdocs/core/modules/bom/doc/doc_generic_bom_odt.modules.php
+++ b/htdocs/core/modules/bom/doc/doc_generic_bom_odt.modules.php
@@ -40,12 +40,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/doc.lib.php';
*/
class doc_generic_bom_odt extends ModelePDFBom
{
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
/**
* @var string Dolibarr version of the loaded document
*/
diff --git a/htdocs/core/modules/cheque/doc/pdf_blochet.class.php b/htdocs/core/modules/cheque/doc/pdf_blochet.class.php
index 6d257de6306..864401b3fb4 100644
--- a/htdocs/core/modules/cheque/doc/pdf_blochet.class.php
+++ b/htdocs/core/modules/cheque/doc/pdf_blochet.class.php
@@ -34,12 +34,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/modules/cheque/modules_chequereceipts.php'
*/
class BordereauChequeBlochet extends ModeleChequeReceipts
{
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
/**
* Constructor
*
@@ -47,7 +41,7 @@ class BordereauChequeBlochet extends ModeleChequeReceipts
*/
public function __construct($db)
{
- global $conf, $langs, $mysoc;
+ global $langs, $mysoc;
// Load traductions files required by page
$langs->loadLangs(array("main", "bills"));
diff --git a/htdocs/core/modules/commande/doc/doc_generic_order_odt.modules.php b/htdocs/core/modules/commande/doc/doc_generic_order_odt.modules.php
index e8d7abfe0d7..6a79f31f048 100644
--- a/htdocs/core/modules/commande/doc/doc_generic_order_odt.modules.php
+++ b/htdocs/core/modules/commande/doc/doc_generic_order_odt.modules.php
@@ -40,12 +40,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/doc.lib.php';
*/
class doc_generic_order_odt extends ModelePDFCommandes
{
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
/**
* Dolibarr version of the loaded document
* @var string
diff --git a/htdocs/core/modules/commande/doc/pdf_einstein.modules.php b/htdocs/core/modules/commande/doc/pdf_einstein.modules.php
index 3f1a62c1b2b..adb695487d9 100644
--- a/htdocs/core/modules/commande/doc/pdf_einstein.modules.php
+++ b/htdocs/core/modules/commande/doc/pdf_einstein.modules.php
@@ -78,47 +78,6 @@ class pdf_einstein extends ModelePDFCommandes
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
-
/**
* Constructor
diff --git a/htdocs/core/modules/commande/doc/pdf_eratosthene.modules.php b/htdocs/core/modules/commande/doc/pdf_eratosthene.modules.php
index f6f9cf79bfa..8c2612fa683 100644
--- a/htdocs/core/modules/commande/doc/pdf_eratosthene.modules.php
+++ b/htdocs/core/modules/commande/doc/pdf_eratosthene.modules.php
@@ -78,47 +78,6 @@ class pdf_eratosthene extends ModelePDFCommandes
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
-
/**
* @var array of document table columns
*/
diff --git a/htdocs/core/modules/contract/doc/doc_generic_contract_odt.modules.php b/htdocs/core/modules/contract/doc/doc_generic_contract_odt.modules.php
index 515109c4f20..f81cbeaf33c 100644
--- a/htdocs/core/modules/contract/doc/doc_generic_contract_odt.modules.php
+++ b/htdocs/core/modules/contract/doc/doc_generic_contract_odt.modules.php
@@ -38,12 +38,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/doc.lib.php';
*/
class doc_generic_contract_odt extends ModelePDFContract
{
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
/**
* @var string Dolibarr version of the loaded document
*/
diff --git a/htdocs/core/modules/contract/doc/pdf_strato.modules.php b/htdocs/core/modules/contract/doc/pdf_strato.modules.php
index fe6f77b9b9a..2709278b7b1 100644
--- a/htdocs/core/modules/contract/doc/pdf_strato.modules.php
+++ b/htdocs/core/modules/contract/doc/pdf_strato.modules.php
@@ -76,47 +76,6 @@ class pdf_strato extends ModelePDFContract
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
-
/**
* Recipient
* @var Societe
diff --git a/htdocs/core/modules/delivery/doc/pdf_storm.modules.php b/htdocs/core/modules/delivery/doc/pdf_storm.modules.php
index fc55f6fe0f3..03b40ecfeec 100644
--- a/htdocs/core/modules/delivery/doc/pdf_storm.modules.php
+++ b/htdocs/core/modules/delivery/doc/pdf_storm.modules.php
@@ -70,46 +70,6 @@ class pdf_storm extends ModelePDFDeliveryOrder
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
/**
* Constructor
@@ -118,7 +78,7 @@ class pdf_storm extends ModelePDFDeliveryOrder
*/
public function __construct($db)
{
- global $conf, $langs, $mysoc;
+ global $langs, $mysoc;
// Translations
$langs->loadLangs(array("main", "bills", "sendings", "companies"));
@@ -147,13 +107,6 @@ class pdf_storm extends ModelePDFDeliveryOrder
if (empty($this->emetteur->country_code)) {
$this->emetteur->country_code = substr($langs->defaultlang, -2); // By default, if was not defined
}
-
- $this->tva = array();
- $this->tva_array = array();
- $this->localtax1 = array();
- $this->localtax2 = array();
- $this->atleastoneratenotnull = 0;
- $this->atleastonediscount = 0;
}
diff --git a/htdocs/core/modules/delivery/doc/pdf_typhon.modules.php b/htdocs/core/modules/delivery/doc/pdf_typhon.modules.php
index 31c46438992..0fcf8381438 100644
--- a/htdocs/core/modules/delivery/doc/pdf_typhon.modules.php
+++ b/htdocs/core/modules/delivery/doc/pdf_typhon.modules.php
@@ -69,46 +69,10 @@ class pdf_typhon extends ModelePDFDeliveryOrder
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
+ public $posxcomm; // For customer comment column
+ public $posxweightvol; // For weight or volume
+ public $posxremainingqty;
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
/**
* Constructor
@@ -149,7 +113,7 @@ class pdf_typhon extends ModelePDFDeliveryOrder
// Define position of columns
$this->posxdesc = $this->marge_gauche + 1;
- $this->posxcomm = 112;
+ $this->posxcomm = 112; // customer comment
//$this->posxtva=112;
//$this->posxup=126;
$this->posxqty = 165;
@@ -164,13 +128,6 @@ class pdf_typhon extends ModelePDFDeliveryOrder
//$this->posxdiscount-=20;
//$this->postotalht-=20;
}
-
- $this->tva = array();
- $this->tva_array = array();
- $this->localtax1 = array();
- $this->localtax2 = array();
- $this->atleastoneratenotnull = 0;
- $this->atleastonediscount = 0;
}
diff --git a/htdocs/core/modules/expedition/doc/doc_generic_shipment_odt.modules.php b/htdocs/core/modules/expedition/doc/doc_generic_shipment_odt.modules.php
index 507f35b34dd..f990dabe767 100644
--- a/htdocs/core/modules/expedition/doc/doc_generic_shipment_odt.modules.php
+++ b/htdocs/core/modules/expedition/doc/doc_generic_shipment_odt.modules.php
@@ -40,12 +40,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/doc.lib.php';
*/
class doc_generic_shipment_odt extends ModelePdfExpedition
{
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
/**
* Dolibarr version of the loaded document
* @var string
diff --git a/htdocs/core/modules/expedition/doc/pdf_espadon.modules.php b/htdocs/core/modules/expedition/doc/pdf_espadon.modules.php
index 297013ed8ac..d9ccc47316b 100644
--- a/htdocs/core/modules/expedition/doc/pdf_espadon.modules.php
+++ b/htdocs/core/modules/expedition/doc/pdf_espadon.modules.php
@@ -67,47 +67,6 @@ class pdf_espadon extends ModelePdfExpedition
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe object that emits
- */
- public $emetteur;
-
/**
* Constructor
@@ -116,7 +75,7 @@ class pdf_espadon extends ModelePdfExpedition
*/
public function __construct(DoliDB $db)
{
- global $conf, $langs, $mysoc;
+ global $langs, $mysoc;
$this->db = $db;
$this->name = "espadon";
diff --git a/htdocs/core/modules/expedition/doc/pdf_merou.modules.php b/htdocs/core/modules/expedition/doc/pdf_merou.modules.php
index 1d8e0c3f19e..7dfa66c3bf7 100644
--- a/htdocs/core/modules/expedition/doc/pdf_merou.modules.php
+++ b/htdocs/core/modules/expedition/doc/pdf_merou.modules.php
@@ -68,47 +68,6 @@ class pdf_merou extends ModelePdfExpedition
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
/**
* Constructor
@@ -117,7 +76,7 @@ class pdf_merou extends ModelePdfExpedition
*/
public function __construct(DoliDB $db)
{
- global $conf, $langs, $mysoc;
+ global $langs, $mysoc;
$this->db = $db;
$this->name = "merou";
diff --git a/htdocs/core/modules/expedition/doc/pdf_rouget.modules.php b/htdocs/core/modules/expedition/doc/pdf_rouget.modules.php
index 11635c6511b..a9e2bd31160 100644
--- a/htdocs/core/modules/expedition/doc/pdf_rouget.modules.php
+++ b/htdocs/core/modules/expedition/doc/pdf_rouget.modules.php
@@ -68,46 +68,8 @@ class pdf_rouget extends ModelePdfExpedition
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe object that emits
- */
- public $emetteur;
+ public $posxweightvol;
+ public $posxqtyordered;
/**
diff --git a/htdocs/core/modules/expensereport/doc/pdf_standard.modules.php b/htdocs/core/modules/expensereport/doc/pdf_standard.modules.php
index ec409109d2d..c2d4799f75a 100644
--- a/htdocs/core/modules/expensereport/doc/pdf_standard.modules.php
+++ b/htdocs/core/modules/expensereport/doc/pdf_standard.modules.php
@@ -75,12 +75,6 @@ class pdf_standard extends ModeleExpenseReport
*/
public $version = 'dolibarr';
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
public $posxpiece;
public $posxcomment;
public $posxtva;
diff --git a/htdocs/core/modules/facture/doc/doc_generic_invoice_odt.modules.php b/htdocs/core/modules/facture/doc/doc_generic_invoice_odt.modules.php
index b74934d96a4..9799df502f7 100644
--- a/htdocs/core/modules/facture/doc/doc_generic_invoice_odt.modules.php
+++ b/htdocs/core/modules/facture/doc/doc_generic_invoice_odt.modules.php
@@ -39,12 +39,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/doc.lib.php';
*/
class doc_generic_invoice_odt extends ModelePDFFactures
{
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
-
/**
* Dolibarr version of the loaded document
* @var string
@@ -59,7 +53,7 @@ class doc_generic_invoice_odt extends ModelePDFFactures
*/
public function __construct($db)
{
- global $conf, $langs, $mysoc;
+ global $langs, $mysoc;
// Load translation files required by the page
$langs->loadLangs(array("main", "companies"));
diff --git a/htdocs/core/modules/facture/doc/pdf_crabe.modules.php b/htdocs/core/modules/facture/doc/pdf_crabe.modules.php
index 7941815ee24..3c81977e3c0 100644
--- a/htdocs/core/modules/facture/doc/pdf_crabe.modules.php
+++ b/htdocs/core/modules/facture/doc/pdf_crabe.modules.php
@@ -75,47 +75,6 @@ class pdf_crabe extends ModelePDFFactures
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
-
/**
* @var bool Situation invoice type
*/
diff --git a/htdocs/core/modules/facture/doc/pdf_sponge.modules.php b/htdocs/core/modules/facture/doc/pdf_sponge.modules.php
index 56cf21e16e8..7a29fe64176 100644
--- a/htdocs/core/modules/facture/doc/pdf_sponge.modules.php
+++ b/htdocs/core/modules/facture/doc/pdf_sponge.modules.php
@@ -76,42 +76,6 @@ class pdf_sponge extends ModelePDFFactures
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
-
/**
* @var int heightforinfotot
*/
@@ -137,12 +101,6 @@ class pdf_sponge extends ModelePDFFactures
*/
public $tab_top_newpage;
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
-
/**
* @var bool Situation invoice type
*/
diff --git a/htdocs/core/modules/fichinter/doc/pdf_soleil.modules.php b/htdocs/core/modules/fichinter/doc/pdf_soleil.modules.php
index d42f85cb3cf..f6b0ed7ea9b 100644
--- a/htdocs/core/modules/fichinter/doc/pdf_soleil.modules.php
+++ b/htdocs/core/modules/fichinter/doc/pdf_soleil.modules.php
@@ -70,46 +70,6 @@ class pdf_soleil extends ModelePDFFicheinter
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
/**
* Constructor
@@ -118,7 +78,7 @@ class pdf_soleil extends ModelePDFFicheinter
*/
public function __construct($db)
{
- global $conf, $langs, $mysoc;
+ global $langs, $mysoc;
$this->db = $db;
$this->name = 'soleil';
diff --git a/htdocs/core/modules/member/doc/doc_generic_member_odt.class.php b/htdocs/core/modules/member/doc/doc_generic_member_odt.class.php
index a62723219b0..5a06a25f529 100644
--- a/htdocs/core/modules/member/doc/doc_generic_member_odt.class.php
+++ b/htdocs/core/modules/member/doc/doc_generic_member_odt.class.php
@@ -36,11 +36,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/doc.lib.php';
*/
class doc_generic_member_odt extends ModelePDFMember
{
- /**
- * @var Societe Issuer
- */
- public $emetteur;
-
/**
* Dolibarr version of the loaded document
* @var string
diff --git a/htdocs/core/modules/movement/doc/pdf_standard.modules.php b/htdocs/core/modules/movement/doc/pdf_standard.modules.php
index d15ae20170b..d8daea8ff51 100644
--- a/htdocs/core/modules/movement/doc/pdf_standard.modules.php
+++ b/htdocs/core/modules/movement/doc/pdf_standard.modules.php
@@ -42,11 +42,6 @@ class pdf_standard extends ModelePDFMovement
*/
public $db;
- /**
- * @var string model name
- */
- public $name;
-
/**
* @var string model description (short text)
*/
@@ -68,13 +63,6 @@ class pdf_standard extends ModelePDFMovement
*/
public $version = 'dolibarr';
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
-
-
public $wref;
public $posxidref;
public $posxdatemouv;
diff --git a/htdocs/core/modules/mrp/doc/doc_generic_mo_odt.modules.php b/htdocs/core/modules/mrp/doc/doc_generic_mo_odt.modules.php
index fe18e6eb6ea..1bb999da071 100644
--- a/htdocs/core/modules/mrp/doc/doc_generic_mo_odt.modules.php
+++ b/htdocs/core/modules/mrp/doc/doc_generic_mo_odt.modules.php
@@ -40,12 +40,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/doc.lib.php';
*/
class doc_generic_mo_odt extends ModelePDFMo
{
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
/**
* @var string Dolibarr version of the loaded document
*/
diff --git a/htdocs/core/modules/mrp/doc/pdf_vinci.modules.php b/htdocs/core/modules/mrp/doc/pdf_vinci.modules.php
index 62e5f062514..f777ed3b6a2 100644
--- a/htdocs/core/modules/mrp/doc/pdf_vinci.modules.php
+++ b/htdocs/core/modules/mrp/doc/pdf_vinci.modules.php
@@ -73,47 +73,6 @@ class pdf_vinci extends ModelePDFMo
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe object that emits
- */
- public $emetteur;
-
/**
* Constructor
@@ -122,7 +81,7 @@ class pdf_vinci extends ModelePDFMo
*/
public function __construct($db)
{
- global $conf, $langs, $mysoc;
+ global $langs, $mysoc;
// Load translation files required by the page
$langs->loadLangs(array("main", "bills"));
diff --git a/htdocs/core/modules/product/doc/doc_generic_product_odt.modules.php b/htdocs/core/modules/product/doc/doc_generic_product_odt.modules.php
index 2728bf266c2..cb2d773b928 100644
--- a/htdocs/core/modules/product/doc/doc_generic_product_odt.modules.php
+++ b/htdocs/core/modules/product/doc/doc_generic_product_odt.modules.php
@@ -37,12 +37,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/doc.lib.php';
*/
class doc_generic_product_odt extends ModelePDFProduct
{
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
/**
* Dolibarr version of the loaded document
* @var string
diff --git a/htdocs/core/modules/product/doc/pdf_standard.modules.php b/htdocs/core/modules/product/doc/pdf_standard.modules.php
index 3cd29891550..6bfd01c2f1b 100644
--- a/htdocs/core/modules/product/doc/pdf_standard.modules.php
+++ b/htdocs/core/modules/product/doc/pdf_standard.modules.php
@@ -63,12 +63,6 @@ class pdf_standard extends ModelePDFProduct
*/
public $version = 'dolibarr';
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
/**
* Constructor
@@ -77,7 +71,7 @@ class pdf_standard extends ModelePDFProduct
*/
public function __construct($db)
{
- global $conf, $langs, $mysoc;
+ global $langs, $mysoc;
// Load traductions files required by page
$langs->loadLangs(array("main", "companies"));
diff --git a/htdocs/core/modules/project/doc/doc_generic_project_odt.modules.php b/htdocs/core/modules/project/doc/doc_generic_project_odt.modules.php
index e8c1357e7a2..6b0c45d4754 100644
--- a/htdocs/core/modules/project/doc/doc_generic_project_odt.modules.php
+++ b/htdocs/core/modules/project/doc/doc_generic_project_odt.modules.php
@@ -77,12 +77,6 @@ if (isModEnabled('expedition')) {
*/
class doc_generic_project_odt extends ModelePDFProjects
{
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
/**
* Dolibarr version of the loaded document
* @var string
diff --git a/htdocs/core/modules/project/doc/pdf_baleine.modules.php b/htdocs/core/modules/project/doc/pdf_baleine.modules.php
index 0a048837d7a..117ad829408 100644
--- a/htdocs/core/modules/project/doc/pdf_baleine.modules.php
+++ b/htdocs/core/modules/project/doc/pdf_baleine.modules.php
@@ -69,46 +69,6 @@ class pdf_baleine extends ModelePDFProjects
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
/**
* Constructor
@@ -117,7 +77,7 @@ class pdf_baleine extends ModelePDFProjects
*/
public function __construct($db)
{
- global $conf, $langs, $mysoc;
+ global $langs, $mysoc;
// Translations
$langs->loadLangs(array("main", "projects", "companies"));
diff --git a/htdocs/core/modules/project/doc/pdf_beluga.modules.php b/htdocs/core/modules/project/doc/pdf_beluga.modules.php
index 1823f68b835..0afff52ee73 100644
--- a/htdocs/core/modules/project/doc/pdf_beluga.modules.php
+++ b/htdocs/core/modules/project/doc/pdf_beluga.modules.php
@@ -59,11 +59,6 @@ class pdf_beluga extends ModelePDFProjects
*/
public $db;
- /**
- * @var string model name
- */
- public $name;
-
/**
* @var string model description (short text)
*/
@@ -85,53 +80,12 @@ class pdf_beluga extends ModelePDFProjects
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
/**
* Page orientation
* @var string 'P' or 'Portait' (default), 'L' or 'Landscape'
*/
private $orientation;
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
public $posxref;
public $posxdate;
public $posxsociete;
diff --git a/htdocs/core/modules/project/doc/pdf_timespent.modules.php b/htdocs/core/modules/project/doc/pdf_timespent.modules.php
index c00ae37ab22..60e03823f22 100644
--- a/htdocs/core/modules/project/doc/pdf_timespent.modules.php
+++ b/htdocs/core/modules/project/doc/pdf_timespent.modules.php
@@ -68,46 +68,6 @@ class pdf_timespent extends ModelePDFProjects
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
/**
* Constructor
@@ -116,7 +76,7 @@ class pdf_timespent extends ModelePDFProjects
*/
public function __construct($db)
{
- global $conf, $langs, $mysoc;
+ global $langs, $mysoc;
// Translations
$langs->loadLangs(array("main", "projects", "companies"));
diff --git a/htdocs/core/modules/project/task/doc/doc_generic_task_odt.modules.php b/htdocs/core/modules/project/task/doc/doc_generic_task_odt.modules.php
index 51e53e21d3f..788780298eb 100644
--- a/htdocs/core/modules/project/task/doc/doc_generic_task_odt.modules.php
+++ b/htdocs/core/modules/project/task/doc/doc_generic_task_odt.modules.php
@@ -76,12 +76,6 @@ if (isModEnabled('agenda')) {
*/
class doc_generic_task_odt extends ModelePDFTask
{
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
-
/**
* Dolibarr version of the loaded document
* @var string
diff --git a/htdocs/core/modules/propale/doc/doc_generic_proposal_odt.modules.php b/htdocs/core/modules/propale/doc/doc_generic_proposal_odt.modules.php
index f1b35a35e57..47b157c8d57 100644
--- a/htdocs/core/modules/propale/doc/doc_generic_proposal_odt.modules.php
+++ b/htdocs/core/modules/propale/doc/doc_generic_proposal_odt.modules.php
@@ -39,11 +39,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/signature.lib.php';
*/
class doc_generic_proposal_odt extends ModelePDFPropales
{
- /**
- * @var Societe Issuer object that emits
- */
- public $emetteur;
-
/**
* @var string Dolibarr version of the loaded document
*/
@@ -57,7 +52,7 @@ class doc_generic_proposal_odt extends ModelePDFPropales
*/
public function __construct($db)
{
- global $conf, $langs, $mysoc;
+ global $langs, $mysoc;
// Load translation files required by the page
$langs->loadLangs(array("main", "companies"));
diff --git a/htdocs/core/modules/propale/doc/pdf_azur.modules.php b/htdocs/core/modules/propale/doc/pdf_azur.modules.php
index 85576e467ec..27caa33087f 100644
--- a/htdocs/core/modules/propale/doc/pdf_azur.modules.php
+++ b/htdocs/core/modules/propale/doc/pdf_azur.modules.php
@@ -79,47 +79,6 @@ class pdf_azur extends ModelePDFPropales
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
-
/**
* Constructor
diff --git a/htdocs/core/modules/propale/doc/pdf_cyan.modules.php b/htdocs/core/modules/propale/doc/pdf_cyan.modules.php
index 7bb166c59b7..0d1bb192820 100644
--- a/htdocs/core/modules/propale/doc/pdf_cyan.modules.php
+++ b/htdocs/core/modules/propale/doc/pdf_cyan.modules.php
@@ -72,47 +72,6 @@ class pdf_cyan extends ModelePDFPropales
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
-
/**
* @var array of document table columns
*/
@@ -126,7 +85,7 @@ class pdf_cyan extends ModelePDFPropales
*/
public function __construct($db)
{
- global $conf, $langs, $mysoc;
+ global $langs, $mysoc;
// Translations
$langs->loadLangs(array("main", "bills"));
diff --git a/htdocs/core/modules/reception/doc/doc_generic_reception_odt.modules.php b/htdocs/core/modules/reception/doc/doc_generic_reception_odt.modules.php
index d254f676e3c..d1362459649 100644
--- a/htdocs/core/modules/reception/doc/doc_generic_reception_odt.modules.php
+++ b/htdocs/core/modules/reception/doc/doc_generic_reception_odt.modules.php
@@ -36,11 +36,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/doc.lib.php';
*/
class doc_generic_reception_odt extends ModelePdfReception
{
- /**
- * @var Societe Issuer object that emits
- */
- public $emetteur; // Objet societe qui emet
-
/**
* @var string Dolibarr version of the loaded document
*/
diff --git a/htdocs/core/modules/reception/doc/pdf_squille.modules.php b/htdocs/core/modules/reception/doc/pdf_squille.modules.php
index 8c1f571aa0c..1c1e4c76010 100644
--- a/htdocs/core/modules/reception/doc/pdf_squille.modules.php
+++ b/htdocs/core/modules/reception/doc/pdf_squille.modules.php
@@ -33,10 +33,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/pdf.lib.php';
class pdf_squille extends ModelePdfReception
{
/**
- * Issuer
- * @var Societe object that emits
+ * @var string Dolibarr version of the loaded document
*/
- public $emetteur;
+ public $version = 'dolibarr';
/**
diff --git a/htdocs/core/modules/societe/doc/doc_generic_odt.modules.php b/htdocs/core/modules/societe/doc/doc_generic_odt.modules.php
index 261aeef9ad5..98f8f9a63b4 100644
--- a/htdocs/core/modules/societe/doc/doc_generic_odt.modules.php
+++ b/htdocs/core/modules/societe/doc/doc_generic_odt.modules.php
@@ -37,10 +37,10 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/doc.lib.php';
class doc_generic_odt extends ModeleThirdPartyDoc
{
/**
- * Issuer
- * @var Societe
+ * @var string Dolibarr version of the loaded document
*/
- public $emetteur;
+ public $version = 'dolibarr';
+
/**
* Constructor
diff --git a/htdocs/core/modules/stock/doc/doc_generic_stock_odt.modules.php b/htdocs/core/modules/stock/doc/doc_generic_stock_odt.modules.php
index 5aae143fc2b..5b692e38253 100644
--- a/htdocs/core/modules/stock/doc/doc_generic_stock_odt.modules.php
+++ b/htdocs/core/modules/stock/doc/doc_generic_stock_odt.modules.php
@@ -37,17 +37,12 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/doc.lib.php';
*/
class doc_generic_stock_odt extends ModelePDFStock
{
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
/**
* @var string Dolibarr version of the loaded document
*/
public $version = 'dolibarr';
+
/**
* Constructor
*
diff --git a/htdocs/core/modules/stock/doc/pdf_standard.modules.php b/htdocs/core/modules/stock/doc/pdf_standard.modules.php
index 23e8deb4aee..e951abb3622 100644
--- a/htdocs/core/modules/stock/doc/pdf_standard.modules.php
+++ b/htdocs/core/modules/stock/doc/pdf_standard.modules.php
@@ -64,12 +64,6 @@ class pdf_standard extends ModelePDFStock
*/
public $version = 'dolibarr';
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
public $wref;
public $posxdesc;
public $posxlabel;
diff --git a/htdocs/core/modules/stocktransfer/doc/pdf_eagle.modules.php b/htdocs/core/modules/stocktransfer/doc/pdf_eagle.modules.php
index 14ee86bccf0..ff1b43bcd49 100644
--- a/htdocs/core/modules/stocktransfer/doc/pdf_eagle.modules.php
+++ b/htdocs/core/modules/stocktransfer/doc/pdf_eagle.modules.php
@@ -65,47 +65,6 @@ class pdf_eagle extends ModelePDFStockTransfer
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe object that emits
- */
- public $emetteur;
-
/**
* Constructor
diff --git a/htdocs/core/modules/stocktransfer/doc/pdf_eagle_proforma.modules.php b/htdocs/core/modules/stocktransfer/doc/pdf_eagle_proforma.modules.php
index 83f0cb802e9..101ee0f43f6 100644
--- a/htdocs/core/modules/stocktransfer/doc/pdf_eagle_proforma.modules.php
+++ b/htdocs/core/modules/stocktransfer/doc/pdf_eagle_proforma.modules.php
@@ -74,47 +74,6 @@ class pdf_eagle_proforma extends ModelePDFCommandes
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe Object that emits
- */
- public $emetteur;
-
/**
* Constructor
@@ -123,7 +82,7 @@ class pdf_eagle_proforma extends ModelePDFCommandes
*/
public function __construct($db)
{
- global $conf, $langs, $mysoc;
+ global $langs, $mysoc;
// Translations
$langs->loadLangs(array("main", "bills", "products"));
diff --git a/htdocs/core/modules/supplier_invoice/doc/pdf_canelle.modules.php b/htdocs/core/modules/supplier_invoice/doc/pdf_canelle.modules.php
index 3dfb6bfd4d2..dcb4deff292 100644
--- a/htdocs/core/modules/supplier_invoice/doc/pdf_canelle.modules.php
+++ b/htdocs/core/modules/supplier_invoice/doc/pdf_canelle.modules.php
@@ -69,48 +69,6 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe object that emits
- */
- public $emetteur;
-
-
/**
* Constructor
diff --git a/htdocs/core/modules/supplier_order/doc/pdf_cornas.modules.php b/htdocs/core/modules/supplier_order/doc/pdf_cornas.modules.php
index f651951fb98..fa215824f55 100644
--- a/htdocs/core/modules/supplier_order/doc/pdf_cornas.modules.php
+++ b/htdocs/core/modules/supplier_order/doc/pdf_cornas.modules.php
@@ -72,47 +72,6 @@ class pdf_cornas extends ModelePDFSuppliersOrders
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe object that emits
- */
- public $emetteur;
-
/**
* Constructor
diff --git a/htdocs/core/modules/supplier_order/doc/pdf_muscadet.modules.php b/htdocs/core/modules/supplier_order/doc/pdf_muscadet.modules.php
index 1b90c123e99..c62a26cb9dc 100644
--- a/htdocs/core/modules/supplier_order/doc/pdf_muscadet.modules.php
+++ b/htdocs/core/modules/supplier_order/doc/pdf_muscadet.modules.php
@@ -72,47 +72,6 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe object that emits
- */
- public $emetteur;
-
/**
* Constructor
diff --git a/htdocs/core/modules/supplier_payment/doc/pdf_standard.modules.php b/htdocs/core/modules/supplier_payment/doc/pdf_standard.modules.php
index 8646ecac0c9..fc7d142d5ae 100644
--- a/htdocs/core/modules/supplier_payment/doc/pdf_standard.modules.php
+++ b/htdocs/core/modules/supplier_payment/doc/pdf_standard.modules.php
@@ -70,12 +70,6 @@ class pdf_standard extends ModelePDFSuppliersPayments
*/
public $version = 'dolibarr';
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
public $posxdate;
public $posxreffacturefourn;
public $posxreffacture;
diff --git a/htdocs/core/modules/supplier_proposal/doc/doc_generic_supplier_proposal_odt.modules.php b/htdocs/core/modules/supplier_proposal/doc/doc_generic_supplier_proposal_odt.modules.php
index e6a7b6fe700..53bacc7aad2 100644
--- a/htdocs/core/modules/supplier_proposal/doc/doc_generic_supplier_proposal_odt.modules.php
+++ b/htdocs/core/modules/supplier_proposal/doc/doc_generic_supplier_proposal_odt.modules.php
@@ -38,12 +38,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/doc.lib.php';
*/
class doc_generic_supplier_proposal_odt extends ModelePDFSupplierProposal
{
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
/**
* Dolibarr version of the loaded document
* @var string
diff --git a/htdocs/core/modules/supplier_proposal/doc/pdf_aurore.modules.php b/htdocs/core/modules/supplier_proposal/doc/pdf_aurore.modules.php
index 84c13dc0ee6..b2739678701 100644
--- a/htdocs/core/modules/supplier_proposal/doc/pdf_aurore.modules.php
+++ b/htdocs/core/modules/supplier_proposal/doc/pdf_aurore.modules.php
@@ -69,47 +69,6 @@ class pdf_aurore extends ModelePDFSupplierProposal
*/
public $version = 'dolibarr';
- /**
- * @var int page_largeur
- */
- public $page_largeur;
-
- /**
- * @var int page_hauteur
- */
- public $page_hauteur;
-
- /**
- * @var array format
- */
- public $format;
-
- /**
- * @var int marge_gauche
- */
- public $marge_gauche;
-
- /**
- * @var int marge_droite
- */
- public $marge_droite;
-
- /**
- * @var int marge_haute
- */
- public $marge_haute;
-
- /**
- * @var int marge_basse
- */
- public $marge_basse;
-
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
/**
* Constructor
diff --git a/htdocs/core/modules/ticket/doc/doc_generic_ticket_odt.modules.php b/htdocs/core/modules/ticket/doc/doc_generic_ticket_odt.modules.php
index 7a629568b4d..2ddd40a255d 100644
--- a/htdocs/core/modules/ticket/doc/doc_generic_ticket_odt.modules.php
+++ b/htdocs/core/modules/ticket/doc/doc_generic_ticket_odt.modules.php
@@ -36,11 +36,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/doc.lib.php';
*/
class doc_generic_ticket_odt extends ModelePDFTicket
{
- /**
- * @var Societe Issuer
- */
- public $emetteur;
-
/**
* Dolibarr version of the loaded document
* @var string
@@ -55,7 +50,7 @@ class doc_generic_ticket_odt extends ModelePDFTicket
*/
public function __construct($db)
{
- global $conf, $langs, $mysoc;
+ global $langs, $mysoc;
// Load translation files required by the page
$langs->loadLangs(array("main", "companies"));
diff --git a/htdocs/core/modules/user/doc/doc_generic_user_odt.modules.php b/htdocs/core/modules/user/doc/doc_generic_user_odt.modules.php
index d6e52e2f21e..fb28cd18b4b 100644
--- a/htdocs/core/modules/user/doc/doc_generic_user_odt.modules.php
+++ b/htdocs/core/modules/user/doc/doc_generic_user_odt.modules.php
@@ -36,11 +36,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/doc.lib.php';
*/
class doc_generic_user_odt extends ModelePDFUser
{
- /**
- * @var Societe Issuer
- */
- public $emetteur;
-
/**
* Dolibarr version of the loaded document
* @var string
@@ -55,7 +50,7 @@ class doc_generic_user_odt extends ModelePDFUser
*/
public function __construct($db)
{
- global $conf, $langs, $mysoc;
+ global $langs, $mysoc;
// Load translation files required by the page
$langs->loadLangs(array("main", "companies"));
diff --git a/htdocs/core/modules/usergroup/doc/doc_generic_usergroup_odt.modules.php b/htdocs/core/modules/usergroup/doc/doc_generic_usergroup_odt.modules.php
index 74ad5902966..535b744f626 100644
--- a/htdocs/core/modules/usergroup/doc/doc_generic_usergroup_odt.modules.php
+++ b/htdocs/core/modules/usergroup/doc/doc_generic_usergroup_odt.modules.php
@@ -38,12 +38,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/doc.lib.php';
*/
class doc_generic_usergroup_odt extends ModelePDFUserGroup
{
- /**
- * Issuer
- * @var Societe
- */
- public $emetteur;
-
/**
* Dolibarr version of the loaded document
* @var string
@@ -58,7 +52,7 @@ class doc_generic_usergroup_odt extends ModelePDFUserGroup
*/
public function __construct($db)
{
- global $conf, $langs, $mysoc;
+ global $langs, $mysoc;
// Load translation files required by the page
$langs->loadLangs(array("main", "companies"));
diff --git a/htdocs/datapolicy/class/datapolicy.class.php b/htdocs/datapolicy/class/datapolicy.class.php
index 0a8928ad1bf..92580fbb785 100644
--- a/htdocs/datapolicy/class/datapolicy.class.php
+++ b/htdocs/datapolicy/class/datapolicy.class.php
@@ -222,11 +222,13 @@ class DataPolicy
require_once DOL_DOCUMENT_ROOT.'/core/class/CMailFile.class.php';
$mailfile = new CMailFile($subject, $sendto, $from, $message, $filepath, $mimetype, $filename, $sendtocc, $sendtobcc, $deliveryreceipt, -1);
+ $resultmasssend = '';
if ($mailfile->error) {
$resultmasssend .= ' '.$mailfile->error.' ';
} else {
- $result4 = $mailfile->sendfile();
- if (!$error) {
+ $resultmail = $mailfile->sendfile();
+
+ if ($resultmail) {
$resultmasssend .= $langs->trans("MailSent").': '.$sendto." ";
$contact->array_options['options_datapolicy_send'] = date('Y-m-d', time());
$contact->update($contact->id);
@@ -294,12 +296,14 @@ class DataPolicy
// Send mail
require_once DOL_DOCUMENT_ROOT.'/core/class/CMailFile.class.php';
$mailfile = new CMailFile($subject, $sendto, $from, $message, $filepath, $mimetype, $filename, $sendtocc, $sendtobcc, $deliveryreceipt, -1);
+
+ $resultmasssend = '';
if ($mailfile->error) {
$resultmasssend .= ''.$mailfile->error.' ';
} else {
- $result4 = $mailfile->sendfile();
+ $resultmail = $mailfile->sendfile();
- if (!$error) {
+ if ($resultmail) {
$resultmasssend .= $langs->trans("MailSent").': '.$sendto." ";
$societe->array_options['options_datapolicy_send'] = date('Y-m-d', time());
$societe->update($societe->id);
@@ -371,9 +375,9 @@ class DataPolicy
if ($mailfile->error) {
$resultmasssend .= ''.$mailfile->error.' ';
} else {
- $result4 = $mailfile->sendfile();
+ $resultmail = $mailfile->sendfile();
- if (!$error) {
+ if ($resultmail) {
$resultmasssend .= $langs->trans("MailSent").': '.$sendto." ";
$adherent->array_options['options_datapolicy_send'] = date('Y-m-d', time());
$adherent->update($user);
diff --git a/htdocs/langs/en_US/stripe.lang b/htdocs/langs/en_US/stripe.lang
index f5b5d3fca91..9b4ddcc04df 100644
--- a/htdocs/langs/en_US/stripe.lang
+++ b/htdocs/langs/en_US/stripe.lang
@@ -51,6 +51,7 @@ StripeAccount=Stripe account
StripeChargeList=List of Stripe charges
StripeTransactionList=List of Stripe transactions
StripeCustomerId=Stripe customer id
+StripePaymentId=Stripe payment id
StripePaymentModes=Stripe payment modes
LocalID=Local ID
StripeID=Stripe ID
diff --git a/htdocs/stripe/charge.php b/htdocs/stripe/charge.php
index 11594c2bff4..3a9493b3c02 100644
--- a/htdocs/stripe/charge.php
+++ b/htdocs/stripe/charge.php
@@ -115,7 +115,7 @@ if (!$rowid) {
print ''."\n";
print '';
- print_liste_field_titre("Ref", $_SERVER["PHP_SELF"], "", "", "", "", $sortfield, $sortorder);
+ print_liste_field_titre("StripePaymentId", $_SERVER["PHP_SELF"], "", "", "", "", $sortfield, $sortorder);
print_liste_field_titre("StripeCustomerId", $_SERVER["PHP_SELF"], "", "", "", "", $sortfield, $sortorder);
print_liste_field_titre("Customer", $_SERVER["PHP_SELF"], "", "", "", "", $sortfield, $sortorder);
print_liste_field_titre("Origin", $_SERVER["PHP_SELF"], "", "", "", "", $sortfield, $sortorder);
diff --git a/htdocs/stripe/class/stripe.class.php b/htdocs/stripe/class/stripe.class.php
index 5a486f6f655..34ad99b18b9 100644
--- a/htdocs/stripe/class/stripe.class.php
+++ b/htdocs/stripe/class/stripe.class.php
@@ -1064,8 +1064,10 @@ class Stripe extends CommonObject
// Save the Stripe payment mode ID into the Dolibarr database
$sql = "UPDATE ".MAIN_DB_PREFIX."societe_rib";
- $sql .= " SET stripe_card_ref = '".$this->db->escape($sepa->id)."', card_type = 'sepa_debit',";
- $sql .= " stripe_account= '" . $this->db->escape($cu->id . "@" . $stripeacc) . "'";
+ $sql .= " SET stripe_card_ref = '".$this->db->escape($sepa->id)."',";
+ $sql .= " card_type = 'sepa_debit',";
+ $sql .= " stripe_account= '" . $this->db->escape($cu->id . "@" . $stripeacc) . "',";
+ $sql .= " ext_payment_site = '".$this->db->escape($service)."'";
$sql .= " WHERE rowid = ".((int) $object->id);
$sql .= " AND type = 'ban'";
$resql = $this->db->query($sql);
diff --git a/htdocs/stripe/payout.php b/htdocs/stripe/payout.php
index 36c798c8571..b1d1d9e6201 100644
--- a/htdocs/stripe/payout.php
+++ b/htdocs/stripe/payout.php
@@ -107,9 +107,6 @@ if (!$rowid) {
print ' ';
print_liste_field_titre("Ref", $_SERVER["PHP_SELF"], "", "", "", "", $sortfield, $sortorder);
- //print_liste_field_titre("StripeCustomerId",$_SERVER["PHP_SELF"],"","","","",$sortfield,$sortorder);
- //print_liste_field_titre("CustomerId", $_SERVER["PHP_SELF"], "", "", "", "", $sortfield, $sortorder);
- //print_liste_field_titre("Origin", $_SERVER["PHP_SELF"], "", "", "", "", $sortfield, $sortorder);
print_liste_field_titre("DatePayment", $_SERVER["PHP_SELF"], "", "", "", '', $sortfield, $sortorder, 'center ');
print_liste_field_titre("DateOperation", $_SERVER["PHP_SELF"], "", "", "", '', $sortfield, $sortorder, 'center ');
print_liste_field_titre("Description", $_SERVER["PHP_SELF"], "", "", "", '', $sortfield, $sortorder, 'left ');
diff --git a/htdocs/stripe/transaction.php b/htdocs/stripe/transaction.php
index 390c989d207..6fe06ce71c8 100644
--- a/htdocs/stripe/transaction.php
+++ b/htdocs/stripe/transaction.php
@@ -107,9 +107,6 @@ if (!$rowid) {
print ' ';
print_liste_field_titre("Ref", $_SERVER["PHP_SELF"], "", "", "", "", $sortfield, $sortorder);
- //print_liste_field_titre("StripeCustomerId",$_SERVER["PHP_SELF"],"","","","",$sortfield,$sortorder);
- //print_liste_field_titre("CustomerId", $_SERVER["PHP_SELF"], "", "", "", "", $sortfield, $sortorder);
- //print_liste_field_titre("Origin", $_SERVER["PHP_SELF"], "", "", "", "", $sortfield, $sortorder);
print_liste_field_titre("DatePayment", $_SERVER["PHP_SELF"], "", "", "", '', $sortfield, $sortorder, 'center ');
print_liste_field_titre("Type", $_SERVER["PHP_SELF"], "", "", "", '', $sortfield, $sortorder, 'left ');
print_liste_field_titre("Paid", $_SERVER["PHP_SELF"], "", "", "", '', $sortfield, $sortorder, 'right ');
|