426

(6 replies, posted in Reporting)

Oh yes, you are right

427

(6 replies, posted in Reporting)

Oh, Yes I missed that. But I think either this Variable is set to 0 or 1, the result shall be same because the function getAverageCost also returns UnitCost with the same algorithm, the weighted average, which is used to calculate the material_cost stored in stock_master.

This was discussed in detail in the topic mentioned in Post # 2

428

(9 replies, posted in Manufactoring)

Yes, you are right. There is no Estimation System in FA right now.

429

(6 replies, posted in Reporting)

$use_costed_values is not used anywhere in reports in latest FA Versions

It was well discussed in this topic.

Adding following 2 Code Components in gl/includes/db/gl_db_rates.inc Worked

at Line 163

elseif ($provider == 'CCA') //free.currencyconverterapi.com
    {
        $filename = "/api/v5/convert?q={$curr_b}_{$curr_a}&compact=y";
        $site = "free.currencyconverterapi.com";
        $proto = 'https://';

    }

and at Line 240

    elseif ($provider == 'CCA')
    {
        $rates = json_decode($contents, true);
        $val = $rates[$curr_b.'_'.$curr_a]['val'];
      }

and It works for all currencies without fail

https://free.currencyconverterapi.com/api/v5/convert?q=PHP_PKR&compact=y

This Gives Results. Can anyone suggest the Code for this

Is there any solution for PKR as base currency?

@Joe, this fix works fine if the Value in Transaction References is a Not Used Value

But I am facing complaints from some of the clients and I couldn't figure out the reason that after some transactions specially in Bank Payment Entry the Value in Transaction References doesn't increment.

How to Fix this?

434

(6 replies, posted in Development)

Thanks @joe for considering me. However, I am not a good PHP Developer and don't know anything about Javascript. I am basically a financial consultant. I have been trying to Hack FA Code for some of my solutions for my clients. As you have talked about 'Landing Costs'. I think you meant Import Landing Cost. I have developed a simple module for this using Dimensions and Stock Adjustment. What it does is it Divides the Total Cost of Imports using Weighted Average Method to all products in Imports. Thus Adding Value to the Purchase Price of the Product.

Similarly I have developed a Manufacturing Module. The Current Manufacturing Module of FA have two Levels

1. Simple Manufacturing
2. Advance Manufacturing

In Advance Manufacturing, we can't handle a manufacturing process that generates 2 or more Finished Goods. We can input multiple Raw Materials but Finished Good is Single. Anyhow, I didn't like it.

My manufacturing module can be used for Simple as well as Advanced Processes. However it doesn't take into account the Labour and Overhead Costs separately. But it just calculates the per unit cost of each Finished Good Item using Weighted Average Method.

In Both Imports and Manufacturing Process, you need to open a Job in Dimensions of Type 2.

I have linked the Stock Adjustment also with Dimension. So all Raw Material can be Stocked Out in that Job day by day as process moves on.

Similarly all cash expenses can be loaded to that Job.

Once Job is Finished, you process it and all cost of that Job is allocated to each Item in Process.

If you are interested in this then give me email address to send the code to.

Regards.

@joe and @apmuthu,

It is necessary in two scenarios

1. You have more than one data entry operators who are recording bank transactions at the same time. Both have same Next Reference say BP115 on their forms. The person who will commit transaction lately will see the error Transaction Reference Already in Use

2. Even if we have only one Data Entry operator but it happens many times that the next reference stucks and don't increase itself. Then one needs to manually go to Transaction References Page and increase it.

This is my point of view.

Also we need to add following lines in copy_to_cart () function in sales_order_entry.php page

