Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implemented Insurance Details Page #6595

Merged
merged 7 commits into from
Nov 22, 2023

Conversation

konavivekramakrishna
Copy link
Contributor

@konavivekramakrishna konavivekramakrishna commented Nov 13, 2023

WHAT

🤖 Generated by Copilot at a288d64

Added a feature to show insurance details for patients in the frontend. Created a new InsuranceDetails component and a route to display the data in a separate page. Modified the PatientHome component to include a card with the insurance information. Added API support and updated the HCXPolicyModel interface to handle the data from the backend.

Proposed Changes

image
image
image

@coronasafe/care-fe-code-reviewers @coronasafe/code-reviewers

Merge Checklist

  • Add specs that demonstrate bug / test a new feature.
  • Update product documentation.
  • Ensure that UI text is kept in I18n files.
  • Prep screenshot or demo video for changelog entry, and attach it to issue.
  • Request for Peer Reviews
  • Completion of QA

HOW

🤖 Generated by Copilot at a288d64

  • Create a new component InsuranceDetails to display the insurance details of a patient in a separate page (link)
  • Import the useQuery hook and the routes object in the PatientHome component to fetch the insurance details of the patient from the listHCXPolicies route (link)
  • Change the grid layout of the patient details section from two columns to three columns, and add a card to show the first policy of the patient or a message indicating no insurance data (link, link, link)
  • Add a button to the card that navigates to the insurance details page if the patient has more than one policy (link)
  • Import the HCXPolicyModel interface in the api.tsx file and set the response type of the listHCXPolicies route to a paginated response of HCXPolicyModel objects (link, link)
  • Make the insurer_id and insurer_name fields optional in the HCXPolicyModel interface, as they may not be available for some policies (link)
  • Add the insurance details page route to the PatientRoutes.tsx file, using the facilityId and id parameters to pass them as props to the InsuranceDetails component (link, link)

@konavivekramakrishna konavivekramakrishna requested a review from a team November 13, 2023 17:24
@konavivekramakrishna konavivekramakrishna requested a review from a team as a code owner November 13, 2023 17:24
Copy link

vercel bot commented Nov 13, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
care-storybook ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 21, 2023 1:50pm

Copy link

netlify bot commented Nov 13, 2023

Deploy Preview for care-egov-staging ready!

Name Link
🔨 Latest commit 585494d
🔍 Latest deploy log https://app.netlify.com/sites/care-egov-staging/deploys/655cb5893d697c000809da34
😎 Deploy Preview https://deploy-preview-6595--care-egov-staging.netlify.app/
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link
Member

@rithviknishad rithviknishad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, just some minor changes. Also see reviews from here (not necessary, but good to have): https://codeclimate.com/github/coronasafe/care_fe/pull/6595

src/Components/Patient/InsuranceDetails.tsx Show resolved Hide resolved
src/Components/Patient/PatientHome.tsx Outdated Show resolved Hide resolved
src/Components/Patient/PatientHome.tsx Outdated Show resolved Hide resolved
Copy link
Member

@rithviknishad rithviknishad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

@nihal467
Copy link
Member

LGTM

@khavinshankar khavinshankar merged commit db03a61 into ohcnetwork:develop Nov 22, 2023
31 of 36 checks passed
@konavivekramakrishna konavivekramakrishna deleted the fix#6517 branch November 22, 2023 04:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Insurance details: make visible
4 participants