This commit is contained in:
owenchen committed 2026-10-23 15:15:53 +08:00
1 parent 6c86c59bdc
commit 31de6c4cd6
15 files changed
+1001 -666

No files matched your search

@@ -22,8 +22,16 @@ namespace CloudBuilder.Security.Service.Subscriber
SecurityUserActorEntity ent = new SecurityUserActorEntity();
ent.UserName = ((SecurityUserEntity)eventData.EventSource).UserName;
ent.ActorName = SecurityUserPolicy.SECURITY_USER_BASE_ACTOR;
repository.InsertNow(ent);
//第一个注册用户就是管理员
if (ent.UserName == SecurityPrefixPolicy.SECURITY_USER_FORMAT.Substring(0, SecurityPrefixPolicy.SECURITY_USER_FORMAT.Length - 1) + "1")
{
ent = new SecurityUserActorEntity();
ent.UserName = ((SecurityUserEntity)eventData.EventSource).UserName;
ent.ActorName = SecurityUserPolicy.SYSTEM_ACTOR;
repository.InsertNow(ent);
}
}
}
}