@Test public void testCreateOrderByAlipay() throws Exception { }
@ApiOperation(value = "支付宝支付,创建订单接口") @RequestMapping(value = "/api/v1/user/order/alipay", method = RequestMethod.POST) public JSONObject createOrderByAlipay(@Valid @RequestBody OrderFormData param, BindingResult br){ if(br.hasErrors()){ LOG.debug(br.getAllErrors()); return fail(-1,"参数错误"); } try { param.getOrder().setUserAccountId(getUserId()); JSONObject result = aliPayService.createTemporaryOrder(param); return success("",result.toString()); }catch (Exception e){ return fail(-1,"订单创建失败"); } }
PayController extends BaseController { @ApiOperation(value = "支付宝支付,创建订单接口") @RequestMapping(value = "/api/v1/user/order/alipay", method = RequestMethod.POST) public JSONObject createOrderByAlipay(@Valid @RequestBody OrderFormData param, BindingResult br){ if(br.hasErrors()){ LOG.debug(br.getAllErrors()); return fail(-1,"参数错误"); } try { param.getOrder().setUserAccountId(getUserId()); JSONObject result = aliPayService.createTemporaryOrder(param); return success("",result.toString()); }catch (Exception e){ return fail(-1,"订单创建失败"); } } }
PayController extends BaseController { @ApiOperation(value = "支付宝支付,创建订单接口") @RequestMapping(value = "/api/v1/user/order/alipay", method = RequestMethod.POST) public JSONObject createOrderByAlipay(@Valid @RequestBody OrderFormData param, BindingResult br){ if(br.hasErrors()){ LOG.debug(br.getAllErrors()); return fail(-1,"参数错误"); } try { param.getOrder().setUserAccountId(getUserId()); JSONObject result = aliPayService.createTemporaryOrder(param); return success("",result.toString()); }catch (Exception e){ return fail(-1,"订单创建失败"); } }  }
PayController extends BaseController { @ApiOperation(value = "支付宝支付,创建订单接口") @RequestMapping(value = "/api/v1/user/order/alipay", method = RequestMethod.POST) public JSONObject createOrderByAlipay(@Valid @RequestBody OrderFormData param, BindingResult br){ if(br.hasErrors()){ LOG.debug(br.getAllErrors()); return fail(-1,"参数错误"); } try { param.getOrder().setUserAccountId(getUserId()); JSONObject result = aliPayService.createTemporaryOrder(param); return success("",result.toString()); }catch (Exception e){ return fail(-1,"订单创建失败"); } }  @ApiOperation(value = "支付宝支付,创建订单接口") @RequestMapping(value = "/api/v1/user/order/alipay", method = RequestMethod.POST) JSONObject createOrderByAlipay(@Valid @RequestBody OrderFormData param, BindingResult br); @ApiOperation(value = "支付成功,支付宝异步通知接口") @RequestMapping(value = "/api/v1/pub/user/order/alipay/callback",method = RequestMethod.POST) void alipayCallback(HttpServletRequest request,HttpServletResponse response); @ResponseBody @ApiOperation(value = "接收支付宝返回的请求参数") @RequestMapping(value = "/api/v1/pub/orders/alipay/callbacks.do", produces = "text/html;charset=UTF-8", method = {RequestMethod.POST}) String callbacks(HttpServletRequest request); @RequestMapping(value = "/api/v1/user/order/alipay/query", method = RequestMethod.POST) void orderPayQuery(HttpServletRequest request, HttpServletResponse response, String tradeno, String orderno,
                              String callback); @RequestMapping(value = "/api/v1/user/order/wxpay/notify", method = RequestMethod.POST) void orderPayNotify(HttpServletRequest request, HttpServletResponse response); @RequestMapping(value = "/api/v1/user/order/alipay/refund", method = RequestMethod.POST) void orderPayRefund(HttpServletRequest request, HttpServletResponse response, String tradeno, String orderno,
                               String callback); @RequestMapping(value = "/api/v1/user/order/alipay/refund/query", method = RequestMethod.POST) void orderPayRefundQuery(HttpServletRequest request, HttpServletResponse response, String orderno,
                                    String tradeno, String callback); }
PayController extends BaseController { @ApiOperation(value = "支付宝支付,创建订单接口") @RequestMapping(value = "/api/v1/user/order/alipay", method = RequestMethod.POST) public JSONObject createOrderByAlipay(@Valid @RequestBody OrderFormData param, BindingResult br){ if(br.hasErrors()){ LOG.debug(br.getAllErrors()); return fail(-1,"参数错误"); } try { param.getOrder().setUserAccountId(getUserId()); JSONObject result = aliPayService.createTemporaryOrder(param); return success("",result.toString()); }catch (Exception e){ return fail(-1,"订单创建失败"); } }  @ApiOperation(value = "支付宝支付,创建订单接口") @RequestMapping(value = "/api/v1/user/order/alipay", method = RequestMethod.POST) JSONObject createOrderByAlipay(@Valid @RequestBody OrderFormData param, BindingResult br); @ApiOperation(value = "支付成功,支付宝异步通知接口") @RequestMapping(value = "/api/v1/pub/user/order/alipay/callback",method = RequestMethod.POST) void alipayCallback(HttpServletRequest request,HttpServletResponse response); @ResponseBody @ApiOperation(value = "接收支付宝返回的请求参数") @RequestMapping(value = "/api/v1/pub/orders/alipay/callbacks.do", produces = "text/html;charset=UTF-8", method = {RequestMethod.POST}) String callbacks(HttpServletRequest request); @RequestMapping(value = "/api/v1/user/order/alipay/query", method = RequestMethod.POST) void orderPayQuery(HttpServletRequest request, HttpServletResponse response, String tradeno, String orderno,
                              String callback); @RequestMapping(value = "/api/v1/user/order/wxpay/notify", method = RequestMethod.POST) void orderPayNotify(HttpServletRequest request, HttpServletResponse response); @RequestMapping(value = "/api/v1/user/order/alipay/refund", method = RequestMethod.POST) void orderPayRefund(HttpServletRequest request, HttpServletResponse response, String tradeno, String orderno,
                               String callback); @RequestMapping(value = "/api/v1/user/order/alipay/refund/query", method = RequestMethod.POST) void orderPayRefundQuery(HttpServletRequest request, HttpServletResponse response, String orderno,
                                    String tradeno, String callback);  }