|
@ -3,6 +3,7 @@ package org.nl.wms.pda.controller; |
|
|
import cn.dev33.satoken.annotation.SaIgnore; |
|
|
import cn.dev33.satoken.annotation.SaIgnore; |
|
|
import com.alibaba.fastjson.JSONObject; |
|
|
import com.alibaba.fastjson.JSONObject; |
|
|
import lombok.extern.slf4j.Slf4j; |
|
|
import lombok.extern.slf4j.Slf4j; |
|
|
|
|
|
import org.nl.common.annotation.Limit; |
|
|
import org.nl.common.logging.annotation.Log; |
|
|
import org.nl.common.logging.annotation.Log; |
|
|
import org.nl.wms.das.device.check.service.IDasDeviceCheckRecordService; |
|
|
import org.nl.wms.das.device.check.service.IDasDeviceCheckRecordService; |
|
|
import org.nl.wms.das.device.check.service.dao.DasDeviceCheckRecord; |
|
|
import org.nl.wms.das.device.check.service.dao.DasDeviceCheckRecord; |
|
@ -44,56 +45,48 @@ public class PdaController { |
|
|
|
|
|
|
|
|
@PostMapping("/deviceCheck/verify") |
|
|
@PostMapping("/deviceCheck/verify") |
|
|
@Log("设备点检") |
|
|
@Log("设备点检") |
|
|
|
|
|
|
|
|
public ResponseEntity<Object> deviceCheck(@Validated @RequestBody DasDeviceCheckRecord entity) { |
|
|
public ResponseEntity<Object> deviceCheck(@Validated @RequestBody DasDeviceCheckRecord entity) { |
|
|
return new ResponseEntity<>(deviceCheckRecordService.create(entity), HttpStatus.OK); |
|
|
return new ResponseEntity<>(deviceCheckRecordService.create(entity), HttpStatus.OK); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@PostMapping("/deviceCheck/deviceInfo") |
|
|
@PostMapping("/deviceCheck/deviceInfo") |
|
|
@Log("设备下拉框数据") |
|
|
@Log("设备下拉框数据") |
|
|
|
|
|
|
|
|
public ResponseEntity<Object> deviceInfo() { |
|
|
public ResponseEntity<Object> deviceInfo() { |
|
|
return new ResponseEntity<>(pdaService.getDeviceInfo(), HttpStatus.OK); |
|
|
return new ResponseEntity<>(pdaService.getDeviceInfo(), HttpStatus.OK); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@PostMapping("/deviceCheck/deviceStatus") |
|
|
@PostMapping("/deviceCheck/deviceStatus") |
|
|
@Log("设备状态下拉框数据") |
|
|
@Log("设备状态下拉框数据") |
|
|
|
|
|
|
|
|
public ResponseEntity<Object> deviceStatus() { |
|
|
public ResponseEntity<Object> deviceStatus() { |
|
|
return new ResponseEntity<>(pdaService.getDeviceStatus(), HttpStatus.OK); |
|
|
return new ResponseEntity<>(pdaService.getDeviceStatus(), HttpStatus.OK); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@PostMapping("/deviceSwitchover/deviceAction") |
|
|
@PostMapping("/deviceSwitchover/deviceAction") |
|
|
@Log("设备动作下拉框数据") |
|
|
@Log("设备动作下拉框数据") |
|
|
|
|
|
|
|
|
public ResponseEntity<Object> deviceAction() { |
|
|
public ResponseEntity<Object> deviceAction() { |
|
|
return new ResponseEntity<>(pdaService.deviceAction(), HttpStatus.OK); |
|
|
return new ResponseEntity<>(pdaService.deviceAction(), HttpStatus.OK); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@PostMapping("/deviceSwitchover/verify") |
|
|
@PostMapping("/deviceSwitchover/verify") |
|
|
@Log("设备动作切换") |
|
|
@Log("设备动作切换") |
|
|
|
|
|
|
|
|
public ResponseEntity<Object> deviceSwitchover(@Validated @RequestBody DasDeviceOperationRecord entity) { |
|
|
public ResponseEntity<Object> deviceSwitchover(@Validated @RequestBody DasDeviceOperationRecord entity) { |
|
|
return new ResponseEntity<>(deviceOperationRecordService.create(entity), HttpStatus.OK); |
|
|
return new ResponseEntity<>(deviceOperationRecordService.create(entity), HttpStatus.OK); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@PostMapping("/group/getPressCode") |
|
|
@PostMapping("/group/getPressCode") |
|
|
@Log("获取压机编码") |
|
|
@Log("获取压机编码") |
|
|
|
|
|
|
|
|
public ResponseEntity<Object> getPressCode() { |
|
|
public ResponseEntity<Object> getPressCode() { |
|
|
return new ResponseEntity<>(pdaService.getDeviceInfo(), HttpStatus.OK); |
|
|
return new ResponseEntity<>(pdaService.getDeviceInfo(), HttpStatus.OK); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@PostMapping("/group/getVehicleType") |
|
|
@PostMapping("/group/getVehicleType") |
|
|
@Log("获取载具类型") |
|
|
@Log("获取载具类型") |
|
|
|
|
|
|
|
|
public ResponseEntity<Object> getVehicleType() { |
|
|
public ResponseEntity<Object> getVehicleType() { |
|
|
return new ResponseEntity<>(pdaService.getVehicleType(), HttpStatus.OK); |
|
|
return new ResponseEntity<>(pdaService.getVehicleType(), HttpStatus.OK); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@PostMapping("/group/getPressWorkOrder") |
|
|
@PostMapping("/group/getPressWorkOrder") |
|
|
@Log("获取工单编码") |
|
|
@Log("获取工单编码") |
|
|
|
|
|
|
|
|
@Deprecated |
|
|
@Deprecated |
|
|
public ResponseEntity<Object> getPressWorkOrder(@RequestBody JSONObject param) { |
|
|
public ResponseEntity<Object> getPressWorkOrder(@RequestBody JSONObject param) { |
|
|
return new ResponseEntity<>(workorderService.getDeviceProductionTask(param.getString("point_code")), HttpStatus.OK); |
|
|
return new ResponseEntity<>(workorderService.getDeviceProductionTask(param.getString("point_code")), HttpStatus.OK); |
|
@ -101,56 +94,48 @@ public class PdaController { |
|
|
|
|
|
|
|
|
@PostMapping("/group/manual") |
|
|
@PostMapping("/group/manual") |
|
|
@Log("人工组盘") |
|
|
@Log("人工组盘") |
|
|
|
|
|
|
|
|
public ResponseEntity<PdaResponseVo> manualDiskAssembly(@Validated @RequestBody ManualGroupDto entity) { |
|
|
public ResponseEntity<PdaResponseVo> manualDiskAssembly(@Validated @RequestBody ManualGroupDto entity) { |
|
|
return new ResponseEntity<>(pdaService.manualCreateByPda(entity), HttpStatus.OK); |
|
|
return new ResponseEntity<>(pdaService.manualCreateByPda(entity), HttpStatus.OK); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@PostMapping("/move/getBlendingCode") |
|
|
@PostMapping("/move/getBlendingCode") |
|
|
@Log("获取混碾机编码") |
|
|
@Log("获取混碾机编码") |
|
|
|
|
|
|
|
|
public ResponseEntity<Object> getBlendingCode() { |
|
|
public ResponseEntity<Object> getBlendingCode() { |
|
|
return new ResponseEntity<>(pdaService.getBlendingCode(), HttpStatus.OK); |
|
|
return new ResponseEntity<>(pdaService.getBlendingCode(), HttpStatus.OK); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@PostMapping("/move/sendTask") |
|
|
@PostMapping("/move/sendTask") |
|
|
@Log("生成混碾->压机任务") |
|
|
@Log("生成混碾->压机任务") |
|
|
|
|
|
|
|
|
public ResponseEntity<PdaResponseVo> sendTask(@Validated @RequestBody BlendingMoveDto blendingMoveDto) { |
|
|
public ResponseEntity<PdaResponseVo> sendTask(@Validated @RequestBody BlendingMoveDto blendingMoveDto) { |
|
|
return new ResponseEntity<>(pdaService.sendTask(blendingMoveDto), HttpStatus.OK); |
|
|
return new ResponseEntity<>(pdaService.sendTask(blendingMoveDto), HttpStatus.OK); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@PostMapping("/forcedResting/show") |
|
|
@PostMapping("/forcedResting/show") |
|
|
@Log("显示静置时长") |
|
|
@Log("显示静置时长") |
|
|
|
|
|
|
|
|
public ResponseEntity<Object> forcedRestingShow() { |
|
|
public ResponseEntity<Object> forcedRestingShow() { |
|
|
return new ResponseEntity<>(pdaService.forcedRestingShow(), HttpStatus.OK); |
|
|
return new ResponseEntity<>(pdaService.forcedRestingShow(), HttpStatus.OK); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@PostMapping("/forcedResting/submit") |
|
|
@PostMapping("/forcedResting/submit") |
|
|
@Log("强制静置") |
|
|
@Log("强制静置") |
|
|
|
|
|
|
|
|
public ResponseEntity<PdaResponseVo> forcedResting(@Validated @RequestBody ForcedRestingDto forcedRestingDto) { |
|
|
public ResponseEntity<PdaResponseVo> forcedResting(@Validated @RequestBody ForcedRestingDto forcedRestingDto) { |
|
|
return new ResponseEntity<>(pdaService.forcedResting(forcedRestingDto), HttpStatus.OK); |
|
|
return new ResponseEntity<>(pdaService.forcedResting(forcedRestingDto), HttpStatus.OK); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@PostMapping("/manualSorting/orders") |
|
|
@PostMapping("/manualSorting/orders") |
|
|
@Log("人工分拣-显示工单") |
|
|
@Log("人工分拣-显示工单") |
|
|
|
|
|
|
|
|
public ResponseEntity<Object> manualOrders() { |
|
|
public ResponseEntity<Object> manualOrders() { |
|
|
return new ResponseEntity<>(pdaService.manualOrders(), HttpStatus.OK); |
|
|
return new ResponseEntity<>(pdaService.manualOrders(), HttpStatus.OK); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@PostMapping("/manualSorting/productionScheduling") |
|
|
@PostMapping("/manualSorting/productionScheduling") |
|
|
@Log("人工分拣-开工") |
|
|
@Log("人工分拣-开工") |
|
|
|
|
|
|
|
|
public ResponseEntity<PdaResponseVo> productionScheduling(@Validated @RequestBody ManualSortingDto manualSortingDto) { |
|
|
public ResponseEntity<PdaResponseVo> productionScheduling(@Validated @RequestBody ManualSortingDto manualSortingDto) { |
|
|
return new ResponseEntity<>(pdaService.productionScheduling(manualSortingDto), HttpStatus.OK); |
|
|
return new ResponseEntity<>(pdaService.productionScheduling(manualSortingDto), HttpStatus.OK); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
@PostMapping("/manualSorting/productionComplete") |
|
|
@PostMapping("/manualSorting/productionComplete") |
|
|
@Log("人工分拣-完工") |
|
|
@Log("人工分拣-完工") |
|
|
|
|
|
|
|
|
public ResponseEntity<PdaResponseVo> productionComplete(@Validated @RequestBody ManualSortingDto manualSortingDto) { |
|
|
public ResponseEntity<PdaResponseVo> productionComplete(@Validated @RequestBody ManualSortingDto manualSortingDto) { |
|
|
return new ResponseEntity<>(pdaService.productionComplete(manualSortingDto), HttpStatus.OK); |
|
|
return new ResponseEntity<>(pdaService.productionComplete(manualSortingDto), HttpStatus.OK); |
|
|
} |
|
|
} |
|
@ -227,7 +212,7 @@ public class PdaController { |
|
|
|
|
|
|
|
|
@PostMapping("/manualSorting/bindingVehicle") |
|
|
@PostMapping("/manualSorting/bindingVehicle") |
|
|
@Log("人工分拣-载具绑定") |
|
|
@Log("人工分拣-载具绑定") |
|
|
|
|
|
@Limit(period = 2, count = 1) |
|
|
public ResponseEntity<PdaResponseVo> bindingVehicle(@Validated @RequestBody VehicleBindingDto vehicleBindingDto) { |
|
|
public ResponseEntity<PdaResponseVo> bindingVehicle(@Validated @RequestBody VehicleBindingDto vehicleBindingDto) { |
|
|
return new ResponseEntity<>(pdaService.bindingVehicle(vehicleBindingDto), HttpStatus.OK); |
|
|
return new ResponseEntity<>(pdaService.bindingVehicle(vehicleBindingDto), HttpStatus.OK); |
|
|
} |
|
|
} |
|
|