提交 has
This commit is contained in:
@@ -31,7 +31,7 @@ function commonInit() {
|
||||
|
||||
|
||||
}
|
||||
function commonGetItemHtml(doc) {
|
||||
function commonGetItemHtml(doc,maxwidth) {
|
||||
|
||||
var data = doc.data;
|
||||
var i = doc.i;
|
||||
@@ -54,23 +54,33 @@ function commonGetItemHtml(doc) {
|
||||
pdf_: !data.file_pdf || data.file_pdf == '' ? '' : `<img src="img/link_3.jpg" width="14" height="16"><a href="${imgFileUrl}articlePDF/${data.file_pdf}" target="_blank" class="txt_pdf" alt="${data.article_id}">PDF</a> ( <span style="color: red">${data.pdf_num}</span> )`,
|
||||
cite_: !data.cite_num || data.cite_num == 0 ? '' :
|
||||
` <span article_id="${data.article_id}" class="cite_box" style="color: #7a2702;">
|
||||
<img src="img/link_6.jpg" width="14" height="16">
|
||||
WOS Citations ( <span style="color: red">${data.cite_num}</span> )
|
||||
<ul class="export_cite "> </ul>
|
||||
</span>`,
|
||||
<img src="img/link_6.jpg" width="14" height="16">
|
||||
WOS Citations ( <span style="color: red">${data.cite_num}</span> )
|
||||
<ul class="export_cite "> </ul>
|
||||
</span>`,
|
||||
abstract: data.abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153"),
|
||||
link_: '',
|
||||
stage_: '',
|
||||
}
|
||||
if (data.mains == '') {
|
||||
|
||||
if (data.has_mains == 0) {
|
||||
if (data.file_html == '') {
|
||||
baseInfo.html_ = ''
|
||||
} else {
|
||||
baseInfo.html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + data.file_html + '" target="_blank" class="txt_html" alt="' + data.article_id + '">HTML</a> ( <span style="color: red">' + data.html_num + '</span> ) '
|
||||
baseInfo.html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + data.file_html + '" target="_blank" class="txt_html" alt="' + data.article_id + '">HTML</a>   '
|
||||
}
|
||||
} else {
|
||||
baseInfo.html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + data.article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + data.article_id + '">HTML</a> ( <span style="color: red">' + data.html_num + '</span> ) '
|
||||
baseInfo.html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + data.article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + data.article_id + '">HTML</a>   '
|
||||
}
|
||||
// if (data.mains == '') {
|
||||
// if (data.file_html == '') {
|
||||
// baseInfo.html_ = ''
|
||||
// } else {
|
||||
// baseInfo.html_ = '<img src="img/link_2.png" width="14" height="16"><a href="' + imgFileUrl + 'articleHTML/' + data.file_html + '" target="_blank" class="txt_html" alt="' + data.article_id + '">HTML</a> ( <span style="color: red">' + data.html_num + '</span> ) '
|
||||
// }
|
||||
// } else {
|
||||
// baseInfo.html_ = '<img src="img/link_2.png" width="14" height="16"><a href="article.html?J_num=' + Jour_num + '&a_id=' + data.article_id + '&s_htm=1" target="_blank" class="txt_html" alt="' + data.article_id + '">HTML</a> ( <span style="color: red">' + data.html_num + '</span> ) '
|
||||
// }
|
||||
|
||||
|
||||
if (data.stage_no == '0') {
|
||||
@@ -114,7 +124,7 @@ function commonGetItemHtml(doc) {
|
||||
|
||||
|
||||
if (data.tradition_tag == '' || data.tradition_tag == null) {
|
||||
var maxwidth = 800;//显示多少字符
|
||||
var maxwidth = maxwidth?maxwidth:800;//显示多少字符
|
||||
if (data.abstract.length > maxwidth) {
|
||||
var abstNew = data.abstract.replace(/<.*?>/ig, "")
|
||||
abstNew = abstNew.substring(0, maxwidth)
|
||||
|
||||
136
js/scientist/scientist_baseid.js
Normal file
136
js/scientist/scientist_baseid.js
Normal file
@@ -0,0 +1,136 @@
|
||||
function initBaseid() {
|
||||
// 通用话题点进去的文章列表
|
||||
var base_ID = getQueryString('base_id'); //
|
||||
// 通用话题点进去的文章列表
|
||||
if (base_ID != null) {
|
||||
var urlList = {
|
||||
list: 'api/Journal/getBaseTopicArticles'
|
||||
}
|
||||
|
||||
commonInit()
|
||||
var base_topic = {};
|
||||
base_topic.pageIndex = 1;
|
||||
base_topic.pageSize = 10;
|
||||
base_topic.base_topic_id = base_ID;
|
||||
var totalPage;//总页码
|
||||
var totalRecords;//总数据条数
|
||||
var pageNo = base_topic.pageIndex;//当前页码
|
||||
$.ajax({
|
||||
type: 'post', url: apiUrl + urlList.list,
|
||||
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);
|
||||
|
||||
|
||||
initArticle(result.data.articleList)
|
||||
//生成分页
|
||||
//有些参数是可选的,比如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 + urlList.list,
|
||||
data: base_topic,
|
||||
success: function (result) {
|
||||
if (result.code == 0) {
|
||||
$('.goup-container').click();
|
||||
totalRecords = result.data.count;
|
||||
$('.wenz_list .tioashu').html(result.data.count);
|
||||
|
||||
$('.wenz_list>h4').html(result.data.topic.title);
|
||||
initArticle(result.data.articleList)
|
||||
|
||||
} 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 ',
|
||||
currPageAfterText: '',
|
||||
totalInfoSplitStr: ' of ',
|
||||
totalRecordsBeforeText: '',
|
||||
totalRecordsAfterText: '',
|
||||
gopageBeforeText: ' Go to page',
|
||||
gopageButtonOkText: 'Go',
|
||||
gopageAfterText: 'page',
|
||||
buttonTipBeforeText: '第',
|
||||
buttonTipAfterText: '页'
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
} else {
|
||||
ShowDanger("请求失败!");
|
||||
}
|
||||
},
|
||||
error: function () {
|
||||
ShowDanger("error!");
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
function initArticle(arr) {
|
||||
var str = "";
|
||||
for (var i = 0; i < arr.length; i++) {
|
||||
if (arr[i].icon == '') {
|
||||
continue
|
||||
}
|
||||
if (arr[i].icon == '') {
|
||||
var img_i = 'img/baiss.png'
|
||||
} else {
|
||||
var img_i = imgarticleUrl + arr[i].icon
|
||||
}
|
||||
var baseInfo = commonGetItemHtml({ data: arr[i], i: i, img_i: img_i, c_t_a: '' })
|
||||
str += `
|
||||
|
||||
<li>
|
||||
<div class="dbt_header">${arr[i].type}${baseInfo.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">${baseInfo.otStat}${arr[i].title}</a>
|
||||
<div class="authorList">${arr[i].authortitle}<br>
|
||||
|
||||
<a href="/${arr[i].usx}" target="_blank" > ${arr[i].journal_title}</a>. ${arr[i].stage_year}, ${arr[i].stage_vol}${baseInfo.stage_}${baseInfo.npp_}<a
|
||||
target="_blank" href="https://doi.org/${arr[i].doi}">${baseInfo.doi_}</a>
|
||||
</div>
|
||||
<div class="links_">${baseInfo.link_}</div>
|
||||
<div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">${baseInfo.person_img}</a>${baseInfo.trad_tion}<br
|
||||
clear="both"></div>
|
||||
</li>
|
||||
|
||||
`
|
||||
}
|
||||
$('.wenz_list>ul').html(str);
|
||||
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
|
||||
commonHandleClickHtml()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
function initCite() {
|
||||
var cite_ID = getQueryString('cite_id'); //Top cited
|
||||
localStorage.setItem("Journals_color", '#006699');
|
||||
|
||||
|
||||
// Top cited点进去的文章列表
|
||||
if (cite_ID != null) {
|
||||
@@ -9,6 +9,7 @@ function initCite() {
|
||||
}
|
||||
// cited
|
||||
commonInit()
|
||||
|
||||
var cited_tcp = {};
|
||||
cited_tcp.page = 1;
|
||||
cited_tcp.limit = 10;
|
||||
@@ -16,7 +17,7 @@ function initCite() {
|
||||
|
||||
var totalPage;//总页码
|
||||
var totalRecords;//总数据条数
|
||||
var pageNo = cited_tcp.page;//当前页码
|
||||
var pageNo = cited_tcp.pageIndex;//当前页码
|
||||
|
||||
$.ajax({
|
||||
type: 'post', url: apiUrl + urlList.list,
|
||||
@@ -28,13 +29,8 @@ function initCite() {
|
||||
totalRecords = result.data.count;
|
||||
$('.wenz_list .tioashu').html(result.data.count);
|
||||
|
||||
|
||||
initArticle(result.data.list)
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
//生成分页
|
||||
//有些参数是可选的,比如lang,若不传有默认值
|
||||
kkpager.generPageHtml({
|
||||
@@ -132,17 +128,17 @@ function initCite() {
|
||||
str += `
|
||||
|
||||
<li>
|
||||
<div class="dbt_header">${arr[i].type}${baseInfo.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">${baseInfo.otStat}${arr[i].title}</a>
|
||||
<div class="authorList">${arr[i].authortitle}<br>
|
||||
${arr[i].journal_title}. ${arr[i].stage_year}, ${arr[i].stage_vol}${baseInfo.stage_}${baseInfo.npp_}<a
|
||||
target="_blank" href="https://doi.org/${arr[i].doi}">${baseInfo.doi_}</a>
|
||||
</div>
|
||||
<div class="links_">${baseInfo.link_}</div>
|
||||
<div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">${baseInfo.person_img}</a>${baseInfo.trad_tion}<br
|
||||
clear="both"></div>
|
||||
</li>
|
||||
<div class="dbt_header">${arr[i].type}${baseInfo.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">${baseInfo.otStat}${arr[i].title}</a>
|
||||
<div class="authorList">${arr[i].authortitle}<br>
|
||||
${arr[i].journal_title}. ${arr[i].stage_year}, ${arr[i].stage_vol}${baseInfo.stage_}${baseInfo.npp_}<a
|
||||
target="_blank" href="https://doi.org/${arr[i].doi}">${baseInfo.doi_}</a>
|
||||
</div>
|
||||
<div class="links_">${baseInfo.link_}</div>
|
||||
<div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">${baseInfo.person_img}</a>${baseInfo.trad_tion}<br
|
||||
clear="both"></div>
|
||||
</li>
|
||||
|
||||
`
|
||||
}
|
||||
|
||||
63
js/scientist/scientist_conid.js
Normal file
63
js/scientist/scientist_conid.js
Normal file
@@ -0,0 +1,63 @@
|
||||
function initConid() {
|
||||
// Comment点进去的文章列表
|
||||
var con_ID = getQueryString('con_id');
|
||||
|
||||
|
||||
// Top cited点进去的文章列表
|
||||
if (con_ID != null) {
|
||||
var urlList = {
|
||||
list: 'api/Main/getNewsArticles'
|
||||
}
|
||||
|
||||
$.ajax({
|
||||
type: 'post', url: apiUrl + urlList.list,
|
||||
data: { "type": 'Comment' },
|
||||
success: function (result) {
|
||||
if (result.code == 0) {
|
||||
$('.wenz_list>h4').html('Comment');
|
||||
initArticle(result.data.articles)
|
||||
} else {
|
||||
ShowDanger("请求失败!");
|
||||
}
|
||||
},
|
||||
error: function () {
|
||||
ShowDanger("error!");
|
||||
}
|
||||
})
|
||||
|
||||
function initArticle(arr) {
|
||||
var str = "";
|
||||
for (var i = 0; i < arr.length; i++) {
|
||||
if (arr[i].icon == '') {
|
||||
continue
|
||||
}
|
||||
|
||||
if (arr[i].icon == '') {
|
||||
var img_i = 'img/baiss.png'
|
||||
} else {
|
||||
var img_i = imgarticleUrl + arr[i].icon
|
||||
}
|
||||
var baseInfo = commonGetItemHtml({ data: arr[i], i: i, img_i: img_i, c_t_a: '' },500)
|
||||
var lr_top = ''
|
||||
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">${baseInfo.otStat}${arr[i].title}</a>
|
||||
<div class="authorList">${arr[i].authortitle}<br>
|
||||
${arr[i].journal_title}. ${arr[i].stage_year}, ${arr[i].stage_vol}${baseInfo.stage_}${baseInfo.npp_}<a
|
||||
target="_blank" href="https://doi.org/${arr[i].doi}">${baseInfo.doi_}</a>
|
||||
</div>
|
||||
<div class="links_">${baseInfo.link_}</div>
|
||||
<div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">${baseInfo.person_img}</a>${baseInfo.trad_tion}<br
|
||||
clear="both"></div>
|
||||
</li>
|
||||
`
|
||||
}
|
||||
$('.wenz_list>ul').html(str);
|
||||
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
|
||||
commonHandleClickHtml()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
136
js/scientist/scientist_downid.js
Normal file
136
js/scientist/scientist_downid.js
Normal file
@@ -0,0 +1,136 @@
|
||||
function initDownid() {
|
||||
// Top download点进去的文章列表
|
||||
var down_ID = getQueryString('down_id'); //Top download
|
||||
|
||||
if (down_ID != null) {
|
||||
var urlList = {
|
||||
list: 'api/Main/getThireTopArticles'
|
||||
}
|
||||
|
||||
commonInit()
|
||||
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 + urlList.list,
|
||||
data: down_tcp,
|
||||
success: function (result) {
|
||||
if (result.code == 0) {
|
||||
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);
|
||||
|
||||
$('.wenz_list>h4').html('Top download');
|
||||
|
||||
|
||||
initArticle(result.data.articles)
|
||||
//生成分页
|
||||
//有些参数是可选的,比如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 + urlList.list,
|
||||
data: down_tcp,
|
||||
success: function (result) {
|
||||
if (result.code == 0) {
|
||||
$('.goup-container').click();
|
||||
totalRecords = result.data.count;
|
||||
$('.wenz_list .tioashu').html(result.data.count);
|
||||
|
||||
$('.wenz_list>h4').html('Top read');
|
||||
initArticle(result.data.articles)
|
||||
|
||||
} 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 ',
|
||||
currPageAfterText: '',
|
||||
totalInfoSplitStr: ' of ',
|
||||
totalRecordsBeforeText: '',
|
||||
totalRecordsAfterText: '',
|
||||
gopageBeforeText: ' Go to page',
|
||||
gopageButtonOkText: 'Go',
|
||||
gopageAfterText: 'page',
|
||||
buttonTipBeforeText: '第',
|
||||
buttonTipAfterText: '页'
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
} else {
|
||||
ShowDanger("请求失败!");
|
||||
}
|
||||
},
|
||||
error: function () {
|
||||
ShowDanger("error!");
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
function initArticle(arr) {
|
||||
var str = "";
|
||||
for (var i = 0; i < arr.length; i++) {
|
||||
if (arr[i].icon == '') {
|
||||
continue
|
||||
}
|
||||
if (arr[i].icon == '') {
|
||||
var img_i = 'img/baiss.png'
|
||||
} else {
|
||||
var img_i = imgarticleUrl + arr[i].icon
|
||||
}
|
||||
var baseInfo = commonGetItemHtml({ data: arr[i], i: i, img_i: img_i, c_t_a: '' })
|
||||
str += `
|
||||
|
||||
<li>
|
||||
<div class="dbt_header">${arr[i].type}${baseInfo.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">${baseInfo.otStat}${arr[i].title}</a>
|
||||
<div class="authorList">${arr[i].authortitle}<br>
|
||||
|
||||
<a href="/${arr[i].usx}" target="_blank" > ${arr[i].journal_title}</a>. ${arr[i].stage_year}, ${arr[i].stage_vol}${baseInfo.stage_}${baseInfo.npp_}<a
|
||||
target="_blank" href="https://doi.org/${arr[i].doi}">${baseInfo.doi_}</a>
|
||||
</div>
|
||||
<div class="links_">${baseInfo.link_}</div>
|
||||
<div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">${baseInfo.person_img}</a>${baseInfo.trad_tion}<br
|
||||
clear="both"></div>
|
||||
</li>
|
||||
|
||||
`
|
||||
}
|
||||
$('.wenz_list>ul').html(str);
|
||||
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
|
||||
commonHandleClickHtml()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
76
js/scientist/scientist_newid.js
Normal file
76
js/scientist/scientist_newid.js
Normal file
@@ -0,0 +1,76 @@
|
||||
function initNewid() {
|
||||
// News点进去的文章列表
|
||||
var new_ID = getQueryString('new_id'); //News
|
||||
|
||||
|
||||
|
||||
|
||||
// Top cited点进去的文章列表
|
||||
if (new_ID != null) {
|
||||
localStorage.setItem("Journals_num", new_ID);
|
||||
$('.art_side').css('display', 'none');
|
||||
$('.art_main_con').css('width', '1070px');
|
||||
$('.new_art > h4').css('padding', ' 0 4px 16px 6px');
|
||||
var urlList = {
|
||||
list: 'api/Journal/getNewsArticle'
|
||||
}
|
||||
|
||||
$.ajax({
|
||||
type: 'post', url: apiUrl + urlList.list,
|
||||
data: { "journal_id": new_ID },
|
||||
success: function (result) {
|
||||
if (result.code == 0) {
|
||||
if (Jour_num == 1) {
|
||||
$('.wenz_list>h4').after('<p style="margin-bottom: 15px;padding: 10px 20px;background-color: #fff">News should focus on policy, science and society or purely scientific issues related to traditional medicine around the world. They should be of immediate interest to a broad readership and should be written in an accessible, non-technical style. Figures and diagrams are encouraged, but are not a requirement. News articles are not peer-reviewed, but undergo editing after consultation with the author.</p>');
|
||||
}
|
||||
$('.wenz_list>h4').html('News');
|
||||
initArticle(result.data.articlelist)
|
||||
} else {
|
||||
ShowDanger("请求失败!");
|
||||
}
|
||||
},
|
||||
error: function () {
|
||||
ShowDanger("error!");
|
||||
}
|
||||
})
|
||||
|
||||
function initArticle(arr) {
|
||||
var str = "";
|
||||
for (var i = 0; i < arr.length; i++) {
|
||||
if (arr[i].icon == '') {
|
||||
continue
|
||||
}
|
||||
|
||||
if (arr[i].icon == '') {
|
||||
var img_i = 'img/baiss.png'
|
||||
} else {
|
||||
var img_i = imgarticleUrl + arr[i].icon
|
||||
}
|
||||
var baseInfo = commonGetItemHtml({ data: arr[i], i: i, img_i: img_i, c_t_a: '' })
|
||||
var lr_top = ''
|
||||
|
||||
if (arr[i].type == 'News') {
|
||||
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">${baseInfo.otStat}${arr[i].title}</a>
|
||||
<div class="authorList">${arr[i].authortitle}<br>
|
||||
${arr[i].journal_title}. ${arr[i].stage_year}, ${arr[i].stage_vol}${baseInfo.stage_}${baseInfo.npp_}<a
|
||||
target="_blank" href="https://doi.org/${arr[i].doi}">${baseInfo.doi_}</a>
|
||||
</div>
|
||||
<div class="links_">${baseInfo.link_}</div>
|
||||
<div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">${baseInfo.person_img}</a>
|
||||
<div><h3>${arr[i].tradition_tag} </h3><p>
|
||||
${baseInfo.trad_tion}</p></div><br clear="both"></div>
|
||||
</li>
|
||||
`
|
||||
}
|
||||
}
|
||||
$('.wenz_list>ul').html(str);
|
||||
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
|
||||
commonHandleClickHtml()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
130
js/scientist/scientist_oid.js
Normal file
130
js/scientist/scientist_oid.js
Normal file
@@ -0,0 +1,130 @@
|
||||
function initOid() {
|
||||
var o_ID = getQueryString('o_id'); //Online First
|
||||
// Online First点进去的文章列表
|
||||
if (o_ID != null) {
|
||||
var urlList = {
|
||||
list: 'api/Main/getOnlineFirstArticles'
|
||||
}
|
||||
|
||||
commonInit()
|
||||
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 + urlList.list,
|
||||
data: online_first,
|
||||
success: function (result) {
|
||||
if (result.code == 0) {
|
||||
$('.wenz_list>h4').html('Online First');
|
||||
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);
|
||||
initArticle(result.data.articles)
|
||||
//生成分页
|
||||
//有些参数是可选的,比如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 + urlList.list,
|
||||
data: online_first,
|
||||
success: function (result) {
|
||||
if (result.code == 0) {
|
||||
$('.goup-container').click();
|
||||
totalRecords = result.data.count;
|
||||
$('.wenz_list .tioashu').html(result.data.count);
|
||||
$('.wenz_list>h4').html('Online First');
|
||||
initArticle(result.data.articles)
|
||||
|
||||
} 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 ',
|
||||
currPageAfterText: '',
|
||||
totalInfoSplitStr: ' of ',
|
||||
totalRecordsBeforeText: '',
|
||||
totalRecordsAfterText: '',
|
||||
gopageBeforeText: ' Go to page',
|
||||
gopageButtonOkText: 'Go',
|
||||
gopageAfterText: 'page',
|
||||
buttonTipBeforeText: '第',
|
||||
buttonTipAfterText: '页'
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
} else {
|
||||
ShowDanger("请求失败!");
|
||||
}
|
||||
},
|
||||
error: function () {
|
||||
ShowDanger("error!");
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
function initArticle(arr) {
|
||||
var str = "";
|
||||
for (var i = 0; i < arr.length; i++) {
|
||||
if (arr[i].icon == '') {
|
||||
continue
|
||||
}
|
||||
if (arr[i].icon == '') {
|
||||
var img_i = 'img/baiss.png'
|
||||
} else {
|
||||
var img_i = imgarticleUrl + arr[i].icon
|
||||
}
|
||||
var baseInfo = commonGetItemHtml({ data: arr[i], i: i, img_i: img_i, c_t_a: '' })
|
||||
str += `
|
||||
|
||||
<li>
|
||||
<div class="dbt_header">${arr[i].type}${baseInfo.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">${baseInfo.otStat}${arr[i].title}</a>
|
||||
<div class="authorList">${arr[i].authortitle}<br>
|
||||
|
||||
<a href="/${arr[i].usx}" target="_blank" > ${arr[i].journal_title}</a>. ${arr[i].stage_year}, ${arr[i].stage_vol}${baseInfo.stage_}${baseInfo.npp_}<a
|
||||
target="_blank" href="https://doi.org/${arr[i].doi}">${baseInfo.doi_}</a>
|
||||
</div>
|
||||
<div class="links_">${baseInfo.link_}</div>
|
||||
<div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">${baseInfo.person_img}</a>${baseInfo.trad_tion}<br
|
||||
clear="both"></div>
|
||||
</li>
|
||||
|
||||
`
|
||||
}
|
||||
$('.wenz_list>ul').html(str);
|
||||
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
|
||||
commonHandleClickHtml()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
63
js/scientist/scientist_pid.js
Normal file
63
js/scientist/scientist_pid.js
Normal file
@@ -0,0 +1,63 @@
|
||||
function initPid() {
|
||||
// New Papers点进去的文章列表
|
||||
var p_ID = getQueryString('p_id'); //Online First
|
||||
|
||||
|
||||
// Top cited点进去的文章列表
|
||||
if (p_ID != null) {
|
||||
var urlList = {
|
||||
list: 'api/Main/getMoreArticles'
|
||||
}
|
||||
|
||||
$.ajax({
|
||||
type: 'post', url: apiUrl + urlList.list,
|
||||
data: {},
|
||||
success: function (result) {
|
||||
if (result.code == 0) {
|
||||
$('.wenz_list>h4').html('New Papers');
|
||||
initArticle(result.data.articles)
|
||||
} else {
|
||||
ShowDanger("请求失败!");
|
||||
}
|
||||
},
|
||||
error: function () {
|
||||
ShowDanger("error!");
|
||||
}
|
||||
})
|
||||
|
||||
function initArticle(arr) {
|
||||
var str = "";
|
||||
for (var i = 0; i < arr.length; i++) {
|
||||
if (arr[i].icon == '') {
|
||||
continue
|
||||
}
|
||||
|
||||
if (arr[i].icon == '') {
|
||||
var img_i = 'img/baiss.png'
|
||||
} else {
|
||||
var img_i = imgarticleUrl + arr[i].icon
|
||||
}
|
||||
var baseInfo = commonGetItemHtml({ data: arr[i], i: i, img_i: img_i, c_t_a: '' })
|
||||
var lr_top = ''
|
||||
str += `
|
||||
<li>
|
||||
<div class="dbt_header">${arr[i].type}${baseInfo.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">${baseInfo.otStat}${arr[i].title}</a>
|
||||
<div class="authorList">${arr[i].authortitle}<br>
|
||||
${arr[i].journal_title}. ${arr[i].stage_year}, ${arr[i].stage_vol}${baseInfo.stage_}${baseInfo.npp_}<a
|
||||
target="_blank" href="https://doi.org/${arr[i].doi}">${baseInfo.doi_}</a>
|
||||
</div>
|
||||
<div class="links_">${baseInfo.link_}</div>
|
||||
<div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">${baseInfo.person_img}</a>${baseInfo.trad_tion}<br
|
||||
clear="both"></div>
|
||||
</li>
|
||||
`
|
||||
}
|
||||
$('.wenz_list>ul').html(str);
|
||||
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
|
||||
commonHandleClickHtml()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
136
js/scientist/scientist_readid.js
Normal file
136
js/scientist/scientist_readid.js
Normal file
@@ -0,0 +1,136 @@
|
||||
function initReadid() {
|
||||
// Top read点进去的文章列表
|
||||
var read_ID = getQueryString('read_id'); //Top read
|
||||
|
||||
if (read_ID != null) {
|
||||
var urlList = {
|
||||
list: 'api/Main/getThireTopArticles'
|
||||
}
|
||||
|
||||
commonInit()
|
||||
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 + urlList.list,
|
||||
data: read_tcp,
|
||||
success: function (result) {
|
||||
if (result.code == 0) {
|
||||
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);
|
||||
|
||||
$('.wenz_list>h4').html('Top read');
|
||||
|
||||
|
||||
initArticle(result.data.articles)
|
||||
//生成分页
|
||||
//有些参数是可选的,比如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 + urlList.list,
|
||||
data: read_tcp,
|
||||
success: function (result) {
|
||||
if (result.code == 0) {
|
||||
$('.goup-container').click();
|
||||
totalRecords = result.data.count;
|
||||
$('.wenz_list .tioashu').html(result.data.count);
|
||||
|
||||
$('.wenz_list>h4').html('Top read');
|
||||
initArticle(result.data.articles)
|
||||
|
||||
} 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 ',
|
||||
currPageAfterText: '',
|
||||
totalInfoSplitStr: ' of ',
|
||||
totalRecordsBeforeText: '',
|
||||
totalRecordsAfterText: '',
|
||||
gopageBeforeText: ' Go to page',
|
||||
gopageButtonOkText: 'Go',
|
||||
gopageAfterText: 'page',
|
||||
buttonTipBeforeText: '第',
|
||||
buttonTipAfterText: '页'
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
} else {
|
||||
ShowDanger("请求失败!");
|
||||
}
|
||||
},
|
||||
error: function () {
|
||||
ShowDanger("error!");
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
function initArticle(arr) {
|
||||
var str = "";
|
||||
for (var i = 0; i < arr.length; i++) {
|
||||
if (arr[i].icon == '') {
|
||||
continue
|
||||
}
|
||||
if (arr[i].icon == '') {
|
||||
var img_i = 'img/baiss.png'
|
||||
} else {
|
||||
var img_i = imgarticleUrl + arr[i].icon
|
||||
}
|
||||
var baseInfo = commonGetItemHtml({ data: arr[i], i: i, img_i: img_i, c_t_a: '' })
|
||||
str += `
|
||||
|
||||
<li>
|
||||
<div class="dbt_header">${arr[i].type}${baseInfo.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">${baseInfo.otStat}${arr[i].title}</a>
|
||||
<div class="authorList">${arr[i].authortitle}<br>
|
||||
|
||||
${arr[i].journal_title}. ${arr[i].stage_year}, ${arr[i].stage_vol}${baseInfo.stage_}${baseInfo.npp_}<a
|
||||
target="_blank" href="https://doi.org/${arr[i].doi}">${baseInfo.doi_}</a>
|
||||
</div>
|
||||
<div class="links_">${baseInfo.link_}</div>
|
||||
<div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">${baseInfo.person_img}</a>${baseInfo.trad_tion}<br
|
||||
clear="both"></div>
|
||||
</li>
|
||||
|
||||
`
|
||||
}
|
||||
$('.wenz_list>ul').html(str);
|
||||
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
|
||||
commonHandleClickHtml()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
59
js/scientist/scientist_stuffid.js
Normal file
59
js/scientist/scientist_stuffid.js
Normal file
@@ -0,0 +1,59 @@
|
||||
function initStuffid() {
|
||||
// Medicament药剂话题文章列表
|
||||
var stuff_ID = getQueryString('stuff_ID'); //Medicament药剂话题
|
||||
if (stuff_ID != null) {
|
||||
var urlList = {
|
||||
list: 'api/Tmrde/getArticleByMed'
|
||||
}
|
||||
$.ajax({
|
||||
type: 'post', url: apiUrl + urlList.list,
|
||||
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 + ' )');
|
||||
initArticle(result.data.articles)
|
||||
} else {
|
||||
ShowDanger("请求失败!");
|
||||
}
|
||||
},
|
||||
error: function () {
|
||||
ShowDanger("error!");
|
||||
}
|
||||
})
|
||||
|
||||
function initArticle(arr) {
|
||||
var str = "";
|
||||
for (var i = 0; i < arr.length; i++) {
|
||||
if (arr[i].icon == '') {
|
||||
continue
|
||||
}
|
||||
|
||||
if (arr[i].icon == '') {
|
||||
var img_i = 'img/baiss.png'
|
||||
} else {
|
||||
var img_i = imgarticleUrl + arr[i].icon
|
||||
}
|
||||
var baseInfo = commonGetItemHtml({ data: arr[i], i: i, img_i: img_i, c_t_a: '' })
|
||||
var lr_top = ''
|
||||
str += `
|
||||
<li>
|
||||
<div class="dbt_header">${arr[i].type}${baseInfo.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">${baseInfo.otStat}${arr[i].title}</a>
|
||||
<div class="authorList">${arr[i].authortitle}<br>
|
||||
${arr[i].journal_title}. ${arr[i].stage_year}, ${arr[i].stage_vol}${baseInfo.stage_}${baseInfo.npp_}<a
|
||||
target="_blank" href="https://doi.org/${arr[i].doi}">${baseInfo.doi_}</a>
|
||||
</div>
|
||||
<div class="links_">${baseInfo.link_}</div>
|
||||
<div class="apwrap"><a onclick="imgbig(this)" class="imgdiv">${baseInfo.person_img}</a>${baseInfo.trad_tion}<br
|
||||
clear="both"></div>
|
||||
</li>
|
||||
`
|
||||
}
|
||||
$('.wenz_list>ul').html(str);
|
||||
$('.links_ .txt_copy').css('background', localStorage.Journals_color);
|
||||
commonHandleClickHtml()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user