* Updated ChangeLog and raised version number to 1.3.0RC1
[Packages/TYPO3.CMS.git] / typo3 / sysext / extbase / ChangeLog.txt
1 ChangeLog for Extbase
2 =====================
4 Changes for 1.3.0 RC1:
5 ======================
6 included in TYPO3 4.5.0 RC1.
8 This release features many bugfixes, in the following areas:
9 * Persistence - invalid SQL has been fixed at various places
10 * MVC - the URI Builder can now handle cached / uncached actions correctly
11 * Improved error handling to catch some configuration errors
12 * Localization - TypoScript overrides for locallang keys with dot inside now works (_LOCAL_LANG.foo.bar)
13 * Persistence - added "pid" property and getter and setter to AbstractDomainModel; thus you can now move
14 domain objects to different pages. However, this feature has *no support for workspaces* yet.
15 * Dependency Injection - now allows the injection of prototypes (see below)
16 * Configuration - for defining the Storage PID, one can use arbitary TypoScript objects (see below)
18 Dependency Injection Improvements
19 ---------------------------------
21 Now, Prototype objects are allowed to be injected into other objects. This means the following cases
22 are supported:
24 * Singletons which need Singletons (most common)
25 * Singletons which need Prototypes (very uncommon,
26 as it usually hints at the fact that the injected
27 prototype should be a singleton). In this case,
29 * Prototypes which need Singletons
30 * Prototypes which need Prototypes
32 TypoScript Storage PID Improvements
33 -----------------------------------
35 The persistence.storagePid now has stdWrap properties so the storagePid can be set dynamically.
36 Now follows an example for use in the Frontend:
37 plugin.tx_extkey.persistence.storagePid.cObject = TEXT
38 plugin.tx_extkey.persistence.storagePid.cObject.value = 8,3
39 ... and this is how you can use it in the backend:
40 module.tx_extkey.persistence.storagePid.cObject = TEXT
41 module.tx_extkey.persistence.storagePid.cObject.value = 8,3
43 Full Changes for 1.3.0 RC1:
44 ===========================
45 [+BUGFIX] Extbase (Object): constructor injection now works if default value for a dependency is NULL. Thanks to Lienhart Woitok! Resolves #11623
46 [+BUGFIX] Extbase (Object): Allow injection of prototypes via dependency injection. Resolves #12013
47 [+BUGFIX] Extbase (Persistence): Use sql_free_result() in Typo3DbBackend to free result memory. Resolves #10957
48 [~BUGFIX] Extbase (Persistence): fixed an wrong referenced exception (resolves #12403)
49 [~BUGFIX] Extbase (Persistence): make Tx_Extbase_Persistence_Repository::remove() handle freshly created objects right. (resolves #11128)
50 [+BUGFIX] Extbase (MVC): UriBuilder automatically added a cHash even on links to nonCacheable actions where this is not needed/recommended (resolves #8565)
51 [~BUGFIX] Extbase (Persistence): made union statement on comma seperated list use find_in_set (Thanks to Marc Bastian Heinrichs) (resolves #9772)
52 [~FOLLOWUP] Extbase (Utility): allow clearPageCache() to clear single, multiple and all pageCaches. (resolves 11978)
53 [+TASK] Extbase (Utility): allow clearPageCache() to clear single, multiple and all pageCaches.
54 [+BUGFIX] Extbase (MVC): Improve Error Handling in Request Builder. Resolves #11302
55 [+BUGFIX] Extbase (Persistence): remove superfluous require_once statements. Thanks to Oliver Klee. Resolves #12324
56 [+BUGFIX] Extbase (Tests): Remove require_once of phpunit testclasses. Thanks to Oliver Klee. Resolves #12323
57 [+BUGFIX] Extbase (Utility): Make _LOCAL_LANG override work with dots. Thanks to Thomas Maroschik. Resolves #12121
58 [+BUGFIX] Extbase (Persistence): Fixed using the correct columnname for contains comparison with RELATION_HAS_MANY and empty parentKeyFieldName. Resolves #11048
59 [+BUGFIX] Extbase (Persistence): Added the missing pid property to the AbstractDomainModel. Related to #11361
60 [+BUGFIX] Extbase (Persistence): Language Oberlay now works with page table as well. Thanks to Andre Stoesel. Resolves #11319
61 [+BUGFIX] Extbase (Persistence): The QueryObject gets cloned now in the getFirst() method of the QueryResult (as it was intended). Thanks to Sebastian Fischer. Resolves #11855.
62 [+BUGFIX] Extbase (Bootstrap): Bootstrap calls initialize on reflectionService if it's already initialized. Resolves #12346, resolves #12156
63 [+BUGFIX] Extbase (Persistence): Fix equals constraint with $caseSensitive FALSE (closing bracket missing). Thanks to Alexander Berl. Resolves #10781
64 [+BUGFIX] Extbase (Reflection): ObjectAccess::isPropertyGettable works for ArrayAccess objects. Resolves #10148
65 [+BUGFIX] Extbase (Configuration): Allow StoragePid to be manually defined by TS. Thanks to Rens Admiraal! Resolves #8397
66 [+BUGFIX] Extbase (Configuration): Fix warning in AbstractConfigurationManager. Resolves #11631
67 [+BUGFIX] Extbase (Object): Disabling Dependency Injection for injectSettings method. Resolves #11011
70 Changes for 1.3.0 Beta 4:
71 =========================
72 included in TYPO3 4.5.0 Beta 4.
74 This release contains numerous bugfixes, and a few small features:
76 * Tx_Extbase_Utility_Extension::registerPlugin() now has a fourth parameter $pluginIconPathAndFilename
77 that you can set to the path of an icon, that will be displayed in the plugin dropdown in the backend.
78 You can use it like:
79 Tx_Extbase_Utility_Extension::registerPlugin(
80 $_EXTKEY,
81 'MyPlugin',
82 'My Plugin description',
83 t3lib_extMgm::extRelPath($_EXTKEY) . 'Resources/Public/Icons/someIcon.gif'
84 );
85 * Hidden Records in Workspaces now work
86 Before, if t3lib_pageSelect::getRecordOverlay returned FALSE (if
87 no translation is found), a fatal error occured:
88 PHP Catchable Fatal Error: Argument 2 passed to Tx_Extbase_Persistence_Mapper_DataMapper::getTargetType()
89 must be an array, boolean given, called in Persistence/Mapper/DataMapper.php
91 Full Changes for 1.3.0 Beta 4:
92 ==============================
94 [+TASK] Extbase (Tests): Fixed a repository unit test so that it works in CLI mode
95 [+TASK] Extbase (Tests): Fixed Extbase unit tests
96 [+BUGFIX] Extbase (Persistence): Hidden Records in Workspaces now work
97 [~TASK] Extbase: Fixed line endings (Windows to Unix).
98 [~TASK] Fluid (Tests): Fixed some more testcase class names and some unit tests
99 [+FEATURE] Extbase (Utility): Add support for custom specify custom plugin icon. Resolves #11179
101 Changes for 1.3.0 Beta 3:
102 =========================
103 included in TYPO3 4.5.0 Beta 3.
105 This release features numerous stability improvements, the biggest one
106 being a re-written core of the Object Manager, such that Lifecycle Methods
107 are supported now. This means, that a method "initializeObject()" gets called
108 as soon as all dependencies are injected and initialized.
110 Additionally, Extbase didn't work in all cases in the TYPO3 Backend. This has
111 also been improved, so Extbase (again) works in the backend
112 with an empty page tree.
114 Full Changes for 1.3.0 Beta 3:
115 =============================
117 [+BUGFIX] Extbase (Tests): Fixed Tx_Extbase_MVC_Controller_AbstractController_testcase. Thanks to Oliver Klee. Resolves #11567.
118 [BUGFIX] Extbase (Configuration): Make Extbase work again in Backend
119 [!!!][+TASK] Extbase (Object): Rewritten Object Container
120 [+BUGFIX] Extbase (MVC): Improve Exception message
121 If one misses the @dontvalidate annotation, he will
122 get a strange error which does not have a hint that
123 the @dontvalidate is missing. Now, the exception message
124 is extended.
125 [+API] Extbase (Configuration): Adding getContentObject to API
126 [+TASK] Extbase (Reflection): Added deprecation annotation to ObjectAccess::getAccessiblePropertyNames()
127 To stay in sync with FLOW3, the methods getAccessibleProperties() and getAccessiblePropertyNames() to
128 getGettableProperties() and getGettablePropertyNames().
129 For compatibility reasons the old methods will stay in Extbase until version 1.5.
130 Note: you can now check wheter properties are settable as well
131 [+FEATURE] Extbase (Reflection): Tx_Extbase_Reflection_ObjectAccess supports stdClass objects now
132 I've backported the ObjectAccess class and its unit tests from FLOW3.
133 Note: FLOW3's implementation allows to specify a third argument for the
134 method getPropertyPath() in order to support Closures.
135 This part is not backported as it's not compatible with PHP < 5.3.
137 Changes for 1.3.0 Beta 2a:
138 ==========================
139 included in TYPO3 4.5.0 Beta 2.
141 This release includes a whole bunch of bugfixes and refactorings, the most important ones listed below.
142 Because the FlashMessages now use t3lib_FlashMessage, TYPO3 4.5 is MANDATORY!
144 The main changes are:
146 * Tx_Extbase_MVC_Controller_FlashMessages now internally uses the
147 t3lib_FlashMessageQueue that has been introduced with TYPO3 4.3.
148 This results in following changes:
149 - flashmessages are now treated globally, not in a per-extension-scope. As soon as you output the messages first, the session will be flushed
150 - a flashmessage is not a simple strings anymore, but consists of
151 message body and (optionally) title & severity.
152 You can specify title and severity like this:
153 $this->flashMessages->add('Your message', 'some title', t3lib_FlashMessage::WARNING);
154 - you can now output flashmessages in backend that were set from other TYPO3 classes
155 - a revised flashmessage ViewHelper allows you to render flashmessages in the style
156 of core flashmessages now (see Fluid changelog)
157 - Resolves #10821
158 * Configuration Manager can now deal with recurring FlexForm Sections (#6067)
159 * Fixed Tx_Extbase_Domain_Model_FrontendUser (and marked the old API as deprecated)
160 * Bugfixes related to Lazy Loading
162 Full Changes for 1.3.0 Beta 2a:
163 ==============================
164 [+BUGFIX] Extbase (Configuration): change the order of methods to determine the current pageId for backend modules, which is used to fetch the TS framework configuration. Fixes #11205
165 [+TASK] Extbase (Object): Make sure the class info cache is returning valid objects
166 [+BUGFIX] Extbase (Persistence): Persistence_Backend::getIdentifierByObject should work with LazyLoadingProxy
167 getIdentifierByObject should check if object is an instance of Tx_Extbase_Persistence_LazyLoadingProxy and should return the
168 identifier of the real object.
169 [+BUGFIX] Extbase (Configuration): slightly tweaked FrontendConfigurationManager (basically replaced explode() by t3lib_div::trimExplode() call)
170 [+TASK] Extbase (Tests): Added some unit tests for Backend- and FrontendConfigurationManager. To be continued
171 [+BUGFIX] Extbase (DomainObject): added default __toString method to Tx_Extbase_DomainObject_AbstractDomainObject. Thanks to Marco Huber. Resolves #8083
172 [+BUGFIX] Extbase (MVC): Fixed UriBuilder for handling LazyLoadingProxy objects as arguments. Resolves #10705
173 [+TASK] Extbase (Object): re-added Tx_Extbase_Object_Manager to gain more backwards compatibility. This class is marked deprecated and will be removed in Extbase 1.5
174 [+BUGFIX] Extbase (Tests): tweaked ObjectContainer tests. Tests are failing deliberately for now
175 The DI implementation has to be rewritten, as discussed.
176 This relates to: #11160
177 [+BUGFIX] Extbase (Domain): fixed (non-breaking) method name for getting usergroup in Tx_Extbase_Domain_Model_FrontendUser. Resolves #11019
178 [+TASK] extbase (ConfigurationManager): Made FrontendConfigurationManager parse recurring sections in flexforms right. Thanks to Franz Koch (resolves #6067)
179 [+BUGFIX] Extbase (Configuration): Slightly tweaked AbstractConfigurationManager
180 [+TASK] Extbase (Tests): Added unit tests for AbstractConfigurationManager
181 Note: the ConfigurationManager now always overrides switchableControllerActions
182 when retrieving configuration for the current plugin. Before that only happened
183 when no extensionName/pluginName was specified.
184 Additionally: It's not possible anymore to specify new controllers in
185 switchableControllerAction configuration. That was the intended behavior.
186 [+TASK] Extbase (Tests): Renamed test files from "*_testcase.php" to "*Test.php"
187 [+TASK] Extbase (Tests): Moving all Tests in "Unit" directory.
188 [+FEATURE] Extbase (MVC): add possibility to output FlashMessageQueue (Resolves #10821)
189 [+TASK] Extbase (Persistence): counting query results does not work with limit constraints (resolves #10956) Tx_Extbase_Persistence_Storage_Typo3DbBackend::getObjectCountByQuery() replaces the SELECT part
190 of a query by COUNT(*) before executing a statement.
191 This did not work as expected in some cases, e.g. the LIMIT constraint was ignored by the count query.
192 [+TASK] Extbase (Persistence): findOneBy*() methods should return NULL if no item was found (Resolves #10958)
193 [+TASK] Extbase (Core): Slightly improved error handling in bootstrap (Resolves #11055)
194 [~TASK] Extbase (Utility): Changed Tx_Extbase_Utility_TypoScript:convertPlainArrayToTypoScriptArray to self::convertPlainArrayToTypoScriptArray. Resolves #10538.
195 [+BUGFIX] Extbase (MVC): UriBuilder: use current plugin if no pluginName has been specified
196 If multiple plugins are found, that are configured to handle the specified action, Extbase
197 will throw an Exception. Now, this only happens if the *current* plugin does not contain
198 the action.
200 Changes for 1.3.0 Beta 1a:
201 ==========================
202 included in TYPO3 4.5.0 Beta 1.
204 Extbase 1.3.0 Beta 1 has a lot new and greatly improved features, and also many bugfixes.
205 The highlights are outlined below, and explained in-depth a little further down.
207 NOTE: This release brings new table definitions, so please visit the install tool or the Extension
208 Manager and update the tables of Extbase.
212 * Dependency Injection
213 * Dispatcher Refactoring & Completely re-done Configuration Manager
214 This means that Tx_Extbase_Dispatcher is now DEPRECATED!
215 Additionally, if you defined the TypoScript setup for a plugin by hand (which you should not),
216 the syntax has changed a bit there.
217 * QueryResult refactoring (needed for Fluid Widgets)
220 Additionally, the following smaller features were implemented:
222 * Configurable plugin namespaces (#8365)
223 * Automatic target page determination (#9121)
224 * Improved resolveView() mechanism
225 * Allowing plugins to be registered as new content element (#10666)
226 * Default Orderings & QuerySettings (#10319)
228 Breaking Changes:
230 * The UriBuilder now uses the current cObject instead of creating a new instance in the constructor. This is a breaking change if you instantiated the UriBuilder in your code. Please use the Extbase ObjectManager or inject the ConfigurationManager manually.
231 * fixed typo in getter and setter of Tx_Extbase_Domain_Model_FrontendUser::lastlogin
232 * Flashmessages now share a scope throughout the extension. Before, every plugin had it's own scope leading to the messages only being output when entering the same plugin again (e.g. redirecting from one plugin to another would never display the messages)
234 Known issues:
236 * The Unit Tests do not fully work again, we will fix that in the next days.
237 * There might be still issues with the support of backend modules, we are working on that!
239 Dependency Injection
240 --------------------
242 Instead of creating objects through t3lib_div::makeInstance, and connecting them together manually,
243 you yan now use Dependency Injection (DI) for that. Let's give an example: If my class "Tx_Foo_Controller_MyController"
244 needs another class "Tx_Foo_Service_LoggingService", it can get an instance of the logging service
245 by Dependency Injection, by specifying the following code:
247 class Tx_Foo_Controller_MyController {
248 protected $loggingService;
250 /**
251 * @param Tx_Foo_Service_LoggingService $loggingService
252 */
253 public function injectLoggingService(Tx_Foo_Service_LoggingService $loggingService) {
254 $this->loggingService = $loggingService;
255 }
256 }
258 The DI container finds that the class "MyController" has an method whose name starts with "inject",
259 and thus passes the logging service to MyController.
260 It is important that you can *only retrieve Singletons* through the inject annotations. If you need
261 to instanciate a prototype object, it is important to *not* use t3lib_div::makeInstance() anymore
262 (as it bypasses the DI container), but instead you need to inject the ObjectManager, and ask it
263 to create your prototype object using the create() method. Example:
265 class Tx_Foo_Controller_MyController {
266 protected $logFile;
268 /**
269 * @param Tx_Extbase_Object_ObjectManagerInterface $objectManager
270 */
271 public function injectObjectManager(Tx_Extbase_Object_ObjectManagerInterface $objectManager) {
272 $this->logFile = $objectManager->create('Tx_Foo_Domain_Model_LogFile');
273 }
274 }
276 In the above example, you have seen that we reference not the concrete implementation *ObjectManager*,
277 but instead the *ObjectManagerInterface*. If a name ends with "...Interface", Extbase DI automatically
278 strips away the "Interface" from the name, and expects to find a concrete implementation of that interface.
279 This is generally a very good practice: For your core classes, you should always reference an *interface*,
280 and let the DI container instanciate the concrete class.
282 Additionally, Extbase DI allows to *replace* certain implementation classes by other classes through
283 configuration in TypoScript. Let's give an example, and then you can see the concept:
285 config.tx_extbase.objects {
286 Tx_Extbase_Persistence_Storage_BackendInterface {
287 className = Tx_Extbase_Persistence_Storage_Typo3DbBackend
288 }
289 }
291 This essentially means to the DI container: "At all places where you encounter a "BackendInterface",
292 you should instanciate the "Typo3DbBackend" class."
294 However, note that this setting can only be configured *globally* right now, it is not possible
295 to override that on a per-extension basis.
297 Generally, the Extbase DI container provides a subset of the functionality of FLOW3's dependency injection.
299 Dispatcher Refactoring & Completely re-done Configuration Manager
300 -----------------------------------------------------------------
302 In the last versions of Extbase, the Dispatcher (Tx_Extbase_Dispatcher) was the main entry point to Extbase.
303 However, as we did not have Dependency Injection at that point, it became really complex and did lots of things
304 which it should not do in the first place. That's why we greatly improved that part. Now, any Extbase extension
305 is invoked using the Tx_Extbase_Core_Bootstrap. Additionally, the TypoScript used for the registration of any
306 Extbase extension has been cleaned up and adjusted:
308 lib.foo = USER
309 lib.foo {
310 userFunc = tx_extbase_core_bootstrap->run
311 extensionName = YourExtension
312 pluginName = YourPlugin
313 }
315 Additionally, you can also override the list of Switchable Controller Actions through TypoScript:
317 lib.foo = USER
318 lib.foo {
319 userFunc = tx_extbase_core_bootstrap->run
320 extensionName = YourExtension
321 pluginName = YourPlugin
322 switchableControllerActions {
323 Standard {
324 1 = action2
325 2 = action3
326 }
327 }
328 }
330 Of course, you cannot call actions which were not defined previously in the plugin; so the Switchable
331 Controller Actions in TypoScript can be only used to shrink the number of actions available.
333 NOTE: If you manually defined the above snippet, notice that there is a NON-BACKWARDS-COMPATIBLE change
334 in there. But you did that at your own risk, as that was never public API ;)
336 If you used Tx_Extbase_Dispatcher before in your own code, it should still work, but it is deprecated.
337 Instead, instead
339 OLD: Tx_Extbase_Dispatcher::getConfigurationManager()
340 NEW: inject Tx_Extbase_Configuration_ConfigurationManagerInterface into your class
342 OLD: Tx_Extbase_Dispatcher::getPersistenceManager()
343 NEW: inject Tx_Extbase_Persistence_ManagerInterface into your class
345 OLD: Tx_Extbase_Dispatcher::getExtbaseFrameworkConfiguration()
346 NEW: inject Tx_Extbase_Configuration_ConfigurationManagerInterface into your class,
347 and call $configurationManager->getConfiguration(Tx_Extbase_Configuration_ConfigurationManagerInterface::CONFIGURATION_TYPE_FRAMEWORK);
348 on the ConfigurationManager.
350 Please note that the Configuration Manager is STILL NO PUBLIC API, and its method signature has also changed.
352 QueryResult refactoring (needed for Fluid Widgets)
353 --------------------------------------------------
355 Before this change, a call of $query->execute() inside a repository immediately executed the query and
356 returned the result as array.
357 Now, queries are executed lazily at the first moment where you really need them. This means that $query->execute()
358 returns an object of type Tx_Extbase_Persistence_QueryResultInterface, which behaves like an array, meaning you
359 can use foreach() to loop over the query result.
360 However, due to an inconsistency of PHP, the array_* methods, and the iteration methods like current(),
361 next(), ... do NOT work on objects which implement ArrayAccess -- that's the reason why the QueryResult
362 refactoring is a breaking change.
364 Now, however, the following is possible:
365 * Return the first query result: $query->execute()->getFirst()
366 * Get the underlying query: $query->execute()->getQuery()
367 * Convert the result to array: $query->execute()->toArray()
369 This change is a prerequisite for Fluid Widgets to work. See the Fluid ChangeLog for details.
372 Configurable Plugin Namespaces
373 ------------------------------
375 By default each Extbase plugin has a unique URI prefix to avoid collisions with other plugins on your website.
376 This so called plugin namespace usually has the format tx_yourextension_yourplugin.
377 With Extbase 1.3 it is possible to override this namespace. This comes in handy if want to interact with 3rd party
378 extensions, for example with tt_news:
380 plugin.tx_yourextension.view.pluginNamespace = tx_ttnews
382 This sets the plugin namespace of all your plugins inside the extension to "tx_ttnews", making it possibl
383 to directly access tt_news parameters in your controller:
385 /**
386 * @param integer $tt_news tt_news Article uid
387 * @return void
388 */
389 public function yourAction($tt_news) {
390 // interact with $tt_news uid
391 }
393 This works with automatic mapping to Domain models too of course:
395 /**
396 * @param Tx_YourExtension_Domain_Model_NewsArticle $tt_news tt_news Article
397 * @return void
398 */
399 public function yourAction(Tx_YourExtension_Domain_Model_NewsArticle $tt_news) {
400 // interact with $tt_news object
401 }
403 You can also override the plugin namespace for a single instance by adding the section <view.pluginNamespace> to your
404 plugin FlexForm.
407 Automatic target page determination
408 -----------------------------------
410 In TYPO3 v5 we won't have the notion of page uids. To accustom developers to this change, we're trying to free you from
411 the need to specify target pages from within your Extension. Of course you can put all your functionality into one fully
412 fledged plugin, then you won't have to deal with target pages as the current page is used by default.
414 But sometimes you want to be able to change the surrounding contents of a special view of your extension (e.g. the
415 subcontent column of a details page). As before you can still specify the target page explicitly like:
417 <f:link.action action="foo" pageUid="123" />
419 With Extbase 1.3 you can also use a new feature called "automatic target page determination". It is disabled by default,
420 but you can enable it with the following TypoScript:
422 plugin.tx_yourextension.view.defaultPid = auto
424 Then Extbase will search the page tree for a plugin that is configured to handle the specified action and you can omit
425 the "pageUid" parameter in your links. Of course, this does not work if you use the same plugin multiple times in your
426 page tree. In this case you can override the default page ID for the respective plugins:
428 plugin.tx_yourextension_yourplugin.view.defaultPid = 123
430 Note: By default this feature is not activated, because that would be a breaking change in some cases
433 Improved resolveView() mechanism
434 --------------------------------
436 Another feature we backported from FLOW3 is the improved view resolving.
437 You can now change the default view implementation *per format* by inserting the following line in your Controller:
439 protected $viewFormatToObjectNameMap = array(
440 'json' => 'Tx_YourExtension_View_JsonView',
441 'html' => 'Tx_YourExtension_View_HtmlView'
442 );
445 Allowing plugins to be registered as new content element
446 --------------------------------------------------------
448 This is done using an additional parameter to Tx_Extbase_Utility_Extension::configurePlugin
449 that allows you to specify the plugin type. Example:
451 Tx_Extbase_Utility_Extension::configurePlugin(
452 $_EXTKEY,
453 'BlogList',
454 array('Blog' => 'index'),
455 array(),
456 Tx_Extbase_Utility_Extension::PLUGIN_TYPE_CONTENT_ELEMENT
457 );
458 (The default value for the pluginType parameter is Tx_Extbase_Utility_Extension::PLUGIN_TYPE_PLUGIN)
460 Default Orderings & QuerySettings
461 ---------------------------------
463 It is now possible to change the default orderings of a repository without you having to modify the query by setting
464 the $defaultOrderings property of your Repository to a non-empty array:
466 protected $defaultOrderings = array(
467 'title' => Tx_Extbase_Persistence_QueryInterface::ORDER_ASCENDING,
468 'date' => 'title' => Tx_Extbase_Persistence_QueryInterface::ORDER_DESCENDING
469 );
471 This will change the default ordering for all queries created by this repository. Of course you can override the
472 ordering by calling $query->setOrderings() in your custom finder method.
474 Besides it's now possible to change the default query settings of a repository. This way you could for instance disable
475 "respect storage pid" for all queries. We added a life-cycle method "initializeObject" to the repository which will be
476 executed as soon as the repository is created. Just override it like the following:
478 public function initializeObject() {
479 $querySettings = $this->objectManager->create('Tx_Extbase_Persistence_Typo3QuerySettings');
480 $querySettings->setRespectStoragePage(FALSE);
481 $this->setDefaultQuerySettings($querySettings);
482 }
484 Of course, QuerySettings can be overridden too in your custom finder method by calling $query->setQuerySettings();
487 Full Changes for 1.3.0 Beta 1a:
488 ===============================
489 [+TASK] Extbase: Re-implement support for BE modules
490 [+FEATURE] Extbase (Utility): Allow plugins to be registered as new content element
491 Added a fifth parameter to Tx_Extbase_Utility_Extension::configurePlugin that allows
492 you to specify the plugin type (currently "list_type" and "CType" are supported).
493 Thanks to Marc Bastian Heinrichs, Rens Admiraal & Franz Koch for your help!
494 Resolves: #10666
495 [+BUGFIX] Extbase (Utility): Added condition to Tx_Extbase_Utility_Extension::getTargetPidByPlugin() in order to only select tt_content entries that are of CType "list". Thanks to Marc Bastian Heinrichs
496 [!!!][~TASK] Extbase (Configuration): Major rework of the ConfigurationManager
497 Configuration of controllers and actions is now stored in a global registry
498 ($GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['extbase']['extensions']). But you
499 should never access this directly. Instead always retrieve the frameworkConfiguration
500 from the ConfigurationManager.
501 Inserting an Extbase plugin is now as simple as:
502 lib.foo = USER
503 lib.foo {
504 userFunc = tx_extbase_core_bootstrap->run
505 extensionName = YourExtension
506 pluginName = YourPlugin
507 }
508 This is not really a breaking change as it does not change the public API. But it's not unlikely that it changes the behavior of your Extension in case you modified the TypoScript, that is generated by Tx_Extbase_Utility_Extension::configurePlugin().
509 NOTE: Unit tests of Extbase and Fluid v4 are broken currently. We'll be fixing those asap
510 [~TAKS] Extbase (MVC): FrontendRequestHandler now retrieves the current cObject through the ConfigurationManager
511 [+BUGFIX] Extbase (MVC): FrontendRequestHandler was refering to $this->frameworkConfiguration which wasn't available
512 [-API] Extbase (MVC): marked Tx_Extbase_MVC_Web_Request::getContentObjectData() deprecated as should retrieve the current cObject through the ConfigurationManager
513 [+TASK] Extbase (MVC): modified the Tx_Extbase_MVC_Web_RequestBuilder so that it's possible to change the action only by specifying the action parameter. Before you had to specify the controller as well, even if it was the default controller
514 [+BUGFIX] Extbase (MVC): Flashmessages now share a scope throughout the extension. Before, every plugin had it's own scope leading to the messages only being output when entering the same plugin again (e.g. redirecting from one plugin to another would never display the messages)
515 [~TASK] Extbase (Core): The Flashmessages now get persisted in the Bootstrap in resetSingletons()
516 [-TASK] Extbase (Core): Removed some commented lines from Bootstrap
517 [FEATURE] Extbase (Object): Make DI Class Mapping configurable through TS
518 It is now possible to configure the Dependency Injection class mapping by specifying:
519 config.tx_extbase.objects.[FullyQualifiedObjectName].className = [NewClassName]
520 This has the effect of effectively replacing [FullyQualifiedObjectName] with
521 [NewClassName].
522 Resolves: #10559
523 [-TASK] Extbase (Utility): Removed two obsolete checks for $GLOBALS['TSFE']->tmpl->setup['tt_content.']['list.']['20.'] in Tx_Extbase_Utility_Extension
524 [~TASK] Extbase: added two doc comments that were missing
525 [+BUGFIX] Extbase (Persistence): Extbase still used PHPs current() on some QueryResults in Persistence/Repository. Replaced these by calls to the getFirst() method of the QueryResult
526 [+TASK] Extbase (Persistence): added a private field to the QueryResult to make the above case easier to debug: When calling current() on an Iterator, PHP returns the first field of that object instead of calling the current() method of the Iterator interface.. With our somewhat pragmatic approach you'll see the warning if you debug the results of current($query->execute())
527 [+BUGFIX] Extbase (Persistence): Replaced two occurrences of Query->count() by Query->execute()->count() to avoid deprecated warnings in the Core
528 [+BUGFIX] Extbase (MVC): view configuration (templateRootPath, ...) has to be set before View::canRender() is called
529 [!!!][+TASK] Extbase (MVC): The UriBuilder now uses the current cObject instead of creating a new instance in the constructor. This is a breaking change if you instantiated the UriBuilder in your code. Please use the Extbase ObjectManager or inject the ConfigurationManager manually.
530 [+BUGFIX] Extbase (Reflection): ReflectionService now uses a cacheIdentifier per Extension. Besides the Bootstrap now resets the ReflectionService after dispatching a request. This resolves #10146
531 [+TASK] Extbase (Configuration): The ConfigurationManager now holds the current cObject. You can retrieve it via ConfigurationManagerInterface::getContentObject()
532 [+BUGFIX] Extbase (Configuration): When loading configuration of other plugins, the context specific configuration (e.g. flexform settings) are no longer merged with the frameworkConfiguration
533 [+BUGFIX] Extbase (MVC): Controllers are no Singletons by default. If a controller contains stateful fields (e.g. $this->settings) this breaks multiple plugins on one page
534 [+TASK] Extbase (Persistence): QuerySettings now also store the storage page id(s). This is required for the upcoming Ajax Widgets
535 [+BUGFIX] Extbase: fixed php warning in Tx_Extbase_Persistence_LazyLoadingProxy when loading the real instance would return NULL. Resolves #10683
536 [+BUGFIX] Extbase: use 3rd parameter = TRUE of t3lib_div::trimExplode to split switchableControllerActionParts from flexform. Thanks to Georg Ringer. Resolves #10688
537 [+TASK] Extbase: Replaced "public static" by "static public" in various places to be CGL conform
538 [+TASK] Extbase: Marked Utitlity_Extension camelCase/underscore helper functions deprecated
539 [+TASK] Extbase: Removed obsolete FIXME comments, whitespace fixes
540 [!!!] Extbase: Reintegrating branch "dispatcher" to trunk. Resolves: #10605
541 Branch history:
542 [+FEATURE] Extbase (Configuration): Extend ConfigurationManager so that it can load configuration of different plugins
543 [+FEATURE] Extbase (Configuration): 1st level cache for ConfigurationManager. Resolves: #10717. Resolves: #10716
544 [+TASK] Extbase: cleaned up Configuration* implementation, replaced t3lib_div::makeInstance() calls
545 Streamlined ConfigurationManager API and enforced its usage throughout the Extbase classes.
546 Replaced all t3lib_div::makeInstance() calls by $objectManager->create()/$objectManager->get() throughout the Extbase classes.
547 Some smaller tweaks and fixes. Resolves: #10655. Resolves: #10712
548 [TASK] Extbase (Object): Make tests work again. Resolves: #10709
549 [TASK] Extbase (Object): Updated autoload.php and emconf. Relates to: #10561
550 [TASK] Extbase (Object): Use typed exceptions. Relates to: #10561
551 [TASK] Extbase (Object): CGL cleanup
552 Additionally, removed support for @inject annotations at methods. Relates to: #10561
553 [TASK] Extbase (Object): Remove getParents. Relates to: #10561
554 [TASK] Extbase (Object): Remove isSingleton. Relates to: #10561
555 [TASK] Extbase (Object): Remove injectExtensionSettings feature. Relates to: #10561
556 [TASK] Extbase (Object): Change namespaces to Tx_Extbase_Object_Container. Relates to: #10561
557 [TASK] Extbase (Object): Add Container to Extbase. Relates to: #10561
558 [+TASK] Extbase (Core): moved Tx_Extbase_Bootstrap to Tx_Extbase_Core_Bootstrap
559 Moving Bootstrap to be compliant with FLOW3
560 Removed obsolete Classes. Resolves: #10704
561 [+TASK] Extbase: Merged current trunk (r2689) with local modifications into dispatcher branch
562 Note: This still needs a cleanup and some fixes (see FIXME comments) before it can be merged back to the trunk. Relates to: #10605. Relates to: #10655
563 [+TASK] Extbase (Configuration): Moved CONFIGURATION_TYPE_* constraints to ConfigurationManagerInterface. Resolves #10604.
564 [~TASK] Extbase (Configuration): The concrete configuration management strategy gets instanciate only once now.
565 [+FEATURE] Extbase (MVC): Decoupled framework settings from Dispatcher.
566 With the new dependency injection feature you can get the Configuration Manager injected by adding the lines
567 protected $configurationManager;
568 public function injectConfigurationManager(Tx_Extbase_Configuration_ConfigurationManagerInterface $configurationManager) {
569 $this->configurationManager = $configurationManager;
570 }
571 You can get various types of configuration invoking
572 $this->configurationManager->getConfiguration(Tx_Extbase_Configuration_ConfigurationManager::CONFIGURATION_TYPE_EXTBASE)
573 where the class constant must be either CONFIGURATION_TYPE_EXTBASE (for Extbase settings), or CONFIGURATION_TYPE_SETTINGS (for the current module/plugin settings), or CONFIGURATION_TYPE_TYPOSCRIPT (for a raw TS array). Resolves #4741.
574 [~TAKS] Extbase: Removed obsolete code.
575 [~TASK] Extbase: Added core patch for mod.php (see previous commit).
576 [+TASK] Extbase: Changed the way a module gets called.
577 - You can now specify a function name to be invoked by mod.php:
578 $TBE_MODULES['_dispatcher'][] = 'Tx_Extbase_Bootstrap->callModule';
579 - This requires a core patch.
580 [~TASK] Extbase: Changed configuration of the RequestHandler class names to TypoScript.
581 - The request handlers can now be registered in TypoScript with the setting:
582 config.tx_extbase.mvc.requestHandlers.[RequestHandlerClassName] = [RequestHandlerClassName].
583 - There are now two RequestHandlers in Extbase: FrontendRequestHandler and BackendRequestHandler. Common functionality is in the AbstractRequestHandler.
584 [+API][+FEATURE] Extbase (Utility): Implemented mechanism to register RequestHandlers.
585 [+TASK] Extbase: Backported Request Handler Resolver.
586 [~TASK] Extbase: Added "deprecated" annotation to Dispatcher.
587 [~TASK] Extbase: Added missing comment.
588 [+BUGFIX] Extbase (Reflection): The ReflectionService now gets injected to the dispatcher. Related to #10146.
589 [+BUGFIX] Extbase (Reflection): Changed the way the Reflection Service and it's cache gets initialized.
590 * Removed check for pre-initialized Reflection Service in the Bootstrap.
591 * Now using a fixed cache key ('ReflectionData').
592 Related to #10146.
593 [~TASK] Extbase: First step of the Dispatcher refactoring.
594 * Added and adapted some Unit Tests.
595 * Moved the Dispatcher to MVC.
596 * Added a backwards compatibility Dispatcher on root level.
597 * Added a Bootstrap class.
598 * Removed all backend module support for now.
599 Related to #7153.
600 [+TASK] Extbase: Added branch for the dispatcher refactoring.
601 [!!!][+BUGFIX] Extbase: fixed typo in getter and setter of Tx_Extbase_Domain_Model_FrontendUser::lastlogin . Thanks to Christian Schwan. Resolves #9345
602 [+FEATURE] Extbase (MVC): Backport possibility to change the view object class name more easily
603 Backported FLOW3s improved resolveView() mechanism. Tx_Fluid_View_TemplateView is still the default implementation, but can be easily changed by setting $defaultViewObjectName in your controller. Besides it's possible to specifying different views depending on the current request format by setting $viewFormatToObjectNameMap.
604 NOTE: If the view can't be rendered, the new template based "NotFoundView" will be created. So instead of the invisible HTML comments of the EmptyView, you'll get a more meaningful error message if the template file could not be found
605 Resolves: #8990
606 [!!!][+FEATURE] Extbase (Persistence): Backport QueryResult from FLOW3
607 Now Query::execute() returns an instance of QueryResultInterface that allows it to modify the query before actually accessing the records that it retrieves. This is required for the upcoming "Fluid widgets" backport (#10568).
608 NOTE: This change is not backwards compatible, if you work with PHPs array_* functions on the query result. To work around this issue, you'll have to convert the query result to an array before by calling the QueryResult::toArray() method. We're planning to add a compatibility mode, but that's not yet implemented.
609 Resolves: #10566
610 [+BUGFIX] Extbase (Object): Minor fix in ObjectManager to make it compatible with PHP 5.2.x
611 Relates to: #9062
612 [+BUGFIX] Extbase (Object): Refactor Object Manager
613 The Object Manager is now at the same location and
614 has the same API as in FLOW3.
615 [+BUGFIX] Extbase: Major cleanups to Dependency Injection and Persistence
616 Now, DI finally works with Persistence, cleaning
617 this greatly up. Additionally, all internal
618 t3lib_div::makeInstance calls have been replaced.
619 Now, dependency injection is actually usable.
620 Additionally, we completely thought over which
621 persistence classes need to be singleton and which
622 should be prototype, leading finally to a
623 coherent design in the persistence layer.
624 [+BUGFIX] Extbase: remove non-used interfaces
625 Removed classes which were not used.
626 Relates to: #9062
627 Resolves: #10585
628 Resolves: #10564
629 * Cleaned up Persistence Backend
630 * Cleaned up QOM Factory
631 [+BUGFIX] Extbase (MVC): Fix arguments object
632 The arguments object is now correctly inheriting from ArrayObject
633 Resolves: #10562
634 [+BUGFIX] Extbase (MVC): Make database connection work again
635 Resolves: #10585
636 [+FEATURE] Extbase (DI): merging DI into trunk. (resolves #10558)
637 [+TASK] Extbase: Undefined identifier in Tx_Extbase_Persistence_Storage_Typo3DbBackend::removeRow
638 Method clearPageCache was given an undefined variable $uid as second parameter.
639 Resolves: #10570
640 [+TASK] Extbase: $query->contains generate incomplete SQL
641 Use FIND_IN_SET instead of a self-constructed query of LIKE statements
642 Resolves: #8959
643 [+BUGFIX] Extbase (Persistence): Removed method createQuery from the QOMFactory. It is neither part of the API nor is it used by Extbase. Resolves #10215
644 [+BUGFIX] Extbase (Property): Minor fix in PHP doc comment
645 Fix the order of @param annotation in Tx_Extbase_Property_Mapper::mapAndValidate()
646 Resolves: #5887
647 [~CONFIGURATION] Extbase (MVC): Changed default value for automatic target page determination
648 The page id gets automatically detected if plugin.tx_extensionname_pluginname.view.defaultPid
649 is an empty string (was "auto" before). This ensures backwards compatibility.
650 Resolves #9121
651 [TASK] Extbase: moved Release Notes to ChangeLog.txt.
652 [+FEATURE] Extbase (MVC): Automatic target page determination
653 you can use the "pageUid" argument of the link.* and uri.* view helpers
654 to link to a different page. That is deprecated though as we won't have
655 the notion of "page uids" in v5. Instead the target page is now determined
656 automatically.
657 If the target page can't be determined because more than one active
658 plugin is capable of handling the action an exception will be thrown.
659 In that case you'll have to define the target page either by using the
660 pageUid argument or - preferably - by setting
661 plugin.tx_extensionname_pluginname.view.defaultPid to a fixed page uid.
662 Note: This feature still has to be documented!
663 Resolves: #9121
664 [+FEATURE] Extbase (MVC): Configurable plugin namespace
665 until now the namespace (aka prefix) of Extbase plugins was
666 fixed (tx_extensionname_pluginname). This is now configurable
667 via TypoScript. Just write:
668 plugin.tx_extensionname_pluginname.view.pluginNamespace = my_custom_namespace
669 to change the prefix for a specific plugin or
670 plugin.tx_extensionname.view.pluginNamespace = my_custom_namespace
671 to change if for the whole extension.
672 Note: This feature still has to be documented!
673 Resolves: #8365
675 Changes for 1.3.0 Alpha 2:
676 ==========================
677 included in TYPO3 4.5.0 Alpha 2.
679 Since the last version, one (possible BREAKING) change happened:
681 * Fixed Extbase Caching Bug.
682 Non-cacheable actions were cached due to the fact that TYPO3s
683 TypoScript condition "GP" does not merge GET & POST vars.
684 Additionally "switchableControllerActions" that were overridden
685 in the plugin flexform were not taken into account.
687 !!! This is a breaking change if you set up your TS configuration
688 of the plugin manually.
690 Full Changes:
691 -------------
693 [!!!][+BUGFIX] Extbase: Fix Extbase Caching Bug (thanks to Bastian Waidelich)
695 [-TASK] Extbase (MVC): removed fallback to current page in AbstractController::redirect() as that's already done within the UriBuilder if $targetPageUid is NULL
698 Changes for 1.3.0 Alpha 1:
699 ==========================
700 included in TYPO3 4.5.0 Alpha 1.
702 Since the last version, the following notable things happened:
704 * All methods trying to find an object by uid now ignore the storagePid. This changes the behavior of argument mapping and the way extbase fetches 1:1 relations. Resolves #5631. You should not experience any negative side-effects of this change, i.e. if your extension worked before, it will definitely after this change. However, it makes the record handling more robust.
705 * Performance improvements in TypoScript::convertTypoScriptArrayToPlainArray. Thanks to Timo Schmidt.
706 * Numerous other bugfixes, see below.
708 Full Changes:
709 -------------
710 [~TASK] Extbase: Raised version number to 1.3.0-devel to reflect the version scheme defined in the wiki. Resolves #9152. Thanks Xavier for pointing to it.
711 [+TASK] Extbase (MVC): cleaned up View implementations and added assign() and assignMultiple() methods to ViewInterface. This resolves #9137
712 [+BUGFIX] Extbase: Fixed a small typo in extension description.
713 [+BUGFIX] Extbase (Persistence): DataMapper now mapps NULL into a property on non-existing related object instead of FALSE. Resolves #8973.
714 [+BUGFIX] Extbase (Reflection): getParentClass() in Tx_Extbase_Reflection_ClassReflection no longer causes a fatal error if no parent class exists. Resolves #8800.
715 [+BUGFIX] Extbase (Utility): Improved performance of TypoScript::convertTypoScriptArrayToPlainArray. Thanks to Timo Schmidt. Resolves #8857.
716 [~TASK] Extbase: Changed state to 'stable'. Resolves #8768.
717 [+BUGFIX] Extbase: Fixed EOL and encoding of several files. Resolves #8876.
718 [+BUGFIX] Extbase (MVC): Fixed a problem where a non-required action argument throwed Exception if it was not found in the Backend. Thanks to Marc Bastian Heinrichs. Resolves #7277.
719 [!!!][+BUGFIX] Extbase (Persistence): All methods trying to find an object by uid now ignores the storagePid. This changes the behavior of argument mapping and the way extbase fetches 1:1 relations. Resolves #5631.
720 [+BUGFIX] Extbase (Persistence): Fixed a problem where localized objects inside an aggregate are not translated. Resolves #8555.
721 [~TASK] Extbase: Removed new lines at the end of php files.
723 RELEASE NOTES of Extbase v1.0.0
724 ===============================
726 This package contains the Extbase Framework for Extensions. You may
727 also want to install the BlogExample (blog_example) to experiment
728 with. This little example extension demonstrates some of the main
729 features of Extbase. The documentation is bundled in a separate
730 extension called doc_extbase. Both, the blog_example and the
731 doc_extbase can downloaded via TER.
733 http://typo3.org/extensions/repository/view/blog_example/current/
734 http://typo3.org/extensions/repository/view/doc_extbase/current/
736 Currently Extbase is in ALPHA state. Do not expect everything in the
737 right place and shape. And keep in mind that the API may change
738 until TYPO3 v4.3beta1 is released.
740 If you have any feature requests or encountered issues regarding
741 this package please use the facilities on forge to report.
743 We are very open to answer your questions. Please use the newsgroup
745 typo3.projects.typo3v4mvc on lists.netfielders.de
747 so other developers can react to your comments and also
748 profit from the postet solutions. Do not contact a member of the
749 development team via private email (or skype, or visits, or ...)
750 until he accepted this channel. We all do coding for Extbase on
751 our sparetime and must handle our regular work load - and don't
752 forget about our families ;-).
754 We hope you have fun with this package!
756 -- Your Extbase Development Team
759 ===========================
760 git log [startRevision]..HEAD --pretty=format:"%s%n%b%n" | grep -v "^$" | grep -v "git-svn-id"
762 Verify that the merge into the Core succeeded:
763 diff -urNw --exclude=".git" --exclude=".svn" -I "@version" ../../../typo3/sysext/extbase/ .