Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Connects the backend and frontend for the schedule veteran directly w…
…orkflow (#15212) Resolves #14895 Stack - [Part 2](#15214) - [Part 3](#15215) ### Description Updates frontend and backend code to connect the functionality and complete the workflow for scheduling veterans directly to either Central Office, Video, or Virtual hearings. ### Acceptance Criteria - [ ] Code compiles correctly - [ ] Behavior is unchanged when the feature flag is disabled ### Testing Plan **With Feature Flag** *Central Hearing* NOTE: You need to do some setup work for the Central flow, first get the `uuid` of an Appeal without a hearing scheduled and open a rails console. Run the following commands to make the central office hearing available to schedule: ``` appeal = Appeal.find_by(uuid: "") appeal.update!(closest_regional_office: "C") CachedAppeal.create!(appeal_id: appeal.id, appeal_type: appeal.class.name, closest_regional_office_key: "C") ``` 1. Shadow user `BVASYELLOW` and navigate to the hearings schedule 1. Click the `Schedule Veterans` button change the dropdown to `Central` 1. Change to the `AMA Veterans Waiting` tab and choose the appeal you just updated 1. Select the Schedule Veteran option from the Actions dropdown 1. Ensure the full page schedule veteran component is loaded 1. Fill in the hearing details and click `Schedule` 1. Ensure you receive a success message with a link back to schedule veterans *Video Hearing* 1. Shadow user `BVASYELLOW` and navigate to the hearings schedule 1. Click the `Schedule Veterans` button change the dropdown to `St. Petersburg, FL` 1. Change to the `AMA Veterans Waiting` tab and choose the appeal you just updated 1. Select the Schedule Veteran option from the Actions dropdown 1. Ensure the full page schedule veteran component is loaded 1. Fill in the hearing details and click `Schedule` 1. Ensure you receive a success message with a link back to schedule veterans *Virtual Hearing* 1. Shadow user `BVASYELLOW` and navigate to the hearings schedule 1. Click the `Schedule Veterans` button change the dropdown to `St. Petersburg, FL` 1. Change to the `AMA Veterans Waiting` tab and choose the appeal you just updated 1. Select the Schedule Veteran option from the Actions dropdown 1. Ensure the full page schedule veteran component is loaded 1. Change the hearing type to `Virtual` 1. Fill in the hearing details and click `Schedule` 1. Ensure you receive a success message with a link back to schedule veterans **Without Feature Flag** *Central Hearing* NOTE: You need to do some setup work for the Central flow, first get the `uuid` of an Appeal without a hearing scheduled and open a rails console. Run the following commands to make the central office hearing available to schedule: ``` appeal = Appeal.find_by(uuid: "") appeal.update!(closest_regional_office: "C") CachedAppeal.create!(appeal_id: appeal.id, appeal_type: appeal.class.name, closest_regional_office_key: "C") ``` 1. Shadow user `BVASYELLOW` and navigate to the hearings schedule 1. Click the `Schedule Veterans` button change the dropdown to `Central` 1. Change to the `AMA Veterans Waiting` tab and choose the appeal you just updated 1. Select the Schedule Veteran option from the Actions dropdown 1. Ensure the full page schedule veteran component is loaded 1. Fill in the hearing details and click `Schedule` 1. Ensure you receive a success message with a link back to schedule veterans *Video Hearing* 1. Shadow user `BVASYELLOW` and navigate to the hearings schedule 1. Click the `Schedule Veterans` button change the dropdown to `St. Petersburg, FL` 1. Change to the `AMA Veterans Waiting` tab and choose the appeal you just updated 1. Select the Schedule Veteran option from the Actions dropdown 1. Ensure the full page schedule veteran component is loaded 1. Fill in the hearing details and click `Schedule` 1. Ensure you receive a success message with a link back to schedule veterans ### User Facing Changes - [ ] Screenshots of UI changes added to PR & Original Issue BEFORE|AFTER ---|--- ![Before-ConvertToCentral](https://user-images.githubusercontent.com/61989526/92796584-2c14dd00-f366-11ea-967c-f7f404c3e443.png)|![After-ConvertToCentral](https://user-images.githubusercontent.com/61989526/92796567-27e8bf80-f366-11ea-821c-feb075d024f0.png) ![Before-PostponeRescheduleImmediately](https://user-images.githubusercontent.com/61989526/92796576-2a4b1980-f366-11ea-8b05-4a3ffc2e0d52.png)|![After-PostponeRescheduleImmediately](https://user-images.githubusercontent.com/61989526/92796597-2cad7380-f366-11ea-8853-02983d1bdfe9.png) ![Before-ConvertToVideo](https://user-images.githubusercontent.com/61989526/92796583-2b7c4680-f366-11ea-9813-bf75c698199c.png)|![After-ConvertToVideo](https://user-images.githubusercontent.com/61989526/92796601-2d460a00-f366-11ea-99eb-3a72fc7b790b.png) | |![After-ConvertToVirtual](https://user-images.githubusercontent.com/61989526/92796599-2d460a00-f366-11ea-960b-ca46f85f6db8.png) | |![After-SchedulingInProgress](https://user-images.githubusercontent.com/61989526/92796590-2c14dd00-f366-11ea-978d-cb105c2c3bb0.png) | |![After-SchedulingComplete](https://user-images.githubusercontent.com/61989526/92796594-2cad7380-f366-11ea-839b-030b5e9f94ff.png) ### Storybook Story *For Frontend (Presentationa) Components* * [x] Add a [Storybook](https://github.com/department-of-veterans-affairs/caseflow/wiki/Documenting-React-Components-with-Storybook) file alongside the component file (e.g. create `MyComponent.stories.js` alongside `MyComponent.jsx`) * [x] Give it a title that reflects the component's location within the overall Caseflow hierarchy * [x] Write a separate story (within the same file) for each discrete variation of the component
- Loading branch information