From: Joe Hunt Date: Fri, 16 Dec 2011 09:21:17 +0000 (+0100) Subject: Added memo/comments print in remittance and receipt. Optimized memo/prints in other... X-Git-Tag: 2.3-final~515 X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=commitdiff_plain;h=6af220a67674c827a1970fe601a4c04e8d07cded;p=fa-stable.git Added memo/comments print in remittance and receipt. Optimized memo/prints in other docs. --- diff --git a/reporting/rep107.php b/reporting/rep107.php index 620117f7..17fbd69d 100644 --- a/reporting/rep107.php +++ b/reporting/rep107.php @@ -129,12 +129,11 @@ function print_invoices() $rep->NewPage(); } - $comments = get_comments(ST_SALESINVOICE, $i); - if ($comments && db_num_rows($comments)) + $memo = get_comments_string(ST_SALESINVOICE, $i); + if ($memo != "") { $rep->NewLine(); - while ($comment=db_fetch($comments)) - $rep->TextColLines(0, 6, $comment['memo_'], -2); + $rep->TextColLines(1, 5, $memo, -2); } $DisplaySubTot = number_format2($SubTotal,$dec); diff --git a/reporting/rep110.php b/reporting/rep110.php index cadfc522..bcb89665 100644 --- a/reporting/rep110.php +++ b/reporting/rep110.php @@ -141,12 +141,11 @@ function print_deliveries() $rep->NewPage(); } - $comments = get_comments(ST_CUSTDELIVERY, $i); - if ($comments && db_num_rows($comments)) + $memo = get_comments_string(ST_CUSTDELIVERY, $i); + if ($memo != "") { $rep->NewLine(); - while ($comment=db_fetch($comments)) - $rep->TextColLines(0, 6, $comment['memo_'], -2); + $rep->TextColLines(1, 5, $memo, -2); } $DisplaySubTot = number_format2($SubTotal,$dec); diff --git a/reporting/rep112.php b/reporting/rep112.php index c13df00d..ba6c9465 100644 --- a/reporting/rep112.php +++ b/reporting/rep112.php @@ -138,6 +138,13 @@ function print_receipts() $rep->NewPage(); } + $memo = get_comments_string($j, $i); + if ($memo != "") + { + $rep->NewLine(); + $rep->TextColLines(1, 5, $memo, -2); + } + $rep->row = $rep->bottomMargin + (15 * $rep->lineHeight); $rep->TextCol(3, 6, _("Total Allocated"), -2); diff --git a/reporting/rep113.php b/reporting/rep113.php index bca06d1b..7a612243 100644 --- a/reporting/rep113.php +++ b/reporting/rep113.php @@ -131,12 +131,11 @@ function print_credits() $rep->NewPage(); } - $comments = get_comments(ST_CUSTCREDIT, $i); - if ($comments && db_num_rows($comments)) + $memo = get_comments_string(ST_CUSTCREDIT, $i); + if ($memo != "") { $rep->NewLine(); - while ($comment=db_fetch($comments)) - $rep->TextColLines(0, 6, $comment['memo_'], -2); + $rep->TextColLines(1, 5, $memo, -2); } $DisplaySubTot = number_format2($SubTotal,$dec); diff --git a/reporting/rep210.php b/reporting/rep210.php index f177fbc1..136f0d2c 100644 --- a/reporting/rep210.php +++ b/reporting/rep210.php @@ -152,6 +152,12 @@ function print_remittances() $rep->NewPage(); } + $memo = get_comments_string($j, $i); + if ($memo != "") + { + $rep->NewLine(); + $rep->TextColLines(1, 5, $memo, -2); + } $rep->row = $rep->bottomMargin + (15 * $rep->lineHeight); $rep->TextCol(3, 6, _("Total Allocated"), -2); diff --git a/reporting/rep409.php b/reporting/rep409.php index a4d41c70..57ed978d 100644 --- a/reporting/rep409.php +++ b/reporting/rep409.php @@ -131,13 +131,13 @@ function print_workorders() $rep->NewLine(1); $rep->TextCol(0, 5," *** = "._("Insufficient stock"), -2); - $comments = get_comments(ST_WORKORDER, $i); - if ($comments && db_num_rows($comments)) + $memo = get_comments_string(ST_WORKORDER, $i); + if ($memo != "") { $rep->NewLine(); - while ($comment=db_fetch($comments)) - $rep->TextColLines(0, 6, $comment['memo_'], -2); + $rep->TextColLines(1, 5, $memo, -2); } + if ($email == 1) { $myrow['DebtorName'] = $myrow['contact'];