本文整理汇总了PHP中CommandeFournisseur::fetch_projet方法的典型用法代码示例。如果您正苦于以下问题:PHP CommandeFournisseur::fetch_projet方法的具体用法?PHP CommandeFournisseur::fetch_projet怎么用?PHP CommandeFournisseur::fetch_projet使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CommandeFournisseur
的用法示例。
在下文中一共展示了CommandeFournisseur::fetch_projet方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: pdfBuildThirdpartyName
/**
* Show top header of page.
*
* @param PDF $pdf Object PDF
* @param CommandeFournisseur $object Object to show
* @param int $showaddress 0=no, 1=yes
* @param Translate $outputlangs Object lang for output
* @return void
*/
function _pagehead(&$pdf, $object, $showaddress, $outputlangs)
{
global $langs, $conf, $mysoc;
$outputlangs->load("main");
$outputlangs->load("bills");
$outputlangs->load("orders");
$outputlangs->load("companies");
$outputlangs->load("sendings");
$default_font_size = pdf_getPDFFontSize($outputlangs);
// Do not add the BACKGROUND as this is for suppliers
//pdf_pagehead($pdf,$outputlangs,$this->page_hauteur);
//Affiche le filigrane brouillon - Print Draft Watermark
/*if($object->statut==0 && (! empty($conf->global->COMMANDE_DRAFT_WATERMARK)) )
{
pdf_watermark($pdf,$outputlangs,$this->page_hauteur,$this->page_largeur,'mm',$conf->global->COMMANDE_DRAFT_WATERMARK);
}*/
//Print content
$pdf->SetTextColor(0, 0, 60);
$pdf->SetFont('', 'B', $default_font_size + 3);
$posx = $this->page_largeur - $this->marge_droite - 100;
$posy = $this->marge_haute;
$pdf->SetXY($this->marge_gauche, $posy);
// Logo
$logo = $conf->mycompany->dir_output . '/logos/' . $this->emetteur->logo;
if ($this->emetteur->logo) {
if (is_readable($logo)) {
$height = pdf_getHeightForLogo($logo);
$pdf->Image($logo, $this->marge_gauche, $posy, 0, $height);
// width=0 (auto)
} else {
$pdf->SetTextColor(200, 0, 0);
$pdf->SetFont('', 'B', $default_font_size - 2);
$pdf->MultiCell(100, 3, $outputlangs->transnoentities("ErrorLogoFileNotFound", $logo), 0, 'L');
$pdf->MultiCell(100, 3, $outputlangs->transnoentities("ErrorGoToModuleSetup"), 0, 'L');
}
} else {
$text = $this->emetteur->name;
$pdf->MultiCell(100, 4, $outputlangs->convToOutputCharset($text), 0, 'L');
}
$pdf->SetFont('', 'B', $default_font_size + 3);
$pdf->SetXY($posx, $posy);
$pdf->SetTextColor(0, 0, 60);
$title = $outputlangs->transnoentities("SupplierOrder") . " " . $outputlangs->convToOutputCharset($object->ref);
$pdf->MultiCell(100, 3, $title, '', 'R');
$posy += 1;
if ($object->ref_supplier) {
$posy += 4;
$pdf->SetFont('', 'B', $default_font_size);
$pdf->SetXY($posx, $posy);
$pdf->SetTextColor(0, 0, 60);
$pdf->MultiCell(100, 3, $outputlangs->transnoentities("RefSupplier") . " : " . $outputlangs->convToOutputCharset($object->ref_supplier), '', 'R');
$posy += 1;
}
$pdf->SetFont('', '', $default_font_size - 1);
if (!empty($conf->global->PDF_SHOW_PROJECT)) {
$object->fetch_projet();
if (!empty($object->project->ref)) {
$posy += 4;
$pdf->SetXY($posx, $posy);
$langs->load("projects");
$pdf->SetTextColor(0, 0, 60);
$pdf->MultiCell(100, 3, $outputlangs->transnoentities("Project") . " : " . (empty($object->project->ref) ? '' : $object->projet->ref), '', 'R');
}
}
if (!empty($object->date_commande)) {
$posy += 4;
$pdf->SetXY($posx, $posy);
$pdf->SetTextColor(0, 0, 60);
$pdf->MultiCell(100, 3, $outputlangs->transnoentities("OrderDate") . " : " . dol_print_date($object->date_commande, "day", false, $outputlangs, true), '', 'R');
} else {
$posy += 4;
$pdf->SetXY($posx, $posy);
$pdf->SetTextColor(255, 0, 0);
$pdf->MultiCell(100, 3, $outputlangs->transnoentities("OrderToProcess"), '', 'R');
}
$pdf->SetTextColor(0, 0, 60);
$usehourmin = 'day';
if (empty($conf->global->SUPPLIER_ORDER_USE_HOUR_FOR_DELIVERY_DATE)) {
$usehourmin = 'dayhour';
}
if (!empty($object->date_livraison)) {
$posy += 4;
$pdf->SetXY($posx - 90, $posy);
$pdf->MultiCell(190, 3, $outputlangs->transnoentities("DateDeliveryPlanned") . " : " . dol_print_date($object->date_livraison, $usehourmin, false, $outputlangs, true), '', 'R');
}
if ($object->thirdparty->code_fournisseur) {
$posy += 4;
$pdf->SetXY($posx, $posy);
$pdf->SetTextColor(0, 0, 60);
$pdf->MultiCell(100, 3, $outputlangs->transnoentities("SupplierCode") . " : " . $outputlangs->transnoentities($object->thirdparty->code_fournisseur), '', 'R');
}
//.........这里部分代码省略.........