コード例 #1
0
        protected async System.Threading.Tasks.Task Grid0RowSelect(Anno.Models.Sample.OrderDetail args)
        {
            var result = await DialogService.OpenAsync <EditOrderDetail>("Edit Order Detail", new Dictionary <string, object>() { { "Id", args.Id } });

            grid0.Reload();

            await InvokeAsync(() => { StateHasChanged(); });
        }
        protected async System.Threading.Tasks.Task Load()
        {
            var sampleGetOrdersResult = await Sample.GetOrders();

            getOrdersResult = sampleGetOrdersResult.Value.AsODataEnumerable();

            var sampleGetProductsResult = await Sample.GetProducts();

            getProductsResult = sampleGetProductsResult.Value.AsODataEnumerable();

            orderdetail = new Anno.Models.Sample.OrderDetail();
        }
        protected async System.Threading.Tasks.Task Form0Submit(Anno.Models.Sample.OrderDetail args)
        {
            try
            {
                var sampleUpdateOrderDetailResult = await Sample.UpdateOrderDetail(id : Id, orderDetail : orderdetail);

                DialogService.Close(orderdetail);
            }
            catch (Exception sampleUpdateOrderDetailException)
            {
                NotificationService.Notify(NotificationSeverity.Error, $"Error", $"Unable to update OrderDetail");
            }
        }