@Service("estatusServicesImpl")
public class EstatusServicesImpl implements IEstatusServices {
@Autowired
private IActivoDao activoDaoImpl;
@Autowired
private Mapper dozerMapper;
@Override
public List<EstatusDto> findAll() {
List<EstatusDto> list = null;
try {
System.out.println("ingres a sevicicio estatus");
List<ActivoModel> list2 = (List<ActivoModel>) activoDaoImpl.findAll();
System.out.println("dro" + dozerMapper);
if (list2 != null && list2.size() > 0) {
System.out.println("ingreso if");
list = list2.stream().map((catalogo) -> {
return dozerMapper.map(catalogo, EstatusDto.class);
}).collect(Collectors.toList());
}
} catch (Exception e) {
e.printStackTrace();
}
return list;
}
@Override
public List<EstatusDto> findbyidActivo(int idActivo) {
List<EstatusDto> listDto = null;
List<EstatusDto> listModel = activoDaoImpl.findByidActivo( idActivo);
if (listModel != null) {
listDto = listModel.stream().map((catalogo) -> {
return dozerMapper.map(catalogo, EstatusDto.class);
}).collect(Collectors.toList());
}
return listDto;
}
}
Este el error me manda cuando lo ejecuto con potsman en la consola de eclipse
Caused by: com.fasterxml.jackson.databind.exc.InvalidDefinitionException: No serializer found for class mx.gob.issfam.dti.api.dto.EstatusDto and no properties discovered to create BeanSerializer (to avoid exception, disable SerializationFeature.FAIL_ON_EMPTY_BEANS) (through reference chain: java.util.ArrayList[0]) at com.fasterxml.jackson.databind.exc.InvalidDefinitionException.from(InvalidDefinitionException.java:77) ~[jackson-databind-2.12.3.jar:2.12.3]
Este el error me manda cuando lo ejecuto con potsman en la consola de eclipse
> Caused by: com.fasterxml.jackson.databind.exc.InvalidDefinitionException: No serializer found for class mx.gob.issfam.dti.api.dto.EstatusDto and no properties discovered to create BeanSerializer (to avoid exception, disable SerializationFeature.FAIL_ON_EMPTY_BEANS) (through reference chain: java.util.ArrayList[0])
at com.fasterxml.jackson.databind.exc.InvalidDefinitionException.from(InvalidDefinitionException.java:77) ~[jackson-databind-2.12.3.jar:2.12.3]