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

Fix:E-claim toggle list button #507 #528

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

iEdmar
Copy link

@iEdmar iEdmar commented Jan 17, 2025

Console Logs for Debugging
Added console.log statements to test the behavior of the tabular view under specific conditions. These logs were used to validate functionality and identify any issues during development.

Screenshot from 2025-01-17 10-20-25

Group 17: Members participated
01: Muddy Ramadhan Fakih(2022-04-01851)
02: Rafia Ramadhan Maganga(2022-04-05593)
03: Edmar Isdor Ngimba(2022-04-10262 )
04: Aisha Mussa Mzava(2022-04-09813)
05: ABDILLAH AHMED ISSA(2022-04-02740)

@iEdmar iEdmar closed this Jan 17, 2025
@iEdmar iEdmar reopened this Jan 17, 2025
@iEdmar iEdmar marked this pull request as draft January 17, 2025 07:31
@iEdmar iEdmar marked this pull request as ready for review January 17, 2025 07:31
@@ -70,13 +70,15 @@ export class EClaimHomeComponent implements OnInit {
this.loadedData = false;
this.visitService.getAllVisits(null, null, true).subscribe(
(visits) => {
console.log('Fetched Active Visits:', visits);
Copy link
Author

Choose a reason for hiding this comment

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

Added a line for console.log to check for fetched active visits status

@iEdmar iEdmar requested a review from Maganga-Rafia January 17, 2025 09:29
@iEdmar iEdmar marked this pull request as draft January 17, 2025 09:29
@iEdmar iEdmar marked this pull request as ready for review January 17, 2025 09:29
Mdsoln and others added 4 commits January 17, 2025 12:39
**_Reason for the bug_**
File: /patient-list.component.html
The condition for rendering the tabular list includes an additional filter for paymentTypeSelected: `*ngIf="
  isTabularList &&
  params?.visits &&
  params?.visits.length > 0 &&
  ((paymentTypeSelected && visit?.visit?.paymentType === paymentTypeSelected) ||
    !paymentTypeSelected)
"`
Compare this with the condition for rendering the account_box view: `***ngIf="params?.visits && params?.visits.length > 0"**` Because of the added filter complexity result in the tabular list not being displayed due to mismatches in data or payme ntTypeSelected.

**_So, by removing the additional complexity the toggle list works as expected._**
500 Internal Server Error: The API endpoint http://localhost:4200/openmrs/ws/rest/v1/icare/visit?&startIndex=undefined&limit=undefined is returning a 500 error. The error likely stems from the startIndex and limit query parameters being undefined. I resolve by adding predefined values for startIndex and limit to the getAllVisit function as initialization and error resolved.
@Moricembiaji
Copy link
Collaborator

Moricembiaji commented Jan 17, 2025 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants