Код: Выделить всё
@JsonInclude(JsonInclude.Include.NON_EMPTY)
private List filterItems;
Код: Выделить всё
public TabInfoFilter getFilter {
final List results = query.getResultList();
if (CollectionUtils.isEmpty(results))
{
return Collections.EMPTY_LIST;
}
return results;
}
Код: Выделить всё
@GET
@Path("/formular/{formularId}")
@Produces(MediaType.APPLICATION_JSON)
public Collection getFilters(@PathParam("formularId") final int formularId)
{
return getTabInfoFilterDAO().getFilters(mandant, userId, userId, formularId);
}
Код: Выделить всё
org.glassfish.jersey.message.internal.WriterInterceptorExecutor MessageBodyWriter not found for media type=application/json, type=class java.util.Collections$EmptyList, genericType=java.util.Collection
Код хорошо работает с javax. Результат должен вернуть []
Подробнее здесь: https://stackoverflow.com/questions/790 ... on-jakarta