Skip to content

Commit

Permalink
Debug for shipment
Browse files Browse the repository at this point in the history
  • Loading branch information
eldy committed Dec 20, 2024
1 parent b9e8cbc commit 3cefab3
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions htdocs/core/lib/invoice2.lib.php
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,17 @@ function rebuild_merge_pdf($db, $langs, $conf, $diroutputpdf, $newlangid, $filte
if ($diroutputpdf == 'auto') {
$diroutputpdf = $conf->propal->dir_output.'/temp';
}
} elseif ($mode == 'shipment') {
require_once DOL_DOCUMENT_ROOT."/expedition/class/expedition.class.php";
require_once DOL_DOCUMENT_ROOT."/core/modules/expedition/modules_expedition.php";

$table = "propal";
$dir_output = $conf->shipment->dir_output;
$date = "date";

if ($diroutputpdf == 'auto') {
$diroutputpdf = $conf->shipment->dir_output.'/temp';
}
} else {
print "Bad value for mode";
return -1;
Expand Down Expand Up @@ -226,6 +237,8 @@ function rebuild_merge_pdf($db, $langs, $conf, $diroutputpdf, $newlangid, $filte
$fac = new Commande($db);
} elseif ($mode == 'proposal') {
$fac = new Propal($db);
} elseif ($mode == 'shipment') {
$fac = new Expedition($db);
}

$result = $fac->fetch($obj->rowid);

Check warning on line 244 in htdocs/core/lib/invoice2.lib.php

View workflow job for this annotation

GitHub Actions / phan / Run phan

invoice2.lib.php: PhanPossiblyUndeclaredVariable: Variable $fac is possibly undeclared
Expand Down

0 comments on commit 3cefab3

Please sign in to comment.