public override void Install() { var settings = new ChronoPayPaymentSettings { GatewayUrl = "https://secure.chronopay.com/index_shop.cgi", ProductId = "", ProductName = "", SharedSecrect = "", AdditionalFee = 0, }; _settingService.SaveSetting(settings); //locales this.AddOrUpdatePluginLocaleResource("Plugins.Payments.ChronoPay.RedirectionTip", "You will be redirected to ChronoPay site to complete the order."); this.AddOrUpdatePluginLocaleResource("Plugins.Payments.ChronoPay.GatewayUrl", "Gateway URL"); this.AddOrUpdatePluginLocaleResource("Plugins.Payments.ChronoPay.GatewayUrl.Hint", "Enter gateway URL."); this.AddOrUpdatePluginLocaleResource("Plugins.Payments.ChronoPay.ProductId", "Product ID"); this.AddOrUpdatePluginLocaleResource("Plugins.Payments.ChronoPay.ProductId.Hint", "Enter product ID."); this.AddOrUpdatePluginLocaleResource("Plugins.Payments.ChronoPay.ProductName", "Product Name"); this.AddOrUpdatePluginLocaleResource("Plugins.Payments.ChronoPay.ProductName.Hint", "Enter product Name."); this.AddOrUpdatePluginLocaleResource("Plugins.Payments.ChronoPay.SharedSecrect", "Shared secret"); this.AddOrUpdatePluginLocaleResource("Plugins.Payments.ChronoPay.SharedSecrect.Hint", "Enter shared secret."); this.AddOrUpdatePluginLocaleResource("Plugins.Payments.ChronoPay.AdditionalFee", "Additional fee"); this.AddOrUpdatePluginLocaleResource("Plugins.Payments.ChronoPay.AdditionalFee.Hint", "Enter additional fee to charge your customers."); base.Install(); }
public ChronoPayPaymentProcessor(ChronoPayPaymentSettings chronoPayPaymentSettings, ICurrencyService currencyService, CurrencySettings currencySettings, ISettingService settingService, IWebHelper webHelper) { this._chronoPayPaymentSettings = chronoPayPaymentSettings; this._currencyService = currencyService; this._currencySettings = currencySettings; this._settingService = settingService; this._webHelper = webHelper; }