| | |
| | | import com.fzzy.igds.camera.ApiCameraManager; |
| | | import com.fzzy.igds.camera.data.ApiCameraData; |
| | | import com.fzzy.igds.camera.data.ApiCameraResp; |
| | | import com.fzzy.igds.constant.DepotType; |
| | | import com.fzzy.igds.constant.OrderRespEnum; |
| | | import com.fzzy.igds.constant.RespCodeEnum; |
| | | import com.fzzy.igds.data.*; |
| | |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.util.Date; |
| | | import java.util.HashMap; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | import java.util.*; |
| | | |
| | | /** |
| | | * @Description |
| | |
| | | request.setDeptId(conf.getDeptId()); |
| | | request.setSn(conf.getSn()); |
| | | request.setLength(conf.getLength()); |
| | | request.setExeUser(ContextUtil.getLoginUserName()); |
| | | |
| | | request.setBatchId(conf.getDepotId() + "_" + DateFormatUtils.format(new Date(), "yyyyMMddHHmm")); |
| | | |
| | |
| | | |
| | | return remoteQuantityService.checkStop(request); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 获取油罐油情及液位信息 |
| | | * |
| | | * @param deptId |
| | | * @return |
| | | */ |
| | | public List<Quantity> getHeightList(String deptId) { |
| | | |
| | | if (StringUtils.isEmpty(deptId)) { |
| | | deptId = ContextUtil.subDeptId(null); |
| | | } |
| | | //获取所有筒仓及浅圆仓 |
| | | List<Depot> depotList = commonManager.listAllDepot(deptId, DepotType.TYPE_02.getCode() + "," + DepotType.TYPE_04.getCode()); |
| | | if (null == depotList || depotList.isEmpty()) { |
| | | return null; |
| | | } |
| | | |
| | | List<Quantity> list = new ArrayList<>(); |
| | | List<Quantity> quantityList; |
| | | Quantity quantity; |
| | | for (Depot depot : depotList) { |
| | | |
| | | quantityList = quantityService.getQuantityList(depot.getId(), 1); |
| | | if (null == quantityList || quantityList.isEmpty()) { |
| | | quantity = new Quantity(); |
| | | quantity.setDepotId(depot.getId()); |
| | | }else { |
| | | quantity = quantityList.get(0); |
| | | } |
| | | quantity.setDepotData(depot); |
| | | |
| | | list.add(quantity); |
| | | } |
| | | |
| | | return list; |
| | | } |
| | | } |