Merge remote-tracking branch 'origin/zcc'

This commit is contained in:
wangjinlei
2023-11-27 11:35:29 +08:00
6 changed files with 78 additions and 16 deletions

View File

@@ -14,5 +14,13 @@
<result property="delFlag" column="del_flag"/>
</resultMap>
<select id="getBooks" parameterType="int" resultType="com.peanut.modules.book.entity.BookEntity">
select b.* from book_medical_records bmr
left join book b on bmr.book_id = b.id
where bmr.book_id not in (select book_id from user_ebook_buy where user_id = #{userId})
and b.del_flag = 0 and b.state = 1
GROUP BY bmr.book_id
limit #{page},#{limit}
</select>
</mapper>