Merge branch '6.0' of git@github.com:Dolibarr/dolibarr.git into 7.0
This commit is contained in:
commit
b0ef8680ff
@ -85,6 +85,9 @@ class Commande extends CommonOrder
|
|||||||
public $facturee;
|
public $facturee;
|
||||||
public $billed; // billed or not
|
public $billed; // billed or not
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @var int Draft Status of the order
|
||||||
|
*/
|
||||||
public $brouillon;
|
public $brouillon;
|
||||||
public $cond_reglement_code;
|
public $cond_reglement_code;
|
||||||
|
|
||||||
@ -233,7 +236,7 @@ class Commande extends CommonOrder
|
|||||||
$mybool|=@include_once $dir.$file;
|
$mybool|=@include_once $dir.$file;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (! $mybool)
|
if ($mybool === false)
|
||||||
{
|
{
|
||||||
dol_print_error('',"Failed to include file ".$file);
|
dol_print_error('',"Failed to include file ".$file);
|
||||||
return '';
|
return '';
|
||||||
@ -407,6 +410,7 @@ class Commande extends CommonOrder
|
|||||||
{
|
{
|
||||||
$this->ref = $num;
|
$this->ref = $num;
|
||||||
$this->statut = self::STATUS_VALIDATED;
|
$this->statut = self::STATUS_VALIDATED;
|
||||||
|
$this->brouillon = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (! $error)
|
if (! $error)
|
||||||
|
|||||||
@ -756,43 +756,6 @@ class pdf_typhon extends ModelePDFDeliveryOrder
|
|||||||
|
|
||||||
$posy+=2;
|
$posy+=2;
|
||||||
|
|
||||||
// Add list of linked orders on shipment
|
|
||||||
// Currently not supported by pdf_writeLinkedObjects, link for delivery to order is done through shipment)
|
|
||||||
if ($object->origin == 'expedition' || $object->origin == 'shipping')
|
|
||||||
{
|
|
||||||
$Yoff=$posy-5;
|
|
||||||
|
|
||||||
include_once DOL_DOCUMENT_ROOT.'/expedition/class/expedition.class.php';
|
|
||||||
$shipment = new Expedition($this->db);
|
|
||||||
$shipment->fetch($object->origin_id);
|
|
||||||
|
|
||||||
$origin = $shipment->origin;
|
|
||||||
$origin_id = $shipment->origin_id;
|
|
||||||
|
|
||||||
if ($conf->$origin->enabled)
|
|
||||||
{
|
|
||||||
$outputlangs->load('orders');
|
|
||||||
|
|
||||||
$classname = ucfirst($origin);
|
|
||||||
$linkedobject = new $classname($this->db);
|
|
||||||
$result=$linkedobject->fetch($origin_id);
|
|
||||||
if ($result >= 0)
|
|
||||||
{
|
|
||||||
$pdf->SetFont('','', $default_font_size - 2);
|
|
||||||
$text=$linkedobject->ref;
|
|
||||||
if ($linkedobject->ref_client) $text.=' ('.$linkedobject->ref_client.')';
|
|
||||||
$Yoff = $Yoff+8;
|
|
||||||
$pdf->SetXY($this->page_largeur - $this->marge_droite - 100,$Yoff);
|
|
||||||
$pdf->MultiCell(100, 2, $outputlangs->transnoentities("RefOrder") ." : ".$outputlangs->transnoentities($text), 0, 'R');
|
|
||||||
$Yoff = $Yoff+3;
|
|
||||||
$pdf->SetXY($this->page_largeur - $this->marge_droite - 60,$Yoff);
|
|
||||||
$pdf->MultiCell(60, 2, $outputlangs->transnoentities("OrderDate")." : ".dol_print_date($linkedobject->date,"day",false,$outputlangs,true), 0, 'R');
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
$posy=$Yoff;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Show list of linked objects
|
// Show list of linked objects
|
||||||
$posy = pdf_writeLinkedObjects($pdf, $object, $outputlangs, $posx, $posy, 100, 3, 'R', $default_font_size);
|
$posy = pdf_writeLinkedObjects($pdf, $object, $outputlangs, $posx, $posy, 100, 3, 'R', $default_font_size);
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user