void UpdateSeatBindings(RoomSeat Seat) { SelectedItemsCount = Items.Sum(i => i.Seats.Count(s => s.IsSelected)); Seat.Row.Refresh(); RemoveBookingCommand.RaiseCanExecuteChanged(); FreeBookingCommand.RaiseCanExecuteChanged(); PaidBookingCommand.RaiseCanExecuteChanged(); }
public void GivenCorrectId_WhenRemoveArticle_ShouldFinishSuccessfully() { // Arrange var LRemoveBookingCommand = new RemoveBookingCommand { Id = Guid.NewGuid() }; // Act var LValidator = new RemoveBookingCommandValidator(); var LResult = LValidator.Validate(LRemoveBookingCommand); // Assert LResult.Errors.Should().BeEmpty(); }
public void GivenIncorrectId_WhenRemoveArticle_ShouldThrowError() { // Arrange var LRemoveArticleCommand = new RemoveBookingCommand { Id = Guid.Empty }; // Act var LValidator = new RemoveBookingCommandValidator(); var LResult = LValidator.Validate(LRemoveArticleCommand); // Assert LResult.Errors.Count.Should().Be(1); LResult.Errors[0].ErrorCode.Should().Be(nameof(ValidationCodes.REQUIRED)); }
void RowSelect(RoomRow row) { RemoveBookingCommand.RaiseCanExecuteChanged(); FreeBookingCommand.RaiseCanExecuteChanged(); PaidBookingCommand.RaiseCanExecuteChanged(); }