zen_Nucleus

The complete system, where every component finds its meaning.

  • Mantra: "From completeness, clarity. From clarity, power."
  • Tagline: The first and final verse of any application.

zen_Nucleus is much more than a component; it is a complete framework. Its purpose is to bind the ogToolsSuite and provide a full set of ORDA-based managers for lists, records, and essential development tools.

Think of it as an out-of-the-box database solution that lets you focus on business logic, not the underlying engine. With zen_Nucleus, development is streamlined into intuitive widget placement and tuning.

We were consistently surprised by its ease and power when migrating the Orwell and Sēmippān databases from 10-year-old classic versions to a full ORDA implementation in just a few straightforward steps.

Localised in EN, FR, ES. Dependencies:  wok_Krolific – Licensing, Simplifiedwox_Xlibrary – The Silent Enginewoc_Colours – Colours, Reloadedwaz_Wazar – UI, Unifiedwob_Boxes – The Universal Containerwor_Recursive – The Infinite, Tamedwos_SvgWidgets – Draw your verseswqr_QuickReport – A 4D legacy fork.

 

Overview

zen_Nucleus handles all core functionality for Lists, Records, and Relations. This includes managing relational joins between tables and providing widgets for both one-to-many and many-to-one relationships:

  • A record picker for selecting a single parent record (1←).
  • A sublist interface with Add, Modify, and Delete commands for managing child records (←N).

Indicate a widget from ogToolsSuite or zen_Nucleus.

 

Main menus

Access to your Root lists and other features is provided through multiple interfaces: the standard Menu bar, a comprehensive database menu, and an accordion-style menu.

A class within the Host, invoked by zen_Nucleus through a shared Formula, manages all of these menus.

zen_Nucleus uses the wox_Xlibrary windowing system to tile all open Lists and Records. The forms animate into place with a customizable curve (set in the preferences), ensuring your screen space is used efficiently.

 

Lists, Records, relations

Lists are highly extensible. They can be enhanced with extra buttons integrated from the Host and can even incorporate a Host subForm to function as a dynamic Business Filter. All associated assets, including buttons and icons, are also sourced from the Host.

Each record is automatically equipped with two specialized widgets:

  • The zen_meta widget manages the record's Unique ID (UID) and associated metadata.
  • The zen_record widget handles record navigation.

This system provides powerful automatic functionality, including detection of changes (record.touched()), and manages all related confirmation and save dialogs, ensuring data integrity.

The zen_sublist widget provides an intuitive interface for managing one-to-many (←N) relations. It automatically handles adding, modifying, deleting, and additional actions for child records. Configuration is simple: just declare the target Table, the name of the foreign key field, and the sort order field. It also provides full support for managing ordered sublists.

The record section features two zen_c4ES widgets, configured for many-to-one (1←) relationships. A click on either widget opens a  menu or a pop-up form including a zen_c4ESWidget —for selecting a single related record. By default, the widget intelligently displays a menu option when there are fewer than 50 records in the selection list, optimizing for user experience.

Multi-transpositions

With the beautiful Protée UI, you can seamlessly transpose data across multiple related tables in a single step—even through complex, multi-level relationships.

Example: Fetching all pictures for a product (Sēmippān)
This single operation navigates the entire relational path:
[PRODUCTS] ← [PATHS]UIDproduct → [PACKS] ← [BANKS]UIDpack ← [MEDIA]UIDbank → [PICTURES]

List builder

Every List and sublist is defined by a JSON configuration file. This system provides an extensive set of parameters and pre-built meta-formulas — powered by ogToolsSuite — allowing you to effortlessly create and customize any list to your exact specifications.

To get started:

  1. Create a List Class: For each table, simply create a new class for the list's form <TABLE>_LIST.

  2. Extend the Base Class: Have your new class extend the ZEN__TABLES_LIST foundation class.
    Class extends ZEN__TABLES_LIST

 

All in one

  • Dashboard and global parameters
  • Users & Groups
  • CLASS generics
    • ZEN__TABLES_LIST, ZEN__TABLES_SEARCH, ZEN__DELETE, ZEN__FORM_MOVE
    • ZEN__RECORD, ZEN__WIDGETS
  • LISTS 
    • use the builder for your lists and sublists, associated to tables & user profile, and views
    • A full user's interface ready for all the needs: navigation, selections, sets, search, filters, export, 4DWP mailing, etc
    • SearchBox, Selection, Sets manager, wob_Boxes integration, Transpositions by menu or circular relate© from tables to tables, List editor, Export list to 4DV, or Excel, Document manager (4DV), QuickReport, Generic Column’s search and filter
    • Open and create with list’s manager
      • Schemas, fields, Relation 1 niveau
      • Metaformulas, switch, popup, menuBtn, timestamp, utc, utc0...
      • Class <TABLE>_LIST for rich display
      • Extras {<TABLE>_EXTRAS}: add specific extra buttons for your business actions
      • Filters {<TABLE>_FILTERS} Class and Form: Host specific filters integration !
      • ZENH_DELETE to manage your records and relations deletion.

  • RECORDS
    • Navigation
      • First, Previous, Next, Last record
      • Read/Write, Close box, Modified manager with 3 states confirm « Don’t Save, Cancel, Save »
      • Ok, Cancel
    • Relate One
      • zen_c4ES
        • Option l_count, 
        • $vJ_widget.is_list:=True
        • $vJ_widget.t_view:="media"
        • Create list’s manager
    • Relate Many
      • zen_sublist
        • Create list’s manager
        • Ordered sublist
  • CLASS
    • <TABLE>_RECORD
    • ZENH_DELETE
  • CRONs
    • Define worker to launch at specific date & time, like 5 minutes, daily, specific days in the week, once a month...
    • Provided with a pane where you can launch, see the progress and even see when a launch occurs even in CS. 

 

