Spike: CIRC-441 - Delivery requests: support tokens for delivery slip
CIRC-441: [Spike] Delivery requests: support tokens for delivery slipClosed
The goal of the spike is to investigate the process of adding new tokens to delivery slips
1. How existing tokens are added to delivery slip:
"POST circulation/check-in-by-barcode" endpoint returns "staffSlipContext" attributes in response:
UI uses this object to replace delivery slip tokens with data when printing delivery slip.
mod-circulation constructs staffSlipContext in method TemplateContextUtil#createCheckInContext by using available data (data is stored in object CheckInProcessRecords).
Before constructing staffSlipContext mod-circulation retrieves all necessary data by making calls to other services in CheckInByBarcodeResource#checkin.
2. How to add new slip tokens
If data for new token is already available in CheckInProcessRecords then we just need to transfer it to staffSlipContext in TemplateContextUtil#createCheckInContext.
If data is not available then we need to retrieve it from corresponding service, store it in CheckInProcessRecords, and then add it to staffSlipContext in TemplateContextUtil#createCheckInContext