[TYPO3-english] external_import, nesting pages
davidgreiner at gmx.net
Fri Jan 30 14:33:12 CET 2015
Thanks for your fast reply and thanks for your awesome work with
The mapping does the trick... No need for extra userfunction. Thanks a
lot! I have tried such a mapping before, probably with wrong arguments.
I have one more question. Is it correct, that my csv file gets imported
in a reverse order?
CSV1 does not work for the import.
CSV2 does import all the data correctly:
Its still the same content, just reversed.
Am 30.01.2015 um 13:36 schrieb François Suter:
> Hi David,
>> In this userfunction i check for currently existing pages which
>> "tx_vtmmage_magento_category_id" == "the current external parent_id". If
>> there is a result, the uid of this page will be returned and should be
>> used as pid for the new record.
>> Unfortunately this pid gets overridden while importing and all new
>> records gets defined 'pid' => 97" from the ctrl section.
> Have you checked that your function works as expected? Normally
> external_import will not override the "pid" field if it already
> contains a value, so my guess is that your function returns nothing.
> BTW have you tried simply mapping the pid field to the pages table
> itself, i.e. something like:
> $GLOBALS['TCA']['pages']['columns']['pid']['external'] = array(
> 0 => array(
> 'field' => 'parent_id',
> 'mapping' => array(
> 'table' => 'pages',
> 'reference_field' => 'tx_vtmmage_magento_category_id'
> This should normally work.
More information about the TYPO3-english