Download the PHP package tastyigniter/ti-ext-automation without Composer

On this page you can find all versions of the php package tastyigniter/ti-ext-automation. 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 ti-ext-automation

Build Status Total Downloads Latest Stable Version License

Introduction

The TastyIgniter Automation extension allows you to automate certain actions within your TastyIgniter application. These automations are triggered when specific events occur, such as a change in order state. Actions can include sending an email to a customer or sending print jobs to a printer when an order status.

Features

Installation

You can install the extension via composer using the following command:

Run the database migrations to create the required tables:

Automation workflow

The Automation extension follows a specific workflow when an automation is triggered:

  1. The extension registers associated actions, conditions, and events using the registerAutomationRules method.
  2. When a system event is triggered, the parameters of the event are captured, along with any global parameters.
  3. These captured parameters are then attached to a job and placed onto the queue for background processing.
  4. The job retrieves all automation rules that match the triggered system event and runs them.
  5. The automation conditions are checked to ensure that any required conditions are met.
  6. Finally, the automation actions associated with the triggered rules are executed using the captured parameters.

Usage

You can manage automations in the admin panel by navigating to Tools > Automations.

Defining events

An event class is responsible for preparing the parameters passed to the conditions and actions.

Automation Event classes are typically stored in the src/AutomationRules/Events directory of an extension. The Event class is a simple class that extends Igniter\Automation\Classes\BaseEvent and defines the eventDetails and makeParamsFromEvent methods.

Here is an example of an event class:

The eventDetails method returns information about the event, including the name and description. The makeParamsFromEvent method prepares the captured parameters passed to the conditions and actions.

These are the available options for the eventDetails method:

Defining actions

A action class defines the final step in an automation and performs the automation.

Action classes are typically stored in the src/AutomationRules/Actions directory of an extension. The Action class is a simple class that extends Igniter\Automation\Classes\BaseAction and defines the actionDetails, defineFormFields, and triggerAction methods.

The actionDetails method returns information about the action, including the name and description. The defineFormFields method defines the form fields required for the action, see TastyIgniter's available form field types. You can access fields defined in the defineFormFields method using $this->model->field_name. The triggerAction method performs the automation action.

These are the available options for the actionDetails method:

Defining conditions

A condition class is used to check whether a condition is true or false.

Automation condition classes are typically stored in the extensions's src/AutomationRules/Conditions directory. The Condition class is a simple class that extends Igniter\Automation\Classes\BaseCondition and defines the conditionDetails and isTrue methods.

The conditionDetails method returns information about the condition, including the name and description. The isTrue method checks whether the condition is true for the specified parameters.

These are the available options for the conditionDetails method:

Defining model attribute conditions

Just like the condition class above, a model attribute condition class applies conditions to sets of model attributes.

Automation model attribute condition classes are typically stored in the extensions's src/AutomationRules/Conditions directory. The model attribute condition class is a simple class that extends Igniter\Automation\Classes\BaseCondition and defines the conditionDetails, defineModelAttributes, and isTrue methods.

The defineModelAttributes method defines the model attributes and labels required for the condition.

Registering automation events, actions, and conditions

After creating the condition classes, you can make them available in the admin panel by registering them in the registerAutomationRules method of the extension class.

The registerAutomationRules method should return an array with the following keys:

Registering global parameters

Global parameters are available to all automation rules. You can register global parameters in the boot method of the extension class.

Permissions

The Automation extension registers the following permissions:

For more on restricting access to the admin area, see the TastyIgniter Permissions documentation.

Changelog

Please see CHANGELOG for more information on what has changed recently.

Reporting issues

If you find a bug in this extension, please report it using the Issue Tracker on GitHub.

Contributing

Contributions are welcome! Please read TastyIgniter's contributing guide.

Security vulnerabilities

For reporting security vulnerabilities, please see our our security policy.

License

TastyIgniter Automation extension is open-source software licensed under the MIT license.


All versions of ti-ext-automation with dependencies

PHP Build Version
Package Version
Requires tastyigniter/core Version ^4.0
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 tastyigniter/ti-ext-automation contains the following files

Loading the files please wait ....