采用微信支付二的方式开发,用户支付已经成功,但是微信端一直在调用通知接口,经过三番五次的验证后发现,采用如下的返回接口,微信才认为是成功的。废话不多说,看代码:只返回SUCCESS就行。
@SuppressWarnings("rawtypes")
@RequestMapping(value="/notice",method={RequestMethod.GET,RequestMethod.POST})
@ResponseBody
public String noticeDispatch(HttpServletRequest requets,HttpServletResponse response) throws Exception{
PageData pd=this.getPageData();
Singleton.count= Singleton.count+1;
System.out.println("Singletoncount="+Singleton.count);
return "SUCCESS";
}