X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=reporting%2Frep707.php;h=0516c17ec53e8e6250a7f438052bad2cb0950414;hb=d1b959c4b73664327c2e17d5bb3fb515aabfa449;hp=7ce02b2c8c8594db6c8f2ed5b07782c549ebbd49;hpb=a8d2bad4b2fbda5eaa5bcbf96733c2979b8083c7;p=fa-stable.git diff --git a/reporting/rep707.php b/reporting/rep707.php index 7ce02b2c..0516c17e 100644 --- a/reporting/rep707.php +++ b/reporting/rep707.php @@ -9,7 +9,7 @@ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the License here . ***********************************************************************/ -$page_security = 2; +$page_security = 'SA_GLANALYTIC'; // ---------------------------------------------------------------- // $ Revision: 2.0 $ // Creator: Joe Hunt @@ -191,7 +191,7 @@ function print_profit_and_loss_statement() { for ( ; $level >= 0, $typename[$level] != ''; $level--) { - if ($account['parent'] == $closing[$level] || $account['parent'] < $last || $account['parent'] <= 0) + if ($account['parent'] == $closing[$level] || $account['parent'] < $last || $account['parent'] <= 0 || $closeclass) { $rep->row += 6; $rep->Line($rep->row); @@ -243,6 +243,7 @@ function print_profit_and_loss_statement() $last = $account['parent']; $typename[$level] = $account['AccountTypeName']; $closing[$level] = $account['parent']; + $rep->row -= 4; $rep->TextCol(0, 5, $account['AccountTypeName']); $rep->row -= 4; @@ -251,8 +252,8 @@ function print_profit_and_loss_statement() } $classname = $account['AccountClassName']; $ctype = $account['ClassType']; - $convert = (($ctype == CL_INCOME || $ctype == 0) ? -1 : 1); // backwards compatibility - + $convert = get_class_type_convert($ctype); + if ($account['account_code'] != null) { //$per_balance *= -1; @@ -294,7 +295,7 @@ function print_profit_and_loss_statement() { for ( ; $level >= 0, $typename[$level] != ''; $level--) { - if ($account['parent'] == $closing[$level] || $account['parent'] < $last || $account['parent'] <= 0) + if ($account['parent'] == $closing[$level] || $account['parent'] < $last || $account['parent'] <= 0 || $closeclass) { $rep->row += 6; $rep->Line($rep->row);