Ejemplo n.º 1
0
        public CustomisationImportDialog(XrmCustomisationImportService service, IDialogController dialogController, XrmRecordService lookupService)
            : base(service, dialogController, lookupService, nextButtonLabel: "Import")
        {
            var validationDialog = new CustomisationImportValidationDialog(this, Request);

            SubDialogs = SubDialogs.Union(new[] { validationDialog }).ToArray();
        }
Ejemplo n.º 2
0
 protected void StartNextAction()
 {
     if (SubDialogs.Any() && _currentSubDialogIndex < SubDialogs.Count())
     {
         _currentSubDialogIndex++;
         SubDialogs.ElementAt(_currentSubDialogIndex - 1).LoadDialog();
     }
     else if (!DialogCompletionCommit)
     {
         DialogCompletionCommit = true;
         CompleteDialog();
     }
     else
     {
         if (ParentDialog != null)
         {
             ParentDialog.StartNextAction();
         }
         else
         {
             ApplicationController.LogEvent(DialogEventName + " Completed", GetPropertiesForCompletedLog());
             if (OverideCompletionScreenMethod != null)
             {
                 OverideCompletionScreenMethod();
             }
             else
             {
                 Controller.ShowCompletionScreen(this);
             }
         }
     }
 }
        public ImportRecordsDialog(ImportRecordsService service, IDialogController dialogController)
            : base(service, dialogController)
        {
            var validationDialog = new ImportXmlValidationDialog(this, Request);

            SubDialogs = SubDialogs.Union(new[] { validationDialog }).ToArray();
        }
Ejemplo n.º 4
0
        protected override void CompleteDialogExtention()
        {
            ApplicationController.ResolveType <ISettingsManager>().SaveSettingsObject(SettingsObject);
            ApplicationController.RegisterInstance <TSettingsInterface>(SettingsObject);
            if (CompletionMessage == null)
            {
                CompletionMessage = "The Settings Have Been Saved";
            }

            if (OverideCompletionScreenMethod == null && !HasParentDialog)
            {
                //okay in this case let set the dialog to
                //keep appending the settings entry to itself when completed
                OverideCompletionScreenMethod = ()
                                                =>
                {
                    //append new dialog for the setting entry and
                    //trigger this dialog to start it
                    var configEntryDialog = new ObjectEntryDialog(SettingsObject, this, ApplicationController, LookupService,
                                                                  null, OnSave, null, saveButtonLabel: "Save", cancelButtonLabel: "Close", initialMessage: "Changes Have Been Saved");
                    SubDialogs             = SubDialogs.Union(new[] { configEntryDialog }).ToArray();
                    DialogCompletionCommit = false;
                    StartNextAction();
                };
            }
        }
        public TestSavedRequestDialog(IDialogController controller)
            : base(new TestSavedRequestDialogService(), controller)
        {
            var validationDialog = new ValidationDisplayDialog(this);

            SubDialogs = SubDialogs.Union(new[] { validationDialog }).ToArray();
        }
Ejemplo n.º 6
0
        public ImportExcelDialog(ImportExcelService service,
                                 IDialogController dialogController, XrmRecordService lookupService)
            : base(service, dialogController, lookupService)
        {
            var validationDialog = new ImportExcelValidationDialog(this, Request);

            SubDialogs = SubDialogs.Union(new[] { validationDialog }).ToArray();
        }
        public ImportSqlDialog(ImportSqlService service,
                               IDialogController dialogController, XrmRecordService lookupService)
            : base(service, dialogController, lookupService, nextButtonLabel: "Import")
        {
            SetTabLabel("Import SQL");
            var validationDialog = new ImportSqlValidationDialog(this, Request);

            SubDialogs = SubDialogs.Union(new[] { validationDialog }).ToArray();
        }