mirror of
https://github.com/Sarjuuk/aowow.git
synced 2025-11-29 15:58:16 +08:00
* GameObjects: initial implementation (some filter missing; positions not yet availabe; some custom data to be set; required table will be added later) * MiscTools: fixed random page; 'implemented' missing Screenshots; fixed access to template file * Search: implemented check for CUSTOM_EXCLUDE_FOR_LISTVIEW if user is not in U_GROUP_STAFF; searches should now be cachable * NPCs: three more tabs on detailPage * some work against Quests * fighting the template-system :<
53 lines
1.4 KiB
PHP
53 lines
1.4 KiB
PHP
<?php
|
|
|
|
if (!defined('AOWOW_REVISION'))
|
|
die('illegal access');
|
|
|
|
|
|
class CurrencyList extends BaseType
|
|
{
|
|
public static $type = TYPE_CURRENCY;
|
|
public static $brickFile = 'currency';
|
|
|
|
protected $queryBase = 'SELECT *, id AS ARRAY_KEY FROM ?_currencies c';
|
|
|
|
public function getListviewData()
|
|
{
|
|
$data = [];
|
|
|
|
foreach ($this->iterate() as $__)
|
|
{
|
|
$data[$this->id] = array(
|
|
'id' => $this->id,
|
|
'category' => $this->curTpl['category'],
|
|
'name' => $this->getField('name', true),
|
|
'icon' => $this->curTpl['iconString']
|
|
);
|
|
}
|
|
|
|
return $data;
|
|
}
|
|
|
|
public function addGlobalsToJscript(&$template, $addMask = 0)
|
|
{
|
|
foreach ($this->iterate() as $__)
|
|
{
|
|
if ($this->id == 104) // in case of honor commit sebbuku
|
|
$icon = ['alliance-icon', 'horde-icon'];
|
|
else if ($this->id == 103) // also arena-icon diffs from item-icon
|
|
$icon = ['money_arena', 'money_arena'];
|
|
else
|
|
$icon = [$this->curTpl['iconString'], $this->curTpl['iconString']];
|
|
|
|
$template->extendGlobalData(self::$type, [$this->id => array(
|
|
'name' => $this->getField('name', true),
|
|
'icon' => $icon
|
|
)]);
|
|
}
|
|
}
|
|
|
|
public function renderTooltip() { }
|
|
}
|
|
|
|
?>
|