lala/recursivechildnodes

此包已被弃用且不再维护。作者建议使用netlogix/recursivechildnodes包。

Neos 包,用于在节点创建时递归生成 childNodes

安装: 201

依赖: 0

建议者: 0

安全性: 0

星标: 0

关注者: 10

分支: 0

开放问题: 0

类型:neos-package

1.2.0 2021-03-24 16:34 UTC

This package is auto-updated.

Last update: 2023-03-20 10:35:59 UTC


README

此包已不再维护。请使用Flowpack.NodeTemplates代替。

Netlogix.RecursiveChildNodes

此包的目的是简化创建具有多个 childNodes 但至少需要一个的新节点类型。一个很好的例子可能是一个事件节点类型,它可以通过内容集合有多个日期。

为了在创建新事件时自动在 dates 内容集合中创建 child nodes,可以使用以下配置

'Netlogix.NodeTypes:Event':
  superTypes:
    'Neos.Neos:Document': true

  options:
    recursiveChildNodes: # Recursive child nodes can be configured here
      dates: # Name of the first childNode
        -
          type: 'Netlogix.NodeTypes:EventDate'
          options:
            recursiveChildNodes: # Infinite recursion, yay!
              items:
                -
                  type: 'Netlogix.NodeTypes:SomeOtherNodeType'

  ui:
    label: 'Event'
    group: 'general'
    icon: 'icon-calendar'

  childNodes:
    dates:
      type: 'Neos.Neos:ContentCollection'
      constraints:
        '*': false
        'Netlogix.NodeTypes:EventDate': true

    main:
      constraints:
        nodeTypes:
          '*': true