using Furion; namespace Myshipping.Core; /// /// 用户管理 /// public static class UserManager { /// /// 用户id /// public static long UserId => long.Parse(App.User.FindFirst(ClaimConst.CLAINM_USERID)?.Value); /// /// 账号 /// public static string Account => App.User.FindFirst(ClaimConst.CLAINM_ACCOUNT)?.Value; /// /// 昵称 /// public static string Name => App.User.FindFirst(ClaimConst.CLAINM_NAME)?.Value; /// /// 是否超级管理员 /// public static bool IsSuperAdmin => App.User.FindFirst(ClaimConst.CLAINM_SUPERADMIN)?.Value == ((int)AdminType.SuperAdmin).ToString(); /// /// 是否租户管理员 /// public static bool IsTenantAdmin => App.User.FindFirst(ClaimConst.CLAINM_SUPERADMIN)?.Value == ((int)AdminType.Admin).ToString(); /// /// 租户ID /// public static string TENANT_ID => App.User.FindFirst(ClaimConst.TENANT_ID)?.Value; /// /// 租户名称 /// public static string TENANT_NAME => App.User.FindFirst(ClaimConst.TENANT_NAME)?.Value; /// /// 大简云userid /// public static string DjyUserId => App.User.FindFirst(ClaimConst.DjyUserId)?.Value; }