ePages 6.11.0 - DE_EPAGES/CrossSelling/API/CSV/CrossSellingExportImport.pm

Package DE_EPAGES::CrossSelling::API::CSV::CrossSellingExportImport

This module implements the high level interface for import and export of CrossSellingProductMaps to CSV files.

Functions

csvExport
csvImport
new
warningCodes

csvExport

Exports objects to a CSV file.

Syntax
$Driver->csvExport($Shop, $PathFileName, $hFileFormat);
$Driver->csvExport($Shop, $PathFileName, $hFileFormat, $aProductIDs);
Example
my $Driver = DE_EPAGES::CrossSelling::API::CSV::CrossSellingExportImport->new;
$Driver->csvExport( $Shop, 'CrossSelling.csv', {
        'LanguageCode2s' => ['de', 'en'],
        'LocaleID' => 'de_DE',
} );
Input
$Shop (string)
alias of shop
$PathFileName (string)
CSV file name
$hFileFormat (ref.hash)
defines what to export
  • LanguageCode2s - list of ISO language codes. defines which
    languages are exported. If the list is empty, then all
    languages are exported. - array of strings
  • LocaleID - locale id - string
$aProductIDs (ref.array.integer)
list of product identifier which crosssellings will be
exported, if undef all crossselling for all products where exported
(optional)

csvImport

Imports objects from a CSV file into a shop.

Syntax
$Driver->csvImport($Shop, $PathFileName, $hFileFormat);
Example
my $Driver = DE_EPAGES::CrossSelling::API::CSV::CrossSellingExportImport->new;
$Driver->csvImport( $Shop , 'CrossSelling.csv', {
        'LanguageCode2s' => ['de', 'en'],
        'LocaleID' => 'de_DE',
} );
Input
$Shop (string)
alias of shop
$PathFileName (string)
CSV file name
$hFileFormat (ref.hash)
defines what to export
  • LanguageCode2s - list of ISO language codes. defines which
    languages are imported. If the list is empty, then all
    languages are imported. - array of strings
  • LocaleID - locale id - string

new

Creates a new csv export driver.

Syntax
$Driver= DE_EPAGES::CrossSelling::API::CSV::CrossSellingExportImport->new(%options);
Example
$Driver= DE_EPAGES::CrossSelling::API::CSV::CrossSellingExportImport->new;
Input
%options (hash)
exporter options
Return
$Driver (object)
import/export driver

warningCodes

Returns the warning codes for csv export.

Syntax
$aWarningCodes = $Driver->warningCodes();
Return
$aWarningCodes (array.string)
warning codes