|
@@ -12,6 +12,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<result property="englishName" column="english_name" />
|
|
<result property="englishName" column="english_name" />
|
|
<result property="link" column="link" />
|
|
<result property="link" column="link" />
|
|
<result property="introduce" column="introduce" />
|
|
<result property="introduce" column="introduce" />
|
|
|
|
+ <result property="sort" column="sort" />
|
|
<result property="createTime" column="create_time" />
|
|
<result property="createTime" column="create_time" />
|
|
<result property="createBy" column="create_by" />
|
|
<result property="createBy" column="create_by" />
|
|
<result property="updateTime" column="update_time" />
|
|
<result property="updateTime" column="update_time" />
|
|
@@ -19,7 +20,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</resultMap>
|
|
</resultMap>
|
|
|
|
|
|
<sql id="selectConsultationVo">
|
|
<sql id="selectConsultationVo">
|
|
- select id, affiliation, location, chinese_name, english_name, link, introduce, create_time, create_by, update_time, update_by from vr_consultation
|
|
|
|
|
|
+ select id, affiliation, location, chinese_name, english_name, link, introduce, sort, create_time, create_by, update_time, update_by from vr_consultation
|
|
</sql>
|
|
</sql>
|
|
|
|
|
|
<select id="selectConsultationList" parameterType="Consultation" resultMap="ConsultationResult">
|
|
<select id="selectConsultationList" parameterType="Consultation" resultMap="ConsultationResult">
|
|
@@ -31,7 +32,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<if test="englishName != null and englishName != ''"> and english_name like concat('%', #{englishName}, '%')</if>
|
|
<if test="englishName != null and englishName != ''"> and english_name like concat('%', #{englishName}, '%')</if>
|
|
<if test="link != null and link != ''"> and link like concat('%', #{link}, '%')</if>
|
|
<if test="link != null and link != ''"> and link like concat('%', #{link}, '%')</if>
|
|
<if test="introduce != null and introduce != ''"> and introduce like concat('%', #{introduce}, '%')</if>
|
|
<if test="introduce != null and introduce != ''"> and introduce like concat('%', #{introduce}, '%')</if>
|
|
|
|
+ <if test="sort != null and sort != ''"> and sort = #{sort}</if>
|
|
</where>
|
|
</where>
|
|
|
|
+ ORDER BY sort
|
|
</select>
|
|
</select>
|
|
|
|
|
|
<select id="selectConsultationById" parameterType="Long" resultMap="ConsultationResult">
|
|
<select id="selectConsultationById" parameterType="Long" resultMap="ConsultationResult">
|
|
@@ -53,6 +56,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<if test="chineseName != null and chineseName != ''">chinese_name,</if>
|
|
<if test="chineseName != null and chineseName != ''">chinese_name,</if>
|
|
<if test="introduce != null and introduce != ''">introduce,</if>
|
|
<if test="introduce != null and introduce != ''">introduce,</if>
|
|
<if test="link != null and link != ''">link,</if>
|
|
<if test="link != null and link != ''">link,</if>
|
|
|
|
+ <if test="sort != null and sort != ''">sort,</if>
|
|
<if test="createBy != null and createBy != ''">create_by,</if>
|
|
<if test="createBy != null and createBy != ''">create_by,</if>
|
|
<if test="createTime != null ">create_time,</if>
|
|
<if test="createTime != null ">create_time,</if>
|
|
<if test="updateBy != null and updateBy != ''">update_by,</if>
|
|
<if test="updateBy != null and updateBy != ''">update_by,</if>
|
|
@@ -65,6 +69,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<if test="chineseName != null and chineseName != ''">#{chineseName},</if>
|
|
<if test="chineseName != null and chineseName != ''">#{chineseName},</if>
|
|
<if test="introduce != null and introduce != ''">#{introduce},</if>
|
|
<if test="introduce != null and introduce != ''">#{introduce},</if>
|
|
<if test="link != null and link != ''">#{link},</if>
|
|
<if test="link != null and link != ''">#{link},</if>
|
|
|
|
+ <if test="sort != null and sort != ''">#{sort},</if>
|
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
|
<if test="createTime != null ">#{createTime},</if>
|
|
<if test="createTime != null ">#{createTime},</if>
|
|
<if test="updateBy != null and updateBy != ''">#{updateBy},</if>
|
|
<if test="updateBy != null and updateBy != ''">#{updateBy},</if>
|
|
@@ -73,11 +78,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
</insert>
|
|
</insert>
|
|
|
|
|
|
<insert id="insertConsultationDataList" parameterType="java.util.List">
|
|
<insert id="insertConsultationDataList" parameterType="java.util.List">
|
|
- INSERT INTO vr_consultation (affiliation, location, chinese_name, english_name, link, introduce, create_by,create_time)
|
|
|
|
|
|
+ INSERT INTO vr_consultation (affiliation, location, chinese_name, english_name, link, introduce, sort, create_by,create_time)
|
|
VALUES
|
|
VALUES
|
|
<foreach collection="list" item="item" separator=",">
|
|
<foreach collection="list" item="item" separator=",">
|
|
(#{item.affiliation}, #{item.location}, #{item.chineseName}, #{item.englishName}, #{item.link}, #{item.introduce},
|
|
(#{item.affiliation}, #{item.location}, #{item.chineseName}, #{item.englishName}, #{item.link}, #{item.introduce},
|
|
- #{item.createBy}, #{item.createTime})
|
|
|
|
|
|
+ #{item.sort},#{item.createBy}, #{item.createTime})
|
|
</foreach>
|
|
</foreach>
|
|
</insert>
|
|
</insert>
|
|
|
|
|
|
@@ -90,6 +95,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<if test="chineseName != null and chineseName != ''">chinese_name = #{chineseName},</if>
|
|
<if test="chineseName != null and chineseName != ''">chinese_name = #{chineseName},</if>
|
|
<if test="introduce != null and introduce != ''">introduce = #{introduce},</if>
|
|
<if test="introduce != null and introduce != ''">introduce = #{introduce},</if>
|
|
<if test="link != null and link != ''">link = #{link},</if>
|
|
<if test="link != null and link != ''">link = #{link},</if>
|
|
|
|
+ <if test="sort != null and sort != ''">sort = #{sort},</if>
|
|
<if test="createBy != null and createBy != ''">create_by = #{createBy},</if>
|
|
<if test="createBy != null and createBy != ''">create_by = #{createBy},</if>
|
|
<if test="createTime != null ">create_time = #{createTime},</if>
|
|
<if test="createTime != null ">create_time = #{createTime},</if>
|
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|