PHPackages                             redcode/flow-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. redcode/flow-bundle

ActiveSymfony-bundle[Utility &amp; Helpers](/categories/utility)

redcode/flow-bundle
===================

Symfony2 flow manager, process entities by flows (status)

0.1.x-dev(12y ago)06MITPHPPHP &gt;=5.4.0

Since Dec 17Pushed 12y ago1 watchersCompare

[ Source](https://github.com/maZahaca/redcode-flow-bundle)[ Packagist](https://packagist.org/packages/redcode/flow-bundle)[ Docs](https://github.com/maZahaca/redcode-flow)[ RSS](/packages/redcode-flow-bundle/feed)WikiDiscussions 0.1 Synced 2mo ago

READMEChangelogDependencies (2)Versions (1)Used By (0)

Using transit between statuses with redcode-flow bundle
=======================================================

[](#using-transit-between-statuses-with-redcode-flow-bundle)

**Steps to start**

- Mark with annotation status field or status entity. Example:

```
use RedCode\Flow\Annotation\Status as Flow;
/**
 * @ORM\Entity
 */
class Order
{
     /**
     * @var OrderStatus
     * @Flow\StatusEntity
     * @ORM\ManyToOne(targetEntity="OrderStatus", cascade={"persist"})
     * @ORM\JoinColumn(name="status_id")
     */
    private $status;
}

use RedCode\Flow\Annotation\Status as Flow;
/**
 * @ORM\Entity
 */
class OrderStatus
{
     /**
     * @var int
     * @Flow\StatusValue
     * @ORM\Column(type="integer")
     */
    private $status;
}
```

- Create your manager and extend it from FlowManager

```
use RedCode\Flow\FlowManager;
use RedCode\Flow\Annotation\Reader;

class OrderManager extends FlowManager
{
    public function __construct(SecurityContext $securityContext, EntityManager $em, Reader $reader, array $flows = array ())
    {
        parent::__construct(
            $securityContext,
            $em,
            $reader,
            'Order', // class name
            $flows
        );
    }
}
```

- Create your own flows between statuses

```
use RedCode\Flow\Item\BaseFlow;

class SomeFlow extends BaseFlow
{
    public function __construct()
    {
        // set allowed user roles or set false to switch off option
        $this->roles = [
            'ROLE_ADMIN'
        ];

        // set allowed movements between statuses
        $this->movements = [
            new FlowMovement(1, 2),
            new FlowMovement(null, 2),
        ];
    }

    /**
     * @inheritDoc
     */
    public function execute($entity, FlowMovement $movement)
    {
        // some actions when transit comes
        return $entity;
    }
}
```

- Define service in xml or yaml file

```

```

- Use service in your code

```
/**
 * Modify order or it status and save using method execute
 */
$container->get('order.manager')->execute($order);
```

###  Health Score

20

—

LowBetter than 14% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity42

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

Unknown

Total

1

Last Release

4532d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/141e58f9f8c19ad2f259d706caade38f44873f47260e09ae03c2cc1effa32bed?d=identicon)[maZahaca](/maintainers/maZahaca)

---

Top Contributors

[![maZahaca](https://avatars.githubusercontent.com/u/1290067?v=4)](https://github.com/maZahaca "maZahaca (2 commits)")

---

Tags

symfonybundlestatusflowtransit

### Embed Badge

![Health badge](/badges/redcode-flow-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/redcode-flow-bundle/health.svg)](https://phpackages.com/packages/redcode-flow-bundle)
```

###  Alternatives

[winzou/state-machine-bundle

Bundle for the very lightweight yet powerful PHP state machine

34010.4M15](/packages/winzou-state-machine-bundle)[pentatrion/vite-bundle

Vite integration for your Symfony app

2725.3M13](/packages/pentatrion-vite-bundle)[gomachan46/state-machine

simple state machine with annotations for PHP, inspired by AASM known as a Ruby state machine.

1893.9k](/packages/gomachan46-state-machine)[ekreative/uuid-extra-bundle

Paramconverter, Normalizer and Form Type for Ramsey Uuid

18168.6k](/packages/ekreative-uuid-extra-bundle)[fsi/datagrid-bundle

FSi Datagrid Bundle

1859.8k1](/packages/fsi-datagrid-bundle)[glooby/task-bundle

Scheduling of tasks for symfony made simple

3216.3k](/packages/glooby-task-bundle)

PHPackages © 2026

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