Explorar o código

Improved validation handling for DynamicEditorForm

Kenric Nugteren hai 3 meses
pai
achega
e180a89aaf

+ 1 - 1
prs.desktop/Panels/DataEntry/DataEntryPanel.xaml.cs

@@ -360,7 +360,7 @@ public partial class DataEntryPanel : UserControl, IBasePanel, IDynamicEditorHos
         var cancel = new System.ComponentModel.CancelEventArgs();
         if (markasprocessed && (_entity is IDataEntryInstance scannable))
             scannable.DataEntered = DateTime.Now;
-        Editor.SaveItem(cancel, validate: false);
+        Editor.SaveItem(cancel);
 
         if (!cancel.Cancel)
         {

+ 1 - 1
prs.desktop/Panels/PurchaseOrders/SupplierPurchaseOrderPanel.xaml.cs

@@ -256,7 +256,7 @@ public partial class SupplierPurchaseOrderPanel : UserControl, IPanel<PurchaseOr
             var rows = Orders.SelectedRows;
 
             var cancel = new System.ComponentModel.CancelEventArgs();
-            PurchaseOrder.SaveItem(cancel, validate: false);
+            PurchaseOrder.SaveItem(cancel);
 
             if (!cancel.Cancel)
             {

+ 1 - 1
prs.desktop/Panels/Reservation Management/Purchasing/ReservationManagementPurchasing.xaml.cs

@@ -149,7 +149,7 @@ public partial class ReservationManagementPurchasing : UserControl
         Editor.OnOK += () =>
         {
             var cancel = new System.ComponentModel.CancelEventArgs();
-            Editor.SaveItem(cancel, validate: false);
+            Editor.SaveItem(cancel);
             Editor.HideButtons = true;
 
             SaveJRIPOIs();

+ 1 - 1
prs.desktop/Panels/Suppliers/Bills/SupplierBillPanel.xaml.cs

@@ -282,7 +282,7 @@ public partial class SupplierBillPanel : UserControl, IPanel<Bill>, IPropertiesP
             SaveApproval();
 
             var cancel = new System.ComponentModel.CancelEventArgs();
-            Bill.SaveItem(cancel, validate: false);
+            Bill.SaveItem(cancel);
             if (!cancel.Cancel)
             {
                 if(_editRows is not null && _bills is not null)