diff --git a/src/formpack/constants.py b/src/formpack/constants.py index f992940..bdd8f30 100644 --- a/src/formpack/constants.py +++ b/src/formpack/constants.py @@ -51,9 +51,6 @@ 'hxl': '', } -GEO_QUESTION_TYPES = ('geopoint', 'geotrace', 'geoshape') -MEDIA_TYPES = ('audio', 'image', 'video') - # Export Settings EXPORT_SETTING_FIELDS = 'fields' EXPORT_SETTING_FIELDS_FROM_ALL_VERSIONS = 'fields_from_all_versions' diff --git a/src/formpack/reporting/export.py b/src/formpack/reporting/export.py index 32537bd..c03fcf5 100644 --- a/src/formpack/reporting/export.py +++ b/src/formpack/reporting/export.py @@ -14,7 +14,6 @@ import xlsxwriter from ..constants import ( - GEO_QUESTION_TYPES, TAG_COLUMNS_AND_SEPARATORS, UNSPECIFIED_TRANSLATION, ) @@ -24,7 +23,7 @@ from ..utils.flatten_content import flatten_tag_list from ..utils.geojson import field_and_response_to_geometry from ..utils.iterator import get_first_occurrence -from ..utils.replace_aliases import EXTENDED_MEDIA_TYPES +from ..utils.replace_aliases import EXTENDED_MEDIA_TYPES, GEO_TYPES from ..utils.spss import spss_labels_from_variables_dict from ..utils.string import unique_name_for_xls from ..utils.text import get_valid_filename @@ -697,7 +696,7 @@ def to_geojson( all_fields = version.sections[first_section_name].fields.values() all_geo_fields = [ - f for f in all_fields if f.data_type in GEO_QUESTION_TYPES + f for f in all_fields if f.data_type in GEO_TYPES ] all_geo_field_names = [f.name for f in all_geo_fields] diff --git a/src/formpack/utils/expand_content.py b/src/formpack/utils/expand_content.py index 71030b7..1e0cbd9 100644 --- a/src/formpack/utils/expand_content.py +++ b/src/formpack/utils/expand_content.py @@ -18,9 +18,8 @@ from .array_to_xpath import EXPANDABLE_FIELD_TYPES from .iterator import get_first_occurrence -from .replace_aliases import META_TYPES, selects +from .replace_aliases import MEDIA_TYPES, META_TYPES, selects from ..constants import ( - MEDIA_TYPES, OR_OTHER_COLUMN, TAG_COLUMNS_AND_SEPARATORS, UNTRANSLATED,