| | |
| | | import com.java110.config.properties.EventProperties; |
| | | import com.java110.core.base.smo.BaseServiceSMO; |
| | | import com.java110.core.context.AppContext; |
| | | import com.java110.core.event.AppEventPublishing; |
| | | import com.java110.event.AppEventPublishing; |
| | | import com.java110.entity.order.BusiOrder; |
| | | import com.java110.entity.order.BusiOrderAttr; |
| | | import com.java110.entity.order.OrderList; |
| | |
| | | */ |
| | | @Override |
| | | public String queryOrderInfo(OrderList orderList) throws Exception{ |
| | | return queryOrderInfo(orderList,true); |
| | | return queryOrderInfo(orderList,true,false); |
| | | } |
| | | |
| | | /** |
| | |
| | | * @return |
| | | */ |
| | | @Override |
| | | public String queryOrderInfo(OrderList orderList,Boolean isQueryDataInfo) throws Exception{ |
| | | public String queryOrderInfo(OrderList orderList,Boolean isQueryDataInfo,Boolean isNeedDelete) throws Exception{ |
| | | |
| | | |
| | | /*List<OrderList> orderLists = iOrderServiceDao.queryOrderListAndAttr(orderList); |
| | |
| | | |
| | | //封装data 节点 |
| | | if(isQueryDataInfo){ |
| | | |
| | | busiOrderTmpJson.put("data",queryDataInfo(busiOrderTmp1,isNeedDelete)); |
| | | } |
| | | |
| | | |
| | |
| | | |
| | | |
| | | return ProtocolUtil.createResultMsg(ProtocolUtil.RETURN_MSG_SUCCESS,"查询成功",orderListJson); |
| | | } |
| | | |
| | | /** |
| | | * 查询data信息 |
| | | * @return |
| | | */ |
| | | private JSONObject queryDataInfo(BusiOrder busiOrder,Boolean isNeedDelete) throws Exception{ |
| | | //购物车订单类型 |
| | | String actionTypeCd = busiOrder.getActionTypeCd(); |
| | | |
| | | //创建上下文对象 |
| | | AppContext context = createApplicationContext(); |
| | | |
| | | //prepareContext(context, busiOrder); |
| | | if(isNeedDelete) { |
| | | return AppEventPublishing.queryDataInfoEvent(context, busiOrder); |
| | | }else { |
| | | return AppEventPublishing.queryNeedDeleteDataInfoEvent(context,busiOrder); |
| | | } |
| | | |
| | | } |
| | | |
| | | /** |
| | |
| | | |
| | | //创建上下文对象 |
| | | AppContext context = createApplicationContext(); |
| | | |
| | | |
| | | prepareContext(context, datasTmp); |
| | | /* try {*/ |
| | |
| | | } |
| | | |
| | | // 查询购物车信息,订单项信息 |
| | | String oldOrderInfo = this.queryOrderInfo(orderList,false); |
| | | String oldOrderInfo = this.queryOrderInfo(orderList,true,true); |
| | | |
| | | JSONObject oldOrderInfoJson = ProtocolUtil.getObject(oldOrderInfo,JSONObject.class); |
| | | |
| | | oldOrderInfoJson.getJSONArray("orderLists"); |
| | | //重新发起撤单订单 |
| | | orderDispatch(null); |
| | | orderDispatch(JSONObject.parseObject(oldOrderInfo)); |
| | | } |
| | | |
| | | /** |