Пример #1
0
        public async Task BoughtItem(ShoppingItems item)
        {
            item.Bought = true;
            await client.GetTable <ShoppingItems>().UpdateAsync(item);

            ShoppingList.Remove(item);
        }
Пример #2
0
        public async Task ItemAdd(Entry item)
        {
            if (!string.IsNullOrEmpty(item.Text))
            {
                var newItem = new ShoppingItems {
                    Bought = false, Item = item.Text
                };
                await client.GetTable <ShoppingItems>().InsertAsync(newItem);

                ShoppingList.Insert(0, newItem);
            }
        }