Updated pdexter 2022-10-22
What is a Ruleset
A ruleset is a block of script that interacts with the Formbird application in response to certain events.
The structure of a ruleset is basically a collection of "rules", which act as a "rules engine". Our system takes some concepts from Rules Engine theory, however this concept in total is quite challenging.
The purpose of rulesets are to :
implement business rules against a document, and to a lesser extent, system rules
automate the modification of data, based on existing data
schedule actions that need to happen at a future date-time
generate further documents that may be required as a result of business rules
Rulesets are currently divided into server-side, and client-side processing, on the following events:
PreSaveServer Occurs before a document is saved; (Changes made to the document are reflected on the screen, if saved from screen)
PostSave Occurs after the document has saved.
Scheduled Occurs at a predefined time.
PreRender Occurs before the document loads.
OnLoad Occurs after the document is loaded
OnFieldChange Occurs after any field is changed (including keystrokes in text)
PreSave (Client) Occurs after the user clicks Save, but before the actual saving
PostSave (Client) Occurs after a save has completed.
Both Server and Client side rulesets are stored in and run from their own documents.
As of Formbird v1.1.197, rulesets can and should be linked to from the template. The ruleset links are specified in the template, rather than the template links being specified in the ruleset.
Multiple rulesets can now be specified for a single event on a template.