You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
41 lines
1.4 KiB
XML
41 lines
1.4 KiB
XML
<?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.zhiyun.zhiyun03.invite.mapper.InviteMapper">
|
|
<update id="updateDownloadById">
|
|
update invite
|
|
<set >
|
|
<if test="inviteName != null" >
|
|
invite_name=#{inviteName},
|
|
</if>
|
|
<if test="inviteBrief != null" >
|
|
invite_brief=#{inviteBrief},
|
|
</if>
|
|
<if test="inviteUrl != null" >
|
|
invite_url=#{inviteUrl},
|
|
</if>
|
|
<if test="dirId != null" >
|
|
dir_id=#{dirId},
|
|
</if>
|
|
<if test="inviteImg != null" >
|
|
invite_img=#{inviteImg}
|
|
</if>
|
|
</set>
|
|
<where>
|
|
<if test="id!=null">
|
|
id = #{id}
|
|
</if>
|
|
</where>
|
|
|
|
|
|
</update>
|
|
<select id="queryInvite" resultType="com.zhiyun.zhiyun03.invite.vo.InviteVo">
|
|
select i.id,i.invite_name,i.invite_brief,i.invite_url,d.dir_name
|
|
from invite as i
|
|
inner join
|
|
(select id,dir_name from directory) as d
|
|
on i.dir_id = d.id
|
|
</select>
|
|
<select id="selectByName" resultType="java.lang.Integer">
|
|
select count(1) from invite where invite_name =#{inviteName}
|
|
</select>
|
|
</mapper> |