-
-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'origin/1.3'
- Loading branch information
Showing
8 changed files
with
60 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
<?php | ||
namespace Neos\Form\Builder\NodeType; | ||
|
||
use Neos\ContentRepository\Domain\Model\NodeType; | ||
use Neos\ContentRepository\NodeTypePostprocessor\NodeTypePostprocessorInterface; | ||
use Neos\Flow\Annotations as Flow; | ||
|
||
/** | ||
* Node Type post processor that populates the "resourceCollection" property with all configured resource collections | ||
*/ | ||
class ResourceCollectionsPostprocessor implements NodeTypePostprocessorInterface | ||
{ | ||
|
||
/** | ||
* @Flow\InjectConfiguration(package="Neos.Flow", path="resource.collections") | ||
* @var array | ||
*/ | ||
protected $resourceCollectionSettings; | ||
|
||
public function process(NodeType $nodeType, array &$configuration, array $options) | ||
{ | ||
$resourceCollectionOptions = []; | ||
foreach ($this->resourceCollectionSettings as $collectionName => $_) { | ||
$resourceCollectionOptions[] = [ | ||
'value' => $collectionName, | ||
'label' => $collectionName, | ||
]; | ||
} | ||
$configuration['properties']['resourceCollection']['ui']['inspector']['editorOptions']['values'] = $resourceCollectionOptions; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters