Beispiel #1
0
 public CheckoutController(ApplicationDbContext context, UserManager <User> userManager
                           , IEmailSender emailSender, Braintree.IBraintreeGateway braintreeGateway)
 {
     this._context          = context;
     this._userManager      = userManager;
     this._emailSender      = emailSender;
     this._braintreeGateway = braintreeGateway;
 }
Beispiel #2
0
        public GuitarStorePaymentService()
        {
            string merchantId  = System.Configuration.ConfigurationManager.AppSettings["Braintree.MerchantId"];
            string environment = System.Configuration.ConfigurationManager.AppSettings["Braintree.Environment"];
            string publicKey   = System.Configuration.ConfigurationManager.AppSettings["Braintree.PublicKey"];
            string privateKey  = System.Configuration.ConfigurationManager.AppSettings["Braintree.PrivateKey"];

            gateway = new Braintree.BraintreeGateway(environment, merchantId, publicKey, privateKey);
        }