优化商品类别和机构的删除操作

This commit is contained in:
季圣华
2021-11-09 23:49:21 +08:00
parent 15ee7455f6
commit 9dc9785111
5 changed files with 38 additions and 10 deletions

View File

@@ -60,6 +60,17 @@
#{parentId,jdbcType=BIGINT}, #{sort,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR},
#{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP})
</insert>
<select id="getOrganizationByParentIds" resultMap="com.jsh.erp.datasource.mappers.OrganizationMapper.BaseResultMap">
select * from jsh_organization
where
1=1
and ifnull(delete_flag,'0') !='1'
and parent_id in (
<foreach collection="ids" item="id" separator=",">
#{id}
</foreach>
)
</select>
<update id="batchDeleteOrganizationByIds">
update jsh_organization
set update_Time=#{updateTime},delete_flag='1'