Просмотр исходного кода

Stopped showing negative/zero JRIs for stock holding

Kenric Nugteren 1 год назад
Родитель
Сommit
a0b3716807

+ 6 - 0
prs.desktop/Panels/Products/Locations/StockHoldingRelocationWindow.xaml.cs

@@ -155,6 +155,12 @@ public partial class StockHoldingRelocationWindow : Window, INotifyPropertyChang
         foreach(var item in rItems)
         {
             var qty = item.ID != Guid.Empty ? quantities.GetValueOrDefault(item.ID) : item.Qty;
+            if(item.ID != Guid.Empty && qty <= 0)
+            {
+                // We can't do anything with this; it shouldn't be shown.
+                continue;
+            }
+
             var newItem = new StockHoldingRelocationItem
             {
                 Issued = 0,