Authored by Lixiaodi

Merge branch 'dev' of http://git.yoho.cn/ufo/yohoufo-fore into dev

package com.yohoufo.dal.order.model;
import com.alibaba.fastjson.JSONObject;
import java.math.BigDecimal;
public class SellerOrder {
... ... @@ -137,4 +139,9 @@ public class SellerOrder {
public void setExceptStatus(Integer exceptStatus) {
this.exceptStatus = exceptStatus;
}
@Override
public String toString() {
return JSONObject.toJSONString(this);
}
}
\ No newline at end of file
... ...
... ... @@ -69,6 +69,9 @@ public class PaymentController {
@RequestParam(name = "payment") int payment){
PaymentRequest request = PaymentRequest.builder().uid(uid).orderCode(orderCode).payment(payment).build();
logger.info("method com.yohoufo.order.controller.PaymentController.pay in, request is {}", request);
PrepayResponse paymentResponse = paymentService.payment(request);
if (paymentResponse.getPrepayResult() == PrepayResponse.FAILED){
return new ApiResponse.ApiResponseBuilder().code(PrepayResponse.FAILED).data(paymentResponse.getJsonObj()).message("支付订单失败").build();
... ...
... ... @@ -17,6 +17,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;
... ... @@ -123,7 +124,7 @@ public class SellerOrderController {
* 后台下架
* 在遥远的未来或者根本就没有未来
* 那就用"也许"来表达下,未来也许需要MQ方式
* @param skup
* @param sellerOrder
* @return
* @throws GatewayException
*/
... ... @@ -131,7 +132,7 @@ public class SellerOrderController {
@ResponseBody
@IgnoreSession
@IgnoreSignature
public ApiResponse offShelveByErp(SellerOrder sellerOrder) throws GatewayException {
public ApiResponse offShelveByErp(@RequestBody SellerOrder sellerOrder) throws GatewayException {
logger.info("in ufo.sellerOrder.cancel, sellerOrder {}", sellerOrder);
boolean result = sellerOrderService.offShelveByErp(sellerOrder.getSkup()) ;
... ...
... ... @@ -82,7 +82,7 @@ public class SellerOrderPaymentService extends AbstractOrderPaymentService {
@Override
public void processAfterPay(OrderInfo orderInfo) {
logger.info("method com.yohoufo.order.service.SellerOrderPaymentService.processAfterPay in, orderInfo is {}", orderInfo);
String prdName = null;
SellerOrder sellerOrder = sellerOrderMapper.selectByOrderCode(orderInfo.getOrderCode());
if (Objects.nonNull(sellerOrder)){
... ...
... ... @@ -8,12 +8,12 @@ consumer:
topic: ufo.order.updateExpressInfo
- class: com.yohoufo.order.mq.consumer.SellerOrderAutoCancelDelayMsgConsumer
topic: seller_order_autoCancel
topic: sellerOrder.autoCancel
delay:
interval: 15
- class: com.yohoufo.order.mq.consumer.BuyerOrderAutoCancelDelayMsgConsumer
topic: buyer_order_autoCancel
topic: buyerOrder.autoCancel
delay:
interval: 15
... ...
... ... @@ -8,12 +8,12 @@ consumer:
topic: ufo.order.updateExpressInfo
- class: com.yohoufo.order.mq.consumer.SellerOrderAutoCancelDelayMsgConsumer
topic: seller_order_autoCancel
topic: sellerOrder.autoCancel
delay:
interval: 15
- class: com.yohoufo.order.mq.consumer.BuyerOrderAutoCancelDelayMsgConsumer
topic: buyer_order_autoCancel
topic: buyerOrder.autoCancel
delay:
interval: 15
... ...