2023-01-29 10:26:52 +08:00

206 lines
6.3 KiB
HTML

{extend name="public/base"/}
{block name="body"}
<style>
.table-responsive{min-height:600px;}
.main-box-body .navs {
padding-left: 0;
list-style: none;
display: block;
clear:both;
}
.main-box-body .navs>li {
float: left;
}
.main-box-body .navs>li>a {padding:2px 5px;}
.main-box-body .navs .active{background:#03A9F3;color:#fff;}
//.main-box-body .nav>li>a {padding:2px 5px;}
//.main-box-body .nav .active{background:#03A9F3;color:#fff;}
.info{max-width:300px;font-size:12px;}
.desc{margin-top: 10px;
text-align: justify;
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 3;
-o-text-overflow: ellipsis;
text-overflow: ellipsis;
overflow: hidden;
height: 4.5em;
}
.clear{clear:both;}
.ml {
margin-left: 10px;
}
.ant-tag {
display: inline-block;
line-height: 20px;
height: 22px;
padding: 0 8px;
-webkit-border-radius: 4px;
-moz-border-radius: 4px;
border-radius: 4px;
border: 1px solid #e9e9e9;
background: #f3f3f3;
font-size: 12px;
-webkit-transition: all .3s cubic-bezier(.215,.61,.355,1);
-o-transition: all .3s cubic-bezier(.215,.61,.355,1);
-moz-transition: all .3s cubic-bezier(.215,.61,.355,1);
transition: all .3s cubic-bezier(.215,.61,.355,1);
opacity: 1;
margin-right: 8px;
cursor: pointer;
white-space: nowrap;
}
.ant-tag-red {
color: #f04134;
background: #fcdbd9;
border-color: #fcdbd9;
}
</style>
<div class="main-box clearfix">
<header class="main-box-header clearfix">
<div class="pull-left">
<ul class="nav nav-tabs">
<li >
<a href="{:url('recommend')}">本周推荐</a>
</li>
<li >
<a href="{:url('index')}">内推榜单(全书库)</a>
</li>
<li class="active">
<a href="{:url('hot')}">派单榜单</a>
</li>
{if $Think.session.user_auth.group != 4&& $Think.session.user_auth.group != 3}
<li>
<a href="{:url('admin/ad/index')}"> 幻灯推荐</a>
</li>
<li>
<a href="{:url('admin/limitedfree/index')}">限时免费</a>
</li>
{/if}
</ul>
</div>
<div class="pull-right">
</div>
</header>
<div class="main-box-body clearfix">
<div class="table-responsive clearfix">
<div class="table-responsive clearfix">
<table class="table table-hover">
<thead>
<tr>
{volist name="grid['grids']" id="item"}
<th>{$item['title']}</th>
{/volist}
<th>已推次数</th>
</tr>
</thead>
<tbody>
{if condition="empty($list)"}
{php}
$cow = count($grid['grids'])+2;
{/php}
<tr>
<td colspan="{$cow}" align="center">暂无数据!</td>
</tr>
{else/}
{volist name="list" id="item" key="k"}
<tr>
{volist name="grid['grids']" id="vo"}
{if isset($vo['format'])}
<td>{$item[$vo['field'][0]]|$vo['format']}</td>
{elseif $vo['field'][0] == 'title'}
<td>
<a href="{:url('admin/chapter/index?model_id='.$model_id,array('id'=>$item['id']))}">{$item[$vo['field'][0]]}</a><i class="fa fa-question-circle" title="" data-toggle="tooltip" data-original-title="点击查看章节"></i>
<div class="info">
<p class="desc">{$item['intro']}……
</p>
<p class="pull-left"><span>{$item['chapters']}章</span><span class="ml">{$item['size']/10000|round=###,1}万字</span></p>
<p class="pull-right"><span class="book-catagory-tag">{$item['keywords']}</span></p>
</div>
</td>
{elseif $vo['field'][0] == 'cover'}
<td>
<a href="{:url('admin/chapter/index?model_id='.$model_id,array('id'=>$item['id']))}"><img src="{$item[$vo['field'][0]]?$item[$vo['field'][0]]:"/public/novel/images/default.jpg"}" width="100" height="" alt="" /></a>
</td>
{elseif $vo['field'][0] == 'category_id'}
<td>
{$item[$vo['field'][0]]|get_document_field='category',###,'id','title'}</td>
{elseif $vo['field'][0] == 'channel'}
<td>
{switch item[$vo['field'][0]] }
{case 1 }男频{/case}
{case 2}女频{/case}
{default /}通用
{/switch}
</td>
{elseif $vo['field'][0] == 'fullflag'}
<td>{eq name="item[$vo['field'][0]]" value="1"}
已完结
{else/}
连载中{/eq}</td>
{elseif $vo['field'][0] == 'index'}
<td>{if condition="($item[$vo['field'][0]] == 100)"} {$item[$vo['field'][0]]}(SS级)
{elseif condition="($item[$vo['field'][0]] >= 95) and ($item[$vo['field'][0]] <= 99)"/}{$item[$vo['field'][0]]}(S级)
{elseif condition="($item[$vo['field'][0]] >= 90) and ($item[$vo['field'][0]] < 95)"/}
{$item[$vo['field'][0]]}(A级)
{else /} -
{/if}</td>
{else/}
<td>{$item[$vo['field'][0]]}</td>
{/if}
{/volist}
<td><a href="{:url('admin/spread/index',array('type'=>1,'urltype'=>2))}" target="_blank">{$item['id']|get_spread=###,2}(内推)</a><br/>
<a href="{:url('admin/spread/index',array('type'=>1,'urltype'=>1))}" target="_blank">{$item['id']|get_spread=###,1}(派单)</a></td>
</tr>
{/volist}
{/if}
</tbody>
</table>
</div>
{$page}
</div>
</div>
</div>
{/block}
{block name="script"}
<script type="text/javascript" src="/public/js/bootstrap-editable.min.js"></script>
<script type="text/javascript">
$(function(){
$.fn.editable.defaults.mode = 'popup';
$.fn.editableform.buttons = '<button type="submit" class="btn btn-success editable-submit btn-mini"><i class="fa fa-check-square-o fa-white"></i></button>' +
'<button type="button" class="btn editable-cancel btn-mini"><i class="fa fa-times"></i></button>';
$('.editable').editable();
$('#ajax-href').click(function() {
var target, query, form;
var url = "{:url('novel/setprice')}";
var target_form = $(this).attr('target-priceform');
var that = this;
var nead_confirm = false;
if (($(this).attr('type') == 'submit') || (target = $(this).attr('href')) || (target = $(this).attr('url'))) {
form = $('.' + target_form);
query = form.serialize();
if (query)
{
window.location.href= url.replace('.html','')+"?"+query;
}else{
updateAlert('非法操作', 'danger');
setTimeout(function() {
location.reload();
}, 1500);
}
}
})
})
</script>
{/block}