承接 processmaker/nayra 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

processmaker/nayra

最新稳定版本:1.12.4

Composer 安装命令:

composer require processmaker/nayra

包简介

BPMN compliant engine

README 文档

README

ProcessMaker Nayra is a package that provides base classes to implement a process execution engine. This includes patterns to implement activities, events and gateways.

How to execute a process

Load a BPMN definition

 $bpmnRepository = new BpmnDocument(); $bpmnRepository->setEngine($this->engine); $bpmnRepository->setFactory($this->repository); $bpmnRepository->load('files/ParallelGateway.bpmn'); 

ParallelGateway diagram

Get a reference to the process

 $process = $bpmnRepository->getProcess('ParallelGateway'); 

Create a data storage

 $dataStore = $this->repository->createDataStore(); 

Create a process instance

 $instance = $this->engine->createExecutionInstance($process, $dataStore); 

Trigger the start event

 $start = $bpmnRepository->getStartEvent('StartEvent'); $start->start($instance); 

Start Event

Execute tokens and run to the next state

 $this->engine->runToNextState(); 

One token arrives to the first task

 $firstTask = $bpmnRepository->getScriptTask('start'); $token = $firstTask->getTokens($instance)->item(0); 

First task

Complete the first task

 $startActivity->complete($token); 

Execute tokens and run to the next state

 $this->engine->runToNextState(); 

One token arrives to the second task and one to the third task

 $secondTask = $bpmnRepository->getScriptTask('ScriptTask_1'); $token1 = $secondTask->getTokens($instance)->item(0); $thirdTask = $bpmnRepository->getScriptTask('ScriptTask_2'); $token2 = $thirdTask->getTokens($instance)->item(0); 

Second task and third task

License

ProcessMaker Nayra is open-sourced software licensed under the Apache 2.0 license.

统计信息

  • 总下载量: 90.16k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 136
  • 点击次数: 2
  • 依赖项目数: 3
  • 推荐数: 0

GitHub 信息

  • Stars: 134
  • Watchers: 29
  • Forks: 38
  • 开发语言: PHP

其他信息

  • 授权协议: Apache-2.0
  • 更新时间: 2026-01-04

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固