diff --git a/mod-audit-server/src/main/java/org/folio/rest/impl/AuditDataAcquisitionImpl.java b/mod-audit-server/src/main/java/org/folio/rest/impl/AuditDataAcquisitionImpl.java index d8f59ff..be70b07 100644 --- a/mod-audit-server/src/main/java/org/folio/rest/impl/AuditDataAcquisitionImpl.java +++ b/mod-audit-server/src/main/java/org/folio/rest/impl/AuditDataAcquisitionImpl.java @@ -10,7 +10,6 @@ import org.folio.rest.jaxrs.model.AuditDataAcquisitionOrderIdGetSortOrder; import org.folio.rest.jaxrs.model.AuditDataAcquisitionOrderLineIdGetSortOrder; import org.folio.rest.jaxrs.model.AuditDataAcquisitionPieceIdGetSortOrder; -import org.folio.rest.jaxrs.model.AuditDataAcquisitionPieceIdUniqueStatusGetSortOrder; import org.folio.rest.jaxrs.resource.AuditDataAcquisition; import org.folio.rest.tools.utils.TenantTool; import org.folio.services.acquisition.OrderAuditEventsService; @@ -29,17 +28,16 @@ public class AuditDataAcquisitionImpl implements AuditDataAcquisition { private static final Logger LOGGER = LogManager.getLogger(); - private final OrderAuditEventsService orderAuditEventsService; - private final OrderLineAuditEventsService orderLineAuditEventsService; - private final PieceAuditEventsService pieceAuditEventsService; + @Autowired + private OrderAuditEventsService orderAuditEventsService; + + @Autowired + private OrderLineAuditEventsService orderLineAuditEventsService; @Autowired - public AuditDataAcquisitionImpl(OrderAuditEventsService orderAuditEventsService, - OrderLineAuditEventsService orderLineAuditEventsService, - PieceAuditEventsService pieceAuditEventsService) { - this.orderAuditEventsService = orderAuditEventsService; - this.orderLineAuditEventsService = orderLineAuditEventsService; - this.pieceAuditEventsService = pieceAuditEventsService; + private PieceAuditEventsService pieceAuditEventsService; + + public AuditDataAcquisitionImpl() { SpringContextUtil.autowireDependencies(this, Vertx.currentContext()); } @@ -105,15 +103,10 @@ public void getAuditDataAcquisitionPieceById(String pieceId, String sortBy, Audi }); } - @Override - public void getAuditDataAcquisitionPieceUniqueStatusById(String id, String sortBy, AuditDataAcquisitionPieceIdUniqueStatusGetSortOrder sortOrder, int limit, int offset, Map okapiHeaders, Handler> asyncResultHandler, Context vertxContext) { - - } - private Response mapExceptionToResponse(Throwable throwable) { LOGGER.debug("mapExceptionToResponse:: Mapping Exception :{} to Response", throwable.getMessage(), throwable); return GetAuditDataAcquisitionOrderByIdResponse - .respond500WithApplicationJson(ErrorUtils.buildErrors(GENERIC_ERROR_CODE.getCode(), throwable)); + .respond500WithApplicationJson(ErrorUtils.buildErrors(GENERIC_ERROR_CODE.getCode(), throwable)); } } diff --git a/ramls/acquisition-events.raml b/ramls/acquisition-events.raml index 7d057c3..19b1ec4 100644 --- a/ramls/acquisition-events.raml +++ b/ramls/acquisition-events.raml @@ -125,38 +125,3 @@ traits: example: strict: false value: !include raml-util/examples/errors.sample - - /piece/{id}/unique-status: - get: - description: Get list of piece events by piece_id - is: [ - pageable, - validate - ] - queryParameters: - sortBy: - description: "sorting by field: actionDate" - type: string - default: action_date - sortOrder: - description: "sort order: asc or desc" - enum: [asc, desc] - type: string - default: desc - limit: - default: 2147483647 - offset: - default: 0 - responses: - 200: - body: - application/json: - type: piece-audit-event-collection - 500: - description: "Internal server error" - body: - application/json: - type: errors - example: - strict: false - value: !include raml-util/examples/errors.sample