Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
341a34f
Enforced mandatory validation for "Reason for Refusal in section e in…
sehjotsinghunthinkable Jun 22, 2026
2908c20
Added counselled flag to confirmed cases response, indicating whether…
sehjotsinghunthinkable Jun 23, 2026
9396905
Align `/complete` and `/submitBulk` form response editing behavior
sehjotsinghunthinkable Jun 23, 2026
9e28141
Merge branch 'vb/counselling' into vb/counselling
sehjotsinghunthinkable Jun 23, 2026
105ede6
Add van/sync tracking fields (vanID, parkingPlaceID, vanSerialNo, pro…
sehjotsinghunthinkable Jun 24, 2026
21b7187
feat(dynamic-form): add Hindi localization fields and completed benef…
sehjotsinghunthinkable Jun 25, 2026
fdb1a1f
feat(dynamic-form): add Hindi localization fields and completed benef…
sehjotsinghunthinkable Jun 25, 2026
6d8cb0b
Merge branch 'vb/counselling' into vb/counselling
vishwab1 Jun 25, 2026
5f05f66
feat(beneficiary): expose GPS coordinates in getBeneficiaryData response
sehjotsinghunthinkable Jun 26, 2026
6ae9ed0
Committed 82b00ccf with only the three files:
sehjotsinghunthinkable Jun 26, 2026
0332e9b
Revert "Committed 82b00ccf with only the three files:"
sehjotsinghunthinkable Jun 26, 2026
4123985
Committed 82b00ccf with only the three files:
sehjotsinghunthinkable Jun 26, 2026
b7488fe
Committed 82b00ccf with only the three files:
sehjotsinghunthinkable Jun 26, 2026
78d402c
Merge branch 'vb/counselling' into vb/counselling
sehjotsinghunthinkable Jun 26, 2026
b92cdea
Updated isMandatory field in Section C, so changed in TbCounsellingFo…
sehjotsinghunthinkable Jun 30, 2026
81e29d2
Add optional villageId and providerServiceMapId filters to getComplet…
sehjotsinghunthinkable Jul 2, 2026
be0d0d6
Removing section f from seeder
sehjotsinghunthinkable Jul 2, 2026
f6aca3a
Removing already existing check in /complete api
sehjotsinghunthinkable Jul 2, 2026
41550c2
Add a CHECKBOX question type and a TB_COUNSELLING_V2 seeder with a GE…
sehjotsinghunthinkable Jul 5, 2026
380014c
Seed single-checkbox questions for Sections A-D and point the Counsel…
sehjotsinghunthinkable Jul 6, 2026
4aafc4b
Mark form/section status REFUSED when TB2_GI_Q1=NO on /complete, spli…
sehjotsinghunthinkable Jul 6, 2026
b4bc4e0
Resolved conflicts
sehjotsinghunthinkable Jul 7, 2026
c53b9b5
fix(stoptb): getBeneficiaryData reads anthropometry/vitals from stand…
vishwab1 Jun 30, 2026
c7806cf
fix(compile): rename variable 'a' to 'anthro' to avoid conflict with …
vishwab1 Jun 30, 2026
d8008c3
fix(stoptb): set CreatedDate on t_benvisitdetail insert to prevent NO…
vishwab1 Jun 30, 2026
095f0ae
fix(anc-pnc): guard CreatedDate on BenVisitDetail insert for ANC and …
vishwab1 Jun 30, 2026
3b3a4c5
fix(docker): set TZ=Asia/Kolkata to prevent UTC/IST date mismatch
vishwab1 Jul 1, 2026
b1d28ae
fix(stoptb): handle ISO 8601 Z suffix in parseDob to fix beneficiary …
vishwab1 Jul 1, 2026
6d92f74
fix(stoptb): fallback to i_ben_flow_outreach.ben_dob when i_beneficia…
vishwab1 Jul 1, 2026
7459c47
fix: use saveAndFlush to prevent FK violation in t_benchiefcomplaint
vishwab1 Jul 1, 2026
9fccf6f
fix(stoptb): compute age from benDetailsRMNCH_OBJ.dob instead of benD…
vishwab1 Jul 3, 2026
7ddde0a
fix(stoptb): scope Suspected/Confirmed getAll by facility+village ins…
vishwab1 Jul 3, 2026
33c4f4d
fix(stoptb): drop date filter from facility-scoped Suspected query
vishwab1 Jul 3, 2026
349e714
fix(stoptb): join facility-scoped query on beneficiaryID, not benefic…
vishwab1 Jul 3, 2026
4d6606e
Added counselled flag to confirmed cases response, indicating whether…
sehjotsinghunthinkable Jun 23, 2026
33219a1
Revert "Committed 82b00ccf with only the three files:"
sehjotsinghunthinkable Jun 26, 2026
6951221
Committed 82b00ccf with only the three files:
sehjotsinghunthinkable Jun 26, 2026
e9fd699
Merge branch 'vb/counselling' into vb/counselling
vishwab1 Jul 7, 2026
e2cb73b
feat(beneficiary): expose GPS coordinates in getBeneficiaryData response
sehjotsinghunthinkable Jun 26, 2026
043ab84
Changing working of checkbox as of radio button
sehjotsinghunthinkable Jul 7, 2026
22202ff
Merge branch 'vb/counselling' into vb/counselling
sehjotsinghunthinkable Jul 7, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
* A single question's answer within a section answer request.
* Exactly one of optionValue, optionValues, answerText, or answerDate should be set per question type:
* RADIO → optionValue (single string)
* CHECKBOX → optionValue (single string, e.g. "CHECKED")
* MCQ → optionValues (list of strings, one row saved per element)
* TEXT/AUTO_FILL → answerText
* DATE → answerDate (ISO date string) or answerText
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public class QuestionResponseDTO {

private Long questionResponseId;
private Long questionId;
/** Populated for RADIO and MCQ answers. */
/** Populated for RADIO, MCQ, and CHECKBOX answers. */
private Long optionId;
/** Populated for TEXT, DATE, AUTO_FILL answers. */
private String answerText;
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/com/iemr/flw/masterEnum/QuestionType.java
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ public enum QuestionType {
RADIO,
/** Multi-select from a predefined list of options. */
MCQ,
/** Single boolean checkbox — checked or unchecked. May carry options for display
* purposes; answers are still stored as free text. */
/** Single boolean checkbox — checked or unchecked. Resolved like RADIO: submit
* optionValue to select it, omit to leave unanswered. */
CHECKBOX,
/** Free-text input. */
TEXT,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -358,6 +358,25 @@ private String getMappingsForAddressIDs(List<RMNCHMBeneficiaryaddress> addressLi
if (benDetailsRMNCH_OBJ.getGpsLongitude() != null)
benDetailsRMNCH_OBJ.setLongitude(BigDecimal.valueOf(benDetailsRMNCH_OBJ.getGpsLongitude()));

// GPS fallback: if not in RMNCH details (syncdatatoamrti not yet called),
// pull from i_beneficiaryaddress (saved during TM-API registration)
if (benDetailsRMNCH_OBJ.getGpsLatitude() == null && benAddressOBJ.getGpsLatitude() != null)
benDetailsRMNCH_OBJ.setGpsLatitude(benAddressOBJ.getGpsLatitude());
if (benDetailsRMNCH_OBJ.getGpsLongitude() == null && benAddressOBJ.getGpsLongitude() != null)
benDetailsRMNCH_OBJ.setGpsLongitude(benAddressOBJ.getGpsLongitude());
if (benDetailsRMNCH_OBJ.getDigipin() == null && benAddressOBJ.getDigipin() != null)
benDetailsRMNCH_OBJ.setDigipin(benAddressOBJ.getDigipin());
if (benDetailsRMNCH_OBJ.getGpsTimestamp() == null && benAddressOBJ.getGpsTimestamp() != null)
benDetailsRMNCH_OBJ.setGpsTimestamp(benAddressOBJ.getGpsTimestamp());
if (benDetailsRMNCH_OBJ.getIsGpsUnavailable() == null && benAddressOBJ.getIsGpsUnavailable() != null)
benDetailsRMNCH_OBJ.setIsGpsUnavailable(benAddressOBJ.getIsGpsUnavailable());

// Map GPS double fields to the exposed latitude/longitude BigDecimal fields for response
if (benDetailsRMNCH_OBJ.getGpsLatitude() != null)
benDetailsRMNCH_OBJ.setLatitude(BigDecimal.valueOf(benDetailsRMNCH_OBJ.getGpsLatitude()));
if (benDetailsRMNCH_OBJ.getGpsLongitude() != null)
benDetailsRMNCH_OBJ.setLongitude(BigDecimal.valueOf(benDetailsRMNCH_OBJ.getGpsLongitude()));

// -----------------------------------------------------------------------------

// related benids
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
import com.iemr.flw.dto.iemr.SectionResponseDTO;
import com.iemr.flw.domain.iemr.DynamicForm;
import com.iemr.flw.masterEnum.FormResponseStatus;
import com.iemr.flw.masterEnum.FormResponseStatus;
import com.iemr.flw.masterEnum.FormType;
import com.iemr.flw.repo.iemr.DynamicFormRepo;
import com.iemr.flw.repo.iemr.FormResponseRepo;
Expand Down Expand Up @@ -388,7 +389,7 @@ private List<QuestionResponse> processAnswers(
// Delete any existing answers for this question in this section (handles re-saves)
questionResponseRepo.deleteByQuestionIdAndSectionResponseId(questionId, sectionResponseId);

if (type == QuestionType.RADIO) {
if (type == QuestionType.RADIO || type == QuestionType.CHECKBOX) {
if (answer.getOptionValue() != null) {
QuestionOption opt = resolveOption(
optionsByQuestion, questionId, answer.getOptionValue(), answer.getQuestionUuid());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -328,7 +328,7 @@ private List<QuestionResponse> processAnswers(

questionResponseRepo.deleteByQuestionIdAndSectionResponseId(questionId, sectionResponseId);

if (type == QuestionType.RADIO) {
if (type == QuestionType.RADIO || type == QuestionType.CHECKBOX) {
if (answer.getOptionValue() != null) {
QuestionOption opt = resolveOption(optionsByQuestion, questionId,
answer.getOptionValue(), answer.getQuestionUuid());
Expand Down