支付宝提示(ALIN42273),订单参数异常?
下单接口
蛮奇怪的,其他接口下单也没什么问题,有个接口就会报这个错,这是生成的form
<html>
<head></head>
<body>
<form id="alipaysubmit" name="alipaysubmit" action="https://openapi.alipay.com/gateway.do" method="POST">
<input type="hidden" name="app_id" value="2016010301059715" />
<input type="hidden" name="method" value="alipay.trade.wap.pay" />
<input type="hidden" name="format" value="JSON" />
<input type="hidden" name="charset" value="utf-8" />
<input type="hidden" name="sign_type" value="RSA2" />
<input type="hidden" name="version" value="1.0" />
<input type="hidden" name="return_url" value="http://yansongda.cn/return.php" />
<input type="hidden" name="notify_url" value="http://47.97.85.149/pay/alipay/notify" />
<input type="hidden" name="timestamp" value="2018-11-30 14:27:29" />
<input type="hidden" name="sign" value="WYSSAaUqt+6jpUwWZaqhKDBW4+O5yFpluFQfOxjhedQhuYqXqYmsNuam1EvW1sURSVUOQFRRZzZEalgJg26wmnNbLhsl67NrAP/E6aOkmz48Qdeps2fO9u8aF1y2wsQlNbifK+4r5HxQEaKdz+Ii1FQ/CLhU7ZT+CMpuVyPpoB8WQd8l2D11ctxWg6enjndO07AySCvpEUJDzwCSet8TgAqse96ACE/1D1AISBe9BBtDvjPp5K/FngxLUsT1cFlZprmprJsMxg0oTwRX7TjlomrDdAUg3Mnw01eniAwS5YL4IFlSFP2m1q6RCYeCj0wkQKnqNaZjhHprXjI6iYSBhg==" />
<input type="hidden" name="biz_content" value="{"out_trade_no":"20181130142729143915","total_amount":"0.01\n","subject":"U\u5e01\u5145\u503c","body":"\u6027\u7528\u793e\u8ba2\u5355\u652f\u4ed8","product_code":"QUICK_WAP_WAY"}" />
<input type="submit" value="ok" style="display:none;" '="" />
</form>
<script>document.forms['alipaysubmit'].submit();</script>
</body>
</html>
看不出有什么问题
这个是正确的订单
<html>
<head></head>
<body>
"
<form id="alipaysubmit" name="alipaysubmit" action="https://openapi.alipay.com/gateway.do" method="POST">
<input type="hidden" name="app_id" value="2016010301059715" />
<input type="hidden" name="method" value="alipay.trade.wap.pay" />
<input type="hidden" name="format" value="JSON" />
<input type="hidden" name="charset" value="utf-8" />
<input type="hidden" name="sign_type" value="RSA2" />
<input type="hidden" name="version" value="1.0" />
<input type="hidden" name="return_url" value="http://yansongda.cn/return.php" />
<input type="hidden" name="notify_url" value="http://47.97.85.149/pay/alipay/notify" />
<input type="hidden" name="timestamp" value="2018-11-30 14:47:40" />
<input type="hidden" name="sign" value="IBs8OuvPfbENvfgSEQMERT8gqiRX5CDeL63pQPKsDc5pubMczrkSxiXuPPdPGURwh2qbT4qHBs20KwoN3no5/Pt06lKlu0ZJBRCQ9gutsJDX+koGfBbxEEau/oOqE0+XcWvXf9m8cnx+Z8UcsMEGs6oGHjt33876W+54j4txHE3VOyaQqPyBGgGhS4vqhp11vgH0QZXlxWIrDF6RalpDsBcaTnPUkVPFWEY6eVas81wf6m1GiOvA2xF/Ro0fhYnb7gUT3Ezy1onFcm7MULsW8MyaiRBMX6BjMVPOAwtb/7+hVkCEVr5+d3K+xrCBkhubOI3IEtcIsvCSzHXPyfWZ9g==" />
<input type="hidden" name="biz_content" value="{"out_trade_no":"201811301447408001917","total_amount":"0.01","subject":"U\u5e01\u5145\u503c","body":"\u6027\u7528\u793e\u8ba2\u5355\u652f\u4ed8","product_code":"QUICK_WAP_WAY"}" />
<input type="submit" value="ok" style="display:none;" '="" />
</form>
<script>document.forms['alipaysubmit'].submit();</script>"
</body>
</html>
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
价格参数导致
回答一下原因,在下单的时候,价格参数有问题
过程是这样的,我的
price
是用decimal类型存的,我在界面上输入0.01
的时候,在0.01
后面多打了一个空格,数据也顺利存进去了(当时我也没在意),后来看了下,支付宝文档里要求,价格参数是精确到后两位的,应该是存入的时候多了几位了(虽然我定义price
也是decimal(10,2)
)