User Tools

Site Tools


Sidebar

xtension_manual:customlistcolumns

Lists: Using Custom Columns

You can add any Unit Property to a custom column in a List window. Unit Properties are keyed values beyond the standard set of properties a unit has. Unit Properties can be numbers, text or dates for the purpose of a custom column, but for scripting they can hold any AppleScript structure including lists or script objects. Some Unit Properties are extra data holders with the values set by the unit’s interface. Such as the “PollRating” value from the Vera. Any others can be set by the user via the Unit Property Control Panel window or via any script with the Unit Property AppleScript verbs.

For this example we’re going to create a display of the Vera’s PollRating value. Each unit that is polled gets an average value in this property that shows you how many polls that device has returned successfully. A value of 5.0 means the last 50 polls were returned OK. As polls are dropped the number will go down and finally hit 0 when a device becomes unreachable. (note that only the Vera UI7 interface sends this data to XTension, the legacy UI5 support does not include this information)

Open your Vera Units list and highlight a unit that you think might have a poll rating. You can check for sure by control clicking on the unit and selecting “show unit properties”. It’s not necessary to highlight or find a unit that has this property, but if you do then you won’t have to properly type the property name into the next window as it will offer you a popup of the available properties for the selected unit.

Once you’ve done that, control click in the headers of the list. Select “Insert Custom Column” from the contextual menu. The Custom Column Setup sheet will drop down into the window. If you click on an already existing Custom Column then you’ll be presented with an additional option to Edit Custom Column which will bring down the same sheet populated with the existing column settings.

The Header Text is the title of the column that you would like to be displayed in the header.

The Unit Property Name is the text key of the unit property you want to display in the column. If you selected a unit in the list the popup will be populated with the available unit properties. If you didn’t select a unit then the popup will contain any properties that were in the first unit in the list. You can select an existing property or you can type in one that doesn’t exist yet. Units that do not have a property by the name will show an empty field in the list.

Draw Centered controls if the value is left justified or centered in the column.

Allow Editing In List makes the field inline editable. Like the Description field is in every list you will be able to click on the field and it will turn into a regular edit field where you can enter a new value or edit an existing one. Press enter to save the value or escape to cancel the edit. This works both in the app and on the web remote identically.

Property is a date if the unit property is a date checking this list makes sure it displays with the same date format that you have selected for the list. It will also make sure that the date is sorted by it’s actual date and not lexigraphically as the text of the date as presented. If you also have selected Allow Editing In List then this will present a date and time selection popup window rather than just an edit field as other data types do. Apologies to our non-US users the date format on the web interface for editing a date is limited to presenting you with the normal US date month/day/year and am/pm formats. I’ll resolve that in a future maintenance release.

For this example enter a Header text of “Rating” and select or type in the name of the property which is “PollRating” Optionally check the Draw Centered In Column checkbox. Once you’ve done that you’ll be able to check the health of any of your devices right from the list as well as sort them by the values to easily find any devices that might be having trouble.

History

  • Custom Column support was added in XTension 9.4
xtension_manual/customlistcolumns.txt · Last modified: 2018/04/11 16:15 by James Sentman