修复自定义页面的关闭评论失效

This commit is contained in:
1152958806@qq.com 2023-07-23 17:10:13 +08:00
parent bb565c5963
commit 85bbc1aa96
4 changed files with 7 additions and 4 deletions

View File

@ -142,7 +142,8 @@
<th:block
th:replace="~{modules/comment :: comment(group = 'content.halo.run',
kind = 'SinglePage',
name = ${singlePage.metadata.name})}"/>
name = ${singlePage.metadata.name},
allowComment = ${singlePage.spec.allowComment})}"/>
</div>

View File

@ -1,6 +1,6 @@
<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<th:block th:fragment="comment(group, kind, name)">
<th:block th:fragment="comment(group, kind, name, allowComment)" th:if="${allowComment}">
<th:block
th:if="${theme.config.comments.twikooEnable && #strings.equals(theme.config.comments.use, 'Twikoo') && not #strings.isEmpty(theme.config.comments.twikoos.envId)}">
<div th:replace="~{modules/comment/twikoo :: twikoo}"></div>

View File

@ -19,7 +19,8 @@
<th:block
th:replace="~{modules/comment :: comment(group = 'content.halo.run',
kind = 'SinglePage',
name = ${singlePage.metadata.name})}"/>
name = ${singlePage.metadata.name},
allowComment = ${singlePage.spec.allowComment})}"/>
</div>

View File

@ -180,7 +180,8 @@
<th:block
th:replace="~{modules/comment :: comment(group = 'content.halo.run',
kind = 'Post',
name = ${post.metadata.name})}"/>
name = ${post.metadata.name},
allowComment = ${post.spec.allowComment})}"/>
</div>