Skip to content
tmaiaroto edited this page Sep 14, 2010 · 3 revisions

The Node Schema plugin will allow you to extend the fields that are on node add/edit forms (and then the data sent to the view) by applying (or associating) new tables to the nodes by type.

All new Node Schema tables must fall into CakePHP convention (pluralized, underscored table names) because they will become loaded models. This means that they will take advantage of all sorts of the caching features CakePHP has to offer.

Currently the Node Schema plugin does not have a way for you to build tables through your browser. A “schema builder” feature is in the plans but doesn’t exist yet. So you will need to first create a table in your database by other means. Then when adding a new Node Schema, you will enter that table name in.

The datasource assumed is “default” but that also will change in the future. You will be able to apply extended data to nodes from tables in different datasources. Meaning different parts of the data that form your nodes (pages, blog posts, etc. whatever the type names may be) can come from different databases and/or servers all without doing anything different that you’d normally do in order to get that working with CakePHP.

The idea here with this plugin is flexibility and scalability. I want to have options while at the same time adapting to CakePHP convention.
When the plugin installs itself, it will generate the tables it needs using Cake’s Schema class. In other words, the plugin is database agnostic.

With that in mind…The Node Schema plugin also allows for easy transport of schemas. You can export and import Node Schema tables with the plugin and they are also database agnostic using Cake’s Schema class.

Clone this wiki locally