PHPackages                             jeyroik/extas-repositories-fields - 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. jeyroik/extas-repositories-fields

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

jeyroik/extas-repositories-fields
=================================

Package for fields adaptors creating

0.1.1(6y ago)02.4k5PHPCI failing

Since Apr 9Pushed 6y ago1 watchersCompare

[ Source](https://github.com/jeyroik/extas-repositories-fields)[ Packagist](https://packagist.org/packages/jeyroik/extas-repositories-fields)[ RSS](/packages/jeyroik-extas-repositories-fields/feed)WikiDiscussions master Synced yesterday

READMEChangelog (2)Dependencies (4)Versions (3)Used By (5)

[![tests](https://github.com/jeyroik/extas-repositories-fields/workflows/PHP%20Composer/badge.svg?branch=master&event=push)](https://github.com/jeyroik/extas-repositories-fields/workflows/PHP%20Composer/badge.svg?branch=master&event=push)[![codecov.io](https://camo.githubusercontent.com/e1496b19eafc1bb88f0d9b19702baaeb2ad9f55c995361d67936b443cc2f9078/68747470733a2f2f636f6465636f762e696f2f67682f6a6579726f696b2f65787461732d7265706f7369746f726965732d6669656c64732f636f7665726167652e7376673f6272616e63683d6d6173746572)](https://camo.githubusercontent.com/e1496b19eafc1bb88f0d9b19702baaeb2ad9f55c995361d67936b443cc2f9078/68747470733a2f2f636f6465636f762e696f2f67682f6a6579726f696b2f65787461732d7265706f7369746f726965732d6669656c64732f636f7665726167652e7376673f6272616e63683d6d6173746572)

Описание
========

[](#описание)

Пакет для создания адапторов полей для Extas.

С помощью адапторов полей можно создавать обработчики, которые будут заменять или обогащать значения полей при создании/обновлении extas-совместимых сущностей.

Использование
=============

[](#использование)

1. Создать плагин.
2. В плагине реализовать адапторы.

```
class MyAdaptorPlugin extends \extas\components\repositories\FieldAdaptorPlugin
{
    protected function getMarkers()
    {
        return [
            new class () extends \extas\components\repositories\FieldAdaptor {
                public function isApplicable(string $value): bool
                {
                    // Проверяем подходит ли значение поля для адаптации.
                    return $value == 'my';
                }

                public function apply(string $value)
                {
                    return 'world';
                }
            }
        ];
    }
}
```

3. Подключить плагин к интересуемой стадии.

В `extas.json`:

```
{
    "plugins": [
        {
            "class": "MyAdaptorPlugin",
            "stage": "extas..create.before"
        }
    ]
}
```

В качестве примера можно посмотреть:

- [extas-repositories-fields-sha1](https://github.com/jeyroik/extas-repositories-fields-sha1) позволяет автоматически шифровать значение с помощью sha1.
- [extas-repositories-fields-uuid](https://github.com/jeyroik/extas-repositories-fields-uuid) позволяет генерировать uuid-строки для значения полей.

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity18

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity47

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% 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 ~0 days

Total

2

Last Release

2224d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/2aaec5c4bade6ab2b5d1a0f7d97ab4e0ff2ce83937f76499b2888ad16cde5e04?d=identicon)[jeyroik](/maintainers/jeyroik)

---

Top Contributors

[![jeyroik](https://avatars.githubusercontent.com/u/6348124?v=4)](https://github.com/jeyroik "jeyroik (7 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/jeyroik-extas-repositories-fields/health.svg)

```
[![Health](https://phpackages.com/badges/jeyroik-extas-repositories-fields/health.svg)](https://phpackages.com/packages/jeyroik-extas-repositories-fields)
```

PHPackages © 2026

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