File tree Expand file tree Collapse file tree
Classes/Flowpack/ElasticSearch/ContentRepositoryAdaptor/Command Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -30,15 +30,24 @@ class NodeTypeCommandController extends CommandController {
3030 protected $ nodeTypeManager ;
3131
3232 /**
33- * show a single node type after applying all supertypes etc
33+ * Show node type configuration after applying all supertypes etc
3434 *
3535 * @param string $nodeType the node type to optionally filter for
36+ * @return void
3637 */
3738 public function showCommand ($ nodeType = NULL ) {
38- $ configuration = $ this ->nodeTypeManager ->getFullConfiguration ();
3939
4040 if ($ nodeType !== NULL ) {
41- $ configuration = $ configuration [$ nodeType ];
41+ /** @var \TYPO3\TYPO3CR\Domain\Model\NodeType $nodeType */
42+ $ nodeType = $ this ->nodeTypeManager ->getNodeType ($ nodeType );
43+ $ configuration = $ nodeType ->getFullConfiguration ();
44+ } else {
45+ $ nodeTypes = $ this ->nodeTypeManager ->getNodeTypes ();
46+ $ configuration = array ();
47+ /** @var \TYPO3\TYPO3CR\Domain\Model\NodeType $nodeType */
48+ foreach ($ nodeTypes as $ nodeTypeName => $ nodeType ) {
49+ $ configuration [$ nodeTypeName ] = $ nodeType ->getFullConfiguration ();
50+ }
4251 }
4352 $ this ->output (\Symfony \Component \Yaml \Yaml::dump ($ configuration , 5 , 2 ));
4453 }
You can’t perform that action at this time.
0 commit comments