| | |
| | | import com.zy.core.model.protocol.StaProtocol; |
| | | import com.zy.core.properties.SlaveProperties; |
| | | import com.zy.core.properties.SystemProperties; |
| | | import com.zy.core.thread.BarcodeThread; |
| | | import com.zy.core.thread.MelsecCrnThread; |
| | | import com.zy.core.thread.ScaleThread; |
| | | import com.zy.core.thread.*; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | |
| | | CrnDetailVo vo = new CrnDetailVo(); |
| | | for (CrnSlave crnSlave : slaveProperties.getCrn()) { |
| | | if (crnSlave.getId().equals(crnNo)) { |
| | | MelsecCrnThread crnThread = (MelsecCrnThread) SlaveConnection.get(SlaveType.Crn, crnSlave.getId()); |
| | | SiemensCrnThread crnThread=(SiemensCrnThread) SlaveConnection.get(SlaveType.Crn, crnSlave.getId()); |
| | | // MelsecCrnThread crnThread = (MelsecCrnThread) SlaveConnection.get(SlaveType.Crn, crnSlave.getId()); |
| | | CrnProtocol crnProtocol = crnThread.getCrnProtocol(); |
| | | vo.setCrnNo(crnNo); |
| | | vo.setWorkNo(crnProtocol.getTaskNo()); |
| | |
| | | } |
| | | return R.error(); |
| | | } |
| | | @PostMapping("/loc/detail2") |
| | | @ManagerAuth(memo = "0101804库位数据详情") |
| | | public R locDetail2(@RequestParam String locNo) { |
| | | if (Cools.isEmpty(locNo)) { |
| | | return R.parse(CodeRes.EMPTY); |
| | | } |
| | | LocMast locMast = locMastService.selectOne(new EntityWrapper<LocMast>().eq("loc_no",locNo)); |
| | | LocDetailVo vo = new LocDetailVo(); |
| | | vo.setChannel(locMast.getChannel()); |
| | | vo.setPackStatus(PackStatusType.process(locMast.getLocSts(),locMast.getPackStatus(),locMast.getFireStatus())); |
| | | return R.ok().add(vo); |
| | | } |
| | | |
| | | @Deprecated |
| | | @PostMapping("/site/update") |