onadata.apps.logger package¶
Subpackages¶
- onadata.apps.logger.management package
- Subpackages
- onadata.apps.logger.management.commands package
- Submodules
- onadata.apps.logger.management.commands.add_id module
- onadata.apps.logger.management.commands.change_s3_media_permissions module
- onadata.apps.logger.management.commands.create_backup module
- onadata.apps.logger.management.commands.create_image_thumbnails module
- onadata.apps.logger.management.commands.export_gps_points module
- onadata.apps.logger.management.commands.export_xforms_and_instances module
- onadata.apps.logger.management.commands.fix_duplicate_instances module
- onadata.apps.logger.management.commands.fix_submission_count module
- onadata.apps.logger.management.commands.import module
- onadata.apps.logger.management.commands.import_briefcase module
- onadata.apps.logger.management.commands.import_forms module
- onadata.apps.logger.management.commands.import_instances module
- onadata.apps.logger.management.commands.import_tools module
- onadata.apps.logger.management.commands.move_media_to_s3 module
- onadata.apps.logger.management.commands.populate_osmdata_model module
- onadata.apps.logger.management.commands.publish_xls module
- onadata.apps.logger.management.commands.pull_from_aggregate module
- onadata.apps.logger.management.commands.restore_backup module
- onadata.apps.logger.management.commands.set_xform_surveys_with_geopoints module
- onadata.apps.logger.management.commands.set_xform_surveys_with_osm module
- onadata.apps.logger.management.commands.sync_deleted_instances_fix module
- onadata.apps.logger.management.commands.update_moved_forms module
- onadata.apps.logger.management.commands.update_xform_uuids module
- Module contents
- onadata.apps.logger.management.commands package
- Module contents
- Subpackages
- onadata.apps.logger.migrations package
- Submodules
- onadata.apps.logger.migrations.0001_initial module
- onadata.apps.logger.migrations.0002_auto_20150717_0048 module
- onadata.apps.logger.migrations.0003_dataview_instances_with_geopoints module
- onadata.apps.logger.migrations.0004_auto_20150910_0056 module
- onadata.apps.logger.migrations.0005_auto_20151015_0758 module
- onadata.apps.logger.migrations.0006_auto_20151106_0130 module
- onadata.apps.logger.migrations.0007_osmdata_field_name module
- onadata.apps.logger.migrations.0008_osmdata_osm_type module
- onadata.apps.logger.migrations.0009_auto_20151111_0438 module
- onadata.apps.logger.migrations.0010_attachment_file_size module
- onadata.apps.logger.migrations.0011_dataview_matches_parent module
- onadata.apps.logger.migrations.0012_auto_20160114_0708 module
- onadata.apps.logger.migrations.0013_note_created_by module
- onadata.apps.logger.migrations.0014_note_instance_field module
- onadata.apps.logger.migrations.0015_auto_20160222_0559 module
- onadata.apps.logger.migrations.0016_widget_aggregation module
- onadata.apps.logger.migrations.0017_auto_20160224_0130 module
- onadata.apps.logger.migrations.0018_auto_20160301_0330 module
- onadata.apps.logger.migrations.0019_auto_20160307_0256 module
- onadata.apps.logger.migrations.0020_auto_20160408_0325 module
- onadata.apps.logger.migrations.0021_auto_20160408_0919 module
- onadata.apps.logger.migrations.0022_auto_20160418_0518 module
- onadata.apps.logger.migrations.0023_auto_20160419_0403 module
- onadata.apps.logger.migrations.0024_xform_has_hxl_support module
- onadata.apps.logger.migrations.0025_xform_last_updated_at module
- onadata.apps.logger.migrations.0026_auto_20160913_0239 module
- onadata.apps.logger.migrations.0027_auto_20161201_0730 module
- Module contents
- onadata.apps.logger.models package
- Submodules
- onadata.apps.logger.models.attachment module
- onadata.apps.logger.models.data_view module
- onadata.apps.logger.models.instance module
- onadata.apps.logger.models.note module
- onadata.apps.logger.models.osmdata module
- onadata.apps.logger.models.project module
- onadata.apps.logger.models.survey_type module
- onadata.apps.logger.models.widget module
- onadata.apps.logger.models.xform module
- Module contents
- onadata.apps.logger.tests package
- Subpackages
- Submodules
- onadata.apps.logger.tests.test_backup_tools module
- onadata.apps.logger.tests.test_briefcase_api module
- onadata.apps.logger.tests.test_briefcase_client module
- onadata.apps.logger.tests.test_digest_authentication module
- onadata.apps.logger.tests.test_encrypted_submissions module
- onadata.apps.logger.tests.test_form_list module
- onadata.apps.logger.tests.test_form_submission module
- onadata.apps.logger.tests.test_importing_database module
- onadata.apps.logger.tests.test_instance_creation module
- onadata.apps.logger.tests.test_parsing module
- onadata.apps.logger.tests.test_publish_xls module
- onadata.apps.logger.tests.test_simple_submission module
- onadata.apps.logger.tests.test_update_xform_uuid module
- onadata.apps.logger.tests.test_webforms module
- Module contents
Submodules¶
onadata.apps.logger.admin module¶
onadata.apps.logger.factory module¶
onadata.apps.logger.import_tools module¶
onadata.apps.logger.tasks module¶
onadata.apps.logger.views module¶
onadata.apps.logger.xform_fs module¶
ODK Collect/Briefcase XForm instances folder traversal.
- class onadata.apps.logger.xform_fs.XFormInstanceFS(filepath)¶
Bases:
object
A class to traverse an ODK Collect/Briefcase XForm instances folder.
- classmethod is_valid_instance(filepath)¶
Returns True if the XML at
filepath
is a valid XML file.
- property metadata_directory¶
Returns the metadata directory.
- property osm¶
Returns all .osm file paths.
- property photos¶
Returns all .jpg file paths.
- property xml¶
Returns the submission XML
onadata.apps.logger.xform_instance_parser module¶
XForm submission XML parser utility functions.
- exception onadata.apps.logger.xform_instance_parser.InstanceEmptyError¶
Bases:
InstanceParseError
- class onadata.apps.logger.xform_instance_parser.XFormInstanceParser(xml_str, data_dictionary)¶
Bases:
object
XFormInstanceParser - parses an XML string into an XML object.
- get(abbreviated_xpath)¶
- get_attributes()¶
- get_flat_dict_with_attributes()¶
Adds the submission XML top level attributes to the resulting python object.
- get_root_node()¶
- get_root_node_name()¶
- get_version()¶
Returns the submission XML version attribute.
- get_xform_id_string()¶
Returns the submission XML id attribute.
- parse(xml_str)¶
Parses a submission XML into a python dictionary object.
- to_dict()¶
- to_flat_dict()¶
- onadata.apps.logger.xform_instance_parser.clean_and_parse_xml(xml_string)¶
Removes spaces between XML tags in
xml_string
Returns an XML object via minidom.parseString(xml_string)
- onadata.apps.logger.xform_instance_parser.get_deprecated_uuid_from_xml(xml)¶
Returns the deprecatedID from submission XML
- onadata.apps.logger.xform_instance_parser.get_meta_from_xml(xml_str, meta_name)¶
Return the meta section of an XForm submission XML.
- onadata.apps.logger.xform_instance_parser.get_submission_date_from_xml(xml)¶
Returns submissionDate from an XML submission.
- onadata.apps.logger.xform_instance_parser.get_uuid_from_xml(xml)¶
Returns the uuid of an XForm submisison XML
- onadata.apps.logger.xform_instance_parser.parse_xform_instance(xml_str, data_dictionary)¶
Parses an XForm submission XML into a flattened python object with additional attributes.
- onadata.apps.logger.xform_instance_parser.xform_instance_to_dict(xml_str, data_dictionary)¶
Parses an XForm submission XML into a python object.
- onadata.apps.logger.xform_instance_parser.xform_instance_to_flat_dict(xml_str, data_dictionary)¶
Parses an XForm submission XML into a flattened python object.
- onadata.apps.logger.xform_instance_parser.xpath_from_xml_node(node)¶
Returns the xpath of an XML node.