CmsUtils.getArticleList 的 isQueryArticleData 参数不生效问题 #I6HN74

This commit is contained in:
thinkgem
2023-02-27 10:35:35 +08:00
parent 0a95c15ff0
commit c81d96a6d4
3 changed files with 32 additions and 29 deletions

View File

@@ -2,15 +2,23 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.jeesite.modules.cms.dao.ArticleDao">
<!-- 查询数据
<select id="findList" resultType="CmsArticle">
<!-- 查询数据 -->
<select id="findList" resultType="Article">
SELECT ${sqlMap.column.toSql()}
<if test="isQueryArticleData">,
ad.content AS "articleData.content",
ad.relation AS "articleData.relation",
ad.is_can_comment AS "articleData.isCanComment"
</if>
FROM ${sqlMap.table.toSql()}
<if test="isQueryArticleData">
JOIN ${_prefix}cms_article_data ad ON ad.id = a.id
</if>
<where>
${sqlMap.where.toSql()}
</where>
ORDER BY ${sqlMap.order.toSql()}
</select> -->
</select>
<update id="updateExpiredWeight">
update ${_prefix}cms_article SET weight = 0