提交 03ee0646 authored 作者: liupengfei's avatar liupengfei

--no commit message

上级 387db30c
......@@ -91,7 +91,7 @@ public class AcupointLibrarySerivceImpl extends BaseServiceImpl<AcupointLibrary,
}else {
if(StringUtils.isNotBlank(form.getName())){
Example example = new Example(AcupointLibrary.class);
example.createCriteria().andEqualTo("name", form.getName()).andEqualTo("id", entity.getId());
example.createCriteria().andEqualTo("name", form.getName()).andNotEqualTo("id", entity.getId());
Integer count = mapper.selectCountByExample(example);
if(count > 0) {
throw new BaseException("该穴位已存在");
......
......@@ -85,7 +85,7 @@ public class MeridianLibrarySerivceImpl extends BaseServiceImpl<MeridianLibrary,
//修改
if(StringUtils.isNotBlank(form.getName())){
Example example = new Example(MeridianLibrary.class);
example.createCriteria().andEqualTo("name", form.getName()).andEqualTo("id", entity.getId());
example.createCriteria().andEqualTo("name", form.getName()).andNotEqualTo("id", entity.getId());
Integer count = mapper.selectCountByExample(example);
if(count > 0) {
throw new BaseException("该经络已存在");
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论