mirror of
https://gitee.com/pnoker/iot-dc3.git
synced 2026-11-03 03:32:08 +08:00
feat: .
This commit is contained in:
+2
-2
@@ -59,7 +59,7 @@ public class BlackIpServiceImpl implements BlackIpService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void delete(String id) {
|
||||
public void delete(Long id) {
|
||||
BlackIp blackIp = selectById(id);
|
||||
if (ObjectUtil.isNull(blackIp)) {
|
||||
throw new NotFoundException("The ip does not exist in the blacklist");
|
||||
@@ -80,7 +80,7 @@ public class BlackIpServiceImpl implements BlackIpService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public BlackIp selectById(String id) {
|
||||
public BlackIp selectById(Long id) {
|
||||
return blackIpMapper.selectById(id);
|
||||
}
|
||||
|
||||
|
||||
+2
-2
@@ -54,7 +54,7 @@ public class ResourceServiceImpl implements ResourceService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void delete(String id) {
|
||||
public void delete(Long id) {
|
||||
selectById(id);
|
||||
if (resourceMapper.deleteById(id) < 1) {
|
||||
throw new DeleteException("The resource delete failed");
|
||||
@@ -70,7 +70,7 @@ public class ResourceServiceImpl implements ResourceService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public Resource selectById(String id) {
|
||||
public Resource selectById(Long id) {
|
||||
Resource resource = resourceMapper.selectById(id);
|
||||
if (ObjectUtil.isNull(resource)) {
|
||||
throw new NotFoundException();
|
||||
|
||||
+2
-2
@@ -63,7 +63,7 @@ public class RoleResourceBindServiceImpl implements RoleResourceBindService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void delete(String id) {
|
||||
public void delete(Long id) {
|
||||
selectById(id);
|
||||
if (bindMapper.deleteById(id) < 1) {
|
||||
throw new DeleteException("The role resource bind delete failed");
|
||||
@@ -79,7 +79,7 @@ public class RoleResourceBindServiceImpl implements RoleResourceBindService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public RoleResourceBind selectById(String id) {
|
||||
public RoleResourceBind selectById(Long id) {
|
||||
RoleResourceBind bind = bindMapper.selectById(id);
|
||||
if (ObjectUtil.isNull(bind)) {
|
||||
throw new NotFoundException();
|
||||
|
||||
+2
-2
@@ -57,7 +57,7 @@ public class RoleUserBindServiceImpl implements RoleUserBindService {
|
||||
|
||||
|
||||
@Override
|
||||
public RoleUserBind selectById(String id) {
|
||||
public RoleUserBind selectById(Long id) {
|
||||
RoleUserBind roleUserBind = roleUserBindMapper.selectById(id);
|
||||
if (ObjectUtil.isNull(roleUserBind)) {
|
||||
throw new NotFoundException();
|
||||
@@ -90,7 +90,7 @@ public class RoleUserBindServiceImpl implements RoleUserBindService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void delete(String id) {
|
||||
public void delete(Long id) {
|
||||
selectById(id);
|
||||
if (roleUserBindMapper.deleteById(id) < 1) {
|
||||
throw new DeleteException("The role user bind delete failed");
|
||||
|
||||
+2
-2
@@ -56,7 +56,7 @@ public class TenantBindServiceImpl implements TenantBindService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void delete(String id) {
|
||||
public void delete(Long id) {
|
||||
TenantBind tenantBind = selectById(id);
|
||||
if (ObjectUtil.isNull(tenantBind)) {
|
||||
throw new NotFoundException("The tenant bind does not exist");
|
||||
@@ -77,7 +77,7 @@ public class TenantBindServiceImpl implements TenantBindService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public TenantBind selectById(String id) {
|
||||
public TenantBind selectById(Long id) {
|
||||
TenantBind tenantBind = tenantBindMapper.selectById(id);
|
||||
if (ObjectUtil.isNull(tenantBind)) {
|
||||
throw new NotFoundException();
|
||||
|
||||
+2
-2
@@ -59,7 +59,7 @@ public class TenantServiceImpl implements TenantService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void delete(String id) {
|
||||
public void delete(Long id) {
|
||||
Tenant tenant = selectById(id);
|
||||
if (ObjectUtil.isNull(tenant)) {
|
||||
throw new NotFoundException("The tenant does not exist");
|
||||
@@ -80,7 +80,7 @@ public class TenantServiceImpl implements TenantService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public Tenant selectById(String id) {
|
||||
public Tenant selectById(Long id) {
|
||||
return tenantMapper.selectById(id);
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -89,7 +89,7 @@ public class UserLoginServiceImpl implements UserLoginService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public UserLogin selectById(String id) {
|
||||
public UserLogin selectById(Long id) {
|
||||
return userLoginMapper.selectById(id);
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -87,7 +87,7 @@ public class UserPasswordServiceImpl implements UserPasswordService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public UserPassword selectById(String id) {
|
||||
public UserPassword selectById(Long id) {
|
||||
return userPasswordMapper.selectById(id);
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -126,7 +126,7 @@ public class UserServiceImpl implements UserService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public User selectById(String id) {
|
||||
public User selectById(Long id) {
|
||||
return userMapper.selectById(id);
|
||||
}
|
||||
|
||||
|
||||
+2
-2
@@ -113,7 +113,7 @@ public class DeviceServiceImpl implements DeviceService {
|
||||
*/
|
||||
@Override
|
||||
@Transactional
|
||||
public void delete(String id) {
|
||||
public void delete(Long id) {
|
||||
Device device = selectById(id);
|
||||
if (ObjectUtil.isNull(device)) {
|
||||
throw new NotFoundException("The device does not exist");
|
||||
@@ -169,7 +169,7 @@ public class DeviceServiceImpl implements DeviceService {
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Override
|
||||
public Device selectById(String id) {
|
||||
public Device selectById(Long id) {
|
||||
Device device = deviceMapper.selectById(id);
|
||||
if (ObjectUtil.isNull(device)) {
|
||||
throw new NotFoundException();
|
||||
|
||||
+2
-2
@@ -78,7 +78,7 @@ public class DriverAttributeConfigServiceImpl implements DriverAttributeConfigSe
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Override
|
||||
public void delete(String id) {
|
||||
public void delete(Long id) {
|
||||
DriverAttributeConfig driverAttributeConfig = selectById(id);
|
||||
if (ObjectUtil.isNull(driverAttributeConfig)) {
|
||||
throw new NotFoundException("The driver attribute config does not exist");
|
||||
@@ -121,7 +121,7 @@ public class DriverAttributeConfigServiceImpl implements DriverAttributeConfigSe
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Override
|
||||
public DriverAttributeConfig selectById(String id) {
|
||||
public DriverAttributeConfig selectById(Long id) {
|
||||
DriverAttributeConfig driverAttributeConfig = driverAttributeConfigMapper.selectById(id);
|
||||
if (ObjectUtil.isNull(driverAttributeConfig)) {
|
||||
throw new NotFoundException();
|
||||
|
||||
+2
-2
@@ -65,7 +65,7 @@ public class DriverAttributeServiceImpl implements DriverAttributeService {
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Override
|
||||
public void delete(String id) {
|
||||
public void delete(Long id) {
|
||||
DriverAttribute driverAttribute = selectById(id);
|
||||
if (ObjectUtil.isNull(driverAttribute)) {
|
||||
throw new NotFoundException("The driver attribute does not exist");
|
||||
@@ -92,7 +92,7 @@ public class DriverAttributeServiceImpl implements DriverAttributeService {
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Override
|
||||
public DriverAttribute selectById(String id) {
|
||||
public DriverAttribute selectById(Long id) {
|
||||
DriverAttribute driverAttribute = driverAttributeMapper.selectById(id);
|
||||
if (ObjectUtil.isNull(driverAttribute)) {
|
||||
throw new NotFoundException();
|
||||
|
||||
+2
-2
@@ -77,7 +77,7 @@ public class DriverServiceImpl implements DriverService {
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Override
|
||||
public void delete(String id) {
|
||||
public void delete(Long id) {
|
||||
DriverDO entityDO = selectById(id);
|
||||
if (ObjectUtil.isNull(entityDO)) {
|
||||
throw new NotFoundException("The driver does not exist");
|
||||
@@ -104,7 +104,7 @@ public class DriverServiceImpl implements DriverService {
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Override
|
||||
public DriverDO selectById(String id) {
|
||||
public DriverDO selectById(Long id) {
|
||||
DriverDO entityDO = driverMapper.selectById(id);
|
||||
if (ObjectUtil.isNull(entityDO)) {
|
||||
throw new NotFoundException();
|
||||
|
||||
+2
-2
@@ -85,7 +85,7 @@ public class PointAttributeConfigServiceImpl implements PointAttributeConfigServ
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Override
|
||||
public void delete(String id) {
|
||||
public void delete(Long id) {
|
||||
PointAttributeConfig pointAttributeConfig = selectById(id);
|
||||
if (ObjectUtil.isNull(pointAttributeConfig)) {
|
||||
throw new NotFoundException("The point attribute config does not exist");
|
||||
@@ -129,7 +129,7 @@ public class PointAttributeConfigServiceImpl implements PointAttributeConfigServ
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Override
|
||||
public PointAttributeConfig selectById(String id) {
|
||||
public PointAttributeConfig selectById(Long id) {
|
||||
PointAttributeConfig pointAttributeConfig = pointAttributeConfigMapper.selectById(id);
|
||||
if (ObjectUtil.isNull(pointAttributeConfig)) {
|
||||
throw new NotFoundException();
|
||||
|
||||
+2
-2
@@ -65,7 +65,7 @@ public class PointAttributeServiceImpl implements PointAttributeService {
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Override
|
||||
public void delete(String id) {
|
||||
public void delete(Long id) {
|
||||
PointAttribute pointAttribute = selectById(id);
|
||||
if (ObjectUtil.isNull(pointAttribute)) {
|
||||
throw new NotFoundException("The point attribute does not exist");
|
||||
@@ -92,7 +92,7 @@ public class PointAttributeServiceImpl implements PointAttributeService {
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Override
|
||||
public PointAttribute selectById(String id) {
|
||||
public PointAttribute selectById(Long id) {
|
||||
PointAttribute pointAttribute = pointAttributeMapper.selectById(id);
|
||||
if (ObjectUtil.isNull(pointAttribute)) {
|
||||
throw new NotFoundException();
|
||||
|
||||
+2
-2
@@ -83,7 +83,7 @@ public class PointServiceImpl implements PointService {
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Override
|
||||
public void delete(String id) {
|
||||
public void delete(Long id) {
|
||||
Point point = selectById(id);
|
||||
if (ObjectUtil.isNull(point)) {
|
||||
throw new NotFoundException("The point does not exist");
|
||||
@@ -126,7 +126,7 @@ public class PointServiceImpl implements PointService {
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Override
|
||||
public Point selectById(String id) {
|
||||
public Point selectById(Long id) {
|
||||
Point point = pointMapper.selectById(id);
|
||||
if (ObjectUtil.isNull(point)) {
|
||||
throw new NotFoundException();
|
||||
|
||||
+2
-2
@@ -67,7 +67,7 @@ public class ProfileBindServiceImpl implements ProfileBindService {
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Override
|
||||
public void delete(String id) {
|
||||
public void delete(Long id) {
|
||||
ProfileBind profileBind = selectById(id);
|
||||
if (ObjectUtil.isNull(profileBind)) {
|
||||
throw new NotFoundException("The profile bind does not exist");
|
||||
@@ -115,7 +115,7 @@ public class ProfileBindServiceImpl implements ProfileBindService {
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
@Override
|
||||
public ProfileBind selectById(String id) {
|
||||
public ProfileBind selectById(Long id) {
|
||||
ProfileBind profileBind = profileBindMapper.selectById(id);
|
||||
if (ObjectUtil.isNull(profileBind)) {
|
||||
throw new NotFoundException();
|
||||
|
||||
+2
-2
@@ -76,7 +76,7 @@ public class ProfileServiceImpl implements ProfileService {
|
||||
|
||||
|
||||
@Override
|
||||
public void delete(String id) {
|
||||
public void delete(Long id) {
|
||||
try {
|
||||
pointService.selectByProfileId(id);
|
||||
throw new ServiceException("The profile already bound by the point");
|
||||
@@ -107,7 +107,7 @@ public class ProfileServiceImpl implements ProfileService {
|
||||
}
|
||||
|
||||
@Override
|
||||
public Profile selectById(String id) {
|
||||
public Profile selectById(Long id) {
|
||||
Profile profile = profileMapper.selectById(id);
|
||||
if (ObjectUtil.isNull(profile)) {
|
||||
throw new NotFoundException();
|
||||
|
||||
Reference in New Issue
Block a user