feat(csv-parser): Implement CSV import functionality with mapping and type conversion
- Added permissions for editing and deleting CSV field mappings. - Created type converter for CSV cells to handle various data types. - Implemented database migrations for CSV field mappings and import logs. - Seeded initial system templates for nutrition and activity data imports. - Developed admin endpoints for managing system CSV templates. - Introduced user endpoints for CSV import analysis and mapping retrieval. - Added tests for core CSV parser functionalities, including delimiter detection and value conversion.
This commit is contained in:
1 parent
73963e7140
commit
4a771f6a83
16 files changed
+3252
-1
No files matched your search
@@ -0,0 +1,27 @@
|
||||
"""Universal CSV import foundation (Issue #21)."""
|
||||
|
||||
from csv_parser.core import (
|
||||
decode_raw_bytes,
|
||||
sniff_delimiter,
|
||||
parse_csv_sample,
|
||||
column_signature,
|
||||
normalize_header_for_signature,
|
||||
)
|
||||
from csv_parser.module_registry import MODULE_DEFINITIONS, get_module_definition, list_modules
|
||||
from csv_parser.type_converter import convert_value, build_row_after_mapping
|
||||
from csv_parser.permissions import user_may_delete_mapping, user_may_edit_mapping_row
|
||||
|
||||
__all__ = [
|
||||
"decode_raw_bytes",
|
||||
"sniff_delimiter",
|
||||
"parse_csv_sample",
|
||||
"column_signature",
|
||||
"normalize_header_for_signature",
|
||||
"MODULE_DEFINITIONS",
|
||||
"get_module_definition",
|
||||
"list_modules",
|
||||
"convert_value",
|
||||
"build_row_after_mapping",
|
||||
"user_may_delete_mapping",
|
||||
"user_may_edit_mapping_row",
|
||||
]
|
||||
Reference in new issue
Block a user