y_id cite

This commit is contained in:
2024-08-22 16:53:15 +08:00
parent d8b59ff8ab
commit 5a3193feb4
7 changed files with 392 additions and 14 deletions

BIN
img/link_6.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

BIN
img/link_7.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 749 B

View File

@@ -1129,9 +1129,16 @@ function at_list() {
} 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].cite_num == 0) {
var cite_ = ''
} else {
var cite_ = `<span article_id="${arr[i].article_id}" class="cite_box" style="color: #7a2702;"> <img src="img/link_6.jpg" width="14" height="16">WOS Citations&nbsp;(&nbsp;<span style="color: red">${arr[i].cite_num} </span>&nbsp;)
<ul class="export_cite "> </ul></span>`
}
if ((Math.round(Date.parse(new Date()) / 1000) - arr[i].ctime) / 86400 >= 21) {
var tong_geogle = '<a href = "https://scholar.google.com/scholar?&q=' + arr[i].title.replace('<i>', '').replace('</i>', '').replace(new RegExp('"', "g"), '') + '"' +
'target = "_blank" style="color: ' + localStorage.Journals_color + ';margin-left: 10px;font-weight: 600;"> ' +
'target = "_blank" style="color:#7a2702;;margin-left: 10px;"> ' +
'Google Scholar</a>' //搜索引用次数
} else {
var tong_geogle = '' //少于21天隐藏
@@ -1198,16 +1205,15 @@ function at_list() {
var person_img = '<img src="' + img_i + '" alt="">'
}
if (localStorage.Journals_num == '22') {
var c_t_a = '<button class="txt_copy">引用这篇文章<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> 复制引用信息</li><li class="Exc_2"><i class="fa fa-download"></i> 下载EndNote格式</li><li class="Exc_3"><i class="fa fa-download"></i> 下载RIS格式</li><li class="Exc_4"><i class="fa fa-download"></i> 下载BibTex格式</li><li class="Exc_5"><i class="fa fa-download"></i> 下载text格式</li><div class="triangle"></div></ul></button>'
if (arr[i].journal_id == 22) {
var c_t_a = '<button class="txt_copy cite_txt_button" >&nbsp;<img src="img/link_7.jpg" width="14" height="16">引用这篇文章<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> 复制引用信息</li><li class="Exc_2"><i class="fa fa-download"></i> 下载EndNote格式</li><li class="Exc_3"><i class="fa fa-download"></i> 下载RIS格式</li><li class="Exc_4"><i class="fa fa-download"></i> 下载BibTex格式</li><li class="Exc_5"><i class="fa fa-download"></i> 下载text格式</li><div class="triangle"></div></ul></button>'
} else {
var c_t_a = '<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>'
var c_t_a = '<button class="txt_copy cite_txt_button">&nbsp;<img src="img/link_7.jpg" width="14" height="16">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>'
}
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">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ + c_t_a + tong_geogle +
html_ + pdf_ + mp4_ + c_t_a+ cite_ + tong_geogle +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
@@ -1302,6 +1308,18 @@ function at_list() {
});
$(this).next().html(num);
})
$('.export_cite').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export_cite') && !$(e.target).is('.cite_box')) {
$('.export_cite').hide();
}
})
$('.cite_box').click(function () {
$('.export_cite').css('display', 'none');
getCiteList($(this).attr('article_id'))
$(this).find('.export_cite').fadeIn(200);
})
$('.export_cite').click(function (e) { e.stopPropagation() })
// 点击弹窗出现 复制和下载
$('.txt_content').css('display', 'none');
@@ -8031,3 +8049,48 @@ function showComments(num) {
, content: shenCode[num]
});
}
function getCiteList(a_ID) {
$('.cite_box .export_cite').html('<div class="loader-01"></div>');
var journalCiteStr = ''
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleCites',
data: {
"article_id": a_ID
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.list
for (let i in arr) {
journalCiteStr += `
<div class='cite_list_item' style="margin-bottom:10px;podding:10px 0;display:flex;border-bottom: ${i != arr.length - 1 ? '1px solid #ccc' : 'none'};}"><p style="margin-right:10px;">${Number(i) + 1}.</p>
<div>
<p style="display: block; line-height: 20px;
font-size: 13px;
margin-bottom: 3px;"> <a style="color:#205493 !important;"
target="_blank"
href="${arr[i].doi ? 'https://doi.org/' + arr[i].doi : ''}">
${arr[i].article_name}
</a></p>
<p style="line-height: 14px;margin-bottom: 10px;">
<span style="color: #a2b1b6;
font-size: 13px;">${arr[i].author ? `${arr[i].author},` : ''} ${arr[i].journal_name}${arr[i].vol ? `${arr[i].vol},` : ''}
</span>
<span style="margin-left:5px;color:#205493 !important;">
</span></p></div>
</div> `
}
journalCiteStr += ` <div class="cite_triangle"></div>`
$('.cite_box .export_cite').html(journalCiteStr);
}
}
})
}

