public TransactionRequest(NameValueCollection requestForm, EpayConfiguration epayConfiguration)
        {
            _epayConfiguration = epayConfiguration;
            _requestForm       = requestForm;

            // setup reponse variables
            Transact       = requestForm["txnid"];
            OrderId        = requestForm["orderid"];
            Currency       = requestForm["currency"];
            Amount         = requestForm["amount"];
            SubscriptionId = requestForm["subscriptionid"];

            _md5Key   = requestForm["hash"];
            _merchant = requestForm["merchant"];
        }
        public EpayPaymentOption(IOrderGroupFactory orderGroupFactory)
        {
            _orderGroupFactory = orderGroupFactory;
            _paymentMethod     = EpayConfiguration.GetEpayPaymentMethod()?.PaymentMethod?.FirstOrDefault();

            if (_paymentMethod == null)
            {
                return;
            }

            PaymentMethodId = _paymentMethod.PaymentMethodId;
            SystemKeyword   = _paymentMethod.SystemKeyword;
            Name            = _paymentMethod.Name;
            Description     = _paymentMethod.Description;
        }
        /// <summary>
        /// Handles the Load event of the Page control.
        /// </summary>
        /// <param name="sender">The source of the event.</param>
        /// <param name="e">The <see cref="System.EventArgs"/> instance containing the event data.</param>
        private void Page_Load(object sender, System.EventArgs e)
        {
            if (Request.Form["paymentprovider"] != null && Request.Form["paymentprovider"].Equals(EpayConfiguration.EpaySystemName))
            {
                ErrorManager.GenerateError(Utilities.Translate("CancelMessage"));
            }

            if (!IsPostBack)
            {
                var epayConfiguration = new EpayConfiguration();
                if (string.IsNullOrEmpty(epayConfiguration.ProcessingUrl) || string.IsNullOrEmpty(epayConfiguration.MD5Key))
                {
                    ConfigMessage.Text = Utilities.Translate("EpaySettingsError");
                }
            }
        }
Ejemplo n.º 4
0
 private PaymentMethodDto.PaymentMethodParameterRow GetParameterByName(string name)
 {
     return(EpayConfiguration.GetParameterByName(_paymentMethodDto, name));
 }