Added support group pages ingame layout + layout of the #menu's and managed to get a AMS-Home button in the top that would bring the page back to the dashboard!

--HG--
branch : quitta-gsoc-2013
This commit is contained in:
Quitta 2013-08-01 04:48:40 +02:00
parent 489e1b7f16
commit 1c6cdfd7a7
7 changed files with 331 additions and 19 deletions

View file

@ -866,7 +866,7 @@
<!--<define id="cs_url"
value="http://app.ryzom.com/ticket_system/index.php?mode=load" />-->
<define id="cs_url"
value="http://shard.ryzomcore.org/ams/index.php" />
value="http://localhost:40917/www/html/index.php" />
<group type="container"
id="cs_browser"
w="410"
@ -916,7 +916,7 @@
posref="MR MR"
x="-16"
y="0"
hardtext="uiBrowseRedoButton"
hardtext="AMS-HOME"
tooltip="uittBrowseHome"
onclick_l="browse_home"
params_l="name=ui:interface:cs_browser:content:html"

View file

@ -14,11 +14,6 @@
<td width="3"></td>
<td height="25" valign="middle" nowrap><a class="ajax-link" href="index.php?page=sgroup_list"><h5> Support Groups</h5></a></td>
<td width="3"></td>
<td width="10" align="center">|</td>
<td width="3"></td>
<td height="25" valign="middle" nowrap><a class="ajax-link" href="index.php?page=libuserlist"><h5> Syncing</h5></a></td>
<td width="3"></td>
<td height="25" valign="middle" nowrap><a href="?page=logout"><h5> Logout </h5></a></td>
<td width="3"></td>
{/block}

View file

@ -1,14 +1,18 @@
{extends file="layout.tpl"}
{block name=menu}
<li class="nav-header hidden-tablet">Main</li>
<li style="margin-left: -2px;"><a class="ajax-link" href="index.php"><i class="icon-home"></i><span class="hidden-tablet"> Dashboard</span></a></li>
<li style="margin-left: -2px;"><a class="ajax-link" href="index.php?page=show_user"><i class="icon-user"></i><span class="hidden-tablet"> Profile</span></a></li>
<li style="margin-left: -2px;"><a class="ajax-link" href="index.php?page=settings"><i class="icon-cog"></i><span class="hidden-tablet"> Settings</span></a></li>
<li class="nav-header hidden-tablet">Admin</li>
<li style="margin-left: -2px;"><a class="ajax-link" href="index.php?page=userlist"><i class="icon-th-list"></i><span class="hidden-tablet"> Users</span></a></li>
<li style="margin-left: -2px;"><a class="ajax-link" href="index.php?page=show_queue&get=todo"><i class="icon-th-list"></i><span class="hidden-tablet"> Queues</span></a></li>
<li style="margin-left: -2px;"><a class="ajax-link" href="index.php?page=sgroup_list"><i class="icon-briefcase"></i><span class="hidden-tablet"> Support Groups</span></a></li>
<li class="nav-header hidden-tablet">Actions</li>
<li style="margin-left: -2px;"><a href="?page=logout"><i class="icon-off"></i><span class="hidden-tablet"> Logout </span></a></li>
{block name=menu}
<td height="25" valign="middle" nowrap><a class="ajax-link" href="index.php"><h5> Dashboard</h5></a></td>
<td width="3"></td>
<td height="25" valign="middle" nowrap><a class="ajax-link" href="index.php?page=show_user"><h5> Profile</h5></a></td>
<td width="3"></td>
<td height="25" valign="middle" nowrap><a class="ajax-link" href="index.php?page=settings"><h5> Settings</h5></a></td>
<td width="3"></td>
<td width="10" align="center">|</td>
<td width="3"></td>
<td height="25" valign="middle" nowrap><a class="ajax-link" href="index.php?page=userlist"><h5> Users</h5></a></td>
<td width="3"></td>
<td height="25" valign="middle" nowrap><a class="ajax-link" href="index.php?page=show_queue&get=todo"><h5> Queues</h5></a></td>
<td width="3"></td>
<td height="25" valign="middle" nowrap><a class="ajax-link" href="index.php?page=sgroup_list"><h5> Support Groups</h5></a></td>
<td width="3"></td>
{/block}

View file

@ -7,5 +7,18 @@
<li class="nav-header hidden-tablet">Actions</li>
<li style="margin-left: -2px;"><a class="ajax-link" href="index.php?page=createticket"><i class="icon-pencil"></i><span class="hidden-tablet">Create New Ticket</span></a></li>
<li style="margin-left: -2px;"><a href="?page=logout"><i class="icon-off"></i><span class="hidden-tablet"> Logout </span></a></li>
<td height="25" valign="middle" nowrap><a class="ajax-link" href="index.php"><h5> Dashboard</h5></a></td>
<td width="3"></td>
<td height="25" valign="middle" nowrap><a class="ajax-link" href="index.php?page=show_user"><h5> Profile</h5></a></td>
<td width="3"></td>
<td height="25" valign="middle" nowrap><a class="ajax-link" href="index.php?page=settings"><h5> Settings</h5></a></td>
<td width="3"></td>
<td width="10" align="center">|</td>
<td width="3"></td>
<td height="25" valign="middle" nowrap><a class="ajax-link" href="index.php?page=createticket"><h5> Create New Ticket</h5></a></td>
<td width="3"></td>
{/block}

