tijiao
This commit is contained in:
@@ -57,7 +57,7 @@ function commonGetItemHtml(doc) {
|
||||
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"),
|
||||
abstract: data.abstract?data.abstract.replace(new RegExp("0, 102, 204", "g"), "0,102,153"):'',
|
||||
link_: '',
|
||||
stage_: '',
|
||||
}
|
||||
@@ -114,13 +114,13 @@ function commonGetItemHtml(doc) {
|
||||
|
||||
if (data.tradition_tag == '' || data.tradition_tag == null) {
|
||||
var maxwidth = 500;//显示多少字符
|
||||
if (data.abstract.length > maxwidth) {
|
||||
if (data.abstract&&data.abstract.length > maxwidth) {
|
||||
var abstNew = data.abstract.replace(/<.*?>/ig, "")
|
||||
abstNew = abstNew.substring(0, maxwidth)
|
||||
abstNew = abstNew.substring(0, maxwidth - abstNew.split(" ").pop().length)
|
||||
baseInfo.trad_tion = '<div>' + abstNew + '...</div>'
|
||||
} else {
|
||||
baseInfo.trad_tion = '<div>' + data.abstract + '</div>'
|
||||
baseInfo.trad_tion = '<div>' + data.abstract?data.abstract:'' + '</div>'
|
||||
}
|
||||
} else {
|
||||
baseInfo.trad_tion = '<div><h3>' + data.tradition_tag + '</h3><p>' + data.tradition + '</p></div>'
|
||||
|
||||
Reference in New Issue
Block a user