function copy_to_cart()
{
    check_reference($_POST['ref'], $_SESSION['Items']->trans_type, $_SESSION['Items']->trans_no); //added by faisal

I found one problem with this.

In Supplier Invoice and Supplier Credit Notes the name of reference input field is not ref but reference

@davidkumi, @itronics, @joe, @apmuthu

I have a suggestion and I have tested it with many transactions (not all) and it is working

Modify the function check_reference() with following single line change

function check_reference($reference, $trans_type, $trans_no=0, $context=null, $line=null)
{
    global $Refs;

    if (!$Refs->is_valid($reference, $trans_type, $context, $line))
    {
        display_error(_("The entered reference is invalid.")); return false;
    }
    elseif (!$Refs->is_new_reference($reference, $trans_type, $trans_no))
    {
        $_POST['ref'] = $Refs->get_next($trans_type, null, $context); //modified by faisal
        // display_error( _("The entered reference is already in use.")); return false;
    }
    return true;
}

Before applying to my main server I request you all to please authenticate it. I don't know if it conflicts with some other behaviour of FA

439

(1 replies, posted in Installation)

Try Using this API

440

(5 replies, posted in Reporting)

Yes please this is needed.

@Joe,
Please check these reports of 2017 and 2018.

Check the closing balance of 2017 and opening balance of 2018

You will find the difference in Allocated and Outstanding Figures of Closing and Opening Balances.

I hope I could have explained the issue.

Regards.

Customer is QY009 Babjee Traders

You can Login

id: admin
pass: Pakistan1947

To reproduce this open rep101.php
select above customer
Show Balance => No
View report of 2017 whole year
View report of 2018 till date

PS: To understand the problem read the whole thread once again. We were discussing that due to Bank Payment Transaction to customer, the SQL Query shall be adjusted to produce correct results.

Hello @joe, could you check this bug

443

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

@Rmendez why don't you try HRM by @notrinos

@joe, still one problem exists in rep101.php after applying your last commit

Check the same customer's balances with Parameter ShowBalance=>No

First Date Range 1st Jan 2017 till 31 Dec 2017

Note down Charges, Credits, Allocated and Balance Closing figures

Second Date Range 1st Jan 2018 till date

The above closing shall reflect in this opening but there is a difference Opening

445

(4 replies, posted in Setup)

One of my clients data file has grown up to 200 MB. The Backup routine is unable to take its backup.

Is there any alternate way except PHPMyadmin to take backup of such large databases?

Yes it is working. Thanks alot for your time and input.

@joe, I think you have check the supplier side also.

@joe
You are absolutely right, but let me show you the situation with real client's data.

Login Here
id: admin
pass: Pakistan1947

Open customer balances report from 1st Jan 2017 till date
Select customer QY009-BABJEE TRADERS
Set Show Balance = Yes
Note down the Ending Balance = 811,922

Now set the date from 23 NOv 2017 till Date with same parameters.
Now the Ending balance will be = -2,609,707

This is because the Opening Balance is wrong i.e. -2,286,233
that is supposed to be 1,135,467

Because you can see 5 Bank Payment Entries that are made to this customer by client.

BP319, BP426, BP747, BP748, BP749.

My point is that since we can't stop customer to make a Bank Payment to a Customer because option is there in FA.

So we need to adjust our report that shall contain such silly accounting mistakes.

I hope my point is clear now.

@Joe, you are right. This is the most professional way to do it.

But I have many clients who are not professional accountants.

Since in FA, we have an option to make a BankPayment to customer so either this option be disabled to stop users to exercise it OR

we have to make necessary adjustments to make report show the actual balance.

If we don't commit the suggested changes to rep101.php and other such reports the Opening Balance is not showing the correct value.

We can't restrict any user to record a BankPayment to a customer through BankPayment Entry. This happens in practical environment when same party works as a customer or supplier or in any other capacity.

Modifying below statements From Line 35 onwards will fix this issue.

$sql = "SELECT SUM(IF(t.type = ".ST_SALESINVOICE." OR (t.type IN (".ST_JOURNAL." , ".ST_BANKPAYMENT.") AND t.ov_amount>0),
             -abs(t.ov_amount + t.ov_gst + t.ov_freight + t.ov_freight_tax + t.ov_discount), 0)) AS charges,";

$sql .= "SUM(IF(t.type != ".ST_SALESINVOICE." AND NOT(t.type IN (".ST_JOURNAL." , ".ST_BANKPAYMENT.") AND t.ov_amount>0),
             abs(t.ov_amount + t.ov_gst + t.ov_freight + t.ov_freight_tax + t.ov_discount) * -1, 0)) AS credits,";

Please verify it