[TYPO3-dev] Fields in the TCA that does not exist in the DB
Malte Jansen
mail at maltejansen.de
Tue Oct 23 21:12:15 CEST 2007
I can confirm this, you don't have to create the column.
For displaying the form:
class tx_yourextension_tceform {
getMainFields_preProcess($table, &$row, &$pObj) {
if ($table == 'tx_yourextension_table') {
$row["your_virtual_field_without_column"] = $some_value;
}
}
}
Before saving the form:
class tx_yourextension_tcemain {
function processDatamap_preProcessFieldArray(&$fieldArray, $table,
$id, &$pObj) {
if ($table == 'tx_yourextension_table') {
$fieldArray["your_virtual_field_without_column"] = 0;
}
}
}
But it would be cool, if don't have to create one or more Hooks...
Dmitry Dulepov [typo3] schrieb:
> Steffen Kamper wrote:
>> Maybe Dmitry or other devs with good TCA-knowledge could give a tip too.
>
> I think the problem can be solved with a hook, which will unset values
> before writing them to database. But these values must be set again
> before appearing in TCEforms.
>
More information about the TYPO3-dev
mailing list