Checks data model

The Checks framework data model broadly consists of objects and the checks to be performed on them. The model supports:

  • Objects and their properties

  • Hierarchical relationship between objects

  • Checks to be performed per object type

  • Organization of checks into checkgroups

  • Additional properties on checks

  • Dynamic response types to cater various requirements

  • Business rules on checks

Code: Unique identifier

Each entity in the data model has a system defined property named Code that serves as the unique identifier of the entity. The code of an entity is bound by the convention on code of dataset items. It can be a combination of alphabets, numbers or underscore, but should not contain spaces or other special characters.

ValueSource: Reference to existing datasets

If multiple properties refer to a predefined list of items, the list should be maintained as a dataset. A dataset should be created with the required items and the name of the dataset should be mentioned as the ValueSource property of the entity.

SortOrder: Order of items

Each entity in the data model has a system defined property named SortOrder that can be used to define the order in which they should be displayed or be relevant. For example, checkgroups and checks are displayed on screen in their defined sort order, input fields in a multi-check response are displayed on screen in the order defined for check responses and so on. The sort order can be a combination of alphabets and numbers.

As SortOrder is alphanumeric, when using numeric values to define the sort order, use zeroes as prefix to enforce the correct order. For example, if maximum number of items expected is 1000, then the sort order can be defined using numbers like 0001, 0002, 0003…

Objects data model

ObjectTypes

An object type is used to define logical groups for objects. For example, tanks or valves.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

Name

string

yes

 

Description

string

no

A more detailed explanation if required.

ObjectTypeProperties

An object type may have properties. A property can be a basic data unit or a reference to an item from a collection.

For example, locations and tanks can be maintained as objects. A tank may have properties StorageCapacity and Location. The StorageCapacity is a basic data unit that is captured as a decimal value. The Location property of a tank however refers to the location object.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

ObjectTypeCode

string

yes

Refers to ObjectTypes.Code

Name

string

yes

 

Description

string

no

A more detailed explanation if required.

ValueSource

string

no

Name of the dataset that lists all possible values for this property.

Objects

An object is usually an asset that is to be inspected or is a part of the asset management system. Objects can belong to an object type, and may further has an optional sub type.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

Name

string

yes

 

Type

string

no

Refers to ObjectTypes.Code

SubType

string

no

 

ObjectPropertyValues

Stores actual value of a property for an object.

If an object belongs to an object type, then all properties defined on the object type are applicable to the object.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

ObjectCode

string

yes

Refers to Objects.Code

PropertyCode

string

yes

Refers to ObjectTypeProperties.Code

Value

string

no

 

ObjectHierarchy

Maintains the relationship between objects.

There can be a hierarchy of objects i.e. an object may have one or more sub objects. If an object has a parent, then the Code of the parent object is stored as ParentCode in the sub object.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

ObjectCode

string

yes

Refers to Objects.Code

ParentCode

string

no

Refers to Objects.Code

DisplayName

string

no

A different name of the object, if applicable, when listed under this relationship.

Checks definition data model

CheckGroups

A checkgroup is used to define logical groups for checks.

There can be a hierarchy within checkgroups i.e. a checkgroup may be further divided into one or more sub-checkgroups. If a checkgroup belongs to another checkgroup, then the Code of the parent checkgroup is stored as ParentCode in the sub checkgroup.

When there is a hierarchy of checkgroups, it is sufficient to link a check to the check at the bottom of the hierarchy.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

Name

string

yes

 

Description

string

no

A more detailed explanation if required.

ParentCode

string

no

Refers to CheckGroups.Code

CheckGroupProperties

A checkgroup may have properties. A property can be a basic data unit or a reference to an item from a collection.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

Name

string

yes

 

Description

string

no

A more detailed explanation if required.

ValueSource

string

no

Name of the dataset that lists all possible values for this property.

CheckGroupPropertyValues

Stores actual value of a property for a checkgroup.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

CheckGroupCode

string

yes

Refers to CheckGroups.Code

PropertyCode

string

yes

Refers to CheckGroupProperties.Code

Value

string

no

 

CheckGroupsPerObjectType

Checkgroups may be linked to one or more object types.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

ObjectTypeCode

string

yes

Refers to ObjectTypes.Code

CheckGroupCode

string

yes

Refers to CheckGroups.Code

Checks

A check is a question/test against which one or more responses are to be provided by the user.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

CheckPrefix

string

no

Text to be shown before the question
e.g. question no or seq no

CheckText

string

yes

Actual question or test to be responded to.

HelpText

string

no

Additional instructions to be shown for the check.

ShowNotes

bit

no

Show option to add notes/remarks.

ShowPhotos

bit

no

Show option to capture photos.

ShowActions

bit

no

Show option to add actions for the check.

CheckTranslationCode

string

no

 

HelpTextTranslationCode

string

no

 

CheckProperties

A check may have properties. A property can be a basic data unit or a reference to an item from a collection.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

Name

string

yes

 

Description

string

no

A more detailed explanation if required.

ValueSource

string

no

Name of the dataset that lists all possible values for this property.

CheckPropertyValues

