public IEnumerable <object> GetReadableListOfGuestRequest(IEnumerable <GuestRequest> fromList = null) { if (fromList == null) { fromList = getListGuestRequest(); } return(from item in fromList where true select new { GuestRequestKey = item.GuestRequestKey, PrivateName = item.PrivateName, FamilyName = item.FamilyName, MailAddress = item.MailAddress, Status = HebrewEnum.GuestReqStatus(item.Status), RegistrationDate = item.RegistrationDate.ToString("dd/MM/yyyy"), EntryDate = item.EntryDate.ToString("dd/MM/yyyy"), ReleaseDate = item.ReleaseDate.ToString("dd/MM/yyyy"), Area = HebrewEnum.Area(item.Area), Type = HebrewEnum.GuestReqType(item.Type), Adults = item.Adults, Children = item.Children, Pool = HebrewEnum.options(item.Pool), Jacuzzi = HebrewEnum.options(item.Jacuzzi), Garden = HebrewEnum.options(item.Garden), ChildrensAttractions = HebrewEnum.options(item.ChildrensAttractions) }); }
private void lsvUpdateHostingUnit_SelectionChanged(object sender, SelectionChangedEventArgs e) { if (lsvUpdateHostingUnit.SelectedIndex != -1) { hostingUnit = listHostingUnits[lsvUpdateHostingUnit.SelectedIndex]; HostingUnitUpdateGrid.DataContext = hostingUnit; cmbHostingUnitUpdateArea.Text = HebrewEnum.Area(hostingUnit.Area); } }
public List <object> GetReadableListOfHostingUnits(IEnumerable <HostingUnit> fromList = null) { if (fromList == null) { fromList = getListHostingUnit(); } return((from item in fromList select new { Area = HebrewEnum.Area(item.Area), HostingUnitKey = item.HostingUnitKey, HostingUnitName = item.HostingUnitName, Owner = item.Owner, }).ToList <object>()); }