<!--
|
功能描述:新闻动态列表
|
-->
|
<!DOCTYPE html>
|
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:layout="http://www.w3.org/1999/xhtml"
|
xmlns:th="http://www.w3.org/1999/xhtml" layout:decorator="MasterPage/Layout">
|
<head>
|
<meta charset="utf-8" />
|
<meta http-equiv="X-UA-Compatible" content="IE=Edge" />
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
<link th:href="@{${pubzyWebRoot} + 'media/css/bootstrap-tree.css'}" rel="stylesheet" type="text/css" />
|
<link rel="stylesheet" th:href="@{${pubzyWebRoot} + 'BootStrap4/expand/plugins/portlet/css/portlet.css'}" />
|
<link th:href="@{${pubzyWebRoot} + 'media/css/select2_metro.css'}" type="text/css" rel="stylesheet" />
|
<link th:href="@{${pubzyWebRoot} + 'media/css/pagination.css'}" type="text/css" rel="stylesheet" />
|
<link rel="stylesheet" th:href="@{${pubzyWebRoot} + 'BootStrap4/assets/plugins/bootstrap-datepicker/old_datepaker/datepicker.css'}" />
|
<link th:href="@{${pubzyWebRoot} + 'zTree/css/metroStyle/metroStyle.css'}" rel="stylesheet" type="text/css" />
|
<script th:src="@{${pubzyWebRoot} + 'jqPaginator/jqpaginator.min.js'}"></script>
|
<script th:src="@{${pubzyWebRoot} + 'media/js/tabPages.js'}"></script>
|
<script th:src="@{${pubzyWebRoot} + 'media/js/winPro.js'}"></script>
|
<script th:src="@{${pubzyWebRoot} + 'echarts/echarts.min-3.0.js'}" type="text/javascript"></script>
|
<script th:src="@{${pubzyWebRoot} + 'media/js/select2.min.js'}" type="text/javascript"></script>
|
<script th:src="@{${pubzyWebRoot} + 'zTree/js/jquery.ztree.all.js'}"></script>
|
<script th:src="@{${pubzyWebRoot} + 'zTree/js/jquery.ztree.core.js'}"></script>
|
<script th:src="@{${pubzyWebRoot} + 'zTree/js/jquery.ztree.exedit.js'}"></script>
|
<script th:src="@{${pubzyWebRoot} + 'zTree/js/jquery.ztree.excheck.js'}"></script>
|
<script src="/js/openresource.js"></script>
|
<style type="text/css">
|
.div_left{
|
/*float: left;*/
|
position: fixed;
|
width:260px;
|
height: 500px;
|
}
|
.div_right{
|
/*float: left;*/
|
margin-left: 270px;
|
height: 100%;
|
}
|
.div_catalog{
|
float: left;
|
width:100%;
|
color: white;
|
}
|
.div_catalog div{
|
width: 100%;
|
height: 50px;
|
border-bottom: 1px solid;
|
cursor:pointer;
|
}
|
.div_catalog div:first-child{
|
background-color: #0E51A6;
|
}
|
.div_catalog div:not(:first-child){
|
background-color: #0B92D4;
|
}
|
.div_catalog div:not(:first-child):hover{
|
background-color: #17A6EC;
|
}
|
.span_left{
|
float: left;
|
font-size:17px;
|
line-height:47px;
|
margin-left: 20px;
|
}
|
.span_right{
|
float: right;
|
fonst-size:14px;
|
line-height: 50px;
|
margin-right: 10px;
|
}
|
.div_search{
|
background-color:white;
|
height: 72px;
|
width: 100%;
|
padding: 18px 0px 0px 27px;
|
}
|
.div_main{
|
color:grey;
|
height: 500px;
|
font-size: 14px;
|
}
|
.div_zy{
|
background-color: white;
|
padding: 18px 0px 0px 27px;
|
border-left:3px solid #E0DEDB;
|
height: 150px;
|
}
|
.div_zy:first-child{
|
border-top: 1px solid #E0DEDB;
|
}
|
.div_zy:not(:first-child){
|
margin-top: 10px;
|
}
|
.sort{
|
cursor: pointer;
|
padding: 2px 15px;
|
}
|
.shtype{
|
cursor: pointer;
|
padding: 2px 15px;
|
}
|
|
.clickCss {
|
color: #EEE683;
|
background-color: #17A6EC !important;
|
}
|
</style>
|
<script type="text/javascript" th:inline="javascript">
|
var formdata = {};
|
$(function () {
|
typeListJson = [[${TypeListJson}]];
|
$(".div_right").css("width",window.innerWidth-300+"px");
|
showType();
|
});
|
function showType(){
|
var list = eval(typeListJson);
|
var html = "<div onclick=\"leftChange(this)\" key=\"all\"><span class=\"span_left\">新闻动态</span></div>";
|
for(var i =0;i<list.length;i++){
|
html+="<div onclick=\"leftChange(this)\" key='"+list[i].key+"'><span class='span_left'>"+list[i].value
|
+"</span><span class='span_right'>资讯数(" + list[i].zycount + "条)> </span></div>";
|
}
|
$(".div_catalog").html(html);
|
}
|
function changepage(num) {
|
var url = 'ZiXunDataList?page=' + num;
|
$("#block").load(url, formdata, function () { //加载图文列表
|
var Page = Number(document.getElementById("curren").value);
|
var Count = Number(document.getElementById("total").value);
|
if (Count != 0) {
|
$('#Paginator').jqPaginator({
|
totalCounts: Count,
|
pageSize: 15,
|
currentPage: Page,
|
first: '<li class="first"><a href="javascript:void(0);">首页</a></li>',
|
prev: '<li class="prev"><a href="javascript:void(0);">上一页</a></li>',
|
next: '<li class="next"><a href="javascript:void(0);">下一页</a></li>',
|
last: '<li class="last"><a href="javascript:void(0);">末页</a></li>',
|
page: '<li class="page"><a href="javascript:void(0);">{{page}}</a></li>',
|
onPageChange: function (num) {
|
if (num != Page) {
|
changepage(num);
|
}
|
}
|
});
|
}
|
});
|
}
|
//左边类型切换
|
function leftChange(obj){
|
$(".div_catalog div:not(:first-child)").each(function () {
|
if($(this).attr("key") == $(obj).attr("key")){
|
$(this).attr("isselect",true);
|
$(this).addClass("clickCss");
|
}else {
|
$(this).attr("isselect",false);
|
$(this).removeClass("clickCss");
|
}
|
})
|
Search();
|
}
|
</script>
|
<script>
|
//查询事件
|
function Search() {
|
var thissystype = "";
|
$(".div_catalog div").each(function () {
|
if($(this).attr("isselect") == "true" || $(this).attr("isselect") == true){
|
thissystype = $(this).attr("key");
|
}
|
})
|
formdata = {
|
title:$("#title").val(),
|
type:thissystype
|
};
|
$("#block").load('ZiXunDataList', formdata, function () {
|
var Page =Number(document.getElementById("curren").value);
|
var Count =Number(document.getElementById("total").value);
|
if(Count != 0) {
|
$('#Paginator').jqPaginator({
|
totalCounts: Count,
|
pageSize: 15,
|
currentPage: Page,
|
first: '<li class="first"><a href="javascript:void(0);">首页</a></li>',
|
prev: '<li class="prev"><a href="javascript:void(0);">上一页</a></li>',
|
next: '<li class="next"><a href="javascript:void(0);">下一页</a></li>',
|
last: '<li class="last"><a href="javascript:void(0);">末页</a></li>',
|
page: '<li class="page"><a href="javascript:void(0);">{{page}}</a></li>',
|
onPageChange: function (num) {
|
if(num!=Page){
|
changepage(num);
|
}
|
}
|
});
|
}
|
});
|
}
|
$(function(){
|
var url ='ZiXunDataList?page='+1;
|
formdata = {
|
sort:'pubdate'
|
};
|
$("#block").load(url, formdata, function () { //加载图文列表
|
var Page =Number(document.getElementById("curren").value);
|
var Count =Number(document.getElementById("total").value);
|
if(Count != 0) {
|
$('#Paginator').jqPaginator({
|
totalCounts: Count,
|
pageSize: 15,
|
currentPage: Page,
|
first: '<li class="first"><a href="javascript:void(0);">首页</a></li>',
|
prev: '<li class="prev"><a href="javascript:void(0);">上一页</a></li>',
|
next: '<li class="next"><a href="javascript:void(0);">下一页</a></li>',
|
last: '<li class="last"><a href="javascript:void(0);">末页</a></li>',
|
page: '<li class="page"><a href="javascript:void(0);">{{page}}</a></li>',
|
onPageChange: function (num) {
|
if(num!=Page){
|
changepage(num);
|
}
|
}
|
});
|
}
|
});
|
})
|
function changepage(num) {
|
var url ='ZiXunDataList?page='+num;
|
$("#block").load(url, formdata, function () { //加载图文列表
|
var Page =Number(document.getElementById("curren").value);
|
var Count =Number(document.getElementById("total").value);
|
if(Count != 0) {
|
$('#Paginator').jqPaginator({
|
totalCounts: Count,
|
pageSize: 15,
|
currentPage: Page,
|
first: '<li class="first"><a href="javascript:void(0);">首页</a></li>',
|
prev: '<li class="prev"><a href="javascript:void(0);">上一页</a></li>',
|
next: '<li class="next"><a href="javascript:void(0);">下一页</a></li>',
|
last: '<li class="last"><a href="javascript:void(0);">末页</a></li>',
|
page: '<li class="page"><a href="javascript:void(0);">{{page}}</a></li>',
|
onPageChange: function (num) {
|
if(num!=Page){
|
changepage(num);
|
}
|
}
|
});
|
}
|
});
|
}
|
</script>
|
</head>
|
<body>
|
<div layout:fragment="content">
|
<input type="hidden" id="resourceclass" />
|
<div class="content-page" style="min-height: 978px !important; margin-top: 8px;background-color: #F6F5F4;margin-left:0px;margin-left:10px">
|
<div class="div_left">
|
<div class="div_catalog">
|
</div>
|
</div>
|
<div class="div_right">
|
<div class="div_search">
|
<div class="row" style="float: left;width: 100%;">
|
<div class="col-xs-12 col-sm-6 col-md-4 col-lg-3 col-xl-12 DivHeight" style="height:40px;padding-right: 20px;">
|
<div class="control-group control-group col-xl-8 DivHeight">
|
<div class="controls input-icon">
|
<div style="float: left;width: 70%;">
|
<input type="text" id="title" name="title" value="" style="height: 36px;" class="form-control col-sm-12" placeholder="请输入关键字" />
|
</div>
|
<div onclick="Search()" class="col-sm-1" style="cursor: pointer;height: 36px; text-align: center;border-radius: 4px; font-size: 20px; border-left:1px solid rgb(221, 221, 221); float: left;margin-left: 5px; background-color: #0B92D4;">
|
<i class="fa fa-search" style="color: #fff;"></i>
|
</div>
|
</div>
|
</div>
|
<div style="text-align: right; line-height: 35px;">
|
<span style="font-weight: bold;">资讯数量: <span id="countNum" style="color: red; font-size: 16px;"></span> 条</span>
|
</div>
|
</div>
|
</div>
|
</div>
|
<div class="div_main" id="block">
|
</div>
|
<div id="grid" style="display: none"></div>
|
</div>
|
</div>
|
</div>
|
</body>
|
</html>
|