Change Default Account on Input Work Order Additional Costs Front Accounting
Base on the article Add Parameters on “System and General GL Setup” FrontAccounting, we also want to implement it into the “Work Order Additional Costs” process. This is the way, open file “\manufacturing\work_order_costs.php”, then find code below.
$item = get_item($wo_details['stock_id']);
$r = get_default_bank_account(get_company_pref('curr_default'));
$_POST['cr_acc'] = $r[0];
$_POST['costs'] = price_format(get_post('PaymentType')==WO_OVERHEAD ? $item['overhead_cost'] : $item['labour_cost']);
Then, modified like code below.
$item = get_item($wo_details['stock_id']);
//$r = get_default_bank_account(get_company_pref('curr_default'));
$company_record = get_company_prefs();
//$_POST['cr_acc'] = $r[0];
$_POST['cr_acc'] = get_post('PaymentType')==WO_LABOUR ? $company_record["default_workorder_creditlabour_act"] : $company_record["default_workorder_creditovrhead_act"];
$_POST['costs'] = price_format(get_post('PaymentType')==WO_OVERHEAD ? $item['overhead_cost'] : $item['labour_cost']);
It’s done, and this is the result.
Excellent job, this is great information which is shared by you. This info is meaningful and factual for us to increase our knowledge about it. about accountants for contractors So please always keep sharing this type of information.
ReplyDeleteExcellent you have provided important data for us. It is essential and informative for everyone. Keep posting always. I am very thankful to you. Read more info about Trusted Payroll Service Provider In London
ReplyDelete