include "system.php"; include "menu.php"; include_once 'class/Log.php'; include_once 'class/BPartnerGroup.php'; include_once 'class/SelectCtrl.php'; error_reporting(E_ERROR | E_WARNING | E_PARSE | E_NOTICE); $log = new Log(); $o = new BPartnerGroup(); $s = new XoopsSecurity(); $ctrl = new SelectCtrl(); $orgctrl = ""; $issimbiz = false; if (file_exists("../simbiz/class/AccountsAPI.php")) { include_once "../simbiz/class/SimbizSelectCtrl.inc.php"; $simbizctrl = new SimbizSelectCtrl(); $issimbiz = true; } $action = ""; echo <<<EOF <script type="text/javascript"> function IsNumeric(sText) { var ValidChars = "0123456789.-"; var IsNumber=true; var Char; for (i = 0; i < sText.length && IsNumber == true; i++) { Char = sText.charAt(i);
if ($o->currency_id == "") { $o->currency_id = 0; } $o->accountsfromctrl = $simbizctrl->getSelectAccounts($o->accountsfrom_id, 'Y', "", "accountsfrom_id", ""); //$o->accountstoctrl=$ctrl->getSelectAccounts($o->accountsto_id,'Y',"","accountsto_id",""); $o->currencyctrl = $ctrl->getSelectCurrency($o->currency_id, 'Y'); //$o->bpartnerctrl=$ctrl->getSelectBPartner($o->bpartner_id,'Y'); $o->showSearchForm(); $wherestr = $o->genWhereString(); $o->showPaymentVoucherTable("WHERE f.paymentvoucher_id>0 and f.organization_id={$defaultorganization_id} {$wherestr}", "ORDER BY f.paymentvoucher_no"); break; case "getaccountinfo": include "../simantz/class/SelectCtrl.inc.php"; $ctrl = new SelectCtrl(); include "../simbiz/class/SimbizSelectCtrl.inc.php"; $simbizctrl = new SimbizSelectCtrl(); $accounts_id = $_REQUEST['accounts_id']; echo $simbizctrl->getSelectBPartner(0, 'Y', "", "bpartner_id", " and (creditoraccounts_id ={$accounts_id} or debtoraccounts_id={$accounts_id})"); die; break; case "checkisbank": include "../simbiz/class/Accounts.php"; $acc = new Accounts(); $acc->fetchAccounts($_REQUEST["accounts_id"]); if ($acc->account_type == 4) { echo 1; } else { echo 0; } die; break;
include_once "../simantz/class/SelectCtrl.inc.php"; //include_once 'class/Log.php'; include_once 'class/BPartner.php'; error_reporting(E_ERROR | E_WARNING | E_PARSE | E_NOTICE); include_once "../simantz/class/datepicker/class.datepicker.php"; //include_once "../system/class/Period.php"; $dp = new datepicker($url); $dp->dateFormat = 'Y-m-d'; $log = new Log(); $o = new BPartner(); $s = new XoopsSecurity(); $ctrl = new SelectCtrl(); $orgctrl = ""; if (file_exists("../simbiz/class/AccountsAPI.php")) { include_once "../simbiz/class/SimbizSelectCtrl.inc.php"; $simbizctrl = new SimbizSelectCtrl(); $issimbiz = true; } if (file_exists("../sales/pricelist.php")) { include_once "../warehouse/class/SimERPSelectCtrl.inc.php"; $simerpctrl = new SimERPSelectCtrl(); $issales = true; } if (file_exists("../purchase/pricelist.php")) { include_once "../warehouse/class/SimERPSelectCtrl.inc.php"; $simerpctrl = new SimERPSelectCtrl(); $ispurchase = true; } $action = $_REQUEST['action']; $isaddnew = $_REQUEST['isaddnew']; // get POST/GET data