<div class="tools" style="margin-bottom:10px;">
    <a class="btn" href="{:addons_url('Advertising://Advertising/add')}">新 增</a>
    <button class="btn ajax-post" target-form="ids" url="{:addons_url('Advertising://Advertising/savestatus',array('status'=>1))}">启 用</button>
    <button class="btn ajax-post" target-form="ids" url="{:addons_url('Advertising://Advertising/savestatus',array('status'=>0))}">禁用</button>
</div>
<table style="text-align: center;">
	<thead>
		<tr>
			<th class="row-selected row-selected"><input class="check-all" type="checkbox"></th>
			<th style="text-align: center;">序号</th>
            <th  style="text-align: center;">标识</th>
            <th  style="text-align: center;">调用代码</th>
			<volist name="listKey" id="vo">
				<th style="text-align: center;">{$vo}</th>
			</volist>
			<th style="text-align: center;">操作</th>
		</tr>
	</thead>
	<tbody>
		<volist name="_list" id="lv" >
		<tr>
			<td><input class="ids" type="checkbox" name="id[]" value="{$lv.id}"></td>
			<td>{$lv.id}</td>
            <td>{$lv.pos}</td>
            <?php
            $lv['code']="{:hook('Advs', '".$lv['pos']."')}";
                echo $lv['code'];
            ?>
            <td><literal>{:hook('Advs', '</literal>{$lv['pos']}<literal>')}</literal></td>


			<volist name="listKey" id="lk">
				<td>{$lv.$key}</td>
			</volist>
			<td>
				<a href="{:addons_url('Advertising://Advertising/edit',array('id'=>$lv['id']))}">编辑</a>
				<if condition="$lv.status eq 1">
				<a class="confirm ajax-get" href="{:addons_url('Advertising://Advertising/forbidden',array('id'=>$lv['id']))}">禁用</a>
				<else/>
				<a class="confirm ajax-get" href="{:addons_url('Advertising://Advertising/off',array('id'=>$lv['id']))}">启用</a>
				</if>
				<a class="confirm ajax-get" href="{:addons_url('Advertising://Advertising/del',array('id'=>$lv['id']))}">删除</a>
			</td>
		</tr>
		</volist>
	</tbody>
</table>
<block name="script">
<script type="text/javascript" src="__STATIC__/uploadify/jquery.uploadify.min.js"></script>
</block>