www/rec_print.php

changeset 338
a51b858aacca
parent 289
4082c41f45e9
child 392
544d7d0183b2
equal deleted inserted replaced
337:faedcfa0610f 338:a51b858aacca
379 global $colorw; 379 global $colorw;
380 global $cost_fermentables; 380 global $cost_fermentables;
381 global $cost_hops; 381 global $cost_hops;
382 global $cost_miscs; 382 global $cost_miscs;
383 global $cost_yeasts; 383 global $cost_yeasts;
384 $colormethod = array( 'Morey', 'Mosher', 'Daniels' );
385 $ibumethod = array( 'Tinseth', 'Rager', 'Daniels' );
384 /* 2 Columns */ 386 /* 2 Columns */
385 $vul = $this->w - $this->rMargin - $this->lMargin - 170; 387 $vul = $this->w - $this->rMargin - $this->lMargin - 170;
386 $cMargin=$this->cMargin; 388 $cMargin=$this->cMargin;
387 $this->cMargin=2; 389 $this->cMargin=2;
388 $this->TableX=$this->lMargin; 390 $this->TableX=$this->lMargin;
418 $this->Cell(25,5,'('.sprintf("%.1f",$row['st_carb_min']).' - '.sprintf("%.1f",$row['st_carb_max']).'%)',0,0,'L',true); 420 $this->Cell(25,5,'('.sprintf("%.1f",$row['st_carb_min']).' - '.sprintf("%.1f",$row['st_carb_max']).'%)',0,0,'L',true);
419 $this->Ln(); 421 $this->Ln();
420 422
421 $row['est_color'] = kw_to_ebc($row['color_method'], $colorw); 423 $row['est_color'] = kw_to_ebc($row['color_method'], $colorw);
422 $this->SetX($this->TableX); 424 $this->SetX($this->TableX);
423 $this->Cell(35,5,'Kleur ('.$row['color_method'].')',0,0,'L',true); 425 $this->Cell(35,5,'Kleur ('.$colormethod[$row['color_method']].')',0,0,'L',true);
424 $beercolor = ebc_to_color($row['est_color']); 426 $beercolor = ebc_to_color($row['est_color']);
425 if ($row['est_color'] > 30) 427 if ($row['est_color'] > 30)
426 $this->SetTextColor(250); 428 $this->SetTextColor(250);
427 $this->SetFillColor($beercolor[0],$beercolor[1],$beercolor[2]); 429 $this->SetFillColor($beercolor[0],$beercolor[1],$beercolor[2]);
428 $this->Cell(25,5,$row['est_color'].' EBC',0,0,'L',true); 430 $this->Cell(25,5,$row['est_color'].' EBC',0,0,'L',true);
429 $this->Cell(25,5,'('.$row['st_color_min'].' - '.$row['st_color_max'].' EBC)',0,0,'L',true); 431 $this->Cell(25,5,'('.$row['st_color_min'].' - '.$row['st_color_max'].' EBC)',0,0,'L',true);
430 $this->SetTextColor(0); 432 $this->SetTextColor(0);
431 $this->SetFillColor(210,245,255); 433 $this->SetFillColor(210,245,255);
432 $this->Cell($vul,5,'',0,0,'L',false); 434 $this->Cell($vul,5,'',0,0,'L',false);
433 $this->Cell(35,5,'Bitterheid ('.$row['ibu_method'].')',0,0,'L',true); 435 $this->Cell(35,5,'Bitterheid ('.$ibumethod[$row['ibu_method']].')',0,0,'L',true);
434 $this->Cell(25,5,sprintf("%.0f",$row['est_ibu']).' IBU',0,0,'L',true); 436 $this->Cell(25,5,sprintf("%.0f",$row['est_ibu']).' IBU',0,0,'L',true);
435 $this->Cell(25,5,'('.$row['st_ibu_min'].' - '.$row['st_ibu_max'].' IBU)',0,0,'L',true); 437 $this->Cell(25,5,'('.$row['st_ibu_min'].' - '.$row['st_ibu_max'].' IBU)',0,0,'L',true);
436 $this->Ln(); 438 $this->Ln();
437 439
438 $this->SetX($this->TableX); 440 $this->SetX($this->TableX);

mercurial