View file

@ -0,0 +1,73 @@
{block name=content}
<div class="row-fluid">
<div class="box span12">
<div class="box-header well">
<h2><i class="icon-info-sign"></i>{$libuserlist_title}</h2>
<div class="box-icon">
<a href="#" class="btn btn-round" onclick="javascript:show_help('intro');return false;"><i class="icon-info-sign"></i></a>
<a href="#" class="btn btn-setting btn-round"><i class="icon-cog"></i></a>
<a href="#" class="btn btn-minimize btn-round"><i class="icon-chevron-up"></i></a>
<a href="#" class="btn btn-close btn-round"><i class="icon-remove"></i></a>
</div>
</div>
<div class="box-content">
<center>
<p>{$libuserlist_info}</p>
{if $shard eq "online"}
<div class="alert alert-success">
<i class="icon-refresh icon-white"></i>{$shard_online}<a href="#" id="sync" onclick="sync()">{$libuserlist_sync}</a>
<script>
function sync(){
xmlhttp=new XMLHttpRequest();
xmlhttp.open("POST","../../../ams_lib/cron/sync_cron.php",true);
xmlhttp.send();
}
</script>
</div>
{else}
<div class="alert alert-error">
<strong><i class="icon-refresh icon-white"></i></strong> {$shard_offline}
</div>
{/if}
</center>
<div class="clearfix"></div>
</div>
</div>
</div>
<div class="row-fluid sortable">
<div class="box span12">
<div class="box-header well" data-original-title>
<h2><i class="icon-user"></i> {$members}</h2>
<div class="box-icon">
<a href="#" class="btn btn-setting btn-round"><i class="icon-cog"></i></a>
<a href="#" class="btn btn-minimize btn-round"><i class="icon-chevron-up"></i></a>
<a href="#" class="btn btn-close btn-round"><i class="icon-remove"></i></a>
</div>
</div>
<div class="box-content">
<table class="table table-striped table-bordered bootstrap-datatable datatable">
<thead>
<tr>
<th>{$id}</th>
<th>{$type}</th>
</tr>
</thead>
<tbody>
{foreach from=$liblist item=element}
<tr>
<td>{$element.id}</td>
<td class="center">{$element.type}</td>
</tr>
{/foreach}
</tbody>
</table>
</div>
</div><!--/span-->
</div><!--/row-->
{/block}

View file

@ -0,0 +1,114 @@
{block name=content}
<tr><td>
<table width="100%" bgcolor="#303030" cellspacing="2">
<tr><td height="7"></td><td></td></tr>
<tr>
<td width="3%"></td>
<td width="100%" height="12" valign="middle"><h1>Support Groups</h1></td>
</tr>
<tr>
<td height="5"></td><td></td>
</tr>
</table>
</td></tr>
<tr><td>
<table width="100%" cellspacing="0" cellpadding="0" border="0">
<tr bgcolor="#000000" valign="middle">
<td>
<table>
<tr><td height="8"></td></tr>
</table>
</td>
</tr>
<tr><td height="2"></td></tr>
<tr><td height="1" bgcolor="#000000"></td></tr>
<tr><td height="10"></td></tr>
<tr valign="middle">
<td>
<table width="100%" height="100%" cellpadding="10">
{if isset($isAdmin) && $isAdmin eq 'TRUE'}
<tr><td>
<table width="100%" bgcolor="#00000030" border="2">
<tr><td>
<table cellpadding="10">
<tr><td>
<p><h3>Add a Support group</h3></p>
<form id="addSGroup" class="form-vertical" method="post" action="index.php">
<table cellpadding="1">
<tr>
<td valign="middle">Group name: </td>
<td><input type="text" maxlength="20" id="Name" name="Name"></td>
</tr>
<tr>
<td valign="middle">Group Tag: </td>
<td><input type="text" maxlength="4" id="Tag" name="Tag"></td>
</tr>
</table>
<input type="hidden" name="function" value="add_sgroup">
<p><input type="submit" value="Add Group" /></p>
{if isset($RESULT_OF_ADDING) and $RESULT_OF_ADDING eq "SUCCESS"}
<p>
<font color="green">{$group_success}</font>
</p>
{else if isset($RESULT_OF_ADDING) and $RESULT_OF_ADDING eq "NAME_TAKEN"}
<p>
<font color="red">{$group_name_taken}</font>
</p>
{else if isset($RESULT_OF_ADDING) and $RESULT_OF_ADDING eq "TAG_TAKEN"}
<p>
<font color="red">{$group_tag_taken}</font>
</p>
{else if isset($RESULT_OF_ADDING) and $RESULT_OF_ADDING eq "SIZE_ERROR"}
<p>
<font color="red">{$group_size_error}</font>
</p>
{/if}
</form>
</td></tr>
</table>
</td></tr>
</table>
</td></tr>
{/if}
<tr><td>
<table width="100%" bgcolor="#00000030" border="2">
<tr><td>
<table cellspacing="10">
<tr><td>
<p><h3>All groups</h3></p>
<table cellpadding="4">
<tr bgcolor="#00000090">
<td>ID</td>
<td>Name</td>
<td>Tag</td>
{if isset($isAdmin) && $isAdmin eq 'TRUE'}<td>Action</td>{/if}
</tr>
{foreach from=$grouplist item=group}
<tr>
<td>{$group.sGroupId}</td>
<td><a href ="index.php?page=show_sgroup&id={$group.sGroupId}">{$group.name}</a></td>
<td class="center"><span class="label label-important" >{$group.tag}</span></td>
{if isset($isAdmin) && $isAdmin eq 'TRUE'}<td class="center"><a href="index.php?page=sgroup_list&delete={$group.sGroupId}"><font color="red">Delete</font></a></td>{/if}
</tr>
{/foreach}
</table>
</td></tr>
</table>
</td></tr>
</table>
</td></tr>
</table>
</td>
</tr>
</table>
</td></tr>
{/block}

