コード例 #1
0
 private void HandleSupplierInsertMessage(Message message)
 {
     SupplierListItemViewData supplier =
 message.Payload as SupplierListItemViewData;
     if (supplier != null && supplier.SupplierID == ((SupplierListItemViewData)ViewData).SupplierID)
     {
         message.HandledStatus = MessageHandledStatus.HandledCompleted;
         ActivateViewModel();
     }
 }
コード例 #2
0
 private void RefreshList(Message message)
 {
     RefreshList();
     message.HandledStatus = MessageHandledStatus.HandledContinue;
 }
コード例 #3
0
 private void RefreshListAfterDelete(Message message)
 {
     RefreshListAfterAction();
     message.HandledStatus = MessageHandledStatus.HandledContinue;
 }
コード例 #4
0
 private void HandleCategorySelectedForEditMessage(Message message)
 {
     CategoryListItemViewData category =
 message.Payload as CategoryListItemViewData;
     if (category != null && category.CategoryID == ((CategoryListItemViewData)ViewData).CategoryID)
     {
         message.HandledStatus = MessageHandledStatus.HandledCompleted;
         ActivateViewModel();
     }
 }
コード例 #5
0
 private void HandleProductInsertMessage(Message message)
 {
     ProductListItemViewData product =
 message.Payload as ProductListItemViewData;
     if (product != null && product.ProductID == ((ProductListItemViewData)ViewData).ProductID)
     {
         message.HandledStatus = MessageHandledStatus.HandledCompleted;
         ActivateViewModel();
     }
 }
コード例 #6
0
 /// <summary>
 /// If somewhere someone selects a Employee for editing and this 
 /// Edit ViewModel is already
 /// Editing that Employee, then abort the message, and make the View active
 /// </summary>
 /// <param name="message"></param>
 private void HandleCustomerSelectedForEditMessage(Message message)
 {
     CustomerListItemViewData customer =
 message.Payload as CustomerListItemViewData;
     if (customer != null && customer.CustomerID == ((CustomerListItemViewData)ViewData).CustomerID)
     {
         message.HandledStatus = MessageHandledStatus.HandledCompleted;
         ActivateViewModel();
     }
 }
コード例 #7
0
 /// <summary>
 /// If somewhere someone selects a Employee for editing and this 
 /// Edit ViewModel is already
 /// Editing that Employee, then abort the message, and make the View active
 /// </summary>
 /// <param name="message"></param>
 private void HandleEmployeeSelectedForEditMessage(Message message)
 {
     EmployeeListItemViewData employee =
 message.Payload as EmployeeListItemViewData;
     if (employee != null && employee.EmployeeID == ((EmployeeListItemViewData)ViewData).EmployeeID)
     {
         message.HandledStatus = MessageHandledStatus.HandledCompleted;
         ActivateViewModel();
     }
 }