Releases: wedevelopnl/silverstripe-menustructure
3.0.2
What's Changed
getLink
might returnnull
. by @erikfrerejean in #12
New Contributors
- @erikfrerejean made their first contribution in #12
Full Changelog: 3.0.1...3.0.2
4.0.1
4.0.0
What's Changed
- Update for SS5 compatibilty by @Dennisprins93 in #11
New Contributors
- @Dennisprins93 made their first contribution in #11
Full Changelog: 3.0.1...4.0.0
3.0.1
3.0.0
What's Changed
- feature/cascading-edited by @DRuiter in #9
- Added Dockerfile and docker-compose.yml by @robertvanlienden in #8
New Contributors
Full Changelog: v2.0.2...3.0.0
Add query string option
v2.0.2 Add query string option
Add link extension
v2.0.1 Fix cs and add link extend
v2.0.0
What's Changed
- Updated README and added docs and contributing guides by @robertvanlienden in #6
- Removed image from MenuItem by @robertvanlienden in #6
Because of fact that the image relation on the MenuItem model has been removed, we've decided to consider this release as a API change.
The reason we've decided to remove the image from an MenuItem is because we almost never use the image feature.
99% of the situations where we install this module , we've extended MenuItem to remove the image...
Since release 2.0.0 we do this the other way; A menu item doen not have a image, but of course you can extend a MenuItem model to add your own images.
Update from 1.* to 2.*
Situation; You remove the image by an extension on MenuItem
Please remove remove the code that removes the Image field from your MenuItemExtension.
For the rest; in this situation, you can safely update to 2.*.
Situation; You use the MenuItem image from 1.*
In this situation, you need to create a extension on MenuItem.
The following snippets is an simple example how to "restore" the Image property when upgrading to 2.*, you can use this as reference when upgrading;
app/src/Extensions/MenuItemExtension.php
<?php
namespace App\Extensions;
use SilverStripe\Assets\Image;
use SilverStripe\Forms\FieldList;
use SilverStripe\ORM\DataExtension;
class MenuItemExtension extends DataExtension
{
private static $has_one = [
'Image' => Image::class,
];
private static $owns = [
'Image',
];
public function updateCMSFields(FieldList $fields)
{
$fields->addFieldToTab('Root.Main', $fields->dataFieldByName('Image')->setFolderName('Menus')->setDescription('Optional image, can be used in some templates.'));
parent::updateCMSFields($fields);
}
}
mysite.yml
---
Name: mysite
---
TheWebmen\Menustructure\Model\MenuItem:
extensions:
- App\Extensions\MenuItemExtension
Full Changelog: 1.1.0...2.0.0
1.1.0
Feature to add page anchor