src/Subjects/ExportableTrait.php
/**
     * Add the passed product type artefacts to the product with the
     * last entity ID.
     *
     * @param string  $type      The artefact type, e. g. configurable
     * @param array   $artefacts The product type artefacts
     * @param boolean $override  Whether or not the artefacts for the actual entity ID has to be overwritten
     *
     * @return void
     * @uses \TechDivision\Import\Product\Subjects\BunchSubject::getLastEntityId()
     */
Add the passed product type artefacts to the product with the
last entity ID.

@param string  $type      The artefact type, e. g. configurable
@param array   $artefacts The product type artefacts
@param boolean $override  Whether or not the artefacts for the actual entity ID has to be overwritten


Add the passed product type artefacts to the product with the last entity ID . @param string $type The artefact type e . g . configurable @param array $artefacts The product type artefacts @param boolean $override Whether or not the artefacts for the actual entity ID has to be overwritten
public function addArtefacts($type, array $artefacts, $override = true)
    {
        if (sizeof($artefacts) === 0) {
            return;
        }
        $keys = array_keys($artefacts);
        foreach ($keys as $key) {
            if (isset($artefacts[$key][ColumnKeys::ORIGINAL_DATA])) {
                $artefacts[$key][ColumnKeys::ORIGINAL_DATA] = $this->isDebugMode() ? serialize($artefacts[$key][ColumnKeys::ORIGINAL_DATA]) : null;
            }
        }
        if ($override === true) {
            $this->overrideArtefacts($type, $artefacts);
        } else {
            $this->appendArtefacts($type, $artefacts);
        }
    }
public function addArtefacts ( $ type , array $ artefacts , $ override = true ) { if ( sizeof ( $ artefacts ) === 0 ) { return ; } $ keys = array_keys ( $ artefacts ) ; foreach ( $ keys as $ key ) { if ( isset ( $ artefacts [ $ key ] [ ColumnKeys :: ORIGINAL_DATA ] ) ) { $ artefacts [ $ key ] [ ColumnKeys :: ORIGINAL_DATA ] = $ this -> isDebugMode ( ) ? serialize ( $ artefacts [ $ key ] [ ColumnKeys :: ORIGINAL_DATA ] ) : null ; } } if ( $ override === true ) { $ this -> overrideArtefacts ( $ type , $ artefacts ) ; } else { $ this -> appendArtefacts ( $ type , $ artefacts ) ; } }
Add the passed product type artefacts to the product with the
 last entity ID.
Add the passed product type artefacts to the product with the last entity ID .
// query whether or not, any artefacts are available // serialize the original data, if we're in debug mode // query whether or not, existing artefacts has to be overwritten