Hi,
Quite old feature request but... :-)
I'm able to show records from a MSSQL database with legacy tables that have nothing to do with TYPO3 (no uid, pid, or other columns). I did this:
- Created a tca.php with some fields of my 'Members' table
- Created a ext_tables.php
- Mapped pid to '1' (sysfolder/page with uid = 1) and uid columns to my primary key ('MemberID')
Configuration looks like that:
$TYPO3_CONF_VARS['EXTCONF']['dbal']['mapping'] = array(
'Members' => array(
'mapFieldNames' => array(
'pid' => '1',
'uid' => 'MemberID',
),
),
);
tca.php looks like that:
$TCA['Members'] = array(
'ctrl' => $TCA['Members']['ctrl'],
'interface' => array(
'showRecordFieldList' => 'firstname,lastname,email'
),
'feInterface' => $TCA['Members']['feInterface'],
'columns' => array(
'firstname' => array(
'exclude' => 0,
'label' => First Name',
'config' => array(
'type' => 'input',
'size' => '20',
'max' => '20',
'eval' => 'required,trim',
)
),
'lastname' => array(
'exclude' => 0,
'label' => 'Last Name',
'config' => array(
'type' => 'input',
'size' => '30',
'max' => '30',
'eval' => 'required,trim',
)
),
'email' => array(
'exclude' => 0,
'label' => 'Email',
'config' => array(
'type' => 'input',
'size' => '30',
'max' => '50',
'eval' => 'trim',
)
),
),
'types' => array(
'0' => array('showitem' => 'firstname;;;;1-1-1, lastname, email')
),
'palettes' => array(
'1' => array('showitem' => '')
)
);
Finally ext_tables.php looks like that:
$TCA['Members'] = array(
'ctrl' => array(
'title' => 'MEMBERS',
'label' => 'lastname',
'tstamp' => 'NOW',
'crdate' => 'NOW',
'cruser_id' => '0',
'default_sortby' => 'ORDER BY lastname',
'dynamicConfigFile' => t3lib_extMgm::extPath($_EXTKEY) . 'tca.php',
'iconfile' => t3lib_extMgm::extRelPath($_EXTKEY) . 'member.gif',
),
);
Records are shown but edit does not (yet) work. Furthermore, 'pid' cannot be mapped onto '0' (root).