DEV Tables

  • All optional
    • ZEN_TRANSLATIONS, ZEN_SCHEMAS & ZEN_SCHEMAS_R
    • ZEN_FORMS & ZEN_FIELDS, ZEN_ENDPOINTS & ZEN_ROUTE
ZEN_TRANSLATIONS

The system includes a powerful yet easy-to-use multi-language manager, supporting up to five languages. It features integrated XLIFF storage and export capabilities, streamlining the localization process for international projects.

ZEN_SCHEMAS & ZEN_SCHEMAS_R

The framework provides dedicated tables for managing the schemas of all your object fields. These schemas are automatically synchronized with the .json schema files exported to the rsc folder, facilitated by an integrated cache manager for optimal performance.

Furthermore, all schema properties utilize the wor_Recursive class, enabling a powerful hierarchical editing interface for every object field, which simplifies complex configuration tasks.

ZEN_FORMS & ZEN_FIELDS, ZEN_ENDPOINTS & ZEN_ROUTES

This robust architecture enables you to seamlessly generate and deploy all necessary components for a sophisticated Node.js web server, directly integrated with your 4D application.

PROD Tables

  • Mandatory
    • ZEN_DASHBOARD
    • ZEN_USERS, ZEN_USERS_SETTINGS, ZEN_GROUPS
    • ZEN_SETS, ZEN_REPORTS, ZEN_DOCUMENTS

  • Optionnal
    • ZEN_POPUPS, ZEN_POPUPS_LABELS
    • ZEN_COUNTRIES, ZEN_STATES, ZEN_COUNTIES, ZEN_AREA_CODES, ZEN_TIMEZONES

 

Widgets

  • zen_c4ES, zen_c4ES_form, zen_c4ESWidget
  • zen_sublist
  • zen_meta, zen_record
  • zen_relate
  • zen_country, zen_e164, zen_popup

 

zen_c4ES, zen_c4ESWidget

These widgets support both single and multiple selection modes, configurable via the is_multiple property. They can be bound to any foreign key, making them perfect for standalone use anywhere in your application.

The zen_c4ES widget includes an intelligent button with an automatically assigned table icon from Host. A click triggers a dynamic interface:

  • If the related table is below a configurable record threshold, a selection menu appears.
  • If the table exceeds the threshold, a dedicated zen_c4ESWidget in a form opens for more powerful, windowed selection.

This adaptive behavior ensures optimal performance and user experience, regardless of dataset size.

zen_sublist

The zen_sublist widget is a powerful interface for managing one-to-many (←N) relations. It provides built-in functionality to Add, Modify, and Delete records in the linked table effortlessly.

For most use cases, you can define the entire context in a single line of configuration. For more advanced needs, you retain full control: you can define custom selections, react to events like On Selection Change, and create sophisticated interactive UIs.

Example from Sēmippān:
In the SETS list, a click displays the related record in a section below, demonstrating this deep customization.

To configure a sublist, simply click the "more" button and select "Edit sublist." This opens the powerful List Builder interface, where you can attach custom classes to each sublist to implement advanced and tailored user interfaces.

zen_meta, zen_record

At Protée, we have established a foundational set of non-negotiable functionalities for all databases, ensuring consistency and robustness in handling Lists and Records.

Core Requirements for Record Management

For every Record, the system must provide the ability to:

  • Navigate Selection: Move seamlessly through records (First, Previous, Next, Last).
  • Manage State: Toggle between Read and Write modes via a dedicated button.
  • Track Changes:
    • Detect modifications using .touched() for both the main record and any sub-records.
    • Present a three-option dialog (Don't Save, Cancel, Save) upon navigation if changes are detected.
  • Validate Data:
    • Perform custom checks on fields for correct input.
    • Enforce errors (preventing save) or display warnings (which can be bypassed).
  • Control Transactions: Optionally enable or disable transactions at the individual table level.
  • Remember User Preferences: Memorize user-adjusted column widths and row heights for each table at the session level.

The Protée Solution: zen_meta & zen_record

To fulfill these requirements efficiently, we provide two integrated widgets:

  • zen_meta: A utility widget for every record that provides:
    • UID management (display and copy).
    • Access to field sizes and schema generation from object fields.
    • Visibility into audit trails: creation and last modification stamps (date, time, user).
  • zen_record: The primary navigation widget that handles all the core functionalities listed above, including navigation, state management, change tracking, and dialog triggers.

Leveraging these functionalities is straightforward thanks to an object-oriented approach.

To get started:

  1. Create a Record Class: For each table, simply create a new class for the record's form.

  2. Extend the Base Class: Have your new class extend the ZEN__RECORD foundation class.
    Class extends ZEN__RECORD

Customization and Overrides:

Within your <TABLE>_RECORD class, you have access to several inherited member methods. You can override these to inject your own custom business logic:

  • initialise(): Execute code each time a record is loaded.

  • Validation Methods: Check field values and cancel a save operation if criteria are not met.

  • ...and more: Add your own "glue" to tailor the record's behavior precisely to your application's needs.

The dialog when you close a record that has been modified: