示例#1
0
        private DateTime?GetBarcodeDateByStatus(List <string> stageIds)
        {
            var barcode = Barcodes.FirstOrDefault(a => stageIds.Contains(a.Stage.Id));

            if (barcode != null)
            {
                return(barcode.DateCreated);
            }

            return(null);
        }
        public void DeleteBarcode(string barcode)
        {
            try
            {
                var barcodeToRemove = Barcodes.FirstOrDefault(f => f == barcode);

                Barcodes.Remove(barcodeToRemove);
            }
            catch (Exception ex)
            {
                MessageBox.Show(JsonConvert.SerializeObject(ex), "Ошибка", MessageBoxButton.OK, MessageBoxImage.Error);
                Log.Error(ex);
            }
        }