调整字典类型新增校验
This commit is contained in:
parent
3b628d4450
commit
b422110c3c
|
|
@ -131,6 +131,11 @@ public class SettingDictTypeServiceImpl implements ISettingDictTypeService {
|
|||
Assert.isNull(dictTypeMapper.selectOne(new QueryWrapper<DictType>()
|
||||
.select("id")
|
||||
.eq("dict_name", dictTypeParam.getDictName())
|
||||
.eq("is_delete", 0)
|
||||
.last("limit 1")), "字典名称已存在!");
|
||||
|
||||
Assert.isNull(dictTypeMapper.selectOne(new QueryWrapper<DictType>()
|
||||
.select("id")
|
||||
.eq("dict_type", dictTypeParam.getDictType())
|
||||
.eq("is_delete", 0)
|
||||
.last("limit 1")), "字典类型已存在!");
|
||||
|
|
@ -163,6 +168,11 @@ public class SettingDictTypeServiceImpl implements ISettingDictTypeService {
|
|||
Assert.isNull(dictTypeMapper.selectOne(new QueryWrapper<DictType>()
|
||||
.ne("id", dictTypeParam.getId())
|
||||
.eq("dict_name", dictTypeParam.getDictName())
|
||||
.eq("is_delete", 0)
|
||||
.last("limit 1")), "字典类型已存在!");
|
||||
|
||||
Assert.isNull(dictTypeMapper.selectOne(new QueryWrapper<DictType>()
|
||||
.ne("id", dictTypeParam.getId())
|
||||
.eq("dict_type", dictTypeParam.getDictType())
|
||||
.eq("is_delete", 0)
|
||||
.last("limit 1")), "字典类型已存在!");
|
||||
|
|
|
|||
Loading…
Reference in New Issue