Open steele-lm opened 5 months ago
For forms with a logged in user, grabbing their Service History via the Lighthouse API would require
The 'endpoint' variable would be set to 'service_history' instead of 'disability_rating'
The frontend will be querying the service history. Functions will need to be added to receive the data and prefill the form. There are examples in the vets-website codebase where form inputs are being prefilled so this may need a little bit of customization
Need to update swagger docs as central mail no longer applies and service_history needs adding
We should talk about putting this endpoint and the Veteran Service History and Eligibility API as a whole under v0/profile. Currently, there is a service_history endpoint under v0/profile, but it does not user the Lighthouse VSH&E API. Perhaps we can have a v0/profile/lighthouse/* path for the endpoints laid out in the documentation here. Right now the 526 team just plugs in the rated_disabilities endpoint to their routing pattern. I have it plugged into our claims_base_controller.rb base class for the claims controllers to inherent from, thus giving all of the inheriting classes the service_history across the endpoints.
Issue Description
To prepare to autofill a Veteran's Service History in the
Burial, COE, and Chapter 36 forms, we need to integrate with the existing Service History API.Chapter 36/PCPG: Prefill only if Veteran is logged in and filling out the form
Tasks
Acceptance Criteria
[ ] What will be created or happen as a result of this story?