コード例 #1
0
        protected override async Task Remove(CashQRCodeViewModel item)
        {
            List.Remove(item);
            await AsyncDatabase.GetItemsAsync <CashQRCode>();

            await AsyncDatabase.RemoveItemAsync <CashQRCode>(item.CashQRCode.Id);
        }
コード例 #2
0
        protected override async Task InitializeListFromDatabase()
        {
            await AsyncDatabase.CreateTableAsync <CashQRCode>();

            var cashQRCodes = await AsyncDatabase.GetItemsAsync <CashQRCode>();

            List = new ObservableCollection <CashQRCodeViewModel>(
                cashQRCodes.Select(c => GetCashQRCodeVM(c)));
        }