Three views of one model

A model page shows the same record type as each part of the platform sees it, and the lists differ. Pick a view with the switcher at the top of the page; your choice is remembered on every model page.

  • Templates: what Smarty and Twig templates receive. On a page template, $page is a Page, and its members are what you call in the template.
  • API & Jobs: the properties of the record in REST API responses and in job payloads, which are built from the same models. A property is a getter without its get, is or has prefix, so getName() becomes name. Methods that need arguments are not available.
  • Admin: what cdna-admin templates receive, for when you override an admin screen in your site repository.

A tag beside a member marks a real difference between the views, such as API & Jobs only or Not in Admin.

Reading a member

Each row gives the member's name and arguments, the type it returns and its description. When the type is another model, it links to that model's page. A question mark before a type, as in ?Layout, means the value can be empty (null). Collection<PageArea> is a collection of PageArea records: loop over it, count it, sort it and filter it.

Finding a model

Every model belongs to a module, such as Pages, Products or Users. On any model page the navigation lists every module with its models, and the filter at its top narrows the list as you type (press / to jump to it). The groups below are good places to start.