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

Being able to configure subject type filter on 'Last 24 type' cards #1263

Closed
Tracked by #912 ...
mahalakshme opened this issue Jun 21, 2024 · 5 comments
Closed
Tracked by #912 ...
Assignees

Comments

@mahalakshme
Copy link
Contributor

mahalakshme commented Jun 21, 2024

AC:

  • Similar to Being able to configure subject type filter for Due and overdue visits cards when part of custom dashboard #1203
  • Should work for standard report cards 'Last 24 hour registrations', 'Last 24 hour enrolments', 'Last 24 hour visits'
  • Rename the standard report card types in the dropdown to 'Recent registrations', 'Recent enrolments', 'Recent visits'
  • For 'Configuration 1', consider the below points:
    1. When any of the 3 recent card types selected, subject type, program and encounter type filters need to display based on what is applicable for the selected subject type
    - Initially when the above standard report card types are selected, show 'Subject type' filter alone.
    - Based on the subject type selected, show any programs if applicable, in the programs filter, and general encounter types in the 'Encounter type' filter.
    - Based on the program selected, show program encounter types as well, in the 'Encounter type' filter.
    - Should be able to save without anything selected in 'Subject Type' filter as well.
    2. When recent visits selected, provide a 'relative date' range filter(like in the image below)
    - Similarly, When recent registrations selected, instead of 'Encounters in last', it needs to be 'Registrations in last'
    - When recent enrolments selected, instead of 'Encounters in last', it needs to be 'Enrolments in last'
    - Options are months, weeks and days - not years
    - Should not be able to save without anything selected in the date range filter
    - By default show '24 hours'
    - Similar UI element used in setting numeric abnormal values.
    - Should be able to set only positive integers, 0 or negative nos should not be allowed
    3. Should be able to select any colour from the colour picker.
  • For Configuration 2, nothing needs to be done here since already done.

Image

@1t5j0y
Copy link
Contributor

1t5j0y commented Jun 28, 2024

pending: dev testing on bundle

1t5j0y added a commit to avniproject/avni-server that referenced this issue Jul 1, 2024
@petmongrels
Copy link
Contributor

  1. org.avni.server.web.contract.ValueUnit#toJSONString can use ObjectMapper json serialisation method
  2. org.avni.server.service.CardService#buildDurationForRecentTypeCards - since the input is internal to the system it is expected always that the string will not throw exception. If it will throw exception then it should be handled explicitly. If it will not throw exception unless there is a bug, we should let the exception break the system.

1t5j0y added a commit to avniproject/avni-server that referenced this issue Jul 2, 2024
…it to JSON

Propagate error if occurs while (de)serializing ValueUnit
@1t5j0y
Copy link
Contributor

1t5j0y commented Jul 2, 2024

Addressed code review comments.

@AchalaBelokar
Copy link

  • Login with Maha@APF
  1. click on offline report card
  2. toggle the button stander report card
  3. Encounter in last is not showing in the report card

Image

@1t5j0y
Copy link
Contributor

1t5j0y commented Jul 16, 2024

@AchalaBelokar please go through AC on this card. Encounter in last is only shown for 'Last 24' type cards. These card types have been renamed as part of this story to 'Recent..'.

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

5 participants