Skip to content

Commit

Permalink
remove sth i don't need
Browse files Browse the repository at this point in the history
HU-Trace: show all connected records metasfresh/metasfresh-webui-api-legacy#632
  • Loading branch information
metas-ts committed Oct 14, 2017
1 parent 48f0d8e commit 5d76e68
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 44 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -78,12 +78,6 @@ public enum EventTimeOperator

Instant eventTimeTo;

/**
* If {@code true}, then also query for all records with that have the same VHU_ID as the "primary" matches.
*/
@Default
boolean expandOnVhuId = false;

@NonNull
@Default
OptionalInt huTraceEventId = OptionalInt.empty();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -231,11 +231,6 @@ private Result queryDbRecord(
.create();
noRecursiveResult.executeQueryAndAddAll(query);

if (huTraceEventQuery.isExpandOnVhuId())
{

}

// no matter which recursion mode, we can always add the records we already have
resultOut.addAll(noRecursiveResult);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,37 +93,4 @@ public void queryToSelection()

assertThat(result).hasSize(1);
}

@Test
public void test()

{
final Instant eventTime = Instant.now();
final HUTraceEvent event1 = HUTraceRepositoryTests.commonEventBuilder
.eventTime(eventTime)
.topLevelHuId(2)
.vhuId(12)
.inOutId(30)
.build();

final HUTraceEvent event2 = HUTraceRepositoryTests.commonEventBuilder
.eventTime(eventTime)
.topLevelHuId(2)
.vhuId(12)
.shipmentScheduleId(40)
.build();

final HUTraceEvent event3 = event2.withVhuId(13);

huTraceRepository.addEvent(event1);
huTraceRepository.addEvent(event2);
huTraceRepository.addEvent(event3);

assertThat(RetrieveDbRecordsUtil.queryAll()).hasSize(3);

final HUTraceEventQuery query = event1.asQueryBuilder().expandOnVhuId(true).build();
final List<HUTraceEvent> result = RetrieveDbRecordsUtil.query(query);
assertThat(result).hasSize(2);
}

}

0 comments on commit 5d76e68

Please sign in to comment.