mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-12-06 01:28:19 +01:00
Merge pull request #8390 from grandoc/new_branch_14_03_2018
New [*use loadLangs for translation files*]
This commit is contained in:
@@ -97,10 +97,9 @@ class pdf_einstein extends ModelePDFCommandes
|
|||||||
public function __construct($db)
|
public function __construct($db)
|
||||||
{
|
{
|
||||||
global $conf,$langs,$mysoc;
|
global $conf,$langs,$mysoc;
|
||||||
|
|
||||||
$langs->load("main");
|
// Translations
|
||||||
$langs->load("bills");
|
$langs->loadLangs(array("main", "bills", "products"));
|
||||||
$langs->load("products");
|
|
||||||
|
|
||||||
$this->db = $db;
|
$this->db = $db;
|
||||||
$this->name = "einstein";
|
$this->name = "einstein";
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
|
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
|
||||||
* Copyright (C) 2008 Raphael Bertrand (Resultic) <raphael.bertrand@resultic.fr>
|
* Copyright (C) 2008 Raphael Bertrand (Resultic) <raphael.bertrand@resultic.fr>
|
||||||
* Copyright (C) 2011 Fabrice CHERRIER
|
* Copyright (C) 2011 Fabrice CHERRIER
|
||||||
* Copyright (C) 2013 Philippe Grand <philippe.grand@atoo-net.com>
|
* Copyright (C) 2013-2018 Philippe Grand <philippe.grand@atoo-net.com>
|
||||||
* Copyright (C) 2015 Marcos García <marcosgdf@gmail.com>
|
* Copyright (C) 2015 Marcos García <marcosgdf@gmail.com>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
@@ -126,11 +126,9 @@ class pdf_strato extends ModelePDFContract
|
|||||||
if (! is_object($outputlangs)) $outputlangs=$langs;
|
if (! is_object($outputlangs)) $outputlangs=$langs;
|
||||||
// For backward compatibility with FPDF, force output charset to ISO, because FPDF expect text to be encoded in ISO
|
// For backward compatibility with FPDF, force output charset to ISO, because FPDF expect text to be encoded in ISO
|
||||||
if (! empty($conf->global->MAIN_USE_FPDF)) $outputlangs->charset_output='ISO-8859-1';
|
if (! empty($conf->global->MAIN_USE_FPDF)) $outputlangs->charset_output='ISO-8859-1';
|
||||||
|
|
||||||
$outputlangs->load("main");
|
// Translations
|
||||||
$outputlangs->load("dict");
|
$outputlangs->loadLangs(array("main", "dict", "companies", "contracts"));
|
||||||
$outputlangs->load("companies");
|
|
||||||
$outputlangs->load("contracts");
|
|
||||||
|
|
||||||
if ($conf->contrat->dir_output)
|
if ($conf->contrat->dir_output)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -91,16 +91,9 @@ class pdf_merou extends ModelePdfExpedition
|
|||||||
if (! is_object($outputlangs)) $outputlangs=$langs;
|
if (! is_object($outputlangs)) $outputlangs=$langs;
|
||||||
// For backward compatibility with FPDF, force output charset to ISO, because FPDF expect text to be encoded in ISO
|
// For backward compatibility with FPDF, force output charset to ISO, because FPDF expect text to be encoded in ISO
|
||||||
if (! empty($conf->global->MAIN_USE_FPDF)) $outputlangs->charset_output='ISO-8859-1';
|
if (! empty($conf->global->MAIN_USE_FPDF)) $outputlangs->charset_output='ISO-8859-1';
|
||||||
|
|
||||||
$outputlangs->load("main");
|
// Translations
|
||||||
$outputlangs->load("dict");
|
$outputlangs->loadLangs(array("main", "bills", "products", "dict", "companies", "propal", "deliveries", "sendings", "productbatch"));
|
||||||
$outputlangs->load("companies");
|
|
||||||
$outputlangs->load("bills");
|
|
||||||
$outputlangs->load("products");
|
|
||||||
$outputlangs->load("propal");
|
|
||||||
$outputlangs->load("deliveries");
|
|
||||||
$outputlangs->load("sendings");
|
|
||||||
$outputlangs->load("productbatch");
|
|
||||||
|
|
||||||
if ($conf->expedition->dir_output)
|
if ($conf->expedition->dir_output)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -122,16 +122,9 @@ class pdf_rouget extends ModelePdfExpedition
|
|||||||
if (! is_object($outputlangs)) $outputlangs=$langs;
|
if (! is_object($outputlangs)) $outputlangs=$langs;
|
||||||
// For backward compatibility with FPDF, force output charset to ISO, because FPDF expect text to be encoded in ISO
|
// For backward compatibility with FPDF, force output charset to ISO, because FPDF expect text to be encoded in ISO
|
||||||
if (! empty($conf->global->MAIN_USE_FPDF)) $outputlangs->charset_output='ISO-8859-1';
|
if (! empty($conf->global->MAIN_USE_FPDF)) $outputlangs->charset_output='ISO-8859-1';
|
||||||
|
|
||||||
$outputlangs->load("main");
|
// Translations
|
||||||
$outputlangs->load("dict");
|
$outputlangs->loadLangs(array("main", "bills", "products", "dict", "companies", "propal", "deliveries", "sendings", "productbatch"));
|
||||||
$outputlangs->load("companies");
|
|
||||||
$outputlangs->load("bills");
|
|
||||||
$outputlangs->load("products");
|
|
||||||
$outputlangs->load("propal");
|
|
||||||
$outputlangs->load("deliveries");
|
|
||||||
$outputlangs->load("sendings");
|
|
||||||
$outputlangs->load("productbatch");
|
|
||||||
|
|
||||||
$nblignes = count($object->lines);
|
$nblignes = count($object->lines);
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2015 Laurent Destailleur <eldy@users.sourceforge.net>
|
/* Copyright (C) 2015 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
* Copyright (C) 2015 Alexandre Spangaro <aspangaro.dolibarr@gmail.com>
|
* Copyright (C) 2015 Alexandre Spangaro <aspangaro.dolibarr@gmail.com>
|
||||||
* Copyright (C) 2016 Philippe Grand <philippe.grand@atoo-net.com>
|
* Copyright (C) 2016-2018 Philippe Grand <philippe.grand@atoo-net.com>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
@@ -154,11 +154,9 @@ class pdf_standard extends ModeleExpenseReport
|
|||||||
if (! is_object($outputlangs)) $outputlangs=$langs;
|
if (! is_object($outputlangs)) $outputlangs=$langs;
|
||||||
// For backward compatibility with FPDF, force output charset to ISO, because FPDF expect text to be encoded in ISO
|
// For backward compatibility with FPDF, force output charset to ISO, because FPDF expect text to be encoded in ISO
|
||||||
if (! empty($conf->global->MAIN_USE_FPDF)) $outputlangs->charset_output='ISO-8859-1';
|
if (! empty($conf->global->MAIN_USE_FPDF)) $outputlangs->charset_output='ISO-8859-1';
|
||||||
|
|
||||||
$outputlangs->load("main");
|
// Translations
|
||||||
$outputlangs->load("dict");
|
$outputlangs->loadLangs(array("main", "trips", "projects", "dict"));
|
||||||
$outputlangs->load("trips");
|
|
||||||
$outputlangs->load("projects");
|
|
||||||
|
|
||||||
$nblignes = count($object->lines);
|
$nblignes = count($object->lines);
|
||||||
|
|
||||||
|
|||||||
@@ -176,12 +176,9 @@ class pdf_crabe extends ModelePDFFactures
|
|||||||
if (! is_object($outputlangs)) $outputlangs=$langs;
|
if (! is_object($outputlangs)) $outputlangs=$langs;
|
||||||
// For backward compatibility with FPDF, force output charset to ISO, because FPDF expect text to be encoded in ISO
|
// For backward compatibility with FPDF, force output charset to ISO, because FPDF expect text to be encoded in ISO
|
||||||
if (! empty($conf->global->MAIN_USE_FPDF)) $outputlangs->charset_output='ISO-8859-1';
|
if (! empty($conf->global->MAIN_USE_FPDF)) $outputlangs->charset_output='ISO-8859-1';
|
||||||
|
|
||||||
$outputlangs->load("main");
|
// Translations
|
||||||
$outputlangs->load("dict");
|
$outputlangs->loadLangs(array("main", "bills", "products", "dict", "companies"));
|
||||||
$outputlangs->load("companies");
|
|
||||||
$outputlangs->load("bills");
|
|
||||||
$outputlangs->load("products");
|
|
||||||
|
|
||||||
$nblignes = count($object->lines);
|
$nblignes = count($object->lines);
|
||||||
|
|
||||||
|
|||||||
@@ -112,11 +112,9 @@ class pdf_soleil extends ModelePDFFicheinter
|
|||||||
if (! is_object($outputlangs)) $outputlangs=$langs;
|
if (! is_object($outputlangs)) $outputlangs=$langs;
|
||||||
// For backward compatibility with FPDF, force output charset to ISO, because FPDF expect text to be encoded in ISO
|
// For backward compatibility with FPDF, force output charset to ISO, because FPDF expect text to be encoded in ISO
|
||||||
if (! empty($conf->global->MAIN_USE_FPDF)) $outputlangs->charset_output='ISO-8859-1';
|
if (! empty($conf->global->MAIN_USE_FPDF)) $outputlangs->charset_output='ISO-8859-1';
|
||||||
|
|
||||||
$outputlangs->load("main");
|
// Translations
|
||||||
$outputlangs->load("dict");
|
$outputlangs->loadLangs(array("main", "interventions", "dict", "companies"));
|
||||||
$outputlangs->load("companies");
|
|
||||||
$outputlangs->load("interventions");
|
|
||||||
|
|
||||||
if ($conf->ficheinter->dir_output)
|
if ($conf->ficheinter->dir_output)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
* Copyright (C) 2005-2014 Regis Houssin <regis.houssin@capnetworks.com>
|
* Copyright (C) 2005-2014 Regis Houssin <regis.houssin@capnetworks.com>
|
||||||
* Copyright (C) 2007 Franky Van Liedekerke <franky.van.liedekerke@telenet.be>
|
* Copyright (C) 2007 Franky Van Liedekerke <franky.van.liedekerke@telenet.be>
|
||||||
* Copyright (C) 2008 Chiptronik
|
* Copyright (C) 2008 Chiptronik
|
||||||
* Copyright (C) 2011-2012 Philippe Grand <philippe.grand@atoo-net.com>
|
* Copyright (C) 2011-2018 Philippe Grand <philippe.grand@atoo-net.com>
|
||||||
* Copyright (C) 2015 Marcos García <marcosgdf@gmail.com>
|
* Copyright (C) 2015 Marcos García <marcosgdf@gmail.com>
|
||||||
|
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
@@ -65,11 +65,9 @@ class pdf_typhon extends ModelePDFDeliveryOrder
|
|||||||
function __construct($db)
|
function __construct($db)
|
||||||
{
|
{
|
||||||
global $conf,$langs,$mysoc;
|
global $conf,$langs,$mysoc;
|
||||||
|
|
||||||
$langs->load("main");
|
// Translations
|
||||||
$langs->load("bills");
|
$langs->loadLangs(array("main", "bills", "sendings", "companies"));
|
||||||
$langs->load("sendings");
|
|
||||||
$langs->load("companies");
|
|
||||||
|
|
||||||
$this->db = $db;
|
$this->db = $db;
|
||||||
$this->name = "typhon";
|
$this->name = "typhon";
|
||||||
|
|||||||
@@ -48,10 +48,9 @@ class pdf_baleine extends ModelePDFProjects
|
|||||||
function __construct($db)
|
function __construct($db)
|
||||||
{
|
{
|
||||||
global $conf,$langs,$mysoc;
|
global $conf,$langs,$mysoc;
|
||||||
|
|
||||||
$langs->load("main");
|
// Translations
|
||||||
$langs->load("projects");
|
$langs->loadLangs(array("main", "projects", "companies"));
|
||||||
$langs->load("companies");
|
|
||||||
|
|
||||||
$this->db = $db;
|
$this->db = $db;
|
||||||
$this->name = "baleine";
|
$this->name = "baleine";
|
||||||
|
|||||||
@@ -64,10 +64,9 @@ class pdf_beluga extends ModelePDFProjects
|
|||||||
function __construct($db)
|
function __construct($db)
|
||||||
{
|
{
|
||||||
global $conf,$langs,$mysoc;
|
global $conf,$langs,$mysoc;
|
||||||
|
|
||||||
$langs->load("main");
|
// Translations
|
||||||
$langs->load("projects");
|
$langs->loadLangs(array("main", "projects", "companies"));
|
||||||
$langs->load("companies");
|
|
||||||
|
|
||||||
$this->db = $db;
|
$this->db = $db;
|
||||||
$this->name = "beluga";
|
$this->name = "beluga";
|
||||||
|
|||||||
@@ -47,10 +47,9 @@ class pdf_timespent extends ModelePDFProjects
|
|||||||
function __construct($db)
|
function __construct($db)
|
||||||
{
|
{
|
||||||
global $conf,$langs,$mysoc;
|
global $conf,$langs,$mysoc;
|
||||||
|
|
||||||
$langs->load("main");
|
// Translations
|
||||||
$langs->load("projects");
|
$langs->loadLangs(array("main", "projects", "companies"));
|
||||||
$langs->load("companies");
|
|
||||||
|
|
||||||
$this->db = $db;
|
$this->db = $db;
|
||||||
$this->name = "timespent";
|
$this->name = "timespent";
|
||||||
|
|||||||
@@ -68,9 +68,9 @@ class pdf_azur extends ModelePDFPropales
|
|||||||
function __construct($db)
|
function __construct($db)
|
||||||
{
|
{
|
||||||
global $conf,$langs,$mysoc;
|
global $conf,$langs,$mysoc;
|
||||||
|
|
||||||
$langs->load("main");
|
// Translations
|
||||||
$langs->load("bills");
|
$langs->loadLangs(array("main", "bills"));
|
||||||
|
|
||||||
$this->db = $db;
|
$this->db = $db;
|
||||||
$this->name = "azur";
|
$this->name = "azur";
|
||||||
|
|||||||
@@ -63,9 +63,9 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
|
|||||||
function __construct($db)
|
function __construct($db)
|
||||||
{
|
{
|
||||||
global $conf,$langs,$mysoc;
|
global $conf,$langs,$mysoc;
|
||||||
|
|
||||||
$langs->load("main");
|
// Translations
|
||||||
$langs->load("bills");
|
$langs->loadLangs(array("main", "bills"));
|
||||||
|
|
||||||
$this->db = $db;
|
$this->db = $db;
|
||||||
$this->name = "canelle";
|
$this->name = "canelle";
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
* Copyright (C) 2005-2011 Regis Houssin <regis.houssin@capnetworks.com>
|
* Copyright (C) 2005-2011 Regis Houssin <regis.houssin@capnetworks.com>
|
||||||
* Copyright (C) 2007 Franky Van Liedekerke <franky.van.liedekerke@telenet.be>
|
* Copyright (C) 2007 Franky Van Liedekerke <franky.van.liedekerke@telenet.be>
|
||||||
* Copyright (C) 2010-2014 Juanjo Menent <jmenent@2byte.es>
|
* Copyright (C) 2010-2014 Juanjo Menent <jmenent@2byte.es>
|
||||||
* Copyright (C) 2015 Marcos García <marcosgdf@gmail.com>
|
* Copyright (C) 2015 Marcos García <marcosgdf@gmail.com>
|
||||||
* Copyright (C) 2017 Ferran Marcet <fmarcet@2byte.es>
|
* Copyright (C) 2017 Ferran Marcet <fmarcet@2byte.es>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
@@ -68,8 +68,8 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
|
|||||||
{
|
{
|
||||||
global $conf,$langs,$mysoc;
|
global $conf,$langs,$mysoc;
|
||||||
|
|
||||||
$langs->load("main");
|
// Translations
|
||||||
$langs->load("bills");
|
$langs->loadLangs(array("main", "bills"));
|
||||||
|
|
||||||
$this->db = $db;
|
$this->db = $db;
|
||||||
$this->name = "muscadet";
|
$this->name = "muscadet";
|
||||||
|
|||||||
@@ -65,9 +65,9 @@ class pdf_standard extends ModelePDFSuppliersPayments
|
|||||||
function __construct($db)
|
function __construct($db)
|
||||||
{
|
{
|
||||||
global $conf,$langs,$mysoc;
|
global $conf,$langs,$mysoc;
|
||||||
|
|
||||||
$langs->load("main");
|
// Translations
|
||||||
$langs->load("bills");
|
$langs->loadLangs(array("main", "bills"));
|
||||||
|
|
||||||
$this->db = $db;
|
$this->db = $db;
|
||||||
$this->name = "standard";
|
$this->name = "standard";
|
||||||
|
|||||||
@@ -65,9 +65,9 @@ class pdf_aurore extends ModelePDFSupplierProposal
|
|||||||
function __construct($db)
|
function __construct($db)
|
||||||
{
|
{
|
||||||
global $conf,$langs,$mysoc;
|
global $conf,$langs,$mysoc;
|
||||||
|
|
||||||
$langs->load("main");
|
// Translations
|
||||||
$langs->load("bills");
|
$langs->loadLangs(array("main", "bills"));
|
||||||
|
|
||||||
$this->db = $db;
|
$this->db = $db;
|
||||||
$this->name = "aurore";
|
$this->name = "aurore";
|
||||||
|
|||||||
Reference in New Issue
Block a user