コード例 #1
0
        // Add the gift card code to the checkout and update the order summary when the request completes.
        private async Task AddGiftCardCodeAsync(string giftCardCode)
        {
            ShowLoadingDialog(Resource.String.syncing_data);
            try
            {
                await SampleApplication.AddGiftCardAsync(giftCardCode);

                UpdateOrderSummary();
            }
            catch (ShopifyException ex)
            {
                Toast.MakeText(this, GetString(Resource.String.gift_card_error, giftCardCode), ToastLength.Long).Show();
            }
            DismissLoadingDialog();
        }