wpfw_ewei_shopv2/plugin/lottery/template/web/index.html
2023-02-14 19:57:32 +08:00

97 lines
3.5 KiB
HTML

{template '_header'}
<div class="page-heading">
<span class="pull-right">
{ifp 'lottery.add'}
<a class='btn btn-primary btn-sm' href="{php echo webUrl('lottery/add',array('lottery_type'=>1))}"><i class="fa fa-plus"></i> 添加大转盘</a>
<a class='btn btn-primary btn-sm' href="{php echo webUrl('lottery/add',array('lottery_type'=>2))}"><i class="fa fa-plus"></i> 添加刮刮卡</a>
<a class='btn btn-primary btn-sm' href="{php echo webUrl('lottery/add',array('lottery_type'=>3))}"><i class="fa fa-plus"></i> 添加九宫格</a>
{/if}
</span>
<h2>抽奖活动管理 <small>总数: {$total}</small></h2>
</div>
<form action="./index.php" method="get" class="form-horizontal" role="form">
<input type="hidden" name="c" value="site" />
<input type="hidden" name="a" value="entry" />
<input type="hidden" name="m" value="{EWEI_SHOP_V2_MODULE_NAME}" />
<input type="hidden" name="do" value="web" />
<input type="hidden" name="r" value="lottery" />
<div class="page-toolbar row m-b-sm m-t-sm">
<div class="col-sm-4">
<div class="input-group-btn">
<button class="btn btn-default btn-sm" type="button" data-toggle='refresh'><i class='fa fa-refresh'></i></button>
{ifp 'lottery.delete'}
<button class="btn btn-default btn-sm" type="button" data-toggle='batch-remove' data-confirm="确认要删除?" data-href="{php echo webUrl('lottery/index/delete')}"><i class='fa fa-trash'></i> 删除</button>
{/if}
</div>
</div>
<div class="col-sm-6 pull-right">
<div class="input-group">
<input type="text" class="input-sm form-control" name='keyword' value="{$_GPC['keyword']}" placeholder="请输入关键词"> <span class="input-group-btn">
<button class="btn btn-sm btn-primary" type="submit"> 搜索</button> </span>
</div>
</div>
</div>
</form>
{if count($list)>0}
<form action="" method="post" >
<table class="table table-hover table-responsive">
<thead>
<tr>
<th style="width:25px;"><input type='checkbox' /></th>
<th style='width:150px;'>活动名称</th>
<th style='width:150px;'>活动类型</th>
<th style='width:80px;'>参与数</th>
<th>操作</th>
</tr>
</thead>
<tbody>
{loop $list $row}
<tr>
<td>
<input type='checkbox' value="{$row['lottery_id']}"/>
</td>
<td>{$row['lottery_title']}</td>
<td>{if $row['lottery_type']==1}大转盘{elseif $row['lottery_type']==2}刮刮卡{elseif $row['lottery_type']==3}九宫格{/if}</td>
<td>{$row['viewcount']}</td>
<td>
{ifp 'lottery.log'}
<a class='btn btn-default btn-sm' href="{php echo webUrl('lottery/log', array('id' => $row['lottery_id'],'lottery_type'=>$row['lottery_type']))}"><i class='fa fa-qrcode'></i> 参与记录</a>
{/if}
{ifp 'lottery.edit|lottery.view'}
<a class='btn btn-default btn-sm' href="{php echo webUrl('lottery/edit', array( 'id' => $row['lottery_id'],'lottery_type'=>$row['lottery_type']))}"><i class='fa fa-edit'></i> {ifp 'lottery.edit'}编辑{else}查看{/if}</a>
{/if}
{ifp 'lottery.delete'}<a class='btn btn-default btn-sm' data-toggle="ajaxRemove" href="{php echo webUrl('lottery/index/delete', array('id' => $row['lottery_id']))}" title='删除' data-confirm="确认删除此活动吗?"><i class='fa fa-trash'></i> 删除</a>{/if}
</td>
</tr>
{/loop}
</tbody>
</table>
{$pager}
{else}
<div class='panel panel-default'>
<div class='panel-body' style='text-align: center;padding:30px;'>
暂时没有任何活动!
</div>
</div>
{/if}
</form>
{template '_footer'}