数据字典
This commit is contained in:
parent
63ecf171fa
commit
32c068b260
|
@ -60,7 +60,7 @@ public class DictDataServiceImpl extends BaseService<DictDataMapper, DictData> i
|
||||||
@Override
|
@Override
|
||||||
public AjaxResult editDictData(String id, DictDataRequest dictDataRequest) {
|
public AjaxResult editDictData(String id, DictDataRequest dictDataRequest) {
|
||||||
if (StrUtil.isBlank(id)) return AjaxResult.fail("id不能为空");
|
if (StrUtil.isBlank(id)) return AjaxResult.fail("id不能为空");
|
||||||
String message = checkDictData("", dictDataRequest);
|
String message = checkDictData(id, dictDataRequest);
|
||||||
if (StrUtil.isNotBlank(message)) return AjaxResult.fail(message);
|
if (StrUtil.isNotBlank(message)) return AjaxResult.fail(message);
|
||||||
DictData dictData = getById(id);
|
DictData dictData = getById(id);
|
||||||
if (ObjectUtil.isNull(dictData)) return AjaxResult.fail("该字典数据不存在");
|
if (ObjectUtil.isNull(dictData)) return AjaxResult.fail("该字典数据不存在");
|
||||||
|
|
|
@ -55,7 +55,7 @@ public class DictTypeServiceImpl extends BaseService<DictTypeMapper, DictType> i
|
||||||
@Override
|
@Override
|
||||||
public AjaxResult editDictType(String id, DictTypeRequest dictTypeRequest) {
|
public AjaxResult editDictType(String id, DictTypeRequest dictTypeRequest) {
|
||||||
if (StrUtil.isBlank(id)) return AjaxResult.fail("id不能为空");
|
if (StrUtil.isBlank(id)) return AjaxResult.fail("id不能为空");
|
||||||
String message = checkDictType("", dictTypeRequest);
|
String message = checkDictType(id, dictTypeRequest);
|
||||||
if (StrUtil.isNotBlank(message)) return AjaxResult.fail(message);
|
if (StrUtil.isNotBlank(message)) return AjaxResult.fail(message);
|
||||||
DictType dictType = getById(id);
|
DictType dictType = getById(id);
|
||||||
if (ObjectUtil.isNull(dictType)) return AjaxResult.fail("该字典类型不存在");
|
if (ObjectUtil.isNull(dictType)) return AjaxResult.fail("该字典类型不存在");
|
||||||
|
|
Loading…
Reference in New Issue