I have come up with a solution

1. changed the columns size and added and extra column in line 60 of rep107:
    $cols = array(4, 60, 195, 260, 285, 325, 390, 450, 515);
2. added the Gross amount calcuations ( hardcoded tax multiplier in file, but works for me for now) in rep107 as per below from line 114 onwards:
                $DisplayPrice = number_format2($myrow2["unit_price"],$dec);
                $DisplayQty = number_format2($sign*$myrow2["quantity"],get_qty_dec($myrow2['stock_id']));
                $DisplayNet = number_format2($Net,$dec);
             //Calculate Gross number
             $DisplayGross = number_format2($Net*1.16,$dec);               
                if ($myrow2["discount_percent"]==0)
                      $DisplayDiscount ="";
                else
                      $DisplayDiscount = number_format2($myrow2["discount_percent"]*100,user_percent_dec()) . "%";
                $rep->TextCol(0, 1,    $myrow2['stock_id'], -2);
                $oldrow = $rep->row;
                $rep->TextColLines(1, 2, $myrow2['StockDescription'], -2);
                $newrow = $rep->row;
                $rep->row = $oldrow;
                if ($Net != 0.0 || !is_service($myrow2['mb_flag']) || !isset($no_zero_lines_amount) || $no_zero_lines_amount == 0)
                {
                    $rep->TextCol(2, 3,    $DisplayQty, -2);
                    $rep->TextCol(3, 4,    $myrow2['units'], -2);
                    $rep->TextCol(4, 5,    $DisplayPrice, -2);
                    $rep->TextCol(5, 6,    $DisplayDiscount, -2);
                    $rep->TextCol(6, 7,    $DisplayNet, -2);
                            //Display Gross Number
                            $rep->TextCol(7, 8,    $DisplayGross, -2);   

3. Change the row descriptions in doctext.inc line 30
    // default item column headers
    $this->headers = array(_("Item Code"), _("Item Description"), _("Quantity"),
        _("Unit"), _("Price"), _("Discount %"), _("Net"), _("Gross"));

I want to show the gross amount per item ( including tax) on the sales invoice and credit note pdfs. So at the item level instead of just after sub total.

Not sure if this has to be done at the code level in the rep files or is there a setting/flag somewhere to trigger this.
Thanks
Sam

Hi
As per new tax requirements, we are supposed to show the related invoice no on the pdf credit note.

Is there any way to do this? 
So ideally I want to replace the Order no with the invoice no in the below code in reporting/includes/doctext.inc

        case ST_CUSTCREDIT:
            $this->title = _("CREDIT NOTE");
            $this->formData['document_name'] =_("Credit No.");
            $Footer[0] = _("Please quote Credit no. when paying. All amounts stated in") . " - " . $this->formData['curr_code'];

            $aux_info = array(
                _("Customer's Reference") => @$this->formData["customer_ref"],
                _("Sales Person") => get_salesman_name($this->formData['salesman']),
                _("Your PIN no.") => $this->formData['tax_id'],
                _("Our Order No") => $this->formData['order_'],
                _("Due Date") => '',
            );
            break;



Thanks
Sam

Hi,

Have done a new install recently and tried to create a sales transaction. When click on sales invoice, quotation etc leads to a blank white page.

I have deactivated all extensions I had installed and also reverted back to the default theme, but still getting the same errors.

Am using FrontAccounting 2.3.24.

Any ideas how to investigate this / fix it?

any help much appreciated.

Update:

Looking through the error log file, I am getting this error only when click on any of the: Sales Quotation, Direct INvoice etc.

23-Nov-2015 21:09:16] <b>DATABASE ERROR :</b> The customer details could not be retrieved<br>error code : 1064<br>error message : You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'IFNULL(IF(trans.type=11 OR trans.type=12 OR trans.type=2, -1, 1)
            * (trans' at line 8<br>sql that failed was : SELECT 0_debtors_master.name, 0_debtors_master.curr_code, 0_payment_terms.terms,
        0_debtors_master.credit_limit, 0_credit_status.dissallow_invoices, 0_credit_status.reason_description,

        Sum(IFNULL(IFNULL(IF(trans.type=11 OR trans.type=12 OR trans.type=2, -1, 1)
            * (trans.ov_amount + trans.ov_gst + trans.ov_freight + trans.ov_freight_tax + trans.ov_discount),0),0)) AS Balance,
        Sum(IF ((TO_DAYS('2015-11-23') - TO_DAYS(IF (trans.type=10, trans.due_date, trans.tran_date))) > 0,IFNULL(IF(trans.type=11 OR trans.type=12 OR trans.type=2, -1, 1)
            * (trans.ov_amount + trans.ov_gst + trans.ov_freight + trans.ov_freight_tax + trans.ov_discount),0),0)) AS Due,
        Sum(IF ((TO_DAYS('2015-11-23') - TO_DAYS(IF (trans.type=10, trans.due_date, trans.tran_date))) > ,IFNULL(IF(trans.type=11 OR trans.type=12 OR trans.type=2, -1, 1)
            * (trans.ov_amount + trans.ov_gst + trans.ov_freight + trans.ov_freight_tax + trans.ov_discount),0),0)) AS Overdue1,
        Sum(IF ((TO_DAYS('2015-11-23') - TO_DAYS(IF (trans.type=10, trans.due_date, trans.tran_date))) > 0,IFNULL(IF(trans.type=11 OR trans.type=12 OR trans.type=2, -1, 1)
            * (trans.ov_amount + trans.ov_gst + trans.ov_freight + trans.ov_freight_tax + trans.ov_discount),0),0)) AS Overdue2

        FROM 0_debtors_master
             LEFT JOIN 0_debtor_trans trans ON
             trans.tran_date <= '2015-11-23' AND 0_debtors_master.debtor_no = trans.debtor_no AND trans.type <> 13
,
             0_payment_terms,
             0_credit_status

        WHERE
             0_debtors_master.payment_terms = 0_payment_terms.terms_indicator
             AND 0_debtors_master.credit_status = 0_credit_status.id
             AND 0_debtors_master.debtor_no = '' GROUP BY
              0_debtors_master.name,
              0_payment_terms.terms,
              0_payment_terms.days_before_due,
              0_payment_terms.day_in_following_month,
              0_debtors_master.credit_limit,
              0_credit_status.dissallow_invoices,
              0_credit_status.reason_description<br><br><br>