View File

@@ -178,6 +178,12 @@ function bf_list() {
} 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].cite_num == 0) {
var cite_ = ''
} else {
var cite_ = `<span article_id="${arr[i].article_id}" class="cite_box" style="color: #7a2702;"> <img src="img/link_6.jpg" width="14" height="16">WOS Citations&nbsp;(&nbsp;<span style="color: red">${arr[i].cite_num} </span>&nbsp;)
<ul class="export_cite "> </ul></span>`
}
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 {
@@ -185,7 +191,7 @@ function bf_list() {
}
if ((Math.round(Date.parse(new Date()) / 1000) - arr[i].ctime) / 86400 >= 21) {
var tong_geogle = '<a href = "https://scholar.google.com/scholar?&q=' + arr[i].title.replace('<i>', '').replace('</i>', '').replace(new RegExp('"', "g"), '') + '"' +
'target = "_blank" style="color: ' + localStorage.Journals_color + ';margin-left: 10px;font-weight: 600;"> ' +
'target = "_blank" style="color:#7a2702;margin-left: 10px;font-weight: 600;"> ' +
'Google Scholar</a>' //搜索引用次数
} else {
var tong_geogle = '' //少于21天隐藏
@@ -208,12 +214,12 @@ function bf_list() {
}
if (arr[i].journal_id == 22) {
var c_t_a = '<button class="txt_copy">引用这篇文章<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> 复制引用信息</li><li class="Exc_2"><i class="fa fa-download"></i> 下载EndNote格式</li><li class="Exc_3"><i class="fa fa-download"></i> 下载RIS格式</li><li class="Exc_4"><i class="fa fa-download"></i> 下载BibTex格式</li><li class="Exc_5"><i class="fa fa-download"></i> 下载text格式</li><div class="triangle"></div></ul></button>'
var c_t_a = '<button class="txt_copy cite_txt_button" >&nbsp;<img src="img/link_7.jpg" width="14" height="16">引用这篇文章<ul class="export"><li id="txt_copy_' + i + '" class="Exc_1">>> 复制引用信息</li><li class="Exc_2"><i class="fa fa-download"></i> 下载EndNote格式</li><li class="Exc_3"><i class="fa fa-download"></i> 下载RIS格式</li><li class="Exc_4"><i class="fa fa-download"></i> 下载BibTex格式</li><li class="Exc_5"><i class="fa fa-download"></i> 下载text格式</li><div class="triangle"></div></ul></button>'
} else {
var c_t_a = '<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>'
var c_t_a = '<button class="txt_copy cite_txt_button">&nbsp;<img src="img/link_7.jpg" width="14" height="16">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>'
}
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">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ + c_t_a + tong_geogle +
html_ + pdf_ + mp4_ + c_t_a + cite_+ tong_geogle +
'<p class="txt_content">' + arr[i].cite + '</p>' +
'<div>' + arr[i].abstract + '</div>';
@@ -387,6 +393,19 @@ function bf_list() {
$(this).next().html(num);
})
$('.current_list .export_cite').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export_cite') && !$(e.target).is('.cite_box')) {
$('.export_cite').hide();
}
})
$('.current_list .cite_box').click(function () {
$('.export_cite').css('display', 'none');
getCiteList($(this).attr('article_id'))
$(this).find('.export_cite').fadeIn(200);
})
$('.export_cite').click(function (e) { e.stopPropagation() })
// 点击弹窗出现 复制和下载
$('.current_list .txt_content').css('display', 'none');
$('.current_list .export').css('display', 'none');
@@ -1242,3 +1261,48 @@ function bf_list() {
}
function getCiteList(a_ID) {
$('.cite_box .export_cite').html('<div class="loader-01"></div>');
var journalCiteStr = ''
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleCites',
data: {
"article_id": a_ID
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.list
for (let i in arr) {
journalCiteStr += `
<div class='cite_list_item' style="margin-bottom:10px;podding:10px 0;display:flex;border-bottom: ${i != arr.length - 1 ? '1px solid #ccc' : 'none'};}"><p style="margin-right:10px;">${Number(i) + 1}.</p>
<div>
<p style="display: block; line-height: 20px;
font-size: 13px;
margin-bottom: 3px;"> <a style="color:#205493 !important;"
target="_blank"
href="${arr[i].doi ? 'https://doi.org/' + arr[i].doi : ''}">
${arr[i].article_name}
</a></p>
<p style="line-height: 14px;margin-bottom: 10px;">
<span style="color: #a2b1b6;
font-size: 13px;">${arr[i].author ? `${arr[i].author},` : ''} ${arr[i].journal_name}${arr[i].vol ? `${arr[i].vol},` : ''}
</span>
<span style="margin-left:5px;color:#205493 !important;">
</span></p></div>
</div> `
}
journalCiteStr += ` <div class="cite_triangle"></div>`
$('.cite_box .export_cite').html(journalCiteStr);
}
}
})
}

