public void orderInfo(ref GasOrderInfo orderinfo, PayParam p)
        {
            log.Write("发起订单:燃气卡号:" + card.CardNo + ",充值气量:" + card.rechargeNum);
            GasOrderParam gasOrderParam = new GasOrderParam();

            gasOrderParam.paymentno    = card.CardNo;
            gasOrderParam.chargeAmount = card.rechargeNum;
            gasOrderParam.paymentAmout = card.price;
            gasOrderParam.shopType     = PayAccess.isWtLkl(p.icParams);
            //发送燃气订单
            orderinfo = GasAccess.gasOrder(gasOrderParam);
            if ("9999".Equals(orderinfo.msgrsp.retcode))
            {
                return;
            }
            if ("1234".Equals(orderinfo.msgrsp.retcode))
            {
                return;
            }
            if ("11111".Equals(orderinfo.msgrsp.retcode))
            {
                return;
            }
            if (!"0000".Equals(orderinfo.msgrsp.retcode))
            {
                return;
            }
            //获取商户号
            p.MERCHANTNO_shopNo = orderinfo.msgrsp.MERCHANTNO;
            //获取终端号
            p.TERMINALNO_clientNo = orderinfo.msgrsp.TERMINALNO;
            //交易金额
            p.rechageAmount = orderinfo.msgrsp.realAmout;
            //交易订单号
            p.orderNo = orderinfo.msgrsp.orderNo;
            if (!orderinfo.msgrsp.retcode.Equals("0000"))
            {
                throw new Exception();
            }
            Payment.GasPayParam.GasOrderInfo = orderinfo;
        }
Example #2
0
        /// <summary>
        /// 燃气卡提交订单接口
        /// </summary>
        /// <param name="param"></param>
        /// <returns></returns>
        public GasOrderInfo GasOrder(GasOrderParam param)
        {
            GasOrderInfo gasOrderInfo = null;
            Dictionary <String, String> parameters = new Dictionary <String, String>();

            parameters.Add("shopType", param.shopType);
            parameters.Add("servicename", "RQ002");
            parameters.Add("loginId", SysBLL.getCpuNo());
            parameters.Add("reqsn", SysBLL.getSerialNum());
            parameters.Add("authcode", SysBLL.Authcode);
            parameters.Add("trandateTime", SysBLL.getYYYYMMDDHHMMSSTime());
            parameters.Add("paymentno", param.paymentno);
            parameters.Add("chargeAmount", param.chargeAmount);
            parameters.Add("paymentAmout", param.paymentAmout);
            parameters.Add("terminalNo", ConfigurationManager.AppSettings["MechineNo"]);

            string jsonText = HttpHelper.getHttp(SysConfigHelper.readerNode("getOrderNoNewName"), parameters, null);

            //反序列化JSON字符串,将JSON字符串转换成LIST列表
            gasOrderInfo = JsonConvert.DeserializeObject <GasOrderInfo>(jsonText);
            return(gasOrderInfo);
        }
Example #3
0
        /// <summary>
        /// 燃气充值
        /// </summary>
        /// <param name="card"></param>
        /// <returns></returns>
        public static GasOrderInfo gasOrder(GasOrderParam param)
        {
            GasInterface access = new GasInterface();

            return(access.GasOrder(param));
        }