コード例 #1
0
ファイル: User.cs プロジェクト: pkhodos/testapsconnector2
        public static User GetObject(Setting setting, HttpRequest request, OaUser oaUser)
        {
            var oaTenant    = Oa.GetResource <OaTenant>(setting, request, oaUser.TenantLink.ApsLink.Id);
            var oaAdminUser = Oa.GetResource <OaAdminUser>(setting, request, oaUser.AdminUserLink.ApsLink.Id);

            return(new User
            {
                ApsId = oaUser.AdminUserLink.ApsLink.Id,
                UserId = oaUser.UserId,
                Email = oaAdminUser.Email,
                Tenant = Tenant.GetObject(setting, request, oaTenant)
            });
        }
コード例 #2
0
        public static Tenant GetObject(Setting setting, HttpRequest request, OaTenant oaTenant)
        {
            var oaApplication = Oa.GetResource <OaApplication>(setting, request, oaTenant.AppLink.ApsLink.Id);
            var oaAccount     = Oa.GetResource <OaAccount>(setting, request, oaTenant.AccountLink.ApsLink.Id);

            return(new Tenant
            {
                Id = oaTenant.Aps.Id,
                CompanyName = oaAccount.CompanyName,
                App = Application.GetObject(oaApplication),

                // resources
                UsersLimit = oaTenant.UsersLimit.Limit,
                DiskspaceLimit = oaTenant.DiskspaceLimit.Limit,
                DevicesLimit = oaTenant.DevicesLimit.Limit
            });
        }
コード例 #3
0
        public static Tenant GetObject(Setting setting, HttpRequest request, string oaTenantId)
        {
            var oaTenant = Oa.GetResource <OaTenant>(setting, request, oaTenantId);

            return(GetObject(setting, request, oaTenant));
        }
コード例 #4
0
ファイル: User.cs プロジェクト: pkhodos/testapsconnector2
        public static User GetObject(Setting setting, HttpRequest request, string oaUserId)
        {
            var oaUser = Oa.GetResource <OaUser>(setting, request, oaUserId);

            return(GetObject(setting, request, oaUser));
        }