|
|
|
@ -1,46 +1,98 @@
|
|
|
|
|
<?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">
|
|
|
|
|
|
|
|
|
|
<!-- 定义 MyBatis 的 Mapper,命名空间为 com.dao.RuzhuanpaiDao,
|
|
|
|
|
该命名空间用于与对应的 DAO 接口关联,从而实现对数据库的操作 -->
|
|
|
|
|
<mapper namespace="com.dao.RuzhuanpaiDao">
|
|
|
|
|
|
|
|
|
|
<!-- 可根据自己的需求,是否要使用 -->
|
|
|
|
|
<resultMap type="com.entity.RuzhuanpaiEntity" id="ruzhuanpaiMap">
|
|
|
|
|
<result property="yudingbianhao" column="yudingbianhao"/>
|
|
|
|
|
<result property="jiudianmingcheng" column="jiudianmingcheng"/>
|
|
|
|
|
<result property="fangjianleixing" column="fangjianleixing"/>
|
|
|
|
|
<result property="shuliang" column="shuliang"/>
|
|
|
|
|
<result property="kefangtupian" column="kefangtupian"/>
|
|
|
|
|
<result property="yonghuming" column="yonghuming"/>
|
|
|
|
|
<result property="xingming" column="xingming"/>
|
|
|
|
|
<result property="shoujihao" column="shoujihao"/>
|
|
|
|
|
<result property="fangjianhao" column="fangjianhao"/>
|
|
|
|
|
<result property="crossuserid" column="crossuserid"/>
|
|
|
|
|
<result property="crossrefid" column="crossrefid"/>
|
|
|
|
|
</resultMap>
|
|
|
|
|
<!--
|
|
|
|
|
定义一个结果映射,可根据实际需求选择是否使用。
|
|
|
|
|
该结果映射用于将数据库查询结果映射到 com.entity.RuzhuanpaiEntity 实体类上。
|
|
|
|
|
type 属性指定结果映射对应的 Java 实体类,id 属性为该结果映射的唯一标识。
|
|
|
|
|
-->
|
|
|
|
|
<resultMap type="com.entity.RuzhuanpaiEntity" id="ruzhuanpaiMap">
|
|
|
|
|
<!-- 将数据库表中的 yudingbianhao 列的值映射到实体类的 yudingbianhao 属性 -->
|
|
|
|
|
<result property="yudingbianhao" column="yudingbianhao"/>
|
|
|
|
|
<!-- 将数据库表中的 jiudianmingcheng 列的值映射到实体类的 jiudianmingcheng 属性 -->
|
|
|
|
|
<result property="jiudianmingcheng" column="jiudianmingcheng"/>
|
|
|
|
|
<!-- 将数据库表中的 fangjianleixing 列的值映射到实体类的 fangjianleixing 属性 -->
|
|
|
|
|
<result property="fangjianleixing" column="fangjianleixing"/>
|
|
|
|
|
<!-- 将数据库表中的 shuliang 列的值映射到实体类的 shuliang 属性 -->
|
|
|
|
|
<result property="shuliang" column="shuliang"/>
|
|
|
|
|
<!-- 将数据库表中的 kefangtupian 列的值映射到实体类的 kefangtupian 属性 -->
|
|
|
|
|
<result property="kefangtupian" column="kefangtupian"/>
|
|
|
|
|
<!-- 将数据库表中的 yonghuming 列的值映射到实体类的 yonghuming 属性 -->
|
|
|
|
|
<result property="yonghuming" column="yonghuming"/>
|
|
|
|
|
<!-- 将数据库表中的 xingming 列的值映射到实体类的 xingming 属性 -->
|
|
|
|
|
<result property="xingming" column="xingming"/>
|
|
|
|
|
<!-- 将数据库表中的 shoujihao 列的值映射到实体类的 shoujihao 属性 -->
|
|
|
|
|
<result property="shoujihao" column="shoujihao"/>
|
|
|
|
|
<!-- 将数据库表中的 fangjianhao 列的值映射到实体类的 fangjianhao 属性 -->
|
|
|
|
|
<result property="fangjianhao" column="fangjianhao"/>
|
|
|
|
|
<!-- 将数据库表中的 crossuserid 列的值映射到实体类的 crossuserid 属性 -->
|
|
|
|
|
<result property="crossuserid" column="crossuserid"/>
|
|
|
|
|
<!-- 将数据库表中的 crossrefid 列的值映射到实体类的 crossrefid 属性 -->
|
|
|
|
|
<result property="crossrefid" column="crossrefid"/>
|
|
|
|
|
</resultMap>
|
|
|
|
|
|
|
|
|
|
<!--
|
|
|
|
|
定义一个查询方法,方法名为 selectListVO。
|
|
|
|
|
resultType 属性指定查询结果的类型为 com.entity.vo.RuzhuanpaiVO。
|
|
|
|
|
该方法用于从 ruzhuanpai 表中查询满足条件的所有记录,
|
|
|
|
|
条件通过 ${ew.sqlSegment} 动态传入,通常 ${ew.sqlSegment} 由 MyBatis-Plus 等框架的条件构造器生成。
|
|
|
|
|
-->
|
|
|
|
|
<select id="selectListVO"
|
|
|
|
|
resultType="com.entity.vo.RuzhuanpaiVO" >
|
|
|
|
|
SELECT * FROM ruzhuanpai ruzhuanpai
|
|
|
|
|
<where> 1=1 ${ew.sqlSegment}</where>
|
|
|
|
|
resultType="com.entity.vo.RuzhuanpaiVO" >
|
|
|
|
|
<!-- 从 ruzhuanpai 表中查询所有列 -->
|
|
|
|
|
SELECT * FROM ruzhuanpai ruzhuanpai
|
|
|
|
|
<!-- where 标签用于动态构建查询条件,1 = 1 是为了方便后续拼接条件,
|
|
|
|
|
当 ${ew.sqlSegment} 有值时,会在 1 = 1 后面拼接具体的查询条件 -->
|
|
|
|
|
<where> 1=1 ${ew.sqlSegment}</where>
|
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!--
|
|
|
|
|
定义一个查询方法,方法名为 selectVO。
|
|
|
|
|
resultType 属性指定查询结果的类型为 com.entity.vo.RuzhuanpaiVO。
|
|
|
|
|
该方法用于从 ruzhuanpai 表中查询满足条件的单条记录,
|
|
|
|
|
条件通过 ${ew.sqlSegment} 动态传入。
|
|
|
|
|
-->
|
|
|
|
|
<select id="selectVO"
|
|
|
|
|
resultType="com.entity.vo.RuzhuanpaiVO" >
|
|
|
|
|
SELECT ruzhuanpai.* FROM ruzhuanpai ruzhuanpai
|
|
|
|
|
<where> 1=1 ${ew.sqlSegment}</where>
|
|
|
|
|
resultType="com.entity.vo.RuzhuanpaiVO" >
|
|
|
|
|
<!-- 从 ruzhuanpai 表中查询所有列 -->
|
|
|
|
|
SELECT ruzhuanpai.* FROM ruzhuanpai ruzhuanpai
|
|
|
|
|
<!-- where 标签用于动态构建查询条件,1 = 1 是为了方便后续拼接条件,
|
|
|
|
|
当 ${ew.sqlSegment} 有值时,会在 1 = 1 后面拼接具体的查询条件 -->
|
|
|
|
|
<where> 1=1 ${ew.sqlSegment}</where>
|
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
<select id="selectListView"
|
|
|
|
|
resultType="com.entity.view.RuzhuanpaiView" >
|
|
|
|
|
|
|
|
|
|
SELECT ruzhuanpai.* FROM ruzhuanpai ruzhuanpai
|
|
|
|
|
<where> 1=1 ${ew.sqlSegment}</where>
|
|
|
|
|
<!--
|
|
|
|
|
定义一个查询方法,方法名为 selectListView。
|
|
|
|
|
resultType 属性指定查询结果的类型为 com.entity.view.RuzhuanpaiView。
|
|
|
|
|
该方法用于从 ruzhuanpai 表中查询满足条件的所有记录,
|
|
|
|
|
以视图对象形式返回,条件通过 ${ew.sqlSegment} 动态传入。
|
|
|
|
|
-->
|
|
|
|
|
<select id="selectListView"
|
|
|
|
|
resultType="com.entity.view.RuzhuanpaiView" >
|
|
|
|
|
<!-- 从 ruzhuanpai 表中查询所有列 -->
|
|
|
|
|
SELECT ruzhuanpai.* FROM ruzhuanpai ruzhuanpai
|
|
|
|
|
<!-- where 标签用于动态构建查询条件,1 = 1 是为了方便后续拼接条件,
|
|
|
|
|
当 ${ew.sqlSegment} 有值时,会在 1 = 1 后面拼接具体的查询条件 -->
|
|
|
|
|
<where> 1=1 ${ew.sqlSegment}</where>
|
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!--
|
|
|
|
|
定义一个查询方法,方法名为 selectView。
|
|
|
|
|
resultType 属性指定查询结果的类型为 com.entity.view.RuzhuanpaiView。
|
|
|
|
|
该方法用于从 ruzhuanpai 表中查询满足条件的单条记录,
|
|
|
|
|
以视图对象形式返回,条件通过 ${ew.sqlSegment} 动态传入。
|
|
|
|
|
-->
|
|
|
|
|
<select id="selectView"
|
|
|
|
|
resultType="com.entity.view.RuzhuanpaiView" >
|
|
|
|
|
SELECT * FROM ruzhuanpai ruzhuanpai <where> 1=1 ${ew.sqlSegment}</where>
|
|
|
|
|
resultType="com.entity.view.RuzhuanpaiView" >
|
|
|
|
|
<!-- 从 ruzhuanpai 表中查询所有列 -->
|
|
|
|
|
SELECT * FROM ruzhuanpai ruzhuanpai
|
|
|
|
|
<!-- where 标签用于动态构建查询条件,1 = 1 是为了方便后续拼接条件,
|
|
|
|
|
当 ${ew.sqlSegment} 有值时,会在 1 = 1 后面拼接具体的查询条件 -->
|
|
|
|
|
<where> 1=1 ${ew.sqlSegment}</where>
|
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</mapper>
|
|
|
|
|
</mapper>
|