Пример #1
0
        public ITenantInformation GetTenantInformation()
        {
            var _client = this.GetActiveDirectoryClient();

            List<ITenantDetail> _tenantList = _client.TenantDetails
                .ExecuteAsync().Result.CurrentPage.ToList();

            var _tenantDetail = _tenantList.First();

            var _tenantInfo = new TenantInformation();
            _tenantInfo.DisplayName = _tenantDetail.DisplayName;
            _tenantInfo.TenantId = _tenantDetail.ObjectId;
            _tenantInfo.DirectorySyncEnabled = _tenantDetail.DirSyncEnabled;
            _tenantInfo.LastDirSyncTime = _tenantDetail.CompanyLastDirSyncTime;

            return _tenantInfo;
        }
Пример #2
0
        public ITenantInformation GetTenantInformation()
        {
            var _client = this.GetActiveDirectoryClient();

            List <ITenantDetail> _tenantList = _client.TenantDetails
                                               .ExecuteAsync().Result.CurrentPage.ToList();

            var _tenantDetail = _tenantList.First();

            var _tenantInfo = new TenantInformation();

            _tenantInfo.DisplayName          = _tenantDetail.DisplayName;
            _tenantInfo.TenantId             = _tenantDetail.ObjectId;
            _tenantInfo.DirectorySyncEnabled = _tenantDetail.DirSyncEnabled;
            _tenantInfo.LastDirSyncTime      = _tenantDetail.CompanyLastDirSyncTime;

            return(_tenantInfo);
        }