|
@@ -43,11 +43,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
</sql>
|
|
|
<select id="checkDeptNameUnique" resultMap="SysDeptResult">
|
|
|
<include refid="selectDeptVo"/>
|
|
|
- where dept_name=#{deptName} and parent_id = #{parentId} and del_flag = '0' limit 1
|
|
|
+ where dept_name=#{deptName} and parent_id = #{parentId} and tenant_id = #{tenantId} and del_flag = '0' limit 1
|
|
|
</select>
|
|
|
<select id="checkDeptCodeUnique" resultMap="SysDeptResult">
|
|
|
<include refid="selectDeptVo"/>
|
|
|
- where dept_code=#{deptCode} and parent_id = #{parentId} and del_flag = '0' limit 1
|
|
|
+ where dept_code=#{deptCode} and parent_id = #{parentId} and tenant_id = #{tenantId} and del_flag = '0' limit 1
|
|
|
</select>
|
|
|
<select id="selectDeptById" parameterType="Long" resultMap="SysDeptResult">
|
|
|
select d.type,d.dept_id,d.is_work_section,d.is_sort_packaging,d.tenant_id,d.parent_id, d.ancestors, d.dept_name,d.dept_code, d.order_num, d.phone, d.email, d.status,d.equiment_flag,d.auto_allocation,
|
|
@@ -147,7 +147,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="supplierId != null">supplier_id = #{supplierId},</if>
|
|
|
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
|
|
|
<if test="type != null">type = #{type},</if>
|
|
|
- <if test="jdId != null">jd_id = #{jdId}</if>
|
|
|
+ <if test="jdId != null">jd_id = #{jdId},</if>
|
|
|
update_time = sysdate()
|
|
|
</set>
|
|
|
where dept_id = #{deptId}
|