You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

128 lines
4.2 KiB
HTML

<extend name="Public/base"/>
<block name="body">
<!-- 标题栏 -->
<div class="cf main-place top_nav_list navtab_list">
{:W('Index/navigation',array('value'=>'Site/channel','compare'=>'Adv/promote_adv_pos_lists'))}
<h3 class="page_title">广告管理</h3>
<p class="description_text"></p>
</div>
<div class="tab_nav stabnav17112 jstabnav box_mt">
<ul>
<li class="">
<a href="{:U('Adv/promote_adv_pos_lists')}">广告位列表</a>
</li>
<li class="current">
<a href="{:U('Adv/promote_adv_lists')}">广告列表</a>
</li>
</ul></div>
<div class="cf top_nav_list">
<empty name="model.extend">
<div class="fl button_list">
<div class="tools">
<a class=" ajax-post confirm " target-form="ids" url="{:U('del_adv?model='.$model['id'])}"><span class="button_icon button_icon2"></span>删除</a>
</div>
</div>
</empty>
<!-- 高级搜索 -->
<div class="jssearch fr cf search_list">
</div>
</div>
<!-- 数据列表 -->
<div class="data_list">
<div class="">
<table>
<!-- 表头 -->
<thead>
<tr>
<th>
<input class="check-all" type="checkbox">
</th>
<th>编号</th>
<th>广告标题</th>
<th>广告链接</th>
<th>所属广告位</th>
<th>开始时间</th>
<th>结束时间</th>
<th>打开方式</th>
<th>操作</th>
</tr>
</thead>
<!-- 列表 -->
<tbody>
<empty name="list_data" >
<tr>
<td colspan="9" class="text-center">aOh! 暂时还没有内容!</td>
</tr>
<else />
<volist name="list_data" id="data">
<tr>
<td><input class="ids" type="checkbox" value="{$data['id']}" name="ids[]"></td>
<td>{$data['id']}</td>
<td>{$data['title']}</td>
<td>{$data['url']}</td>
<td>{:get_adv_pos_title($data['pos_id'])}</td>
<td>{:set_show_time($data['start_time'],'','forever')}</td>
<td>{:set_show_time($data['end_time'],'','forever')}</td>
<td>
<switch name="data['target']" >
<case value="_blank" >新页面</case>
<case value="_self">本页面</case>
<default />未知
</switch></td>
<td>
<a href="{:U('promote_edit_adv',array('id'=>$data['id'],'model'=>$model['id']))}">编辑</a>
<a href="{:U('del_adv?ids='.$data['id'])}" class="ajax-get confirm" target-form="ids">删除</a>
</td>
</tr>
</volist>
</empty>
</tbody>
</table>
</div>
</div>
<div class="page">
{$_page|default=''}
</div>
</block>
<block name="script">
<script src="__STATIC__/layer/layer.js"></script>
<script src="__STATIC__/layer/extend/layer.ext.js"></script>
<script type="text/javascript">
$(function(){
//导航高亮
highlight_subnav('{:U('Site/channel')}');
Think.setValue('row','{:I("row",10)}');
//搜索功能
$("#search").click(function(){
var url = $(this).attr('url');
var query = $('.jssearch').find('input').serialize();
query = query.replace(/(&|^)(\w*?\d*?\-*?_*?)*?=?((?=&)|(?=$))/g,'');
query = query.replace(/^&/g,'');
if( url.indexOf('?')>0 ){
url += '&' + query;
}else{
url += '?' + query;
}
window.location.href = url;
});
//回车自动提交
$('.jssearch').find('input').keyup(function(event){
if(event.keyCode===13){
$("#search").click();
}
});
})
</script>
</block>