| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165 |
- <include file="public@header"/>
- </head>
- <body>
- <div class="wrap js-check-wrap">
- <ul class="nav nav-tabs">
- <li class="active"><a href="javascript:;">图文列表</a></li>
- <li><a href="{:url('Pic/add')}">添加图文</a></li>
- </ul>
- <form class="well form-inline margin-top-20" method="post" action="{:url('Pic/index')}">
- 分类:
- <select class="form-control" name="type" style="width: 140px;" value="{$params.type}">
- <option value='0'>全部</option>
- <option value='1' <if condition="$params.type eq 1">selected</if>>我们恋爱了</option>
- <option value='2' <if condition="$params.type eq 2">selected</if>>我们结婚了</option>
- <option value='3' <if condition="$params.type eq 3">selected</if>>活动花絮</option>
- </select>
- 关键字:
- <input type="text" class="form-control" name="keyword" style="width: 200px;"
- value="{$params.keyword|default=''}" placeholder="请输入关键字...">
- <input type="submit" class="btn btn-primary" value="搜索"/>
- <a class="btn btn-danger" href="{:url('Pic/index')}">清空</a>
- </form>
- <form class="js-ajax-form" action="" method="post">
- <div class="table-actions">
- <button class="btn btn-danger btn-sm js-ajax-submit" type="submit"
- data-action="{:url('Pic/delete')}" data-subcheck="true" data-msg="您确定删除吗?">
- {:lang('DELETE')}
- </button>
- </div>
- <table class="table table-hover table-bordered table-list">
- <thead>
- <tr>
- <th width="15">
- <label>
- <input type="checkbox" class="js-check-all" data-direction="x" data-checklist="js-check-x">
- </label>
- </th>
- <th width="50">ID</th>
- <th>标题</th>
- <th>分类</th>
- <th>作者</th>
- <th width="160">描述</th>
- <th width="160">添加时间</th>
- <th width="160">发布时间</th>
- <th width="70">状态</th>
- <th width="95">操作</th>
- </tr>
- </thead>
- <foreach name="datas" item="vo">
- <tr>
- <td>
- <input type="checkbox" class="js-check" data-yid="js-check-y" data-xid="js-check-x" name="ids[]"
- value="{$vo.id}" title="ID:{$vo.id}">
- </td>
- <td><b>{$vo.id}</b></td>
- <td>
- {$vo.post_title}
- </td>
- <td>
- <if condition="$vo.type eq 1">
- 我们恋爱了
- <elseif condition="$vo.type eq 2">
- 我们结婚了
- <else>
- 活动花絮
- </if>
- </td>
- <td>{$vo.user_nickname}</td>
- <td>
- {$vo.post_excerpt}
- </td>
- <td>
- <notempty name="vo.create_time">
- {:date('Y-m-d H:i',$vo['create_time'])}
- </notempty>
- </td>
- <td>
- <empty name="vo.published_time">
- 未发布
- <else/>
- {:date('Y-m-d H:i',$vo['published_time'])}
- </empty>
- </td>
- <td>
- {$vo.post_status == 1? '显示':'隐藏'}
- </td>
- <td>
- <a class="btn btn-xs btn-primary" href="{:url('Pic/edit',array('id'=>$vo['id']))}">{:lang('EDIT')}</a>
- <a class="btn btn-xs btn-danger js-ajax-delete"
- href="{:url('Pic/delete',array('ids'=>$vo['id']))}">{:lang('DELETE')}</a>
- </td>
- </tr>
- </foreach>
- </table>
- <ul class="pagination">{$page|default=''}</ul>
- </form>
- </div>
- <script src="__STATIC__/js/admin.js"></script>
- <script>
- function reloadPage(win) {
- win.location.reload();
- }
- $(function () {
- setCookie("refersh_time", 0);
- Wind.use('ajaxForm', 'artDialog', 'iframeTools', function () {
- //批量复制
- $('.js-articles-copy').click(function (e) {
- var ids = [];
- $("input[name='ids[]']").each(function () {
- if ($(this).is(':checked')) {
- ids.push($(this).val());
- }
- });
- if (ids.length == 0) {
- art.dialog.through({
- id: 'error',
- icon: 'error',
- content: '您没有勾选信息,无法进行操作!',
- cancelVal: '关闭',
- cancel: true
- });
- return false;
- }
- ids = ids.join(',');
- art.dialog.open("__ROOT__/index.php?g=portal&m=AdminArticle&a=copy&ids=" + ids, {
- title: "批量复制",
- width: "300px"
- });
- });
- //批量移动
- $('.js-articles-move').click(function (e) {
- var ids = [];
- $("input[name='ids[]']").each(function () {
- if ($(this).is(':checked')) {
- ids.push($(this).val());
- }
- });
- if (ids.length == 0) {
- art.dialog.through({
- id: 'error',
- icon: 'error',
- content: '您没有勾选信息,无法进行操作!',
- cancelVal: '关闭',
- cancel: true
- });
- return false;
- }
- ids = ids.join(',');
- art.dialog.open("__ROOT__/index.php?g=portal&m=AdminArticle&a=move&old_term_id={$term.term_id|default=0}&ids=" + ids, {
- title: "批量移动",
- width: "300px"
- });
- });
- });
- });
- </script>
- </body>
- </html>
|