WebUI/Api/payment/alipayOld/notify_url.aspx.cs

(开头部分) 5KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.Specialized;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using API; 
using Common;
using API.Payment.Alipay;
using Bll;
using HModel;
using WebBase;

namespace WebUI.api.payment.alipay
{
    public partial class notify_url : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            SortedDictionary<string, string> sPara = GetRequestPost();

            if (sPara.Count > 0)//判断是否有带返回参数
            {
                Notify aliNotify = new Notify();
                bool verifyResult = aliNotify.Verify(sPara, EKRequest.GetString("notify_id"), EKRequest.GetString("sign"));

                if (verifyResult)//验证成功
                {
                    string trade_no = EKRequest.GetString("trade_no");         //支付宝交易号
                    string order_no = EKRequest.GetString("out_trade_no");     //获取订单号
                    string total_fee = EKRequest.GetString("total_fee");       //获取总金额
                    string subject = EKRequest.GetString("subject");           //商品名称、订单名称
                    string body = EKRequest.GetString("body");                 //商品描述、订单备注、描述
                    string buyer_email = EKRequest.GetString("buyer_email");   //买家支付宝账号
                    string trade_status = EKRequest.GetString("trade_status"); //交易状态
                    string order_type = EKRequest.GetString("extra_common_param"); //订单交易类别

                    if (EKRequest.GetString("trade_status") == "TRADE_FINISHED" || EKRequest.GetString("trade_status") == "TRADE_SUCCESS")
                    {
                        //修改支付状态、时间
                        //if (order_type.ToLower() == DTEnums.AmountTypeEnum.Recharge.ToString().ToLower()) //在线充值
                        //{
                        //    BLL.amount_log bll = new BLL.amount_log();
                        //    Model.amount_log model = bll.GetModel(order_no);
                        //    if (model == null)
                        //    {
                        //        Response.Write("该订单号不存在");
                        //        return;
                        //    }
                        //    if (model.value != decimal.Parse(total_fee))
                        //    {
                        //        Response.Write("订单金额和支付金额不相符");
                        //        return;
                        //    }
                        //    model.status = 1;
                        //    model.complete_time = DateTime.Now;
                        //    bool result = bll.Update(model);
                        //    if (!result)
                        //    {
后面还有 69 行代码,购买后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。