fix-添加平台

This commit is contained in:
xl
2024-06-28 14:09:10 +08:00
parent 23bac4ff19
commit 0d09c59e03

View File

@@ -79,10 +79,10 @@ public class ReturnCommissionPlatformInformationServiceImpl extends ServiceImpl<
@Override
public Boolean add(ReturnCommissionPlatformInformationEditRequest request) {
ReturnCommissionPlatformInformation byPlatformSn = getByPlatformSn(request.getPlatformSn());
if (ObjectUtil.isNotNull(byPlatformSn)) {
throw new LxkException("平台编码重复");
}
//ReturnCommissionPlatformInformation byPlatformSn = getByPlatformSn(request.getPlatformSn());
//if (ObjectUtil.isNotNull(byPlatformSn)) {
// throw new LxkException("平台编码重复");
//}
if (plagiarismCheck(request.getName(), null)) {
throw new LxkException(StrUtil.format("平台名称:{}存在重复", request.getName()));
}
@@ -133,9 +133,9 @@ public class ReturnCommissionPlatformInformationServiceImpl extends ServiceImpl<
throw new LxkException("平台编码重复");
}
}
if (!platformInformation.getName().equals(request.getName()) && plagiarismCheck(request.getName(), null)) {
throw new LxkException(StrUtil.format("平台名称:{}存在重复", request.getName()));
}
// if (!platformInformation.getName().equals(request.getName()) && plagiarismCheck(request.getName(), null)) {
// throw new LxkException(StrUtil.format("平台名称:{}存在重复", request.getName()));
// }
if (!LxkDateUtil.checkDateFormat(request.getStartTime(), DateConstants.DATE_FORMAT)) {
throw new LxkException(StrUtil.format("{}时间格式错误请传2000-01-01 01:01:01的格式", request.getStartTime()));
}