| | |
| | | package com.vci.web.service.impl; |
| | | |
| | | import com.vci.client.common.providers.ServiceProvider; |
| | | import com.vci.corba.common.VCIError; |
| | | import com.vci.corba.query.data.KV; |
| | | import com.vci.starter.web.annotation.log.VciUnLog; |
| | | import com.vci.starter.web.exception.VciBaseException; |
| | | import com.vci.starter.web.pagemodel.BaseQueryObject; |
| | |
| | | * @return 显示对象 |
| | | */ |
| | | @Override |
| | | public OsStatusVO statusDO2VO(StatePool statePool) { |
| | | public OsStatusVO statusDO2VO(com.vci.corba.omd.stm.StatePool statePool) { |
| | | OsStatusVO statusVO = new OsStatusVO(); |
| | | if(statePool!=null){ |
| | | statusVO.setOid(statePool.oid); |
| | | statusVO.setCreator(statePool.creator); |
| | | statusVO.setLastModifier(statePool.modifier); |
| | | try { |
| | | statusVO.setCreateTime(VciDateUtil.str2Date(statePool.createTime,VciDateUtil.DateTimeFormat)); |
| | | statusVO.setLastModifyTime(VciDateUtil.str2Date(statePool.modifyTime,VciDateUtil.DateTimeFormat)); |
| | | statusVO.setCreateTime(new Date(statePool.createTime)); |
| | | statusVO.setLastModifyTime(new Date(statePool.modifyTime)); |
| | | statusVO.setTs(VciDateUtil.str2Date(statePool.ts,VciDateUtil.DateTimeMillFormat)); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | |
| | | * @return 显示对象 |
| | | */ |
| | | @Override |
| | | public List<OsStatusVO> statusDO2VOs(Collection<StatePool> statePools) { |
| | | public List<OsStatusVO> statusDO2VOs(Collection<com.vci.corba.omd.stm.StatePool> statePools) { |
| | | List<OsStatusVO> statusVOS = new ArrayList<>(); |
| | | if(!CollectionUtils.isEmpty(statePools)){ |
| | | statePools.stream().forEach(statePool -> { |
| | |
| | | @VciUnLog |
| | | public List<OsStatusVO> selectAllStatus() { |
| | | try { |
| | | return statusDO2VOs(Arrays.stream(platformClientUtil.getStatePoolService().getStatePools()).collect(Collectors.toList())); |
| | | // return statusDO2VOs(Arrays.stream(platformClientUtil.getStatePoolService().getStatePools()).collect(Collectors.toList())); |
| | | return statusDO2VOs(Arrays.stream(ServiceProvider.getOMDService().getStateService().getStatePools()).collect(Collectors.toList())); |
| | | } catch (VCIError vciError) { |
| | | throw WebUtil.getVciBaseException(vciError); |
| | | } |