コード例 #1
0
 /// <summary>
 /// This is where you should call your service.
 /// Batch parameter contains the selected order IDs
 /// that should be processed in this service call.
 /// </summary>
 protected override void ExecuteForBatch(List <string> batch)
 {
     BasicSamplesService.OrderBulkAction(new OrderBulkActionRequest
     {
         OrderIDs = batch.Select(x => int.Parse(x, 10)).ToList()
     },
                                         response =>
     {
         SuccessCount = SuccessCount + batch.Count;
     },
                                         options: new ServiceCallOptions
     {
         BlockUI = false,
         OnError = response =>
         {
             ErrorCount = ErrorCount + batch.Count;
         },
         OnCleanup = ServiceCallCleanup
     });
 }
コード例 #2
0
ファイル: ChartInDialog.cs プロジェクト: hkudug/Serene
        protected override void OnDialogOpen()
        {
            base.OnDialogOpen();

            BasicSamplesService.OrdersByShipper(new OrdersByShipperRequest(), response =>
            {
                areaChart = CreateAreaChart(new
                {
                    element   = this.IdPrefix + "Chart",
                    resize    = true,
                    parseTime = false,
                    data      = response.Values,
                    xkey      = "Month",
                    ykeys     = response.ShipperKeys,
                    labels    = response.ShipperLabels,
                    hideHover = "auto"
                });
            });

            this.element.Closest(".ui-dialog").Bind("resize", delegate { Arrange(); });
        }