@ -3,7 +3,7 @@ package org.nl.hand.amb.rest;
import cn.dev33.satoken.annotation.SaIgnore ;
import cn.dev33.satoken.annotation.SaIgnore ;
import cn.hutool.core.util.StrUtil ;
import com.alibaba.fastjson.JSONObject ;
import io.swagger.annotations.Api ;
import io.swagger.annotations.Api ;
import io.swagger.annotations.ApiOperation ;
import io.swagger.annotations.ApiOperation ;
import lombok.RequiredArgsConstructor ;
import lombok.RequiredArgsConstructor ;
@ -29,15 +29,15 @@ import java.util.Map;
@RequestMapping ( "/api/hand" )
@RequestMapping ( "/api/hand" )
@Slf4j
@Slf4j
public class HFHandController {
public class HFHandController {
private final HFHandService H andService;
private final HFHandService h andService;
@PostMapping ( "/area " )
@PostMapping ( "/region " )
@Log ( "查询区域" )
@Log ( "查询区域" )
@ApiOperation ( "查询区域" )
@ApiOperation ( "查询区域" )
@SaIgnore
@SaIgnore
//@PreAuthorize("@el.check('sect:list')")
//@PreAuthorize("@el.check('sect:list')")
public ResponseEntity < Object > query ( ) {
public ResponseEntity < Object > query ( ) {
return new ResponseEntity < > ( H andService. queryArea ( null ) , HttpStatus . OK ) ;
return new ResponseEntity < > ( h andService. queryArea ( null ) , HttpStatus . OK ) ;
}
}
@PostMapping ( "/point" )
@PostMapping ( "/point" )
@ -47,8 +47,8 @@ public class HFHandController {
//@PreAuthorize("@el.check('sect:list')")
//@PreAuthorize("@el.check('sect:list')")
//@RequestBody JSONObject json
//@RequestBody JSONObject json
public ResponseEntity < Object > queryPoint ( @RequestBody Map < String , String > whereJson ) {
public ResponseEntity < Object > queryPoint ( @RequestBody Map < String , String > whereJson ) {
String region = ( String ) whereJson . get ( "region" ) ;
String region = whereJson . get ( "region_code " ) ;
return new ResponseEntity < > ( H andService. queryPointByArea ( region ) , HttpStatus . OK ) ;
return new ResponseEntity < > ( h andService. queryPointByArea ( region ) , HttpStatus . OK ) ;
}
}
@PostMapping ( "/point/storage" )
@PostMapping ( "/point/storage" )
@ -58,7 +58,7 @@ public class HFHandController {
//@PreAuthorize("@el.check('sect:list')")
//@PreAuthorize("@el.check('sect:list')")
//@RequestBody JSONObject json
//@RequestBody JSONObject json
public ResponseEntity < Object > queryDeviceAugmentabilityByCode ( @RequestBody Map < String , String > whereJson ) {
public ResponseEntity < Object > queryDeviceAugmentabilityByCode ( @RequestBody Map < String , String > whereJson ) {
return new ResponseEntity < > ( H andService. queryDeviceAugmentabilityByCode ( whereJson ) , HttpStatus . OK ) ;
return new ResponseEntity < > ( h andService. queryDeviceAugmentabilityByCode ( whereJson ) , HttpStatus . OK ) ;
}
}
@PostMapping ( "/task_type" )
@PostMapping ( "/task_type" )
@ -68,7 +68,7 @@ public class HFHandController {
//@PreAuthorize("@el.check('sect:list')")
//@PreAuthorize("@el.check('sect:list')")
//@RequestBody JSONObject json
//@RequestBody JSONObject json
public ResponseEntity < Object > queryTaskType ( ) {
public ResponseEntity < Object > queryTaskType ( ) {
return new ResponseEntity < > ( H andService. queryTaskType ( ) , HttpStatus . OK ) ;
return new ResponseEntity < > ( h andService. queryTaskType ( ) , HttpStatus . OK ) ;
}
}
@PostMapping ( "/tasks" )
@PostMapping ( "/tasks" )
@ -78,7 +78,7 @@ public class HFHandController {
//@PreAuthorize("@el.check('sect:list')")
//@PreAuthorize("@el.check('sect:list')")
public ResponseEntity < Object > queryTask ( @RequestBody Map < String , String > whereJson ) {
public ResponseEntity < Object > queryTask ( @RequestBody Map < String , String > whereJson ) {
return new ResponseEntity < > ( H andService. queryTask ( whereJson ) , HttpStatus . OK ) ;
return new ResponseEntity < > ( h andService. queryTask ( whereJson ) , HttpStatus . OK ) ;
}
}
@PostMapping ( "/insts" )
@PostMapping ( "/insts" )
@ -88,7 +88,7 @@ public class HFHandController {
//@PreAuthorize("@el.check('sect:list')")
//@PreAuthorize("@el.check('sect:list')")
public ResponseEntity < Object > queryInst ( @RequestBody Map < String , String > whereJson ) {
public ResponseEntity < Object > queryInst ( @RequestBody Map < String , String > whereJson ) {
return new ResponseEntity < > ( H andService. queryInst ( whereJson ) , HttpStatus . OK ) ;
return new ResponseEntity < > ( h andService. queryInst ( whereJson ) , HttpStatus . OK ) ;
}
}
@PostMapping ( "/routeplan_type" )
@PostMapping ( "/routeplan_type" )
@ -97,7 +97,7 @@ public class HFHandController {
@SaIgnore
@SaIgnore
//@PreAuthorize("@el.check('sect:list')")
//@PreAuthorize("@el.check('sect:list')")
public ResponseEntity < Object > queryRouteplanType ( ) {
public ResponseEntity < Object > queryRouteplanType ( ) {
return new ResponseEntity < > ( H andService. queryRouteplanType ( ) , HttpStatus . OK ) ;
return new ResponseEntity < > ( h andService. queryRouteplanType ( ) , HttpStatus . OK ) ;
}
}
@PostMapping ( "/task" )
@PostMapping ( "/task" )
@ -106,7 +106,7 @@ public class HFHandController {
@SaIgnore
@SaIgnore
//@PreAuthorize("@el.check('sect:list')")
//@PreAuthorize("@el.check('sect:list')")
public ResponseEntity < Object > createTask ( @RequestBody Map < String , String > whereJson ) {
public ResponseEntity < Object > createTask ( @RequestBody Map < String , String > whereJson ) {
return new ResponseEntity < > ( H andService. createTask ( whereJson ) , HttpStatus . OK ) ;
return new ResponseEntity < > ( h andService. createTask ( whereJson ) , HttpStatus . OK ) ;
}
}
@PostMapping ( "/inst" )
@PostMapping ( "/inst" )
@ -115,7 +115,7 @@ public class HFHandController {
@SaIgnore
@SaIgnore
//@PreAuthorize("@el.check('sect:list')")
//@PreAuthorize("@el.check('sect:list')")
public ResponseEntity < Object > Instoperation ( @RequestBody Map < String , String > whereJson ) {
public ResponseEntity < Object > Instoperation ( @RequestBody Map < String , String > whereJson ) {
return new ResponseEntity < > ( H andService. Instoperation ( whereJson ) , HttpStatus . OK ) ;
return new ResponseEntity < > ( h andService. Instoperation ( whereJson ) , HttpStatus . OK ) ;
}
}
@PostMapping ( "/taskoperation" )
@PostMapping ( "/taskoperation" )
@ -124,7 +124,7 @@ public class HFHandController {
@SaIgnore
@SaIgnore
//@PreAuthorize("@el.check('sect:list')")
//@PreAuthorize("@el.check('sect:list')")
public ResponseEntity < Object > Taskoperation ( @RequestBody Map < String , String > whereJson ) throws Exception {
public ResponseEntity < Object > Taskoperation ( @RequestBody Map < String , String > whereJson ) throws Exception {
return new ResponseEntity < > ( H andService. Taskoperation ( whereJson ) , HttpStatus . OK ) ;
return new ResponseEntity < > ( h andService. Taskoperation ( whereJson ) , HttpStatus . OK ) ;
}
}
@PostMapping ( "/deviceStatus" )
@PostMapping ( "/deviceStatus" )
@ -134,7 +134,7 @@ public class HFHandController {
//@PreAuthorize("@el.check('sect:list')")
//@PreAuthorize("@el.check('sect:list')")
public ResponseEntity < Object > updateDeviceStatus ( @RequestBody Map < String , String > whereJson ) {
public ResponseEntity < Object > updateDeviceStatus ( @RequestBody Map < String , String > whereJson ) {
return new ResponseEntity < > ( H andService. updateDeviceStatus ( whereJson ) , HttpStatus . OK ) ;
return new ResponseEntity < > ( h andService. updateDeviceStatus ( whereJson ) , HttpStatus . OK ) ;
}
}
@PostMapping ( "/handlogin" )
@PostMapping ( "/handlogin" )
@ -144,7 +144,7 @@ public class HFHandController {
//@PreAuthorize("@el.check('sect:list')")
//@PreAuthorize("@el.check('sect:list')")
public ResponseEntity < Object > handlogin ( @RequestBody Map < String , String > whereJson ) {
public ResponseEntity < Object > handlogin ( @RequestBody Map < String , String > whereJson ) {
return new ResponseEntity < > ( H andService. handleLogin ( whereJson ) , HttpStatus . OK ) ;
return new ResponseEntity < > ( h andService. handleLogin ( whereJson ) , HttpStatus . OK ) ;
}
}
@PostMapping ( "/matrial" )
@PostMapping ( "/matrial" )
@ -153,7 +153,7 @@ public class HFHandController {
@SaIgnore
@SaIgnore
//@PreAuthorize("@el.check('sect:list')")
//@PreAuthorize("@el.check('sect:list')")
public ResponseEntity < Object > queryMaterial ( ) {
public ResponseEntity < Object > queryMaterial ( ) {
return new ResponseEntity < > ( H andService. queryMaterial ( ) , HttpStatus . OK ) ;
return new ResponseEntity < > ( h andService. queryMaterial ( ) , HttpStatus . OK ) ;
}
}
@PostMapping ( "/task2" )
@PostMapping ( "/task2" )
@ -162,7 +162,7 @@ public class HFHandController {
@SaIgnore
@SaIgnore
//@PreAuthorize("@el.check('sect:list')")
//@PreAuthorize("@el.check('sect:list')")
public ResponseEntity < Object > createTask2 ( @RequestBody Map < String , String > whereJson ) {
public ResponseEntity < Object > createTask2 ( @RequestBody Map < String , String > whereJson ) {
return new ResponseEntity < > ( H andService. createTask2 ( whereJson ) , HttpStatus . OK ) ;
return new ResponseEntity < > ( h andService. createTask2 ( whereJson ) , HttpStatus . OK ) ;
}
}
@PostMapping ( "/createChargingTask" )
@PostMapping ( "/createChargingTask" )
@ -171,7 +171,25 @@ public class HFHandController {
@SaIgnore
@SaIgnore
//@PreAuthorize("@el.check('sect:list')")
//@PreAuthorize("@el.check('sect:list')")
public ResponseEntity < Object > createChargingTask ( @RequestBody Map < String , String > whereJson ) {
public ResponseEntity < Object > createChargingTask ( @RequestBody Map < String , String > whereJson ) {
return new ResponseEntity < > ( HandService . createChargingTask ( whereJson ) , HttpStatus . OK ) ;
return new ResponseEntity < > ( handService . createChargingTask ( whereJson ) , HttpStatus . OK ) ;
}
@PostMapping ( "/material" )
@Log ( "查询物料" )
@ApiOperation ( "查询物料" )
@SaIgnore
//@PreAuthorize("@el.check('sect:list')")
public ResponseEntity < Object > material ( ) {
return new ResponseEntity < > ( handService . material ( ) , HttpStatus . OK ) ;
}
@PostMapping ( "/pointOpt" )
@Log ( "点位操作" )
@ApiOperation ( "点位操作" )
@SaIgnore
//@PreAuthorize("@el.check('sect:list')")
public ResponseEntity < Object > pointOpt ( @RequestBody JSONObject param ) {
return new ResponseEntity < > ( handService . pointOpt ( param ) , HttpStatus . OK ) ;
}
}
}
}