ePages 6.10 - DE_EPAGES/Content/API/CSV/ContentImportHandler.pm

Package DE_EPAGES::Content::API::CSV::ContentImportHandler

This module implements a handler to import content objects See DE_EPAGES::Content::API::CSV::ContentExportImport for usage examples.

Base
DE_EPAGES::ShopCSVExportImport::API::CSV::ShopObjectImportHandler

Functions

processMediaGalleryImage

processMediaGalleryImage

Copies the category image from the given source and generates its scaled variations. Updates the given attribute hash with the image names.

Syntax
$hNewAttributes = $self->processMediaGalleryImage(
    $hDirectAttributes,
    $SourceFileName,
    $TargetFileName
);
Example
$hDirectAttributes = $self->processMediaGalleryImage(
    $hDirectAttributes,
    $MGNewImageLargeAbs,
    $Category->get('PublicPath') . '/' . $NewImageLargeFileName.$NewImageLargeExtension
);
Input
$Object (object)
Category object which was imported
$SourceFileName (string)
full file path and name of the source image
$TargetFileName (string)
full file path and name for the target image
$ScaleImages
boolean value if automatic generation of other image sizes
should be applied.
$hScaleDimension (ref.hash)
Width and Height for the scaled image
Return
$hDirectAttributes (ref.hash)
updated direct attribute values