Experimental project

This is a sandbox project, which contains experimental code for developer use only.

This module creates a simple WYSIWYG-style interface for all aspects of building, designing and developing the logic behind very complex forms.

Submodules:

Classy Logic

- A sandboxed simplified JavaScript/CoffeeScript-like scripting language that allows you to define triggers and effects (such as hiding/revealing, disabling, validating) via a standard programming language, as snippets that are attached to fields. This language can access form values and the values of other entities referenced by the edited entity as simple variables. No evals are used.

Array comparisons, selection counts, sums of keys are all possible with real-time client-side validation. The same validation engine and rules are also run by the server to confirm validation and provide non-JS fallback.

This module is intended to solve the problem of performant real-time validations and complex dynamic forms as they might apply to business application processes. As such, IE7 support and user experience are important to us.

For example:

Attached to: field_colors_selected
Condition: (field_colors_selected >= 8)
Action: validateError
Message: "You must select at least 8 colors on this form."

Attached to: field_colors_selected
Condition: (field_colors_selected = 'purple' AND field_colors_selected = 'green')
Action: validateError
Message: "You may not select both green and purple."

Attached to: field_colors_selected
Condition: (field_colors_selected = 'purple' OR field_colors_selected = 'green') AND field_colors_selected < 3
Action: validateError
Message: "If you select less than 3 colors, you may not use purple or green."

Attached to: field_colors_selected
Condition: (field_colors_selected < field_group_ref.field_colors_minimum) AND user.role != "Designer")
Action: validateError
Message: "Unless you are a designer, this group requires at least [field_group_ref.field_colors_minimum] to be selected."

This module has been optimized for high-performance logic with scenarios using 1500 triggers, 500+ fields and dozens of field groups in various formats on single-node forms under IE7.

Classy Fields

Classy Fields provides a WYSIWYG, drag-and-drop, interactive real-time interface for creating forms directly from the node/edit form page itself. You can add new fields, adjust the positioning (weight) of fields and adjust the layout of the fields in a very consistent manner. You can create multi-column, tabbed, guided forms with real-time client-side and consistent server-side validation and display rules.

You can also attach Classy Logic triggers using the WYSIWYG interface.

Classy Business Rules

Adds a CSV and Excel-compatible importer/exporter of Classy Logic fields, with all fields, events, messaging and logic represented in a review-friendly format. This document is meant to be reviewed with a client, edited, and re-imported to ensure that all fields are configured precisely as the client approved.

This module suite is supported by Carr Systems and Third Sector Labs as a way to make Drupal more accessible to non-developers building complex business applications.

Project information