echo "<br><br><br>";
echo "OPD:&nbsp;" . number_format($ro3->showPFaccounts_total() + $ro3->_opd_totalz() + $otTotal + $stTotal, 2);
echo "<Br>";
echo "IPD:&nbsp;" . number_format($ro3->showAllAccountTitle_ipd_total(), 2);
echo "<br>";
echo "<a href='#' id='totalLink' style='text-decoration:none; color:black'>Total:&nbsp;" . number_format($ro3->showPFaccounts_total() + $ro3->_opd_totalz() + $otTotal + $stTotal + $ro3->showAllAccountTitle_ipd_total(), 2) . "</a>";
//for original transaction summary format
$opd_creditCard = $ro3->showAllAccountTitle_opd_creditCard() + $ro3->showPFAccounts_creditCard_totalCard() + $otCreditCard + $stCreditCard;
$opd_cash = $ro3->showAllAccountTitle_opd_cash() + $ro3->showPFaccounts_cash() + $otCash + $stCash;
$opd_hmo = $ro3->showAllAccountTitle_opd_hmo() + $ro3->showPFaccounts_hmo() + $otHMO + $stHMO;
$opd_phic = $ro3->showAllAccountTitle_opd_phic() + $ro3->showPFaccounts_phic() + $otPHIC + $stPHIC;
$opd_unpaid = $ro3->showAllAccountTitle_opd_unpaid() + $ro3->showPFaccounts_unpaid() + $otUnpaid + $stUnpaid;
$opd_discount = $ro3->showAllAccountTitle_opd_discount() + $ro3->showPFaccounts_discount() + $otDiscount + $stDiscount;
$opd_paidBalance = $ro3->showAllAccountTitle_opd_balancePaid();
$opd_PF_total = $ro3->showPFaccounts_total();
$opd_PF_hospitalShare = $ro3->showPFaccounts_unpaid() + $ro3->showPFaccounts_cash() + $ro3->showPFaccounts_creditCards() + $ro3->showPFaccounts_phic() + $ro3->showPFaccounts_hmo() + $ro3->showPFaccounts_discount();
$opd_PF_creditCard = $ro3->showPFaccounts_creditCards();
$opd_PF_payable = $ro3->showPFaccounts_payable();
$opd_ecg = $ro3->showAllAccountTitle_opd_ecg();
$opd_xray = $ro3->showAllAccountTitle_opd_xray();
$opd_ultrasound = $ro3->showAllAccountTitle_opd_ultrasound();
$opd_erFee = $ro3->showAllAccountTitle_opd_erFee();
$opd_nursery = $ro3->showAllAccountTitle_opd_nursery();
$opd_rehab = $ro3->showAllAccountTitle_opd_rehab();
$opd_ctscan = $ro3->showAllAccountTitle_opd_ctscan();
$opd_laboratory = $ro3->showAllAccountTitle_opd_laboratory();
$opd_medicine = $ro3->showAllAccountTitle_opd_medicine();
$opd_supplies = $ro3->showAllAccountTitle_opd_supplies();
$opd_spyrometry = $ro3->showAllAccountTitle_opd_spyrometry();
$opd_derma = $ro3->showAllAccountTitle_opd_derma();
$opd_others = $ro3->showAllAccountTitle_opd_others();
echo "OPD:&nbsp;" . number_format($ro->showPFaccounts_total() + $ro->_opd_totalz() + $otTotal + $stTotal, 2);
echo "<Br>";
echo "IPD:&nbsp;" . number_format($ro->showAllAccountTitle_ipd_total(), 2);
echo "<br>";
echo "<a href='#' id='totalLink' style='text-decoration:none; color:black'>Total:&nbsp;" . number_format($ro->showPFaccounts_total() + $ro->_opd_totalz() + $otTotal + $stTotal + $ro->showAllAccountTitle_ipd_total(), 2) . "</a>";
//for original transaction summary format
$opd_creditCard = $ro->showAllAccountTitle_opd_creditCard() + $ro->showPFAccounts_creditCard_totalCard() + $otCreditCard + $stCreditCard;
$opd_cash = $ro->showAllAccountTitle_opd_cash() + $ro->showPFaccounts_cash() + $otCash + $stCash + $ro->showPFaccounts_pf() + $otShare + $stShare;
$opd_hmo = $ro->showAllAccountTitle_opd_hmo() + $ro->showPFaccounts_hmo() + $otHMO + $stHMO;
$opd_phic = $ro->showAllAccountTitle_opd_phic() + $ro->showPFaccounts_phic() + $otPHIC + $stPHIC;
$opd_unpaid = $ro->showAllAccountTitle_opd_unpaid() + $ro->showPFaccounts_unpaid() + $otUnpaid + $stUnpaid;
$opd_discount = $ro->showAllAccountTitle_opd_discount() + $ro->showPFaccounts_discount() + $otDiscount + $stDiscount;
$opd_paidBalance = $ro->showAllAccountTitle_opd_balancePaid();
$opd_PF_total = $ro->showPFaccounts_total();
$opd_PF_hospitalShare = $ro->showPFaccounts_cash();
$opd_PF_creditCard = $ro->showPFaccounts_creditCards();
$opd_PF_payable = $ro->showPFaccounts_payable();
$opd_ecg = $ro->showAllAccountTitle_opd_ecg();
$opd_xray = $ro->showAllAccountTitle_opd_xray();
$opd_ultrasound = $ro->showAllAccountTitle_opd_ultrasound();
$opd_erFee = $ro->showAllAccountTitle_opd_erFee();
$opd_ctscan = $ro->showAllAccountTitle_opd_ctscan();
$opd_laboratory = $ro->showAllAccountTitle_opd_laboratory();
$opd_medicine = $ro->showAllAccountTitle_opd_medicine();
$opd_supplies = $ro->showAllAccountTitle_opd_supplies();
$opd_spyrometry = $ro->showAllAccountTitle_opd_spyrometry();
$opd_derma = $ro->showAllAccountTitle_opd_derma();
$opd_others = $ro->showAllAccountTitle_opd_others();
$opd_OR = $ro->showAllAccountTitle_opd_OR();
$opd_PT = $ro->showAllAccountTitle_opd_PT();
$opd_OT = $otTotal;