Example #1
0
        public void WizardEvent(WizardEventArgs WizardEventArgs)
        {
            switch (WizardEventArgs.EventType)
            {
            case EventType.Init:
                wiz = (AddPluginPackageWizard)WizardEventArgs.Wizard;
                break;

            case EventType.Active:
                try
                {
                    wiz.PluginPackage = new PluginPackage(wiz.Folder);
                }
                catch (Exception ex)
                {
                    Reporter.ToUser(eUserMsgKey.StaticErrorMessage, string.Format("Failed to find the Plugin package, error: '{0}'", ex));
                }
                if (wiz.PluginPackage != null)
                {
                    mPluginPackage       = wiz.PluginPackage;
                    xIDTextBox.Text      = mPluginPackage.PluginId;
                    xVersionTextBox.Text = mPluginPackage.PluginPackageVersion;
                    FolderTextBox.BindControl(mPluginPackage, nameof(PluginPackage.Folder));
                    mPluginPackage.LoadServicesFromJSON();
                    ServicesGrid.ItemsSource    = mPluginPackage.Services;
                    ActionsDataGrid.ItemsSource = mPluginPackage.Services[0].Actions;
                }
                break;
            }
        }
        public void WizardEvent(WizardEventArgs WizardEventArgs)
        {
            switch (WizardEventArgs.EventType)
            {
            case EventType.Init:
                wiz = (AddPluginPackageWizard)WizardEventArgs.Wizard;
                break;

            case EventType.Active:
                mPluginPackage       = wiz.PluginPackage;
                xIDTextBox.Text      = mPluginPackage.PluginID;
                xVersionTextBox.Text = mPluginPackage.PluginPackageVersion;
                FolderTextBox.BindControl(mPluginPackage, nameof(PluginPackage.Folder));

                List <StandAloneAction> actions = mPluginPackage.LoadServicesInfoFromFile();

                // show distict list of the services
                ServicesGrid.ItemsSource = (from x in actions select x.ServiceID).Distinct();

                // TODO: get selected service only  - add radio show al or per selected

                ActionsDataGrid.ItemsSource = actions;

                break;
            }
        }
Example #3
0
 public void WizardEvent(WizardEventArgs WizardEventArgs)
 {
     switch (WizardEventArgs.EventType)
     {
     case EventType.Init:
         wiz = (AddPluginPackageWizard)WizardEventArgs.Wizard;
         FolderTextBox.BindControl(wiz, nameof(AddPluginPackageWizard.Folder));
         break;
     }
 }
 public void WizardEvent(WizardEventArgs WizardEventArgs)
 {
     switch (WizardEventArgs.EventType)
     {
     case EventType.Init:
         wiz = (AddPluginPackageWizard)WizardEventArgs.Wizard;
         xPluginFolderUC.Init(null, wiz, nameof(AddPluginPackageWizard.Folder), false, true, UCValueExpression.eBrowserType.Folder);
         break;
     }
 }
Example #5
0
        public void WizardEvent(WizardEventArgs WizardEventArgs)
        {
            switch (WizardEventArgs.EventType)
            {
            case EventType.Init:
                wiz = (AddPluginPackageWizard)WizardEventArgs.Wizard;
                xPluginFolderUC.Init(null, wiz, nameof(AddPluginPackageWizard.Folder), false, true, UCValueExpression.eBrowserType.Folder);
                break;

            case EventType.LeavingForNextPage:
                string folderName = xPluginFolderUC.ValueTextBox.Text;
                if (string.IsNullOrEmpty(folderName))
                {
                    WizardEventArgs.CancelEvent = true;
                    Amdocs.Ginger.Common.Reporter.ToUser(Amdocs.Ginger.Common.eUserMsgKey.StaticErrorMessage,
                                                         "Folder path cannot be empty");
                }
                break;
            }
        }
Example #6
0
        public void WizardEvent(WizardEventArgs WizardEventArgs)
        {
            switch (WizardEventArgs.EventType)
            {
            case EventType.Init:
                wiz = (AddPluginPackageWizard)WizardEventArgs.Wizard;
                break;

            case EventType.Active:
                mPluginPackage       = wiz.PluginPackage;
                xIDTextBox.Text      = mPluginPackage.PluginId;
                xVersionTextBox.Text = mPluginPackage.PluginPackageVersion;
                FolderTextBox.BindControl(mPluginPackage, nameof(PluginPackage.Folder));
                mPluginPackage.LoadServicesFromJSON();

                ServicesGrid.ItemsSource = mPluginPackage.Services;

                ActionsDataGrid.ItemsSource = mPluginPackage.Services[0].Actions;

                break;
            }
        }
Example #7
0
        public void WizardEvent(WizardEventArgs WizardEventArgs)
        {
            switch (WizardEventArgs.EventType)
            {
            case EventType.Init:
                wiz = (AddPluginPackageWizard)WizardEventArgs.Wizard;
                break;

            case EventType.Active:
                mPluginPackage       = wiz.PluginPackage;
                xIDTextBox.Text      = mPluginPackage.PluginID;
                xVersionTextBox.Text = mPluginPackage.PluginPackageVersion;
                FolderTextBox.BindControl(mPluginPackage, nameof(PluginPackage.Folder));

                ServicesGrid.ItemsSource = mPluginPackage.GetServices();

                // TODO: get selected service only
                ObservableList <StandAloneAction> actions = mPluginPackage.GetStandAloneActions();
                ActionsDataGrid.ItemsSource = actions;

                break;
            }
        }