| | |
| | | import com.sandu.ximon.dao.domain.C3mCharging; |
| | | import com.sandu.ximon.dao.domain.C3mOrder; |
| | | import com.sandu.ximon.dao.domain.Pole; |
| | | import com.sandu.ximon.dao.enums.C3mRedisConstant; |
| | | import com.sandu.ximon.admin.manager.iot.rrpc.enums.C3mRedisConstant; |
| | | import com.sandu.ximon.dao.enums.OrderStatus; |
| | | import com.sandu.ximon.dao.enums.OrderType; |
| | | import com.sandu.ximon.dao.mapper.C3mOrderMapper; |
| | | import lombok.AllArgsConstructor; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.time.LocalDateTime; |
| | | import java.util.Date; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * @Author liuhaonan |
| | |
| | | return false; |
| | | } else { |
| | | orderByOutTradeNo.setRefundAmount(refundAmount); |
| | | return c3mOrderRefund(orderByOutTradeNo, "页面API退款", userId, username); |
| | | return c3mOrderRefund(orderByOutTradeNo, "充电桩退款", userId, username); |
| | | } |
| | | |
| | | |
| | |
| | | ); |
| | | // 推送到自动查询模块,进行扫描启动 |
| | | orderQueryListener.startScan(OrderScanType.C3M.getType()); |
| | | if(b){ |
| | | save(c3mOrderEntity); |
| | | } |
| | | // if(b){ |
| | | // save(c3mOrderEntity); |
| | | // } |
| | | return b ? c3mOrderEntity : null; |
| | | } |
| | | |
| | |
| | | WxPayOrderNotifyResult wxPayOrderNotifyResult = fastPayService.parseOrderNotifyResult(xmlData); |
| | | String orderSn = wxPayOrderNotifyResult.getOutTradeNo(); |
| | | String transactionId = wxPayOrderNotifyResult.getOutTradeNo(); |
| | | Integer totalFee = wxPayOrderNotifyResult.getTotalFee(); |
| | | C3mOrder userOrder = getByOrderSn(orderSn); |
| | | if (userOrder == null) { |
| | | return WxPayNotifyResponse.fail("订单不存在 sn=" + orderSn); |
| | |
| | | if (!updateById(userOrder)) { |
| | | return WxPayNotifyResponse.fail("更新数据已失效"); |
| | | } |
| | | |
| | | // UserPayRecord userPayRecord = new UserPayRecord(); |
| | | // userPayRecord.setOrderId(userOrder.getId()); |
| | | // userPayRecord.setPayAmount(userOrder.getTotalPrice()); |
| | | // userPayRecord.setPayType(PayTypeEnums.WECHAT.getCode()); |
| | | // userPayRecord.setPayDate(userOrder.getPayTime()); |
| | | // userPayRecord.setUserId(userOrder.getUserId()); |
| | | // userPayRecordService.save(userPayRecord); |
| | | |
| | | return WxPayNotifyResponse.success("更新数据成功"); |
| | | } |