Browse Source

tenant code check update

pull/2/head
qiaozhanwei 6 years ago
parent
commit
74175cbdd7
  1. 2
      escheduler-api/src/main/java/cn/escheduler/api/service/TenantService.java

2
escheduler-api/src/main/java/cn/escheduler/api/service/TenantService.java

@ -80,7 +80,7 @@ public class TenantService extends BaseService{
Tenant tenant = new Tenant(); Tenant tenant = new Tenant();
Date now = new Date(); Date now = new Date();
if (!tenantCode.matches("^[0-9a-zA-Z_.]{1,}$") || tenantCode.startsWith("-")){ if (!tenantCode.matches("^[0-9a-zA-Z_.-]{1,}$") || tenantCode.startsWith("-") || tenantCode.startsWith(".")){
putMsg(result, Status.VERIFY_TENANT_CODE_ERROR); putMsg(result, Status.VERIFY_TENANT_CODE_ERROR);
return result; return result;
} }

Loading…
Cancel
Save