重构管理员列表页adminlist.phtml,普通用户列表页list.phtml

This commit is contained in:
Li Heng 2013-12-04 02:22:16 +00:00
parent 48d2740a4b
commit 2c50c49baf
3 changed files with 128 additions and 115 deletions

View File

@ -12,9 +12,7 @@ table thead tr th {background:#EBF2F6;color:#444;}
.high{background:#444;color:#FFF;} .high{background:#444;color:#FFF;}
</style> </style>
<div class="row-fluid"> <div class="row-fluid">
<div class="span3"> <div class="span3"><?= $this->partial('review/left.phtml'); ?></div>
<?= $this->partial('review/left.phtml'); ?>
</div>
<div class="span9"> <div class="span9">
<?php if ($this->msg or $this->messages) :?> <?php if ($this->msg or $this->messages) :?>
<div id="message"> <div id="message">

View File

@ -2,27 +2,31 @@
$this->headTitle($this->config->title->site); $this->headTitle($this->config->title->site);
$this->headTitle('后台管理'); $this->headTitle('后台管理');
$this->headTitle()->setSeparator(' - '); $this->headTitle()->setSeparator(' - ');
$this->headLink()->appendStylesheet('/css/admin.css'); # $this->headLink()->appendStylesheet('/css/admin.css');
$this->breadcrumb('<a href="/">首页</a>'); $this->breadcrumb('<a href="/">首页</a>');
$this->breadcrumb('<a href="/admin/">后台首页</a>'); $this->breadcrumb('<a href="/admin/">后台首页</a>');
$this->breadcrumb('<a href="/admin/user">用户管理</a>'); $this->breadcrumb('<a href="/admin/user">用户管理</a>');
$this->breadcrumb()->setSeparator(' > '); $this->breadcrumb()->setSeparator(' > ');
?> ?>
<div id="leftPanel">
<?= $this->partial('user/left.phtml'); ?>
</div>
<div id="rightPanel"> <style>
<div class="title">管理员列表</div> table thead tr th {background:#EBF2F6;color:#444;}
<table> .high{background:#444;color:#FFF;}
</style>
<div class="row-fluid">
<div class="span3"><?= $this->partial('user/left.phtml'); ?></div>
<div class="span9">
<div style="font-size:26px; font-family:微软雅黑; text-align:center;line-height:30px;">管理员列表</div>
<table class="table table-bordered table-hover table-condensed"><thead>
<thead> <thead>
<tr> <tr>
<td width='150'>用户名</td> <th>用户名</th>
<td width='250'>电子邮箱</td> <th>电子邮箱</th>
<td width='100'>用户类型</td> <th>用户类型</th>
<td width='150'>真实姓名</td> <th>真实姓名</th>
<td width='150'>电话</td> <th>电话</th>
<td width='150'>操作</td> <th>操作</th>
</tr> </tr>
</thead> </thead>
<?php if (count($this->paginator)): ?> <?php if (count($this->paginator)): ?>
@ -44,3 +48,4 @@
</table> </table>
<div class="pagenavi"><?= $this->paginator; ?></div> <div class="pagenavi"><?= $this->paginator; ?></div>
</div> </div>
</div>

View File

@ -2,16 +2,23 @@
$this->headTitle($this->config->title->site); $this->headTitle($this->config->title->site);
$this->headTitle('后台管理'); $this->headTitle('后台管理');
$this->headTitle()->setSeparator(' - '); $this->headTitle()->setSeparator(' - ');
$this->headLink()->appendStylesheet('/css/admin.css'); # $this->headLink()->appendStylesheet('/css/admin.css');
$this->breadcrumb('<a href="/">首页</a>'); $this->breadcrumb('<a href="/">首页</a>');
$this->breadcrumb('<a href="/admin/">后台首页</a>'); $this->breadcrumb('<a href="/admin/">后台首页</a>');
$this->breadcrumb('<a href="/admin/user">用户管理</a>'); $this->breadcrumb('<a href="/admin/user">用户管理</a>');
$this->breadcrumb()->setSeparator(' > '); $this->breadcrumb()->setSeparator(' > ');
?> ?>
<div id="leftPanel"> <style>
<?= $this->partial('user/left.phtml'); ?> table thead tr th {background:#EBF2F6;color:#444;}
.high{background:#444;color:#FFF;}
</style>
<div class="row-fluid">
<div class="span3">
<div id="leftPanel"><?= $this->partial('user/left.phtml'); ?></div>
</div> </div>
<div class="span9">
<?php if ($this->msg or $this->messages) :?> <?php if ($this->msg or $this->messages) :?>
<div id="message"> <div id="message">
<?php if ($this->msg) : ?> <?php if ($this->msg) : ?>
@ -24,34 +31,33 @@
<div id="rightPanel"> <div id="rightPanel">
<div style="font-size:16px;line-height:30px;">用户列表</div> <div style="font-size:26px; font-family:微软雅黑; text-align:center;line-height:30px;">用户列表</div>
<div class="search"> <div class="search">
<form action="/admin/user/search/" method="get"> <form action="/admin/user/search/" method="get" class="search input-append">
<input type="hidden" name="search" value='1' /> <input type="hidden" name="search" value='1' />
<ul> <ul class="inline">
<li><label>姓名</label><input type="text" name="realname" value="<?php echo $this->realname; ?>" /></li> <li><label>姓名</label><input type="text" name="realname" value="<?php echo $this->realname; ?>" class="search-query"/></li>
<li><label>单位</label><input type="text" name="unit" value="<?php echo $this->unit; ?>" /></li> <li><label>单位</label><input type="text" name="unit" value="<?php echo $this->unit; ?>" class="search-query"/></li>
<li><label>项目</label><input type="text" name="project" value="<?php echo $this->project; ?>" /></li> <li><label>项目</label><input type="text" name="project" value="<?php echo $this->project; ?>" class="search-query"/></li>
<li><input type="submit" class="searchbtn" value="搜索" /></li> <li><input type="submit" class="btn" value="搜索" /></li>
</ul> </ul>
</form> </form>
</div><!-- search DIV --> </div><!-- search DIV -->
<table> <table class="table table-bordered table-hover table-condensed"><thead>
<thead>
<tr> <tr>
<td width='150'>用户名</td> <th>用户名</th>
<td width='250'>电子邮箱</td> <th>电子邮箱</th>
<td width='100'>用户类型</td> <th>用户类型</th>
<td width='200'>单位</td> <th>单位</th>
<td width='100'>真实姓名</td> <th>真实姓名</th>
<td width='150'>操作</td> <th>操作</th>
</tr> </tr>
</thead><!-- table's head --> </thead><!-- table's head -->
<?php if (count($this->paginator)): ?> <?php if (count($this->paginator)): ?>
<?php $autoindex=0;?> <?php $autoindex=0;?>
<?php foreach ($this->paginator as $item): ?> <?php foreach ($this->paginator as $item): ?>
<?php $autoindex++;?> <?php $autoindex++;?>
<tr class="<?php if($autoindex%2 == 0) echo 'even'; else echo 'odd'; ?>"> <tr>
<td><?= $item['username']?></td> <td><?= $item['username']?></td>
<td><?= $item['email']; ?></td> <td><?= $item['email']; ?></td>
<td><?= $item['usertype']; ?></td> <td><?= $item['usertype']; ?></td>
@ -70,3 +76,7 @@
</table> </table>
<div class="pagenavi"><?= $this->paginator; ?></div> <div class="pagenavi"><?= $this->paginator; ?></div>
</div> </div>
</div>
</div>