Topic: Show the gross amount per item on sales invoice and credit note

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

Re: Show the gross amount per item on sales invoice and credit note

This may not be everything you want, but you could sell your items including tax (Select from price list in invoice creation - set up in "Sales Types")
Try it in your training program first.

The FrontAccounting Wiki(Manual, examples, tips, setup info, links to accounting sites, etc) https://frontaccounting.com/fawiki/

Re: Show the gross amount per item on sales invoice and credit note

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"));