This commit is contained in:
make
2025-04-12 22:45:39 +08:00
parent 23b082e3c1
commit f740eed79f
14 changed files with 310 additions and 835 deletions

View File

@@ -56,13 +56,13 @@
</div>
<div class="tabBd">
<ul class="hotBookBd " >
<ul class="hotBookBd ">
{volist name="arrMoonRankNovel" id="Novel" key="key"}
{include file="Pc/Public/endNovelList" start="0"/}
{/volist}
</ul>
</div>
</div>
@@ -76,19 +76,19 @@
{volist name="arrRecommendEndNovel" id="Novel" key="key"}
{$arrGRM[$key]|raw}
<li>
<a href='{$strPcPath}{site:nurl n_id="$Novel->n_id" n_py="$Novel->og_novel_pin_yin"/}'
alt="{$Novel.og_novel_book_name ?? ''}" title="{$Novel.og_novel_book_name ?? ''}">
<img src="{$Novel.n_cover_path ?? ''}">
<a href='{$strPcPath}{site:nurl n_id="$Novel[n_id]" n_py="$Novel[og_novel_pin_yin]"/}'
title="{$Novel.og_novel_book_name ?? ''}">
<img src="{$Novel.n_cover_path ?? ''}" alt="{$Novel.og_novel_book_name ?? ''}">
</a>
<p>
<a href="/novel/332.html">
<a href='{$strPcPath}{site:nurl n_id="$Novel->n_id" n_py="$Novel->og_novel_pin_yin"/}'>
<span class="bookName other">{$Novel.og_novel_book_name ?? ''}</span>
</a>
<a href='{site:souurl key="$arrNovel.og_novel_author" p="1"/}'>
<a href='{$strPcPath}{site:souurl key="$Novel[og_novel_author]" p="1"/}'>
<span class="bookStatus other">{$Novel->og_novel_author ?? ''}</span>
</a>
<span class="bookBrief">
{$Novel.og_description ?? ''}</span>
{$Novel.og_description ?? ''}</span>
</p>
</li>
{/volist}
@@ -100,9 +100,12 @@
</div>
<script>
const strNovelUrlTemp = `{$strNovelUrlTemp}`;
const strNovelChapterUrlTemp = `{$strNovelChapterUrlTemp}`;
const strSearchUrlTemp = `{$strSearchUrlTemp}`;
document.addEventListener("DOMContentLoaded", function () {
displayBookshelfInUser()
displayHistoryInUser()
})
@@ -122,55 +125,59 @@
const DomBookshelfContainer = document.getElementById('bookshelf-ul');
DomBookshelfContainer.innerHTML = ''
arrBookshelf.forEach(book => {
let strNovelUrl = formatNovelUrl(book.og_novel_pin_yin, book.n_id)
let strNovelChapterUrl = formatNovelChapterUrl(book.og_novel_pin_yin, book.n_id, book.c_sort_num)
let strSearchUrl = formatSearchUrl(book.og_novel_author, 1)
const bookElement = document.createElement('li');
if (isMobile()) {
bookElement.innerHTML = `
<a href="/xiaoshuo/${book.og_novel_pin_yin}-${book.n_id}" alt="${book.og_novel_book_name}" title="${book.og_novel_book_name}">
<a href="${strNovelUrl}" alt="${book.og_novel_book_name}" title="${book.og_novel_book_name}">
<img src="${book.n_cover_path}">
</a>
<p>
<a href="/xiaoshuo/${book.og_novel_pin_yin}-${book.n_id}" >
<a href="${strNovelUrl}" >
<span class="bookName">${book.og_novel_book_name}</span>
</a>
<span class="bookStatus">
<b class="authorSt"><em>${book.og_novel_status}</em>
<a href='{site:souurl key="$arrNovel.og_novel_author" p="1"/}'>
<a href='${strSearchUrl}'>
<em class="none">${book.og_novel_author}</em>
</a>
</b>
<b class="authorSt chapterSt">
<a href="/xiaoshuo/${book.og_novel_pin_yin}-${book.n_id}/zhang-${book.c_sort_num}" >
<a href="${strNovelChapterUrl}" >
<em class="ct">${book.c_name}</em>
</a>
<em class="time">${book.og_novel_update_time}</em></b>
</span>
<a href="/xiaoshuo/${book.og_novel_pin_yin}-${book.n_id}/zhang-${book.c_sort_num}" >
<a href="${strNovelChapterUrl}" >
<i class="goon">阅读</i>
</a>
</p>
`;
} else {
bookElement.innerHTML = `
<a href="{$strPcPath}/xiaoshuo/${book.og_novel_pin_yin}-${book.n_id}" alt="${book.og_novel_book_name}" title="${book.og_novel_book_name}">
<a href="${strPcPath}${strNovelUrl}" alt="${book.og_novel_book_name}" title="${book.og_novel_book_name}">
<img src="${book.n_cover_path}">
</a>
<p>
<a href="{$strPcPath}/xiaoshuo/${book.og_novel_pin_yin}-${book.n_id}" >
<a href="${strPcPath}${strNovelUrl}" >
<span class="bookName">${book.og_novel_book_name}</span>
</a>
<span class="bookStatus">
<b class="authorSt"><em>${book.og_novel_status}</em>
<a href='{site:souurl key="$arrNovel.og_novel_author" p="1"/}'>
<a href='${strPcPath}${strSearchUrl}'>
<em class="none">${book.og_novel_author}</em>
</a>
</b>
<b class="authorSt chapterSt">
<a href="{$strPcPath}/xiaoshuo/${book.og_novel_pin_yin}-${book.n_id}/zhang-${book.c_sort_num}" >
<a href="${strPcPath}${strNovelChapterUrl}" >
<em class="ct">${book.c_name}</em>
</a>
<em class="time">${book.og_novel_update_time}</em></b>
</span>
<a href="{$strPcPath}/xiaoshuo/${book.og_novel_pin_yin}-${book.n_id}/zhang-${book.c_sort_num}" >
<a href="${strPcPath}${strNovelChapterUrl}" >
<i class="goon">阅读</i>
</a>
</p>
@@ -196,55 +203,58 @@
const DomBookshelfContainer = document.getElementById('history-ul');
DomBookshelfContainer.innerHTML = ''
arrBookshelf.forEach(book => {
let strNovelUrl = formatNovelUrl(book.og_novel_pin_yin, book.n_id)
let strNovelChapterUrl = formatNovelChapterUrl(book.og_novel_pin_yin, book.n_id, book.c_sort_num)
let strSearchUrl = formatSearchUrl(book.og_novel_author, 1)
const bookElement = document.createElement('li');
if (isMobile()) {
bookElement.innerHTML = `
<a href="/xiaoshuo/${book.og_novel_pin_yin}-${book.n_id}" alt="${book.og_novel_book_name}" title="${book.og_novel_book_name}">
<a href="${strNovelUrl}" alt="${book.og_novel_book_name}" title="${book.og_novel_book_name}">
<img src="${book.n_cover_path}">
</a>
<p>
<a href="/xiaoshuo/${book.og_novel_pin_yin}-${book.n_id}" >
<a href="${strNovelUrl}" >
<span class="bookName">${book.og_novel_book_name}</span>
</a>
<span class="bookStatus">
<b class="authorSt"><em>${book.og_novel_status}</em>
<a href='{site:souurl key="$arrNovel.og_novel_author" p="1"/}'>
<a href='${strSearchUrl}'>
<em class="none">${book.og_novel_author}</em>
</a>
</b>
<b class="authorSt chapterSt">
<a href="/xiaoshuo/${book.og_novel_pin_yin}-${book.n_id}/zhang-${book.c_sort_num}" >
<a href="${strNovelChapterUrl}" >
<em class="ct">${book.c_name}</em>
</a>
<em class="time">${book.og_novel_update_time}</em></b>
</span>
<a href="/xiaoshuo/${book.og_novel_pin_yin}-${book.n_id}/zhang-${book.c_sort_num}" >
<a href="${strNovelChapterUrl}" >
<i class="goon">阅读</i>
</a>
</p>
`;
} else {
bookElement.innerHTML = `
<a href="{$strPcPath}/xiaoshuo/${book.og_novel_pin_yin}-${book.n_id}" alt="${book.og_novel_book_name}" title="${book.og_novel_book_name}">
<a href="${strPcPath}${strNovelUrl}" alt="${book.og_novel_book_name}" title="${book.og_novel_book_name}">
<img src="${book.n_cover_path}">
</a>
<p>
<a href="{$strPcPath}/xiaoshuo/${book.og_novel_pin_yin}-${book.n_id}" >
<a href="${strPcPath}${strNovelUrl}" >
<span class="bookName">${book.og_novel_book_name}</span>
</a>
<span class="bookStatus">
<b class="authorSt"><em>${book.og_novel_status}</em>
<a href='{site:souurl key="$arrNovel.og_novel_author" p="1"/}'>
<a href='${strSearchUrl}'>
<em class="none">${book.og_novel_author}</em>
</a>
</b>
<b class="authorSt chapterSt">
<a href="{$strPcPath}/xiaoshuo/${book.og_novel_pin_yin}-${book.n_id}/zhang-${book.c_sort_num}" >
<a href="${strPcPath}${strNovelChapterUrl}" >
<em class="ct">${book.c_name}</em>
</a>
<em class="time">${book.og_novel_update_time}</em></b>
</span>
<a href="{$strPcPath}/xiaoshuo/${book.og_novel_pin_yin}-${book.n_id}/zhang-${book.c_sort_num}" >
<a href="${strPcPath}${strNovelChapterUrl}" >
<i class="goon">阅读</i>
</a>
</p>