|
@@ -4,9 +4,9 @@
|
|
|
|
|
|
<resultMap type="com.bosshand.virgo.core.model.MgrRole" id="mgrRoleResult">
|
|
|
<id column="id" property="id"/>
|
|
|
- <result column="code" property="code"/>
|
|
|
<result column="name" property="name"/>
|
|
|
- <result column="memo" property="memo"/>
|
|
|
+ <result column="responsible" property="responsible"/>
|
|
|
+ <result column="responsibility" property="responsibility"/>
|
|
|
<result column="projectId" property="projectId"/>
|
|
|
<result column="organizationId" property="organizationId"/>
|
|
|
<result column="parentId" property="parentId"/>
|
|
@@ -21,7 +21,7 @@
|
|
|
</select>
|
|
|
|
|
|
<insert id="insert" parameterType="com.bosshand.virgo.core.model.MgrRole" useGeneratedKeys="true" keyProperty="id">
|
|
|
- INSERT INTO mgr_role(code, name, memo, projectId, organizationId, parentId) VALUES (#{code}, #{name}, #{memo}, #{projectId}, #{organizationId}, #{parentId})
|
|
|
+ INSERT INTO mgr_role(responsible, name, responsibility, projectId, organizationId, parentId) VALUES (#{responsible}, #{name}, #{responsibility}, #{projectId}, #{organizationId}, #{parentId})
|
|
|
</insert>
|
|
|
|
|
|
<delete id="delete">
|
|
@@ -29,7 +29,13 @@
|
|
|
</delete>
|
|
|
|
|
|
<update id="update" parameterType="com.bosshand.virgo.core.model.MgrRole">
|
|
|
- UPDATE mgr_role SET name = #{name} WHERE id = #{id}
|
|
|
+ UPDATE mgr_role
|
|
|
+ <trim prefix="set" suffixOverrides=",">
|
|
|
+ <if test="name!=null">name=#{name},</if>
|
|
|
+ <if test="responsible!=null">responsible=#{responsible},</if>
|
|
|
+ <if test="responsibility!=null">responsibility=#{responsibility},</if>
|
|
|
+ </trim>
|
|
|
+ WHERE id = #{id}
|
|
|
</update>
|
|
|
|
|
|
</mapper>
|