예제 #1
0
 private void _ok(object ignore)
 {
     if (_result == null)
     {
         _result = "";
     }
     ShouldClose = true;
     _pcs.NotifyChange(nameof(ShouldClose));
     OnPromptClosed(new PromptClosedEventArgs(Result));
 }
예제 #2
0
 private void _payment_changed(object sender, PropertyChangedEventArgs pcea)
 {
     if (pcea.PropertyName == nameof(_paymentEntity.Ammount))
     {
         _unlockSaveIfNeeded();
     }
     _pcs.NotifyChange(nameof(PaymentMode));
 }
예제 #3
0
 private void _clientChanged(object sender, PropertyChangedEventArgs pcea)
 {
     try
     {
         if (pcea.PropertyName != "FirstName" && pcea.PropertyName != "LastName")
         {
             return;
         }
         _computeTitle(_clientEntity);
         _pcs.NotifyChange("Title");
     }
     catch (Exception ex)
     {
         Logger.Log(ex);
     }
 }
예제 #4
0
        private void _selectClient(SearchClientsViewModel searchClientsVM)
        {
            ClientEntity selectedClient = null;

            if (SearchClientVMsView.CurrentPosition != -1)
            {
                selectedClient = (SearchClientVMsView.CurrentItem as SearchClientViewModel).ClientEntity;
            }
            else
            {
                selectedClient = _subClientSelected;
            }
            ClientSelected?.Invoke(this, selectedClient);
            ShouldClose = true;
            _pcs.NotifyChange(nameof(ShouldClose));
        }
예제 #5
0
 private void _selectBooking(object ignore)
 {
     try
     {
         if (_clientBookingsView.CurrentPosition != -1)
         {
             BookingEntity selectedBookingEntity = _clientBookingsView.CurrentItem as BookingEntity;
             BookingSelected?.Invoke(this, selectedBookingEntity);
             ShouldClose = true;
             _pcs.NotifyChange(nameof(ShouldClose));
         }
     }
     catch (Exception ex)
     {
         Logger.Log(ex);
     }
 }
예제 #6
0
 private void _clientChanged(object sender, PropertyChangedEventArgs pcea)
 {
     _unlockSaveAndSumUpIfNeeded();
     _pcs.NotifyChange("Title");
 }
예제 #7
0
 private void _displayMore(SearchClientViewModel searchClientsVM)
 {
     _displayMoreToggled = !_displayMoreToggled;
     _pcs.NotifyChange(nameof(ShowSubs));
     _pcs.NotifyChange(nameof(DisplayMoreImage));
 }