ILIAS  Release_4_0_x_branch Revision 61816
 All Data Structures Namespaces Files Functions Variables Groups Pages
ilPaymentCurrency Class Reference
+ Collaboration diagram for ilPaymentCurrency:

Public Member Functions

 _getAvailableCurrencies ()
 _getCurrency ($a_currency_id)
 _getUnit ($a_currency_id)
 _getSubUnit ($a_currency_id)

Detailed Description

Definition at line 31 of file class.ilPaymentCurrency.php.

Member Function Documentation

ilPaymentCurrency::_getAvailableCurrencies ( )

Definition at line 33 of file class.ilPaymentCurrency.php.

References $ilDB, $res, and $row.

Referenced by ilPaymentObjectGUI\performAddPrice(), and ilObjPaymentSettingsGUI\performAddPriceObject().

{
global $ilDB;
$res = $ilDB->query('SELECT * FROM payment_currencies');
while($row = $ilDB->fetchObject($res))
{
$currencies[$row->currency_id]['currency_id'] = $row->currency_id;
$currencies[$row->currency_id]['unit'] = $row->unit;
$currencies[$row->currency_id]['subunit'] = $row->subunit;
}
return $currencies ? $currencies : array();
}

+ Here is the caller graph for this function:

ilPaymentCurrency::_getCurrency (   $a_currency_id)

Definition at line 48 of file class.ilPaymentCurrency.php.

References $ilDB, $res, and $row.

Referenced by ilPaymentObjectGUI\editPrices(), and ilObjPaymentSettingsGUI\editPricesObject().

{
global $ilDB;
$res = $ilDB->queryf('
SELECT * FROM payment_currencies WHERE currency_id = %s',
array('integer'), array($a_currency_id));
while($row = $ilDB->fetchObject($res))
{
$currencies['currency_id'] = $row->currency_id;
$currencies['unit'] = $row->unit;
$currencies['sub_unit'] = $row->subunit;
}
return $currencies;
}

+ Here is the caller graph for this function:

ilPaymentCurrency::_getSubUnit (   $a_currency_id)

Definition at line 79 of file class.ilPaymentCurrency.php.

References $ilDB, $res, and $row.

{
global $ilDB;
$statement = $ilDB->queryf('
SELECT subunit FROM payment_currencies WHERE currency_id = %s',
array('integer'), array($a_currency_id));
while($row = $ilDB->fetchObject($res))
{
return $row->subunit;
}
return false;
}
ilPaymentCurrency::_getUnit (   $a_currency_id)

Definition at line 65 of file class.ilPaymentCurrency.php.

References $ilDB, $res, and $row.

{
global $ilDB;
$res = $ilDB->queryf('
SELECT unit FROM payment_currencies WHERE currency_id = %s',
array('integer'), array($a_currency_id));
while($row = $ilDB->fetchObject($res))
{
return $row->unit;
}
return false;
}

The documentation for this class was generated from the following file: