Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dolibarr
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container Registry
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Software_Artifact_Infrastructure_Repository
dolibarr
Commits
9244ef23
Commit
9244ef23
authored
10 years ago
by
Marcos García de La Fuente
Browse files
Options
Downloads
Patches
Plain Diff
Removed 2nd argument of muscadet and canelle model __construct function
parent
8e1f9c8d
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
htdocs/core/modules/supplier_invoice/pdf/pdf_canelle.modules.php
+7
-8
7 additions, 8 deletions
...core/modules/supplier_invoice/pdf/pdf_canelle.modules.php
htdocs/core/modules/supplier_order/pdf/pdf_muscadet.modules.php
+1
-2
1 addition, 2 deletions
.../core/modules/supplier_order/pdf/pdf_muscadet.modules.php
with
8 additions
and
10 deletions
htdocs/core/modules/supplier_invoice/pdf/pdf_canelle.modules.php
+
7
−
8
View file @
9244ef23
...
...
@@ -58,9 +58,8 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
* Constructor
*
* @param DoliDB $db Database handler
* @param Object $object Supplier invoice
*/
function
__construct
(
$db
,
$object
)
function
__construct
(
$db
)
{
global
$conf
,
$langs
,
$mysoc
;
...
...
@@ -91,12 +90,6 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
$this
->
franchise
=!
$mysoc
->
tva_assuj
;
// Get source company
if
(
!
is_object
(
$object
->
thirdparty
))
$object
->
fetch_thirdparty
();
if
(
!
is_object
(
$object
->
thirdparty
))
$object
->
thirdparty
=
$mysoc
;
// If fetch_thirdparty fails, object has no socid (specimen)
$this
->
emetteur
=
$object
->
thirdparty
;
if
(
!
$this
->
emetteur
->
country_code
)
$this
->
emetteur
->
country_code
=
substr
(
$langs
->
defaultlang
,
-
2
);
// By default, if was not defined
// Defini position des colonnes
$this
->
posxdesc
=
$this
->
marge_gauche
+
1
;
$this
->
posxtva
=
112
;
...
...
@@ -139,6 +132,12 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
{
global
$user
,
$langs
,
$conf
,
$mysoc
,
$hookmanager
;
// Get source company
if
(
!
is_object
(
$object
->
thirdparty
))
$object
->
fetch_thirdparty
();
if
(
!
is_object
(
$object
->
thirdparty
))
$object
->
thirdparty
=
$mysoc
;
// If fetch_thirdparty fails, object has no socid (specimen)
$this
->
emetteur
=
$object
->
thirdparty
;
if
(
!
$this
->
emetteur
->
country_code
)
$this
->
emetteur
->
country_code
=
substr
(
$langs
->
defaultlang
,
-
2
);
// By default, if was not defined
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
if
(
!
empty
(
$conf
->
global
->
MAIN_USE_FPDF
))
$outputlangs
->
charset_output
=
'ISO-8859-1'
;
...
...
This diff is collapsed.
Click to expand it.
htdocs/core/modules/supplier_order/pdf/pdf_muscadet.modules.php
+
1
−
2
View file @
9244ef23
...
...
@@ -61,9 +61,8 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
* Constructor
*
* @param DoliDB $db Database handler
* @param Object $object Supplier order
*/
function
__construct
(
$db
,
$object
)
function
__construct
(
$db
)
{
global
$conf
,
$langs
,
$mysoc
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment