/// <summary>
        /// Construct an XML serialized form that will define the input properties that will be displayed in the UI and 
        /// used to pass back into the connection using the connect method the connection method
        /// </summary>
        /// <returns></returns>
        private string BuildUiFormDefinition()
        {
            FormDefinition formDefinition = new FormDefinition();
            //Add your company name here, this is a required field 
            formDefinition.CompanyName = "Scribe Software Corporation © 1996-2011 All rights reserved.";
            //declare the key used for transfering of sensative data
            //this is a required 
            formDefinition.CryptoKey = CryptoKey;

            //decalare a help uri, this is not required and will not be display if it is not declared
            formDefinition.HelpUri = new Uri("http://www.scribesoft.com");

            //for each input item on the screen a new entry definition will need to be created and 
            //added to the form definition in order to be serialized and passed up to the ui.
            //this first entry will define a combo box
            EntryDefinition entry = new EntryDefinition();

            //set the input type to plain text
            entry.InputType = InputType.Text;
            entry.IsRequired = true;

            //set the Label that is displayed to the user and the identifying property name
            //note: the label and the property name may be different
            entry.Label = "Provider";
            entry.PropertyName = "Provider";

            //set the position in which the control will be displayed
            entry.Order = 1;

            //the options will hold the list of values to be placed in the combo box
            //The first value is what will be displayed to the user
            //The second value is the actual value that will be passed back to the connector
            entry.Options.Add("SQL Server 2012", "SQLNCLI11");
            entry.Options.Add("SQL Server 2008", "SQLNCLI10");
            entry.Options.Add("SQL Server 2005", "SQLNCLI");
            //finally add the entry definition representing the combobox to the form definition
            formDefinition.Add(entry);

            //create and entry for a standard text box
            formDefinition.Add(new EntryDefinition { InputType = InputType.Text, PropertyName = "Server", Label = "Server", Order = 2, IsRequired = true });
            formDefinition.Add(new EntryDefinition { InputType = InputType.Text, PropertyName = "Database", Label = "Database", Order = 3, IsRequired = true });
            formDefinition.Add(new EntryDefinition { InputType = InputType.Text, PropertyName = "UserName", Label = "UserName", Order = 4, IsRequired = true });

            //Finally create a password field
            formDefinition.Add(new EntryDefinition { InputType = InputType.Password, PropertyName = "Password", Label = "Password", Order = 5, IsRequired = true });

            //serialize the formDefinition so that it can be sent back to the UI
            return formDefinition.Serialize();
        }
Пример #2
0
        public string PreConnect(IDictionary <string, string> properties)
        {
            var form = new FormDefinition
            {
                CompanyName = "ScribeLabs",
                CryptoKey   = ConnectorSettings.cryptoKey,
                HelpUri     = new Uri("http://www.scribesoft.com"),
                Entries     =
                    new Collection <EntryDefinition>
                {
                    new EntryDefinition
                    {
                        InputType    = InputType.Text,
                        IsRequired   = true,
                        Label        = "API URL",
                        PropertyName = "BaseURL"
                    },
                }
            };

            return(form.Serialize());
        }
Пример #3
0
        public string PreConnect(IDictionary <string, string> properties)
        {
            var form = new FormDefinition
            {
                CompanyName = "Samanage Software",
                CryptoKey   = ConnectorSettings.cryptoKey,
                HelpUri     = new Uri("http://www.samanage.com/api"),
                Entries     =
                    new Collection <EntryDefinition>
                {
                    new EntryDefinition
                    {
                        InputType    = InputType.Text,
                        IsRequired   = true,
                        Label        = "API Token",
                        PropertyName = "accessToken"
                    },
                }
            };

            return(form.Serialize());
        }