View File

@@ -193,6 +193,12 @@ function bf_list() {
} 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].cite_num == 0) {
var cite_ = ''
} else {
var cite_ = `<span article_id="${arr[i].article_id}" class="cite_box" style="color: #7a2702;"> <img src="img/link_6.jpg" width="14" height="16">WOS Citations&nbsp;(&nbsp;<span style="color: red">${arr[i].cite_num} </span>&nbsp;)
<ul class="export_cite "> </ul></span>`
}
if ((Math.round(Date.parse(new Date()) / 1000) - arr[i].ctime) / 86400 >= 21) {
var tong_geogle = '<a href = "https://scholar.google.com/scholar?&q=' + arr[i].title.replace('<i>', '').replace('</i>', '').replace(new RegExp('"', "g"), '') + '"' +
'target = "_blank" style="color: ' + localStorage.Journals_color + ';margin-left: 10px;font-weight: 600;"> ' +
@@ -209,7 +215,7 @@ function bf_list() {
}
if ((Math.round(Date.parse(new Date()) / 1000) - arr[i].ctime) / 86400 >= 21) {
var tong_geogle_2_2 = '<a href = "https://scholar.google.com/scholar?&q=' + arr[i].title.replace('<i>', '').replace('</i>', '').replace(new RegExp('"', "g"), '') + '"' +
'target = "_blank" style="color: ' + localStorage.Journals_color + ';margin:5px 37px 0 0;font-weight: 600;display: inline-block;"> ' +
'target = "_blank" style="color: #7a2702;margin:5px 37px 0 0;font-weight: 600;display: inline-block;"> ' +
'Google Scholar</a>' //搜索引用次数
} else {
var tong_geogle_2_2 = '' //少于21天隐藏
@@ -243,10 +249,10 @@ function bf_list() {
arr[i].abstract = arr[i].abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153")
var c_t_a = '<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>'
var c_t_a = '<button class="txt_copy cite_txt_button">&nbsp;<img src="img/link_7.jpg" width="14" height="16">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>'
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">' + arr[i].abs_num + '</span>&nbsp;)&nbsp;&nbsp;&nbsp;' +
html_ + pdf_ + mp4_ + c_t_a + tong_geogle
html_ + pdf_ + mp4_ + c_t_a + cite_+ tong_geogle
+ '<p class="txt_content">' + arr[i].cite + '</p><div>' + arr[i].abstract + '</div>';
var lr_top = ''
for (var t = 0; t < arr[i].topic.length; t++) {
@@ -369,6 +375,18 @@ function bf_list() {
});
$(this).next().html(num);
})
$('.current_list .export_cite').css('display', 'none');
$(document).click(function (e) {
if (!$(e.target).is('.export_cite') && !$(e.target).is('.cite_box')) {
$('.export_cite').hide();
}
})
$('.current_list .cite_box').click(function () {
$('.export_cite').css('display', 'none');
getCiteList($(this).attr('article_id'))
$(this).find('.export_cite').fadeIn(200);
})
$('.export_cite').click(function (e) { e.stopPropagation() })
// 点击弹窗出现 复制和下载
$('.current_list .txt_content').css('display', 'none');
@@ -1272,3 +1290,48 @@ function bf_list() {
})
}
function getCiteList(a_ID) {
$('.cite_box .export_cite').html('<div class="loader-01"></div>');
var journalCiteStr = ''
$.ajax({
type: 'post', url: apiUrl + 'api/Article/getArticleCites',
data: {
"article_id": a_ID
},
success: function (result) {
if (result.code == 0) {
var arr = result.data.list
for (let i in arr) {
journalCiteStr += `
<div class='cite_list_item' style="margin-bottom:10px;podding:10px 0;display:flex;border-bottom: ${i != arr.length - 1 ? '1px solid #ccc' : 'none'};}"><p style="margin-right:10px;">${Number(i) + 1}.</p>
<div>
<p style="display: block; line-height: 20px;
font-size: 13px;
margin-bottom: 3px;"> <a style="color:#205493 !important;"
target="_blank"
href="${arr[i].doi ? 'https://doi.org/' + arr[i].doi : ''}">
${arr[i].article_name}
</a></p>
<p style="line-height: 14px;margin-bottom: 10px;">
<span style="color: #a2b1b6;
font-size: 13px;">${arr[i].author ? `${arr[i].author},` : ''} ${arr[i].journal_name}${arr[i].vol ? `${arr[i].vol},` : ''}
</span>
<span style="margin-left:5px;color:#205493 !important;">
</span></p></div>
</div> `
}
journalCiteStr += ` <div class="cite_triangle"></div>`
$('.cite_box .export_cite').html(journalCiteStr);
}
}
})
}

