(4 replies, posted in FA Modifications)

email scripts can be found in reporting/includes/pdf_report.inc and reporting/includes/class_mail.inc

The print problem with purchase order was appeared since this commit and then was fixed by this commit
Those who encountered this problem can simply update the source code with the lastest snapshot (download here) to get it disappeared

The most effective method for this case is downgrade php version to 5.6, it should much easier than update FrontAccounting to 2.4 unless you have to.

file isession.inc at line 34 uses get_magic_quotes_gpc() that has been deprecated as of php 7.4

line 776 of pdf_report.inc uses function money_format() that is deprecated in php7.4


(4 replies, posted in Setup)

All contacts for both suppliers and customers are recorded in two tables: crm_contacts and crm_person
If customers, suppliers data are the same in both company then copy the said two tables and modify table prefix will achieve your goal.

Hello @mfonnix

FrontHrm already has functions to add extra earning and deduction elements in Salary Structure page.
However if you want to investigate how the calculations work then most of them can be found in payslip_ui.inc and payslip_db.inc

In applications/generalledger.php line 75, the security area for close_period.php should be 'SA_GLCLOSE'

$problemTransaction needs to be defined before line 187 in the bank_transfer.php

After produce a work order, press Print the GL Journal Entries for this Work Order
It will fire an error : Unhandled exception [0]: Call to undefined function count_array() in .../pdf_report.inc at line 344

To fix this issue replace line 175 of rep704.php with this code:

if($myrow["person_type_id"] == PT_WORKORDER)
    $txt = '';
    $txt = payment_person_name($myrow["person_type_id"], $myrow["person_id"], false);

Steps to reaproduce this problem :
1. Add a cost to an Advance Manufacture work order, this process will create a journal entry
2. Open General Ledger report -> GL Account Transactions, this report will show html code in the Person/Item column for the created journal entry.
See this image

line 55 of accruals.php should be


Hi @bradlanier

I guess @itronics is managing the official modules repository
We have to install the module manually (has been instructed in post #1 of this thread) until he update the repo.

I confirm the rounding problem.
Fix: line 202 of item_adjustment_ui.inc should be

amount_cells(null, 'std_cost', null, null, null, $dec2);

The last passed variable should be $dec2 not $dec, $dec is for quantity decimal

This problem occurs because duplication of function get_po() defined in po_db.inc and rep209.php.
@joe, can replace funtion get_po in po_db.inc by the one in rep209

There maybe some reasons that cause user browser javascript turned of then branch and customer can be wrong selected then process wrong data to database.
This check need to be added to function can_process() in sales_order_entry.php, customer_payments.php, credit_note_entry.php

if(!branch_in_foreign_table(get_post('customer_id'), get_post('branch_id'), 'cust_branch')) {
        display_error(_("The selected branch is not a branch of the selected customer."));
        return false;

Note: in customer_payments.php 'branch_id' should be 'BranchID'

This error does not usually occurs but it would be critical when it does.

Acctually I already made my own solution for the problem by replace line 406 of allocation_cart.inc with this code:

elseif ($_SESSION['alloc']->person_type == PT_SUPPLIER && $_SESSION['alloc']->allocs[$counter]->type != ST_PURCHORDER)

But it will damage the solution of @itronics
A better solution in my opinion is to add a function called get_po() to po_db.inc like this

function get_po($order_no) {
    $sql = "SELECT * FROM ".TB_PREF."purch_orders WHERE order_no = ".db_escape($order_no);
    $result = db_query($sql);

    return db_fetch($result);

Then add a check for purchase orders in the allocation table by replace line 407 of allocation_cart.inc by this code:

if ($_SESSION['alloc']->allocs[$counter]->type == ST_PURCHORDER)
                $trans = get_po($_SESSION['alloc']->allocs[$counter]->type_no);
                $trans = get_supp_trans($_SESSION['alloc']->allocs[$counter]->type_no, $_SESSION['alloc']->allocs[$counter]->type);

This commit has made the error on Payment to Supplier process
Function get_supp_trans() at line 407 of allocation_cart.inc will fire the error when allocation table has a purchase order

rafat wrote:

Hi @notrinos

You need to take a look at Employee Payment Entry when allocating a Loan (Employee Advance) amount. Its not generating the correct Total Amount for This Allocation.
Its somehow messy. Also is there a plan for an inquiry screen or report for loans (Advances).? It will be nice to have.

Hi @rafat

The Employee Loan Allocating issue has been fixed and can be seen here

The report of loans will be processed later

Thank you

Hi @mfonnix you may have installed the incorrect source code, please read post #1 in this thread to know how to install the correct one.

boxygen wrote:

@notrinos, the Employee Transaction Inquiry has a bug. Once you Select any one Employee, the Transactions related to Employee Advance is not shown. I tried a lot of ways but in vain. The SQL Query is too complex

Can anyone help out in this?

This problem has been fixed and can be downloaded here
Thank you @boxygen

Hi Niyaz, please read post #1 in this thread to get fix for your problem: https://frontaccounting.com/punbb/viewtopic.php?id=6860

Hello @minmaxfamily

Read post #1 in this topic to get fix for your problem


(81 replies, posted in FA Modifications)

joe wrote:

Hello Guys,

I have plans about incorporating a new class.graphic.inc in release 2.5 core.
I have already made a local version for looking at now by replacing the old class.graphic.inc with a new one, which is a wrapper around the Open Source chart.js. This chart.js is a very famous and qualified script to go for.

The file, dashboard.php in the admin folder has been slightly changed to this new one.
The dashboard.inc file in the includes folder is replaced with a new and adequate file.
My plans are further to make a Dashboard Setup in the Setup section. This is for setting a lot of parameters for
the dashboard.
At the same time my plans are to let dashboard.php check if there is a dashboard.inc file in the theme folder, if so this will be included instead of the core one.

Included in this look at version are the new Dimension booking on Balance Accounts.

You can have a look at this local version at the following URL:

http://frontaccounting.co.uk/fa248 .
User: admin
Pass: 98765

This version will only be available a week or so.


Awsome @joe

On this basis we can generate countless charts for unlimited number of different statistical needs