mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-11-15 03:59:06 +00:00
df3da6f99b
Fix's for installer for AMS
216 lines
11 KiB
HTML
216 lines
11 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
|
<title>Ryzom Account Management System: Design Info</title>
|
|
|
|
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
|
|
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="jquery.js"></script>
|
|
<script type="text/javascript" src="search/search.js"></script>
|
|
<script type="text/javascript">
|
|
$(document).ready(function() { searchBox.OnSelectItem(0); });
|
|
</script>
|
|
|
|
</head>
|
|
<body>
|
|
<div id="top"><!-- do not remove this div! -->
|
|
|
|
|
|
<div id="titlearea">
|
|
<table cellspacing="0" cellpadding="0">
|
|
<tbody>
|
|
<tr style="height: 56px;">
|
|
|
|
<td id="projectlogo"><img alt="Logo" src="logo.png"/></td>
|
|
|
|
|
|
<td style="padding-left: 0.5em;">
|
|
<div id="projectname">Ryzom Account Management System
|
|
 <span id="projectnumber">1.0</span>
|
|
</div>
|
|
|
|
</td>
|
|
|
|
|
|
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<!-- Generated by Doxygen 1.7.6.1 -->
|
|
<script type="text/javascript">
|
|
var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
|
</script>
|
|
<div id="navrow1" class="tabs">
|
|
<ul class="tablist">
|
|
<li><a href="index.html"><span>Main Page</span></a></li>
|
|
<li class="current"><a href="pages.html"><span>Related Pages</span></a></li>
|
|
<li><a href="annotated.html"><span>Data Structures</span></a></li>
|
|
<li><a href="files.html"><span>Files</span></a></li>
|
|
<li>
|
|
<div id="MSearchBox" class="MSearchBoxInactive">
|
|
<span class="left">
|
|
<img id="MSearchSelect" src="search/mag_sel.png"
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
alt=""/>
|
|
<input type="text" id="MSearchField" value="Search" accesskey="S"
|
|
onfocus="searchBox.OnSearchFieldFocus(true)"
|
|
onblur="searchBox.OnSearchFieldFocus(false)"
|
|
onkeyup="searchBox.OnSearchFieldChange(event)"/>
|
|
</span><span class="right">
|
|
<a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
|
|
</span>
|
|
</div>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<div class="header">
|
|
<div class="headertitle">
|
|
<div class="title">Design Info </div> </div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
<div class="textblock"><h2><a class="anchor" id="intro_design"></a>
|
|
A brief introduction to the design of the AMS</h2>
|
|
<p>We will take a look at the current db design, the way the classes are designed, the way the WWW version works and how it was reused in the drupal module.</p>
|
|
<h3><a class="anchor" id="db_struct"></a>
|
|
The database structure</h3>
|
|
<p>My project started with the design of our database. I had to think about the advanced AMS features in advance. This is the reason why there are still a few unused DB tables in the design, the plan however is to use those as soon as possible by implementing the extra features.</p>
|
|
<p>The tables that are unused are the following: </p>
|
|
<ul>
|
|
<li>
|
|
ticket_group </li>
|
|
<li>
|
|
in_group </li>
|
|
<li>
|
|
tag </li>
|
|
<li>
|
|
tagged </li>
|
|
</ul>
|
|
<p><em>The idea for the ticket_groups was to provide the ability to bundle multiple tickets together in groups, this could be used for tickets that are alike or are in a weird way related. The idea for the tagging was to provide an extra system that allows to query tickets based on their tags (datamining). These features can be easily added in the future!</em></p>
|
|
<p>Let's take a look at the 'used' tables. The database structure is shown in the image below. For each table I made a matching class that handles the info of that table. </p>
|
|
<p>Quite central you can see the <b>ticket</b> table. As you can see, a ticket has a ticket_category field and author field, these hold the id of the related row in the <b>ticket_category</b> and <b>ticket_user</b> table. There's also the relation between a ticket and it's log entries, this is done by the ticket foreign key in the <b>ticket_log</b> table. The same counts for most other tables that are related to the ticket, they all got a ticket column used as foreign key. </p>
|
|
<p>Another thing that you might notice is the separation between <b>ticket_reply</b> and <b>ticket_content</b>, this is a 1-to-1 relation and this makes it easier to search between the replies if we only need their general information without having to take care of the content. The <b>ticket_user</b> is another quite important table that's being foreigned keyed by the others. It holds the permission of a user and the externID links to an ID given by the CMS(or our own www version) </p>
|
|
<p><em>Most things are pretty clear and straight forward, you can find the MYSQL Workbench file in the ryzom_ams/www/html/sql folder, which might give a better overview and can be used to update the DB easily when adding/modifying features in the future.</em> </p>
|
|
<div class="image">
|
|
<img src="db.png" alt="db.png"/>
|
|
</div>
|
|
<h3><a class="anchor" id="used_tech"></a>
|
|
Technologies used</h3>
|
|
<ul>
|
|
<li>
|
|
Smarty (for templating) (<a href="http://www.smarty.net/">http://www.smarty.net/</a>) </li>
|
|
<li>
|
|
multiple language .ini files to support different languages </li>
|
|
<li>
|
|
Charisma (WWW layout (uses bootstrap)) (<a href="http://usman.it/themes/charisma/">http://usman.it/themes/charisma/</a>) </li>
|
|
<li>
|
|
Drupal (drupal module) (<a href="https://drupal.org/">https://drupal.org/</a>) </li>
|
|
</ul>
|
|
<h3><a class="anchor" id="struct_info"></a>
|
|
Information regarding the structure</h3>
|
|
<p>As you might have noticed, the ryzom_ams directory contains 3 directories: the ams_lib dir, the www dir and a drupal_module dir. </p>
|
|
<p>the ams_lib contains the following important dirs/files: </p>
|
|
<ul>
|
|
<li>
|
|
<b>autoload dir</b> <em>holds all classes of the lib</em> </li>
|
|
<li>
|
|
<b>cron dir</b> <em>holds the cron functions regarding email and the ams_querycache</em> </li>
|
|
<li>
|
|
<b>ingame_templates dir</b> <em>holds the templates that are being used while ingame</em> </li>
|
|
<li>
|
|
<b>smarty dir</b> <em>the smarty files (<a href="http://www.smarty.net/">http://www.smarty.net/</a>)</em> </li>
|
|
<li>
|
|
<b>translations dir</b> <em>multiple .ini files, one for each language that's being supported.</em> </li>
|
|
<li>
|
|
<b><a class="el" href="libinclude_8php.html">libinclude.php</a></b> <em>php file that holds the __autoload function</em> </li>
|
|
</ul>
|
|
<p>the www contains the following important dirs/files: </p>
|
|
<ul>
|
|
<li>
|
|
<b>autoload dir</b> <em>holds the webusers.php file (which extends the Users.php file in the lib)</em> </li>
|
|
<li>
|
|
<b>func dir</b> <em>holds php files that contain a function that is being executed after filling in a form.</em> </li>
|
|
<li>
|
|
<b>inc dir</b> <em>holds php files that contain a function that is being executed before loading a specific file.</em> </li>
|
|
<li>
|
|
<b>templates dir</b> <em>holds the templates being used outgame.</em> </li>
|
|
<li>
|
|
<b>config.php</b> <em>php file that holds configuration settings</em> </li>
|
|
</ul>
|
|
<p>the drupal_module contains the following important dirs/files: </p>
|
|
<ul>
|
|
<li>
|
|
<b>autoload dir</b> <em>holds the webusers.php file that uses drupal functions (which extends the Users.php file in the lib)</em> </li>
|
|
<li>
|
|
<b>func dir</b> <em>holds php files that contain a function that is being executed after filling in a form.</em> </li>
|
|
<li>
|
|
<b>inc dir</b> <em>holds php files that contain a function that is being executed before loading a specific file.</em> </li>
|
|
<li>
|
|
<b>templates dir</b> <em>holds the templates being used outgame.</em> </li>
|
|
<li>
|
|
<b>config.php</b> <em>php file that holds configuration settings</em> </li>
|
|
<li>
|
|
<b>ryzommanage.info</b> <em>drupal file that holds information being used by drupal</em> </li>
|
|
<li>
|
|
<b>ryzommanage.install</b> <em>drupal file thats being used for installing the module</em> </li>
|
|
<li>
|
|
<b>ryzommanage.module</b> <em>drupal file that holds all functionality that's being needed to handle the AMS in drupal. (read more about it at the wiki page)</em> </li>
|
|
</ul>
|
|
<p><em><b>Important:</b> the func dir and inc dir in the drupal_module are almost empty, that's because the inc/func directories of the WWW version can be copied to the drupal version, they are exactly the same. However, because the drupal_module isn't completely up to date, the settings page doesn't has the extra fields (like gender,country,..) therefore the ingame template file, inc files related to that are still in the module.</em> </p>
|
|
<h3><a class="anchor" id="pageload"></a>
|
|
How does the page loading work?</h3>
|
|
<div class="image">
|
|
<img src="info.jpg" alt="info.jpg"/>
|
|
</div>
|
|
<h3><a class="anchor" id="classload"></a>
|
|
How are the classes being used?</h3>
|
|
<p>Like I mentioned above, each DB table has a class related that handles the data linked to that table and has functions working with that data. </p>
|
|
<p>The private attributes of each class are similar to the fields in the DB table. Every class also has the following functions: </p>
|
|
<ul>
|
|
<li>
|
|
function __construct() </li>
|
|
<li>
|
|
function set($values) </li>
|
|
<li>
|
|
function create() </li>
|
|
<li>
|
|
function delete() </li>
|
|
<li>
|
|
function load( $id) <em>or named similar</em> </li>
|
|
<li>
|
|
some also have: update () </li>
|
|
</ul>
|
|
<p>These methods are being used by the public static functions of that class, which represent the 'real' AMS-functions, the ones being used by the inc/func files. </p>
|
|
<p>You can reference for example the <a class="el" href="classSupport__Group.html" title="groups moderators & admins together.">Support_Group</a> class's information, which shows this setup! </p>
|
|
</div></div><!-- contents -->
|
|
<!-- window showing the filter options -->
|
|
<div id="MSearchSelectWindow"
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark"> </span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark"> </span>Data Structures</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark"> </span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark"> </span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark"> </span>Variables</a></div>
|
|
|
|
<!-- iframe showing the search results (closed by default) -->
|
|
<div id="MSearchResultsWindow">
|
|
<iframe src="javascript:void(0)" frameborder="0"
|
|
name="MSearchResults" id="MSearchResults">
|
|
</iframe>
|
|
</div>
|
|
|
|
|
|
|
|
<hr class="footer"/><address class="footer"><small>
|
|
Generated on Sun Sep 15 2013 17:49:37 for Ryzom Account Management System by  <a href="http://www.doxygen.org/index.html">
|
|
<img class="footer" src="doxygen.png" alt="doxygen"/>
|
|
</a> 1.7.6.1
|
|
</small></address>
|
|
|
|
</body>
|
|
</html>
|