Hello and thanks in advance for your help.
I have developed a project where I have defined a customPrompt based on select/multiple select prompt. I have setup a handlebar file, the javascript file and I have included a prompt_types worksheet with prompt_type_name and type columns in the xls. The type is array.
It is working correctly in the application designer chorme preview tool but when I push the project to the android handset and try to run survey, the app crashes. I see the following error in the log:
E/createOrOpenTableWithColumnsAndProperties: 2018-06-05 02:26:38.409 org.opendatakit|java.lang.IllegalArgumentException: malformed elementType – cannot declare an object or array having no children: object dbHandle: uuid:2704bd71-8254-4775-837f-b38d3fdb9004
java.lang.IllegalArgumentException: malformed elementType – cannot declare an object or array having no children: object
at org.opendatakit.aggregate.odktables.rest.ElementType.parseElementType(ElementType.java:131)
at org.opendatakit.database.data.ColumnDefinition.getType(ColumnDefinition.java:559)
at org.opendatakit.database.data.ColumnDefinition.buildColumnDefinitions(ColumnDefinition.java:195)
at org.opendatakit.database.data.OrderedColumns.(OrderedColumns.java:47)
at org.opendatakit.services.database.utilities.ODKDatabaseImplUtils.createOrOpenTableWithColumnsAndProperties(ODKDatabaseImplUtils.java:2497)
at org.opendatakit.services.database.service.OdkDatabaseServiceImpl.createOrOpenTableWithColumnsAndProperties(OdkDatabaseServiceImpl.java:508)
at org.opendatakit.services.database.service.OdkDatabaseServiceInterface.createOrOpenTableWithColumnsAndProperties(OdkDatabaseServiceInterface.java:356)
at org.opendatakit.database.service.AidlDbInterface$Stub.onTransact(AidlDbInterface.java:390)
at android.os.Binder.execTransact(Binder.java:682)
Can you please tell me how should I define it? where can I find documentation or an example for that? I have seen examples with the pulseox object where properties.pulse.type and properties.ox.type are included in the worksheet but in my case there are no adittional fields.
Why does it work in the emulator and not in the real survey?
What I need to save in the custom fields of the in the database is:
[“item1”,“item3”,“item21”,“Item33”,“item2”,“item95”], this is what the chrome emulatar saves.
This is an example of what it has defined In the _colum_definitions table for one of these fields:
43 tableName zona_delantera zona_delantera array [“zona_delantera_items”]
For some reason it does not create the same in the handset.
I am usiing odk services and ODK survey 2.0.3 rev 220 in samsung device with android 8. ODK 2.0 rev 214a for the application designer web tool.
Thanks again