|
|
@@ -155,9 +155,11 @@ public class SysDictTypeServiceImpl implements ISysDictTypeService
|
|
|
public int updateDictType(SysDictType dict)
|
|
|
{
|
|
|
SysDictType oldDict = dictTypeMapper.selectDictTypeById(dict.getDictId());
|
|
|
- dictDataMapper.updateDictDataType(oldDict.getDictType(), dict.getDictType());
|
|
|
- int row = dictTypeMapper.updateDictType(dict);
|
|
|
- return row;
|
|
|
+ if (dict!=null&&oldDict!=null){
|
|
|
+ dictDataMapper.updateDictDataType(oldDict.getDictType(), dict.getDictType());
|
|
|
+ return dictTypeMapper.updateDictType(dict);
|
|
|
+ }
|
|
|
+ return 0;
|
|
|
}
|
|
|
|
|
|
/**
|