Пример #4
0
        public string PreConnect(IDictionary <string, string> properties)
        {
            var form = new FormDefinition
            {
                CompanyName = "DayForce Portal",
                CryptoKey   = ConstantUtils.CryptoKey,
                HelpUri     = new Uri("https://help.scribesoft.com"),
                Entries     =
                    new Collection <EntryDefinition>
                {
                    new EntryDefinition
                    {
                        InputType    = InputType.Text,
                        IsRequired   = true,
                        Label        = "UserName",
                        PropertyName = ConstantUtils.Username
                    },
                    new EntryDefinition
                    {
                        InputType    = InputType.Text,
                        IsRequired   = true,
                        Label        = "Password",
                        PropertyName = ConstantUtils.Password
                    },
                    new EntryDefinition
                    {
                        InputType    = InputType.Password,
                        IsRequired   = true,
                        Label        = "Client Namespace",
                        PropertyName = ConstantUtils.clientNamespace
                    }
                }
            };


            return(form.Serialize());
        }
Пример #5
0
        //-----------------------------------------------------------------------------------------------------
        public string PreConnect(IDictionary<string, string> properties)
        {
            var form = new FormDefinition
            {
                CompanyName = ("Melissa Data. Additional Information : http://www.melissadata.com/dqt/scribe.htm"),
                CryptoKey = "1",
                HelpUri = new Uri("http://wiki.melissadata.com/index.php?title=Data_Quality_Components_for_Scribesoft"),
                Entries =
                new Collection<EntryDefinition>
                {
                     new EntryDefinition
                    {
                    InputType = InputType.Text,
                    IsRequired = true,
                    Label = "Melissa Data License Key",
                    PropertyName = "licensekey"
                    },
                }
            };

            return form.Serialize();
        }
Пример #6
0
        public string PreConnect(IDictionary<string, string> properties)
        {
            var form = new FormDefinition
                {
                    CompanyName = "etouches, Inc.",
                    CryptoKey = "{B5D0EEE1-40CE-4D34-B161-52B8620903EE}",
                    HelpUri = new Uri("https://developer.etouches.com/"),
                    Entries = new Collection<EntryDefinition>
                    {
                        new EntryDefinition
                        {
                            InputType = InputType.Text,
                            IsRequired = true,
                            Label = "Account Id",
                            PropertyName = "AccountId"
                        },
                        new EntryDefinition
                        {
                            InputType = InputType.Text,
                            IsRequired = true,
                            Label = "Event Id",
                            PropertyName = "EventId"
                        },
                        new EntryDefinition
                        {
                            InputType = InputType.Text,                               
                            IsRequired = true,
                            Label = "API Key",
                            PropertyName = "ApiKey"
                        },
                        new EntryDefinition
                        {
                            InputType = InputType.Text,
                            IsRequired = true,
                            Label = "TTL for Cache In Minutes",
                            PropertyName = "TTL"
                        },
                        new EntryDefinition
                        {
                            InputType = InputType.Text,
                            IsRequired = true,
                            Label = "Page Size",
                            PropertyName = "PageSize"
                        },
                        new EntryDefinition
                        {
                            InputType = InputType.Text,
                            IsRequired = true,
                            Label = "Base URL (leave blank for https://eiseverywhere.com)",
                            PropertyName = "BaseUrl"
                        },
                        new EntryDefinition
                        {
                            InputType = InputType.Text,
                            IsRequired = true,
                            Label = "API V2 URL (leave blank for https://eiseverywhere.com)",
                            PropertyName = "V2Url"
                        }
                    }


            };

            return form.Serialize();
        }
