Exemplo n.º 1
0
        /// <summary>
        /// 充值POST
        /// </summary>
        public void UserRecharge()
        {
            decimal price      = 1;
            int     userID     = 1;
            var     alipayImpl = new AlipayImpl();

            alipayImpl.RechargeTo(price, userID);
        }
Exemplo n.º 2
0
        /// <summary>
        /// 订单POST
        /// </summary>
        public void UserOrder()
        {
            int     userID = 0, sourceType = 0;
            decimal price = 1;
            string  orderID = "OR001", name = "zzl";
            var     alipayImpl = new AlipayImpl();

            alipayImpl.OnlineTo(orderID, sourceType, userID, price, name, "时间戳tradeid,它是传到支付宝的号");
        }
Exemplo n.º 3
0
        /// <summary>
        /// 银联通知页面
        /// </summary>
        public void ChinaPayNotify()
        {
            var alipayImpl = new AlipayImpl();

            alipayImpl.Success += Impl_Success;
            alipayImpl.Fail    += Impl_Fail;
            alipayImpl.Notify_Return(HttpMethod.Post);
            alipayImpl.Success -= Impl_Success;
            alipayImpl.Fail    -= Impl_Fail;
        }
Exemplo n.º 4
0
        /// <summary>
        /// 支付宝返回页面
        /// </summary>
        public void AlipayReturn()
        {
            var alipayImpl = new AlipayImpl();

            alipayImpl.Success += Impl_Success;
            alipayImpl.Fail    += Impl_Fail;
            alipayImpl.Notify_Return(HttpMethod.Get);
            alipayImpl.Success -= Impl_Success;
            alipayImpl.Fail    -= Impl_Fail;
        }