Exemple #1
0
        private void preLoad(long periodId, long?jobId)
        {
            ShowBusyIndicator("در حال دریافت اطلاعات...");
            periodService.GetPeriod((res, exp) => appController.BeginInvokeOnDispatcher(() =>
            {
                HideBusyIndicator();
                if (exp == null)
                {
                    Period = res;
                }
            }), periodId);


            if (!jobId.HasValue)
            {
                return;
            }

            jobInPeriodService.GetJobInPeriod((res, exp) => appController.BeginInvokeOnDispatcher(() =>
            {
                if (exp == null)
                {
                    SelectedJobInPeriod = res;
                }
            }), periodId, jobId.Value);
        }
Exemple #2
0
        private void preLoad(long periodId)
        {
            ShowBusyIndicator();

            periodService.GetPeriod((res, exp) => appController.BeginInvokeOnDispatcher(() =>
            {
                if (exp == null)
                {
                    Period = res;
                }
                else
                {
                    appController.HandleException(exp);
                }
            }), periodId);
        }
Exemple #3
0
 public void Load(PeriodDto periodParam, ActionEnum actionTypeParam)
 {
     actionType = actionTypeParam;
     if (actionType == ActionEnum.ModifyPeriod)
     {
         ShowBusyIndicator();
         periodService.GetPeriod((res, exp) =>
         {
             //HideBusyIndicator();
             //if (exp == null)
             //    Period = res;
             //else
             //    appController.HandleException(exp);
         },
                                 periodParam.Id);
     }
 }
Exemple #4
0
 public void DoAction(PeriodListVM vm)
 {
     periodService.GetPeriod((res, exp) => pmsController.BeginInvokeOnDispatcher(() =>
     {
         if (exp == null)
         {
             if (res != null)
             {
                 periodController.ShowPeriodStatusView(res, ActionType.GetPeriodInitializingInquiryStatus);
             }
             else
             {
                 pmsController.ShowMessage("اطلاعات دوره جهت ارسال به صفحه ویرایش معتبر نمی باشد");
             }
         }
         else
         {
             pmsController.HandleException(exp);
         }
     }), vm.SelectedPeriod.Id);
 }
Exemple #5
0
        public void Load(PeriodDTO periodParam, ActionType actionTypeParam)
        {
            actionType = actionTypeParam;
            if (actionType == ActionType.ModifyPeriod)
            {
                ShowBusyIndicator("در حال دریافت اطلاعات");
                periodService.GetPeriod((res, exp) => appController.BeginInvokeOnDispatcher(() =>
                {
                    HideBusyIndicator();
                    if (exp == null)
                    {
                        Period           = res;
                        Period.StartDate = res.StartDate;
                    }

                    else
                    {
                        appController.HandleException(exp);
                    }
                }),
                                        periodParam.Id);
            }
        }