Home Schema Example JSON Schema

Clinic Table Settings

Type: object

Schema for configuring the look and feel of a table.

No Additional Properties

Title

Type: string

Title of the table for display to the user. Will be passed through i18n.

Must be at least 1 characters long

Default sort field

Type: string

This is used to decide the default sorting for the result set.

Must be at least 1 characters long

Order descending

Type: boolean

Result is order in descending order based on the default sort field is set to true.

Columns

Type: array of object

Settings for each column in the table. This is an ordered array of columns from left to right.

Must contain a minimum of 1 items

No Additional Items

Each item of this array must be:

Type: object
No Additional Properties

ID

Type: string

Column unique identifier. This is used for sorting purposes.

Must be at least 1 characters long

Header

Type: string or object

The column header for display. Will be passed through i18n if its a string, if it is an object it will be rendered based on the component property (ie. component "TableSectionHeader, TableSubSectionHeader", componentProps "title, subtitle").

Accessor

Type: string

Accessor value to use to retrieve the data

Must be at least 1 characters long

Sticky

Type: enum (of string)

Make column sticky either to left or right

Must be one of:

  • "left"
  • "right"

manualSorting

Type: boolean

Use to determine if we do the sorting manually or use the predefined sorting functionality that comes with the library

Background color

Type: string

background color of the column

Must be at least 3 characters long

Sub columns

Type: array of object

Define child columns within a header column. The properties of this column are similar to its parent

Must contain a minimum of 1 items

No Additional Items

Each item of this array must be:

Type: object

Additional Properties of any type are allowed.

Type: object

Component

Type: enum (of string)

The component to render. Defaults to Text.

Must be one of:

  • "Text"
  • "Link"
  • "Alert"
  • "Comment"
  • "BGTableCell"
  • "Badge"
  • "Markdown"
  • "MonitoringFormsArray"
  • "Boolean"

Width

Type: string

Width of the column. Defaults to browser math.

Must be at least 1 characters long

Style

Type: object

Styling props to pass to the component.

Additional Properties of any type are allowed.

Type: object

Disable Sort By

Type: boolean

Make this column un-sortable. Defaults to false.

Data

Type: object

Describes how data is being formatted and rendered to the user.

No Additional Properties

Value Template

Type: string

Template string (include ${x} variables) to define how cells are rendered.

The following variables are available for patient-form tables:

  • ${clinic[name]}: Name of clinic.
  • ${clinic[uid]}: UID of clinic.
  • ${clinic[domain]}: Domain for clinic login.
  • ${clinic[effective_logo]}: URL to clinic logo.
  • ${profile[uid]}: UID of clinician/patient profile.
  • ${profile[name]}: Name of clinician/patient.
  • ${profile[phone]}: Phone number of clinician/patient.
  • ${profile[language]}: ISO language code of clinician/patient's preferred language.
  • ${profile[communication_method]}: Preferred communication method of clinician/patient.
  • ${clinician[designation]}: Designation of clinician (currently not used).
  • ${patient[identifier]}: Masked identifier for patient.
  • ${monitoring_formset[uid]}: UID of monitoring formset.
  • ${monitoring_formset[name]}: Name of monitoring formset.
  • ${monitoring_formset[alert_rules]}: Comma-separated names of alert rules of monitoring formset.
  • ${monitoring_formset[reminders]}: Comma-separated names of effective reminders of monitoring formset.
  • ${monitoring_formset[reminder_descriptions]}: Comma-separated description of effective reminders of monitoring formset. Descriptions are human readable representation of the reminder schedule.
  • ${monitoring_formset[clinical_parameters]}: Comma-separated names of clinical parameters of monitoring formset.
  • ${monitoring_form[uid]}: UID of monitoring form.
  • ${monitoring_form[effective_name]}: Name of monitoring form.
  • ${monitoring_form[language]}: Language of monitoring form.
  • ${monitoring_form[url]}: URL of monitoring form.
  • ${patient_form[uid]}: UID of patient-form.
  • ${patient_form[language]}: Language of patient-form.
  • ${patient_form[alert_rules]}: Comma-separated names of effective alert rules of patient-form.
  • ${patient_form[reminders]}: Comma-separated names of effective reminders of patient-form.
  • ${patient_form[reminder_descriptions]}: Comma-separated description of effective reminders of patient-form. Descriptions are human readable representation of the reminder schedule.
  • ${patient_form[alertees]}: Comma-separated values of patient-form's clinicians alertees' names.
  • ${patient_form[ics]}: Comma-separated values of patient-form's clinicians in-charges' names.
  • ${patient_form[created_on]}: Enrollment date of patient-form. Formatted using clinic datetime format string.
  • ${patient_form[deactivated_on]}: Discharge date of patient-form. Formatted using clinic datetime format string.
  • ${patient_form[last_submitted_on]}: Date of most recent submission form. Formatted using clinic datetime format string; N/A if not available.

The following variables are available for submission tables (in addition to the variables ☝️)

  • ${submission[uid]}: UID of submission.
  • ${submission[created_on]}: Submission date of submission.
  • ${submission_value[<name_with_group>]}: Submission value for clinical parameter name_with_group. Example: ${submission_value[BP Systolic]}.
  • ${submission_value[<uid>]}: Submission value for clinical parameter with UID uid. Example: ${submission_value[xxxxx123456789012345678901234567]}.

Href Template

Type: string

Template string for href of Link component. The same variables set as valueTemplate is supported.