liujie
7 天以前 570ae72b8ab5cf51b91fd6dc48411710dbf04125
UserQYTTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/api/OrderController.java
@@ -582,6 +582,41 @@
    }
    @ResponseBody
    @PostMapping("/api/order/addAppeal")
    @ApiOperation(value = "发起申诉", tags = {"用户端-服务中"}, notes = "",response = OrderInfoWarpper.class)
    @ApiImplicitParams({
            @ApiImplicitParam(value = "订单id", name = "orderId", required = true, dataType = "int"),
            @ApiImplicitParam(value = "订单类型(1=专车,2=出租车,3=城际)", name = "orderType", required = true, dataType = "int"),
            @ApiImplicitParam(value = "申诉描述", name = "abnormalIntro", required = true, dataType = "String"),
            @ApiImplicitParam(value = "申诉图片", name = "abnormalImg", required = true, dataType = "String"),
            @ApiImplicitParam(name = "Authorization", value = "Bearer +token", required = true, dataType = "String", paramType = "header", defaultValue = "Bearer eyJhbGciOiJIUzUxMiJ9.....")
    })
    public ResultUtil<OrderInfoWarpper> addAppeal(Integer orderId, Integer orderType,String abnormalIntro, String abnormalImg, HttpServletRequest request){
        try {
            Integer uid = userInfoService.getUserIdFormRedis(request);
            if(null == uid){
                return ResultUtil.tokenErr();
            }
            switch (orderType){
                case 1://专车
                     orderPrivateCarService.addAppeal(uid, orderId,abnormalIntro,abnormalImg);
                    break;
                case 2://出租车
                    orderTaxiService.addAppeal(uid,orderId,abnormalIntro,abnormalImg);
                    break;
                case 3://跨城
                     orderCrossCityService.addAppeal(uid,orderId,abnormalIntro,abnormalImg);
                    break;
            }
            return ResultUtil.success();
        }catch (Exception e){
            e.printStackTrace();
            return ResultUtil.runErr();
        }
    }
    /**
     * 获取服务中的详情数据