qa-ifish7/web/Application/Admin/View/Template/index.html

81 lines
3.4 KiB
HTML

<include file="Inc:header"/>
<style>
.table-bordered .icon-ok{ color:#468847}
.table-bordered .icon-remove{ color:#ff0000}
</style>
<div class="container-fluid">
<div class="main_head">
<div class="main_h1"><h1>{$pagetitle}</h1></div>
<div class="main_add">
<a class="btn btn-inverse" href="{:U('add')}">添加模板</a>
</div>
</div>
<div style="text-align:right; float:right"></div>
<div class="row-fluid">
<div class="span12">
<div class="widget-box">
<div class="widget-content nopadding">
<form method="post" action="__SELF__" onsubmit="return save_form2(this);" class="modelIndex">
<table class="table table-bordered table-striped">
<thead>
<tr>
<th width="5%">排序</th>
<th width="5%">ID</th>
<th width="40%">模型名称</th>
<?php
if(C('LANG_SWITCH_ON')){
?>
<th width="10%">语言</th>
<?php
}
?>
<th width="10%">默认</th>
<th width="15%">操作</th>
</tr>
</thead>
<tbody>
<foreach name="data" item="v" >
<tr>
<td style="text-align: center;"><input type='text' value="{$v.sort}" name="sort[]" class="" style="width:30px;height:10px; margin:0px;"><input type='hidden' value="{$v.template_id}" name="template_id[]"></td>
<td style="text-align: center;">{$v.template_id}</td>
<td style="text-align: left;">{$v.name}</td>
<?php
if(C('LANG_SWITCH_ON')){
?>
<td class="center">{:$LANG_OPT[$v[lang]]?$LANG_OPT[$v[lang]]:'-'}</td>
<?php
}
?>
<td class="center">
<if condition="$v.isdefault eq 1 ">
<i class='icon-ok'></i>
<else />
<i class='icon-remove'></i>
</if>
</td>
<td class="center">
<a href="{:U("setDefault",array("template_id"=>$v[template_id]))}" class="btn btn-success btn-mini ajax_del" confirm_info="确定要设为默认的首页吗?">设为默认</a>
<a href="{:U("editor",array("template_id"=>$v[template_id]))}" class="btn btn-primary btn-mini">修改</a>
<a href="{:U('delete',array("template_id"=>$v[template_id]))}" class="btn btn-danger btn-mini ajax_del">删除</a>
</td>
</tr>
</foreach>
</tbody>
</table>
</form>
</div>
</div>
<div class="widget-bottom">
<button class="btn btn-success" onclick="$('.modelIndex').attr('action','{:U('sort')}');$('.modelIndex').submit();" type="button">修改顺序</button>
</div>
</div>
</div>
</div>
<include file="Inc/footer"/>