PHPackages                             basilicom/path-formatter-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. basilicom/path-formatter-bundle

Abandoned → [basilicom/pimcore-path-formatter-bundle](/?search=basilicom%2Fpimcore-path-formatter-bundle)Pimcore-bundle[Utility &amp; Helpers](/categories/utility)

basilicom/path-formatter-bundle
===============================

This bundle provides path formatter pattern configuration for Pimcore DataObjects in multi-relation.

v3.1.0(1mo ago)381GPL-3.0-or-laterPHPPHP &gt;=8.1CI failing

Since Aug 5Pushed 1mo ago6 watchersCompare

[ Source](https://github.com/basilicom/pimcore-path-formatter-bundle)[ Packagist](https://packagist.org/packages/basilicom/path-formatter-bundle)[ Docs](https://basilicom.de)[ RSS](/packages/basilicom-path-formatter-bundle/feed)WikiDiscussions master Synced 1w ago

READMEChangelog (9)Dependencies (7)Versions (23)Used By (0)

Basilicom Extended Path Formatter Bundle for Pimcore
====================================================

[](#basilicom-extended-path-formatter-bundle-for-pimcore)

Usecase / Summary
-----------------

[](#usecase--summary)

If you want to display specific information of a DataObject when it's listed in a relation-field (Many-to-Many, Many-to-One, Advanced Many-to-Many, etc.), you can use this bundle to easily configure a display pattern.

Instead of creating a new PathFormatter PHP class for every specific display requirement (e.g., showing the name, price, and currency of a product), you can simply define patterns in your configuration.

```
# config/packages/basilicom_path_formatter.yaml
basilicom_path_formatter:
  pattern:
    Pimcore\Model\DataObject\Product: "{name} {price}{currency}"
```

You can also define specific pattern overwrites for a class when it is referenced in a specific field of another class:

```
# config/packages/basilicom_path_formatter.yaml
basilicom_path_formatter:
  pattern:
    Pimcore\Model\DataObject\Product: "{name} {price}{currency}" # global product format
    Pimcore\Model\DataObject\ProductList::products:
       patternOverwrites:
          Pimcore\Model\DataObject\Product: "#{id} {name}"
```

While the product will be formatted like `Sneakers 19.99EUR` in most relation-fields, the `products` field in the `ProductList` class will show them like `#13 Sneakers`.

---

Version information
-------------------

[](#version-information)

Bundle VersionPHPPimcore^1.0^7.3^6.0^2.0^8.0^10.0^3.0^8.1^11.0Installation
------------

[](#installation)

1. Install the bundle using composer:

    ```
    composer require basilicom/pimcore-path-formatter-bundle
    ```
2. Enable the bundle:

    - **Pimcore &gt;= 10:** The bundle should be automatically registered. If not, add it to `config/bundles.php`.
    - **Pimcore &lt; 10:** Add the following to `AppKernel::registerBundlesToCollection()`: ```
        if (class_exists('\\Basilicom\\PathFormatterBundle\\BasilicomPathFormatterBundle')) {
              $collection->addBundle(new \Basilicom\PathFormatterBundle\BasilicomPathFormatterBundle);
        }
        ```

Configuration
-------------

[](#configuration)

1. Create a configuration file (e.g., `config/packages/basilicom_path_formatter.yaml`).
2. Configure your patterns using the full qualified class names as keys.

### Basic Configuration

[](#basic-configuration)

Use curly brackets `{}` to reference class properties. Any property accessible via a public getter (e.g., `{name}` calls `getName()`) can be used.

```
basilicom_path_formatter:
  pattern:
    # Output example: "Product: Sneakers (/dataObject/Products/Sneakers)"
    Pimcore\Model\DataObject\Product: "Product: {name} ({fullPath})"
```

### Nested Properties

[](#nested-properties)

The bundle supports nested property access using dot notation. For example, if a Product has a Category, and you want to show the category name:

```
basilicom_path_formatter:
  pattern:
    Pimcore\Model\DataObject\Product: "{name} (Category: {category.name})"
```

*Note: This will call `$product->getCategory()->getName()`.*

### Contextual Pattern Overwrites

[](#contextual-pattern-overwrites)

You can override patterns based on the context (the parent object and the specific field).

```
basilicom_path_formatter:
  pattern:
    # Global default
    Pimcore\Model\DataObject\Product: "{name}"

    # Overwrite when a Product is shown in the 'featuredProducts' field of a Category object
    Pimcore\Model\DataObject\Category::featuredProducts:
      patternOverwrites:
        Pimcore\Model\DataObject\Product: "FEATURED: {name} ({price})"
```

### Formatting Documents and Assets

[](#formatting-documents-and-assets)

The formatter is not limited to DataObjects; it also works for Assets and Documents.

```
basilicom_path_formatter:
  pattern:
    Pimcore\Model\Asset: "{id} {filename}"
    Pimcore\Model\Document: "{id} {key}"
```

Additional Features
-------------------

[](#additional-features)

### Inheritance in DataObjects

[](#inheritance-in-dataobjects)

By default, inherited values are used when resolving placeholders. You can disable this globally:

```
basilicom_path_formatter:
  enable_inheritance: false # default: true
```

### Asset Previews

[](#asset-previews)

If a referenced property resolves to a `Pimcore\Model\Asset\Image`, the bundle automatically renders a small preview thumbnail in the relation list.

```
basilicom_path_formatter:
  enable_asset_preview: true # default: true
  pattern:
    Pimcore\Model\DataObject\Product: "{mainImage} {name}"
```

If the target element itself is an `Asset\Image`, a preview is also prepended to the pattern.

Usage in Pimcore Admin
----------------------

[](#usage-in-pimcore-admin)

To apply the formatter to a field:

1. Open your **Class Definition**.
2. Select a relation field (e.g., Many-to-Many Relation).
3. In the **Formatter** input field, enter the service ID: `@Basilicom\PathFormatterBundle\DependencyInjection\BasilicomPathFormatter`

---

**Author:** Alexander Heidrich (Basilicom GmbH)
**License:** GPL v3

###  Health Score

49

—

FairBetter than 95% of packages

Maintenance90

Actively maintained with recent releases

Popularity9

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity73

Established project with proven stability

 Bus Factor1

Top contributor holds 98% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~103 days

Recently: every ~155 days

Total

21

Last Release

53d ago

Major Versions

v0.1.1 → v1.0.02020-08-06

v1.2.1 → v2.0.02021-11-24

v2.1.0 → v3.0.02024-07-12

v1.3.0 → v2.x-dev2024-07-12

v2.2.0 → v3.0.22026-03-18

PHP version history (3 changes)v0.1PHP &gt;=7.3

v2.1.0PHP &gt;=8.0

v3.0.0PHP &gt;=8.1

### Community

Maintainers

![](https://www.gravatar.com/avatar/5c0d06c93d4cfac61be4239ec123ca75a189a5275d4e1782755d85029e67b6bc?d=identicon)[christophluehr](/maintainers/christophluehr)

![](https://www.gravatar.com/avatar/a5082ec20fca835c8a833af5de2647529bad59c9423fbc58cc5625c9fbff230c?d=identicon)[IgorBenko](/maintainers/IgorBenko)

![](https://www.gravatar.com/avatar/afb6145ee5c0c6af7662a537e76ee9c679d30e7e6217636d72576ea5ccd8b002?d=identicon)[AlexanderHeidrich](/maintainers/AlexanderHeidrich)

![](https://www.gravatar.com/avatar/66044563147e9ced476ac0107e7142f6f97c7362d143800c115401b0eebe102e?d=identicon)[mixahead](/maintainers/mixahead)

---

Top Contributors

[![AlexanderHeidrich](https://avatars.githubusercontent.com/u/9350895?v=4)](https://github.com/AlexanderHeidrich "AlexanderHeidrich (49 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (1 commits)")

---

Tags

pimcorepath formatterpathformatter

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/basilicom-path-formatter-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/basilicom-path-formatter-bundle/health.svg)](https://phpackages.com/packages/basilicom-path-formatter-bundle)
```

###  Alternatives

[dachcom-digital/formbuilder

Pimcore FormBuilder - create forms easily!

96269.7k](/packages/dachcom-digital-formbuilder)[instride/data-definitions

Data Definitions allows you to define your DataObject Imports and Exports using a nice GUI and re-run the definitions as often you like.

8117.7k](/packages/instride-data-definitions)[dpfaffenbauer/process-manager

Process Manager helps you to see statuses for long running Processes

3289.3k2](/packages/dpfaffenbauer-process-manager)[youwe/workflow-gui

Workflow Configuration UI for Pimcore

2884.6k](/packages/youwe-workflow-gui)[dachcom-digital/schema

Pimcore Schema

1075.7k](/packages/dachcom-digital-schema)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
