mirror of
https://bitbucket.org/jsuto/piler.git
synced 2025-06-13 00:17:02 +02:00
added group handling feature
This commit is contained in:
@ -25,7 +25,8 @@
|
||||
|
||||
<li class="search_li" style="font: 11px normal Arial, sans-serif;"><a class="hide" href="#"<?php if(strstr($_SERVER['QUERY_STRING'], "domain/") || ($_SERVER['QUERY_STRING'] != "route=user/settings" && strstr($_SERVER['QUERY_STRING'], "user/")) || strstr($_SERVER['QUERY_STRING'], "policy/") || strstr($_SERVER['QUERY_STRING'], "import/")) { ?> id="active"<?php } ?>><?php print $text_administration; ?></a>
|
||||
<ul class="sub_menu">
|
||||
<li><a href="index.php?route=user/list"><?php print $text_user_management; ?></a></li>
|
||||
<li><a href="index.php?route=user/list"><?php print $text_users; ?></a></li>
|
||||
<li><a href="index.php?route=group/list"><?php print $text_groups; ?></a></li>
|
||||
<li><a href="index.php?route=domain/domain"><?php print $text_domain; ?></a></li>
|
||||
<li><a href="index.php?route=policy/archiving"><?php print $text_archiving_rules; ?></a></li>
|
||||
<li><a href="index.php?route=policy/retention"><?php print $text_retention_rules; ?></a></li>
|
||||
|
35
webui/view/theme/default/templates/group/add.tpl
Normal file
35
webui/view/theme/default/templates/group/add.tpl
Normal file
@ -0,0 +1,35 @@
|
||||
|
||||
<h4><?php print $text_add_new_group; ?></h4>
|
||||
|
||||
<?php if(isset($errorstring)){ ?><p class="loginfailed"><?php print $text_error; ?>: <?php print $errorstring; ?></p><?php } ?>
|
||||
|
||||
|
||||
<form action="index.php?route=group/add" name="adduser" method="post" autocomplete="off">
|
||||
|
||||
<div id="ss1">
|
||||
|
||||
<div class="domainrow">
|
||||
<div class="domaincell"><?php print $text_groupname; ?>:</div>
|
||||
<div class="domaincell"><input type="text" name="groupname" value="<?php if(isset($post['groupname'])){ print $post['groupname']; } ?>" class="text" /></div>
|
||||
</div>
|
||||
|
||||
<div class="domainrow">
|
||||
<div class="domaincell"><?php print $text_email_addresses; ?>:</div>
|
||||
<div class="domaincell"><textarea style="height:280px;" name="email" class="domain"><?php if(isset($post['email'])){ print $post['email']; } ?></textarea></div>
|
||||
</div>
|
||||
|
||||
<div class="domainrow">
|
||||
<div class="domaincell"> </div>
|
||||
<div class="domaincell"><input type="submit" value="<?php print $text_add; ?>" /><input type="reset" value="<?php print $text_cancel; ?>" /></div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</form>
|
||||
|
||||
|
||||
<?php if(isset($x)){ print $x; ?>. <a href="index.php?route=group/list"><?php print $text_back; ?></a>
|
||||
<?php } ?>
|
||||
|
39
webui/view/theme/default/templates/group/edit.tpl
Normal file
39
webui/view/theme/default/templates/group/edit.tpl
Normal file
@ -0,0 +1,39 @@
|
||||
|
||||
|
||||
<?php if(isset($group)) { ?>
|
||||
|
||||
<form action="index.php?route=group/edit" name="addgroup" method="post" autocomplete="off">
|
||||
<input type="hidden" name="id" value="<?php print $id; ?>" />
|
||||
|
||||
<div id="ss1">
|
||||
|
||||
<div class="domainrow">
|
||||
<div class="domaincell"><?php print $text_groupname; ?>:</div>
|
||||
<div class="domaincell"><input type="text" name="groupname" value="<?php print $group['groupname']; ?>" class="text" /></div>
|
||||
</div>
|
||||
|
||||
<div class="domainrow">
|
||||
<div class="domaincell"><?php print $text_email_addresses; ?>:</div>
|
||||
<div class="domaincell"><textarea style="height:280px;" name="email" class="domain"><?php if(isset($email)){ print $email; } ?></textarea></div>
|
||||
</div>
|
||||
|
||||
<div class="domainrow">
|
||||
<div class="domaincell"> </div>
|
||||
<div class="domaincell"><input type="submit" value="<?php print $text_modify; ?>" /><input type="reset" value="<?php print $text_cancel; ?>" /></div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
</form>
|
||||
|
||||
<p> </p>
|
||||
<p><a href="index.php?route=group/remove&id=<?php print $group['id']; ?>&group=<?php print $group['groupname']; ?>"><?php print $text_remove_this_group; ?>: <?php print $group['groupname']; ?></a></p>
|
||||
<p> </p>
|
||||
|
||||
<p>
|
||||
<?php } else if(isset($x)){ print $x; ?>.
|
||||
<?php } ?>
|
||||
|
||||
<a href="index.php?route=group/list"><?php print $text_back; ?></a>
|
||||
</p>
|
57
webui/view/theme/default/templates/group/list.tpl
Normal file
57
webui/view/theme/default/templates/group/list.tpl
Normal file
@ -0,0 +1,57 @@
|
||||
|
||||
<p/>
|
||||
|
||||
<p><a href="index.php?route=group/add"><?php print $text_add_new_group; ?></a></p>
|
||||
|
||||
<h4><?php print $text_existing_groups; ?></h4>
|
||||
|
||||
<form method="post" name="search1" action="index.php?route=group/list">
|
||||
<input type="text" name="search" value="<?php print $search; ?>" />
|
||||
<input type="submit" value="<?php print $text_search; ?>" />
|
||||
</form>
|
||||
|
||||
|
||||
<p> </p>
|
||||
|
||||
<?php if(isset($groups) && count($groups) > 0){ ?>
|
||||
|
||||
<div id="pagenav">
|
||||
<?php if($page > 0){ ?><a href="index.php?route=group/list&page=0&search=<?php print $search; ?>&sort=<?php print $sort; ?>&order=<?php print $order; ?>" class="navlink"><?php } ?> « <?php if($page > 0){ ?></a><?php } ?>
|
||||
<?php if($page > 0){ ?><a href="index.php?route=group/list&page=<?php print $prev_page; ?>&search=<?php print $search; ?>&sort=<?php print $sort; ?>&order=<?php print $order; ?>" class="navlink"><?php } ?> ‹ <?php if($page > 0){ ?></a><?php } ?>
|
||||
<?php print $groups[0][$sort]; ?> - <?php print $groups[count($groups)-1][$sort]; ?>
|
||||
<?php if($total_groups >= $page_len*($page+1) && $total_groups > $page_len){ ?><a href="index.php?route=group/list&page=<?php print $next_page; ?>&search=<?php print $search; ?>&sort=<?php print $sort; ?>&order=<?php print $order; ?>" class="navlink"><?php } ?> › <?php if($total_groups >= $page_len*($page+1) && $total_groups > $page_len){ ?></a><?php } ?>
|
||||
<?php if($page < $total_pages){ ?><a href="index.php?route=group/list&page=<?php print $total_pages; ?>&search=<?php print $search; ?>&sort=<?php print $sort; ?>&order=<?php print $order; ?>" class="navlink"><?php } ?> » <?php if($page < $total_pages){ ?></a><?php } ?>
|
||||
</div>
|
||||
|
||||
|
||||
<div id="ss1" style="margin-top: 10px;">
|
||||
<div class="domainrow">
|
||||
<div class="domaincell"><?php print $text_groupname; ?> <a href="index.php?route=group/list&sort=groupname&order=0"><img src="<?php print ICON_ARROW_UP; ?>" border="0"></a> <a href="index.php?route=group/list&sort=groupname&order=1"><img src="<?php print ICON_ARROW_DOWN; ?>" border="0"></a></div>
|
||||
<div class="domaincell"> </div>
|
||||
</div>
|
||||
|
||||
<?php foreach($groups as $group) { ?>
|
||||
<div class="domainrow">
|
||||
<div class="domaincell"><?php print $group['groupname']; ?></div>
|
||||
<div class="domaincell"><a href="index.php?route=group/edit&id=<?php print $group['id']; ?>"><?php print $text_edit_or_view; ?></a></div>
|
||||
</div>
|
||||
<?php } ?>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div id="pagenav">
|
||||
<?php if($page > 0){ ?><a href="index.php?route=group/list&page=0&search=<?php print $search; ?>&sort=<?php print $sort; ?>&order=<?php print $order; ?>" class="navlink"><?php } ?> « <?php if($page > 0){ ?></a><?php } ?>
|
||||
<?php if($page > 0){ ?><a href="index.php?route=group/list&page=<?php print $prev_page; ?>&search=<?php print $search; ?>&sort=<?php print $sort; ?>&order=<?php print $order; ?>" class="navlink"><?php } ?> ‹ <?php if($page > 0){ ?></a><?php } ?>
|
||||
<?php print $groups[0][$sort]; ?> - <?php print $groups[count($groups)-1][$sort]; ?>
|
||||
<?php if($total_groups >= $page_len*($page+1) && $total_groups > $page_len){ ?><a href="index.php?route=group/list&page=<?php print $next_page; ?>&search=<?php print $search; ?>&sort=<?php print $sort; ?>&order=<?php print $order; ?>" class="navlink"><?php } ?> › <?php if($total_groups >= $page_len*($page+1) && $total_groups > $page_len){ ?></a><?php } ?>
|
||||
<?php if($page < $total_pages){ ?><a href="index.php?route=group/list&page=<?php print $total_pages; ?>&search=<?php print $search; ?>&sort=<?php print $sort; ?>&order=<?php print $order; ?>" class="navlink"><?php } ?> » <?php if($page < $total_pages){ ?></a><?php } ?>
|
||||
</div>
|
||||
|
||||
|
||||
<?php } else { ?>
|
||||
<?php print $text_not_found; ?>
|
||||
<?php } ?>
|
||||
|
||||
|
13
webui/view/theme/default/templates/group/remove.tpl
Normal file
13
webui/view/theme/default/templates/group/remove.tpl
Normal file
@ -0,0 +1,13 @@
|
||||
|
||||
<p>
|
||||
|
||||
<?php if($confirmed){ ?>
|
||||
|
||||
<?php print $x; ?>. <a href="index.php?route=group/list"><?php print $text_back; ?></a>
|
||||
|
||||
<?php } else { ?>
|
||||
<a href="index.php?route=group/remove&id=<?php print $id; ?>&group=<?php print $group; ?>&confirmed=1"><?php print $text_remove_this_group; ?>: <?php print $group; ?></a>
|
||||
<?php } ?>
|
||||
|
||||
</p>
|
||||
|
@ -34,6 +34,20 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="domainrow">
|
||||
<div class="domaincell"><?php print $text_groups; ?>:</div>
|
||||
<div class="domaincell">
|
||||
<select name="gid">
|
||||
<option value="0"<?php if(isset($post) && $post['gid'] == 0){ ?> selected="selected"<?php } ?>>-</option>
|
||||
<?php foreach ($groups as $group) { ?>
|
||||
<option value="<?php print $group['id']; ?>"<?php if(isset($post) && $post['gid'] == $group['id']){ ?> selected="selected"<?php } ?>><?php print $group['groupname']; ?></option>
|
||||
<?php } ?>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<?php if(ENABLE_LDAP_IMPORT_FEATURE == 1) { ?>
|
||||
<div class="domainrow">
|
||||
<div class="domaincell">LDAP DN:</div>
|
||||
|
@ -34,6 +34,19 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="domainrow">
|
||||
<div class="domaincell"><?php print $text_groups; ?>:</div>
|
||||
<div class="domaincell">
|
||||
<select name="gid">
|
||||
<option value="0"<?php if($user['gid'] == 0){ ?> selected="selected"<?php } ?>>-</option>
|
||||
<?php foreach ($groups as $group) { ?>
|
||||
<option value="<?php print $group['id']; ?>"<?php if($user['gid'] == $group['id']){ ?> selected="selected"<?php } ?>><?php print $group['groupname']; ?></option>
|
||||
<?php } ?>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<?php if(ENABLE_LDAP_IMPORT_FEATURE == 1) { ?>
|
||||
<div class="domainrow">
|
||||
<div class="domaincell">LDAP DN:</div>
|
||||
|
Reference in New Issue
Block a user