|
@@ -123,6 +123,13 @@ public class OrgServiceImpl implements OrgService {
|
|
|
orgEntity.setDomainName(domainName);
|
|
|
orgEntity.setRemark(remark);
|
|
|
|
|
|
+ if (StringUtils.isNotBlank(domainName)) {
|
|
|
+ OrgEntity tempOrg = orgRepo.findByParentIdIsNullAndDomainName(domainName);
|
|
|
+ if (null != tempOrg && !tempOrg.getId().equals(orgEntity.getId())) {
|
|
|
+ throw new StatusException("B-150004", "域名被占用");
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
OrgEntity saved = orgRepo.save(orgEntity);
|
|
|
|
|
|
Map<DynamicEnum, String> map = checkAndGetOrgProperties(properties);
|