Hi Everyone,
We have a editable grid where we placed 2 drop down values. Second dropdown choice values and choice labels purely dependent on first drop down selected value.But we are getting the error.
a!dropdownField( label: "Therapeutic Area", placeholder: "---Please Select---", choiceLabels: index(local!therapeuticArea, "name", {}), choiceValues: index( local!therapeuticArea, "therapeuticAreaId", {} ), value: fv!item.therapeuticAreaId, saveInto: { fv!item.therapeuticAreaId, a!save(fv!item.diseaseStateId, null), a!save(fv!item.studyGap1Id, null()) }, required: true(), validationGroup: cons!ISR_VALIDATION_GROUP_SUBMIT ), a!dropdownField( label: "Evidence Category", labelPosition: "ABOVE", value: fv!item.studyGap1Id, choiceValues: index( rule!ISR_qry_GetStudyGap1ById( isActiv: true(), studyGap1Ids: rule!ISR_qry_GetStudyGap1ByTAIds( therapeuticIds: fv!item.therapeuticAreaId, diseaseStateIds: fv!item.diseaseStateId, fetchTotalCount: false() ), columns: { "name", "studyGap1Id" }, returnDataSubset: false() ), "studyGap1Id", {} ), choiceLabels: index( rule!ISR_qry_GetStudyGap1ById( isActiv: true(), studyGap1Ids: rule!ISR_qry_GetStudyGap1ByTAIds( therapeuticIds: fv!item.therapeuticAreaId, diseaseStateIds: fv!item.diseaseStateId, fetchTotalCount: false() ), columns: { "name", "studyGap1Id" }, returnDataSubset: false() ), "name", {} ), placeholder: "-- Please Select the value for Evidence Category", required: true(), disabled: if(fv!item.therapeuticAreaId, false, true), validationGroup: cons!ISR_VALIDATION_GROUP_SUBMIT, saveInto: { fv!item.studyGap1Id, a!save( fv!item.studyGap1Name, index( rule!ISR_qry_GetStudyGap1(StudyGap1Id: fv!item.studyGap1Id), "name", null ) ), a!save( fv!item.evidenceCategory, index( rule!ISR_qry_GetStudyGap1(StudyGap1Id: fv!item.studyGap1Id), "name", null ) )/ }, ),
Discussion posts and replies are publicly visible
For this we will need to know what your choiceLabels and choiceValues evaluate to. I would debug by doing something such as, commenting out the dropdownField and adding a textField in it's place temporarily with these values.
choice values will have ids and choice labels will have names from the database
Can you check design_errors.csv it will log more about your error (With the above details we couldn't understand what's the exact error was ). Just like Chris mentioned above try debugging from root level (For example try passing values to second dropdown directly to see how it behaves)