Table

Your project contains tables.

A table in the builder does not represent only the SQL structure.
Here in builder, a table represent a triad.

Joomla tables



Cook self service Builder tablesTables

The list tables of your selected project.



Create a new table

1. Click the [ + ] button, then New table.

Cook create new table

2. Give a plural name. (Accept all characters ad spaces)

Cook Builder create table edit name

3, Press Enter a click the save icon.

Naming

Cook Builder Table properties

A table (triad) is made of 2 types: plural, singular

  • Table title : Table default label. Accept all caracters and spaces (ex: Items)
  • Table alias : File name and MVC plural class name. Only [a-z] caracters. Must be unique. (ex: items)
  • Item title : Default label for singular record. Accept all caracters and spaces (ex: Item)
  • Item alias : File name and MVC class name. Only [a-z] caracters. Must be different than Table alias. (ex: item)

Forbidden names

Some aliases are not allowed for your table alias. Cook does not accept the following names :

model, dev, fork, result, print, xxxx, xxxxs, yyyy, yyyys, zzzz, zzzzs

Entry point :

Determines if this triad is the default view.

Note: Deprecated feature since CPanel.



Cook Builder Fields types

Fields

Create a new field in table:

  1. From the Data types tab, drag a field type to the Data fields droppable list.
  2. Give a name, and an alias.

Cook add new field edit field

Warning : Some aliases are not allowed.

 (complete list to come)

 

Known issue : sometimes you can experience some difficulties to edit in the builder interface.
Workaroun: Save and edit again the field.

 

Default field

The default field is the field to choose as fallback when label key is not specified. It should be setted for a text readable field. (when possible)
For example, the modal pickers are using the default field to show the item label (or title, description, ...)

To define a field as default, click on the star : Cook default field in SQL table

Create a Foreign Key:

  1. Instance a Foreign Key field type.
  2. Name the field (Label + name)
  3. Drag the foreign Table in the droppable area of the instancied field.

ex : Country table is referenced in the country field of the Cities table

Create Foreign Key in your SQL table



WizardsCook Self Service wizards

Wizards are automated functionalities. Cook can instance basic Joomla features such as authoring infos, publishing states, creation infos, holder (checked_in), ordering, accesses, aliasing (slug), hits, defaulting, ...

Instance a new wizard:

  1. From the Wizards tab, drag the wizard you want to create.
  2. Link the fields to work with. To do it automatically, click to the green (+) button.

Create a new wizard

Once the fields are correctly linked to a wizard, an orange arrow is displayed on the top-left corner of the field:

Cook linked field to wizard

Warning : Some wizards can be instancied only once time per table. Some others can be instancied both times.

Warning : Some wizards lock the name of the field. In this case, you cannot change the name of the field.

Field name locked by a wizard



Generated files

For each table, your component will contain :

  • Database
    • Table declaration
  • back-end
    • Table class
    • Controllers
      • plural controller
      • singular controler
    • Models
      • plural model
      • singular model
      • XML JForms file
    • Views (when needed)
  • front-end

    • Controllers
      • plural controller
      • singular controler
    • Models
      • plural model
      • singular model
    • Views (when needed)

 

Get Started