122 lines
4.7 KiB
HTML
122 lines
4.7 KiB
HTML
{extend name="public/base"/}
|
|
{block name="body"}
|
|
<style>
|
|
.table-responsive{min-height:600px;}
|
|
</style>
|
|
|
|
<div class="main-box clearfix">
|
|
<header class="main-box-header clearfix">
|
|
<div class="pull-left">
|
|
<h2>{$meta_title}</h2>
|
|
</div>
|
|
<div class="pull-right">
|
|
<a class="btn btn-primary" href="{:url('admin/apptopiccontent/add?model_id='.$model_id,array('topicid'=>$topicid))}">新增</a>
|
|
<button class="btn btn-danger ajax-post confirm" url="{:url('admin/apptopiccontent/del?model_id='.$model_id)}" target-form="ids">删 除</button>
|
|
</div>
|
|
</header>
|
|
<div class="main-box-body clearfix">
|
|
<div class="row">
|
|
<form method="get">
|
|
<div class="col-sm-12 col-md-4 col-lg-3">
|
|
<input type="text" class="form-control" name="keyword" value="{$keyword|default=''}" placeholder="请输入关键字">
|
|
</div>
|
|
{if isset($cate_list)}
|
|
<div class="col-sm-12 col-md-4 col-lg-3">
|
|
<select name="category" id="category" class="form-control">
|
|
<option value="">请选择栏目</option>
|
|
{volist name="cate_list" id="item"}
|
|
<option value="{$item['id']}" {if isset($category) && $item['id'] == $category}selected{/if}>{$item['title_show']}</option>
|
|
{/volist}
|
|
</select>
|
|
</div>
|
|
{/if}
|
|
<div class="col-sm-12 col-md-4">
|
|
<button class="btn btn-primary" type="submit">搜索</button>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
<div class="table-responsive clearfix">
|
|
|
|
<div class="table-responsive clearfix">
|
|
<table class="table table-hover">
|
|
<thead>
|
|
<tr>
|
|
<th width="30"><input class="checkbox check-all" type="checkbox"></th>
|
|
{volist name="grid['grids']" id="item"}
|
|
<th>{$item['title']}</th>
|
|
{/volist}
|
|
<th>操作</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{if condition="empty($list)"}
|
|
{php}
|
|
$cow = count($grid['grids'])+2;
|
|
{/php}
|
|
<tr>
|
|
<td colspan="{$cow}" align="center">暂无数据!</td>
|
|
</tr>
|
|
{else/}
|
|
{volist name="list" id="item"}
|
|
<tr>
|
|
<td><input class="ids row-selected" type="checkbox" name="id[]" value="{$item['id']}"></td>
|
|
{volist name="grid['grids']" id="vo"}
|
|
{if isset($vo['format'])}
|
|
<td>{$item[$vo['field'][0]]|$vo['format']}</td>
|
|
{elseif $vo['field'][0] == 'model'}
|
|
<td>{$item[$vo['field'][0]]==1?"小说":"漫画"}</td>
|
|
{elseif $vo['field'][0] == 'cover'}
|
|
<td><img src="{$item[$vo['field'][0]]}" width="50" ></td>
|
|
{elseif $vo['field'][0] == 'status'}
|
|
<td>{$item[$vo['field'][0]]==1?"正常":"禁用"}</td>
|
|
{elseif $vo['field'][0] == 'content'}
|
|
<td>{$item[$vo['field'][0]]|msubstr=0,50,'utf-8',true}</td>
|
|
|
|
{else/}
|
|
<td>{$item[$vo['field'][0]]}</td>
|
|
{/if}
|
|
{/volist}
|
|
<td>
|
|
<a href="{:url('admin/apptopiccontent/edit?model_id='.$model_id,array('id'=>$item['id']))}" >编辑</a>
|
|
<a href="{:url('admin/apptopiccontent/del?model_id='.$model_id,array('id'=>$item['id']))}" class="ajax-get confirm">删除</a>
|
|
<div class="btn-group">
|
|
<button type="button" class="btn btn-xs btn-info dropdown-toggle" data-toggle="dropdown">
|
|
更多操作 <span class="caret"></span>
|
|
</button>
|
|
<ul class="dropdown-menu dropdown-menu-right">
|
|
{if isset($item['is_top'])}
|
|
{if in_array(1,explode(',',$item['is_top']))}
|
|
<li><a href="{:url('admin/apptopiccontent/unsettop?model_id='.$model_id,array('id'=>$item['id'],'is_top'=>'1'))}" class="ajax-get">取消热门</a></li>
|
|
{else/}
|
|
<li><a href="{:url('admin/apptopiccontent/settop?model_id='.$model_id,array('id'=>$item['id'],'is_top'=>'1'))}" class="ajax-get">热门</a></li>
|
|
{/if}
|
|
{if in_array(2,explode(',',$item['is_top']))}
|
|
<li><a href="{:url('admin/apptopiccontent/unsettop?model_id='.$model_id,array('id'=>$item['id'],'is_top'=>'2'))}" class="ajax-get">取消推荐</a></li>
|
|
{else/}
|
|
<li><a href="{:url('admin/apptopiccontent/settop?model_id='.$model_id,array('id'=>$item['id'],'is_top'=>'2'))}" class="ajax-get">推荐</a></li>
|
|
{/if}
|
|
{/if}
|
|
{if isset($item['status'])}
|
|
{if $item['status']}
|
|
<li><a href="{:url('admin/apptopiccontent/status?model_id='.$model_id,array('id'=>$item['id'],'status'=>'0'))}" class="ajax-get">取消审核</a></li>
|
|
{else/}
|
|
<li><a href="{:url('admin/apptopiccontent/status?model_id='.$model_id,array('id'=>$item['id'],'status'=>'1'))}" class="ajax-get">审核</a></li>
|
|
{/if}
|
|
{/if}
|
|
|
|
|
|
</ul>
|
|
</div>
|
|
|
|
</td>
|
|
</tr>
|
|
{/volist}
|
|
{/if}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
{$page}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{/block} |