Пример #7
0
        /// <summary>
        /// Construct an XML serialized form that will define the input properties that will be displayed in the UI and 
        /// used to pass back into the connection using the connect method the connection method
        /// </summary>
        /// <returns></returns>
        private string BuildUiFormDefinition()
        {
            FormDefinition formDefinition = new FormDefinition();
            //Add your company name here, this is a required field
            formDefinition.CompanyName = "Scribe Software Corporation © 1996-2011 All rights reserved.";
            //declare the key used for transfering of sensative data
            //this is a required
            formDefinition.CryptoKey = CryptoKey;

            //decalare a help uri, this is not required and will not be display if it is not declared
            formDefinition.HelpUri = new Uri("http://www.scribesoft.com");

            //for each input item on the screen a new entry definition will need to be created and
            //added to the form definition in order to be serialized and passed up to the ui.
            //this first entry will define a combo box
            EntryDefinition entry = new EntryDefinition();

            //set the input type to plain text
            entry.InputType = InputType.Text;
            entry.IsRequired = true;

            //set the Label that is displayed to the user and the identifying property name
            //note: the label and the property name may be different
            entry.Label = "Provider";
            entry.PropertyName = "Provider";

            //set the position in which the control will be displayed
            entry.Order = 1;

            //the options will hold the list of values to be placed in the combo box
            //The first value is what will be displayed to the user
            //The second value is the actual value that will be passed back to the connector
            entry.Options.Add("SQL Server 2012", "SQLNCLI11");
            entry.Options.Add("SQL Server 2008", "SQLNCLI10");
            entry.Options.Add("SQL Server 2005", "SQLNCLI");
            //finally add the entry definition representing the combobox to the form definition
            formDefinition.Add(entry);

            //create and entry for a standard text box
            formDefinition.Add(new EntryDefinition { InputType = InputType.Text, PropertyName = "Server", Label = "Server", Order = 2, IsRequired = true });
            formDefinition.Add(new EntryDefinition { InputType = InputType.Text, PropertyName = "Database", Label = "Database", Order = 3, IsRequired = true });
            formDefinition.Add(new EntryDefinition { InputType = InputType.Text, PropertyName = "UserName", Label = "UserName", Order = 4, IsRequired = true });

            //Finally create a password field
            formDefinition.Add(new EntryDefinition { InputType = InputType.Password, PropertyName = "Password", Label = "Password", Order = 5, IsRequired = true });

            //serialize the formDefinition so that it can be sent back to the UI
            return formDefinition.Serialize();
        }
Пример #8
0
        public string PreConnect(IDictionary <string, string> properties)
        {
            var form = new FormDefinition
            {
                CompanyName = "etouches, Inc.",
                CryptoKey   = "{B5D0EEE1-40CE-4D34-B161-52B8620903EE}",
                HelpUri     = new Uri("https://developer.etouches.com/"),
                Entries     = new Collection <EntryDefinition>
                {
                    new EntryDefinition
                    {
                        InputType    = InputType.Text,
                        IsRequired   = true,
                        Label        = "Account Id",
                        PropertyName = "AccountId"
                    },
                    new EntryDefinition
                    {
                        InputType    = InputType.Text,
                        IsRequired   = true,
                        Label        = "Event Id",
                        PropertyName = "EventId"
                    },
                    new EntryDefinition
                    {
                        InputType    = InputType.Text,
                        IsRequired   = true,
                        Label        = "API Key",
                        PropertyName = "ApiKey"
                    },
                    new EntryDefinition
                    {
                        InputType    = InputType.Text,
                        IsRequired   = true,
                        Label        = "TTL for Cache In Minutes",
                        PropertyName = "TTL"
                    },
                    new EntryDefinition
                    {
                        InputType    = InputType.Text,
                        IsRequired   = true,
                        Label        = "Page Size",
                        PropertyName = "PageSize"
                    },
                    new EntryDefinition
                    {
                        InputType    = InputType.Text,
                        IsRequired   = true,
                        Label        = "Base URL (leave blank for https://eiseverywhere.com)",
                        PropertyName = "BaseUrl"
                    },
                    new EntryDefinition
                    {
                        InputType    = InputType.Text,
                        IsRequired   = true,
                        Label        = "API V2 URL (leave blank for https://eiseverywhere.com)",
                        PropertyName = "V2Url"
                    }
                }
            };

            return(form.Serialize());
        }