Beispiel #1
0
 private void RemoveStockFromSaleMethod()
 {
     try
     {
         if (SelectedStock != null && StockSaleList.Contains(SelectedStock))
         {
             TransactionDetails.Amount -= SelectedStock.SaleValue;
             StockList.Add(SelectedStock);
             StockSaleList.Remove(SelectedStock);
             SelectedStock = new skStock();
         }
     }
     catch (Exception E)
     {
         ExepionLogger.Logger.LogException(E);
         ExepionLogger.Logger.Show(E);
     }
 }
Beispiel #2
0
 private void ClearStockFromSaleMethod()
 {
     try
     {
         if (StockSaleList.Count() > 0)
         {
             foreach (var item in StockSaleList)
             {
                 StockList.Add(item);
             }
             StockSaleList.Clear();
             TransactionDetails.Amount = 0;
         }
     }
     catch (Exception E)
     {
         ExepionLogger.Logger.LogException(E);
         ExepionLogger.Logger.Show(E);
     }
 }
Beispiel #3
0
 private void AddStockToSaleMethod()
 {
     try
     {
         if (SelectedStock != null)
         {
             SelectedStock.SaleValue    = StockItemSaleValue;
             TransactionDetails.Amount += SelectedStock.SaleValue;
             StockSaleList.Add(_SelectedStock);
             StockList.Remove(StockList.FirstOrDefault(x => x.Stockid == SelectedStock.Stockid));
             SelectedStock      = new skStock();
             StockItemSaleValue = 0;
         }
     }
     catch (Exception E)
     {
         ExepionLogger.Logger.LogException(E);
         ExepionLogger.Logger.Show(E);
     }
 }