소스 검색

Stopped showing negative/zero JRIs for stock holding

Kenric Nugteren 1 년 전
부모
커밋
a0b3716807
1개의 변경된 파일6개의 추가작업 그리고 0개의 파일을 삭제
  1. 6 0
      prs.desktop/Panels/Products/Locations/StockHoldingRelocationWindow.xaml.cs

+ 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,