Ejemplo n.º 1
0
        public void Insert(string hash, CollectionDirection direction, Card card)
        {
            var deck = repository.GetDeck(hash);

            cardsHelper.Insert(direction, deck.Cards, card);
            repository.Update(deck);
        }
Ejemplo n.º 2
0
        public void Insert(string hash, string pileHash, CollectionDirection direction, Card card)
        {
            var deck = _deckRepository.GetDeck(hash);
            var pile = deck.Piles.FirstOrDefault(x => x.Hash == pileHash);

            _cardsHelper.Insert(direction, pile.Cards, card);
            _deckRepository.Update(deck);
        }