www/rec_print.php

changeset 514
3c680d1dea35
parent 449
a1d6b9eec988
child 516
28670364bd0c
--- a/www/rec_print.php	Mon Oct 14 23:13:40 2019 +0200
+++ b/www/rec_print.php	Wed Oct 16 21:05:03 2019 +0200
@@ -1,6 +1,7 @@
 <?php
 require_once($_SERVER['DOCUMENT_ROOT'].'/includes/global.inc.php');
 require_once($_SERVER['DOCUMENT_ROOT'].'/includes/formulas.php');
+require_once($_SERVER['DOCUMENT_ROOT'].'/includes/constants.php');
 require_once($_SERVER['DOCUMENT_ROOT'].'/fpdf/fpdf.php');
 
 
@@ -60,7 +61,7 @@
 
 	function TableGlobal($row) {
 		/* 2 Columns */
-		$recipetype = array( 'Extract', 'Deelmaisch', 'Mout' );
+		global $recipetype;
 		$vul = $this->w - $this->rMargin - $this->lMargin - 120;
 		$cMargin=$this->cMargin;
 		$this->cMargin=2;
@@ -100,9 +101,9 @@
 		global $pCara;
 		global $colorw;
 		global $preboil_sg;
-		$added = array( 'Maischen', 'Koken 10 min', 'Vergisten', 'Nagisten/lageren', 'Bottelen' );
-		$ftype = array( 'Mout', 'Suiker', 'Vloeibaar extract', 'Droog extract', 'Ongemout graan' );
-		$mtype = array( 'Basismout', 'Geroosterde mout', 'Cara- of crystalmout', 'Geƫeste mout', 'Zuurmout', 'Speciale mout', 'Geen mout' );
+		global $added;
+		global $fermentabletype;
+		global $graintype;
 		$vul = $this->w - $this->rMargin - $this->lMargin - 125;
 		$this->Ln();
 		$this->AddCol($vul,'Mout, granen en suikers','L');
@@ -140,9 +141,9 @@
 				$pCara += $percent;
 
 			if ($item['f_type'] == 0)
-				$soort = iconv('UTF-8','windows-1252',$mtype[$item['f_graintype']]);
+				$soort = iconv('UTF-8','windows-1252',$graintype[$item['f_graintype']]);
 			else
-				$soort = iconv('UTF-8','windows-1252',$ftype[$item['f_type']]);
+				$soort = iconv('UTF-8','windows-1252',$fermentabletype[$item['f_type']]);
 
 			$cost = $amount * $costkg;
 			$cost_fermentables += $cost;
@@ -188,8 +189,8 @@
 		global $total_ibus;
 		global $cost_hops;
 		global $preboil_sg;
-		$hopform = array( 'Pellets', 'Plugs', 'Bellen', 'Hop nat', 'Cryo Hop' );
-		$hopuse  = array( 'Maischen', 'First wort', 'Koken', 'Vlamuit', 'Whirlpool', 'Koudhop' );
+		global $hopform;
+		global $hopuse;
 		$vul = $this->w - $this->rMargin - $this->lMargin - 122;
 		$this->Ln();
 		$this->AddCol($vul,'Hop','L');
@@ -259,8 +260,8 @@
 	function TableYeasts($row) {
 		global $cost_yeasts;
 		global $svg;
-		$yeastform = array( 'Vloeibaar', 'Droog', 'Schuine buis', 'Slurry', 'Ingevroren', 'Depot' );
-		$yeastuse  = array( 'Hoofdgisting', 'Nagisting', 'Lagering', 'Bottelen' );
+		global $yeastform;
+		global $yeastuse;
 		$vul = $this->w - $this->rMargin - $this->lMargin - 110;
 		$this->Ln();
 		$this->AddCol($vul,'Gist','L');
@@ -317,8 +318,8 @@
 
 	function TableMiscs($row) {
 		global $cost_miscs;
-		$misctype = array( 'Specerij', 'Kruid', 'Smaakstof', 'Klaringsmiddel', 'Brouwzout', 'Gistvoeding', 'Anders' );
-		$miscuse  = array( 'Starter', 'Maischen', 'Koken', 'Hoofdvergisting', 'Nagisting/lagering', 'Bottelen' );
+		global $misctype;
+		global $miscuse;
 		$vul = $this->w - $this->rMargin - $this->lMargin - 95;
 		if ($this->GetY() > 200)
                         $this->AddPage();
@@ -388,7 +389,7 @@
                 global $cost_yeasts;
                 global $svg;
                 global $mashkg;
-                $mashtype = array( 'Infusie', 'Verwarming', 'Decoctie' );
+                global $mashtype;
                 $vul = $this->w - $this->rMargin - $this->lMargin - 137;
                 if ($this->GetY() > 250)
                         $this->AddPage();
@@ -518,8 +519,8 @@
 		global $cost_hops;
 		global $cost_miscs;
 		global $cost_yeasts;
-		$colormethod = array( 'Morey', 'Mosher', 'Daniels' );
-		$ibumethod = array( 'Tinseth', 'Rager', 'Daniels' );
+		global $colormethod;
+		global $ibumethod;
 		/* 2 Columns */
 		if ($this->GetY() > 200)
                         $this->AddPage();

mercurial