分区前端页面修改
This commit is contained in:
parent
d79d9fdebe
commit
47e879bd19
|
@ -12,4 +12,7 @@ public class PartQuery extends PartVO {
|
||||||
@ApiModelProperty("分区ID列表")
|
@ApiModelProperty("分区ID列表")
|
||||||
private List<Long> ids;
|
private List<Long> ids;
|
||||||
|
|
||||||
|
@ApiModelProperty("父分区ID列表")
|
||||||
|
private List<Long> parentIds;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -74,5 +74,5 @@ public interface PartMapper
|
||||||
|
|
||||||
public List<Long> selectIdByQuery(@Param("query") PartQuery query);
|
public List<Long> selectIdByQuery(@Param("query") PartQuery query);
|
||||||
|
|
||||||
List<PartVO> selectChildren(PartVO partVO);
|
List<PartVO> selectChildren(List<Long> ids);
|
||||||
}
|
}
|
||||||
|
|
|
@ -44,6 +44,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
<if test="query.picture != null and query.picture != ''"> and picture = #{query.picture}</if>
|
<if test="query.picture != null and query.picture != ''"> and picture = #{query.picture}</if>
|
||||||
<if test="query.storeName != null and query.storeName != ''"> and bs.store_name like concat('%', #{query.storeName}, '%') </if>
|
<if test="query.storeName != null and query.storeName != ''"> and bs.store_name like concat('%', #{query.storeName}, '%') </if>
|
||||||
<if test="query.parentName != null and query.parentName != ''"> and bp_parent.part_name like concat('%', #{query.parentName}, '%') </if>
|
<if test="query.parentName != null and query.parentName != ''"> and bp_parent.part_name like concat('%', #{query.parentName}, '%') </if>
|
||||||
|
<if test="query.parentIds != null and query.parentIds.size() > 0">
|
||||||
|
and bp.parent_id in
|
||||||
|
<foreach collection="query.parentIds" item="ids" open="(" separator="," close=")">
|
||||||
|
#{ids}
|
||||||
|
</foreach>
|
||||||
|
</if>
|
||||||
${@com.ruoyi.framework.util.DataScopeUtil@create(query.scope)
|
${@com.ruoyi.framework.util.DataScopeUtil@create(query.scope)
|
||||||
.userSetAlias("bs.user_id")
|
.userSetAlias("bs.user_id")
|
||||||
.storeAlias("bp.store_id",query.storePermissions)
|
.storeAlias("bp.store_id",query.storePermissions)
|
||||||
|
|
|
@ -114,6 +114,10 @@ public class PartServiceImpl implements PartService
|
||||||
@Override
|
@Override
|
||||||
public int deletePartByPartIds(List<Long> partIds)
|
public int deletePartByPartIds(List<Long> partIds)
|
||||||
{
|
{
|
||||||
|
PartQuery query = new PartQuery();
|
||||||
|
query.setParentIds(partIds);
|
||||||
|
List<PartVO> list = partMapper.selectPartList(query);
|
||||||
|
ServiceUtil.assertion(!list.isEmpty(),"当前区域有子分区,不允许删除");
|
||||||
return partMapper.deletePartByPartIds(partIds);
|
return partMapper.deletePartByPartIds(partIds);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user