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

Not all lower address levels passed in params to custom report card #1393

Closed
Tracked by #1607
vedfordev opened this issue May 9, 2024 · 3 comments
Closed
Tracked by #1607
Assignees

Comments

@vedfordev
Copy link
Contributor

vedfordev commented May 9, 2024

Describe the bug
When we are applying state filter then we get only state and village in address filter not giving block and district.

logs:

05-09 09:47:02.639  3798  4374 I ReactNativeJS: 'addressFilter=====', [ { type: 'Address',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:     dataType: null,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:     filterValue:
05-09 09:47:02.639  3798  4374 I ReactNativeJS:      [ { uuid: '924674dc-d32b-4276-b7b5-fb782f5511f2',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Kerala',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 4,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'State',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: null,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          typeUuid: 'fda77dde-6346-47b9-84e0-25e7f171f55a',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          isSelected: true },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: 'c17638eb-241a-4560-a0d2-773e743d8652',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Ambalappuzha',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '5b26df29-e1b7-4782-a29c-edeaee770d37' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: '324aa6ed-e88d-414a-b84f-d197bdfd484d',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Ambalappuzha North',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '5b26df29-e1b7-4782-a29c-edeaee770d37' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: 'b4aae6f6-0217-4c7b-85c1-45eae036092f',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Karumady',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '5b26df29-e1b7-4782-a29c-edeaee770d37' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: '9e4bb74b-b0b4-4b2d-85d0-781a3cc08848',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Paravoor',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '5b26df29-e1b7-4782-a29c-edeaee770d37' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: 'd1b869d8-99c9-409d-930c-ec03e6f7cc37',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Punnapra (Og)',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '5b26df29-e1b7-4782-a29c-edeaee770d37' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: 'd949df36-2fc7-442d-9550-364f48c919ea',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Purakkad',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '5b26df29-e1b7-4782-a29c-edeaee770d37' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: '28b6dc97-7d29-4875-bc29-b8079e0403ea',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Other',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '5b26df29-e1b7-4782-a29c-edeaee770d37' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: '9b4c4494-361a-41f2-9c00-ef47a22fc497',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Other',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '18038ff2-6174-4d07-8811-140cc8ef73a7' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: '06f5fdd5-5951-4bb5-a519-5bd3683a4c46',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Aryad South (Part)',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '6d115de4-a387-45a4-ac76-15e8134eae9e' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: 'fd3126a0-3b5f-456c-a0ae-627fc235ebc8',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Kalavoor',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '6d115de4-a387-45a4-ac76-15e8134eae9e' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: '5b97b91d-9033-474c-b47a-5c2e752cc32c',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Komalapuram (Ct)',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '6d115de4-a387-45a4-ac76-15e8134eae9e' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: '934717fe-03ac-4fbd-80ed-e6cbe63f7c9a',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Mannanchery (Ct)',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '6d115de4-a387-45a4-ac76-15e8134eae9e' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: 'b56607d7-5720-4489-a848-93d9b8a4e101',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Mullakkal (Part)',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '6d115de4-a387-45a4-ac76-15e8134eae9e' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: '731f3c44-1fb1-4918-9784-4240e900371d',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Pathirappally (Ct)',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '6d115de4-a387-45a4-ac76-15e8134eae9e' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: 'c8148663-bc47-4e87-b21e-8f6674f65257',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Thanneermukkam South',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '6d115de4-a387-45a4-ac76-15e8134eae9e' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: 'da9b7a21-47cd-470d-9b5a-8294eecd27cb',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Other',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '6d115de4-a387-45a4-ac76-15e8134eae9e' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: '74d7df78-c2c0-4968-95c3-4d271614015d',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Bharanikkavu (Ct)',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '0fbdf905-5f58-400d-b4f6-ef16d2d79e4b' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: 'eb57f070-a32b-4fc2-940b-deb014f6a6a4',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Chunakkara',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '0fbdf905-5f58-400d-b4f6-ef16d2d79e4b' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: '207f3564-1292-47e9-a171-bfe7967b9645',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Kattanam (Ct)',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          level: 1,
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          type: 'Village',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          parentUuid: '0fbdf905-5f58-400d-b4f6-ef16d2d79e4b' },
05-09 09:47:02.639  3798  4374 I ReactNativeJS:        { uuid: 'e49b9f64-f016-4a83-9005-2a8e8b697029',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:          name: 'Noornad',
05-09 09:47:02.639  3798  4374 I ReactNativeJS:

Release
8.0
org : gvamp_uat
user: beulah@gvamp_uat

To Reproduce
Steps to reproduce the behaviour:

  1. login with user (beulah@gvamp_uat)
  2. apply any state filter
  3. check card which are register at district level (Demand to be dispatch)
Screen.Recording.2024-05-09.at.3.16.53.PM.mov

Test cases:

Make sure the below cards doesn't break when fixing this card

@github-project-automation github-project-automation bot moved this to New Issues in Avni Product May 9, 2024
@mahalakshme mahalakshme moved this from New Issues to In Analysis in Avni Product May 9, 2024
@mahalakshme mahalakshme changed the title Address Filter is not working Not all lower address levels passed in params to custom report card May 9, 2024
@mahalakshme mahalakshme moved this from In Analysis to Ready in Avni Product May 9, 2024
@petmongrels petmongrels moved this from Ready to In Progress in Avni Product May 13, 2024
@petmongrels petmongrels self-assigned this May 13, 2024
@petmongrels
Copy link
Contributor

Affected areas to test

  • address filter display on selection of items in dashboard and search
  • search filter results

@petmongrels petmongrels moved this from In Progress to Code Review Ready in Avni Product May 13, 2024
@himeshr himeshr moved this from Code Review Ready to In Code Review in Avni Product May 13, 2024
@himeshr
Copy link
Contributor

himeshr commented May 13, 2024

Code review comments:

9ff9efe#r141950426 (Functional issue)
9ff9efe#r141950659 (Performance concern)

@himeshr himeshr moved this from In Code Review to Code Review with Comments in Avni Product May 13, 2024
@petmongrels petmongrels moved this from Code Review with Comments to In Progress in Avni Product May 14, 2024
petmongrels added a commit that referenced this issue May 14, 2024
…ad of looking for children to avoid db queries.
@petmongrels petmongrels moved this from In Progress to QA Ready in Avni Product May 14, 2024
@himeshr
Copy link
Contributor

himeshr commented May 14, 2024

@AchalaBelokar, additionally evaluate following this as part of this card:

  • MyDashboard, Address Filter Select, Display and clear are working as expected and include all expected values
  • Performance varioation between this and older version of APKs on select high level address in organisations which have large number of locations under them

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

No branches or pull requests

4 participants