implement Quests for Character groups (-groups)
This commit is contained in:
parent
3d82dd7297
commit
3517d6d0ed
8 changed files with 364 additions and 23 deletions
35
agents/intermediate/CharactergroupsquestsAgent.inc
Normal file
35
agents/intermediate/CharactergroupsquestsAgent.inc
Normal file
|
|
@ -0,0 +1,35 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The Legend of Z
|
||||||
|
*
|
||||||
|
* @author Oliver Hanraths <oliver.hanraths@uni-duesseldorf.de>
|
||||||
|
* @copyright 2014 Heinrich-Heine-Universität Düsseldorf
|
||||||
|
* @license http://www.gnu.org/licenses/gpl.html
|
||||||
|
* @link https://bitbucket.org/coderkun/the-legend-of-z
|
||||||
|
*/
|
||||||
|
|
||||||
|
namespace hhu\z\agents\intermediate;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Agent to display Character groups Quests.
|
||||||
|
*
|
||||||
|
* @author Oliver Hanraths <oliver.hanraths@uni-duesseldorf.de>
|
||||||
|
*/
|
||||||
|
class CharactergroupsquestsAgent extends \nre\agents\IntermediateAgent
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Action: index.
|
||||||
|
*/
|
||||||
|
public function index(\nre\core\Request $request, \nre\core\Response $response)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
?>
|
||||||
|
|
@ -71,20 +71,21 @@
|
||||||
* @var array
|
* @var array
|
||||||
*/
|
*/
|
||||||
public static $routes = array(
|
public static $routes = array(
|
||||||
array('css/?(.*)', 'css/$1?layout=stylesheet', true),
|
array('css/?(.*)', 'css/$1?layout=stylesheet', true),
|
||||||
array('users/([^/]+)/(edit|delete)', 'users/$2/$1', true),
|
array('users/([^/]+)/(edit|delete)', 'users/$2/$1', true),
|
||||||
array('users/(?!(index|login|logout|create|edit|delete))', 'users/user/$1', true),
|
array('users/(?!(index|login|logout|create|edit|delete))', 'users/user/$1', true),
|
||||||
array('seminaries/([^/]+)/(edit|delete)', 'seminaries/$2/$1', true),
|
array('seminaries/([^/]+)/(edit|delete)', 'seminaries/$2/$1', true),
|
||||||
array('seminaries/(?!(index|create|edit|delete))', 'seminaries/seminary/$1', true),
|
array('seminaries/(?!(index|create|edit|delete))', 'seminaries/seminary/$1', true),
|
||||||
/*// z/<Seminary> ⇒ z/seminaries/seminary/<Seminary>
|
/*// z/<Seminary> ⇒ z/seminaries/seminary/<Seminary>
|
||||||
array('^([^/]+)/*$', 'seminaries/seminary/$1', true),
|
array('^([^/]+)/*$', 'seminaries/seminary/$1', true),
|
||||||
// z/<Seminary>/<Questgroup> ⇒ z/questgroups/questgroup/<Seminary>/<Questgroup>
|
// z/<Seminary>/<Questgroup> ⇒ z/questgroups/questgroup/<Seminary>/<Questgroup>
|
||||||
array('^([^/]+)/([^/]+)/?$', 'questgropus/questgroup/$1/$2', true),
|
array('^([^/]+)/([^/]+)/?$', 'questgropus/questgroup/$1/$2', true),
|
||||||
// z/<Seminary>/<Questgroup>/<Quest> ⇒ z/quests/quest/<Seminary>/<Questgroup>/<Quest>
|
// z/<Seminary>/<Questgroup>/<Quest> ⇒ z/quests/quest/<Seminary>/<Questgroup>/<Quest>
|
||||||
array('^([^/]+)/([^/]+)/([^/]+)/?$', 'quests/quest/$1/$2/3', true)*/
|
array('^([^/]+)/([^/]+)/([^/]+)/?$', 'quests/quest/$1/$2/3', true)*/
|
||||||
array('charactergroups/(?!(index|groupsgroup|group))', 'charactergroups/index/$1', true),
|
array('charactergroups/(?!(index|groupsgroup|group))', 'charactergroups/index/$1', true),
|
||||||
array('media/(.*)', 'media/$1?layout=binary', false),
|
array('charactergroupsquests/(?!(quest))', 'charactergroupsquests/quest/$1', true),
|
||||||
array('media/(.*)', 'media/index/$1', true)
|
array('media/(.*)', 'media/$1?layout=binary', false),
|
||||||
|
array('media/(.*)', 'media/index/$1', true)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -95,12 +96,13 @@
|
||||||
* @var array
|
* @var array
|
||||||
*/
|
*/
|
||||||
public static $reverseRoutes = array(
|
public static $reverseRoutes = array(
|
||||||
array('users/user/(.*)', 'users/$1', true),
|
array('users/user/(.*)', 'users/$1', true),
|
||||||
array('users/([^/]+)/(.*)', 'users/$2/$1', true),
|
array('users/([^/]+)/(.*)', 'users/$2/$1', true),
|
||||||
array('seminaries/seminary/(.*)', 'seminaries/$1', false),
|
array('seminaries/seminary/(.*)', 'seminaries/$1', false),
|
||||||
//array('seminaries/seminary/(.*)', '$1', false)
|
//array('seminaries/seminary/(.*)', '$1', false)
|
||||||
array('charactergroup/index/(.*)', 'charactergroup/$1', true),
|
array('charactergroup/index/(.*)', 'charactergroup/$1', true),
|
||||||
array('media/index/(.*)', 'media/$1', true)
|
array('charactergroupsquests/quest/(.*)', 'charactergroupsquests/$1', true),
|
||||||
|
array('media/index/(.*)', 'media/$1', true)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,7 @@
|
||||||
*
|
*
|
||||||
* @var array
|
* @var array
|
||||||
*/
|
*/
|
||||||
public $models = array('seminaries', 'charactergroups');
|
public $models = array('seminaries', 'charactergroups', 'charactergroupsquests');
|
||||||
/**
|
/**
|
||||||
* User permissions
|
* User permissions
|
||||||
*
|
*
|
||||||
|
|
@ -89,11 +89,15 @@
|
||||||
// Get Character groups
|
// Get Character groups
|
||||||
$groups = $this->Charactergroups->getGroupsForGroupsgroup($groupsgroup['id']);
|
$groups = $this->Charactergroups->getGroupsForGroupsgroup($groupsgroup['id']);
|
||||||
|
|
||||||
|
// Get Character groups-group Quests
|
||||||
|
$quests = $this->Charactergroupsquests->getQuestsForCharactergroupsgroup($groupsgroup['id']);
|
||||||
|
|
||||||
|
|
||||||
// Pass data to view
|
// Pass data to view
|
||||||
$this->set('seminary', $seminary);
|
$this->set('seminary', $seminary);
|
||||||
$this->set('groupsgroup', $groupsgroup);
|
$this->set('groupsgroup', $groupsgroup);
|
||||||
$this->set('groups', $groups);
|
$this->set('groups', $groups);
|
||||||
|
$this->set('quests', $quests);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -119,11 +123,15 @@
|
||||||
// Get Character group
|
// Get Character group
|
||||||
$group = $this->Charactergroups->getGroupByUrl($groupsgroup['id'], $groupUrl);
|
$group = $this->Charactergroups->getGroupByUrl($groupsgroup['id'], $groupUrl);
|
||||||
|
|
||||||
|
// Get Character groups Quests
|
||||||
|
$quests = $this->Charactergroupsquests->getQuestsForGroup($group['id']);
|
||||||
|
|
||||||
|
|
||||||
// Pass data to view
|
// Pass data to view
|
||||||
$this->set('seminary', $seminary);
|
$this->set('seminary', $seminary);
|
||||||
$this->set('groupsgroup', $groupsgroup);
|
$this->set('groupsgroup', $groupsgroup);
|
||||||
$this->set('group', $group);
|
$this->set('group', $group);
|
||||||
|
$this->set('quests', $quests);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
91
controllers/CharactergroupsquestsController.inc
Normal file
91
controllers/CharactergroupsquestsController.inc
Normal file
|
|
@ -0,0 +1,91 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The Legend of Z
|
||||||
|
*
|
||||||
|
* @author Oliver Hanraths <oliver.hanraths@uni-duesseldorf.de>
|
||||||
|
* @copyright 2014 Heinrich-Heine-Universität Düsseldorf
|
||||||
|
* @license http://www.gnu.org/licenses/gpl.html
|
||||||
|
* @link https://bitbucket.org/coderkun/the-legend-of-z
|
||||||
|
*/
|
||||||
|
|
||||||
|
namespace hhu\z\controllers;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Controller of the CharactergroupsquestsAgent to display Character
|
||||||
|
* groups Quests.
|
||||||
|
*
|
||||||
|
* @author Oliver Hanraths <oliver.hanraths@uni-duesseldorf.de>
|
||||||
|
*/
|
||||||
|
class CharactergroupsquestsController extends \hhu\z\controllers\SeminaryRoleController
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* Required models
|
||||||
|
*
|
||||||
|
* @var array
|
||||||
|
*/
|
||||||
|
public $models = array('seminaries', 'charactergroups', 'charactergroupsquests', 'media');
|
||||||
|
/**
|
||||||
|
* User permissions
|
||||||
|
*
|
||||||
|
* @var array
|
||||||
|
*/
|
||||||
|
public $permissions = array(
|
||||||
|
'quest' => array('admin', 'moderator', 'user')
|
||||||
|
);
|
||||||
|
/**
|
||||||
|
* User seminary permissions
|
||||||
|
*
|
||||||
|
* @var array
|
||||||
|
*/
|
||||||
|
public $seminaryPermissions = array(
|
||||||
|
'quest' => array('admin', 'moderator', 'user')
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Action: quest.
|
||||||
|
*
|
||||||
|
* Show a Character groups Quest for a Character groups-group
|
||||||
|
* of a Seminary.
|
||||||
|
*
|
||||||
|
* @throws IdNotFoundException
|
||||||
|
* @param string $seminaryUrl URL-Title of a Seminary
|
||||||
|
* @param string $groupsgroupUrl URL-Title of a Character groups-group
|
||||||
|
* @param string $questUrl URL-Title of a Character groups Quest
|
||||||
|
*/
|
||||||
|
public function quest($seminaryUrl, $groupsgroupUrl, $questUrl)
|
||||||
|
{
|
||||||
|
// Get seminary
|
||||||
|
$seminary = $this->Seminaries->getSeminaryByUrl($seminaryUrl);
|
||||||
|
|
||||||
|
// Get Character groups-group
|
||||||
|
$groupsgroup = $this->Charactergroups->getGroupsgroupByUrl($seminary['id'], $groupsgroupUrl);
|
||||||
|
|
||||||
|
// Get Character groups-group Quests
|
||||||
|
$quest = $this->Charactergroupsquests->getQuestByUrl($groupsgroup['id'], $questUrl);
|
||||||
|
|
||||||
|
// Get Character groups-groups
|
||||||
|
$groups = $this->Charactergroupsquests->getGroupsForQuest($quest['id']);
|
||||||
|
|
||||||
|
// Media
|
||||||
|
$questmedia = null;
|
||||||
|
if(!is_null($quest['questsmedia_id'])) {
|
||||||
|
$questmedia = $this->Media->getMediaById($quest['questsmedia_id']);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// Pass data to view
|
||||||
|
$this->set('seminary', $seminary);
|
||||||
|
$this->set('groupsgroup', $groupsgroup);
|
||||||
|
$this->set('quest', $quest);
|
||||||
|
$this->set('groups', $groups);
|
||||||
|
$this->set('media', $questmedia);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
?>
|
||||||
136
models/CharactergroupsquestsModel.inc
Normal file
136
models/CharactergroupsquestsModel.inc
Normal file
|
|
@ -0,0 +1,136 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The Legend of Z
|
||||||
|
*
|
||||||
|
* @author Oliver Hanraths <oliver.hanraths@uni-duesseldorf.de>
|
||||||
|
* @copyright 2014 Heinrich-Heine-Universität Düsseldorf
|
||||||
|
* @license http://www.gnu.org/licenses/gpl.html
|
||||||
|
* @link https://bitbucket.org/coderkun/the-legend-of-z
|
||||||
|
*/
|
||||||
|
|
||||||
|
namespace hhu\z\models;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Model of the CharactergroupsquestsAgent to interact with
|
||||||
|
* Charactergroupsquests-table.
|
||||||
|
*
|
||||||
|
* @author Oliver Hanraths <oliver.hanraths@uni-duesseldorf.de>
|
||||||
|
*/
|
||||||
|
class CharactergroupsquestsModel extends \hhu\z\Model
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Construct a new CharactergroupsquestsModel.
|
||||||
|
*/
|
||||||
|
public function __construct()
|
||||||
|
{
|
||||||
|
parent::__construct();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get Character groups Quests of a Character groups-groups.
|
||||||
|
*
|
||||||
|
* @param int $groupsgroupId ID of the Character groups-group
|
||||||
|
* @return array Character groups Quest data
|
||||||
|
*/
|
||||||
|
public function getQuestsForCharactergroupsgroup($groupsgroupId)
|
||||||
|
{
|
||||||
|
return $this->db->query(
|
||||||
|
'SELECT id, questgroups_id, title, url '.
|
||||||
|
'FROM charactergroupsquests '.
|
||||||
|
'WHERE charactergroupsgroup_id = ?',
|
||||||
|
'i',
|
||||||
|
$groupsgroupId
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get a Character groups Quest by its URL.
|
||||||
|
*
|
||||||
|
* @throws IdNotFoundException
|
||||||
|
* @param int $groupsgroupId ID of the Character groups-group
|
||||||
|
* @param string $questUrl URL-title of the Character groups Quest
|
||||||
|
* @return array Character groups Quest data
|
||||||
|
*/
|
||||||
|
public function getQuestByUrl($groupsgroupId, $questUrl)
|
||||||
|
{
|
||||||
|
$data = $this->db->query(
|
||||||
|
'SELECT id, questgroups_id, title, url, description, xps, rules, won_text, lost_text, questsmedia_id '.
|
||||||
|
'FROM charactergroupsquests '.
|
||||||
|
'WHERE charactergroupsgroup_id = ? AND url = ?',
|
||||||
|
'is',
|
||||||
|
$groupsgroupId,
|
||||||
|
$questUrl
|
||||||
|
);
|
||||||
|
if(empty($data)) {
|
||||||
|
throw new \nre\exceptions\IdNotFoundException($questUrl);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
return $data[0];
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the Character groups for a Quest.
|
||||||
|
*
|
||||||
|
* @param int $questId ID of the Character groups Quest
|
||||||
|
* @return array Character groups
|
||||||
|
*/
|
||||||
|
public function getGroupsForQuest($questId)
|
||||||
|
{
|
||||||
|
$groups = $this->db->query(
|
||||||
|
'SELECT charactergroups.id, charactergroups.name, charactergroups.url, charactergroupsquests_groups.created, charactergroupsquests_groups.xps_factor, charactergroupsquests.xps '.
|
||||||
|
'FROM charactergroupsquests_groups '.
|
||||||
|
'LEFT JOIN charactergroups ON charactergroups.id = charactergroupsquests_groups.charactergroup_id '.
|
||||||
|
'LEFT JOIN charactergroupsquests ON charactergroupsquests.id = charactergroupsquests_groups.charactergroupsquest_id '.
|
||||||
|
'WHERE charactergroupsquests_groups.charactergroupsquest_id = ?',
|
||||||
|
'i',
|
||||||
|
$questId
|
||||||
|
);
|
||||||
|
foreach($groups as &$group) {
|
||||||
|
$group['xps'] = round($group['xps'] * $group['xps_factor'], 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
return $groups;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get Character groups Quests for a Character group.
|
||||||
|
*
|
||||||
|
* @param int $groupId ID of the Character group
|
||||||
|
* @return array Character groups Quests
|
||||||
|
*/
|
||||||
|
public function getQuestsForGroup($groupId)
|
||||||
|
{
|
||||||
|
$quests = $this->db->query(
|
||||||
|
'SELECT charactergroupsquests.id, charactergroupsquests_groups.created, charactergroupsquests.title, charactergroupsquests.url, charactergroupsquests.xps, charactergroupsquests_groups.xps_factor '.
|
||||||
|
'FROM charactergroupsquests_groups '.
|
||||||
|
'LEFT JOIN charactergroupsquests ON charactergroupsquests.id = charactergroupsquests_groups.charactergroupsquest_id '.
|
||||||
|
'WHERE charactergroupsquests_groups.charactergroup_id = ?',
|
||||||
|
'i',
|
||||||
|
$groupId
|
||||||
|
);
|
||||||
|
foreach($quests as &$quest) {
|
||||||
|
$quest['group_xps'] = round($quest['xps'] * $quest['xps_factor'], 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
return $quests;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
?>
|
||||||
|
|
@ -1,5 +1,20 @@
|
||||||
<h1><?=_('Seminaries')?></h1>
|
<h1><?=_('Seminaries')?></h1>
|
||||||
<h2><?=$seminary['title']?></h2>
|
<h2><?=$seminary['title']?></h2>
|
||||||
<h3><?=_('Character Groups')?></h3>
|
<h3><a href="<?=$linker->link(array('index',$seminary['url']),1)?>"><?=_('Character Groups')?></a></h3>
|
||||||
<h4><?=$groupsgroup['name']?></h4>
|
<h4><a href="<?=$linker->link(array('groupsgroup',$seminary['url'],$groupsgroup['url']),1)?>"><?=$groupsgroup['name']?></a></h4>
|
||||||
<h5><?=$group['name']?></h5>
|
<h5><?=$group['name']?></h5>
|
||||||
|
|
||||||
|
<section>
|
||||||
|
<h1><?=_('Quests')?></h1>
|
||||||
|
<table>
|
||||||
|
<tbody>
|
||||||
|
<?php foreach($quests as &$quest) : ?>
|
||||||
|
<tr>
|
||||||
|
<td><?=$dateFormatter->format(new \DateTime($quest['created']))?></td>
|
||||||
|
<td><a href="<?=$linker->link(array('charactergroupsquests','quest',$seminary['url'],$groupsgroup['url'],$quest['url']))?>"><?=$quest['title']?></a></td>
|
||||||
|
<td><?=$quest['group_xps']?>/<?=$quest['xps']?> XPs</td>
|
||||||
|
</tr>
|
||||||
|
<?php endforeach ?>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</section>
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
<h1><?=_('Seminaries')?></h1>
|
<h1><?=_('Seminaries')?></h1>
|
||||||
<h2><?=$seminary['title']?></h2>
|
<h2><?=$seminary['title']?></h2>
|
||||||
<h3><?=_('Character Groups')?></h3>
|
<h3><a href="<?=$linker->link(array('index',$seminary['url']),1)?>"><?=_('Character Groups')?></a></h3>
|
||||||
<h4><?=$groupsgroup['name']?></h4>
|
<h4><?=$groupsgroup['name']?></h4>
|
||||||
|
|
||||||
<ul>
|
<ul>
|
||||||
|
|
@ -8,3 +8,11 @@
|
||||||
<li><a href="<?=$linker->link(array('group',$seminary['url'],$groupsgroup['url'],$group['url']),1)?>"><?=$group['name']?></a></li>
|
<li><a href="<?=$linker->link(array('group',$seminary['url'],$groupsgroup['url'],$group['url']),1)?>"><?=$group['name']?></a></li>
|
||||||
<?php endforeach ?>
|
<?php endforeach ?>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
|
||||||
|
<h4><?=_('Character Groups Quests')?></h4>
|
||||||
|
<ul>
|
||||||
|
<?php foreach($quests as &$quest) : ?>
|
||||||
|
<li><a href="<?=$linker->link(array('charactergroupsquests','quest',$seminary['url'],$groupsgroup['url'],$quest['url']))?>"><?=$quest['title']?></a></li>
|
||||||
|
<?php endforeach ?>
|
||||||
|
</ul>
|
||||||
|
|
|
||||||
46
views/html/charactergroupsquests/quest.tpl
Normal file
46
views/html/charactergroupsquests/quest.tpl
Normal file
|
|
@ -0,0 +1,46 @@
|
||||||
|
<h1><?=_('Seminaries')?></h1>
|
||||||
|
<h2><?=$seminary['title']?></h2>
|
||||||
|
<h3><?=_('Character Groups Quests')?></h3>
|
||||||
|
<h4><?=$quest['title']?></h4>
|
||||||
|
|
||||||
|
<?php if(!is_null($media)) : ?>
|
||||||
|
<img src="<?=$linker->link(array('media','index',$seminary['url'],$media['url']))?>" />
|
||||||
|
<?php endif ?>
|
||||||
|
|
||||||
|
<section>
|
||||||
|
<p>XPs: <?=$quest['xps']?></p>
|
||||||
|
<h1><?=_('Description')?></h1>
|
||||||
|
<p><?=\hhu\z\Utils::t($quest['description'])?></p>
|
||||||
|
<?php if(!empty($quest['rules'])) : ?>
|
||||||
|
<h1><?=_('Rules')?></h1>
|
||||||
|
<p><?=\hhu\z\Utils::t($quest['rules'])?></p>
|
||||||
|
<?php endif ?>
|
||||||
|
</section>
|
||||||
|
|
||||||
|
<?php if(!empty($quest['von_text'])) : ?>
|
||||||
|
<section>
|
||||||
|
<h1><?=_('Won Quest')?></h1>
|
||||||
|
<p><?=\hhu\z\Utils::t($quest['won_text'])?></p>
|
||||||
|
</section>
|
||||||
|
<?php endif ?>
|
||||||
|
<?php if(!empty($quest['lost_text'])) : ?>
|
||||||
|
<section>
|
||||||
|
<h1><?=_('Lost Quest')?></h1>
|
||||||
|
<p><?=\hhu\z\Utils::t($quest['lost_text'])?></p>
|
||||||
|
</section>
|
||||||
|
<?php endif ?>
|
||||||
|
|
||||||
|
<section>
|
||||||
|
<h1><?=$groupsgroup['name']?></h1>
|
||||||
|
<table>
|
||||||
|
<tbody>
|
||||||
|
<?php foreach($groups as &$group) : ?>
|
||||||
|
<tr>
|
||||||
|
<td><?=$dateFormatter->format(new \DateTime($group['created']))?></td>
|
||||||
|
<td><a href="<?=$linker->link(array('charactergroups','group',$seminary['url'],$groupsgroup['url'],$group['url']))?>"><?=$group['name']?></a></td>
|
||||||
|
<td><?=$group['xps']?>/<?=$quest['xps']?> XPs</td>
|
||||||
|
</tr>
|
||||||
|
<?php endforeach ?>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</section>
|
||||||
Loading…
Add table
Add a link
Reference in a new issue