mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
Add entry to change log about CMSPageHistoryController deprecation. (#8508)
* Add entry to change log about CMSPageHistoryController deprecation. * Correct typo #8508 * Tweaking CMS History controller changelog entry #8508
This commit is contained in:
parent
022e0b971e
commit
4e62698391
@ -7,6 +7,7 @@
|
||||
- Take care with `stageChildren()` overrides. `Hierarchy::numChildren() ` results will only make use of `stageChildren()` customisations that are applied to the base class and don't include record-specific behaviour.
|
||||
- New React-based search UI for the CMS, Asset-Admin, GridFields and ModelAdmins.
|
||||
- A new `GridFieldLazyLoader` component can be added to `GridField`. This will delay the fetching of data until the user access the container Tab of the GridField.
|
||||
- `SilverStripe\VersionedAdmin\Controllers\CMSPageHistoryViewerController` is now the default CMS history controller and `SilverStripe\CMS\Controllers\CMSPageHistoryController` has been deprecated.
|
||||
|
||||
## Upgrading {#upgrading}
|
||||
|
||||
@ -41,3 +42,23 @@ public function getCMSFields()
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
### Keep using the legacy `CMSPageHistoryController`
|
||||
|
||||
To keep using the old CMS history controller for every page type, add the following entry to your YML config.
|
||||
|
||||
```yml
|
||||
SilverStripe\Core\Injector\Injector:
|
||||
SilverStripe\CMS\Controllers\CMSPageHistoryController:
|
||||
class: SilverStripe\CMS\Controllers\CMSPageHistoryController
|
||||
```
|
||||
|
||||
If you want to use both CMS history controllers in different contexts, you can implement your own _Factory_ class.
|
||||
```yml
|
||||
SilverStripe\Core\Injector\Injector:
|
||||
SilverStripe\CMS\Controllers\CMSPageHistoryController:
|
||||
factory:
|
||||
App\MySite\MyCustomControllerFactory
|
||||
```
|
||||
|
||||
[Implementing a _Factory_ with the Injector](/developer_guides/extending/injector/#factories)
|
||||
|
Loading…
x
Reference in New Issue
Block a user