Report fixed according to changed headers API in FrontReport class.
[fa-stable.git] / reporting / rep111.php
index 5db2f9d06dd40f8ce9281e46d4c1eea7228f35fa..e3b0ab1fcddf684a6e85cc4cc3da6d96ff4b1e15 100644 (file)
@@ -58,6 +58,7 @@ function print_sales_quotations()
        if ($email == 0)
        {
                $rep = new FrontReport(_("SALES QUOTATION"), "SalesQuotationBulk", user_pagesize());
+               $rep->SetHeaderType('Header2');
                $rep->currency = $cur;
                $rep->Font();
                $rep->Info($params, $cols, null, $aligns);
@@ -72,13 +73,16 @@ function print_sales_quotations()
                if ($email == 1)
                {
                        $rep = new FrontReport("", "", user_pagesize());
+                       $rep->SetHeaderType('Header2');
                        $rep->currency = $cur;
                        $rep->Font();
                        $rep->filename = "SalesQuotation" . $i . ".pdf";
                        $rep->Info($params, $cols, null, $aligns);
                }
                $rep->title = _("SALES QUOTATION");
-               $rep->Header2($myrow, $branch, $myrow, $baccount, ST_SALESQUOTE);
+               $rep->SetCommonData($myrow, $branch, $myrow, $baccount, ST_SALESQUOTE);
+               $rep->headerFunc = 'Header2';
+               $rep->NewPage();
 
                $result = get_sales_order_details($i, ST_SALESQUOTE);
                $SubTotal = 0;
@@ -107,7 +111,7 @@ function print_sales_quotations()
                        $rep->row = $newrow;
                        //$rep->NewLine(1);
                        if ($rep->row < $rep->bottomMargin + (15 * $rep->lineHeight))
-                               $rep->Header2($myrow, $branch, $myrow, $baccount, ST_SALESQUOTE);
+                               $rep->NewPage();
                }
                if ($myrow['comments'] != "")
                {