Stores actual value of a property for a check.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

CheckCode

string

yes

Refers to Checks.Code

PropertyCode

string

yes

Refers to CheckProperties.Code

Value

string

no

 

ChecksPerCheckGroup

Checks may belong to one or more checkgroups.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

CheckGroupCode

string

yes

Refers to CheckGroups.Code

CheckCode

string

yes

Refers to Checks.Code

ResponseTypes

A response type is a data capture unit (part of the response to the check).

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

Name

string

yes

 

Type

string

yes

STANDARD or CUSTOM

ControlType

string

no

 

DataType

string

yes

 

Unit

string

no

 

Prefix

string

no

Prefix text to be shown before the control

Suffix

string

no

Suffix text to be shown after the control

Configuration

string

no

 

ValueSource

string

no

Name of the dataset that lists all possible values for this property.

FilterType

string

no

 

Filter

string

no

 

ResponseTypeValues

Stores values to be shown for multi-value response types (in case ValueSource is not defined).

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

ResponseTypeCode

string

yes

Refers to ResponseTypes.Code

Value

string

no

 

CheckResponses

A check may have one or more responses.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

CheckCode

string

yes

Refers to Checks.Code

ResponseTypeCode

string

yes

Refers to ResponseTypes.Code

Name

string

no

 

DisplayText

string

no

 

Rules

A rule controls the check e.g. when to show the check, what default value should be set, whether it is mandatory etc.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

Name

string

yes

 

Type

string

yes

 

Configuration

string

no

 

FlagCheckOnFailure

bit

no

Mark the check as failed if the rule fails.

CheckRules

Mapping between checks and rules.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

CheckCode

string

yes

Refers to Checks.Code

CheckResponseCode

string

no

Refers to CheckResponses.Code

RuleCode

string

yes

Refers to Rules.Code

ActionProperties

Actions may have properties. A property can be a basic data unit or a reference to an item from a collection.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

Name

string

yes

 

Description

string

no

A more detailed explanation if required.

ValueSource

string

no

Name of the dataset that lists all possible values for this property.

ActionPropertyValues

Stores actual value of a property for an action.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

ActionCode

string

yes

Refers to Actions.Code

PropertyCode

string

yes

Refers to ActionProperties.Code

Value

string

no

 

Processes

An inspection is a process that may have one or more tasks.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

Type

string

no

 

Status

string

no

 

StartDateTime

string

yes

 

EndDateTime

string

yes

 

ProcessProperties

A process may have properties.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

Name

string

yes

 

Description

string

no

A more detailed explanation if required.

ValueSource

string

no

Name of the dataset that lists all possible values for this property.

ProcessPropertyValues

Stores actual value of a property for a process.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

ProcessCode

string

yes

Refers to Processes.Code

PropertyCode

string

yes

Refers to CheckProperties.Code

Value

string

no

 

Tasks

A process may have one or more tasks. If a process has only one task, then the underlying form is the same for both the process and the task. If a process contains one or more tasks, then each task has an underlying form of its own.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

Name

string

no

 

Type

string

no

 

Status

string

no

 

ProcessCode

string

no

 

StartDateTime

string

no

 

EndDateTime

string

no

 

CreationUser

string

no

User who first responded to the task.

ModifiedUser

string

no

User who last made some edits in the task.

Checks results data model

CheckResults

A check result is the response captured for a check as a part of a process and a task.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

CheckCode

string

yes

Refers to Checks.Code

CheckGroupCode

string

yes

Refers to CheckGroups.Code

ObjectCode

string

yes

Refers to Objects.Code

ObjectTypeCode

string

yes

Refers to ObjectTypes.Code

ProcessCode

string

yes

Refers to Processes.Code

TaskCode

string

yes

Refers to Tasks.Code

IsFlagged

bit

no

Indicates if the check failed.

Notes

string

no

Notes added during the check.

CreationUser

string

no

User who first responded to the check.

ModifiedUser

string

no

User who last modified the check response.

CheckResultValues

A check may have multiple response types, hence a check result may have multiple response values.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

CheckResultCode

string

yes

Refers to CheckResults.Code

CheckCode

string

yes

Refers to Checks.Code

CheckResponseCode

string

yes

Refers to CheckResponses.Code

Value

string

no

The actual response captured.

Unit

string

no

 

DataType

string

no

 

CheckResultActions

A check may result in one or more actions. Actions can be tracked individually, separate from checks.

Property

Type

Mandatory

Description

Property

Type

Mandatory

Description

Code

string

yes

Unique identifier. System defined property.

CheckResultCode

string

yes

Refers to CheckResults.Code

CheckCode

string

yes

Refers to Checks.Code

CheckGroupCode

string

yes

Refers to CheckGroups.Code

ObjectCode

string

yes

Refers to Objects.Code

ProcessCode

string

yes

Refers to Processes.Code

TaskCode

string

yes

Refers to Tasks.Code

ActionText

string

yes

 

Remarks

string

no

 

Status

string

no

 

CreationUser

string

no

User who first responded to the check.

ModifiedUser

string

no

User who last modified the check response.