Пример #1
0
        private void GuestCheckAsync()
        {
            Guest.GuestName = GuestName;

            if (!String.IsNullOrEmpty(Guest.GuestName))
            {
                int residentId = (from res in residents where res.Username == (string)Application.Current.Properties["Username"] select res.ResidentID).First();
                Guest.CheckedIn = true;
                checkinTime     = DateTime.Now.ToString("dd MMMM yyyy HH:mm");
                OnPropertyChanged("CheckinTime");
                Guest.CheckinTime = checkinTime;
                Guest.ResID       = residentId;
                database.postNewGuestAsync(Guest);
            }
        }