zhouxiang
2021-12-08 2fea45bd7a6aecb44fd2a7282a4f5488787f302d
添加创建订单接口
2个文件已修改
9 ■■■■■ 已修改文件
phi_platform_user/src/main/java/com/hx/phip/order/controller/OrderController.java 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
phi_platform_user/src/main/java/com/hx/phip/service/OrderItemService.java 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
phi_platform_user/src/main/java/com/hx/phip/order/controller/OrderController.java
@@ -14,6 +14,8 @@
import com.hx.phip.service.SysAdminService;
import com.hx.phip.tool.CreateNo;
import com.hx.util.StringUtils;
import com.platform.constants.LoginConstant;
import com.platform.entity.ThirtApplication;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
@@ -44,16 +46,14 @@
        if(StringUtils.isEmpty(param)){
            throwParamException("请传订单参数");
        }
//        SysAdmin sysAdmin = (SysAdmin) getRequestAttribute(Constants.LOGIN_ADMIN);
//        if(sysAdmin==null){
//            throw new TipsException("未找到当前登录人的信息");
//        }
        ThirtApplication thirtApplication= (ThirtApplication) getRequestAttribute(LoginConstant.LOGIN_APPLY);
        JSONObject object = JSONObject.parseObject(param);
        //获取总订单对象
        OrdersTotal orderTotal = JSONObject.parseObject(object.getString("orderTotal"), OrdersTotal.class);
        //校验参数成功的订单
        orderTotal = checkOrderTotalParam(orderTotal);
        orderTotal.setAppId(thirtApplication.getAppId());
        //获取订单的子订单
        List<OrderItem> orderItem = JSONObject.parseArray(object.getString("orderItem"), OrderItem.class);
        if(orderItem==null || orderItem.size()==0){
phi_platform_user/src/main/java/com/hx/phip/service/OrderItemService.java
@@ -2,7 +2,6 @@
import com.hx.phiappt.model.order.OrderItem;
import com.hx.mybatisTool.SqlSentence;
import com.hx.phiappt.model.order.OrderItemSource;
import java.util.List;
import java.util.Map;