From 7705e3245ad407ba226a30a0ce06caf0bbfb6c8b Mon Sep 17 00:00:00 2001 From: "liang.chao" <1360241448@qq.com> Date: Mon, 23 Sep 2024 17:46:05 +0800 Subject: [PATCH] =?UTF-8?q?=E9=87=8D=E5=BA=86=E9=9C=80=E6=B1=82=E5=8F=98?= =?UTF-8?q?=E6=9B=B4=E4=BB=A3=E7=A0=81=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../sgzb/base/service/impl/MaTypeServiceImpl.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/sgzb-modules/sgzb-material/src/main/java/com/bonus/sgzb/base/service/impl/MaTypeServiceImpl.java b/sgzb-modules/sgzb-material/src/main/java/com/bonus/sgzb/base/service/impl/MaTypeServiceImpl.java index 9d63f52..4d55eb1 100644 --- a/sgzb-modules/sgzb-material/src/main/java/com/bonus/sgzb/base/service/impl/MaTypeServiceImpl.java +++ b/sgzb-modules/sgzb-material/src/main/java/com/bonus/sgzb/base/service/impl/MaTypeServiceImpl.java @@ -60,9 +60,9 @@ public class MaTypeServiceImpl implements ITypeService { MaType maType1 = maTypeMapper.selectMaTypeByTypeId(parentId); String level; if (maType1 == null) { - level = "0"; + level = "0"; } else { - level = maType1.getLevel(); + level = maType1.getLevel(); } maType.setLevel(String.valueOf(Integer.parseInt(level) + 1)); maType.setCreateTime(DateUtils.getNowDate()); @@ -147,7 +147,7 @@ public class MaTypeServiceImpl implements ITypeService { typeFileMapper.insertMaTypeFile(typeFile1); } // 库管员配置 - if (maType.getKeeperUserId() >= 0L) { + if (maType.getKeeperUserId() != null) { maTypeMapper.deleteKeeperByTypeId(typeId); MaTypeKeeper typeKeeper = new MaTypeKeeper(); typeKeeper.setUserId(maType.getKeeperUserId()); @@ -158,7 +158,7 @@ public class MaTypeServiceImpl implements ITypeService { } // 维修员配置 - if (maType.getRepairUserId() >= 0L) { + if (maType.getRepairUserId() != null) { maTypeMapper.deleteTypeByTypeId(typeId); MaTypeRepair typeRepair = new MaTypeRepair(); typeRepair.setUserId(maType.getRepairUserId()); @@ -335,7 +335,7 @@ public class MaTypeServiceImpl implements ITypeService { @Override public List selectParentId(Long typeId, Integer level) { - return maTypeMapper.selectParentId(typeId,level); + return maTypeMapper.selectParentId(typeId, level); } /**