Пример #1
0
        internal void ItemQuantityIncreased(BuyCell item)
        {
            if (allItems != null)
            {
                var obj = allItems.First(x => x.Name == item.Text);
                if (obj != null)
                {
                    obj.Quantity += 1;
                }
            }

            UpdateBuyItemsList();
        }
Пример #2
0
        internal void ItemBought(BuyCell item)
        {
            if (allItems != null)
            {
                var obj = allItems.First(x => x.Name == item.Text);
                if (obj != null)
                {
                    obj.Buy      = false;
                    obj.Quantity = 1;
                }
                App.Database.UpdateItem((Item)obj);
            }

            UpdateBuyItemsList();
            MessagingCenter.Send <BuyPage>(this, "UpdateAddItemsListFromBuyList");
        }