protected OrgDashboardViewModel CreateDashboardViewModel(MyJobLeads.DomainModel.Entities.Organization org) { var model = new OrgDashboardViewModel { AlottedLicenseCount = org.FpPilotLicenseCount, RemainingLicenseCount = org.FpPilotLicenseCount - org.FpUsedPilotLicenses.Count }; foreach (var user in org.FpUsedPilotLicenses) { model.LicensedUsers.Add(new OrgDashboardViewModel.PilotLicenseUser { Id = user.Id, Name = user.FullName, Email = user.Email, GrantedDate = user.LicenseGrantDate }); } return(model); }
protected OrgDashboardViewModel CreateDashboardViewModel(MyJobLeads.DomainModel.Entities.Organization org) { var model = new OrgDashboardViewModel { AlottedLicenseCount = org.FpPilotLicenseCount, RemainingLicenseCount = org.FpPilotLicenseCount - org.FpUsedPilotLicenses.Count }; foreach (var user in org.FpUsedPilotLicenses) { model.LicensedUsers.Add(new OrgDashboardViewModel.PilotLicenseUser { Id = user.Id, Name = user.FullName, Email = user.Email, GrantedDate = user.LicenseGrantDate }); } return model; }