/** * This function is used to show the currency * * * @return string */ function displayEnabledCurrencies() { $sql = "SELECT a.id,a.currency_name,a.currency_code,a.currency_tocken,a.default_currency,b.cou_name as country_name FROM currency_master_table a, country_table b WHERE a.status=1 AND a.country_code=b.cou_code"; $obj = new Bin_Query(); $obj->executeQuery($sql); return Display_DCurrencySettings::displayEnabledCurrencies($obj->records); }
/** * Function displays the selected currency for updation * * @param array $Err * @return string */ function showEditCurrency($Err) { $sqlCat = "SELECT * FROM country_table ORDER BY cou_name"; $queryCat = new Bin_Query(); $queryCat->executeQuery($sqlCat); $sqlCat1 = "SELECT * FROM currency_codes_table ORDER BY currency_name"; $queryCat1 = new Bin_Query(); $queryCat1->executeQuery($sqlCat1); if (isset($_GET['cid'])) { $currencyid = trim($_GET['cid']); $sql = "select id as hidecurrencyid,currency_name,currency_code,currency_tocken,status from currency_master_table where id={$currencyid}"; $qry = new Bin_Query(); $qry->executeQuery($sql); return Display_DCurrencySettings::showEditCurrency($queryCat->records, $queryCat1->records, $qry->records, $Err); } else { return '<div class="alert alert-error"> <button type="button" class="close" data-dismiss="alert">×</button> No more currency.</div>'; } }