Example #1
0
        private void SetLodgerTab()
        {
            ISLodger lodger = DBLodgers.GetLodgerById(user.Id);

            _SetLodgerInfo(lodger);

            List <ISCard> cards = DBCards.GetCardsById(user.Id);

            if (cardsGrid.Rows.Count > 0)
            {
                cardsGrid.Rows.Clear();
            }

            if (cards.Count > 0)
            {
                for (int i = 0; i < cards.Count; i++)
                {
                    ISCard c              = cards[i];
                    int    id             = c.Id;
                    string cardNumber     = c.CardNumber;
                    string expirationDate = c.ExpirationDate;

                    cardsGrid.Rows.Add(new string[] { (i + 1).ToString(), id.ToString(), cardNumber, expirationDate });
                }
            }
        }