View file

@ -0,0 +1,113 @@
{block name=content}
<tr><td>
<table width="100%" bgcolor="#303030" cellspacing="2">
<tr><td height="7"></td><td></td></tr>
<tr>
<td width="3%"></td>
<td width="100%" height="12" valign="middle"><h1>Support Group: {$groupsname}</h1></td>
</tr>
<tr>
<td height="5"></td><td></td>
</tr>
</table>
</td></tr>
<tr><td>
<table width="100%" cellspacing="0" cellpadding="0" border="0">
<tr bgcolor="#000000" valign="middle">
<td>
<table>
<tr><td height="8"></td></tr>
</table>
</td>
</tr>
<tr><td height="2"></td></tr>
<tr><td height="1" bgcolor="#000000"></td></tr>
<tr><td height="10"></td></tr>
<tr valign="middle">
<td>
<table width="100%" height="100%" cellpadding="10">
<tr><td>
<table width="100%" bgcolor="#00000030" border="2">
<tr><td>
<table cellpadding="10">
<tr><td>
<p><h3>Add user to the list</h3></p>
{if isset($isAdmin) && $isAdmin eq 'TRUE'}
<form id="addSGroup" class="form-vertical" method="post" action="index.php?page=show_sgroup&id={$target_id}">
<table>
<tr>
<td valign="middle">Username: </td>
<td><input type="text" maxlength="15" id="Name" name="Name"></td>
</tr>
</table>
<input type="hidden" name="function" value="add_user_to_sgroup">
<input type="hidden" name="target_id" value="{$target_id}">
<p>
<input type="submit" value="Add user" />
</p>
{if isset($RESULT_OF_ADDING) and $RESULT_OF_ADDING eq "SUCCESS"}
<p>
<font color="green">{$add_to_group_success}</font>
</p>
{else if isset($RESULT_OF_ADDING) and $RESULT_OF_ADDING eq "ALREADY_ADDED"}
<p>
<font color="red">{$user_already_added}</font>
</p>
{else if isset($RESULT_OF_ADDING) and $RESULT_OF_ADDING eq "GROUP_NOT_EXISTING"}
<p>
<font color="red">{$group_not_existing}</font>
</p>
{else if isset($RESULT_OF_ADDING) and $RESULT_OF_ADDING eq "USER_NOT_EXISTING"}
<p>
<font color="red">{$user_not_existing}</font>
</p>
{else if isset($RESULT_OF_ADDING) and $RESULT_OF_ADDING eq "NOT_MOD_OR_ADMIN"}
<p>
<font color="red">{$not_mod_or_admin}</font>
</p>
{/if}
</form>
{/if}
</td></tr>
</table>
</td></tr>
</table>
</td></tr>
<tr><td>
<table width="100%" bgcolor="#00000030" border="2">
<tr><td>
<table cellpadding="10">
<tr><td>
<p><h3>All members</h3></p>
<table cellpadding="4">
<tr bgcolor="#00000090">
<td>ID</td>
<td>Name</td>
{if isset($isAdmin) && $isAdmin eq 'TRUE'}<td>Action</td>{/if}
</tr>
{foreach from=$userlist item=user}
<tr>
<td>{$user.tUserId}</td>
<td><a href ="index.php?page=show_user&id={$user.tUserId}">{$user.name}</a></td>
{if isset($isAdmin) && $isAdmin eq 'TRUE'}<td class="center"><a href="index.php?page=show_sgroup&id={$target_id}&delete={$user.tUserId}"><font color="red">Delete</font></a></td>{/if}
</tr>
{/foreach}
</table>
</td></tr>
</table>
</td></tr>
</table>
</td></tr>
</table>
</td>
</tr>
</table>
</td></tr>
{/block}