You can not select more than 25 topics
			Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
		
		
		
		
		
			
		
			
				
					32 lines
				
				1.2 KiB
			
		
		
			
		
	
	
					32 lines
				
				1.2 KiB
			| 
								 
											1 year ago
										 
									 | 
							
								<?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="com.hc.gpbusiness.mapper.NewsMapper">
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								    <resultMap type="com.hc.gpbusiness.model.News" id="NewsMap">
							 | 
						||
| 
								 | 
							
								        <result property="newsId" column="news_id" jdbcType="INTEGER"/>
							 | 
						||
| 
								 | 
							
								        <result property="newsTitle" column="news_title" jdbcType="VARCHAR"/>
							 | 
						||
| 
								 | 
							
								        <result property="newsLogo" column="news_logo" jdbcType="VARCHAR"/>
							 | 
						||
| 
								 | 
							
								        <result property="newsContent" column="news_content" jdbcType="VARCHAR"/>
							 | 
						||
| 
								 | 
							
								        <result property="moduleId" column="module_id" jdbcType="INTEGER"/>
							 | 
						||
| 
								 | 
							
								        <result property="createTime" column="create_time" jdbcType="BIGINT"/>
							 | 
						||
| 
								 | 
							
								        <result property="updateTime" column="update_time" jdbcType="BIGINT"/>
							 | 
						||
| 
								 | 
							
								    </resultMap>
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								    <sql id="Base_Column_List">
							 | 
						||
| 
								 | 
							
								           news_id,
							 | 
						||
| 
								 | 
							
								           news_title,
							 | 
						||
| 
								 | 
							
								           news_logo,
							 | 
						||
| 
								 | 
							
								           news_content,
							 | 
						||
| 
								 | 
							
								           module_id,
							 | 
						||
| 
								 | 
							
								           create_time,
							 | 
						||
| 
								 | 
							
								           update_time
							 | 
						||
| 
								 | 
							
								        </sql>
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								    <select id="queryNewsByModuleId" resultMap="NewsMap">
							 | 
						||
| 
								 | 
							
								       SELECT
							 | 
						||
| 
								 | 
							
								       <include refid="Base_Column_List"/>
							 | 
						||
| 
								 | 
							
								       FROM news
							 | 
						||
| 
								 | 
							
								       WHERE module_id = #{moduleId}
							 | 
						||
| 
								 | 
							
								    </select>
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								</mapper>
							 |