public ActionResult Configure()
        {
            var model = new ConfigurationModel();
            model.UseSandbox = _authorizeNetPaymentSettings.UseSandbox;
            model.TransactModeId = Convert.ToInt32(_authorizeNetPaymentSettings.TransactMode);
            model.TransactionKey = _authorizeNetPaymentSettings.TransactionKey;
            model.LoginId = _authorizeNetPaymentSettings.LoginId;
            model.AdditionalFee = _authorizeNetPaymentSettings.AdditionalFee;
            model.AdditionalFeePercentage = _authorizeNetPaymentSettings.AdditionalFeePercentage;
            model.TransactModeValues = _authorizeNetPaymentSettings.TransactMode.ToSelectList();

            return View("Nas.Plugin.Payments.AuthorizeNet.Views.PaymentAuthorizeNet.Configure", model);
        }
        public ActionResult Configure(ConfigurationModel model)
        {
            if (!ModelState.IsValid)
                return Configure();

            //save settings
            _authorizeNetPaymentSettings.UseSandbox = model.UseSandbox;
            _authorizeNetPaymentSettings.TransactMode = (TransactMode)model.TransactModeId;
            _authorizeNetPaymentSettings.TransactionKey = model.TransactionKey;
            _authorizeNetPaymentSettings.LoginId = model.LoginId;
            _authorizeNetPaymentSettings.AdditionalFee = model.AdditionalFee;
            _authorizeNetPaymentSettings.AdditionalFeePercentage = model.AdditionalFeePercentage;
            _settingService.SaveSetting(_authorizeNetPaymentSettings);

            model.TransactModeValues = _authorizeNetPaymentSettings.TransactMode.ToSelectList();

            return View("Nas.Plugin.Payments.AuthorizeNet.Views.PaymentAuthorizeNet.Configure", model);
        }