Download the PHP package punktde/archivist without Composer

On this page you can find all versions of the php package punktde/archivist. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package archivist

PunktDe.Archivist

Travis Build Status Latest Stable Version Total Downloads

Purpose of this package: Automatically sorts nodes into a predefined structure which is created on the fly.

Neos has some drawbacks, if you store lots of Node - like news for example - on the same hierarchical level. Especially the backend trees are getting slow and confusing. This package automatically sorts this nodes in a configured and automatically created hierarchy.

Configuration

You can configure the behavior differently for every triggering node type. The configuration options are best explained by example. These examples are taken from Configuration/Testing/Settings.yaml and are thus automatically tested.

Simple Example

Configuration for the nodeType 'PunktDe.Archivist.TriggerNode'. The sorting is triggered if a node of this type is created or if a property on this node is changed. This node is then available as 'node' in the other parts of the configuration

PunktDe: Archivist: sortingInstructions:

  'PunktDe.Archivist.TriggerNode':

    # The query selecting the root node of the automatically created hierarchy
    hierarchyRoot: "${q(site).find('[instanceof Neos.ContentRepository.Testing:Page]').get(0)}"

    # Optional: The sorting of the nodes inside the target hierarchy. Can be the name of a property
    # or an eel expression like seen below
    sorting: title

    # Optional: Trigger sorting only, when condition is met. Can be used to make sure that required properties are set as expected.
    condition: "${node.properties.date != null}"

    # In the context is evaluated first. You can define variables here which you can use in
    # the remaining configuration
    context:
      publishDate: "${node.properties.date}"

    # Automatically publish the created document hierarchy
    publishHierarchy: true

    # Definition of the auto-generated hierarchy
    hierarchy:
      -
        # The type of the hierarchy-node
        type: 'PunktDe.Archivist.HierarchyNode'

        # Properties of the new created node.
        properties:
          name: "${Date.year(publishDate)}"
          title: "${Date.year(publishDate)}"
          hiddenInIndex: "${true}"

        # The property which is identical throughout all nodes of this level
        identity: title

        # An eel query that describes the sorting condition
        sorting: "${q(a).property('title') < q(b).property('title')}"
      -
        type: 'PunktDe.Archivist.HierarchyNode'
        properties:
          name: "${Date.month(publishDate)}"
          title: "${Date.month(publishDate)}"
        identity: title

        # Simple sorting on a property
        sorting: title

Example with a triggering content node

A content node triggers the move of its parent document node. For example, if you have a title node which should be considered to move the page.

PunktDe:
  Archivist:
    sortingInstructions:
      'PunktDe.Archivist.TriggerContentNode':

        # The query selecting the root node of the automatically created hierarchy
        hierarchyRoot: "${q(site).find('[instanceof Neos.ContentRepository.Testing:Page]').get(0)}"

        # Optional: The node to be moved, described by an Eel query.
        # This defaults to the triggering node if not set. The triggering node is available as "node".
        # If the affected node is not found by the operation is skipped.
        # This can for example be used if a change in a content node should move its parent document node
        #
        affectedNode: "${q(node).parent('[instanceof Neos.ContentRepository.Testing:Document]').get(0)}"

        # Definition of the auto-generated hierarchy
        hierarchy:
          -
            # The type of the hierarchy-node
            type: 'PunktDe.Archivist.HierarchyNode'

            # Properties of the new created node.
            properties:
              name: "${Archivist.buildSortingCharacter(title)}"
              title: "${Archivist.buildSortingCharacter(title)}"

Define multiple configurations for the same NodeType

In addition to

you can now do this:

Make sure, to define a conditon to not run several configurations on the same Node action.

Archivist Eel Helper

Archivist.buildSortingCharacter(string, position = 0, length = 1) Generates upper case sorting characters from the given string. Starting position and length can be defined.


All versions of archivist with dependencies

PHP Build Version
Package Version
Requires php Version ^7.2 || ^8.0
neos/neos Version ^5.0 || ^7.0 || ^8.0 || dev-master
neos/neos-ui Version *
neos/neos-ui-compiled Version *
behat/transliterator Version *
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package punktde/archivist contains the following files

Loading the files please wait ....