Exemple #1
0
        private void DisplayDealView(object obj)
        {
            SelectedObsInstruPosition = (ObsInstruPosition)obj;

            if (SelectedObsInstruPosition == null)
            {
                return;
            }

            ObsDeals.Clear();

            foreach (var deal in _deals)
            {
                if (deal?.InstrumentId == SelectedObsInstruPosition?.InstruRic)
                {
                    ObsDeals.Add(deal);
                }
            }

            var positionDetails = new PositionDetailsWin {
                DataContext = this
            };

            positionDetails.Show();
        }
Exemple #2
0
        public void RemoveDeal(object obj)
        {
            _dbManager.RemoveDeal(SelectedDeal.DealId);
            CloseAction();
            _currentPosDico.Clear();
            ObsPositions.Clear();
            ObsDeals.Clear();
            LoadCurrentDeals();

            foreach (var deal in _deals)
            {
                if (deal?.InstrumentId == SelectedObsInstruPosition?.InstruRic)
                {
                    ObsDeals.Add(deal);
                }
            }
        }