| | |
| | | import com.zy.core.properties.SlaveProperties; |
| | | import com.zy.core.properties.SystemProperties; |
| | | import com.zy.core.thread.RgvThread; |
| | | import com.zy.task.CrnTiltRecordTask; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | | import org.springframework.web.bind.annotation.PostMapping; |
| | | import org.springframework.web.bind.annotation.RequestMapping; |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.util.ArrayList; |
| | |
| | | private MainServiceImpl mainService; |
| | | @Autowired |
| | | private LocMastService locMastService; |
| | | @Autowired |
| | | private CrnTiltRecordTask crnTiltRecordTask; |
| | | |
| | | |
| | | @ManagerAuth(memo = "进行中的命令") |
| | |
| | | return false; |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 手动触发堆垛机倾斜度记录 |
| | | * @param crnNo 堆垛机编号,如果为空则记录所有堆垛机 |
| | | * @return |
| | | */ |
| | | @PostMapping("/tiltRecord/manual") |
| | | @ManagerAuth |
| | | public R manualTiltRecord(@RequestParam(required = false) Integer crnNo) { |
| | | try { |
| | | crnTiltRecordTask.manualRecord(crnNo); |
| | | return R.ok("手动触发倾斜度记录成功"); |
| | | } catch (Exception e) { |
| | | log.error("手动触发倾斜度记录失败", e); |
| | | return R.error("手动触发失败:" + e.getMessage()); |
| | | } |
| | | } |
| | | } |