Skip to main content
Version: Next

Data Import and Export

Files Referenced in this Document

  • IMyEntityNameAppService.cs
  • MyEntityNameAppService.cs
  • MyEntityNameExcelDto.cs

Table of Contents​

  1. Introduction
  2. Overview
  3. Architecture
  4. Supported Formats

Introduction​

The Data Import and Export module provides a standardized way to move large amounts of data in and out of the system. Integrated within the Application Service layer, it ensures that data handling respects the same business rules and validation logic as standard API calls.

Overview​

This feature is designed to support:

  • Bulk Creation: Importing data from external sources via Excel.
  • Reporting: Exporting current system data for offline analysis.
  • Migration: Moving data between environments.

Architecture​

The functionality is built upon the IDataImportAppService<T> interface, which enforces a standard contract for import/export operations.

  • DTOs: MyEntityNameExcelDto defines the structure of the Excel row, often using attributes to map column names.
  • Service: MyEntityNameAppService implements the logic, coordinating between the Repository (database) and the Excel Manager (file parsing).
  • Excel Manager: A utility component responsible for reading/writing Excel file streams.

Supported Formats​

Currently, the system primarily supports:

  • Import: .xlsx (Excel 2007+)
  • Export: .xlsx (Excel 2007+)

This covers the most common business use cases.