|
|
@@ -1,6 +1,7 @@
|
|
|
package com.vber.system.service.impl;
|
|
|
|
|
|
import cn.hutool.core.collection.CollUtil;
|
|
|
+import cn.hutool.core.util.ObjectUtil;
|
|
|
import cn.hutool.crypto.SecureUtil;
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
|
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
|
|
@@ -48,7 +49,6 @@ public class SysClientServiceImpl implements ISysClientService {
|
|
|
return vo;
|
|
|
}
|
|
|
|
|
|
-
|
|
|
/**
|
|
|
* 查询客户端管理
|
|
|
*/
|
|
|
@@ -130,7 +130,6 @@ public class SysClientServiceImpl implements ISysClientService {
|
|
|
.eq(SysClient::getClientId, clientId));
|
|
|
}
|
|
|
|
|
|
-
|
|
|
/**
|
|
|
* 批量删除客户端管理
|
|
|
*/
|
|
|
@@ -140,4 +139,18 @@ public class SysClientServiceImpl implements ISysClientService {
|
|
|
|
|
|
return baseMapper.deleteByIds(ids) > 0;
|
|
|
}
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 校验客户端key是否唯一
|
|
|
+ *
|
|
|
+ * @param client 客户端信息
|
|
|
+ * @return 结果
|
|
|
+ */
|
|
|
+ @Override
|
|
|
+ public boolean checkClickKeyUnique(SysClientBo client) {
|
|
|
+ boolean exist = baseMapper.exists(new LambdaQueryWrapper<SysClient>()
|
|
|
+ .eq(SysClient::getClientKey, client.getClientKey())
|
|
|
+ .ne(ObjectUtil.isNotNull(client.getId()), SysClient::getId, client.getId()));
|
|
|
+ return !exist;
|
|
|
+ }
|
|
|
}
|