View File

@@ -2144,6 +2144,39 @@ ul li .ab_tad {
.current_list li .links_ button .export li:hover {
text-decoration: underline;
}
.current_list li .cite_box {
position: relative;
display: inline-block;
cursor: pointer;
padding-left: 5px;
}
.pai_two .current_list li .cite_box {
padding-left: 0px;
}
.current_list li .cite_box .export_cite {
position: absolute;
left: 5px;
top: 35px;
background-color: #fff;
width: 500px;
padding: 5px 10px;
box-shadow: 2px 2px 5px #ccc;
z-index: 100;
}
.current_list li .cite_box .export_cite li {
color: #444;
text-align: left;
line-height: 26px;
}
.current_list li .cite_box .export_cite li:hover {
text-decoration: underline;
}
.wenz_list li .links_ button {
position: relative;
@@ -3063,3 +3096,60 @@ ul li .ab_tad {
margin-bottom: 2px;
display: block;
}
[class*="loader-"] {
display: inline-block;
width: 1em;
height: 1em;
color: inherit;
vertical-align: middle;
pointer-events: none;
}
.loader-01 {
border: .2em dotted currentcolor;
border-radius: 50%;
-webkit-animation: 1s loader-01 linear infinite;
animation: 1s loader-01 linear infinite;
}
@-webkit-keyframes loader-01 {
0% {
-webkit-transform: rotate(0deg);
transform: rotate(0deg);
}
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
@keyframes loader-01 {
0% {
-webkit-transform: rotate(0deg);
transform: rotate(0deg);
}
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
.cite_txt_button {
background: #fff !important;
padding: 0 !important;
color: #7a2702 !important;
margin-left: 5px !important;
font-family: "Helvetica Neue", Helvetica, Georgia, sans-serif !important;
font-size: 14px !important;
}
.cite_txt_button .export{
left: 130px !important;
}
.pai_two .cite_txt_button {
margin-left: 0px !important;
}

View File

@@ -2646,6 +2646,44 @@ ul li .ab_tad {
text-decoration: underline;
}
.cite_box {
position: relative;
display: inline-block;
cursor: pointer;
padding-left: 5px;
}
.pai_two .current_list li .cite_box {
padding-left: 0px;
}
.cite_box .export_cite {
position: absolute;
left: 5px;
top: 35px;
background-color: #fff;
width: 500px;
padding: 5px 10px;
box-shadow: 2px 2px 5px #ccc;
z-index: 100;
}
.cite_box .export_cite li {
color: #444;
text-align: left;
line-height: 26px;
}
.cite_box .export_cite li:hover {
text-decoration: underline;
}
.cite_box .export_cite a:hover {
text-decoration: underline !important;
}
.wenz_list li .links_ button {
position: relative;
}
@@ -5198,4 +5236,64 @@ ul li .ab_tad {
}
/* 20240306 */
/* 20240306 */
[class*="loader-"] {
display: inline-block;
width: 1em;
height: 1em;
color: inherit;
vertical-align: middle;
pointer-events: none;
}
.loader-01 {
border: .2em dotted currentcolor;
border-radius: 50%;
-webkit-animation: 1s loader-01 linear infinite;
animation: 1s loader-01 linear infinite;
}
@-webkit-keyframes loader-01 {
0% {
-webkit-transform: rotate(0deg);
transform: rotate(0deg);
}
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
@keyframes loader-01 {
0% {
-webkit-transform: rotate(0deg);
transform: rotate(0deg);
}
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
}
}
.cite_txt_button {
background: #fff !important;
padding: 0 !important;
color: #7a2702 !important;
margin-left: 5px !important;
font-family: "Helvetica Neue", Helvetica, Georgia, sans-serif !important;
font-size: 14px !important;
}
.cite_txt_button .export {
z-index: 10;
left: 130px !important;
}
.pai_two .cite_txt_button {
margin-left: 0px !important;
}