From 88bd75d93f86d3cf4f12e652d459da8bae71e545 Mon Sep 17 00:00:00 2001
From: zxl <763096477@qq.com>
Date: 星期二, 24 六月 2025 15:22:04 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/dev' into dev

---
 framework/src/main/resources/mapper/lmk/NewsMapper.xml |   44 ++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 44 insertions(+), 0 deletions(-)

diff --git a/framework/src/main/resources/mapper/lmk/NewsMapper.xml b/framework/src/main/resources/mapper/lmk/NewsMapper.xml
new file mode 100644
index 0000000..52e26c3
--- /dev/null
+++ b/framework/src/main/resources/mapper/lmk/NewsMapper.xml
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="cn.lili.modules.lmk.mapper.NewsMapper">
+
+    <!-- 閫氱敤鏌ヨ鏄犲皠缁撴灉 -->
+    <resultMap id="BaseResultMap" type="cn.lili.modules.lmk.domain.vo.NewsVO">
+        <result column="title" property="title" />
+        <result column="content" property="content"/>
+        <result column="publish" property="publish" />
+        <result column="publishDate" property="publish_date" />
+
+    </resultMap>
+
+    <select id="getById" resultMap="BaseResultMap">
+        SELECT
+            LN.id,
+            LN.publish,
+            LN.publish_date,
+            LN.content,
+            LN.title
+        FROM
+            lmk_news LN
+        WHERE
+            LN.id = #{id} AND LN.delete_flag = 0
+    </select>
+
+
+    <select id="getPage" resultMap="BaseResultMap">
+        SELECT
+        LN.id,
+        LN.publish,
+        LN.publish_date,
+        LN.content,
+        LN.title
+        FROM
+            lmk_news LN
+        WHERE
+            LN.delete_flag = 0
+            <if test="query.title != null and query.title != ''">AND LN.title LIKE CONCAT('%', #{query.title}, '%')</if>
+            <if test="query.publish != null and query.publish != ''">AND LN.publish = #{query.publish}</if>
+    </select>
+
+
+</mapper>

--
Gitblit v1.8.0