Files
journal_com/js/scientist.js
@fawn-nine 465c99ac98 .
2023-07-03 16:48:01 +08:00

8756 lines
499 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
// 左边引进去
// $('.art_side').load('./side_in.html');
// 底部
$('.footer').load('footer_in.html')
// 首页内容
function scien_list() {
}
// 首页中侧内容
function sy_index() {
Jour_num = '1';
localStorage.setItem("Journals_title", 'Traditional Medicine Research.');
// 上侧期刊列表数据
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getJournalList',
data: {},
beforeSend: function () {
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.journalList;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].title != 'tmRxiv') {
str += '<li><a target="_blank" href="/' + arr[i].usx + '">' +
arr[i].title + '</a></li>'
}
}
$('.exten_sion .es_jour').html(str);
} else {
ShowDanger("请求失败!");
}
}
})
// 上面智慧搜索话题
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getAllTopics',
data: {},
beforeSend: function () {
},
success: function (result) {
if (result.code == 0) {
var old_arry = result.data.topic;
var new_arry = result.data.topic;
new_arry = old_arry.map(o => {
return {id: o.base_topic_id, text: o.title}
})
for (var i = 0; i < old_arry.length; i++) {
new_arry[i].children = old_arry[i].children.map(o => {
return {id: o.base_topic_id, text: o.title}
})
}
$('#com_index').selectivity({
allowClear: true,
items: new_arry,
placeholder: 'Please select a topic'
})
$('.es_serch_btn').click(function () {
$('.es_serch_span').css('display', 'none')
if ($('#com_index').selectivity('val') == null) {
$('.es_serch_span').css('display', 'block')
ShowDanger("Request was aborted");
} else {
window.open("atr_wisdom.html?&wis_dom=" + $('#com_index').selectivity('val'));
}
})
} else {
ShowDanger("请求失败!");
}
}
})
//中侧专刊列表Open Special Issues
$.ajax({
type: 'post', url: apiUrl + 'api/Special/getAllSpecials',
data: {},
success: function (result) {
if (result.code == 0) {
var arr = result.data.specials;
var str = "";
for (var i = 0; i < 2; i++) {
if ($.cookie("username") != undefined && $.cookie("user_id") != undefined) {
var co_sp_user = 'contribu_list.html?J_num=' + arr[i].journal_id + '&&special_id=' + arr[i].journal_special_id;
} else {
var co_sp_user = 'contribu_login.html?J_num=' + arr[i].journal_id + '&&special_id=' + arr[i].journal_special_id;
}
str += '<li><a href="/' + arr[i].usx + '" target="_blank"><img src="' + imgjourUrl + arr[i].icon + '"></a>' +
'<div><a href="gue_cont.html?J_num=' + arr[i].journal_id + '&&Gu_num=' + arr[i].journal_special_id + '" target="_blank">' + arr[i].title + '</a>' +
'<span><font style="color: #006699;margin-right: 5px">Journal:</font>' + arr[i].journaltitle + '</span>' +
'<span><font style="color: #006699;margin-right: 5px">Guest Editor:</font>' + arr[i].editor + '</span>' +
'<span><font style="color: #006699;margin-right: 5px">Deadline:</font>' + arr[i].deadline + '</span>' +
'<div class="gue_s_btn"><a href="gue_cont_gea.html?J_num=' + arr[i].journal_id + '&&Gu_num=' + arr[i].journal_special_id + '" class="gue_appli" target="_blank">Guest Editor Application</a>' +
'<a href="' + co_sp_user + '" class="gue_submin" target="_blank">Submit Article</a>' +
'</div></div><br clear="both"></li>'
}
$('.sy_splis>div>a').attr('href', 'artihom_list.html?J_num=' + Jour_num + '&issu_id=' + Jour_num);
$('.sy_splis>div>ul.sy_spls_list').html(str + '<br clear="both">');
} else {
// ShowDanger("请求失败!");
$('.sy_splis').css('display', 'none')
}
},
error: function () {
ShowDanger("error");
}
})
// 中下侧New Papers文章
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getMainArticles',
data: {},
success: function (result) {
if (result.code == 0) {
var arr = result.data.articles;
var str1 = "";
var str2_1 = "";
var str2_2 = "";
var str3 = "";
var str1_num = 0;
var str2_num_1 = 0;
var str3_num = 0;
for (var i = 0; i < arr.length; i++) {
if (i == 0) {
str1_num = str1_num + 1
str1 += '<img src="' + imgarticleUrl + arr[i].icon + '" alt="">' +
'<div><span>' + arr[i].abbr + '. | <a style="color: #fff" target="_blank" href="/' + arr[i].usx + '">' + arr[i].journal_short + '</a></span>' +
'<a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '">' +
'<p>' + arr[i].title + '</p></a></div>'
} else if (i == 1 || i == 2) {
str2_num_1 = str2_num_1 + 1
str2_1 += '<div><img src="' + imgarticleUrl + arr[i].icon + '" alt="">' +
'<span>' + arr[i].abbr + '. | <a style="color: #006699" target="_blank" href="/' + arr[i].usx + '">' + arr[i].journal_short + '</a></span>' +
'<a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '"><p>'
+ arr[i].title + '</p></a></div>'
} else if (i <= 5) {
str3_num = str3_num + 1
str3 += '<div><span>' + arr[i].abbr + ' | <a style="color: #006699" target="_blank" href="/' + arr[i].usx + '">' + arr[i].journal_short + '</a></span><a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '"><p>'
+ arr[i].title + '</p></a></div>'
}
}
$('.sy_npar>div>a').attr('href', 'artihom_list.html?J_num=' + Jour_num + '&p_id=' + Jour_num);
$('.sy_npar .tpoce_con1').html(str1);
$('.sy_npar .tpoce_con2').html(str2_1 + str2_2 + '<br clear="both">');
$('.sy_npar .tpoce_con3').html(str3);
if (arr == '') {
$('.sy_npar').css('display', 'none')
}
} else {
// ShowDanger("请求失败!");
$('.sy_npar').css('display', 'none')
}
},
error: function () {
ShowDanger("error");
}
})
// 中下侧Online First文章
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getOnlineFirstArticles',
data: {
'pageIndex': '1', 'pageSize': '10'
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.articles;
var str = "";
var j = 0;
for (var i = 0; i < arr.length; i++) {
if (j == 4) break;
if (arr[i].icon != '') {
str += '<li><a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '"><img src="' + imgarticleUrl + arr[i].icon + '" alt=""></a>' +
'<h6><a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '">' + arr[i].title + '</a></h6>' +
'<div>' + arr[i].abbr + ' | ' + arr[i].stage_year + ' | <span><a style="color: #006699" target="_blank" href="/' + arr[i].usx + '">' + arr[i].journal_short + '</a><span></div></li>'
j += 1;
}
}
$('.sy_fr>div>a').attr('href', 'artihom_list.html?J_num=' + Jour_num + '&o_id=' + Jour_num);
$('.sy_fr>div>ul').html(str + '<br clear="both">');
if (arr == '') {
$('.sy_fr').css('display', 'none')
}
if (localStorage.Journals_title == '经典中医研究') {
$('.sy_fr>div>h4').html('最新录用');
$('.more').html('更多');
}
} else {
// ShowDanger("请求失败!");
$('.sy_fr').css('display', 'none')
}
},
error: function () {
ShowDanger("error");
}
})
// 中下侧News & Comment文章
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getNewsArticles',
data: {
"type": 'News'
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.articles;
var str = "";
var j = 0;
for (var i = 0; i < arr.length; i++) {
if (j == 2) break;
str += '<li><a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '"><img src="' + imgarticleUrl + arr[i].icon + '" alt=""></a>' +
'<h6><a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '">' + arr[i].title + '</a></h6>' +
'<div>' + arr[i].abbr + ' | ' + arr[i].stage_year + ' | <span><a style="color: #006699" target="_blank" href="/' + arr[i].usx + '">' + arr[i].journal_short + '</a><span></div></li>'
j += 1;
}
$('.sy_nct>div>div>a').attr('href', 'artihom_list.html?J_num=' + Jour_num + '&new_id=' + Jour_num);
$('.sy_nct>div>div:nth-child(1)>ul').html(str);
} else {
// ShowDanger("请求失败!");
$('.sy_nct').css('display', 'none')
}
},
error: function () {
ShowDanger("error");
}
})
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getNewsArticles',
data: {
"type": 'Comment'
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.articles;
var str = "";
var j = 0;
for (var i = 0; i < arr.length; i++) {
if (j == 2) break;
str += '<li><a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '"><img src="' + imgarticleUrl + arr[i].icon + '" alt=""></a>' +
'<h6><a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '">' + arr[i].title + '</a></h6>' +
'<div>' + arr[i].abbr + ' | ' + arr[i].stage_year + ' | <span><a style="color: #006699" target="_blank" href="/' + arr[i].usx + '">' + arr[i].journal_short + '</a><span></div></li>'
j += 1;
}
$('.sy_nct>div>div>a').attr('href', 'artihom_list.html?J_num=' + Jour_num + '&con_id=' + Jour_num);
$('.sy_nct>div>div:nth-child(2)>ul').html(str);
} else {
// ShowDanger("请求失败!");
$('.sy_nct').css('display', 'none')
}
},
error: function () {
ShowDanger("error");
}
})
// 中下侧News & Comment文章
// $.ajax({
// type: 'post', url: apiUrl + 'api/Main/getNewsArticles',
// data: {
// "type": 'News'
// },
// success: function (result) {
// if (result.code == 0) {
//
// var arr = result.data.articles;
// var str = "";
// var j = 0;
// for (var i = 0; i < arr.length; i++) {
// if (j == 8) break;
// if (arr[i].icon == '') {
// var img_i = 'img/baiss.png'
// } else {
// var img_i = imgarticleUrl + arr[i].icon
// }
// str += '<div class="swiper-slide"><img src="' + img_i + '"><h6>' +
// '<a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '">' +
// arr[i].title + '</a></h6><div>' + arr[i].abbr + ' | ' + arr[i].stage_year +
// ' | <span><a style="color: #006699" target="_blank" href="/' + arr[i].usx + '">' +
// arr[i].journal_short + '</a></div></div>'
// j += 1;
// }
//
// $('.sy_nct>div>a').attr('href', 'artihom_list.html?J_num=' + Jour_num + '&new_id=' + Jour_num);
// // $('.sy_nct>div>ul').html(str+'<br clear="both">');
// // $('.sy_nct>div>ul').html('<div id="Marquee_x"><ul><li>'+str+'</li></ul></div>');
// // $('#Marquee_x').jcMarquee({ 'marquee':'x','speed':20 });
// $('.sy_nct #certify .swiper-container .swiper-wrapper').html(str);
// // $('.sy_nct .marketing .click_con').children().eq(2).addClass('new_cur');
// // focus_lun();
//
// var certifySwiper = new Swiper('#certify .swiper-container', {
// watchSlidesProgress: true,
// slidesPerView: 'auto',
// centeredSlides: true,
// loop: true,
// autoplay: true,
// loopedSlides: 5,
// navigation: {
// nextEl: '#certify .swiper-button-next',
// prevEl: '#certify .swiper-button-prev',
// },
// pagination: {
// el: '#certify .swiper-pagination',
// clickable: true,
// },
// on: {
// progress: function (progress) {
// for (i = 0; i < this.slides.length; i++) {
// var slide = this.slides.eq(i);
// var slideProgress = this.slides[i].progress;
// modify = 1;
// if (Math.abs(slideProgress) > 1) {
// modify = (Math.abs(slideProgress) - 1) * 0.3 + 1;
// }
// translate = slideProgress * modify * 260 + 'px';
// scale = 1 - Math.abs(slideProgress) / 5;
// zIndex = 999 - Math.abs(Math.round(10 * slideProgress));
// if (scale == '0.6') {
// translate = slideProgress * modify * 240 + 'px';
// }
// slide.transform('translateX(' + translate + ') scale(' + scale + ')');
// slide.css('zIndex', zIndex);
// slide.css('opacity', 1);
// if (Math.abs(slideProgress) > 3) {
// slide.css('opacity', 0);
// }
// }
// },
// setTransition: function (transition) {
// for (var i = 0; i < this.slides.length; i++) {
// var slide = this.slides.eq(i)
// slide.transition(transition);
// }
// }
// }
// })
//
// if (arr == '') {
// $('.sy_nct').css('display', 'none')
// }
//
// $('.sy_nct h4 span').click(function () {
// var tnm_num = $(".sy_nct h4 span").index(this) + 1;
// $('.sy_nct h4 span').css('font-weight', 'normal')
// $(this).css('font-weight', '600')
// if (tnm_num == '1') {
// var tnm_type = 'News';
// $('.sy_nct>div>a').attr('href', 'artihom_list.html?J_num=' + Jour_num + '&new_id=1');
// $('#certify').css('display', 'block')
// $('#certify_').css('display', 'none')
// setTimeout(function () {
// $('#certify .swiper-pagination-bullet-active').next().trigger("click")
// }, 1000);
// }
// if (tnm_num == '2') {
// var tnm_type = 'Comment';
// $('.sy_nct>div>a').attr('href', 'artihom_list.html?J_num=' + Jour_num + '&con_id=1');
// $('#certify').css('display', 'none')
// $('#certify_').css('display', 'block')
// setTimeout(function () {
// $('#certify_ .swiper-pagination-bullet-active').next().trigger("click")
// }, 1000);
// }
//
// })
//
// } else {
// // ShowDanger("请求失败!");
// $('.sy_nct').css('display', 'none')
// }
// },
// error: function () {
// ShowDanger("error");
// }
// })
//
// $.ajax({
// type: 'post', url: apiUrl + 'api/Main/getNewsArticles',
// data: {
// "type": 'Comment'
// },
// success: function (result) {
// if (result.code == 0) {
//
// var arr = result.data.articles;
// var str = "";
// var p = 0;
// for (var i = 0; i < arr.length; i++) {
// if (p == 8) break;
// if (arr[i].icon == '') {
// var img_i = 'img/baiss.png'
// } else {
// var img_i = imgarticleUrl + arr[i].icon
// }
// str += '<div class="swiper-slide"><img src="' + img_i + '"><h6>' +
// '<a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '">' +
// arr[i].title + '</a></h6><div>' + arr[i].abbr + ' | ' + arr[i].stage_year +
// ' | <span><a style="color: #006699" target="_blank" href="/' + arr[i].usx + '">' +
// arr[i].journal_short + '</a></div></div>'
// p += 1;
// }
//
// // $('.sy_nct>div>ul').html(str+'<br clear="both">');
//
// // $('.sy_nct>div>ul').html('<div id="Marquee_x"><ul><li>'+str+'</li></ul></div>');
// // $('#Marquee_x').jcMarquee({ 'marquee':'x','speed':20 });
// $('.sy_nct #certify_ .swiper-container .swiper-wrapper').html(str);
// // $('.sy_nct .marketing .click_con').html(str + '<br clear="both">');
// // $('.sy_nct .marketing .click_con').children().eq(2).addClass('new_cur');
// // focus_lun();
// var certifySwiper_ = new Swiper('#certify_ .swiper-container', {
// watchSlidesProgress: true,
// slidesPerView: 'auto',
// centeredSlides: true,
// loop: true,
// autoplay: true,
// loopedSlides: 5,
// navigation: {
// nextEl: '#certify_ .swiper-button-next',
// prevEl: '#certify_ .swiper-button-prev',
// },
// pagination: {
// el: '#certify_ .swiper-pagination',
// clickable: true,
// },
// on: {
// progress: function (progress) {
// for (i = 0; i < this.slides.length; i++) {
// var slide = this.slides.eq(i);
// var slideProgress = this.slides[i].progress;
// modify = 1;
// if (Math.abs(slideProgress) > 1) {
// modify = (Math.abs(slideProgress) - 1) * 0.3 + 1;
// }
// translate = slideProgress * modify * 260 + 'px';
// scale = 1 - Math.abs(slideProgress) / 5;
// zIndex = 999 - Math.abs(Math.round(10 * slideProgress));
// if (scale == '0.6') {
// translate = slideProgress * modify * 240 + 'px';
// }
// slide.transform('translateX(' + translate + ') scale(' + scale + ')');
// slide.css('zIndex', zIndex);
// slide.css('opacity', 1);
// if (Math.abs(slideProgress) > 3) {
// slide.css('opacity', 0);
// }
// }
// },
// setTransition: function (transition) {
// for (var i = 0; i < this.slides.length; i++) {
// var slide = this.slides.eq(i)
// slide.transition(transition);
// }
// }
// }
// })
// $('#certify_').css('display', 'none')
// }
// }
// })
// 中下侧Top cited / Top read / Top download文章
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getThireTopArticles',
data: {
"type": 'cite',
"pageIndex": '1',
"pageSize": '8'
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.articles;
var str = "";
var j = 0;
for (var i = 0; i < arr.length; i++) {
if (j == 4) break;
if (arr[i].icon != '') {
str += '<li><a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '"><img src="' + imgarticleUrl + arr[i].icon + '" alt=""></a>' +
'<h6><a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '">' + arr[i].title + '</a></h6>' +
'<div>' + arr[i].abbr + ' | ' + arr[i].stage_year + ' | <span><a style="color: #006699" target="_blank" href="/' + arr[i].usx + '">' + arr[i].journal_short + '</a><span></div></li>'
j += 1;
}
}
$('.sy_tcrd>div>a').attr('href', 'artihom_list.html?J_num=' + Jour_num + '&cite_id=1');
$('.sy_tcrd>div>ul').html(str + '<br clear="both">');
// var arr = result.data.articles;
// var str1 = "";
// var str2 = "";
// for (var i = 0; i < arr.length; i++) {
// if (i == 0) {
// str1 += '<img src="' + imgarticleUrl + arr[i].icon + '" alt="">' +
// '<div><span>' + arr[i].abbr + '. | <a style="color: #fff" target="_blank" href="/' + arr[i].usx + '">' + arr[i].journal_short + '</a></span>' +
// '<a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '">' +
// '<p>' + arr[i].title + '</p></a></div>'
// } else if (i == 1 || i == 2 || i == 3) {
// str2 += '<div><img src="' + imgarticleUrl + arr[i].icon + '" alt="">' +
// '<span>' + arr[i].abbr + '. | <a style="color: #006699" target="_blank" href="/' + arr[i].usx + '">' + arr[i].journal_short + '</a></span>' +
// '<a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '"><p>'
// + arr[i].title + '</p></a></div>'
// }
// }
//
// $('.sy_tcrd>div>a').attr('href', 'artihom_list.html?J_num=' + Jour_num + '&cite_id=1');
// $('.sy_tcrd .tcrd_con1').html(str1);
// $('.sy_tcrd .tcrd_con2').html(str2 + '<br clear="both">');
// var arr = result.data.articles;
// var str = "";
// var j = 0;
// for (var i = 0; i < arr.length; i++) {
// if(j == 4) break;
// if(arr[i].icon==''){var img_i='img/baiss.png'}else{var img_i=imgarticleUrl + arr[i].icon}
// str += '<li><a target="_blank" href="article.html?J_num='+arr[i].journal_id+'&a_id=' + arr[i].article_id + '"><img src="' + img_i + '" alt=""></a>' +
// '<h6><a target="_blank" href="article.html?J_num='+arr[i].journal_id+'&a_id=' + arr[i].article_id + '">' + arr[i].title + '</a></h6>' +
// '<div>'+arr[i].abbr+' | '+ arr[i].stage_year +' | <span><a style="color: #006699" target="_blank" href="/'+arr[i].usx+'">'+arr[i].journal_short+'</a><span></div></li>'
// j += 1;
// }
//
// $('.sy_tcrd>div>a').attr('href','artihom_list.html?J_num='+Jour_num+'&cite_id=1');
// $('.sy_tcrd>div>ul').html(str+'<br clear="both">');
// $('.sy_tcrd h4 span').click(function () {
// var tnm_num=$(".sy_tcrd h4 span").index(this)+1;
// $('.sy_tcrd h4 span').css('font-weight','normal')
// $(this).css('font-weight','600')
// if(tnm_num=='1'){var tnm_type='cite';$('.sy_tcrd>div>a').attr('href','artihom_list.html?J_num='+Jour_num+'&cite_id=1');}
// if(tnm_num=='2'){var tnm_type='read';$('.sy_tcrd>div>a').attr('href','artihom_list.html?J_num='+Jour_num+'&read_id=1');}
// if(tnm_num=='3'){var tnm_type='download';$('.sy_tcrd>div>a').attr('href','artihom_list.html?J_num='+Jour_num+'&down_id=1');}
// $.ajax({
// type: 'post', url: apiUrl + 'api/Main/getThireTopArticles',
// data: {
// "type": tnm_type,
// "pageIndex": '1',
// "pageSize": '4'
// },
// success: function (result) {
// if (result.code == 0) {
//
// var arr = result.data.articles;
// var str = "";
// var p = 0;
// for (var i = 0; i < arr.length; i++) {
// if(p == 4) break;
// if(arr[i].icon==''){var img_i='img/baiss.png'}else{var img_i=imgarticleUrl + arr[i].icon}
// str += '<li><a target="_blank" href="article.html?J_num='+arr[i].journal_id+'&a_id=' + arr[i].article_id + '"><img src="' + img_i + '" alt=""></a>' +
// '<h6><a target="_blank" href="article.html?J_num='+arr[i].journal_id+'&a_id=' + arr[i].article_id + '">' + arr[i].title + '</a></h6>' +
// '<div>'+arr[i].abbr+' | '+ arr[i].stage_year +' | <span><a style="color: #006699" target="_blank" href="/'+arr[i].usx+'">'+arr[i].journal_short+'</a><span></div></li>'
// p += 1;
// }
//
// $('.sy_tcrd>div>ul').html(str+'<br clear="both">');
// }
// }
// })
// })
} else {
// ShowDanger("请求失败!");
$('.sy_tcrd').css('display', 'none')
}
},
error: function () {
ShowDanger("error");
}
})
// 下面新增加社区内容-搜索
$('.es_setext_btn').click(function () {
$('.es_setext_span').css('display', 'none')
if ($('#es_setext_input').val() == '') {
$('.es_setext_span').css('display', 'inline-block')
ShowDanger("Request was aborted");
} else {
window.open("ind_search.html?&set_text=" + $('#es_setext_input').val() + '&set_sel=' + $(".es_setext select[name=es_setext_in]").find("option:selected").val());
}
})
// 下面新增加社区内容-话题订阅
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getAllTopics',
data: {},
beforeSend: function () {
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.topic;
// 话题订阅
var data_de = [];
for (var i = 0; i < arr.length; i++) {
data_de.push({
id: arr[i].base_topic_id,
text: arr[i].title
});
}
$('#combox_box').selectivity({
allowClear: true,
items: data_de,
placeholder: 'Please choose topic'
})
// 订阅提交
$(".yue_de").click(function () {
$(".spa").text('');
var add_mess = {};
add_mess.email = $('#emapl_de').val();
add_mess.base_topic_id = $('#combox_box').selectivity('val');
var S_Dan = '0';
var reg = /^[-.-_A-Za-z0-9]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/
if ($('#combox_box').selectivity('val') == null) {
$(".spa_de").text('Please choose topic');
S_Dan = '1';
} else if ($("#emapl_de").val() == "") {
$(".spa_de").text('Please fill in E-mail');
S_Dan = '1';
} else if (!(reg.test($("#emapl_de").val()))) {
$(".spa_de").text('Please fill in properly formatted E-mail');
S_Dan = '1';
}
if (S_Dan == '1') {
ShowDanger("Incomplete information");
} else {
$(".yue_de").addClass("disable");
$.ajax({
type: 'post', url: apiUrl + 'subscribe/Journal/addSubscribeBaseTopic',
data: add_mess,
success: function (result) {
if (result.code == 0) {
$(".ding_yue input[type='text']").val('');
$(".yue_de").removeClass("disable");
$(".jour_ts").fadeIn();
$(".jour_ts .mainbox input[type='submit']").css('background-color', '#006699')
$(".jour_ts input.tishi_author").click(function () {
$(".jour_ts").fadeOut();
});
} else {
ShowDanger(result.msg);
$(".yue_de").removeClass("disable");
}
},
error: function () {
ShowDanger("error");
$(".yue_de").removeClass("disable");
}
})
}
})
} else {
ShowDanger("请求失败!");
}
}
})
// 单个话题列表数据
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getBaseTopicArticles',
data: {
"base_topic_id": 5,
"pageIndex": 1,
"pageSize": 10
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.articleList;
var str1 = "";
var str2_1 = "";
var str2_2 = "";
var str3 = "";
var str1_num = 0;
var str2_num_1 = 0;
var str2_num_2 = 0;
var str3_num = 0;
for (var i = 0; i < arr.length; i++) {
if (arr[i].stage_year == 2021 && str1_num < 1) {
str1_num = str1_num + 1
str1 += '<img src="' + imgarticleUrl + arr[i].icon + '" alt="">' +
'<div><span>' + arr[i].abbr + '. | <a style="color: #fff" target="_blank" href="/' + arr[i].usx + '">' +
arr[i].jabbr + '</a> | ' + arr[i].stage_year + '</span><a target="_blank" href="article.html?J_num=' +
arr[i].journal_id + '&a_id=' + arr[i].article_id + '"><p>' + arr[i].title + '</p></a></div>'
} else if (arr[i].stage_year == 2021 && str2_num_1 < 1) {
str2_num_1 = str2_num_1 + 1
str2_1 += '<div><img src="' + imgarticleUrl + arr[i].icon + '" alt="">' +
'<span>' + arr[i].abbr + '. | <a style="color: #006699" target="_blank" href="/' + arr[i].usx + '">' +
arr[i].jabbr + '</a> | ' + arr[i].stage_year + '</span>' +
'<a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '"><p>'
+ arr[i].title + '</p></a></div>'
} else if (arr[i].stage_year == 2021 && str2_num_2 < 1) {
str2_num_2 = str2_num_2 + 1
str2_2 += '<div><img src="' + imgarticleUrl + arr[i].icon + '" alt="">' +
'<span>' + arr[i].abbr + '. | <a style="color: #006699" target="_blank" href="/' + arr[i].usx + '">' +
arr[i].jabbr + '</a> | ' + arr[i].stage_year + '</span>' +
'<a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '"><p>'
+ arr[i].title + '</p></a></div>'
} else if (arr[i].stage_year == 2021 && str3_num < 3) {
str3_num = str3_num + 1
str3 += '<div><span>' + arr[i].abbr + '. | <a style="color: #006699" target="_blank" href="/' + arr[i].usx + '">' +
arr[i].jabbr + '</a> | ' + arr[i].stage_year + '</span>' +
'<a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '"><p>'
+ arr[i].title + '</p></a></div>'
}
}
$('.sy_dmne .sy_dmne_talk .talk_con1').html(str1);
$('.sy_dmne .sy_dmne_talk .talk_con2').html(str2_1 + str2_2 + '<br clear="both">');
$('.sy_dmne .sy_dmne_talk .talk_con3').html(str3);
}
}
})
// 六个话题
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getAllTopics',
data: {},
success: function (result) {
if (result.code == 0) {
// 话题列表
var arr = result.data.topic;
var st_talk = '';
var st_allIst = '';
var url_href = '';
for (var i = 0; i < arr.length; i++) {
if (arr[i].title != 'Immunology') {
if (i == 7) break;
if (arr[i].is_final == '1') {
url_href = 'topic_list.html?J_num=1&t_id='
} else {
url_href = 'topic.html?J_num=1&t_id='
}
st_talk += '<li><a target="_blank" href="artihom_list.html?J_num=1&base_id='
+ arr[i].base_topic_id + '"><img src="' + imgbaseUrl + arr[i].icon + '"/></a>' +
'<h6 style="text-align: center"><a target="_blank" ' +
'href="artihom_list.html?J_num=1&base_id=' + arr[i].base_topic_id + '">'
+ arr[i].title + '</a></h6></li>'
st_allIst += '<a target="_blank" href="artihom_list.html?J_num=1&base_id='
+ arr[i].base_topic_id + '">'+ arr[i].title + '</a>'
}
}
$('.sy_dmne ul.sy_dmne_lies').html(st_talk);
$('.sy_dmne div.sy_tit_all').html(st_allIst);
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
// 中下侧notices文章
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getAllNotices',
data: {},
success: function (result) {
if (result.code == 0) {
// 消息列表
var arr = result.data.notices;
var str = '';
var link = '';
for (var i = 0; i < arr.length; i++) {
if (i == 0) {
link = 'z_f4-1.html';
} else if (i == 1) {
link = 'booker_list.html?bo_id=0';
} else {
link = '/tmrde';
}
str += '<li><img src="' + imgsystemUrl + arr[i].icon + '"/><div class="di_con"><h3>' +
'<a href="' + link + '" target="_blank">' +
arr[i].title + '</a></h3><p>' + formatTimeToDate4(arr[i].ctime * 1000) + '</p></div></li>'
}
$('.sy_notice>div>div>ul').html(str);
var unslider04 = $('#b04').unslider({
dots: true,
delay: 3000
}),
data04 = unslider04.data('unslider');
$('.unslider-arrow04').click(function () {
var fn = this.className.split(' ')[1];
data04[fn]();
});
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// 科学家和书籍列表
function bs_list() {
// 获取地址栏信息
function getQueryString(name) {
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
var r = window.location.search.substr(1).match(reg);
if (r != null) return unescape(r[2]);
return null;
}
var sc_ID = getQueryString('sc_id'); //Scientists
var bo_ID = getQueryString('bo_id'); //Books
var me_ID = getQueryString('me_id'); //Meeting
var nt_ID = getQueryString('nt_id'); //Notices
// Scientists点进去的列表
if (sc_ID != null) {
// 科学家列表
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getScients',
data: {},
success: function (result) {
if (result.code == 0) {
var arr = result.data.scients;
var str = '';
for (var i = 0; i < arr.length; i++) {
str += '<li><img src="' + imgsystemUrl + arr[i].icon + '" alt=""><div>' +
'<a target="_blank" href="booker.html?sc_id=' + arr[i].system_scient_id + '">' + arr[i].name + '</a>' +
'<p>' + arr[i].intro + '</p></div></li>'
}
$('.scien_tist ul').html(str);
$(".scien_tist ul p").each(function () {
var maxwidth = 200;//显示多少字符
if ($(this).text().length > maxwidth) {
$(this).text($(this).text().substring(0, maxwidth));
$(this).html($(this).html() + '...');
}
});
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// Books点进去的列表
if (bo_ID != null) {
// 书籍列表
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getBooks',
data: {},
success: function (result) {
if (result.code == 0) {
var arr = result.data.books;
var str = '';
for (var i = 0; i < arr.length; i++) {
str += '<li><img src="' + imgsystemUrl + arr[i].icon + '" alt=""><div>' +
'<a target="_blank" href="booker.html?bo_id=' + arr[i].system_book_id + '">' + arr[i].title + '</a>' +
'<p>Language: ' + arr[i].language + '<br/>Author/Editor: ' + arr[i].author + '<br/>ISBN: ' + arr[i].isbn + '<br/>Price: ' + arr[i].price + '</p></div></li>'
}
$('.scien_tist ul').html(str);
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
//第三个输入框
$('.es_setext_btn').click(function () {
$('.es_setext_span').css('display', 'none')
if ($('#es_setext_input').val() == '') {
$('.es_setext_span').css('display', 'inline-block')
ShowDanger("Request was aborted");
} else {
window.open("ind_search.html?&set_text=" + $('#es_setext_input').val() + '&set_sel=' + $(".es_setext select[name=es_setext_in]").find("option:selected").val());
}
})
// Topic通用文章
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getAllTopics',
data: {},
beforeSend: function () {
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.topic;
// 话题订阅
var data_de = [];
for (var i = 0; i < arr.length; i++) {
data_de.push({
id: arr[i].base_topic_id,
text: arr[i].title
});
}
$('#combox_box').selectivity({
allowClear: true,
items: data_de,
placeholder: 'Please choose topic'
})
// 订阅提交
$(".yue_de").click(function () {
$(".spa").text('');
var add_mess = {};
add_mess.email = $('#emapl_de').val();
add_mess.base_topic_id = $('#combox_box').selectivity('val');
var S_Dan = '0';
var reg = /^[-.-_A-Za-z0-9]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/
if ($('#combox_box').selectivity('val') == null) {
$(".spa_de").text('Please choose topic');
S_Dan = '1';
} else if ($("#emapl_de").val() == "") {
$(".spa_de").text('Please fill in E-mail');
S_Dan = '1';
} else if (!(reg.test($("#emapl_de").val()))) {
$(".spa_de").text('Please fill in properly formatted E-mail');
S_Dan = '1';
}
if (S_Dan == '1') {
ShowDanger("Incomplete information");
} else {
$(".yue_de").addClass("disable");
$.ajax({
type: 'post', url: apiUrl + 'subscribe/Journal/addSubscribeBaseTopic',
data: add_mess,
success: function (result) {
if (result.code == 0) {
$(".ding_yue input[type='text']").val('');
$(".yue_de").removeClass("disable");
$(".jour_ts").fadeIn();
$(".jour_ts .mainbox input[type='submit']").css('background-color', '#006699')
$(".jour_ts input.tishi_author").click(function () {
$(".jour_ts").fadeOut();
});
} else {
ShowDanger(result.msg);
$(".yue_de").removeClass("disable");
}
},
error: function () {
ShowDanger("error");
$(".yue_de").removeClass("disable");
}
})
}
})
} else {
ShowDanger("请求失败!");
}
}
})
}
}
// 消息页面notices列表
function nurt_list() {
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getNotices',
data: {
"journal_id": Jour_num
},
success: function (result) {
if (result.code == 0) {
// 消息列表
var arr = result.data.notices;
var str = '';
for (var i = 0; i < arr.length; i++) {
str += '<div><a href="notice.html?notice_id=' + arr[i].journal_notices_id + '" target="_blank">' + arr[i].title + '</a><i>' + formatTimeToDate3(arr[i].ctime * 1000) + '</i></div>'
}
// $('.noti_lis').html(str);
// $('.noti_mes').html('common 1 page / '+ arr.length +' Records');
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// 科学家和书籍内容
function bs_text() {
// 获取地址栏信息
function getQueryString(name) {
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
var r = window.location.search.substr(1).match(reg);
if (r != null) return unescape(r[2]);
return null;
}
var sc_ID = getQueryString('sc_id'); //Scientists
var bo_ID = getQueryString('bo_id'); //Books
var nt_ID = getQueryString('nt_id'); //Notices
// Scientists点进去的列表
if (sc_ID != null) {
// Scientists
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getScientDetail',
data: {
"system_scient_id": sc_ID
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.scient;
$('.topics>h2').html(arr.name);
$('.topics>div').html(arr.intro);
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// Books点进去的列表
if (bo_ID != null) {
// Books
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getBookDetail',
data: {
"system_book_id": bo_ID
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.book;
$('.topics>h2').html(arr.title);
if (arr.phone == '') {
var tel_ = ''
} else {
var tel_ = 'Advance sale-Tel. number (Chinese) : ' + arr.phone + '<br/>'
}
if (arr.pdf == '') {
var pdf_ = ''
} else {
var pdf_ = 'File : <a href="' + imgFileUrl + 'bookpdf/' + arr.pdf + '" target="_blank"><img src="img/link_3.jpg" width="14" height="16" style="vertical-align: middle;"> PDF</a>'
}
var book_ing = '<p style="text-align: center;font-size: 18px;line-height: 48px;color: #333333">' +
'Language: ' + arr.language + '<br/>' +
'Author/Editor: ' + arr.author + '<br/>' +
'ISBN: ' + arr.isbn + '<br/>' +
'Price: ' + arr.price + '<br/>' +
tel_ +
'Purchase address: <a href="' + arr.sale_url + '" target="_blank" style="color: #003c98">' + arr.sale_url + '</a><br/>' +
'<img src="' + imgsystemUrl + arr.sale_icon + '" alt="" style="width: 300px"><br/>' +
pdf_ + '</p>'
$('.topics>div').html(book_ing);
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// Notices点进去的列表
if (nt_ID != null) {
// Notices
}
}
// 所有期刊列表
function art_list() {
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getJournalListByName',
data: {},
success: function (result) {
if (result.code == 0) {
var arr = result.data.journalList;
var str = '';
for (var i = 0; i < arr.length; i++) {
if (arr[i].title != 'tmRxiv') {
str += '<li><img src="' + imgjourUrl + arr[i].icon + '" alt=""><div>' +
'<a target="_blank" href="/' + arr[i].usx + '">' + arr[i].title + '</a>' +
'<p>' + arr[i].abstract + '</p>' +
'<a target="_blank" href="/' + arr[i].usx + '">Home</a> | ' +
'<a target="_blank" href="' + arr[i].submission_url + '">Submission</a> | ' +
'<a target="_blank" href="/' + arr[i].usx + '">Current Issue</a> | ' +
'<a target="_blank" href="stages.html?J_num=' + arr[i].journal_id + '">All Issues</a></div></li>'
}
}
$('.atr_tist ul').html(str);
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// 所有more点进去文章列表
function more_list() {
// 获取地址栏信息
function getQueryString(key) {
// 获取参数
var url = window.location.search;
// 正则筛选地址栏
var reg = new RegExp("(^|&)" + key + "=([^&]*)(&|$)");
// 匹配目标参数
var result = url.substr(1).match(reg);
//返回参数值
return result ? decodeURIComponent(result[2]) : null;
}
var p_ID = getQueryString('p_id'); //New Papers
var o_ID = getQueryString('o_id'); //Online First
var base_ID = getQueryString('base_id'); //通用话题
var new_ID = getQueryString('new_id'); //News
var con_ID = getQueryString('con_id'); //Commentdian
var cite_ID = getQueryString('cite_id'); //Top cited
var read_ID = getQueryString('read_id'); //Top read
var down_ID = getQueryString('down_id'); //Top download
var issu_ID = getQueryString('issu_id'); //专刊
var waite_ID = getQueryString('waite_id'); //待审稿
var stuff_ID = getQueryString('stuff_ID'); //Medicament药剂话题
var stuff_LIST = getQueryString('stuff_LIST'); //Medicament药剂搜索列表
localStorage.setItem("Journals_color", '#006699');
// New Papers点进去的文章列表
if (p_ID != null) {
//New Papers
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getMoreArticles',
data: {},
success: function (result) {
if (result.code == 0) {
$('.wenz_list>h4').html('New Papers');
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].icon == '') {
continue
}
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
var lr_top = ''
// for (var t = 0; t < arr[i].topic.length; t++) {
// lr_top += '<a href="topic_list.html?J_num='+Jour_num+'&t_id='+ arr[i].topic[t].journal_topic_id +'" target="_blank">' + arr[i].topic[t].title + '</a>'
// }
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '<div class="url_top">' + lr_top + '</div></div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal_title + '.&nbsp;' + arr[i].stage_year + ',&nbsp;' + arr[i].stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// Online First点进去的文章列表
if (o_ID != null) {
//Online First
$('.art_main_con').append('<div id="kkpager"></div>')
$('.wenz_list').append('<div style="font-size: 12px;text-align: right;padding-top: 10px;padding-right: 27px;" class="gue_chinese_tot">all total <b class="tioashu"></b> </div>')
var online_first = {};
online_first.pageIndex = 1;
online_first.pageSize = 10;
var totalPage;//总页码
var totalRecords;//总数据条数
var pageNo = online_first.pageIndex;//当前页码
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getOnlineFirstArticles',
data: online_first,
success: function (result) {
if (result.code == 0) {
totalPage = result.data.count % online_first.pageSize == 0 ? (result.data.count / online_first.pageSize) : (Math.ceil(result.data.count / online_first.pageSize));
totalRecords = result.data.count;
$('.wenz_list .tioashu').html(result.data.count);
$('.wenz_list>h4').html('Online First');
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].icon == '') {
continue
}
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '</div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ '<a href="/' + arr[i].usx + '" target="_blank" >' + arr[i].journal_title + '.</a>&nbsp;' + arr[i].stage_year + ',&nbsp;' + arr[i].stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+trad_tion+'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
//生成分页
//有些参数是可选的比如lang若不传有默认值
kkpager.generPageHtml({
pno: pageNo,
//总页码
total: totalPage,
//总数据条数
totalRecords: totalRecords,
mode: 'click',//默认值是link可选link或者click
click: function (n) {
this.selectPage(n);
//除了第一页写逻辑跳转
online_first.pageIndex = n;
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getOnlineFirstArticles',
data: online_first,
success: function (result) {
if (result.code == 0) {
totalRecords = result.data.count;
$('.wenz_list .tioashu').html(result.data.count);
$('.wenz_list>h4').html('Online First');
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].icon == '') {
continue
}
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '</div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal_title + '.&nbsp;' + arr[i].stage_year + ',&nbsp;' + arr[i].stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.goup-container').click();
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post',
url: apiUrl + 'yuan/Article/addArticleNum',
async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
return false;
}, lang: {
firstPageText: 'First page',
firstPageTipText: 'First page',
lastPageText: 'Last page',
lastPageTipText: 'Last page',
prePageText: 'Previous page',
prePageTipText: 'Previous page',
nextPageText: 'Next page',
nextPageTipText: 'Next page',
totalPageBeforeText: '',
totalPageAfterText: '',
currPageBeforeText: 'on page&nbsp;',
currPageAfterText: '',
totalInfoSplitStr: '&nbsp;of&nbsp;',
totalRecordsBeforeText: '',
totalRecordsAfterText: '',
gopageBeforeText: '&nbsp;&nbsp;&nbsp;Go to page',
gopageButtonOkText: 'Go',
gopageAfterText: 'page',
buttonTipBeforeText: '第',
buttonTipAfterText: '页'
}
});
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// 通用话题点进去的文章列表
if (base_ID != null) {
// 通用话题
$('.art_main_con').append('<div id="kkpager"></div>')
$('.wenz_list').append('<div style="font-size: 12px;text-align: right;padding-top: 10px;padding-right: 27px;" class="gue_chinese_tot">all total <b class="tioashu"></b> </div>')
var base_topic = {};
base_topic.base_topic_id = base_ID;
base_topic.pageIndex = 1;
base_topic.pageSize = 10;
var totalPage;//总页码
var totalRecords;//总数据条数
var pageNo = base_topic.pageIndex;//当前页码
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getBaseTopicArticles',
data: base_topic,
success: function (result) {
if (result.code == 0) {
totalPage = result.data.count % base_topic.pageSize == 0 ? (result.data.count / base_topic.pageSize) : (Math.ceil(result.data.count / base_topic.pageSize));
totalRecords = result.data.count;
$('.wenz_list .tioashu').html(result.data.count);
$('.wenz_list>h4').html(result.data.topic.title);
var arr = result.data.articleList;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '</div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ '<a href="/' + arr[i].usx + '" target="_blank" >' + arr[i].journal_title + '.</a>&nbsp;' + arr[i].stage_year + ',&nbsp;' + arr[i].stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
//生成分页
//有些参数是可选的比如lang若不传有默认值
kkpager.generPageHtml({
pno: pageNo,
//总页码
total: totalPage,
//总数据条数
totalRecords: totalRecords,
mode: 'click',//默认值是link可选link或者click
click: function (n) {
this.selectPage(n);
//除了第一页写逻辑跳转
base_topic.pageIndex = n;
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getBaseTopicArticles',
data: base_topic,
success: function (result) {
if (result.code == 0) {
totalRecords = result.data.count;
$('.wenz_list .tioashu').html(result.data.count);
$('.wenz_list>h4').html(result.data.topic.title);
var arr = result.data.articleList;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '</div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal_title + '.&nbsp;' + arr[i].stage_year + ',&nbsp;' + arr[i].stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.goup-container').click();
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post',
url: apiUrl + 'yuan/Article/addArticleNum',
async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
return false;
}, lang: {
firstPageText: 'First page',
firstPageTipText: 'First page',
lastPageText: 'Last page',
lastPageTipText: 'Last page',
prePageText: 'Previous page',
prePageTipText: 'Previous page',
nextPageText: 'Next page',
nextPageTipText: 'Next page',
totalPageBeforeText: '',
totalPageAfterText: '',
currPageBeforeText: 'on page&nbsp;',
currPageAfterText: '',
totalInfoSplitStr: '&nbsp;of&nbsp;',
totalRecordsBeforeText: '',
totalRecordsAfterText: '',
gopageBeforeText: '&nbsp;&nbsp;&nbsp;Go to page',
gopageButtonOkText: 'Go',
gopageAfterText: 'page',
buttonTipBeforeText: '第',
buttonTipAfterText: '页'
}
});
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// News点进去的文章列表
if (new_ID != null) {
// News
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getNewsArticles',
data: {
"type": 'News'
},
success: function (result) {
if (result.code == 0) {
$('.wenz_list>h4').html('News');
// var doi_ = '';
// var npp_ = '';
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].icon == '') {
continue
}
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal_title + '.&nbsp;' + arr[i].stage_year + ',&nbsp;' + arr[i].stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// Comment点进去的文章列表
if (con_ID != null) {
// Comment
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getNewsArticles',
data: {
"type": 'Comment'
},
success: function (result) {
if (result.code == 0) {
$('.wenz_list>h4').html('Comment');
// var doi_ = '';
// var npp_ = '';
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].icon == '') {
continue
}
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 500;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal_title + '.&nbsp;' + arr[i].stage_year + ',&nbsp;' + arr[i].stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'</div><br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// Top cited点进去的文章列表
if (cite_ID != null) {
// cited
$('.art_main_con').append('<div id="kkpager"></div>')
$('.wenz_list').append('<div style="font-size: 12px;text-align: right;padding-top: 10px;padding-right: 27px;" class="gue_chinese_tot">all total <b class="tioashu"></b> </div>')
var cited_tcp = {};
cited_tcp.pageIndex = 1;
cited_tcp.pageSize = 10;
cited_tcp.type = 'cite';
var totalPage;//总页码
var totalRecords;//总数据条数
var pageNo = cited_tcp.pageIndex;//当前页码
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getThireTopArticles',
data: cited_tcp,
success: function (result) {
if (result.code == 0) {
$('.wenz_list>h4').html('Top cited');
totalPage = result.data.count % cited_tcp.pageSize == 0 ? (result.data.count / cited_tcp.pageSize) : (Math.ceil(result.data.count / cited_tcp.pageSize));
totalRecords = result.data.count;
$('.wenz_list .tioashu').html(result.data.count);
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].icon == '') {
continue
}
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '</div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal_title + '.&nbsp;' + arr[i].stage_year + ',&nbsp;' + arr[i].stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
//生成分页
//有些参数是可选的比如lang若不传有默认值
kkpager.generPageHtml({
pno: pageNo,
//总页码
total: totalPage,
//总数据条数
totalRecords: totalRecords,
mode: 'click',//默认值是link可选link或者click
click: function (n) {
this.selectPage(n);
//除了第一页写逻辑跳转
cited_tcp.pageIndex = n;
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getThireTopArticles',
data: cited_tcp,
success: function (result) {
if (result.code == 0) {
totalRecords = result.data.count;
$('.wenz_list .tioashu').html(result.data.count);
$('.wenz_list>h4').html('Top cited');
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].icon == '') {
continue
}
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '</div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal_title + '.&nbsp;' + arr[i].stage_year + ',&nbsp;' + arr[i].stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.goup-container').click();
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post',
url: apiUrl + 'yuan/Article/addArticleNum',
async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
return false;
}, lang: {
firstPageText: 'First page',
firstPageTipText: 'First page',
lastPageText: 'Last page',
lastPageTipText: 'Last page',
prePageText: 'Previous page',
prePageTipText: 'Previous page',
nextPageText: 'Next page',
nextPageTipText: 'Next page',
totalPageBeforeText: '',
totalPageAfterText: '',
currPageBeforeText: 'on page&nbsp;',
currPageAfterText: '',
totalInfoSplitStr: '&nbsp;of&nbsp;',
totalRecordsBeforeText: '',
totalRecordsAfterText: '',
gopageBeforeText: '&nbsp;&nbsp;&nbsp;Go to page',
gopageButtonOkText: 'Go',
gopageAfterText: 'page',
buttonTipBeforeText: '第',
buttonTipAfterText: '页'
}
});
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// Top read点进去的文章列表
if (read_ID != null) {
// read
$('.art_main_con').append('<div id="kkpager"></div>')
$('.wenz_list').append('<div style="font-size: 12px;text-align: right;padding-top: 10px;padding-right: 27px;" class="gue_chinese_tot">all total <b class="tioashu"></b> </div>')
var read_tcp = {};
read_tcp.pageIndex = 1;
read_tcp.pageSize = 10;
read_tcp.type = 'read';
var totalPage;//总页码
var totalRecords;//总数据条数
var pageNo = read_tcp.pageIndex;//当前页码
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getThireTopArticles',
data: read_tcp,
success: function (result) {
if (result.code == 0) {
$('.wenz_list>h4').html('Top read');
totalPage = result.data.count % read_tcp.pageSize == 0 ? (result.data.count / read_tcp.pageSize) : (Math.ceil(result.data.count / read_tcp.pageSize));
totalRecords = result.data.count;
$('.wenz_list .tioashu').html(result.data.count);
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].icon == '') {
continue
}
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '</div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal_title + '.&nbsp;' + arr[i].stage_year + ',&nbsp;' + arr[i].stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
//生成分页
//有些参数是可选的比如lang若不传有默认值
kkpager.generPageHtml({
pno: pageNo,
//总页码
total: totalPage,
//总数据条数
totalRecords: totalRecords,
mode: 'click',//默认值是link可选link或者click
click: function (n) {
this.selectPage(n);
//除了第一页写逻辑跳转
read_tcp.pageIndex = n;
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getThireTopArticles',
data: read_tcp,
success: function (result) {
if (result.code == 0) {
totalRecords = result.data.count;
$('.wenz_list .tioashu').html(result.data.count);
$('.wenz_list>h4').html('Top read');
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].icon == '') {
continue
}
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '</div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal_title + '.&nbsp;' + arr[i].stage_year + ',&nbsp;' + arr[i].stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.goup-container').click();
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post',
url: apiUrl + 'yuan/Article/addArticleNum',
async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
return false;
}, lang: {
firstPageText: 'First page',
firstPageTipText: 'First page',
lastPageText: 'Last page',
lastPageTipText: 'Last page',
prePageText: 'Previous page',
prePageTipText: 'Previous page',
nextPageText: 'Next page',
nextPageTipText: 'Next page',
totalPageBeforeText: '',
totalPageAfterText: '',
currPageBeforeText: 'on page&nbsp;',
currPageAfterText: '',
totalInfoSplitStr: '&nbsp;of&nbsp;',
totalRecordsBeforeText: '',
totalRecordsAfterText: '',
gopageBeforeText: '&nbsp;&nbsp;&nbsp;Go to page',
gopageButtonOkText: 'Go',
gopageAfterText: 'page',
buttonTipBeforeText: '第',
buttonTipAfterText: '页'
}
});
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// Top down点进去的文章列表
if (down_ID != null) {
// down
$('.art_main_con').append('<div id="kkpager"></div>')
$('.wenz_list').append('<div style="font-size: 12px;text-align: right;padding-top: 10px;padding-right: 27px;" class="gue_chinese_tot">all total <b class="tioashu"></b> </div>')
var down_tcp = {};
down_tcp.pageIndex = 1;
down_tcp.pageSize = 10;
down_tcp.type = 'download';
var totalPage;//总页码
var totalRecords;//总数据条数
var pageNo = down_tcp.pageIndex;//当前页码
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getThireTopArticles',
data: down_tcp,
success: function (result) {
if (result.code == 0) {
$('.wenz_list>h4').html('Top download');
totalPage = result.data.count % down_tcp.pageSize == 0 ? (result.data.count / down_tcp.pageSize) : (Math.ceil(result.data.count / down_tcp.pageSize));
totalRecords = result.data.count;
$('.wenz_list .tioashu').html(result.data.count);
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].icon == '') {
continue
}
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '</div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal_title + '.&nbsp;' + arr[i].stage_year + ',&nbsp;' + arr[i].stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
//生成分页
//有些参数是可选的比如lang若不传有默认值
kkpager.generPageHtml({
pno: pageNo,
//总页码
total: totalPage,
//总数据条数
totalRecords: totalRecords,
mode: 'click',//默认值是link可选link或者click
click: function (n) {
this.selectPage(n);
//除了第一页写逻辑跳转
down_tcp.pageIndex = n;
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getThireTopArticles',
data: down_tcp,
success: function (result) {
if (result.code == 0) {
totalRecords = result.data.count;
$('.wenz_list .tioashu').html(result.data.count);
$('.wenz_list>h4').html('Top download');
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].icon == '') {
continue
}
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '</div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal_title + '.&nbsp;' + arr[i].stage_year + ',&nbsp;' + arr[i].stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.goup-container').click();
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post',
url: apiUrl + 'yuan/Article/addArticleNum',
async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
return false;
}, lang: {
firstPageText: 'First page',
firstPageTipText: 'First page',
lastPageText: 'Last page',
lastPageTipText: 'Last page',
prePageText: 'Previous page',
prePageTipText: 'Previous page',
nextPageText: 'Next page',
nextPageTipText: 'Next page',
totalPageBeforeText: '',
totalPageAfterText: '',
currPageBeforeText: 'on page&nbsp;',
currPageAfterText: '',
totalInfoSplitStr: '&nbsp;of&nbsp;',
totalRecordsBeforeText: '',
totalRecordsAfterText: '',
gopageBeforeText: '&nbsp;&nbsp;&nbsp;Go to page',
gopageButtonOkText: 'Go',
gopageAfterText: 'page',
buttonTipBeforeText: '第',
buttonTipAfterText: '页'
}
});
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// 客座列表
if (issu_ID != null) {
$.ajax({
type: 'post', url: apiUrl + 'api/Special/getAllSpecials',
data: {},
success: function (result) {
if (result.code == 0) {
$('.wenz_list>h4').html('Open Special Issues');
var arr = result.data.specials;
var str = "";
for (var i = 0; i < arr.length; i++) {
if ($.cookie("username") != undefined && $.cookie("user_id") != undefined) {
var co_sp_user = 'contribu_list.html?J_num=' + arr[i].journal_id + '&&special_id=' + arr[i].journal_special_id;
} else {
var co_sp_user = 'contribu_login.html?J_num=' + arr[i].journal_id + '&&special_id=' + arr[i].journal_special_id;
}
str += '<li><p>' + arr[i].journaltitle + '</p><a href="/' + arr[i].usx + '" target="_blank">' +
'<img src="' + imgjourUrl + arr[i].icon + '"></a>' +
'<div><a href="gue_cont.html?J_num=' + arr[i].journal_id + '&&Gu_num=' + arr[i].journal_special_id + '" target="_blank">' + arr[i].title + '</a>' +
'<span><font style="color: #006699;margin-right: 5px">Guest Editor:</font>' + arr[i].editor + '</span>' +
'<span><font style="color: #006699;margin-right: 5px">Deadline:</font>' + arr[i].deadline + '</span>' +
'<div class="iss_abs"><span><font style="color: #006699;margin-right: 5px">Special Issue Information:</font></span><b>' + arr[i].abstract + '</b></div>' +
'<div class="gue_s_btn"><a href="gue_cont_gea.html?J_num=' + arr[i].journal_id + '&&Gu_num=' + arr[i].journal_special_id + '" class="gue_appli" target="_blank">Guest Editor Application</a>' +
'<a href="' + co_sp_user + '" class="gue_submin" target="_blank">Submit Article</a>' +
'</div></div><br clear="both"></li>'
}
$('.wenz_list>ul').addClass('iss_artiom_list');
$('.wenz_list>ul').html(str + '<br clear="both"/>');
$(".wenz_list li>div .iss_abs>b").each(function () {
var maxwidth = 440;//显示多少字符
if ($(this).text().length > maxwidth) {
$(this).text($(this).text().substring(0, maxwidth));
$(this).text($(this).text().substring(0, maxwidth - $(this).text().split(" ").pop().length));
$(this).html($(this).html() + '...');
} else {
$(this).html($(this).text());
}
});
} else {
// ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// 待审稿列表
if (waite_ID != null) {
$.ajax({
type: 'post', url: apiUrl + 'special/Article/getReviewerArticles',
data: {},
success: function (result) {
if (result.code == 0) {
$('.wenz_list>h4').html('Finding Reviewers for Articles');
var arr = result.data.articles;
var str = '';
for (var i = 0; i < arr.length; i++) {
if (arr[i].abstrart == '') {
var abst_c = ''
} else {
var maxwidth = 440;//显示多少字符
if (arr[i].abstrart.length > maxwidth) {
arr[i].abstrart = arr[i].abstrart.substring(0, maxwidth)
arr[i].abstrart = arr[i].abstrart.substring(0, maxwidth - arr[i].abstrart.split(" ").pop().length)
arr[i].abstrart = arr[i].abstrart + '...'
}
var abst_c = '<font style="color: #006699;">Abstrart: </font><font>' + arr[i].abstrart + '</font>'
}
str += '<li><a target="_blank" href="https://submission.tmrjournals.com/peerewer">' + arr[i].title + '</a>' +
'<font style="color: #006699">Journal: </font>' + arr[i].journalname +
'<font style="color: #006699;margin-left: 50px">Type: </font>' + pan_type(arr[i].type) +
'<br>' + abst_c + '</li>'
}
$('.wenz_list>ul').addClass('waite_artiom_list');
$('.wenz_list>ul').html(str + '<br clear="both"/>');
} else {
// ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// Medicament药剂话题文章列表
if (stuff_ID != null) {
//药剂
$.ajax({
type: 'post', url: apiUrl + 'api/Tmrde/getArticleByMed',
data: {
"med_id": stuff_ID
},
success: function (result) {
if (result.code == 0) {
$('.wenz_list>h4').html(result.data.medicament.med_ename + ' ( ' + result.data.medicament.med_title + ' )');
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].icon == '') {
continue
}
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
var lr_top = ''
// for (var t = 0; t < arr[i].topic.length; t++) {
// lr_top += '<a href="topic_list.html?J_num='+Jour_num+'&t_id='+ arr[i].topic[t].journal_topic_id +'" target="_blank">' + arr[i].topic[t].title + '</a>'
// }
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '<div class="url_top">' + lr_top + '</div></div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal_title + '.&nbsp;' + arr[i].stage_year + ',&nbsp;' + arr[i].stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// Medicament药剂话题搜索列表
if (stuff_LIST != null) {
$.ajax({
type: 'post', url: apiUrl + 'api/Tmrde/searchMeds',
data: {
"keyword": stuff_LIST
},
success: function (result) {
if (result.code == 0) {
$('.wenz_list>h4').html('"' + stuff_LIST + '" search results');
var arr = result.data.meds;
var str = "";
for (var i = 0; i < arr.length; i++) {
str += '<li class="stuff_list"><a href="artihom_list.html?J_num=1&stuff_ID=' + arr[i].med_id + '" target="_blank">' +
'<h3>' + arr[i].med_ename + '</h3><h5>' + arr[i].med_title + '</h5></a></li>'
}
$('.wenz_list>ul').css({"overflow":"auto","padding":"10px 0 0 0"})
$('.wenz_list>ul').html(str+'<br/>');
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
}
// 消息内容
function notice_index() {
// 获取地址栏信息
function getQueryString(name) {
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
var r = window.location.search.substr(1).match(reg);
if (r != null) return unescape(r[2]);
return null;
}
var notice_ID = getQueryString('notice_id'); //消息
//消息
if (notice_ID != null) {
// 消息
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getNoticesDetail',
data: {
"journal_notices_id": notice_ID
},
success: function (result) {
if (result.code == 0) {
// 消息列表
var arr = result.data.notices;
$('.fuwenben>h2').html(arr.title);
$('.fuwenben>div').html(arr.content);
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
}
//搜索列表
function scout_ind() {
// 获取地址栏信息
function getQueryString(name) {
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
var r = window.location.search.substr(1).match(reg);
if (r != null) return decodeURIComponent(r[2]);
return null;
}
var se_ch = getQueryString('se_ch'); //关键字
var set_text = getQueryString('set_text'); //输入字和下拉搜索
var set_xial = getQueryString('set_sel'); //输入字和下拉搜索
if (se_ch != null) {
$('.art_main_con').append('<div id="kkpager"></div>')
$('.wenz_list').append('<div style="font-size: 12px;text-align: right;padding-top: 10px;padding-right: 27px;" class="gue_chinese_tot">all total <b class="tioashu"></b> </div>')
var sin_list = {};
sin_list.keyword = se_ch;
sin_list.pageIndex = 1;
sin_list.pageSize = 10;
var totalPage;//总页码
var totalRecords;//总数据条数
var pageNo = sin_list.pageIndex;//当前页码
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/searchArticleAll',
data: sin_list,
success: function (result) {
if (result.code == 0) {
totalPage = result.data.count % sin_list.pageSize == 0 ? (result.data.count / sin_list.pageSize) : (Math.ceil(result.data.count / sin_list.pageSize));
totalRecords = result.data.count;
$('.wenz_list .tioashu').html(result.data.count);
$('.wenz_list>h4').html('"' + se_ch + '" search results');
$(".sfh_inp").val(se_ch)
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage.stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage.stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '</div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal.title + '.&nbsp;' + arr[i].stage.stage_year + ',&nbsp;' + arr[i].stage.stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
//生成分页
//有些参数是可选的比如lang若不传有默认值
kkpager.generPageHtml({
pno: pageNo,
//总页码
total: totalPage,
//总数据条数
totalRecords: totalRecords,
mode: 'click',//默认值是link可选link或者click
click: function (n) {
this.selectPage(n);
//除了第一页写逻辑跳转
sin_list.pageIndex = n;
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/searchArticleAll',
data: sin_list,
success: function (result) {
if (result.code == 0) {
totalRecords = result.data.count;
$('.wenz_list .tioashu').html(result.data.count);
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage.stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage.stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '</div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal.title + '.&nbsp;' + arr[i].stage.stage_year + ',&nbsp;' + arr[i].stage.stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.goup-container').click();
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post',
url: apiUrl + 'yuan/Article/addArticleNum',
async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
return false;
}, lang: {
firstPageText: 'First page',
firstPageTipText: 'First page',
lastPageText: 'Last page',
lastPageTipText: 'Last page',
prePageText: 'Previous page',
prePageTipText: 'Previous page',
nextPageText: 'Next page',
nextPageTipText: 'Next page',
totalPageBeforeText: '',
totalPageAfterText: '',
currPageBeforeText: 'on page&nbsp;',
currPageAfterText: '',
totalInfoSplitStr: '&nbsp;of&nbsp;',
totalRecordsBeforeText: '',
totalRecordsAfterText: '',
gopageBeforeText: '&nbsp;&nbsp;&nbsp;Go to page',
gopageButtonOkText: 'Go',
gopageAfterText: 'page',
buttonTipBeforeText: '第',
buttonTipAfterText: '页'
}
});
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
if (set_text != null) {
$('.art_main_con').append('<div id="kkpager"></div>')
$('.wenz_list').append('<div style="font-size: 12px;text-align: right;padding-top: 10px;padding-right: 27px;" class="gue_chinese_tot">all total <b class="tioashu"></b> </div>')
var text_list = {};
text_list.journal_id = '1,10,6,12,13,8,4,14,11,9,7,15,3,16,2,17,18,20,19,24,21,22';
text_list.val1 = set_text;
text_list.key1 = set_xial;
text_list.pageIndex = 1;
text_list.pageSize = 10;
var totalPage;//总页码
var totalRecords;//总数据条数
var pageNo = text_list.pageIndex;//当前页码
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/searchArticleMenu',
data: text_list,
success: function (result) {
if (result.code == 0) {
totalPage = result.data.count % text_list.pageSize == 0 ? (result.data.count / text_list.pageSize) : (Math.ceil(result.data.count / text_list.pageSize));
totalRecords = result.data.count;
$('.wenz_list .tioashu').html(result.data.count);
$('.wenz_list>h4').html('"' + set_text + '" search results');
$(".sfh_inp").val(set_text)
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage.stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage.stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '</div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal.title + '.&nbsp;' + arr[i].stage.stage_year + ',&nbsp;' + arr[i].stage.stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
//生成分页
//有些参数是可选的比如lang若不传有默认值
kkpager.generPageHtml({
pno: pageNo,
//总页码
total: totalPage,
//总数据条数
totalRecords: totalRecords,
mode: 'click',//默认值是link可选link或者click
click: function (n) {
this.selectPage(n);
//除了第一页写逻辑跳转
text_list.pageIndex = n;
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/searchArticleMenu',
data: text_list,
success: function (result) {
if (result.code == 0) {
totalRecords = result.data.count;
$('.wenz_list .tioashu').html(result.data.count);
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage.stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage.stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '</div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal.title + '.&nbsp;' + arr[i].stage.stage_year + ',&nbsp;' + arr[i].stage.stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.goup-container').click();
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post',
url: apiUrl + 'yuan/Article/addArticleNum',
async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
return false;
}, lang: {
firstPageText: 'First page',
firstPageTipText: 'First page',
lastPageText: 'Last page',
lastPageTipText: 'Last page',
prePageText: 'Previous page',
prePageTipText: 'Previous page',
nextPageText: 'Next page',
nextPageTipText: 'Next page',
totalPageBeforeText: '',
totalPageAfterText: '',
currPageBeforeText: 'on page&nbsp;',
currPageAfterText: '',
totalInfoSplitStr: '&nbsp;of&nbsp;',
totalRecordsBeforeText: '',
totalRecordsAfterText: '',
gopageBeforeText: '&nbsp;&nbsp;&nbsp;Go to page',
gopageButtonOkText: 'Go',
gopageAfterText: 'page',
buttonTipBeforeText: '第',
buttonTipAfterText: '页'
}
});
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
}
// 高级搜索
function seek_senior() {
// 增加访问次数
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': 'de'},
success: function (result) {
if (result.code == 0) {
} else {
// ShowDanger("请求失败!");
}
},
error: function () {
// ShowDanger("error");
}
});
// 多选期刊
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getJournalList',
data: {},
success: function (result) {
if (result.code == 0) {
var arr = result.data.journalList;
var str = "";
var sgr = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].title != 'tmRxiv') {
str += '<label><input name="ser_in1" type="checkbox" value="' + arr[i].journal_id + '" />' + arr[i].title + '</label>'
}
}
$(".fu_xk>div").append(str);
// 全选或者不选
$('.checkall').click(function () {
$('input[name="ser_in1"]').each(function () {
$(this).prop("checked", true);
});
})
$('.deselall').click(function () {
$('input[name="ser_in1"]').each(function () {
$(this).prop("checked", false);
});
})
} else {
// ShowDanger("请求失败!");
}
},
error: function () {
// ShowDanger("error");
}
});
// Topic通用文章
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getAllTopics',
data: {},
beforeSend: function () {
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.topic;
var str = '';
for (var i = 0; i < arr.length; i++) {
str += '<li><a href="artihom_list.html?J_num=1&base_id=' + arr[i].base_topic_id
+ '" target="_blank"><img src="' + imgbaseUrl + arr[i].icon + '"><h3>' +
arr[i].title + '</h3></a></li>'
}
$(".cur_rency ul").html(str + '<br clear="both"/>');
// 话题订阅
var data_de = [];
for (var i = 0; i < arr.length; i++) {
data_de.push({
id: arr[i].base_topic_id,
text: arr[i].title
});
}
$('#combox_box').selectivity({
allowClear: true,
items: data_de,
placeholder: 'Please choose topic'
})
// 订阅提交
$(".yue_de").click(function () {
$(".spa").text('');
var add_mess = {};
add_mess.email = $('#emapl_de').val();
add_mess.base_topic_id = $('#combox_box').selectivity('val');
var S_Dan = '0';
var reg = /^[-.-_A-Za-z0-9]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/
if ($('#combox_box').selectivity('val') == null) {
$(".spa_de").text('Please choose topic');
S_Dan = '1';
} else if ($("#emapl_de").val() == "") {
$(".spa_de").text('Please fill in E-mail');
S_Dan = '1';
} else if (!(reg.test($("#emapl_de").val()))) {
$(".spa_de").text('Please fill in properly formatted E-mail');
S_Dan = '1';
}
if (S_Dan == '1') {
ShowDanger("Incomplete information");
} else {
$(".yue_de").addClass("disable");
$.ajax({
type: 'post', url: apiUrl + 'subscribe/Journal/addSubscribeBaseTopic',
data: add_mess,
success: function (result) {
if (result.code == 0) {
$(".ding_yue input[type='text']").val('');
$(".yue_de").removeClass("disable");
$(".jour_ts").fadeIn();
$(".jour_ts .mainbox input[type='submit']").css('background-color', '#006699')
$(".jour_ts input.tishi_author").click(function () {
$(".jour_ts").fadeOut();
});
} else {
ShowDanger(result.msg);
$(".yue_de").removeClass("disable");
}
},
error: function () {
ShowDanger("error");
$(".yue_de").removeClass("disable");
}
})
}
})
} else {
ShowDanger("请求失败!");
}
}
})
// Herbs Topic文章
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getTopicList',
data: {
"journal_topic_id": '48'
},
success: function (result) {
if (result.code == 0) {
// 话题列表
var arr = result.data.journalList;
var str_1 = "";
var str_2 = "";
var str_3 = "";
var str_4 = "";
var str_5 = "";
var str_6 = "";
var url_href = '';
for (var i = 0; i < arr.length; i++) {
var szm_txt = arr[i].title.slice(0, 1);
if (arr[i].is_final == '1') {
url_href = 'topic_list.html?J_num=1&t_id='
} else {
url_href = 'topic.html?J_num=1&t_id='
}
if (szm_txt == 'A' || szm_txt == 'B' || szm_txt == 'C' || szm_txt == 'D') {
str_1 += '<li><a href="' + url_href + arr[i].journal_topic_id + '" target="_blank">' +
'<img src="' + imgtopicUrl + arr[i].icon + '">' +
'<h3>' + arr[i].title + '</h3></a></li>'
} else if (szm_txt == 'E' || szm_txt == 'F' || szm_txt == 'G' || szm_txt == 'H') {
str_2 += '<li><a href="' + url_href + arr[i].journal_topic_id + '" target="_blank">' +
'<img src="' + imgtopicUrl + arr[i].icon + '">' +
'<h3>' + arr[i].title + '</h3></a></li>'
} else if (szm_txt == 'I' || szm_txt == 'J' || szm_txt == 'K' || szm_txt == 'L') {
str_3 += '<li><a href="' + url_href + arr[i].journal_topic_id + '" target="_blank">' +
'<img src="' + imgtopicUrl + arr[i].icon + '">' +
'<h3>' + arr[i].title + '</h3></a></li>'
} else if (szm_txt == 'M' || szm_txt == 'N' || szm_txt == 'O' || szm_txt == 'P') {
str_4 += '<li><a href="' + url_href + arr[i].journal_topic_id + '" target="_blank">' +
'<img src="' + imgtopicUrl + arr[i].icon + '">' +
'<h3>' + arr[i].title + '</h3></a></li>'
} else if (szm_txt == 'Q' || szm_txt == 'R' || szm_txt == 'S' || szm_txt == 'T') {
str_5 += '<li><a href="' + url_href + arr[i].journal_topic_id + '" target="_blank">' +
'<img src="' + imgtopicUrl + arr[i].icon + '">' +
'<h3>' + arr[i].title + '</h3></a></li>'
} else if (szm_txt == 'U' || szm_txt == 'V' || szm_txt == 'W' || szm_txt == 'X' || szm_txt == 'Y' || szm_txt == 'Z') {
str_6 += '<li><a href="' + url_href + arr[i].journal_topic_id + '" target="_blank">' +
'<img src="' + imgtopicUrl + arr[i].icon + '">' +
'<h3>' + arr[i].title + '</h3></a></li>'
}
}
$(".topic_sek .hua_con>ul").eq(0).html(str_1 + '<br clear="both">');
$(".topic_sek .hua_con>ul").eq(1).html(str_2 + '<br clear="both">');
$(".topic_sek .hua_con>ul").eq(2).html(str_3 + '<br clear="both">');
$(".topic_sek .hua_con>ul").eq(3).html(str_4 + '<br clear="both">');
$(".topic_sek .hua_con>ul").eq(4).html(str_5 + '<br clear="both">');
$(".topic_sek .hua_con>ul").eq(5).html(str_6 + '<br clear="both">');
$(".topic_sek .hua_tab>div").click(function () {
$(".topic_sek .hua_tab>div").eq($(this).index()).addClass("cur").siblings().removeClass('cur');
$(".topic_sek .hua_con>ul").hide().eq($(this).index()).show();
//另一种方法: $("div").eq($(".tab li").index(this)).addClass("on").siblings().removeClass('on');
});
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
// 药剂Medicament文章
$.ajax({
type: 'post', url: apiUrl + 'api/Tmrde/getAllMeds',
data: {},
success: function (result) {
if (result.code == 0) {
// 话题列表
var arr = result.data.meds;
var str_1 = "";
var str_2 = "";
var str_3 = "";
var str_4 = "";
var str_5 = "";
var str_6 = "";
var str_7 = "";
var str_8 = "";
var str_9 = "";
var url_href = '';
for (var i = 0; i < arr.length; i++) {
var szm_txt = arr[i].med_ename.slice(0, 1);
url_href = 'artihom_list.html?J_num=1&stuff_ID='
if (szm_txt == 'A' || szm_txt == 'B' || szm_txt == 'C') {
str_1 += '<li><a href="' + url_href + arr[i].med_id + '" target="_blank">' +
'<h3>' + arr[i].med_ename + '</h3><h5>' + arr[i].med_title + '</h5></a></li>'
} else if (szm_txt == 'D' || szm_txt == 'E' || szm_txt == 'F') {
str_2 += '<li><a href="' + url_href + arr[i].med_id + '" target="_blank">' +
'<h3>' + arr[i].med_ename + '</h3><h5>' + arr[i].med_title + '</h5></a></li>'
} else if (szm_txt == 'G' || szm_txt == 'H' || szm_txt == 'I') {
str_3 += '<li><a href="' + url_href + arr[i].med_id + '" target="_blank">' +
'<h3>' + arr[i].med_ename + '</h3><h5>' + arr[i].med_title + '</h5></a></li>'
} else if (szm_txt == 'J' || szm_txt == 'K' || szm_txt == 'L') {
str_4 += '<li><a href="' + url_href + arr[i].med_id + '" target="_blank">' +
'<h3>' + arr[i].med_ename + '</h3><h5>' + arr[i].med_title + '</h5></a></li>'
} else if (szm_txt == 'M' || szm_txt == 'N' || szm_txt == 'O') {
str_5 += '<li><a href="' + url_href + arr[i].med_id + '" target="_blank">' +
'<h3>' + arr[i].med_ename + '</h3><h5>' + arr[i].med_title + '</h5></a></li>'
} else if (szm_txt == 'P' || szm_txt == 'Q' || szm_txt == 'R') {
str_6 += '<li><a href="' + url_href + arr[i].med_id + '" target="_blank">' +
'<h3>' + arr[i].med_ename + '</h3><h5>' + arr[i].med_title + '</h5></a></li>'
} else if (szm_txt == 'S' || szm_txt == 'T' || szm_txt == 'U') {
str_7 += '<li><a href="' + url_href + arr[i].med_id + '" target="_blank">' +
'<h3>' + arr[i].med_ename + '</h3><h5>' + arr[i].med_title + '</h5></a></li>'
} else if (szm_txt == 'V' || szm_txt == 'W' || szm_txt == 'X') {
str_8 += '<li><a href="' + url_href + arr[i].med_id + '" target="_blank">' +
'<h3>' + arr[i].med_ename + '</h3><h5>' + arr[i].med_title + '</h5></a></li>'
} else if (szm_txt == 'Y' || szm_txt == 'Z') {
str_9 += '<li><a href="' + url_href + arr[i].med_id + '" target="_blank">' +
'<h3>' + arr[i].med_ename + '</h3><h5>' + arr[i].med_title + '</h5></a></li>'
}
}
$(".stuff_sek .stuff_con>ul").eq(0).html(str_1 + '<br clear="both">');
$(".stuff_sek .stuff_con>ul").eq(1).html(str_2 + '<br clear="both">');
$(".stuff_sek .stuff_con>ul").eq(2).html(str_3 + '<br clear="both">');
$(".stuff_sek .stuff_con>ul").eq(3).html(str_4 + '<br clear="both">');
$(".stuff_sek .stuff_con>ul").eq(4).html(str_5 + '<br clear="both">');
$(".stuff_sek .stuff_con>ul").eq(5).html(str_6 + '<br clear="both">');
$(".stuff_sek .stuff_con>ul").eq(6).html(str_7 + '<br clear="both">');
$(".stuff_sek .stuff_con>ul").eq(7).html(str_8 + '<br clear="both">');
$(".stuff_sek .stuff_con>ul").eq(8).html(str_9 + '<br clear="both">');
$(".stuff_sek .stuff_tab>div").click(function () {
$(".stuff_sek .stuff_tab>div").eq($(this).index()).addClass("cur").siblings().removeClass('cur');
$(".stuff_sek .stuff_con>ul").hide().eq($(this).index()).show();
//另一种方法: $("div").eq($(".tab li").index(this)).addClass("on").siblings().removeClass('on');
});
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
// 点击添加
$('.serseek .search .fu_form .seek_add').click(function () {
var form_seek_add = '<select name="ser_in4" class="ser_anor"><option value="and">And</option><option value="or">Or</option></select>' +
'<select name="ser_in5" class="ser_ect"><option value="title">Title</option><option value="abstract">Abstract</option><option value="keywords">Keywords</option><option value="author">Author</option></select>' +
'<input type="text" placeholder="Please enter the..." name="ser_in6" value="" class="ser_input"/>' +
'<a class="seek_delete"><b>-</b></a>'
$('.fu_form .loo_ne').html(form_seek_add);
// 点击删除
$('.serseek .search .fu_form .seek_delete').click(function () {
$('.fu_form .loo_ne').html('');
})
})
// 下册期刊
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getJournalList',
data: {},
success: function (result) {
if (result.code == 0) {
var arr = result.data.journalList;
var str = '';
// tmr im hpm lr cancer tcr
str = '<a target="_blank" href="/' + arr[0].usx + '"><li>' +
'<img src="' + imgjourUrl + arr[0].icon + '" alt=""></li></a>' +
'<a target="_blank" href="/' + arr[15].usx + '"><li>' +
'<img src="' + imgjourUrl + arr[15].icon + '" alt=""></li></a>' +
'<a target="_blank" href="/' + arr[5].usx + '"><li>' +
'<img src="' + imgjourUrl + arr[5].icon + '" alt=""></li></a>' +
'<a target="_blank" href="/' + arr[7].usx + '"><li>' +
'<img src="' + imgjourUrl + arr[7].icon + '" alt=""></li></a>' +
'<a target="_blank" href="/' + arr[14].usx + '"><li>' +
'<img src="' + imgjourUrl + arr[14].icon + '" alt=""></li></a>' +
'<a target="_blank" href="/' + arr[13].usx + '"><li>' +
'<img src="' + imgjourUrl + arr[13].icon + '" alt=""></li></a>'
$('.show_jour ul').html(str);
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
// 轮播
// $.ajax({
// type: 'post', url: apiUrl + 'api/Journal/getNewsArticle',
// data: {
// "journal_id": Jour_num
// },
// success: function (result) {
// if (result.code == 0) {
// var arr = result.data.articlelist;
// var str = '';
// for (var i = 0; i < arr.length; i++) {
// if(i == 5) break;
// str += '<li class="carousel-item"><img src="'+imgarticleUrl + arr[i].icon+'"/>' +
// '<div class="di_con"><h3><a href="../article.html?J_num=14&a_id='+arr[i].article_id+'" target="_blank">'+
// arr[i].title+'</a></h3><p>'+arr[i].authortitle+' | '+arr[i].stage_year+'</p></div></li>'
// }
// // $('.ft-carousel .carousel-inner').html(str);
// $("#carousel_1").FtCarousel();
// } else {
// // ShowDanger("请求失败!");
// $('.ncon_fr').css('display','none')
// }
// },
// error: function () {
// ShowDanger("error");
// }
// })
// 展览信息(轮播)
// 左侧期刊列表数据
// $.ajax({
// type: 'post', url: apiUrl+'api/Journal/getJournal',
// data: {
// "journal_id":'1'
// },
// success : function(result) {
// if (result.code == 0) {
//
// // 期刊基础信息
// var arr_jour = result.data.journal;
// // $('.rgb_color_background').css('background-color',arr_jour.system_color);
// // $('.drup_ne .draw_form').css('background-color','#00669913');
// $('.drup_ne_tmr .draw_form input').css('border-color',arr_jour.system_color);
// $('.drup_ne_tmr .draw_form input[type="submit"]').css('background-color',arr_jour.system_color);
// $('.jour_ts input[type="submit"]').css('background-color',arr_jour.system_color);
// $('.jour_ts input[type="submit"]').css('border-color',arr_jour.system_color);
//
// $('.drup_ne_tmr .dn_mess>a').attr("href" , arr_jour.usx);
// $('.drup_ne_tmr .dn_mess>a img').attr("src" , imgjourUrl + arr_jour.icon);
// $('.drup_ne_tmr .dn_mess div .dn_tit').html(arr_jour.title);
// $('.drup_ne_tmr .dn_mess div .dn_issn').html(arr_jour.issn);
// $('.drup_ne_tmr .dn_mess div .dn_edit').html(arr_jour.editorinchief);
// $('.drup_ne_tmr .dn_mess div .dn_accep').html(arr_jour.acceptance);
// $('.drup_ne_tmr .dn_mess div .dn_final').html(arr_jour.finaldecision);
// $('.drup_ne_tmr .dn_mess div .dn_APC').html(arr_jour.apc);
// $('.drup_ne_tmr .draw_form p b').html(arr_jour.title);
//
//
// }else{
// ShowDanger("请求失败!");
// }
// },
// error : function() {
// ShowDanger("error");
// }
// });
// $.ajax({
// type: 'post', url: apiUrl+'api/Journal/getJournal',
// data: {
// "journal_id":'14'
// },
// success : function(result) {
// if (result.code == 0) {
//
// // 期刊基础信息
// var arr_jour = result.data.journal;
// // $('.rgb_color_background').css('background-color',arr_jour.system_color);
// // $('.drup_ne .draw_form').css('background-color','#00669913');
// $('.drup_ne_lr .draw_form input').css('border-color',arr_jour.system_color);
// $('.drup_ne_lr .draw_form input[type="submit"]').css('background-color',arr_jour.system_color);
//
// $('.drup_ne_lr .dn_mess>a').attr("href" , arr_jour.usx);
// $('.drup_ne_lr .dn_mess>a img').attr("src" , imgjourUrl + arr_jour.icon);
// $('.drup_ne_lr .dn_mess div .dn_tit').html(arr_jour.title);
// $('.drup_ne_lr .dn_mess div .dn_issn').html(arr_jour.issn);
// $('.drup_ne_lr .dn_mess div .dn_edit').html(arr_jour.editorinchief);
// $('.drup_ne_lr .dn_mess div .dn_accep').html(arr_jour.acceptance);
// $('.drup_ne_lr .dn_mess div .dn_final').html(arr_jour.finaldecision);
// $('.drup_ne_lr .dn_mess div .dn_APC').html(arr_jour.apc);
// $('.drup_ne_lr .draw_form p b').html(arr_jour.title);
//
//
// }else{
// ShowDanger("请求失败!");
// }
// },
// error : function() {
// ShowDanger("error");
// }
// });
// 订阅提交
//11111111111
// $(".yue_addw").click(function(){
// $(".spa6").text('');
// var add_mess = {};
// add_mess.journal_id = '1';
// add_mess.email = $('#emapw').val();
//
// var S_Dan = '0';
// var reg = /^[-.-_A-Za-z0-9]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/
// if ($("#emapw").val() == "") {
// $(".spa6").text('Please fill in E-mail');
// S_Dan = '1';
// }else if(!(reg.test($("#emapw").val()))){
// $(".spa6").text('Please fill in properly formatted E-mail');
// S_Dan = '1';
// }
//
//
// if (S_Dan == '1') {
// ShowDanger("Incomplete information");
// } else {
// $(".yue_addw").addClass("disable");
// $.ajax({
// type: 'post', url: apiUrl + 'subscribe/Journal/addSubscribeJournal',
// data: add_mess,
// success: function (result) {
// if (result.code == 0) {
// $(".draw_form input[type='text']").val('');
// $(".yue_addw").removeClass("disable");
// $(".jour_ts").fadeIn();
// } else {
// ShowDanger(result.msg);
// $(".yue_addw").removeClass("disable");
// }
// },
// error: function () {
// ShowDanger("error");
// $(".yue_addw").removeClass("disable");
// }
// })
// }
// })
// //14141414141414
// $(".yue_addl").click(function(){
// $(".spa7").text('');
// var add_mess = {};
// add_mess.journal_id = '14';
// add_mess.email = $('.carousel-inner>li:nth-child(3) #emals').val();
//
// var S_Dan = '0';
// var reg = /^[-.-_A-Za-z0-9]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/
// if ($('.carousel-inner>li:nth-child(3) #emals').val() == "") {
// $(".spa7").text('Please fill in E-mail');
// S_Dan = '1';
// }else if(!(reg.test($('.carousel-inner>li:nth-child(3) #emals').val()))){
// $(".spa7").text('Please fill in properly formatted E-mail');
// S_Dan = '1';
// }
// if (S_Dan == '1') {
// ShowDanger("Incomplete information");
// } else {
// $(".yue_addl").addClass("disable");
// $.ajax({
// type: 'post', url: apiUrl + 'subscribe/Journal/addSubscribeJournal',
// data: add_mess,
// success: function (result) {
// if (result.code == 0) {
// $(".draw_form input[type='text']").val('');
// $(".yue_addl").removeClass("disable");
// $(".jour_ts").fadeIn();
// } else {
// ShowDanger(result.msg);
// $(".yue_addl").removeClass("disable");
// }
// },
// error: function () {
// ShowDanger("error");
// $(".yue_addl").removeClass("disable");
// }
// })
// }
// })
//
// $(".jour_ts input.tishi_author").click(function(){
// $(".jour_ts").fadeOut();
// });
// 展开隐藏
// $('.zk_yc').click(function () {
// if($('.zk_yc').html()=='show'){
// $('.search>.xc_b').show();
// $('.zk_yc').html('hide')
// }else{
// $('.search>.xc_b').hide();
// $('.zk_yc').html('show')
// }
// })
// 点击搜索
$('.serseek .serior_btn').click(function () {
var chk_value = [];//定义一个数组
$('input[name="ser_in1"]:checked').each(function () {//遍历每一个名字为nodes的复选框其中选中的执行函数
chk_value.push($(this).val());//将选中的值添加到数组chk_value中
});
var groups = chk_value.join(",");
if(groups==''){
ShowDanger("Please select a journal");
return
}
$('.exten_sion').hide();
$('.cur_rency').hide();
$('.sy_topic').hide();
$('.ding_yue').hide();
$('.sy_stuff').hide();
// $('.zk_yc').html('show')
$('.art_main_con').html('<div class="new_art wenz_list"><h4 class="rgb_color">Search Results</h4><ul></ul></div>')
$('.wenz_list').append('<div style="font-size: 12px;text-align: right;padding-top: 10px;padding-right: 27px;" class="gue_chinese_tot">all total <b class="tioashu"></b> </div>')
var se_ary = {}
se_ary.journal_id = groups
// se_ary.start_date = $(".search select[name='ser_stat']").find("option:selected").val()
se_ary.key1 = $(".search select[name=ser_in2]").find("option:selected").val()
se_ary.val1 = $(".ser_input[name=ser_in3]").val()
if ($(".search select[name=ser_in4]").find("option:selected").val() != undefined) {
se_ary.oper = $(".search select[name=ser_in4]").find("option:selected").val()
}
if ($(".search select[name=ser_in5]").find("option:selected").val() != undefined) {
se_ary.key2 = $(".search select[name=ser_in5]").find("option:selected").val()
}
if ($(".ser_input[name=ser_in6]").val() != undefined) {
se_ary.val2 = $(".ser_input[name=ser_in6]").val()
}
se_ary.pageIndex = 1
se_ary.pageSize = $(".ser_input[name=ser_in7]").val()
// se_ary.sort = $("input[name=ser_in8]:checked").val()
var totalPage;//总页码
var totalRecords;//总数据条数
var pageNo = se_ary.pageIndex;//当前页码
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/searchArticleMenu',
data: se_ary,
success: function (result) {
if (result.code == 0) {
totalPage = result.data.count % se_ary.pageSize == 0 ? (result.data.count / se_ary.pageSize) : (Math.ceil(result.data.count / se_ary.pageSize));
totalRecords = result.data.count;
$('.wenz_list .tioashu').html(result.data.count);
$('.wenz_list>h4').html("Search Results");
var arr = result.data.articles;
var str = "";
if (arr != '') {
$('.art_main_con').append('<div id="kkpager"></div>')
}
for (var i = 0; i < arr.length; i++) {
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage.stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage.stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '</div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal.title + '.&nbsp;' + arr[i].stage.stage_year + ',&nbsp;' + arr[i].stage.stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {'type': $(this).siblings('.jum_art_id').attr('alt'), 'is_detail': '1'},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
//生成分页
//有些参数是可选的比如lang若不传有默认值
kkpager.generPageHtml({
pno: pageNo,
//总页码
total: totalPage,
//总数据条数
totalRecords: totalRecords,
mode: 'click',//默认值是link可选link或者click
click: function (n) {
this.selectPage(n);
//除了第一页写逻辑跳转
se_ary.pageIndex = n;
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/searchArticleMenu',
data: se_ary,
success: function (result) {
if (result.code == 0) {
totalRecords = result.data.count;
$('.wenz_list .tioashu').html(result.data.count);
var arr = result.data.articles;
var str = "";
for (var i = 0; i < arr.length; i++) {
if (arr[i].doi == '') {
var doi_ = ''
} else {
var doi_ = 'https://doi.org/' + arr[i].doi
}
if (arr[i].npp == '') {
var npp_ = ''
} else {
var npp_ = ':&nbsp;' + arr[i].npp + '.&nbsp;&nbsp;'
}
if (arr[i].stage.stage_no == '0') {
var stage_ = ''
} else {
var stage_ = '&nbsp;(' + arr[i].stage.stage_no + ')'
}
if (arr[i].mains == '') {
if (arr[i].file_html == '') {
var html_ = ''
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + arr[i].file_html + '" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
} else {
var html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + arr[i].article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + arr[i].article_id + '">HTML</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].html_num + '</span>&nbsp;)&nbsp;&nbsp;'
}
if (arr[i].file_pdf == '') {
var pdf_ = ''
} else {
var pdf_ = '<img src="img/link_3.jpg" width="14" height="16"><a href="' + imgFileUrl + 'articlePDF/' + arr[i].file_pdf + '" target="_blank" class="txt_pdf" alt="' + arr[i].article_id + '">PDF</a>&nbsp;(&nbsp;<span style="color: red">' + arr[i].pdf_num + '</span>&nbsp;)'
}
if (arr[i].article_id == '172') {
var mp4_ = '<a href="https://youtu.be/3eDbnHRkFKQ" target="_blank"><img src="img/link_5.png" width="50" height="16" style="margin-left: 10px"></a>'
} else {
var mp4_ = ''
}
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
if (arr[i].other_state == 0) {
var otStat = ''
} else if (arr[i].other_state == 1) {
var otStat = '<span class="otStat">Editorial Expression of Concern</span>'
} else if (arr[i].other_state == 2) {
var otStat = '<span class="otStat">Retracted</span>'
}
if (arr[i].isShowOtime == 1) {
if (arr[i].pub_date == '') {
var pub_date = ''
} else {
var pub_date = '<div class="url_data">Published Date: ' + arr[i].pub_date + '</div>'
}
} else {
var pub_date = ''
}
if (arr[i].article_id == '86' || arr[i].article_id == '176' || arr[i].article_id == '455' || arr[i].article_id == '400' || arr[i].article_id == '145' || arr[i].article_id == '116' || arr[i].article_id == '717' || arr[i].article_id == '632' || arr[i].article_id == '24') {
var person_img = '<img src="' + img_i + '" alt="" style="width: 120px">'
} else {
var person_img = '<img src="' + img_i + '" alt="">'
}
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var link_ = '<img src="img/link_1.png" width="14" height="16"><a class="txt_zhaiyao" alt="' + arr[i].article_id + '">Abstract</a>&nbsp;(&nbsp;<span style="color: red" alt="' + arr[i].journal_id + '" class="jum_art_id">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ +
'<button class="txt_copy">Cite this article<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> Copy citation information</li><li class="Exc_2"><i class="fa fa-download"></i> Export citation to EndNote</li><li class="Exc_3"><i class="fa fa-download"></i> Export citation to RIS</li><li class="Exc_4"><i class="fa fa-download"></i> Export citation to BibTex</li><li class="Exc_5"><i class="fa fa-download"></i> Export citation to txt</li><div class="triangle"></div></ul></button>' +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
if (arr[i].tradition_tag == '' || arr[i].tradition_tag == null) {
var maxwidth = 800;//显示多少字符
if (arr[i].abstract.length > maxwidth) {
var abstNew= arr[i].abstract.replace(/<.*?>/ig,"")
abstNew = abstNew.substring(0, maxwidth)
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
var trad_tion = '<div>' + abstNew + '...</div>'
} else {
var trad_tion = '<div>' + arr[i].abstract + '</div>'
}
} else {
var trad_tion = '<div><h3>' + arr[i].tradition_tag + '</h3><p>' + arr[i].tradition + '</p></div>'
}
str += '<li><div class="dbt_header">' + arr[i].type + pub_date + '</div>' +
'<a id="' + arr[i].article_id + '" target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '" class="txt_biaoti">' + otStat + arr[i].title + '</a>' +
'<div class="authorList">' + arr[i].authortitle + ' <br>'
+ arr[i].journal.title + '.&nbsp;' + arr[i].stage.stage_year + ',&nbsp;' + arr[i].stage.stage_vol + stage_ + npp_ +
'<a target="_blank" href="https://doi.org/' + arr[i].doi + '">' + doi_ + '</a>' +
'</div><div class="links_">' + link_ + '</div><div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">' + person_img + '</a>'
+ trad_tion +'<br clear="both"></div></li>'
}
$('.wenz_list>ul').html(str);
$('.goup-container').click();
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
// 点击Abstract显示隐藏
$('.txt_zhaiyao').click(function () {
$(this).nextAll('div').toggle();
if ($(this).nextAll('div').css("display") == 'block') {
var num = $(this).next().html();
$.ajax({
type: 'post',
url: apiUrl + 'yuan/Article/addArticleNum',
async: false,
data: {"article_id": $(this).attr('alt'), "type": 'abs'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
}
})
$('.txt_html').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'html'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
})
$('.txt_pdf').click(function () {
var num = $(this).next().html();
$.ajax({
type: 'post', url: apiUrl + 'yuan/Article/addArticleNum', async: false,
data: {"article_id": $(this).attr('alt'), "type": 'pdf'},
success: function (result) {
if (result.code == 0) {
num = num * 1 + 1 * 1
}
}
})
$.ajax({
type: 'post', url: apiUrl + 'super/Publish/addVisitNum',
data: {
'type': $(this).siblings('.jum_art_id').attr('alt'),
'is_detail': '1'
},
success: function (result) {
}
});
$(this).next().html(num);
})
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
$('.export').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export') && !$(e.target).is('.txt_copy')) {
$('.export').hide();
}
})
$('.txt_copy').click(function () {
$('.export').css('display', 'none');
$(this).find('.export').fadeIn(200);
})
$('.Exc_1').click(function () {
var content_ = $(this).parents('.txt_copy').nextAll('.txt_content').text();
var clipboard = new Clipboard('#' + $(this).attr('id'), {
text: function () {
return content_;
}
})
clipboard.on('success', function (e) {
ShowSuccess("Citation information has been copied!");
});
})
$('.Exc_2').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleenw', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_3').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleRis', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_4').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticlebib', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
$('.Exc_5').click(function () {
var ecx_id = $(this).parents('.links_').siblings('.txt_biaoti').attr('id')
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticletext', async: false,
data: {"article_id": ecx_id},
success: function (result) {
var a = document.createElement('a');
a.href = result.data.url;
a.download = ''
a.click();
}
})
})
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
return false;
}, lang: {
firstPageText: 'First page',
firstPageTipText: 'First page',
lastPageText: 'Last page',
lastPageTipText: 'Last page',
prePageText: 'Previous page',
prePageTipText: 'Previous page',
nextPageText: 'Next page',
nextPageTipText: 'Next page',
totalPageBeforeText: '',
totalPageAfterText: '',
currPageBeforeText: 'on page&nbsp;',
currPageAfterText: '',
totalInfoSplitStr: '&nbsp;of&nbsp;',
totalRecordsBeforeText: '',
totalRecordsAfterText: '',
gopageBeforeText: '&nbsp;&nbsp;&nbsp;Go to page',
gopageButtonOkText: 'Go',
gopageAfterText: 'page',
buttonTipBeforeText: '第',
buttonTipAfterText: '页'
}
});
} else {
ShowDanger("error");
}
},
error: function () {
ShowDanger("error");
}
});
})
// $('.serseek .serior_btn>a').click(function () {
// var ary=[]
// for (var i=0;i<$("form").length;i++){
// var yy=$("form").eq(i).serializeArray()
// var pp={}
// for (var j=0;j<yy.length;j++){
// var tt = yy[j].name;
// pp[tt]=yy[j].value;
// }
// ary.push(pp);
// }
// console.log(ary);
// })
}
// 智慧搜索期刊列表
function art_wisdom() {
// 获取地址栏信息
function getQueryString(name) {
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
var r = window.location.search.substr(1).match(reg);
if (r != null) return unescape(r[2]);
return null;
}
var wis_Dom = getQueryString('wis_dom'); //消息
if (wis_Dom == 0) {
// 全部
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/findJournalTopic',
data: {
'journal_topic_id': wis_Dom
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.journals;
var str_1 = '';
var str_2 = '';
var str_3 = '';
var str_4 = '';
var str_5 = '';
var str_6 = '';
for (var i = 0; i < arr.length; i++) {
if (arr[i].title != 'tmRxiv') {
var list_tio = '' //话题
if (arr[i].topics == undefined) {
list_tio = '<a target="_blank" href="topic_list.html?J_num=' + arr[i].journal_id + '&t_id=' + arr[i].journal_topic_id + '">' + arr[i].topic_title + '</a>'
} else {
for (var j = 0; j < arr[i].topics.length; j++) {
if (j < arr[i].topics.length - 1) {
list_tio += '<a target="_blank" href="topic_list.html?J_num=' + arr[i].topics[j].journal_id + '&t_id=' + arr[i].topics[j].journal_topic_id + '">' + arr[i].topics[j].title + ',</a> '
} else {
list_tio += '<a target="_blank" href="topic_list.html?J_num=' + arr[i].topics[j].journal_id + '&t_id=' + arr[i].topics[j].journal_topic_id + '">' + arr[i].topics[j].title + '</a>'
}
}
}
var list_href = '' //外链
for (var p = 0; p < arr[i].abs.length; p++) {
if (p < arr[i].abs.length - 1) {
list_href += '<a target="_blank" href="' + arr[i].abs[p].url + '">' + arr[i].abs[p].title + ',</a> '
} else {
list_href += '<a target="_blank" href="' + arr[i].abs[p].url + '">' + arr[i].abs[p].title + '</a>'
}
}
// 出版周期匹配
if (arr[i].cycle == 1) {
arr[i].cycle_ = 'Monthly'
} else if (arr[i].cycle == 2) {
arr[i].cycle_ = 'Bimonthly'
} else if (arr[i].cycle == 3) {
arr[i].cycle_ = 'Quarterly'
}
if (arr[i].journal_id == 2 || arr[i].journal_id == 17 || arr[i].journal_id == 18) {
arr[i].cycle_ = 'Continuities'
}
if (i < 4) {
str_1 += '<li><a href="' + arr[i].usx + '" target="_blank"><img src="' + imgjourUrl + arr[i].icon + '" alt=""></a><div>' +
// '<a target="_blank" href="/' + arr[i].usx + '">' + arr[i].title + '</a>' +
'<h2>Abstracting & Indexing</h2><p>' + list_href + '...</p>' +
'<p><b>Editor-in-Chief: </b>' + arr[i].editorinchief +
'<br/><b>Acceptance: </b>' + arr[i].acceptance +
'<br/><b>Final Decision: </b>' + arr[i].finaldecision +
'<br/><b>APC: </b>' + arr[i].apc +
'<br/><b>Frequency: </b>' + arr[i].cycle_ + '</p>' +
'<h2>Scope</h2><p>' + list_tio + '</p>' +
'<a class="wis_btn wis_btn_1" target="_blank" href="for_author.html?J_num=' + arr[i].journal_id + '">For Authors</a>' +
'<a class="wis_btn" target="_blank" href="' + arr[i].submission_url + '">Submission</a>' +
'</div>'
} else if (i < 8) {
str_2 += '<li><a href="' + arr[i].usx + '" target="_blank"><img src="' + imgjourUrl + arr[i].icon + '" alt=""></a><div>' +
// '<a target="_blank" href="/' + arr[i].usx + '">' + arr[i].title + '</a>' +
'<h2>Abstracting & Indexing</h2><p>' + list_href + '...</p>' +
'<p><b>Editor-in-Chief: </b>' + arr[i].editorinchief +
'<br/><b>Acceptance: </b>' + arr[i].acceptance +
'<br/><b>Final Decision: </b>' + arr[i].finaldecision +
'<br/><b>APC: </b>' + arr[i].apc +
'<br/><b>Frequency: </b>' + arr[i].cycle_ + '</p>' +
'<h2>Scope</h2><p>' + list_tio + '</p>' +
'<a class="wis_btn wis_btn_1" target="_blank" href="for_author.html?J_num=' + arr[i].journal_id + '">For Authors</a>' +
'<a class="wis_btn" target="_blank" href="' + arr[i].submission_url + '">Submission</a>' +
'</div>'
} else if (i < 12) {
str_3 += '<li><a href="' + arr[i].usx + '" target="_blank"><img src="' + imgjourUrl + arr[i].icon + '" alt=""></a><div>' +
// '<a target="_blank" href="/' + arr[i].usx + '">' + arr[i].title + '</a>' +
'<h2>Abstracting & Indexing</h2><p>' + list_href + '...</p>' +
'<p><b>Editor-in-Chief: </b>' + arr[i].editorinchief +
'<br/><b>Acceptance: </b>' + arr[i].acceptance +
'<br/><b>Final Decision: </b>' + arr[i].finaldecision +
'<br/><b>APC: </b>' + arr[i].apc +
'<br/><b>Frequency: </b>' + arr[i].cycle_ + '</p>' +
'<h2>Scope</h2><p>' + list_tio + '</p>' +
'<a class="wis_btn wis_btn_1" target="_blank" href="for_author.html?J_num=' + arr[i].journal_id + '">For Authors</a>' +
'<a class="wis_btn" target="_blank" href="' + arr[i].submission_url + '">Submission</a>' +
'</div>'
} else if (i < 16) {
str_4 += '<li><a href="' + arr[i].usx + '" target="_blank"><img src="' + imgjourUrl + arr[i].icon + '" alt=""></a><div>' +
// '<a target="_blank" href="/' + arr[i].usx + '">' + arr[i].title + '</a>' +
'<h2>Abstracting & Indexing</h2><p>' + list_href + '...</p>' +
'<p><b>Editor-in-Chief: </b>' + arr[i].editorinchief +
'<br/><b>Acceptance: </b>' + arr[i].acceptance +
'<br/><b>Final Decision: </b>' + arr[i].finaldecision +
'<br/><b>APC: </b>' + arr[i].apc +
'<br/><b>Frequency: </b>' + arr[i].cycle_ + '</p>' +
'<h2>Scope</h2><p>' + list_tio + '</p>' +
'<a class="wis_btn wis_btn_1" target="_blank" href="for_author.html?J_num=' + arr[i].journal_id + '">For Authors</a>' +
'<a class="wis_btn" target="_blank" href="' + arr[i].submission_url + '">Submission</a>' +
'</div>'
} else if (i < 20) {
str_5 += '<li><a href="' + arr[i].usx + '" target="_blank"><img src="' + imgjourUrl + arr[i].icon + '" alt=""></a><div>' +
// '<a target="_blank" href="/' + arr[i].usx + '">' + arr[i].title + '</a>' +
'<h2>Abstracting & Indexing</h2><p>' + list_href + '...</p>' +
'<p><b>Editor-in-Chief: </b>' + arr[i].editorinchief +
'<br/><b>Acceptance: </b>' + arr[i].acceptance +
'<br/><b>Final Decision: </b>' + arr[i].finaldecision +
'<br/><b>APC: </b>' + arr[i].apc +
'<br/><b>Frequency: </b>' + arr[i].cycle_ + '</p>' +
'<h2>Scope</h2><p>' + list_tio + '</p>' +
'<a class="wis_btn wis_btn_1" target="_blank" href="for_author.html?J_num=' + arr[i].journal_id + '">For Authors</a>' +
'<a class="wis_btn" target="_blank" href="' + arr[i].submission_url + '">Submission</a>' +
'</div>'
} else {
str_6 += '<li><a href="' + arr[i].usx + '" target="_blank"><img src="' + imgjourUrl + arr[i].icon + '" alt=""></a><div>' +
// '<a target="_blank" href="/' + arr[i].usx + '">' + arr[i].title + '</a>' +
'<h2>Abstracting & Indexing</h2><p>' + list_href + '...</p>' +
'<p><b>Editor-in-Chief: </b>' + arr[i].editorinchief +
'<br/><b>Acceptance: </b>' + arr[i].acceptance +
'<br/><b>Final Decision: </b>' + arr[i].finaldecision +
'<br/><b>APC: </b>' + arr[i].apc +
'<br/><b>Frequency: </b>' + arr[i].cycle_ + '</p>' +
'<h2>Scope</h2><p>' + list_tio + '</p>' +
'<a class="wis_btn wis_btn_1" target="_blank" href="for_author.html?J_num=' + arr[i].journal_id + '">For Authors</a>' +
'<a class="wis_btn" target="_blank" href="' + arr[i].submission_url + '">Submission</a>' +
'</div>'
}
}
}
if (str_1 != '') {
str_1 = '<div><ul>' + str_1 + '</ul></div>'
}
if (str_2 != '') {
str_2 = '<div><ul>' + str_2 + '</ul></div>'
}
if (str_3 != '') {
str_3 = '<div><ul>' + str_3 + '</ul></div>'
}
if (str_4 != '') {
str_4 = '<div><ul>' + str_4 + '</ul></div>'
}
if (str_5 != '') {
str_5 = '<div><ul>' + str_5 + '</ul></div>'
}
if (str_6 != '') {
str_6 = '<div><ul>' + str_6 + '</ul></div>'
}
$('.atr_wisdom').html(str_1 + str_2 + str_3 + str_4 + str_5 + str_6);
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
} else {
// 搜索
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/findJournalTopic1',
data: {
'topic': wis_Dom
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.journals;
var str_1 = '';
var str_2 = '';
var str_3 = '';
var str_4 = '';
var str_5 = '';
var str_6 = '';
for (var i = 0; i < arr.length; i++) {
if (arr[i].title != 'tmRxiv') {
var list_tio = '' //话题
if (arr[i].topics == undefined) {
list_tio = '<a target="_blank" href="topic_list.html?J_num=' + arr[i].journal_id + '&t_id=' + arr[i].journal_topic_id + '">' + arr[i].topic_title + '</a>'
} else {
for (var j = 0; j < arr[i].topics.length; j++) {
if (j < arr[i].topics.length - 1) {
list_tio += '<a target="_blank" href="topic_list.html?J_num=' + arr[i].topics[j].journal_id + '&t_id=' + arr[i].topics[j].journal_topic_id + '">' + arr[i].topics[j].title + ',</a> '
} else {
list_tio += '<a target="_blank" href="topic_list.html?J_num=' + arr[i].topics[j].journal_id + '&t_id=' + arr[i].topics[j].journal_topic_id + '">' + arr[i].topics[j].title + '</a>'
}
}
}
var list_href = '' //外链
for (var p = 0; p < arr[i].abs.length; p++) {
if (p < arr[i].abs.length - 1) {
list_href += '<a target="_blank" href="' + arr[i].abs[p].url + '">' + arr[i].abs[p].title + ',</a> '
} else {
list_href += '<a target="_blank" href="' + arr[i].abs[p].url + '">' + arr[i].abs[p].title + '</a>'
}
}
if (i < 4) {
str_1 += '<li><img src="' + imgjourUrl + arr[i].icon + '" alt=""><div>' +
// '<a target="_blank" href="/' + arr[i].usx + '">' + arr[i].title + '</a>' +
'<h2>Abstracting & Indexing</h2><p>' + list_href + '...</p>' +
'<p><b>Editor-in-Chief: </b>' + arr[i].editorinchief +
'<br/><b>Acceptance: </b>' + arr[i].acceptance +
'<br/><b>Final Decision: </b>' + arr[i].finaldecision +
'<br/><b>APC: </b>' + arr[i].apc + '</p>' +
'<h2>Scope</h2><p>' + list_tio + '</p>' +
'<a class="wis_btn wis_btn_1" target="_blank" href="for_author.html?J_num=' + arr[i].journal_id + '">For Authors</a>' +
'<a class="wis_btn" target="_blank" href="' + arr[i].submission_url + '">Submission</a>' +
'</div>'
} else if (i < 8) {
str_2 += '<li><img src="' + imgjourUrl + arr[i].icon + '" alt=""><div>' +
// '<a target="_blank" href="/' + arr[i].usx + '">' + arr[i].title + '</a>' +
'<h2>Abstracting & Indexing</h2><p>' + list_href + '...</p>' +
'<p><b>Editor-in-Chief: </b>' + arr[i].editorinchief +
'<br/><b>Acceptance: </b>' + arr[i].acceptance +
'<br/><b>Final Decision: </b>' + arr[i].finaldecision +
'<br/><b>APC: </b>' + arr[i].apc + '</p>' +
'<h2>Scope</h2><p>' + list_tio + '</p>' +
'<a class="wis_btn wis_btn_1" target="_blank" href="for_author.html?J_num=' + arr[i].journal_id + '">For Authors</a>' +
'<a class="wis_btn" target="_blank" href="' + arr[i].submission_url + '">Submission</a>' +
'</div>'
} else if (i < 12) {
str_3 += '<li><img src="' + imgjourUrl + arr[i].icon + '" alt=""><div>' +
// '<a target="_blank" href="/' + arr[i].usx + '">' + arr[i].title + '</a>' +
'<h2>Abstracting & Indexing</h2><p>' + list_href + '...</p>' +
'<p><b>Editor-in-Chief: </b>' + arr[i].editorinchief +
'<br/><b>Acceptance: </b>' + arr[i].acceptance +
'<br/><b>Final Decision: </b>' + arr[i].finaldecision +
'<br/><b>APC: </b>' + arr[i].apc + '</p>' +
'<h2>Scope</h2><p>' + list_tio + '</p>' +
'<a class="wis_btn wis_btn_1" target="_blank" href="for_author.html?J_num=' + arr[i].journal_id + '">For Authors</a>' +
'<a class="wis_btn" target="_blank" href="' + arr[i].submission_url + '">Submission</a>' +
'</div>'
} else if (i < 16) {
str_4 += '<li><img src="' + imgjourUrl + arr[i].icon + '" alt=""><div>' +
// '<a target="_blank" href="/' + arr[i].usx + '">' + arr[i].title + '</a>' +
'<h2>Abstracting & Indexing</h2><p>' + list_href + '...</p>' +
'<p><b>Editor-in-Chief: </b>' + arr[i].editorinchief +
'<br/><b>Acceptance: </b>' + arr[i].acceptance +
'<br/><b>Final Decision: </b>' + arr[i].finaldecision +
'<br/><b>APC: </b>' + arr[i].apc + '</p>' +
'<h2>Scope</h2><p>' + list_tio + '</p>' +
'<a class="wis_btn wis_btn_1" target="_blank" href="for_author.html?J_num=' + arr[i].journal_id + '">For Authors</a>' +
'<a class="wis_btn" target="_blank" href="' + arr[i].submission_url + '">Submission</a>' +
'</div>'
} else if (i < 20) {
str_5 += '<li><img src="' + imgjourUrl + arr[i].icon + '" alt=""><div>' +
// '<a target="_blank" href="/' + arr[i].usx + '">' + arr[i].title + '</a>' +
'<h2>Abstracting & Indexing</h2><p>' + list_href + '...</p>' +
'<p><b>Editor-in-Chief: </b>' + arr[i].editorinchief +
'<br/><b>Acceptance: </b>' + arr[i].acceptance +
'<br/><b>Final Decision: </b>' + arr[i].finaldecision +
'<br/><b>APC: </b>' + arr[i].apc + '</p>' +
'<h2>Scope</h2><p>' + list_tio + '</p>' +
'<a class="wis_btn wis_btn_1" target="_blank" href="for_author.html?J_num=' + arr[i].journal_id + '">For Authors</a>' +
'<a class="wis_btn" target="_blank" href="' + arr[i].submission_url + '">Submission</a>' +
'</div>'
} else {
str_6 += '<li><img src="' + imgjourUrl + arr[i].icon + '" alt=""><div>' +
// '<a target="_blank" href="/' + arr[i].usx + '">' + arr[i].title + '</a>' +
'<h2>Abstracting & Indexing</h2><p>' + list_href + '...</p>' +
'<p><b>Editor-in-Chief: </b>' + arr[i].editorinchief +
'<br/><b>Acceptance: </b>' + arr[i].acceptance +
'<br/><b>Final Decision: </b>' + arr[i].finaldecision +
'<br/><b>APC: </b>' + arr[i].apc + '</p>' +
'<h2>Scope</h2><p>' + list_tio + '</p>' +
'<a class="wis_btn wis_btn_1" target="_blank" href="for_author.html?J_num=' + arr[i].journal_id + '">For Authors</a>' +
'<a class="wis_btn" target="_blank" href="' + arr[i].submission_url + '">Submission</a>' +
'</div>'
}
}
}
if (str_1 != '') {
str_1 = '<div><ul>' + str_1 + '</ul></div>'
}
if (str_2 != '') {
str_2 = '<div><ul>' + str_2 + '</ul></div>'
}
if (str_3 != '') {
str_3 = '<div><ul>' + str_3 + '</ul></div>'
}
if (str_4 != '') {
str_4 = '<div><ul>' + str_4 + '</ul></div>'
}
if (str_5 != '') {
str_5 = '<div><ul>' + str_5 + '</ul></div>'
}
if (str_6 != '') {
str_6 = '<div><ul>' + str_6 + '</ul></div>'
}
$('.atr_wisdom').html(str_1 + str_2 + str_3 + str_4 + str_5 + str_6);
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
//第三个输入框
$('.es_setext_btn').click(function () {
$('.es_setext_span').css('display', 'none')
if ($('#es_setext_input').val() == '') {
$('.es_setext_span').css('display', 'inline-block')
ShowDanger("Request was aborted");
} else {
window.open("ind_search.html?&set_text=" + $('#es_setext_input').val() + '&set_sel=' + $(".es_setext select[name=es_setext_in]").find("option:selected").val());
}
})
// Topic通用文章
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getAllTopics',
data: {},
beforeSend: function () {
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.topic;
// 话题搜索
var old_arry = result.data.topic;
new_arry = old_arry.map(o => {
return {id: o.base_topic_id, text: o.title}
})
for (var i = 0; i < old_arry.length; i++) {
new_arry[i].children = old_arry[i].children.map(o => {
return {id: o.base_topic_id, text: o.title}
})
}
$('#com_index').selectivity({
allowClear: true,
items: new_arry,
placeholder: 'Please select a topic'
})
$('.es_serch_btn').click(function () {
$('.es_serch_span').css('display', 'none')
if ($('#com_index').selectivity('val') == null) {
$('.es_serch_span').css('display', 'inline')
$('.es_serch_span').text('Please select a topic')
ShowDanger("Request was aborted");
} else {
window.open("atr_wisdom.html?&wis_dom=" + $('#com_index').selectivity('val'));
}
})
// 话题订阅
var data_de = [];
for (var i = 0; i < arr.length; i++) {
data_de.push({
id: arr[i].base_topic_id,
text: arr[i].title
});
}
$('#combox_box').selectivity({
allowClear: true,
items: data_de,
placeholder: 'Please choose topic'
})
// 订阅提交
$(".yue_de").click(function () {
$(".spa").text('');
var add_mess = {};
add_mess.email = $('#emapl_de').val();
add_mess.base_topic_id = $('#combox_box').selectivity('val');
var S_Dan = '0';
var reg = /^[-.-_A-Za-z0-9]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/
if ($('#combox_box').selectivity('val') == null) {
$(".spa_de").text('Please choose topic');
S_Dan = '1';
} else if ($("#emapl_de").val() == "") {
$(".spa_de").text('Please fill in E-mail');
S_Dan = '1';
} else if (!(reg.test($("#emapl_de").val()))) {
$(".spa_de").text('Please fill in properly formatted E-mail');
S_Dan = '1';
}
if (S_Dan == '1') {
ShowDanger("Incomplete information");
} else {
$(".yue_de").addClass("disable");
$.ajax({
type: 'post', url: apiUrl + 'subscribe/Journal/addSubscribeBaseTopic',
data: add_mess,
success: function (result) {
if (result.code == 0) {
$(".ding_yue input[type='text']").val('');
$(".yue_de").removeClass("disable");
$(".jour_ts").fadeIn();
$(".jour_ts .mainbox input[type='submit']").css('background-color', '#006699')
$(".jour_ts input.tishi_author").click(function () {
$(".jour_ts").fadeOut();
});
} else {
ShowDanger(result.msg);
$(".yue_de").removeClass("disable");
}
},
error: function () {
ShowDanger("error");
$(".yue_de").removeClass("disable");
}
})
}
})
} else {
ShowDanger("请求失败!");
}
}
})
}
// 审稿人、编委、作者、读者
function rev_ver() {
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getJournalList',
data: {},
beforeSend: function () {
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.journalList;
var journal_data = [];
// 第一个ul
var str = ''
for (var i = 0; i < arr.length; i++) {
str += '<li><a href="https://submission.tmrjournals.com/reviewer" target="_blank">' + arr[i].title + '</a></li>'
}
$('#feng_sipder ul').html(str)
//for (var i = 0; i < arr.length; i++) {
// str += '<div class="swiper-slide"><a href="https://submission.tmrjournals.com/reviewer" target="_blank">' +
// '<img src="' + imgjourUrl + arr[i].icon + '" alt="" style="width:160px;height: 210px"></a></div>'
//}
//$('#feng_sipder .swiper-wrapper').html(str)
//new Swiper('#feng_sipder .swiper-container', {
// direction: 'horizontal', //默认horizontal, 水平轮播
// autoplay: false, //自动切换
// loop: true, //循环
// slidesPerView: "5", //默认1, 同时显示的slides数量,auto 代表根据轮播图的宽度排列
// spaceBetween: 1, //轮播图之间的间距
// // 如果需要前进后退按钮
// navigation: {
// nextEl: '#feng_sipder .swiper-button-next',
// prevEl: '#feng_sipder .swiper-button-prev',
// },
//})
// 第二个ul
var tgy = ''
for (var i = 0; i < arr.length; i++) {
tgy += '<div class="swiper-slide"><a href="z_f6-1.html?J_num=' + arr[i].journal_id + '" target="_blank">' +
'<img src="' + imgjourUrl + arr[i].icon + '" alt="" style="width:160px;height: 210px"></a></div>'
}
$('#ying_sipder .swiper-wrapper').html(tgy)
//期刊轮播
new Swiper('#ying_sipder .swiper-container', {
direction: 'horizontal', //默认horizontal, 水平轮播
autoplay: false, //自动切换
loop: true, //循环
slidesPerGroup: 6, // 多少列为一组
slidesPerView: "6", //默认1, 同时显示的slides数量,auto 代表根据轮播图的宽度排列
observer: true,//修改swiper自己或子元素时自动初始化swiper
observeParents: true,//修改swiper的父元素时自动初始化swiper
spaceBetween: 1, //轮播图之间的间距
// 如果需要前进后退按钮
navigation: {
nextEl: '#ying_sipder .swiper-button-next',
prevEl: '#ying_sipder .swiper-button-prev',
},
})
// 第二个下拉
for (var i = 0; i < arr.length; i++) {
if (arr[i].title != 'tmRxiv') {
journal_data.push({
id: arr[i].journal_id,
text: arr[i].title
});
}
}
$('#select_jour').selectivity({
allowClear: true,
items: journal_data,
placeholder: 'Please choose journal'
})
$('.se_jour_btn').click(function () {
$('.se_jour_span').css('display', 'none')
if ($('#select_jour').selectivity('val') == null) {
$('.se_jour_span').css('display', 'inline')
ShowDanger("Request was aborted");
} else {
window.open("guest.html?J_num=" + $('#select_jour').selectivity('val'));
}
})
// 第三个下拉
for (var i = 0; i < arr.length; i++) {
if (arr[i].title != 'tmRxiv') {
journal_data.push({
id: arr[i].journal_id,
text: arr[i].title
});
}
}
$('#select_box').selectivity({
allowClear: true,
items: journal_data,
placeholder: 'Please choose journal'
})
$('.se_slct_btn').click(function () {
$('.se_select_span').css('display', 'none')
if ($('#select_box').selectivity('val') == null) {
$('.se_select_span').css('display', 'inline')
ShowDanger("Request was aborted");
} else {
window.open("gue_edit.html?J_num=" + $('#select_box').selectivity('val'));
}
})
} else {
ShowDanger("请求失败!");
}
}
})
// 第一个下拉
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getAllTopics',
data: {},
beforeSend: function () {
},
success: function (result) {
if (result.code == 0) {
var old_arry = result.data.topic;
var new_arry = result.data.topic;
new_arry = old_arry.map(o => {
return {id: o.base_topic_id, text: o.title}
})
for (var i = 0; i < old_arry.length; i++) {
new_arry[i].children = old_arry[i].children.map(o => {
return {id: o.base_topic_id, text: o.title}
})
}
$('#com_index').selectivity({
allowClear: true,
items: new_arry,
placeholder: 'Please select a topic'
})
$('.es_serch_btn').click(function () {
$('.es_serch_span').css('display', 'none')
if ($('#com_index').selectivity('val') == null) {
$('.es_serch_span').css('display', 'inline')
ShowDanger("Request was aborted");
} else {
window.open("atr_wisdom.html?&wis_dom=" + $('#com_index').selectivity('val'));
}
})
} else {
ShowDanger("请求失败!");
}
}
})
//第三个输入框
$('.es_setext_btn').click(function () {
$('.es_setext_span').css('display', 'none')
if ($('#es_setext_input').val() == '') {
$('.es_setext_span').css('display', 'inline-block')
ShowDanger("Request was aborted");
} else {
window.open("ind_search.html?&set_text=" + $('#es_setext_input').val() + '&set_sel=' + $(".es_setext select[name=es_setext_in]").find("option:selected").val());
}
})
// Topic通用文章
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getAllTopics',
data: {},
beforeSend: function () {
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.topic;
var str = '';
for (var i = 0; i < arr.length; i++) {
str += '<li><a href="artihom_list.html?J_num=1&base_id=' + arr[i].base_topic_id
+ '" target="_blank"><img src="' + imgbaseUrl + arr[i].icon + '"><h3>' +
arr[i].title + '</h3></a></li>'
}
$(".cur_rency ul").html(str + '<br clear="both"/>');
// 话题订阅
var data_de = [];
for (var i = 0; i < arr.length; i++) {
data_de.push({
id: arr[i].base_topic_id,
text: arr[i].title
});
}
$('#combox_box').selectivity({
allowClear: true,
items: data_de,
placeholder: 'Please choose topic'
})
// 订阅提交
$(".yue_de").click(function () {
$(".spa").text('');
var add_mess = {};
add_mess.email = $('#emapl_de').val();
add_mess.base_topic_id = $('#combox_box').selectivity('val');
var S_Dan = '0';
var reg = /^[-.-_A-Za-z0-9]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/
if ($('#combox_box').selectivity('val') == null) {
$(".spa_de").text('Please choose topic');
S_Dan = '1';
} else if ($("#emapl_de").val() == "") {
$(".spa_de").text('Please fill in E-mail');
S_Dan = '1';
} else if (!(reg.test($("#emapl_de").val()))) {
$(".spa_de").text('Please fill in properly formatted E-mail');
S_Dan = '1';
}
if (S_Dan == '1') {
ShowDanger("Incomplete information");
} else {
$(".yue_de").addClass("disable");
$.ajax({
type: 'post', url: apiUrl + 'subscribe/Journal/addSubscribeBaseTopic',
data: add_mess,
success: function (result) {
if (result.code == 0) {
$(".ding_yue input[type='text']").val('');
$(".yue_de").removeClass("disable");
$(".jour_ts").fadeIn();
$(".jour_ts .mainbox input[type='submit']").css('background-color', '#006699')
$(".jour_ts input.tishi_author").click(function () {
$(".jour_ts").fadeOut();
});
} else {
ShowDanger(result.msg);
$(".yue_de").removeClass("disable");
}
},
error: function () {
ShowDanger("error");
$(".yue_de").removeClass("disable");
}
})
}
})
} else {
ShowDanger("请求失败!");
}
}
})
// Top cited / Top read / Top download文章
$.ajax({
type: 'post', url: apiUrl + 'api/Main/getThireTopArticles',
data: {
"type": 'read',
"pageIndex": '1',
"pageSize": '4'
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.articles;
var str = "";
var j = 0;
for (var i = 0; i < arr.length; i++) {
if (j == 4) break;
if (arr[i].icon == '') {
var img_i = 'img/baiss.png'
} else {
var img_i = imgarticleUrl + arr[i].icon
}
str += '<li><a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '"><img src="' + img_i + '" alt=""></a>' +
'<h6><a target="_blank" href="article.html?J_num=' + arr[i].journal_id + '&a_id=' + arr[i].article_id + '">' + arr[i].title + '</a></h6>' +
'<div>' + arr[i].abbr + ' | ' + arr[i].stage_year + ' | <span><a style="color: #006699" target="_blank" href="/' + arr[i].usx + '">' + arr[i].journal_short + '</a><span></div></li>'
j += 1;
}
$('.sy_tcrd>div>a').attr('href', 'artihom_list.html?J_num=1&read_id=1');
$('.sy_tcrd>div>ul').html(str + '<br clear="both">');
} else {
// ShowDanger("请求失败!");
$('.sy_tcrd').css('display', 'none')
}
},
error: function () {
ShowDanger("error");
}
})
//专刊列表
$.ajax({
type: 'post', url: apiUrl + 'api/Special/getAllSpecials',
data: {},
success: function (result) {
if (result.code == 0) {
var arr = result.data.specials;
var str = "";
for (var i = 0; i < 3; i++) {
if ($.cookie("username") != undefined && $.cookie("user_id") != undefined) {
var co_sp_user = 'contribu_list.html?J_num=' + arr[i].journal_id + '&&special_id=' + arr[i].journal_special_id;
} else {
var co_sp_user = 'contribu_login.html?J_num=' + arr[i].journal_id + '&&special_id=' + arr[i].journal_special_id;
}
str += '<li><p>' + arr[i].journaltitle + '</p><a href="/' + arr[i].usx + '" target="_blank">' +
'<img src="' + imgjourUrl + arr[i].icon + '"></a>' +
'<div><a href="gue_cont.html?J_num=' + arr[i].journal_id + '&&Gu_num=' + arr[i].journal_special_id + '" target="_blank">' + arr[i].title + '</a>' +
'<span><font style="color: #006699;margin-right: 5px">Guest Editor:</font>' + arr[i].editor + '</span>' +
'<span><font style="color: #006699;margin-right: 5px">Deadline:</font>' + arr[i].deadline + '</span>' +
'<div class="iss_abs"><span><font style="color: #006699;margin-right: 5px">Special Issue Information:</font></span><b>' + arr[i].abstract + '</b></div>' +
'<div class="gue_s_btn"><a href="gue_cont_gea.html?J_num=' + arr[i].journal_id + '&&Gu_num=' + arr[i].journal_special_id + '" class="gue_appli" target="_blank">Guest Editor Application</a>' +
'<a href="' + co_sp_user + '" class="gue_submin" target="_blank">Submit Article</a>' +
'</div></div><br clear="both"></li>'
}
$('.reth_ff>h3>a').attr('href', 'artihom_list.html?J_num=1&issu_id=1');
$('.reth_ff>ul.sy_spls_list').html(str);
$(".reth_ff .sy_spls_list li>div .iss_abs>b").each(function () {
var maxwidth = 400;//显示多少字符
if ($(this).text().length > maxwidth) {
$(this).text($(this).text().substring(0, maxwidth));
$(this).text($(this).text().substring(0, maxwidth - $(this).text().split(" ").pop().length));
$(this).html($(this).html() + '...');
}
});
} else {
// ShowDanger("请求失败!");
$('.sy_splis').css('display', 'none')
}
},
error: function () {
ShowDanger("error");
}
})
//待审稿件列表
$.ajax({
type: 'post', url: apiUrl + 'special/Article/getReviewerArticles',
data: {},
success: function (result) {
if (result.code == 0) {
var arr = result.data.articles;
var str = '';
for (var i = 0; i < 3; i++) {
str += '<li><a target="_blank" href="https://submission.tmrjournals.com/peerewer">' + arr[i].title + '</a>' +
'<font style="color: #006699">Journal: </font>' + arr[i].journalname +
'<font style="color: #006699;margin-left: 50px">Type: </font>' + pan_type(arr[i].type) + '</li>'
}
$('.reth_aa .rese_awaite').html(str);
$('.reth_aa .rese_awaite_more').attr('href', 'artihom_list.html?J_num=1&waite_id=1');
if (str == '') {
$('.reth_aa .rese_awaite').css('display', 'none');
}
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// 底栏政策
function afooter_content() {
// 获取地址栏信息
function getQueryString(name) {
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
var r = window.location.search.substr(1).match(reg);
if (r != null) return unescape(r[2]);
return null;
}
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getFooterAtrNew',
data: {
footer_id: getQueryString('footer_id')
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.footer;
$('.new_art>h4').html(arr.footer_title);
$('.new_art>div').html(arr.content);
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}
// 底栏政策锚点部分
function afooter_text() { // 获取地址栏信息
function getQueryString(name) {
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
var r = window.location.search.substr(1).match(reg);
if (r != null) return unescape(r[2]);
return null;
}
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getAllFooter',
data: {},
success: function (result) {
if (result.code == 0) {
var arr = result.data.footers;
var str = "";
var claSty = "";
for (var i in arr) {
if (i == 'Guidelines') {
str += '<ul><h3>' + i + '</h3>'
for (var j = 0; j < arr[i].length; j++) {
if (arr[i][j].footer_id == getQueryString('footer_id')) {
claSty = " class='leli_chlik'"
} else {
claSty = ""
}
str += '<li' + claSty + ' id="' + arr[i][j].footer_id + '"><i></i><a>' + arr[i][j].footer_title + '</a></li>'
}
str += '</ul>'
} else if (i == 'Publisher Information') {
str += '<ul><h3>' + i + '</h3>'
for (var j = 0; j < arr[i].length; j++) {
if (arr[i][j].footer_id == getQueryString('footer_id')) {
claSty = " class='leli_chlik'"
} else {
claSty = ""
}
str += '<li' + claSty + ' id="' + arr[i][j].footer_id + '"><i></i><a>' + arr[i][j].footer_title + '</a></li>'
}
}
}
$('.legal_list').html(str);
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getFooterAtrNew',
data: {
footer_id: getQueryString('footer_id')
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.footer;
$('.legal_art>h4').html(arr.footer_title);
$('.legal_art>div').html(arr.content);
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
$('.legal_list ul li').click(function () {
$('.legal_list ul').find(".leli_chlik").removeClass("leli_chlik")
$(this).addClass("leli_chlik")
$.ajax({
type: 'post', url: apiUrl + 'api/Journal/getFooterAtrNew',
data: {
footer_id: this.id
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.footer;
$('.legal_art>h4').html(arr.footer_title);
$('.legal_art>div').html(arr.content);
} else {
ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
})
} else {
// ShowDanger("请求失败!");
}
},
error: function () {
ShowDanger("error");
}
})
}