tijiao 20251027

This commit is contained in:
2025-10-27 14:47:31 +08:00
parent d70b7a5e6d
commit 602f9c7d11
2 changed files with 68 additions and 65 deletions

View File

@@ -721,55 +721,57 @@ margin-top:15px;
wh_topicd = 'top'
var st_top_tit = "";
var st_top_con = "";
// 10
if (Jour_num == 1) {
var forLength = arr_topic[i].title == "Diseases" ? 10 : 5
var forLength = arr_topic[i].title == "Diseases" ? arr_topic[i].children.length : 5
} else {
var forLength = 5
}
if (wh_number == '1') {
if(arr_topic[i].children){
for (var j = 0; j < arr_topic[i].children.length; j++) {
if (j == forLength) break;
var url_href = '';
if (arr_topic[i].children[j].is_final == '1') {
url_href = 'topic_list.html?J_num=' + Jour_num + '&t_id='
} else (
url_href = 'topic.html?J_num=' + Jour_num + '&t_id='
)
st_top_con += '<li><a target="_blank" href="' + url_href + arr_topic[i].children[j].journal_topic_id + '">' +
'<img src="' + imgtopicUrl + arr_topic[i].children[j].icon + '" alt="">' +
'<h3>' + arr_topic[i].children[j].title + '</h3></a></li>'
}
}
} else {
if(arr_topic[i].children){
if (arr_topic[i].children) {
for (var j = 0; j < arr_topic[i].children.length; j++) {
if (Jour_num == 1) {
if (j == forLength) break;
} else {
if (j == forLength - 1) break;
}
var url_href = '';
if (arr_topic[i].children[j].is_final == '1') {
url_href = 'topic_list.html?J_num=' + Jour_num + '&t_id='
} else (
url_href = 'topic.html?J_num=' + Jour_num + '&t_id='
)
st_top_con += '<li><a target="_blank" href="' + url_href + arr_topic[i].children[j].journal_topic_id + '">' +
'<img src="' + imgtopicUrl + arr_topic[i].children[j].icon + '" alt="">' +
'<h3>' + arr_topic[i].children[j].title + '</h3></a></li>'
if (j == forLength) break;
var url_href = '';
if (arr_topic[i].children[j].is_final == '1') {
url_href = 'topic_list.html?J_num=' + Jour_num + '&t_id='
} else (
url_href = 'topic.html?J_num=' + Jour_num + '&t_id='
)
st_top_con += '<li><a target="_blank" href="' + url_href + arr_topic[i].children[j].journal_topic_id + '">' +
'<img src="' + imgtopicUrl + arr_topic[i].children[j].icon + '" alt="">' +
'<h3>' + arr_topic[i].children[j].title + '</h3></a></li>'
}
}
} else {
if (arr_topic[i].children) {
for (var j = 0; j < arr_topic[i].children.length; j++) {
if (Jour_num == 1) {
if (j == forLength) break;
} else {
if (j == forLength - 1) break;
}
var url_href = '';
if (arr_topic[i].children[j].is_final == '1') {
url_href = 'topic_list.html?J_num=' + Jour_num + '&t_id='
} else (
url_href = 'topic.html?J_num=' + Jour_num + '&t_id='
)
st_top_con += '<li><a target="_blank" href="' + url_href + arr_topic[i].children[j].journal_topic_id + '">' +
'<img src="' + imgtopicUrl + arr_topic[i].children[j].icon + '" alt="">' +
'<h3>' + arr_topic[i].children[j].title + '</h3></a></li>'
}
}
}
// '<a target="_blank" href="topic.html?J_num=' + Jour_num + '&t_id=' + arr_topic[i].journal_topic_id + '" class="more" target="_blank">More</a>' +
if (Jour_num == 1) {
if (arr_topic[i].title == "Diseases") {
st_top_tit = '<div class="topics" style="padding: 0 0 5px 0;"><h4 class="rgb_color" style="font-size: 16px">' + arr_topic[i].title + '</h4>' +
'<a target="_blank" href="topic.html?J_num=' + Jour_num + '&t_id=' + arr_topic[i].journal_topic_id + '" class="more" target="_blank">More</a>' +
'<ul>' + st_top_con + '</ul></div>' +
'<p style="height: 1px;width: 97%;background-color: #ebf2f6;margin: 5px auto 0 auto;"></p>'
} else {
@@ -795,43 +797,43 @@ if(arr_topic[i].children){
// MDM 十个话题 // LF 十个话题 // BEC 十个话题 // cancer 十个话题
if ([2, 25, 11, 14].includes(Number(Jour_num))) {
if(arr_topic[i].children){
for (var j = 0; j < arr_topic[i].children.length; j++) {
if (MDM_mark == 10) break;
MDM_mark = MDM_mark + 1
var url_href = '';
if (arr_topic[i].children[j].is_final == '1') {
url_href = 'topic_list.html?J_num=' + Jour_num + '&t_id='
} else (
url_href = 'topic.html?J_num=' + Jour_num + '&t_id='
)
MDM_str += '<li><a target="_blank" href="' + url_href + arr_topic[i].children[j].journal_topic_id + '">' +
'<img src="' + imgtopicUrl + arr_topic[i].children[j].icon + '" alt="">' +
'<h3>' + arr_topic[i].children[j].title + '</h3></a></li>'
if (arr_topic[i].children) {
for (var j = 0; j < arr_topic[i].children.length; j++) {
if (MDM_mark == 10) break;
MDM_mark = MDM_mark + 1
var url_href = '';
if (arr_topic[i].children[j].is_final == '1') {
url_href = 'topic_list.html?J_num=' + Jour_num + '&t_id='
} else (
url_href = 'topic.html?J_num=' + Jour_num + '&t_id='
)
MDM_str += '<li><a target="_blank" href="' + url_href + arr_topic[i].children[j].journal_topic_id + '">' +
'<img src="' + imgtopicUrl + arr_topic[i].children[j].icon + '" alt="">' +
'<h3>' + arr_topic[i].children[j].title + '</h3></a></li>'
}
}
}
$('.art_top_topic>div>div.topics').html('<ul>' + MDM_str + '</ul>');
}
} else if (arr_topic[i].position == "left" && arr_topic[i].title == "Diseases" && Jour_num == 1) {
if (panduan != '1') {
panduan = '1';
if(arr_topic[i].children){
for (var j = 0; j < arr_topic[i].children.length; j++) {
if (j == 5) break;
var url_href = '';
if (arr_topic[i].children[j].is_final == '1') {
url_href = 'topic_list.html?J_num=' + Jour_num + '&t_id='
} else (
url_href = 'topic.html?J_num=' + Jour_num + '&t_id='
)
st_left_con += '<li><a target="_blank" href="' + url_href + arr_topic[i].children[j].journal_topic_id + '">' +
'<img src="' + imgtopicUrl + arr_topic[i].children[j].icon + '"/></a>' +
'<h3 style="text-align: center"><a target="_blank" href="' + url_href + arr_topic[i].children[j].journal_topic_id + '">' + arr_topic[i].children[j].title + '</a></h3></li>'
if (arr_topic[i].children) {
for (var j = 0; j < arr_topic[i].children.length; j++) {
if (j == 5) break;
var url_href = '';
if (arr_topic[i].children[j].is_final == '1') {
url_href = 'topic_list.html?J_num=' + Jour_num + '&t_id='
} else (
url_href = 'topic.html?J_num=' + Jour_num + '&t_id='
)
st_left_con += '<li><a target="_blank" href="' + url_href + arr_topic[i].children[j].journal_topic_id + '">' +
'<img src="' + imgtopicUrl + arr_topic[i].children[j].icon + '"/></a>' +
'<h3 style="text-align: center"><a target="_blank" href="' + url_href + arr_topic[i].children[j].journal_topic_id + '">' + arr_topic[i].children[j].title + '</a></h3></li>'
}
}
}
st_left_tit = '<div class="topics" style="padding: 0 0 5px 0;"><h4 class="rgb_color" style="font-size: 16px">' + arr_topic[i].title + '</h4>' +
'<a target="_blank" href="topic.html?J_num=' + Jour_num + '&t_id=' + arr_topic[i].journal_topic_id + '" class="more" target="_blank">More</a><ul>' + st_left_con + '</ul></div>'