/// <summary> /// 创建支付信息(安卓 IOS) /// </summary> /// <param name="request">request</param> /// <param name="config">配置</param> /// <returns>结果</returns> public static UnifiedOrderResult CreateDirectPayByUser(UnifiedOrderRequest request, Config config) { // 统一下单 var requestStr = TenpayUtil.GetUnifiedOrderXml(request, config); var response = HttpHelp.PostXmlToUrl(Config.UnifiedPayUrl, requestStr); var unifiedOrderResult = TenpayUtil.ConvertToUnifiedOrderResult(response); // 调起支付 var parameters = TenpayUtil.GetPaySign(unifiedOrderResult, config); var result = TenpayUtil.CreatePayParameters(parameters, unifiedOrderResult); return(result); }