Pu Zhibing
1 天以前 ddf438536267b9c9bb77369cdccce4e67206842a
DriverGOPOSTTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/api/DriverController.java
@@ -186,7 +186,7 @@
    @ResponseBody
    @PostMapping("/base/driver/queryEmailCaptcha")
    @ApiOperation(value = "发送验证码【1.0】", tags = {"司机端-注册"}, notes = "")
    @ApiOperation(value = "发送验证码", tags = {"司机端-注册"}, notes = "")
    @ApiImplicitParams({
            @ApiImplicitParam(value = "邮箱地址", name = "email", required = true, dataType = "String"),
    })
@@ -376,7 +376,7 @@
    @ResponseBody
    @PostMapping("/api/driver/editEmail")
    @ApiOperation(value = "个人中心修改邮箱【1.0】", tags = {"司机端-个人中心"}, notes = "")
    @ApiOperation(value = "个人中心修改邮箱", tags = {"司机端-个人中心"}, notes = "")
    @ApiImplicitParams({
            @ApiImplicitParam(value = "邮箱", name = "email", required = true, dataType = "string"),
            @ApiImplicitParam(name = "Authorization", value = "Bearer +token", required = true, dataType = "String", paramType = "header", defaultValue = "Bearer eyJhbGciOiJIUzUxMiJ9.....")
@@ -436,7 +436,7 @@
     */
    @ResponseBody
    @PostMapping("/base/driver/addDriverCar")
    @ApiOperation(value = "司机注册后完善车辆信息【1.0】", tags = {"司机端-注册"}, notes = "")
    @ApiOperation(value = "司机注册后完善车辆信息", tags = {"司机端-注册"}, notes = "")
    @ApiImplicitParams({
            @ApiImplicitParam(value = "车辆型号id", name = "modelId", required = true, dataType = "int"),
            @ApiImplicitParam(value = "车辆颜色", name = "color", required = true, dataType = "string"),
@@ -548,7 +548,7 @@
     */
    @ResponseBody
    @PostMapping("/base/driver/queryPhone")
    @ApiOperation(value = "获取忘记密码页面的电话【1.0】", tags = {"司机端-登录"}, notes = "")
    @ApiOperation(value = "获取忘记密码页面的电话", tags = {"司机端-登录"}, notes = "")
    @ApiImplicitParams({
            @ApiImplicitParam(value = "当前定位纬度", name = "lat", required = true, dataType = "double"),
            @ApiImplicitParam(value = "当前定位经度", name = "lnt", required = true, dataType = "double")
@@ -627,7 +627,7 @@
     */
    @ResponseBody
    @PostMapping("/api/driver/work")
    @ApiOperation(value = "司机上下班操作【1.0】", tags = {"司机端-首页"}, notes = "")
    @ApiOperation(value = "司机上下班操作", tags = {"司机端-首页"}, notes = "")
    @ApiImplicitParams({
            @ApiImplicitParam(value = "上班的业务类型(1=专车,4=小件物流-同城)多个已逗号分隔", name = "type", required = false, dataType = "String"),
            @ApiImplicitParam(name = "Authorization", value = "Bearer +token", required = true, dataType = "String", paramType = "header", defaultValue = "Bearer eyJhbGciOiJIUzUxMiJ9.....")
@@ -708,7 +708,7 @@
    @ResponseBody
    @PostMapping("/api/driver/work2")
    @ApiOperation(value = "司机上下班操作,同时设置接单类型【1.0】", tags = {"司机端-车载端"}, notes = "")
    @ApiOperation(value = "司机上下班操作,同时设置接单类型", tags = {"司机端-车载端"}, notes = "")
    @ApiImplicitParams({
            @ApiImplicitParam(value = "上班的业务类型(1=专车,4=小件物流-同城)多个已逗号分隔", name = "type", required = false, dataType = "String"),
            @ApiImplicitParam(name = "Authorization", value = "Bearer +token", required = true, dataType = "String", paramType = "header", defaultValue = "Bearer eyJhbGciOiJIUzUxMiJ9.....")
@@ -820,7 +820,7 @@
     */
    @ResponseBody
    @PostMapping("/api/driver/queryInfo")
    @ApiOperation(value = "获取个人中心详情【1.0】", tags = {"司机端-个人中心"}, notes = "")
    @ApiOperation(value = "获取个人中心详情", tags = {"司机端-个人中心"}, notes = "")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "Authorization", value = "Bearer +token", required = true, dataType = "String", paramType = "header", defaultValue = "Bearer eyJhbGciOiJIUzUxMiJ9.....")
    })
@@ -895,7 +895,7 @@
    @ResponseBody
    @PostMapping("/api/driver/editLanguage")
    @ApiOperation(value = "修改系统语言【1.0】", tags = {"司机端-个人中心"}, notes = "")
    @ApiOperation(value = "修改系统语言", tags = {"司机端-个人中心"}, notes = "")
    @ApiImplicitParams({
            @ApiImplicitParam(value = "语言类型(1=简体中文,2=英语,3=法语)", name = "language", required = true, dataType = "String"),
            @ApiImplicitParam(name = "Authorization", value = "Bearer +token", required = true, dataType = "String", paramType = "header", defaultValue = "Bearer eyJhbGciOiJIUzUxMiJ9.....")
@@ -1208,7 +1208,7 @@
     */
    @ResponseBody
    @PostMapping("/api/driver/queryTotalRevenue")
    @ApiOperation(value = "获取收入明细【2.0】", tags = {"司机端-个人中心"}, notes = "")
    @ApiOperation(value = "获取收入明细", tags = {"司机端-个人中心"}, notes = "")
    @ApiImplicitParams({
            @ApiImplicitParam(value = "页码,首页1", name = "pageNum", required = true, dataType = "int"),
            @ApiImplicitParam(value = "页条数", name = "size", required = true, dataType = "int"),
@@ -1750,7 +1750,7 @@
    
    @ResponseBody
    @PostMapping("/api/driver/queryBalanceUsageRecord")
    @ApiOperation(value = "获取余额使用记录【2.0】", tags = {"司机端-个人中心"}, notes = "")
    @ApiOperation(value = "获取余额使用记录", tags = {"司机端-个人中心"}, notes = "")
    @ApiImplicitParams({
            @ApiImplicitParam(value = "页码,首页1", name = "pageNum", required = true, dataType = "int"),
            @ApiImplicitParam(value = "页条数", name = "size", required = true, dataType = "int"),
@@ -1775,29 +1775,29 @@
    
    
    
    @ResponseBody
    @PostMapping("/api/driver/getFleetEngineAuth")
    @ApiOperation(value = "获取google地图授权token", tags = {"司机端-个人中心"}, notes = "")
    @ApiImplicitParams({
            @ApiImplicitParam(value = "车辆id", name = "vehicleId", required = true, dataType = "string"),
            @ApiImplicitParam(name = "Authorization", value = "Bearer +token", required = true, dataType = "String", paramType = "header", defaultValue = "Bearer eyJhbGciOiJIUzUxMiJ9.....")
    })
    public ResultUtil<Map<String, Object>> getFleetEngineAuth(String vehicleId, HttpServletRequest request){
        try {
            Integer uid = driverService.getUserIdFormRedis(request);
            if(null == uid){
                return ResultUtil.tokenErr();
            }
            if(!StringUtils.hasLength(vehicleId)){
                return ResultUtil.paranErr();
            }
            Map<String, Object> s = fleetEngineUtil.fleetEngineAuth(2, vehicleId);
            return ResultUtil.success(s);
        }catch (Exception e){
            e.printStackTrace();
            return ResultUtil.runErr();
        }
    }
//    @ResponseBody
//    @PostMapping("/api/driver/getFleetEngineAuth")
//    @ApiOperation(value = "获取google地图授权token", tags = {"司机端-个人中心"}, notes = "")
//    @ApiImplicitParams({
//            @ApiImplicitParam(value = "车辆id", name = "vehicleId", required = true, dataType = "string"),
//            @ApiImplicitParam(name = "Authorization", value = "Bearer +token", required = true, dataType = "String", paramType = "header", defaultValue = "Bearer eyJhbGciOiJIUzUxMiJ9.....")
//    })
//    public ResultUtil<Map<String, Object>> getFleetEngineAuth(String vehicleId, HttpServletRequest request){
//        try {
//            Integer uid = driverService.getUserIdFormRedis(request);
//            if(null == uid){
//                return ResultUtil.tokenErr();
//            }
//            if(!StringUtils.hasLength(vehicleId)){
//                return ResultUtil.paranErr();
//            }
//            Map<String, Object> s = fleetEngineUtil.fleetEngineAuth(2, vehicleId);
//            return ResultUtil.success(s);
//        }catch (Exception e){
//            e.printStackTrace();
//            return ResultUtil.runErr();
//        }
//    }