Discussing ProcessWire CMS Infrastructure And Configurations

ProFields: Page Table

Technical Issue Menu

The ProFields: Page Table field can be used for a variety of needs. The Page Table Fieldtype and Inputfield are located in the Core Modules tab and they are part of any standard ProcessWire installation. This Page Table Fieldtype must be installed, as it is not activated as part of the default ProcessWire installation. The Page Table Fieldtype will automatically install the Page Table Inputfield.

It must be stressed that this module is provided at no cost, it's free and part of the ProcessWire Core.

What we will show here is one implementation of this field on a website.

Status Updates Field

On every website that I develop, each content page has a special field that is added to templates. It's called "Status Updates". Status Updates makes use of the ProFields: Page Table field. It's a convenient place where the Web Developer or the Website Owner can make historical notes about each website page. This has been very helpful in documenting changes made to individual pages. On this example website, the ProFields: Page Table field is actually called "CRMS Status Updates".

CRMS Status Updates Template

To use this ProFields: Page Table field for the Status Updates, we need to first define a template that uses the fields that will make up the ProFields: Page Table field. I normally name the template the same as the ProFields: Page Table field, in this example "CRMS Status Updates".

CRMS Status Update Template - Basic Tab

I have 3 fields defined within this template:

  • title: The basic ProcessWire title field. Important Note: This field will be defined as hidden within this template.
  • crms_date_start: This is a datetime field. It will be called "Start Date". The field has been defined with a date and no time.
  • body: This is the standard TextArea field. It will be called "Comments". Important Note: The InputField Type for the body field on this website has been changed to CKEditor from TextArea.

The following screenshot shows what the "CRMS Status Updates" Template Basics tab looks like. This shows the fields that are defined for this template.

The next screenshot shows the "Title" field's configuration. What is important is that this field is set to "Hidden", which means it is not shown in the editor.

The next screenshot shows the "CRMS Status Updates" Template's Family tab. It shows allowed templates for the parent and children pages.

This setup allows for additional Status Updates to be created within an existing Status Update.

Next we will look at the configuration of the CRMS Status Updates field.

CRMS Status Updates Field - Configuration Setup

This screenshot shows the Basics tab for this field. I normally provide detailed descriptions and notes for the Status Updates.

This next screenshot shows the Details tab of this field. Please notice that the associated template is "CRMS Status Updates". The Page Behaviors are defined to detail what happens under different circumstances. This is one of the many great features of these modules that Ryan Cramer creates. He always ensures that there are explanations within his modules.

Now we go to the Input tab where we can define what fields show and how they are displayed. A great feature of this field is that you can define an automatic page naming scheme. I normally use a time based format, because you can then easily go back and track when something was created.

The following video shows the Profields: Page Table field being used in the Status Updates setup.

VIDEO: Status Update Example

Related Source Documentation

Note: ProFields: Page Table was introduced in May 2014. FieldtypePageTable is at Version 0.0.8 and InputfieldPageTable is at Version 0.1.3.