| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335 |
- <!DOCTYPE html>
- <html lang="en"
- xmlns:th="http://www.thymeleaf.org"
- xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
- layout:decorate="~{home/common/common}">
- <head>
- <meta charset="UTF-8">
- <title th:text="${navigation_name}"></title>
- </head>
- <body layout:fragment="content">
- <!-- 头部导航 -->
- <div th:replace="~{home/common/header :: header}"></div>
- <!--nav-->
- <div class="center_nav">
- <div th:replace="~{home/common/header :: nav}"></div>
- </div>
- <div class="policy-bg">
- <div class="policy-content">
- <!--面包屑-->
- <div class="row">
- <div class="col-sm-6 col-md-6 col-lg-8 hidden-xs" style="padding-left: 0;">
- <ol class="breadcrumb" style="padding-top: 15px;border-bottom: 0px solid #fff;margin-bottom: 0;">
- <li>
- <a th:href="@{/home}">首页</a>
- </li>
- <li class="active"><a><cite>[[${navigation_name}]]</cite></a></li>
- </ol>
- </div>
- <!--搜索框-->
- <div class="col-sm-6 col-md-6 col-lg-4 col-xs-12">
- <div style="display: inline-block;float: right;padding-top: 10px;width: 100%;">
- <span style="display: inline-block;width:100%">
- <input type="text" id="keyWord" name="keyword" placeholder="请输入政策搜索关键词" class="layui-input" style="width: 100%;display: inline-block">
- </span>
- <button id="keywordSearch"style="display: inline-block;float: right;background:none;border:none;">
- <i class=" iconfont icon-sousuo"></i>
- </button>
- </div>
- </div>
- </div>
- <!--内容-->
- <div class="clearfix">
- <div class="clearfix">
- <div class="focus-img swiper-container">
- <div class="swiper-wrapper">
- </div>
- <div class="pagination"></div>
- <!--<img src="/image/banner-bg.jpg">-->
- </div>
- <div class="focus-news">
- <div class="tab-nav">
- <ul class="clearfix">
- <li class="active" dataValue="0"><a href="javascript:;">全部</a></li>
- <li dataValue="4"><a href="javascript:;">国家</a></li>
- <li dataValue="1"><a href="javascript:;">江苏省</a></li>
- <li dataValue="2"><a href="javascript:;">苏州市</a></li>
- <li dataValue="3"><a href="javascript:;">高新区</a></li>
- </ul>
- </div>
- <div class="policy-tab-content">
- <div class="news-tab">
- <ul id="newsList">
- </ul>
- <p class="t-right"><a href="" class="view-more j-more">更多>></a></p>
- </div>
- </div>
- </div>
- </div>
- <div class="p-index-content">
- <div class="policy-index-title">
- <span>
- <p class="p-titile-zh">专项解读</p>
- <p class="p-title-en">Special interpretation</p>
- </span>
- <p class="policy-title-line"></p>
- <a th:href="@{/policy/toSpecialList}" class="special-more">更多>></a>
- </div>
- <div class="p-interpretation-list">
- <ul id="interpretationList" class="clearfix">
- </ul>
- </div>
- </div>
- <div class="p-index-content">
- <div class="policy-index-title">
- <span>
- <p class="p-titile-zh">政策顾问</p>
- <p class="p-title-en">Special interpretation</p>
- </span>
- <p class="policy-title-line"></p>
- </div>
- <div class="p-interpretation-list">
- <div class="p-zcgw p-cx"><a onclick="checkLogin()">创新能力体检</a></div>
- <div class="p-zcgw p-tj"><a onclick="recommend()">项目申报推荐</a></div>
- </div>
- </div>
- <div class="p-index-content">
- <div class="policy-index-title">
- <span>
- <p class="p-titile-zh">分类阅读</p>
- <p class="p-title-en">Category reading</p>
- </span>
- <p class="policy-title-line"></p>
- </div>
- <div class="read-list">
- <ul id="readList" class="clearfix">
- </ul>
- </div>
- </div>
- </div>
- </div>
- </div>
- <!--页底-->
- <div th:replace="~{home/common/footer :: footer}"></div>
- <script>
- $(function () {
- //头部导航栏
- $("li[role='presentation']").removeClass();
- var id = [[${navigation_id}]];
- $("#" + id).parent().attr("class", "active");
- var pagePath = $("meta[name='_ctx']").attr("content");
- pagePath = pagePath.substring(0, pagePath.length - 1);
- var type = "", criteria = "0", isinvalid = "0";
- layui.use('element', function () {
- var element = layui.element; //导航的hover效果、二级菜单等功能,需要依赖element模块
- });
-
- // 搜索
- $("#keywordSearch").on("click",function () {
- var keywordVal = encodeURI($("#keyWord").val());
- window.location.href = pagePath +"/home/policySearchList?lkey="+keywordVal;
- });
- specialData();
- readData();
- getNewsData(0);
- $(".j-more").attr("href",pagePath +"/home/policyList?lb=0");
- $(".tab-nav ul li").on("click",function () {
- var index = $(this).attr("dataValue");
- $(this).addClass("active").siblings().removeClass("active");
- $(".j-more").attr("href",pagePath +"/home/policyList?lb="+index);
- getNewsData(index);
- });
- // 焦点图
- $.ajax({
- url: pagePath+"/policy/radar?apikey=snd_apis&at=1&page=1&pagesize=10",
- type: 'get',
- dataType: 'json',
- success: function (json) {
- json = json.obj;
- var _html = '';
- $.each(json.list, function (index, item) {
- _html += '<div class="swiper-slide">\
- <a href="'+pagePath+'/home/policyDetail?bno='+ item.bno +'" target="_blank">\
- <img src="'+item.picurl+'" />\
- <div class="focus-img-name">'+ item.title +'</div>\
- </a>\
- </div>';
- });
- $(".swiper-wrapper").html(_html);
- var mySwiper = new Swiper('.swiper-container',{
- loop: true,
- autoplay: 3000,
- autoplayDisableOnInteraction : false,
- pagination : '.pagination',
- paginationClickable :true
- });
- }
- });
- // 信息列表
- function getNewsData(lbIndex) {
- $.ajax({
- url: pagePath+"/policy/radar?apikey=snd_apis&at=2&page=1&pagesize=8",
- type: 'get',
- dataType: 'json',
- data:{lb:lbIndex},
- success: function (json) {
- json = json.obj;
- var _html = '';
- var moreHtml = '';
- $.each(json.list, function (index, item) {
- _html += '<li>\
- <span>['+ item.lx +']</span>\
- <a href="'+pagePath+'/home/policyDetail?bno='+ item.bno +'" target="_blank">'+ item.title +'</a>\
- </li>';
- });
- $("#newsList").html(_html);
- }
- });
- }
- // 专项解读
- function specialData() {
- $.ajax({
- url: pagePath+'/policy/radar?apikey=snd_apis&at=3&page=1&pagesize=5',
- type: 'get',
- dataType: 'json',
- success: function (json) {
- json = json.obj;
- var _html = '';
- $.each(json.list, function (index, item) {
- _html += '<li>\
- <a href="'+pagePath+'/home/policySpecialDetail?bno='+ item.bno +'" target="_blank">\
- <img src="'+ item.picurl +'" />\
- <div class="p-interpretation-name">'+ item.title +'</div>\
- </a>\
- </li>';
- });
- $("#interpretationList").html(_html);
- }
- });
- }
- // 分类阅读
- function readData() {
- var colorItem = ["ft-color-deepblue","ft-color-lightred","ft-color-lightblue","ft-color-lightgreen","ft-color-violet","ft-color-orange","ft-color-deepgreen","ft-color-brown","ft-color-lightblue","ft-color-deepred","ft-color-pink","ft-color-deepgreen"];
- var iconItem = ["","","","","","","","","","","",""]
- $.ajax({
- url: pagePath+'/policy/radar?apikey=snd_apis&at=4&page=1&pagesize=12',
- type: 'get',
- dataType: 'json',
- success: function (json) {
- json = json.obj;
- var _html = '';
- $.each(json.list, function (index, item) {
- _html += '<li>\
- <a href="'+pagePath+'/home/policyList?k4='+ item.lb +'">\
- <span class="p-icon-bg '+ colorItem[index] +'"><i class="iconfont">'+ iconItem[index] +'</i></span>\
- <p>'+ item.title +'</p>\
- </a>\
- </li>';
- });
- $("#readList").html(_html);
- }
- })
- }
- });
- function isPermission(){
- $.ajax({
- url: pagePath + "/policy/isPermission",
- type: "get",
- dataType: "json",
- success: function (result) {
- if (result.success){
- // window.location.href = pagePath + "/policy/toPolicyExamination";
- return true;
- }
- else {
- // errorMessage('您还未进行诊断,请在诊断后查看推荐的项目申报!');
- errorMessage(result.message);
- return false;
- }
- }
- });
- }
- function recommend(){
- $.ajax({
- url: pagePath + "/policy/recommendProjectApi",
- type: "get",
- dataType: "json",
- success: function (result) {
- if (result.success){
- checkLogin();
- }
- else {
- errorMessage('您还未进行诊断,请在诊断后查看推荐的项目申报!');
- // errorMessage(result.message);
- }
- }
- });
- }
- function checkLogin() {
- $.ajax({
- url: pagePath + "/home/checkLogin/",
- type: "get",
- dataType: "json",
- data:{
- timeStamp: new Date()
- },
- success: function (result) {
- if (result.success) {
- var obj = result.obj;
- if (obj.isLogin) {
- //已登录
- if(!obj.userType==3){
- errorMessage('仅供企业用户诊断!');
- }else{
- // isPermission();//是否有权限
- $.ajax({
- url: pagePath + "/policy/isPermission",
- type: "get",
- dataType: "json",
- success: function (result) {
- if (result.success){
- window.location.href = pagePath + "/policy/toPolicyExamination";
- }
- else {
- // errorMessage('您还未进行诊断,请在诊断后查看推荐的项目申报!');
- errorMessage(result.message);
- }
- }
- });
- // location.href = pagePath + '/policy/toPolicyExamination';
- }
- } else {
- //errorMessage("请登陆!");
- location.href = pagePath + "/home/login";
- localStorage.setItem("activityUrl", pagePath + '/home/informList/3');
- localStorage.setItem("returnUrl", pagePath + '/home/informList/3');
- localStorage.setItem("requiredUserType", "3");
- localStorage.setItem("errorMsg", "仅供企业用户诊断!");
- }
- } else {
- errorMessage(result.message);
- }
- },
- error: function () {
- errorMessage('系统错误!');
- }
- });
- }
- </script>
- </body>
- </html>
|