<?php if (!defined('APP_PATH')) exit;?><!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/html; charset=utf-8" />
<title></title>
<link href="http://127.0.0.5/magic/Data/Public/css/style.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="http://127.0.0.5/magic/Data/Public/js/jquery.js"></script>
<script src="http://127.0.0.5/magic/Data/Public/js/main.js"></script>
</head>
<body>
<div class="place">
	<span>位置：</span>
	<ul class="placeul">
		<li><a href="/">首页</a></li>
		<li><a href="#">系统设置</a></li>
		<li><a href="#">管理员组</a></li>
	</ul>
</div>
<div class="rightinfo">
    <div class="tools">
		<ul class="toolbar">
			<li><a href="javascript:" onclick="load('添加管理员组','?r=admin-group-edit','350px','280px')"><span><img src="http://127.0.0.5/magic/Data/Public/images/t01.png" /></span>添加管理员组</a></li>
			<li><a href="?r=admin"><span><img src="http://127.0.0.5/magic/Data/Public/images/d09.png" width="24" height="24" /></span>管理员列表</a></li>
		</ul>
    </div>  
   <div class="formtitle1"><span>管理员组列表</span></div>
   <iframe id="blank" name="blank"  style="display:none" ></iframe>
    <table class="tablelist">
		<thead>
    	<tr>
			<th width="80" align="center">ID</th>
			<th width="150" align="center">名称</th>
			<th align="center">描述</th>
			<th width="150" align="center">创建时间</th>
			<th width="150" align="center">状态</th>
			<th width="200" align="center">操作</th>
		</tr>
		</thead>
		<tbody>
		<?php foreach ($role as $vo){?>
		<tr>
			<td align="center"><?php echo $vo['rid'];?></td>
			<td align="center"><?php echo $vo['name'];?></td>
			<td align="center"><?php echo $vo['desc'];?></td>
			<td align="center"><?php echo date('Y-m-d H:i:s',$vo['pubtime']);?></td>
			<td align="center"><img src="http://127.0.0.5/magic/Data/Public/images/ico-0<?php echo $vo['status'];?>.png" width="15" height="15"></td>
			<td align="center">
			<?php if($vo['rid']==1){ ?>
			<i style="color:#ccc;font-style:normal">编辑</i> | <i style="color:#ccc;font-style:normal">权限</i> | <i style="color:#ccc;font-style:normal">删除</i>
			<?php }else{ ?>
			<a href="javascript:"  onclick="load('编辑管理员组','?r=admin-group-edit&rid=<?php echo $vo['rid'];?>','350px','280px')";>编辑</a> | <a href="?r=admin-rbac&rid=<?php echo $vo['rid'];?>">权限</a> | <a  href="javascript:" onclick="confirms('组别删除后将无法恢复，<br>请谨慎操作，确认删除？','?r=admin-group-del&rid=<?php echo $vo['rid'];?>')">删除</a>
			<?php }?>
			</td>
		</tr>
		<?php }?>
		 </tbody>
		</table>
</div>
 <script type="text/javascript">$('.tablelist tbody tr:odd').addClass('odd');</script>
</body>
</html>