mirror of
https://github.com/Sarjuuk/aowow.git
synced 2025-11-29 15:58:16 +08:00
Implemented new type: mail
* display and link clientside mails to other types and events * fixed favorites menu for new types * fixed sorting column triggered spells in enchantment listview * some misc cleanups
This commit is contained in:
46
pages/mails.php
Normal file
46
pages/mails.php
Normal file
@@ -0,0 +1,46 @@
|
||||
<?php
|
||||
|
||||
if (!defined('AOWOW_REVISION'))
|
||||
die('illegal access');
|
||||
|
||||
|
||||
// menuId 103: Mail g_initPath()
|
||||
// tabid 0: Database g_initHeader()
|
||||
class MailsPage extends GenericPage
|
||||
{
|
||||
use TrListPage;
|
||||
|
||||
protected $type = TYPE_MAIL;
|
||||
protected $tpl = 'list-page-generic';
|
||||
protected $path = [0, 103];
|
||||
protected $tabId = 0;
|
||||
protected $mode = CACHE_TYPE_PAGE;
|
||||
|
||||
public function __construct($pageCall, $pageParam)
|
||||
{
|
||||
parent::__construct($pageCall, $pageParam);
|
||||
|
||||
$this->name = Util::ucFirst(Lang::game('mails'));
|
||||
}
|
||||
|
||||
protected function generateContent()
|
||||
{
|
||||
$tabData = [];
|
||||
$mails = new MailList();
|
||||
if (!$mails->error)
|
||||
$tabData['data'] = array_values($mails->getListviewData());
|
||||
|
||||
$this->extendGlobalData($mails->getJsGlobals());
|
||||
|
||||
$this->lvTabs[] = ['mail', $tabData, 'mail'];
|
||||
}
|
||||
|
||||
protected function generateTitle()
|
||||
{
|
||||
array_unshift($this->title, $this->name);
|
||||
}
|
||||
|
||||
protected function generatePath() { }
|
||||
}
|
||||
|
||||
?>
|
||||
Reference in New Issue
Block a user