fix(stoptb): resolve district/block/village against Nikshay masters, … - #444
fix(stoptb): resolve district/block/village against Nikshay masters, …#444vishwab1 wants to merge 1 commit into
Conversation
…not standard AMRIT masters Stop TB workers are mapped to Nikshay's own isolated location hierarchy (m_nikshay_district/tu/village), a separate ID space from AMRIT's standard masters (m_district/m_districtblock/m_DistrictBranchMapping). The beneficiary address mapper ignored the districtName/districtBranchName strings sent by mobile and re-derived them by looking the numeric ID up in the standard masters instead, so every Stop TB registration got stamped with whatever unrelated place happened to share that ID (e.g. district 1 -> "Nicobars" instead of "Alluri Sitharama Raju"). Add Nikshay-specific lookup entities/repos and a NikshayAddressResolver that gates on providerServiceMapID -> ServiceName == "Stop TB". Only Stop TB beneficiaries take the Nikshay resolution path; every other service line's address mapping is untouched. Hibernate ddl-auto=none means tenants without the Nikshay tables are unaffected at both startup and runtime, since the new repositories are never queried unless isStopTB is true. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|


…not standard AMRIT masters
Stop TB workers are mapped to Nikshay's own isolated location hierarchy (m_nikshay_district/tu/village), a separate ID space from AMRIT's standard masters (m_district/m_districtblock/m_DistrictBranchMapping). The beneficiary address mapper ignored the districtName/districtBranchName strings sent by mobile and re-derived them by looking the numeric ID up in the standard masters instead, so every Stop TB registration got stamped with whatever unrelated place happened to share that ID (e.g. district 1 -> "Nicobars" instead of "Alluri Sitharama Raju").
Add Nikshay-specific lookup entities/repos and a NikshayAddressResolver that gates on providerServiceMapID -> ServiceName == "Stop TB". Only Stop TB beneficiaries take the Nikshay resolution path; every other service line's address mapping is untouched. Hibernate ddl-auto=none means tenants without the Nikshay tables are unaffected at both startup and runtime, since the new repositories are never queried unless isStopTB is true.
📋 Description
JIRA ID:
Please provide a summary of the change and the motivation behind it. Include relevant context and details.
✅ Type of Change
ℹ️ Additional Information
Please describe how the changes were tested, and include any relevant screenshots, logs, or other information that provides additional context.