* Updates

+Added missing images
+Added report viewer as requested by icekis
-Code cleanup

if strict db, need to set spell to null run

ALTER TABLE `myaac_spells` CHANGE `spell` `spell` VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL;
This commit is contained in:
Lee 2018-12-12 19:44:29 +00:00 committed by slawkens
parent 876b1b988a
commit 1b539f82ac
14 changed files with 456 additions and 260 deletions

View File

@ -56,7 +56,7 @@
'book', 'list', 'book', 'list',
'plug', 'user', 'plug', 'user',
'edit', 'gavel', 'edit', 'gavel',
'book', 'edit', 'book', 'wrench', 'edit', 'book', 'book',
); );
$menus = array( $menus = array(
@ -72,10 +72,17 @@
), ),
'Items' => 'items', 'Items' => 'items',
'Tools' => array( 'Tools' => array(
'Notepad' => 'notepad',
'phpinfo' => 'phpinfo', 'phpinfo' => 'phpinfo',
), ),
'Notepad' => 'notepad', 'Editor' => array(
'Logs' => 'logs' 'Accounts' => 'accounts',
'Players' => 'players',
),
'Logs' => array(
'Logs' => 'logs',
'Reports' => 'reports',
),
); );
$i = 0; $i = 0;

View File

@ -14,7 +14,23 @@ class Spells {
private static $spellsList = null; private static $spellsList = null;
private static $lastError = ''; private static $lastError = '';
public static function loadFromXML($show = false) { // 1 - attack, 2 - healing, 3 - summon, 4 - supply, 5 - support
public static function loadGroup($tGroup) {
switch ($tGroup) {
case "attack":
return 1;
case "healing":
return 2;
case "summon":
return 3;
case "supply":
return 4;
case "support":
return 5;
}
}
public static function loadFromXML($show = false) {
global $config, $db; global $config, $db;
try { $db->query('DELETE FROM `' . TABLE_PREFIX . 'spells`;'); } catch(PDOException $error) {} try { $db->query('DELETE FROM `' . TABLE_PREFIX . 'spells`;'); } catch(PDOException $error) {}
@ -58,6 +74,8 @@ class Spells {
'premium' => $spell->isPremium() ? 1 : 0, 'premium' => $spell->isPremium() ? 1 : 0,
'vocations' => json_encode($spell->getVocations()), 'vocations' => json_encode($spell->getVocations()),
'conjure_count' => $spell->getConjureCount(), 'conjure_count' => $spell->getConjureCount(),
'conjure_id' => $spell->getConjureId(),
'reagent' => $spell->getReagentId(),
'hidden' => $spell->isEnabled() ? 0 : 1 'hidden' => $spell->isEnabled() ? 0 : 1
)); ));
@ -121,7 +139,7 @@ class Spells {
foreach($runeslist as $spellname) { foreach($runeslist as $spellname) {
$spell = self::$spellsList->getRune($spellname); $spell = self::$spellsList->getRune($spellname);
$name = $spell->getName() . ' (rune)'; $name = $spell->getName() . ' Rune';
try { try {
$db->insert(TABLE_PREFIX . 'spells', array( $db->insert(TABLE_PREFIX . 'spells', array(

View File

@ -16,77 +16,68 @@ $title = 'Logs viewer';
<h3 class="box-title">Logs:</h3> <h3 class="box-title">Logs:</h3>
</div> </div>
<div class="box-body"> <div class="box-body">
<div id="logs_wrapper" class="dataTables_wrapper form-inline dt-bootstrap"> <div class="row">
<div class="row"> <div class="col-sm-6">
<div class="col-sm-12"> <table id="tb_logs">
<table id="logs" class="table table-bordered table-striped dataTable" role="grid" <thead>
aria-describedby="logs_info"> <tr>
<thead>
<tr role="row">
<th class="sorting_asc" tabindex="0" aria-controls="logs" rowspan="1" colspan="1"
aria-sort="ascending" aria-label="Log name: activate to sort column descending"
style="width: 297px;">Log name
</th>
<th class="sorting" tabindex="0" aria-controls="logs" rowspan="1" colspan="1"
aria-label="Last updated: activate to sort column ascending" style="width: 361px;">Last
updated
</th>
</tr>
</thead>
<tbody>
<?php
$files = array();
$aac_path_logs = BASE . 'system/logs/';
foreach (scandir($aac_path_logs) as $f) {
if ($f[0] == '.' || $f == '..' || is_dir($aac_path_logs . $f))
continue;
$files[] = array($f, $aac_path_logs);
}
$server_path_logs = $config['server_path'] . 'logs/';
if (!file_exists($server_path_logs)) {
$server_path_logs = $config['data_path'] . 'logs/';
}
if (file_exists($server_path_logs)) {
foreach (scandir($server_path_logs) as $f) {
if ($f[0] == '.' || $f == '..')
continue;
if (is_dir($server_path_logs . $f)) {
foreach (scandir($server_path_logs . $f) as $f2) {
if ($f2[0] == '.' || $f2 == '..')
continue;
$files[] = array($f . '/' . $f2, $server_path_logs);
}
continue;
}
$files[] = array($f, $server_path_logs);
}
}
$i = 0;
foreach ($files as $f) {
?>
<tr>
<td>
<a href="<?php echo ADMIN_URL . '?p=logs&file=' . $f[0]; ?>"><?php echo $f[0]; ?></a>
</td>
<td><?php echo date("Y-m-d H:i:s", filemtime($f[1] . $f[0])); ?></td>
</tr>
<?php
}
?>
</tbody>
<tfoot>
<th>Log name</th> <th>Log name</th>
<th>Last updated</th> <th>Last updated</th>
</tfoot> </tr>
</table> </thead>
</div> <tbody>
<?php
$files = array();
$aac_path_logs = BASE . 'system/logs/';
foreach (scandir($aac_path_logs) as $f) {
if ($f[0] == '.' || $f == '..' || is_dir($aac_path_logs . $f))
continue;
$files[] = array($f, $aac_path_logs);
}
$server_path_logs = $config['server_path'] . 'logs/';
if (!file_exists($server_path_logs)) {
$server_path_logs = $config['data_path'] . 'logs/';
}
if (file_exists($server_path_logs)) {
foreach (scandir($server_path_logs) as $f) {
if ($f[0] == '.' || $f == '..')
continue;
if (is_dir($server_path_logs . $f)) {
foreach (scandir($server_path_logs . $f) as $f2) {
if ($f2[0] == '.' || $f2 == '..')
continue;
$files[] = array($f . '/' . $f2, $server_path_logs);
}
continue;
}
$files[] = array($f, $server_path_logs);
}
}
$i = 0;
foreach ($files as $f) {
?>
<tr>
<td>
<a href="<?php echo ADMIN_URL . '?p=logs&file=' . $f[0]; ?>"><?php echo $f[0]; ?></a>
</td>
<td><?php echo date("Y-m-d H:i:s", filemtime($f[1] . $f[0])); ?></td>
</tr>
<?php
}
?>
</tbody>
<tfoot>
<th>Log name</th>
<th>Last updated</th>
</tfoot>
</table>
</div> </div>
</div> </div>
</div> </div>
@ -119,6 +110,6 @@ if (!empty($file)) {
?> ?>
<script> <script>
$(function () { $(function () {
$('#logs').DataTable() $('#tb_logs').DataTable()
}) })
</script> </script>

View File

@ -0,0 +1,91 @@
<?php
/**
* Reports
*
* @package MyAAC
* @author Lee
* @copyright 2018 MyAAC
* @link http://my-aac.org
*/
defined('MYAAC') or die('Direct access not allowed!');
$title = 'Report viewer';
?>
<div class="box">
<div class="box-header">
<h3 class="box-title">Reports:</h3>
</div>
<div class="box-body">
<div class="row">
<div class="col-sm-12">
<table id="tb_reports">
<thead>
<tr>
<th>Report name</th>
<th>Last updated</th>
</tr>
</thead>
<tbody>
<?php
$files = array();
$server_path_reports = $config['data_path'] . 'reports/';
if (file_exists($server_path_reports)) {
foreach (scandir($server_path_reports) as $f) {
if ($f[0] == '.' || $f == '..')
continue;
if (is_dir($server_path_reports . $f)) {
foreach (scandir($server_path_reports . $f) as $f2) {
if ($f2[0] == '.' || $f2 == '..')
continue;
$files[] = array($f . '/' . $f2, $server_path_reports);
}
continue;
}
$files[] = array($f, $server_path_reports);
}
}
$i = 0;
foreach ($files as $f) {
?>
<tr>
<td>
<a href="<?php echo ADMIN_URL . '?p=reports&file=' . $f[0]; ?>"><?php echo $f[0]; ?></a>
</td>
<td><?php echo date("Y-m-d H:i:s", filemtime($f[1] . $f[0])); ?></td>
</tr>
<?php
}
?>
</tbody>
</table>
</div>
</div>
</div>
</div>
<?php
$file = isset($_GET['file']) ? $_GET['file'] : NULL;
if (!empty($file)) {
if (!preg_match('/[^A-z0-9\' _\/\-\.]/', $file)) {
if (file_exists($server_path_reports . $file)) {
echo '<div class="box"><div class="box-header"><h3 class="box-title"><b>' . $file . '</b></h3></div><div class="box-body">';
echo nl2br(file_get_contents($server_path_reports . $file));
echo '</div></div>';
} else
echo 'Specified file does not exist.';
} else
echo 'Invalid file name specified.';
}
?>
<script>
$(document).ready(function () {
$('#tb_reports').DataTable();
});
</script>

View File

@ -41,8 +41,9 @@ else {
} }
} }
$order = 'name';
$spells = array(); $spells = array();
$spells_db = $db->query('SELECT * FROM `' . TABLE_PREFIX . 'spells` WHERE `hidden` != 1 AND `type` < 3 ORDER BY name, level'); $spells_db = $db->query('SELECT * FROM `' . TABLE_PREFIX . 'spells` WHERE `hidden` != 1 AND `type` < 4 AND `level` > 0 ORDER BY ' . $order . '');
if((string)$vocation_id != 'all') { if((string)$vocation_id != 'all') {
foreach($spells_db->fetchAll() as $spell) { foreach($spells_db->fetchAll() as $spell) {
@ -77,12 +78,16 @@ $twig->display('spells.html.twig', array(
'post_vocation_id' => $vocation_id, 'post_vocation_id' => $vocation_id,
'post_vocation' => $vocation, 'post_vocation' => $vocation,
'spells' => $spells, 'spells' => $spells,
'item_path' => $config['item_images_url'],
)); ));
?> ?>
<script> <script>
$(document).ready( function () { $(document).ready( function () {
$('#spellstb').DataTable();
$("#tb_instantSpells").DataTable();
$("#tb_conjureSpells").DataTable();
$("#tb_runeSpells").DataTable();
} ); } );
</script> </script>

View File

@ -6,58 +6,44 @@
</div> </div>
</div> </div>
<div class="box-body"> <div class="box-body">
<div id="tb_pages_wrapper" class="dataTables_wrapper form-inline dt-bootstrap"> <div class="row">
<div class="row"> <div class="col-sm-12">
<div class="col-sm-12"> <table id="tb_pages">
<table id="tb_pages" class="table table-bordered table-striped dataTable" role="grid" <thead>
aria-describedby="tb_pages_info"> <tr>
<thead> <th>Name</th>
<tr role="row"> <th>Title</th>
<th class="sorting_asc" tabindex="0" aria-controls="tb_pages" rowspan="1" colspan="1" <th style="width: 150px;">Options</th>
aria-sort="ascending" aria-label="Name: activate to sort column descending">Name </tr>
</th> </thead>
<th class="sorting" tabindex="0" aria-controls="tb_pages" rowspan="1" colspan="1" <tbody>
aria-sort="ascending" aria-label="Title: activate to sort column descending">Title {% for page in pages %}
</th>
<th class="" tabindex="0" aria-controls="tb_pages" rowspan="1" colspan="1"
style="width: 150px;">Options
</th>
</tr>
</thead>
<tbody>
{% for page in pages %}
<tr>
<td>{{ page.link|raw }}</td>
<td><i>{{ page.title }}</i></td>
<td>
<a href="?p=pages&action=edit&id={{ page.id }}" class="ico" title="Edit"><span
class="btn btn-success btn-sm edit btn-flat"><i class="fa fa-edit"></i></span></a>
<a href="?p=pages&action=delete&id={{ page.id }}" class="ico"
onclick="return confirm('Are you sure?');" title="Delete"><span
class="btn btn-danger btn-sm delete btn-flat"><i
class="fa fa-trash"></i></span></a>
<a href="?p=pages&action=hide&id={{ page.id }}" class="ico"
title="{% if page.hidden != 1 %}Hide{% else %}Show{% endif %}">
{% if page.hidden != 1 %}
<span class="btn btn-primary btn-sm btn-flat"><i
class="fa fa-eye"></i></span>
{% else %}
<span class="btn btn-default btn-sm btn-flat"><i
class="fa fa-eye-slash"></i></span>
{% endif %}
</a>
</td>
</tr>
{% endfor %}
</tbody>
<tfoot>
<tr> <tr>
<th>Name</th> <td>{{ page.link|raw }}</td>
<th>Title</th> <td><i>{{ page.title }}</i></td>
<th>Options</th> <td>
</tfoot> <a href="?p=pages&action=edit&id={{ page.id }}" class="ico" title="Edit"><span
</table> class="btn btn-success btn-sm edit btn-flat"><i
</div> class="fa fa-edit"></i></span></a>
<a href="?p=pages&action=delete&id={{ page.id }}" class="ico"
onclick="return confirm('Are you sure?');" title="Delete"><span
class="btn btn-danger btn-sm delete btn-flat"><i
class="fa fa-trash"></i></span></a>
<a href="?p=pages&action=hide&id={{ page.id }}" class="ico"
title="{% if page.hidden != 1 %}Hide{% else %}Show{% endif %}">
{% if page.hidden != 1 %}
<span class="btn btn-primary btn-sm btn-flat"><i
class="fa fa-eye"></i></span>
{% else %}
<span class="btn btn-default btn-sm btn-flat"><i
class="fa fa-eye-slash"></i></span>
{% endif %}
</a>
</td>
</tr>
{% endfor %}
</tbody>
</table>
</div> </div>
</div> </div>
</div> </div>

View File

@ -5,55 +5,40 @@
<h3 class="box-title">Installed plugins:</h3> <h3 class="box-title">Installed plugins:</h3>
</div> </div>
<div class="box-body"> <div class="box-body">
<div id="plugins_wrapper" class="dataTables_wrapper form-inline dt-bootstrap"> <div class="row">
<div class="row"> <div class="col-sm-12">
<div class="col-sm-12"> <table id="tb_plugins">
<table id="plugins" class="table table-bordered table-striped dataTable" role="grid" <thead>
aria-describedby="plugins_info"> <tr>
<thead> <th>Name</th>
<tr role="row"> <th>Description</th>
<th class="sorting_asc" tabindex="0" aria-controls="plugins" rowspan="1" <th>Author</th>
colspan="1" aria-sort="ascending" <th>Filename</th>
aria-label="Name: activate to sort column descending">Name <th style="width: 55px;">Options</th>
</th> </tr>
<th class="sorting" tabindex="0" aria-controls="plugins" rowspan="1" colspan="1" </thead>
aria-label="Description: activate to sort column ascending">Description <tbody>
</th> {% for plugin in plugins %}
<th class="sorting" tabindex="0" aria-controls="plugins" rowspan="1" colspan="1" <tr>
aria-label="Author: activate to sort column ascending">Author <td><b>{{ plugin.name }}</b><br>
</th> <small>{{ plugin.description }}</small>
<th class="sorting" tabindex="0" aria-controls="plugins" rowspan="1" colspan="1" </td>
aria-label="Filename: activate to sort column ascending">Filename <td>{{ plugin.version }}</td>
</th> <td><b>{{ plugin.author }}</b><br>
<th class="sorting" tabindex="0" aria-controls="plugins" rowspan="1" colspan="1" <small>{{ plugin.contact }}</small>
aria-label="Options: activate to sort column ascending" </td>
style="width: 55px;">Options <td>{{ plugin.file }}.json</td>
</th> <td>
{% if plugin.uninstall %}
<a href="?p=plugins&uninstall={{ plugin.file }}" title="Uninstall"
onclick="return confirm('Are you sure?');"><span
class="btn btn-danger btn-sm delete btn-flat"><i
class="fa fa-trash"></i></span></a>
{% endif %}</td>
</tr> </tr>
</thead> {% endfor %}
<tbody> </tbody>
{% for plugin in plugins %} </table>
<tr>
<td><b>{{ plugin.name }}</b><br>
<small>{{ plugin.description }}</small>
</td>
<td>{{ plugin.version }}</td>
<td><b>{{ plugin.author }}</b><br>
<small>{{ plugin.contact }}</small>
</td>
<td>{{ plugin.file }}.json</td>
<td>
{% if plugin.uninstall %}
<a href="?p=plugins&uninstall={{ plugin.file }}" title="Uninstall"
onclick="return confirm('Are you sure?');"><span
class="btn btn-danger btn-sm delete btn-flat"><i
class="fa fa-trash"></i></span></a>
{% endif %}</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
</div> </div>
</div> </div>
</div> </div>
@ -62,6 +47,6 @@
</div> </div>
<script> <script>
$(function () { $(function () {
$('#plugins').DataTable() $('#tb_plugins').DataTable()
}) })
</script> </script>

View File

@ -3,54 +3,36 @@
<h3 class="box-title">Users active within last {{ config_visitors_counter_ttl }} minutes.</h3> <h3 class="box-title">Users active within last {{ config_visitors_counter_ttl }} minutes.</h3>
</div> </div>
<div class="box-body"> <div class="box-body">
<div id="visitors_wrapper" class="dataTables_wrapper form-inline dt-bootstrap"> <div class="row">
<div class="row"> <div class="col-sm-12">
<div class="col-sm-12"> <table id="tb_visitors">
<table id="visitors" class="table table-bordered table-striped dataTable" role="grid" <thead>
aria-describedby="visitors_info"> <tr>
<thead> <th>IP</th>
<tr role="row"> <th>Last visit</th>
<th class="sorting_asc" tabindex="0" aria-controls="visitors" rowspan="1" colspan="1" <th>Page</th>
aria-sort="ascending" aria-label="IP: activate to sort column descending" </tr>
style="width: 297px;">IP </thead>
</th> <tbody>
<th class="sorting" tabindex="0" aria-controls="visitors" rowspan="1" colspan="1" {% set i = 0 %}
aria-label="Last visit: activate to sort column ascending" style="width: 361px;">Last {% for visitor in visitors %}
visit {% set i = i + 1 %}
</th> <tr role="row" class="odd">
<th class="sorting" tabindex="0" aria-controls="visitors" rowspan="1" colspan="1" <td>{{ visitor.ip }}</td>
aria-label="Page: activate to sort column ascending" style="width: 322px;">Page <td>{{ visitor.lastvisit|date("H:i:s") }}</td>
</th> <td>
<a href="{{ visitor.page }}">{{ visitor.page|slice(0, 50) }}</a>
</td>
</tr> </tr>
</thead> {% endfor %}
<tbody> </tbody>
{% set i = 0 %} </table>
{% for visitor in visitors %}
{% set i = i + 1 %}
<tr role="row" class="odd">
<td>{{ visitor.ip }}</td>
<td>{{ visitor.lastvisit|date("H:i:s") }}</td>
<td>
<a href="{{ visitor.page }}">{{ visitor.page|slice(0, 50) }}</a>
</td>
</tr>
{% endfor %}
</tbody>
<tfoot>
<tr>
<th>IP</th>
<th>Last visit</th>
<th>Page</th>
</tr>
</tfoot>
</table>
</div>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
<script> <script>
$(function () { $(function () {
$('#visitors').DataTable() $('#tb_visitors').DataTable()
}) })
</script> </script>

View File

@ -1,9 +1,42 @@
<style type="text/css">
.ts_Spells > input[type="radio"] {
position: absolute;
left: -200vw;
}
.ts_Spells .tab-panel {
display: none;
}
.ts_Spells > input:first-child:checked ~ .tab-panels > .tab-panel:first-child,
.ts_Spells > input:nth-child(3):checked ~ .tab-panels > .tab-panel:nth-child(2),
.ts_Spells > input:nth-child(5):checked ~ .tab-panels > .tab-panel:nth-child(3),
.ts_Spells > input:nth-child(7):checked ~ .tab-panels > .tab-panel:nth-child(4),
.ts_Spells > input:nth-child(9):checked ~ .tab-panels > .tab-panel:nth-child(5),
.ts_Spells > input:nth-child(11):checked ~ .tab-panels > .tab-panel:nth-child(6) {
display: block;
}
.ts_Spells > label {
position: relative;
display: inline-block;
padding: 10px 10px 10px;
margin-bottom: 10px;
border: 1px solid transparent;
border-bottom: 0;
cursor: pointer;
font-weight: 600;
background-color: {{ config.vdarkborder }};
color: #fff;
}
</style>
{% if canEdit %} {% if canEdit %}
<form method="post" action="{{ getLink('spells') }}"> <form method="post" action="{{ getLink('spells') }}">
<input type="hidden" name="reload_spells" value="yes"/> <input type="hidden" name="reload_spells" value="yes"/>
<input type="submit" value="(admin) Reload spells"/> <input type="submit" value="(admin) Reload spells"/>
</form> </form>
{% endif %} {% endif %}
<form action="{{ getLink('spells') }}" method="post"> <form action="{{ getLink('spells') }}" method="post">
@ -18,7 +51,7 @@
<td>Only for vocation: <select name="vocation_id"> <td>Only for vocation: <select name="vocation_id">
<option value="all" {% if post_vocation_id == 'all' %} selected{% endif %}>All</option> <option value="all" {% if post_vocation_id == 'all' %} selected{% endif %}>All</option>
{% for id, vocation in config.vocations %} {% for id, vocation in config.vocations %}
<option value="{{ id }}"{% if id == post_vocation_id and post_vocation_id != "all" and post_vocation_id != '' %} selected{% endif %}>{{ vocation }}</option> <option value="{{ id }}"{% if id == post_vocation_id and post_vocation_id != "all" and post_vocation_id != '' %} selected{% endif %}>{{ vocation }}</option>
{% endfor %} {% endfor %}
</select> </select>
</td> </td>
@ -32,39 +65,137 @@
</table> </table>
</form> </form>
<br/> <br/>
<table id="spellstb" class=""><thead>
<tr role="row"><th>Name</th><th>Words</th><th>Type<br/>(count)</th> <div class="ts_Spells">
<th>Mana</th><th>Level</th><th>Magic Level</th><th>Soul</th><th>Premium</th><th>Vocations</th></tr> <input type="radio" name="ts_Spells" id="tab_instant" aria-controls="instant" checked>
</thead><tbody> <label for="tab_instant">Instant</label>
{% set i = 0 %}
{% for spell in spells %} <input type="radio" name="ts_Spells" id="tab_conjure" aria-controls="conjure">
{% set i = i + 1 %} <label for="tab_conjure">Conjure</label>
<tr>
<td>{{ spell.name }}</td> <input type="radio" name="ts_Spells" id="tab_rune" aria-controls="rune">
<td>{{ spell.words }}</td> <label for="tab_rune">Rune</label>
<td>
{% if spell.type == 1 %} <div class="tab-panels">
Instant <section id="instant" class="tab-panel">
{% elseif spell.type == 2 %} <table id="tb_instantSpells">
Conjure ({{ spell.conjure_count }}) <thead>
{% else %} <th>Name</th>
Rune <th>Words</th>
{% endif %} <th>Level</th>
</td> <th>Mana</th>
<td>{{ spell.mana }}</td> <th>Vocations</th>
<td>{{ spell.level }}</td> </thead>
<td>{{ spell.maglevel }}</td> <tbody>
<td>{{ spell.soul }}</td> {% set i = 0 %}
<td>{% if spell.premium == 1 %}yes{% else %}no{% endif %}</td> {% set y = 0 %}
<td> {% for spell in spells %}
{% if spell.vocations|length > 0 %} {% set i = i + 1 %}
<span style="font-size: 10px"> {% if spell.type == 1 %}
{{ spell.vocations|raw }} {% set y = y + 1 %}
</span> <tr>
{% else %} <td>{{ spell.name }}</td>
{{ config.vocations[post_vocation_id] }} <td>{{ spell.words }}</td>
{% endif %} <td>{{ spell.level }}</td>
</td> <td>{{ spell.mana }}</td>
</tr> <td>
{% endfor %} {% if spell.vocations|length > 0 %}
</tbody></table> <span style="font-size: 10px">{{ spell.vocations|raw }}</span>
{% else %}
{{ config.vocations[post_vocation_id] }}
{% endif %}
</td>
</tr>
{% endif %}
{% endfor %}
</tbody>
</table>
</section>
<section id="conjure" class="tab-panel">
<table id="tb_conjureSpells">
<thead>
<th>Name</th>
<th>Words</th>
<th>Level</th>
<th>Mana</th>
<th>Soul</th>
<th>Item</th>
<th>Reagent</th>
<th>Vocations</th>
</thead>
<tbody>
{% set i = 0 %}
{% set y = 0 %}
{% for spell in spells %}
{% set i = i + 1 %}
{% if spell.type == 2 %}
{% set y = y + 1 %}
<tr>
<td>{{ spell.name }}</td>
<td>{{ spell.words }}</td>
<td>{{ spell.level }}</td>
<td>{{ spell.mana }}</td>
<td>{{ spell.soul }}</td>
<td>
<small>
{% if (spell.conjure_count < 150) and ( spell.conjure_count > 0) %} {{ spell.conjure_count }}x
<br/>{% endif %}</small>
<img src="{{ item_path }}/{{ spell.conjure_id }}.gif"
width="32" height="32" border="0"
alt="{{ spell.conjure_id }}"></td>
<td>{% if (spell.reagent > 0) %}
<img src="{{ item_path }}/{{ spell.reagent }}.gif"
width="32" height="32" border="0"
alt="{{ spell.reagent }}">{% else %}---{% endif %}</td>
<td>
{% if spell.vocations|length > 0 %}
<span style="font-size: 10px">{{ spell.vocations|raw }}</span>
{% else %}
{{ config.vocations[post_vocation_id] }}
{% endif %}
</td>
</tr>
{% endif %}
{% endfor %}
</tbody>
</table>
</section>
<section id="rune" class="tab-panel">
<table id="tb_runeSpells">
<thead>
<th>Name</th>
<th>Level</th>
<th>Magic Level</th>
<th>Item</th>
<th>Vocations</th>
</thead>
<tbody>
{% set i = 0 %}
{% set y = 0 %}
{% for spell in spells %}
{% set i = i + 1 %}
{% if spell.type == 3 %}
{% set y = y + 1 %}
<tr>
<td>{{ spell.name }}</td>
<td>{{ spell.level }}</td>
<td>{{ spell.maglevel }}</td>
<td><img src="{{ item_path }}/{{ spell.item_id }}.gif"
width="32" height="32" border="0"
alt="{{ spell.item_id }}"></td>
<td>
{% if spell.vocations|length > 0 %}
<span style="font-size: 10px">{{ spell.vocations|raw }}</span>
{% else %}
{{ config.vocations[post_vocation_id] }}
{% endif %}
</td>
</tr>
{% endif %}
{% endfor %}
</tbody>
</table>
</section>
</div>
</div>

BIN
tools/images/sort_asc.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 160 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 148 B

BIN
tools/images/sort_both.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 201 B

BIN
tools/images/sort_desc.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 158 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 146 B