3 => array('text' => _('Currency'), 'from' => $currency, 'to' => ''));
$rep = new FrontReport(_('Customer Balances'), "CustomerBalances", user_pagesize());
-
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
-
+ $rep->NewPage();
$grandtotal = array(0,0,0,0);
$sql = "SELECT debtor_no, name, curr_code FROM ".TB_PREF."debtors_master ";
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$total = array(0,0,0,0, 0);
$x = ($rep->pageWidth - $w) / 2;
$rep->NewLine(2);
if ($rep->row - $h < $rep->bottomMargin)
- $rep->Header();
+ $rep->NewPage();
$rep->AddImage($filename, $x, $rep->row - $h, $w, $h);
}
$rep->NewLine();
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$result = get_customer_details_for_report($area, $folk);
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$result = fetch_items($category);
{
$rep->NewLine();
if ($rep->row - $pic_height < $rep->bottomMargin)
- $rep->Header();
+ $rep->NewPage();
$rep->AddImage($image, $rep->cols[1], $rep->row - $pic_height, 0, $pic_height);
$rep->row -= $pic_height;
$rep->NewLine();
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns, $cols2, $headers2, $aligns2);
- $rep->Header();
+ $rep->NewPage();
$orderno = 0;
$result = GetSalesOrders($from, $to, $category, $location, $backorder);
if ($rep->row < $rep->bottomMargin + (2 * $rep->lineHeight))
{
$orderno = 0;
- $rep->Header();
+ $rep->NewPage();
}
$rep->NewLine(0, 2, false, $orderno);
if ($orderno != $myrow['order_no'])
if ($rep->row < $rep->bottomMargin + (2 * $rep->lineHeight))
{
$orderno = 0;
- $rep->Header();
+ $rep->NewPage();
}
}
$rep->Line($rep->row);
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns, $cols2, $headers2, $aligns2);
- $rep->Header();
+ $rep->NewPage();
$salesman = 0;
$subtotal = $total = $subprov = $provtotal = 0;
if ($rep->row < $rep->bottomMargin + (2 * $rep->lineHeight))
{
$salesman = 0;
- $rep->Header();
+ $rep->NewPage();
}
$rep->NewLine(0, 2, false, $salesman);
if ($salesman != $myrow['salesman_code'])
if ($rep->row < $rep->bottomMargin + (2 * $rep->lineHeight))
{
$salesman = 0;
- $rep->Header();
+ $rep->NewPage();
}
}
$subtotal += $amt;
if ($email == 0)
{
$rep = new FrontReport(_('INVOICE'), "InvoiceBulk", user_pagesize());
+ $rep->SetHeaderType('Header2');
$rep->currency = $cur;
$rep->Font();
$rep->Info($params, $cols, null, $aligns);
if ($email == 1)
{
$rep = new FrontReport("", "", user_pagesize());
+ $rep->SetHeaderType('Header2');
$rep->currency = $cur;
$rep->Font();
if ($j == ST_SALESINVOICE)
}
else
$rep->title = ($j == ST_SALESINVOICE) ? _('INVOICE') : _('CREDIT NOTE');
- $rep->Header2($myrow, $branch, $sales_order, $baccount, $j);
+ $rep->SetCommonData($myrow, $branch, $sales_order, $baccount, $j);
+ $rep->NewPage();
$result = get_customer_trans_details($j, $i);
$SubTotal = 0;
$rep->row = $newrow;
//$rep->NewLine(1);
if ($rep->row < $rep->bottomMargin + (15 * $rep->lineHeight))
- $rep->Header2($myrow, $branch, $sales_order, $baccount,$j);
+ $rep->NewPage();
}
$comments = get_comments($j, $i);
if ($email == 0)
{
$rep = new FrontReport(_('STATEMENT'), "StatementBulk", user_pagesize());
+ $rep->SetHeaderType('Header2');
$rep->currency = $cur;
$rep->Font();
$rep->Info($params, $cols, null, $aligns);
if ($email == 1)
{
$rep = new FrontReport("", "", user_pagesize());
+ $rep->SetHeaderType('Header2');
$rep->currency = $cur;
$rep->Font();
$rep->title = _('STATEMENT');
$rep->filename = "Statement" . $myrow['debtor_no'] . ".pdf";
$rep->Info($params, $cols, null, $aligns);
}
- $rep->Header2($myrow, null, null, $baccount, ST_STATEMENT);
+ $rep->SetCommonData($myrow, null, null, $baccount, ST_STATEMENT);
+ $rep->NewPage();
$rep->NewLine();
$linetype = true;
$doctype = ST_STATEMENT;
$rep->TextCol(7, 8, $DisplayNet, -2);
$rep->NewLine();
if ($rep->row < $rep->bottomMargin + (10 * $rep->lineHeight))
- $rep->Header2($myrow, null, null, $baccount, ST_STATEMENT);
+ $rep->NewPage();
}
$nowdue = "1-" . $PastDueDays1 . " " . $doc_Days;
$pastdue1 = $PastDueDays1 + 1 . "-" . $PastDueDays2 . " " . $doc_Days;
$rep = new FrontReport(_("SALES ORDER"), "SalesOrderBulk", user_pagesize());
else
$rep = new FrontReport(_("QUOTE"), "QuoteBulk", user_pagesize());
+ $rep->SetHeaderType('Header2');
$rep->currency = $cur;
$rep->Font();
$rep->Info($params, $cols, null, $aligns);
if ($email == 1)
{
$rep = new FrontReport("", "", user_pagesize());
+ $rep->SetHeaderType('Header2');
$rep->currency = $cur;
$rep->Font();
if ($print_as_quote == 1)
}
else
$rep->title = ($print_as_quote==1 ? _("QUOTE") : _("SALES ORDER"));
- $rep->Header2($myrow, $branch, $myrow, $baccount, ST_SALESORDER);
+ $rep->SetCommonData($myrow, $branch, $myrow, $baccount, ST_SALESORDER);
+ $rep->NewPage();
$result = get_sales_order_details($i, ST_SALESORDER);
$SubTotal = 0;
$rep->row = $newrow;
//$rep->NewLine(1);
if ($rep->row < $rep->bottomMargin + (15 * $rep->lineHeight))
- $rep->Header2($myrow, $branch, $myrow, $baccount, ST_SALESORDER);
+ $rep->NewPage();
}
if ($myrow['comments'] != "")
{
$rep = new FrontReport(_('DELIVERY'), "DeliveryNoteBulk", user_pagesize());
else
$rep = new FrontReport(_('PACKING SLIP'), "PackingSlipBulk", user_pagesize());
+ $rep->SetHeaderType('Header2');
$rep->currency = $cur;
$rep->Font();
$rep->Info($params, $cols, null, $aligns);
if ($email == 1)
{
$rep = new FrontReport("", "", user_pagesize());
+ $rep->SetHeaderType('Header2');
$rep->currency = $cur;
$rep->Font();
if ($packing_slip == 0)
}
else
$rep->title = _('DELIVERY NOTE');
- $rep->Header2($myrow, $branch, $sales_order, '', ST_CUSTDELIVERY);
+ $rep->SetCommonData($myrow, $branch, $sales_order, '', ST_CUSTDELIVERY);
+ $rep->NewPage();
$result = get_customer_trans_details(ST_CUSTDELIVERY, $i);
$SubTotal = 0;
$rep->row = $newrow;
//$rep->NewLine(1);
if ($rep->row < $rep->bottomMargin + (15 * $rep->lineHeight))
- $rep->Header2($myrow, $branch, $sales_order,'',ST_CUSTDELIVERY);
+ $rep->NewPage();
}
$comments = get_comments(ST_CUSTDELIVERY, $i);
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);
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;
$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'] != "")
{
$cur = get_company_Pref('curr_default');
$rep = new FrontReport(_('RECEIPT'), "ReceiptBulk", user_pagesize());
+ $rep->SetHeaderType('Header2');
$rep->currency = $cur;
$rep->Font();
$rep->Info($params, $cols, null, $aligns);
$params['bankaccount'] = $baccount['id'];
$rep->title = _('RECEIPT');
- $rep->Header2($myrow, null, $myrow, $baccount, ST_CUSTPAYMENT);
+ $rep->SetCommonData($myrow, null, $myrow, $baccount, ST_CUSTPAYMENT);
+ $rep->NewPage();
$result = get_allocations_for_receipt($myrow['debtor_no'], $myrow['type'], $myrow['trans_no']);
$linetype = true;
$total_allocated += $myrow2['amt'];
$rep->NewLine(1);
if ($rep->row < $rep->bottomMargin + (15 * $rep->lineHeight))
- $rep->Header2($myrow, null, $myrow, $baccount, ST_CUSTPAYMENT);
+ $rep->NewPage();
}
$rep->row = $rep->bottomMargin + (15 * $rep->lineHeight);
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$total = array();
$grandtotal = array(0,0,0,0);
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$total = array();
$total[0] = $total[1] = $total[2] = $total[3] = $total[4] = 0.0;
$x = ($rep->pageWidth - $w) / 2;
$rep->NewLine(2);
if ($rep->row - $h < $rep->bottomMargin)
- $rep->Header();
+ $rep->NewPage();
$rep->AddImage($filename, $x, $rep->row - $h, $w, $h);
}
$rep->End();
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$total = array();
$grandtotal = array(0,0);
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$Tot_Val=0;
$Supplier = '';
if ($email == 0)
{
$rep = new FrontReport(_('PURCHASE ORDER'), "PurchaseOrderBulk", user_pagesize());
+ $rep->SetHeaderType('Header2');
$rep->currency = $cur;
$rep->Font();
$rep->Info($params, $cols, null, $aligns);
if ($email == 1)
{
$rep = new FrontReport("", "", user_pagesize());
+ $rep->SetHeaderType('Header2');
$rep->currency = $cur;
$rep->Font();
$rep->title = _('PURCHASE ORDER');
}
else
$rep->title = _('PURCHASE ORDER');
- $rep->Header2($myrow, null, $myrow, $baccount, ST_PURCHORDER);
+ $rep->SetCommonData($myrow, null, $myrow, $baccount, ST_PURCHORDER);
+ $rep->NewPage();
$result = get_po_details($i);
$SubTotal = 0;
$rep->TextCol(6, 7, $DisplayNet, -2);
$rep->NewLine(1);
if ($rep->row < $rep->bottomMargin + (15 * $rep->lineHeight))
- $rep->Header2($myrow, $branch, $myrow, $baccount, ST_PURCHORDER);
+ $rep->NewPage();
}
if ($myrow['comments'] != "")
{
if ($email == 0)
{
$rep = new FrontReport(_('REMITTANCE'), "RemittanceBulk", user_pagesize());
+ $rep->SetHeaderType('Header2');
$rep->currency = $cur;
$rep->Font();
$rep->Info($params, $cols, null, $aligns);
if ($email == 1)
{
$rep = new FrontReport("", "", user_pagesize());
+ $rep->SetHeaderType('Header2');
$rep->currency = $cur;
$rep->Font();
$rep->title = _('REMITTANCE');
}
else
$rep->title = _('REMITTANCE');
- $rep->Header2($myrow, null, $myrow, $baccount, ST_SUPPAYMENT);
+ $rep->SetCommonData($myrow, null, $myrow, $baccount, ST_SUPPAYMENT);
+ $rep->NewPage();
$result = get_allocations_for_remittance($myrow['supplier_id'], $myrow['type'], $myrow['trans_no']);
$linetype = true;
$total_allocated += $myrow2['amt'];
$rep->NewLine(1);
if ($rep->row < $rep->bottomMargin + (15 * $rep->lineHeight))
- $rep->Header2($myrow, null, $myrow, $baccount, ST_SUPPAYMENT);
+ $rep->NewPage();
}
$rep->row = $rep->bottomMargin + (15 * $rep->lineHeight);
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$res = getTransactions($category, $location);
$total = $grandtotal = 0.0;
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$res = getTransactions($category, $location);
$catt = '';
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$res = getTransactions($category, $location);
$catt = '';
{
$rep->NewLine();
if ($rep->row - $pic_height < $rep->bottomMargin)
- $rep->Header();
+ $rep->NewPage();
$rep->AddImage($image, $rep->cols[1], $rep->row - $pic_height, 0, $pic_height);
$rep->row -= $pic_height;
$rep->NewLine();
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$res = getTransactions($category, $location, $fromcust, $from, $to);
$total = $grandtotal = 0.0;
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$res = getTransactions($from, $to);
$total = $qtotal = $grandtotal = 0.0;
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$res = getTransactions($frompart, $topart);
$parent = '';
if ($email == 0)
{
$rep = new FrontReport(_('WORK ORDER'), "WorkOrderBulk", user_pagesize());
+ $rep->SetHeaderType('Header2');
$rep->currency = $cur;
$rep->Font();
$rep->Info($params, $cols, null, $aligns);
if ($email == 1)
{
$rep = new FrontReport("", "", user_pagesize());
+ $rep->SetHeaderType('Header2');
$rep->currency = $cur;
$rep->Font();
$rep->title = _('WORK ORDER');
}
else
$rep->title = _('WORK ORDER');
- $rep->Header2($myrow, null, null, '', 26);
+ $rep->SetCommonData($myrow, null, null, '', 26);
+ $rep->NewPage();
$result = get_wo_requirements($i);
$rep->TextCol(0, 5,_("Work Order Requirements"), -2);
$rep->AmountCol(6, 7, $myrow2['units_issued'], $dec, -2);
$rep->NewLine(1);
if ($rep->row < $rep->bottomMargin + (15 * $rep->lineHeight))
- $rep->Header2($myrow, null, null,'',26);
+ $rep->NewPage();
}
$rep->NewLine(1);
$rep->TextCol(0, 5," *** = "._("Insufficient stock"), -2);
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$res = getTransactions($fromdim, $todim);
while ($trans=db_fetch($res))
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$prev_balance = get_bank_balance_to($from, $account["id"]);
if ($rep->row < $rep->bottomMargin + $rep->lineHeight)
{
$rep->Line($rep->row - 2);
- $rep->Header();
+ $rep->NewPage();
}
}
$rep->NewLine();
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$classresult = get_account_classes(false);
while ($class = db_fetch($classresult))
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
if ($systype == -1)
$systype = null;
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$accounts = get_gl_accounts($fromacc, $toacc);
if ($rep->row < $rep->bottomMargin + $rep->lineHeight)
{
$rep->Line($rep->row - 2);
- $rep->Header();
+ $rep->NewPage();
}
}
$rep->NewLine();
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$sales = Array(1 => 0,0,0,0,0,0,0,0,0,0,0,0,0,0);
$rep = new FrontReport(_('Balance Sheet'), "BalanceSheet", user_pagesize());
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$calc_open = $calc_period = 0.0;
$equity_open = $equity_period = 0.0;
$x = ($rep->pageWidth - $w) / 2;
$rep->NewLine(2);
if ($rep->row - $h < $rep->bottomMargin)
- $rep->Header();
+ $rep->NewPage();
$rep->AddImage($filename, $x, $rep->row - $h, $w, $h);
}
$rep->End();
if ($rep->row < $rep->bottomMargin + 3 * $rep->lineHeight)
{
$rep->Line($rep->row - 2);
- $rep->Header();
+ $rep->NewPage();
}
$code_per_balance += $per_balance;
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$classper = 0.0;
$classacc = 0.0;
$x = ($rep->pageWidth - $w) / 2;
$rep->NewLine(2);
if ($rep->row - $h < $rep->bottomMargin)
- $rep->Header();
+ $rep->NewPage();
$rep->AddImage($filename, $x, $rep->row - $h, $w, $h);
}
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns, $cols2, $headers2, $aligns2);
- $rep->Header();
+ $rep->NewPage();
$accounts = get_gl_accounts();
if ($rep->row < $rep->bottomMargin + $rep->lineHeight)
{
$rep->Line($rep->row - 2);
- $rep->Header();
+ $rep->NewPage();
}
}
$rep->Line($rep->row);
$rep->Info($params, $cols, $headers, $aligns);
if (!$summaryOnly)
{
- $rep->Header();
+ $rep->NewPage();
}
$totalnet = 0.0;
if ($rep->row < $rep->bottomMargin + $rep->lineHeight)
{
$rep->Line($rep->row - 2);
- $rep->Header();
+ $rep->NewPage();
}
}
if ($trans['trans_type']==ST_JOURNAL && $trans['amount']<0) {
$rep->headers = $headers2;
$rep->aligns = $aligns2;
- $rep->Header();
+ $rep->NewPage();
$taxtotal = 0;
foreach( $taxes as $id=>$sum)
$rep->Font();
$rep->Info($params, $cols, $headers, $aligns);
- $rep->Header();
+ $rep->NewPage();
$trans = getTransactions($from, $to, $systype, $user);