Browse Source

Methods findInfoByTo() and findInfoByQuery() should return EntityRelationInfo but no EntityRelation

pull/3888/head
Viacheslav Kukhtyn 6 years ago
committed by Andrew Shvayka
parent
commit
8e279bbbd7
  1. 4
      rest-client/src/main/java/org/thingsboard/rest/client/RestClient.java

4
rest-client/src/main/java/org/thingsboard/rest/client/RestClient.java

@ -1456,7 +1456,7 @@ public class RestClient implements ClientHttpRequestInterceptor, Closeable {
params.put("relationTypeGroup", relationTypeGroup.name());
return restTemplate.exchange(
baseURL + "/api/relations?toId={toId}&toType={toType}&relationTypeGroup={relationTypeGroup}",
baseURL + "/api/relations/info?toId={toId}&toType={toType}&relationTypeGroup={relationTypeGroup}",
HttpMethod.GET,
HttpEntity.EMPTY,
new ParameterizedTypeReference<List<EntityRelationInfo>>() {
@ -1491,7 +1491,7 @@ public class RestClient implements ClientHttpRequestInterceptor, Closeable {
public List<EntityRelationInfo> findInfoByQuery(EntityRelationsQuery query) {
return restTemplate.exchange(
baseURL + "/api/relations",
baseURL + "/api/relations/info",
HttpMethod.POST,
new HttpEntity<>(query),
new ParameterizedTypeReference<List<EntityRelationInfo>>() {

Loading…
Cancel
Save