1,376

(5 replies, posted in Modules Add-on's)

The documentation is at:
https://github.com/apmuthu/FA24extensions/tree/master/Extensions/repgen/doc

1,377

(17 replies, posted in Reporting)

Study the use of the $Footer array in reporting/includes/doctext.inc.

At the end of the reporting/includes/doctext.inc file, the following was added to get the output attached:

    $Footer[] = "THIS IS A SYSTEM GENERATED REPORT AND NO SIGNATURE IS REQUIRED";

1,378

(3 replies, posted in Modules Add-on's)

This parameter 4 is available only when the company preferences is set to use 2 dimensions and the report request form has the second dimension chosen. If you still get this error, then you should get a similar error when using report rep706.php too - Balance Sheet - with similar form request parameters chosen. The same applies to the Cash Flow Statement as well.

Customer Ledger Report: The constants ST_BULKDEPOSIT and ST_CASHDEPOSIT are not part of standard FrontAccounting and is what @braathwaate has in his fork. You may remove those entries in the said line and it should work.

1,379

(5 replies, posted in Modules Add-on's)

Yes, that's right.
How did it go?

CTRL-P is a browser attached command and has nothing to do with FA.
Assign CTRL-P to something in the browser shortcuts customisation if you want it browser wide for all sites.

The popup page comes from gl/view/gl_trans_view.php.

Comment out the last php line in the above file (line 160).
Output Attached.

1,381

(17 replies, posted in Reporting)

I trust the attachment will speak for itself.

Checkout the function hyperlink_back() in includes/ui/ui_controls.inc, specifically the echo lines 213 and 215:

    if ($no_menu)
    {
        echo "<td align=center><a href='javascript:window.print();'>"._("Print")."</a></td>\n";
    }    
    echo "<td align=center><a href='javascript:goBack(".($final ? '-2' : '').");'>".($no_menu ? _("Close") : _("Back"))."</a></td>\n";

If you want to remove the Print/Close in all pages, then make the above to be:

    if ($no_menu)
    {
        echo "<td align=center>&nbsp;</td>\n";
    }    
    echo "<td align=center><a href='javascript:goBack(".($final ? '-2' : '').");'>".($no_menu ? "" : _("Back"))."</a></td>\n";

1,383

(17 replies, posted in Reporting)

See the release post for changed files.

1,384

(4 replies, posted in Announcements)

Attached is the set of changed files between FA 2.4.4 and FA 2.4.5.

All upgrade caveats apply and among others they are:
1. backup files and sql first
2. sys_prefs table entries - ref_no_auto_increase, print_dialog_direct
3. config.php variables and their settings
4. db changes if any
5. sequential updates from each version
6. extensions compatibility
7. language strings

The Sourceforge mirrors may not yet have been updated (Excellmedia, Kent). The following links work now:

https://liquidtelecom.dl.sourceforge.net/project/frontaccounting/FrontAccounting%202.4/2.4.5/frontaccounting-2.4.5.tar.gz
Size: 1,574,771 bytes
MD5: C0AA7D697E8DCB5F3A44E709165DE3485E396911
md5: c0aa7d697e8dcb5f3a44e709165de3485e396911

https://sourceforge.net/code-snapshots/git/f/fr/frontaccounting/git.git/frontaccounting-git-080086d679db208567059b420ebfb5fcd7aae5b5.zip

The first 2 day download stats for FA 2.4.5 since it's release shows the UK (57) just leading India (41) with the others way behind. Weekend may be a reason as well.

1,385

(17 replies, posted in Reporting)

This has been fixed a few weeks ago for PHP 7.x users. Upgrade to FA 2.4.5 or use the appropriate commits for fixing it.

1,386

(3 replies, posted in Modules Add-on's)

These are strict variable scoping issues with PHP 7.2+. Just declare the said variables as 0 just before the structure ("if", "while", etc.,) in which it is used for the first time. In the case of your first issue, you will need to insert the following just before the "if" statement at line 110 in rep_statement_reconcile.php:

$total_debit = $total_credit = 0;

1,387

(5 replies, posted in Modules Add-on's)

What version of PHP are you using?
It could be a scope issue in some later versions of PHP.
Just place the following statement above the "if" statement at line 50 in repgen/includes/repgen_def.inc:

$protocol='';

or hardcode as desired.

1,388

(3 replies, posted in Reporting)

You need to alter the reporting/rep103.php file.

Lines 30 to 53 in it:

function get_customer_details_for_report($area=0, $salesid=0)
{
    $sql = "SELECT debtor.debtor_no,
            debtor.name,
            debtor.address,
            debtor.curr_code,
            debtor.dimension_id,
            debtor.dimension2_id,
            debtor.notes,
            pricelist.sales_type,
            branch.branch_code,
            branch.br_name,
            branch.br_address,
            branch.br_post_address,
            branch.area,
            branch.salesman,
            area.description,
            salesman.salesman_name
        FROM ".TB_PREF."debtors_master debtor
        INNER JOIN ".TB_PREF."cust_branch branch ON debtor.debtor_no=branch.debtor_no
        INNER JOIN ".TB_PREF."sales_types pricelist    ON debtor.sales_type=pricelist.id
        INNER JOIN ".TB_PREF."areas area ON branch.area = area.area_code
        INNER JOIN ".TB_PREF."salesman salesman    ON branch.salesman=salesman.salesman_code
        WHERE debtor.inactive = 0";

may be replaced with:

function get_customer_details_for_report($area=0, $salesid=0)
{
    $sql = "SELECT debtor.debtor_no,
            debtor.name,
            debtor.address,
            debtor.curr_code,
            debtor.dimension_id,
            debtor.dimension2_id,
            pt.terms,
            debtor.credit_limit,
            debtor.notes,
            pricelist.sales_type,
            branch.branch_code,
            branch.br_name,
            branch.br_address,
            branch.br_post_address,
            branch.area,
            branch.salesman,
            area.description,
            salesman.salesman_name
        FROM ".TB_PREF."debtors_master debtor
        INNER JOIN ".TB_PREF."cust_branch branch ON debtor.debtor_no=branch.debtor_no
        INNER JOIN ".TB_PREF."sales_types pricelist    ON debtor.sales_type=pricelist.id
        INNER JOIN ".TB_PREF."areas area ON branch.area = area.area_code
        INNER JOIN ".TB_PREF."salesman salesman    ON branch.salesman=salesman.salesman_code
        INNER JOIN ".TB_PREF."payment_terms pt ON debtor.payment_terms=pt.terms_indicator
        WHERE debtor.inactive = 0";

The necessary fields will now be available for placement as needed in the report.

1,389

(7 replies, posted in Setup)

That should be a breeze with a cronjob.
Make one entry in VirtueMart in the normal course of wok and compare the before and after backups of VirtueMart and see what gets inserted and what is modified.

Manually make the corresponding entry in FA and compare the before and after backups of the FA DB and check what gets inserted and what gets modified.

Now it should be easy to make an sql construct to select from VirtueMart table(s) and then insert into the FA DB. These sqls caan then be made generic with variables as placeholders and used in a php script that handles the necessary insert/update sqls.

1,390

(3 replies, posted in Fixed Assets)

Take a backup of your FA DB and search for your asset code and asset name there. Then check the appropriate reference in FA.

1,391

(7 replies, posted in Setup)

Which direction?
From FA to Virtue Mart or from Virtue Mart to FA ?

DB: Database
Each Database is comprised of tables which in turn is comprised of records which have several fields which are the smallest nuggets of data you can query out.

Would you like to make the master entries in FA and have them sucked into Virtue Mart or the reverse way?

If you had to sell a new item, where would you enter it - FA or Virtue mart? Once the data is entered into one application, the other would have to take it in from there. If you start entering master data in both applications without synching them, it would lead to chaos.

Similarly, the transactional data like daily sales - would you like to have them taken into FA from Virtue Mart or the other way around?

1,392

(7 replies, posted in Setup)

Will FA data need to get populated into VirtueMart or vice-versa? Create views of the write DB's table in the read-only DB's table.

The function get_invoice_range() in the invoice report reporting/rep107.php uses the sql:

SELECT trans.trans_no, trans.reference
FROM 1_debtor_trans trans 
LEFT JOIN 1_voided voided ON trans.type=voided.type AND trans.trans_no=voided.id
WHERE trans.type=10 AND ISNULL(voided.id);

which extracts the invoices to be printed and example of it is:

trans_no    reference
1    001/2017
2    002/2017
3    003/2017
4    004/2017

The function get_customer_trans in sales/includes/db/cust_trans_db.inc uses the sql:

SELECT trans.*, ov_amount+ov_gst+ov_freight+ov_freight_tax+ov_discount AS Total,
    cust.name AS DebtorName, cust.address, 
    cust.curr_code, 
    cust.tax_id,
    trans.prep_amount>0 AS prepaid,
    com.memo_, 
    1_shippers.shipper_name, 
    1_sales_types.sales_type, 
    1_sales_types.tax_included, 
    branch.*, 
    cust.discount, 
    1_tax_groups.name AS tax_group_name, 
    1_tax_groups.id AS tax_group_id 
FROM 1_debtor_trans trans
    LEFT JOIN 1_comments com ON trans.type=com.type AND trans.trans_no=com.id
    LEFT JOIN 1_shippers ON 1_shippers.shipper_id=trans.ship_via, 
    1_debtors_master cust, 
    1_sales_types, 
    1_cust_branch branch, 
    1_tax_groups 
WHERE trans.debtor_no=cust.debtor_no
  AND 1_sales_types.id = trans.tpe
  AND branch.branch_code = trans.branch_code
  AND branch.tax_group_id = 1_tax_groups.id;

The delivery date is in another record (type=13) and not in the invoice record (type=10).

1,394

(4 replies, posted in Setup)

Take a data dump of your FA database from phpMyAdmin directly if you are not able to benefit from the instructions in my previous post.

1,395

(3 replies, posted in Fixed Assets)

Ensure that the fixed asset you wish to delete does not have any transactions in FA first.

1,396

(17 replies, posted in Reporting)

If this info is for all customers - add signature in the file reporting/includes/header2.inc

This will apply for all reports that use the header2.inc file if the "if" statement is removed in the succeeding bulleted point.

Make an extension to implement this ether with a sys_prefs flag to toggle the functionality or have an option in the report request form as a parameter. ST_CUSTDELIVERY (13) in gl_trans table has the trans_date as the delivery date.

1,398

(82 replies, posted in FA Modifications)

JQuery can be an extension by itself. Other extensions can then depend on this or install it as a pre-requisite where absent with an alert.

An extension with a separate table should be designed and a page showing undelivered items and their client/order details should be presented to select from to make a delivery schedule. The order will be qualified with a delivery schedule ID to make it a primary key in it. On delivery, separate delivery orders would get created from this combination uniquely.

Short of this, make a separate delivery application and then import into FA by studying the DB Anatomy of a Delivery Order in FA.

1,400

(17 replies, posted in Reporting)

Refer the Wiki under the Report Signature para.