Non-spatial Editor

The content here is a work in progress and may not be complete or accurate.

Namespace

urn:com.cohga.server.editor#1.0

Tags

entity

Properties

NameTypeRequiredDescription
idstringyesunique identifier.
aclref urn:com.cohga.server.acl#1.0:aclnoOptional ACL to restrict access.
entityref urn:com.cohga.server.entity#1.0:entityyesThe entity that this edit config relates to.
labelstringyesThe label that is displayed to the user for this edit.
datasourceref urn:com.cohga.server.datasource.jdbc#1.0:datasourceyesThe datasource that contains the table to edit.
tablestringyesThe name of the table within the datasource that is to be edited.
keystringnoThe column in the table that will uniquely identify each row, the primary key will be used if not set.
entityTablestringnoSpecify a different table for the entity id column from the one that's being edited. Requires a join to be configured to link this table to the source table.
entityKeystringnoSpecify a different column for the entity id from the key column specified here. If entityTable is specified the column must be in that table.
joinref urn:com.cohga.server.editor#1.0:joinnoA join expression for linking the source table and other tables (generally for joins to refine what rows are available, e.g. linking to a status table ).
sortref urn:com.cohga.server.editor#1.0:sortnoOrder by clauses to use when retrieving data for display.
parametersbooleanno

If set to true the table will be examined to determine the information about what columns can be edited and the parameter tags override/supplement this information.

If not set or set to false the parameter tags will determine what columns can be edited.

parameterref urn:com.cohga.server.editor#1.0:parameternoDescribes one column to be edited, can be specified multiple times.
retireColumnstringno

Column to use to "retire" a record rather than deleting the row when deleting a record. Must be a timestamp column type in the database.

When this column is specified then deleting a record won't delete the record but will instead record the date the record was retired in this column.

Rows with a value in this column won't be included when displaying data from this table to the user.

historybooleannoWhen set to true indicates that a history of the changes made to this table will be recorded in a separate history table. The schema for the history table must match the source table (with the addition of the user and time columns).
historyTablestringnoThe name of the table to record historical data, defaults to the table name plus the suffix "_hst".
historyUserColumnstringnoThe column in the history table to record the user who made the change, defaults to "modified_user"
historyTimeColumnstringnoThe column in the history table to record the time when the change was made, defaults to "modified_time". Must be a timestamp column type in the database.

join

Properties

NameTypeRequiredDescription
typeLEFT, INNER, RIGHTnoType of join to perform, default is INNER
leftstring or objectyes

The left table and column in the join, formatted as TABLE.COLUMN.

<left>TABLE.COLUMN</left> can also be specified using table and column sub-tags, e.g. <left><table>TABLE</table><column>COLUMN</column></left>

rightstring or objectyes

The right table and column in the join, formatted as TABLE.COLUMN.

<right>TABLE.COLUMN</right can also be specified using table and column sub-tags, e.g. <right><table>TABLE</table><column>COLUMN</column></right>

sort

Properties

NameTypeRequiredDescription

stringyesThe column name to sort by. Note this isn't an attribute of the tag, it's the content, e.g. it's <sort>CREATION_DATE</sort>
directionASC or DESCnoSort direction, <sort direction="DESC">CREATION_DATE</sort>

parameter

Properties

NameTypeRequiredDescription
displayNamestringnoNo idea.
helpTextstringnoDescription of the input field.
promptTextstringnoThe label for the field (can also be called label rather than promptText)
aclref urn:com.cohga.server.acl#1.0:aclnoAn ACL to restrict access to the parameter.
hiddenbooleannoIs the input field displayed?
idstringyesA unique id for the parameter
alignment'left', 'center', 'right' or 'auto'noHow to align the input.
controlType'listbox', 'checkbox', 'radiobutton', 'textbox', 'textarea' or 'money'noHow the input of the field should be presented.
dataType'any', 'boolean', 'datetime', 'date', 'time', 'decimal', 'float', 'integer', 'string'noWhat is the underlying data type for the column?
allowBlankbooleannoCan this field be left blank?
allowNewValuesbooleannoIs a combo box limited to the defined values or can the user enter their own values?
allowNullbooleannoDoes the database allow this value to be null?
defaultValuestringnoThe initial value to populate a field with.
displayFormatstringnoNo idea.
fixedOrderbooleannoNo idea, but apparently you can set it to true or false.
concealValuebooleannoShould the input value be hidden when the user types it in (no currently supported in the client).
listlist of valuesno
scalarParameterType'simple' or 'multi-value'noIf set to multi-value then more than one item can be selected from a list box.
pageSizeintegernoNumber of entries in a list box to display per-page, set to 0 to disable paging.
widthintegernoChange the width of the input field.
matchType'start', 'middle', end or 'auto'noWhen searching a list box based on the text the user us typing this determines how the text is used, default is start.
autoSelectbooleannoIf true then the first value in a list box is preselected.
forceSelectionbooleannoIf true then a value must be chosen from a list box.
typeAheadbooleannoIf set to true typing in a list box field refines the available values.
minLengthintegernoThe minimum number of characters required for a field.
maxLengthintegernoThe maximum number of characters required for a field.
minValue
noThe minimum value allowed for a field.
maxValue
noThe maximum value allowed for a field.
increment
noFor fields that support it this is the value of the difference between subsequent values, e.g. it's 15 for time fields
uppercasebooleannoShould the value be converted to upper-case before being inserted into the database.
sequencestringnoIf the value for the parameter is generated from a database sequence then this is the name.
autogeneratedbooleannoIs the value for the parameter generated by the database.
trueValue
noThe value stored in the database that indicates that the value us "true".
falseValue
noThe value stored in the database that indicates that the value us "false".
readOnlyOnUpdatebooleannoIf set to true then the value can not be changed when the record is being updated.
readOnlyOnInsertbooleannoIf set to true then the value can not be changed when the record is being created.
dataSetref urn:com.cohga.server.data.database#1.0noSource data definition for list box content
labelColumnstringnoParameter in dataSet that contains the label for the list box content
valueColumnstringnoParameter in dataSet that contains the value for the list box content
sortColumnlabelColumn or valueColumn or one of 'label', 'value', 'none', 'defined' or 'default'no

How the content of the listbox should be sorted:

  • label - sort based on content of the label
  • value - sort based on the content of the value
  • none - no sorting
  • defined - sorting is provided by the data definition
  • default - whatever happens when this value isn't set

Additionally the value could be the same as the labelColumn or valueColumn attribute

valuestringnoThe value that should be written to the column, the user will not be able to change this value.
autoExpandbooleannoShould a list box be expanded immediately when the user enters the field?
readOnlybooleannoIf set to true then the value can not be changed.

Extra Notes

The editor.panel.simplegrid panel now supports a comboWidth and comboListWidth properties to change the size of the drop-down list.