Bug #82911
closedTCA Subclasses doese not affect ObjectStorages
0%
Description
config.tx_extbase {
persistence {
classes {
EXT\ExtA\Domain\Model\Facility {
subclasses {
EXT\ExtB\Domain\Model\AdvancedFacility = EXT\ExtB\Domain\Model\AdvancedFacility
}
}
EXT\ExtB\Domain\Model\AdvancedFacility {
mapping {
tableName = tx_ext_domain_model_facility
}
}
}
}
}
config.tx_extbase {
objects {
EXT\ExtA\Domain\Model\Facility {
className = EXT\ExtB\Domain\Model\AdvancedFacility
}
}
}
I try to subclass a Model over TCA (see above).
It works fine with repositories. Sadly ObjectStorages give me only the standard Facility not the AdvancedFacility.
I See in the Datamaps of the DataMapper the Subclass but it is completly ignored.
it was in a Schedule.
Updated by Benjamin Rannow about 7 years ago
- Priority changed from Must have to -- undefined --
- Complexity changed from medium to no-brainer
EDIT: NOTHING
Updated by Benjamin Rannow about 7 years ago
- Priority changed from -- undefined -- to Should have
EDIT: it was Extbase bootstap, which is not called in Scheduler Mode
Fixed it with this in my Scheduler Task
$bootstrap = GeneralUtility::makeInstance(\TYPO3\CMS\Extbase\Core\Bootstrap::class);
$bootstrap->initialize([
'extensionName' => 'EXTKEY',
'pluginName' => 'PLUGINNAME',
'vendorName' => 'VENDORNAME'
]);
Updated by Benni Mack over 5 years ago
- Status changed from New to Closed
Thanks for the hint. Yes. that is/was a conceptual problem within Extbase CLI bootstrap, which is not reliably fixable on CLI (due to Configuration based on TypoScript which is bound to a Page ID). That's why we migrated to Symfony Console and deprecated Command Controller logic in v9, and removed it in v10.0. So your workaround works fine for your use-case but that's nothing we will fix in Core. However, we're building new ways to set up Extbase configuration in v10.0 so this will solve issues on CLI as well.