Пример #1
0
        public override async Task <SenderLandPageConfiguration> Register(SignUpSender signUpSender)
        {
            var senderLandPageConfiguration = new SenderLandPageConfiguration(this.Provider.ServiceName)
            {
                Logo = "/Resources/com.baladorPlant/WhatsApp/whatsapp64x64.png",
                MessageEmailTemplate    = "WhatsApp",
                TextLandPageTemplate    = "WhatsApp",
                TwoFactorAuthentication = true
            };

            senderLandPageConfiguration
            .AddExtraFields(new FieldView {
                Name = "phone", Title = "phone"
            })
            .AddExtraFields(new FieldView {
                Name = "method", Title = "method sms"
            })
            .AddAcceptable("Remember It's will replace your whatsApp Application Account  on your mobile phone!!!")
            .AddHelpFile("/Resources/com.baladorPlant/WhatsApp/helpfile.html");

            var config = await Context.GetConfiguration <ConfigWhatsApp>(this.Provider.ServiceName, signUpSender.UserId);

            if (config != null && !String.IsNullOrEmpty(config.Token))
            {
                senderLandPageConfiguration.IsAlreadyRegister = true;
            }

            return(senderLandPageConfiguration);
        }
Пример #2
0
        public override async Task <SenderLandPageConfiguration> Register(SignUpSender signUpSender)
        {
            var senderLandPageConfiguration = new SenderLandPageConfiguration(this.Provider.ServiceName)
            {
                Logo = "",
                MessageEmailTemplate    = "Telegram",
                TextLandPageTemplate    = "Telegram",
                TwoFactorAuthentication = true
            };

            senderLandPageConfiguration.AddExtraFields(new FieldView {
                Name = "API_ID", Title = "API_ID"
            })
            .AddExtraFields(new FieldView {
                Name = "API_HASH", Title = "API_HASH"
            })
            .AddExtraFields(new FieldView {
                Name = "phone", Title = "phone"
            });
            senderLandPageConfiguration.AddAcceptable("Remember It's will replace your whatsApp Application Account  on your mobile phone!!!").AddHelpFile("/plugin/h.html");
            var config = await Context.GetConfiguration <ConfigTelegram>(this.Provider.ServiceName, signUpSender.UserName);

            if (config != null && !String.IsNullOrEmpty(config.Token))
            {
                senderLandPageConfiguration.IsAlreadyRegister = true;
            }

            return(senderLandPageConfiguration);
        }
Пример #3
0
        public override async Task <SenderLandPageConfiguration> Register(SignUpSender signUpSender)
        {
            var senderLandPageConfiguration = new SenderLandPageConfiguration(this.Provider.ServiceName)
            {
                Logo = "/Resources/com.baladorPlant/MockHttpSender/whatsapp64x64.png",
                MessageEmailTemplate    = "http test",
                TextLandPageTemplate    = "http test",
                TwoFactorAuthentication = true
            };

            senderLandPageConfiguration.ExtraFields.Add(new FieldView {
                Name = "pws", Title = "write password"
            });
            senderLandPageConfiguration.ExtraFields.Add(new FieldView {
                Name = "client_id", Title = "client"
            });
            senderLandPageConfiguration.ExtraFields.Add(new FieldView {
                Name = "grant_type", Title = "grant type"
            });

            senderLandPageConfiguration.AddAcceptable("Remember It your mobile phone!!!")
            .AddHelpFile("/Resources/com.baladorPlant/MockHttpSender/helpfile.html");

            var config = await Context.GetConfiguration <ConfigHttp>(this.Provider.ServiceName, signUpSender.UserId);

            if (config != null && !String.IsNullOrEmpty(config.Token))
            {
                senderLandPageConfiguration.IsAlreadyRegister = true;
            }

            return(senderLandPageConfiguration);
        }
Пример #4
0
        public override async Task <SenderLandPageConfiguration> Register(SignUpSender signUpSender)
        {
            var senderLandPageConfiguration = new SenderLandPageConfiguration(this.Provider.ServiceName)
            {
                Logo = "/Resources/com.baladorPlant/MockSender/telegram-logo64x64.png",
                MessageEmailTemplate    = "http lite",
                TextLandPageTemplate    = "http lite",
                TwoFactorAuthentication = false
            };

            senderLandPageConfiguration.AddExtraFields(new FieldView {
                Name = "token", Title = "write token only "
            });
            senderLandPageConfiguration.AddAcceptable("Remember It's will replace your whatsApp Application Account  on your mobile phone!!!")
            .AddHelpFile("/Resources/com.baladorPlant/MockSender/helpfile.html");


            var token = await GetToken(signUpSender);

            if (token != null)
            {
                senderLandPageConfiguration.IsAlreadyRegister = true;
            }

            return(senderLandPageConfiguration);
        }