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

[LAHI] Add "Other" location values for all locations #34

Closed
2 tasks done
Tracked by #24
utkarshavni opened this issue Sep 21, 2022 · 1 comment
Closed
2 tasks done
Tracked by #24

[LAHI] Add "Other" location values for all locations #34

utkarshavni opened this issue Sep 21, 2022 · 1 comment
Assignees
Labels

Comments

@utkarshavni
Copy link
Collaborator

utkarshavni commented Sep 21, 2022

Use case:
Students do not necessarily share all address level details like District, block and other lower level locations through Whatsapp (Glific chatbot). This means that once the integration is done and data from Glific is pulled into Avni for Registration, it will not have all location details. In order to complete the Registration for these students, we should have the option "Other" for all the location fields.

Goal:
State, District, Block, School name, UDISE code to have Other option.

Acceptance criteria:

  • Have locations with complete hierarchy with title "Other" - From State to UDISE
  • Have "Other" District, block, School and UDISE locations created under existing States.

When Student registrations are done by pulling data from Gliffic. The location values should be selected as "Other".

@utkarshavni utkarshavni changed the title [LAHI] Add "Unknown" location values for lower level location types. [LAHI] Add "Other" location values for lower level location types. Apr 13, 2023
@utkarshavni utkarshavni changed the title [LAHI] Add "Other" location values for lower level location types. [LAHI] Add "Other" location values for all locations Apr 17, 2023
@vedfordev vedfordev self-assigned this Jun 22, 2023
@vedfordev
Copy link
Contributor

vedfordev commented Jun 29, 2023

steps for dev

  1. create one "State" as "Other" via web-app.

  2. create one csv file with title with order as following: "State" , "District", "Block", "School", "UDISE"

  3. Note down count from the following query :

select count(distinct title)
from address_level where type_id = (select id
                                    from address_level_type
                                    where name = 'State' and
                                            is_voided = false);
  1. Copy State from query and paste into csv sheet :
select distinct title
from address_level where type_id = (select id
                                    from address_level_type
                                    where name = 'State' and
                                            is_voided = false);
  1. Fill csv sheet "District", "Block", "School", "UDISE" as other for all "State" and upload:
  2. verification query and it should match with count of step 3 :
select count(*)
--       state.title,district.title,block.title,school.title,udise.title
from address_level state
join address_level district on state.id = district.parent_id
join address_level block on district.id = block.parent_id
join address_level school on block.id = school.parent_id
join address_level udise on school.id = udise.parent_id
where state.type_id = (select id
                    from address_level_type
                    where name = 'State' and
                            is_voided = false)
and district.title = 'Other'
and block.title = 'Other'
and school.title = 'Other'
and udise.title = 'Other';

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

No branches or pull requests

4 participants