Grid design in Facility and ePortal - Part 4 (formatting the grid itself)

Up to now we've been looking at how to format and manipulate the left hand column of the grid that contains the student names. Now we're going to move over a look at the other columns and the grid itself.

For the time being I'm going to carry on using the roll call attendance grid as my example, but the concepts will work with other grids within Facility. However, we will move on to look at assessment grids in more detail in future weeks as they offer more scope for customisation.

The Columns tab in the Design grid view window

Create a new attendance grid design in the usual way:

  1. From the main menu in Facility, select Attendance | Advanced | Grid design for Roll Call attendance
  2. Highlight ‘AttendanceRolls’, which is the default grid that comes with the system
  3. Change the name in the Name field to something like ‘MyGrid2’
  4. Click New
  5. Highlight the 'MyGrid2' grid and click Configure
  6. Click on the Columns tab   

The columns tab contains all of the information relating to how all the column headings and grid values are displayed.

Data items 

You will notice that the top part of the window now contains a list view. This is where we can add data items to display as columns in the grid. This is a bit like designing a list report in Facility; we specify the column headings, the values that will appear in the cells and how we want the data to be formatted.

Usually, however, we won't want to specify a specific column heading but to get the system to create multiple columns based on other data within the system. This is like creating a 'generated' column in a list report. So rather than create a column that displays the attendance data for a fixed session, like the morning of 5 February 2008, we want Facility to create columns for all the sessions that occur in the date range the user specifies when using the Edit roll call attendance window. 

If you highlight the single row of data in the list view on the columns tab of our 'MyGrid2' grid, you can see this in action.

The Title field contains the formula:

roll ConCat(Left(Rollcall.Date, 5), '\\', Rollcall.Code)

This is telling Facility that for each roll call session in the date range chosen by the user, display the day and the month - left(,5) - and on the next line - '\\' - whether the session was AM or PM - Rollcall.Code

Looking further down on the Columns tab, the Contents field specifies what will be displayed in the cell. In this case, the attendance code:


Editing the column headings

To edit the column headings, put the cursor in the Title field and hit the F9 key. The data tree will appear. In the case of roll call attendance, there aren't a huge number of items to choose from, but we could add the name of the day to make it easier for users to identify the session they want:

roll ConCat(Left(Rollcall.Date, 5), '\\',  Rollcall.Day, '\\', Rollcall.Code)

Note that:

  • We must precede the formula with the word 'roll', to indicate that we wish to generate multiple columns
  • We've added an extra line break code - '\\' - so the column heading will display over three lines

The resultant display in the Edit roll call attendance window should look something like this:

Incidentally, the word 'roll' is specific to attendance roll call grids. For other grids, use the following words:
  • Lesson by lesson attendance: 'Inst'
  • Assessment: 'res'
  • Sats result entry: 'sats'
  • Teaching groups: 'grp'

In fact, it is this word rather than the formulae in the Title and Contents fields that specify which columns are generated. Unlike a generated column in a list report, it is possible to end up with more than one column with the same title. If we put...

roll "rubbish"

...into the Title field the grid would look like this:

The columns are still generated correctly, but the titles don't mean anything. So be careful! 

Editing the cell values

Placing the cursor in the Contents field and hitting F9 gives you access to the data tree where you can choose the data item to display in the cell itself.

With an attendance grid there is not much call to edit the default value, as you 99 times out of 100 you would want to display the attendance mark. But if you wanted to show whether an absence was authorised or not instead, you could do so with this formula:


Which would look something like this:


(note that Stuabsence.Abscategory.Explained gives you the same thing - Serco changed the name of the data item in version 2.8 but stuabsence still works, although it doesn't appear in the data tree)