ropensci / ruODK

ruODK: An R Client for the ODK Central API
https://docs.ropensci.org/ruODK/
GNU General Public License v3.0
41 stars 12 forks source link

Feature/extend schema with choice filter #108

Closed mtyszler closed 3 years ago

mtyszler commented 3 years ago

Closes #105

When using form_schema_ext the choice lists are missing for select types when a choice_filter is applied.

This update covers this case with and without languages.

Test forms:

sample_xlsform_no_languages_choicefilter.xlsx

sample_xlsform_label_and_choice_languages_choicefilter.xlsx

Action needed Tests passed locally, in my own ODK Central Cloud deployment. For obvious reasons, the tests in https://github.com/mtyszler/ruODK/blob/fce2aadcf4e7fea50f0dc357cdf9feb4f507c65f/tests/testthat/test-form_schema_ext.R have just a place holder.

I marked here https://github.com/mtyszler/ruODK/commit/fce2aadcf4e7fea50f0dc357cdf9feb4f507c65f where changes will be needed.

florianm commented 3 years ago

Thanks for the PR @mtyszler! I've uploaded the test forms to the test server and shortened the names a bit:

fid = Sys.getenv("ODKC_TEST_FID_I8N3", unset = "I8n_no_lang_choicefilter")
fid = Sys.getenv("ODKC_TEST_FID_I8N4", unset = "I8n_lang_choicefilter")

The tests are passing, I'm releasing this as version 0.9.5 shortly.