Repository navigation
Feat/token claims - #1486
Merged
Merged
Feat/token claims#1486
Conversation
原逻辑用 ObjectSid 的 RID 冒充工号,与真实工号无关。 变更: - 工号取 AD employeeNumber,移除 SID RID 兜底;无值时写空以清除存量 RID 脏数据 - 超长 employeeNumber 直接丢弃并告警(截断后仍是错值) - employeeType 映射为 Position 聚合并绑定 Staff.PositionId,按名匹配/创建,缓存去重,超长截断 - SyncLdapUserAsync 两个循环各加 per-user try-catch,单账号异常不再中断整批同步 - Position 创建失败时 Detach 实体,避免 ChangeTracker 污染后续账号导致级联失败 - Staff.JobNumber 放宽为可空(对齐 Name/IdCard 的 AllowNull 模式) - 列宽常量收敛至 BusinessConsts,EF 配置与同步逻辑共用
修正了 QueryHandler.cs 文件中的中文注释乱码问题,提升代码可读性。用户信息查询方法由 FindAsync 替换为 FindWithIncludAsync,确保包含角色和员工信息。生成用户声明时同步角色、团队和员工相关声明,优化角色合并逻辑,保证角色ID集合去重且完整,提升声明信息的准确性和一致性。
|
wzh425
approved these changes
Sep 22, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



token claims