HTML implementation standards
Purpose
This document is intended for use by software developers, both provider supplier and consumer supplier, looking to build a conformant GP Connect HTML care record viewer application.
Notational conventions
The keywords “MUST”, “MUST NOT”, “REQUIRED”, “SHALL”, “SHALL NOT”, “SHOULD”, “SHOULD NOT”, “RECOMMENDED”, “MAY”, and “OPTIONAL” in this document are to be interpreted as described in RFC 2119.
Near real time view
- local pending changes (that is, within a consultation that is actively ongoing) may not be available
- the record is machine-generated and therefore is not owned or attested by any single clinician
Record locking
GP Connect queries/requests may be received while the patient’s record is being updated.
Record locking inside a provider system MUST NOT impact the ability of the system to fulfil read/query requests of the patient’s record.
However, it is understood that there are differing approaches to record locking within the GP principal systems which have an effect when any local/pending changes are actually committed back to the patient’s record.
When a consumer system accesses a patient’s record, the provider systems MUST only return data that has been successfully committed back to the patient’s record and thus has become available to all users (including users of the provider APIs).
Common user interface guidance
Where appropriate the following Common User Interface (CUI) guidance documents should be followed when generating the GP Connect HTML views.
NHS Number format
NHS Number input and display
NHS Number input and display - Quick Implementation Guide
Patient details
Patient Name input and display
Patient Name input and display - Quick Implementation Guide
Sex and current Gender input and display
Sex and current Gender input and display - Quick Implementation Guide
Date/time format
Date display
Time display
Date Time display - Quick Implementation Guide
GP details
Address input and display
Telephone Number input and display
Medication representation
Medications Management - Medication Line
Patient banner
Consumer systems MUST present a patient banner above the HTML content returned from the GP Connect APIs in line with the CUI guidance.
Patient Banner
Patient Banner - Quick Implementation Guide
Minimum display resolution
This guidance is applicable to user interfaces displayed on desktop or laptop computers. It is assumed that, at a minimum, these computers are capable of operating at a minimum display resolution of 1024 x 768 and have a keyboard and pointing device.
Structured data
FHIR resources
Provider systems MUST return a minimal set of structured data along with the HTML content as follows:
FHIR resource(s) | Composition section |
---|---|
Patient |
Subject |
Practitioner |
User |
Organization |
Custodian |
Device |
Author1 |
1 As the composition is machine-generated the concept of a single Author does not make logical sense. It is expected that the Author field will be populated with the details of the software system which generated the composition.
Demographic cross checking
Consumer systems MUST compare the returned structured patient demographic data (supplied by the provider system as structured data) against the demographic data held in the consumer system.
If differences exist then the consumer system MUST show an alert/warning and provide details of which fields/values are different between the two systems.
The following data MUST be cross checked between consumer and returned provider data. Any differences between these fields MUST be brought to the attention of the user.
Item | Resource element |
---|---|
Family Name | patient.name.family |
Given Name | patient.name.given |
Gender | patient.gender |
Birth Date | patient.birthDate |
GP Practice Code | patient.managingOrganization |
Additionally, the following data MAY be displayed if returned from the provider to assist a visual cross check and for safe identification but should not be part of the automatic comparison.
- Address and Postcode
- Contact (telephone, mobile, email)
- Responsible GP Code and Name
- GP Practice Name and Address
Where a patient is flagged on the GP clinical system as sensitive (and as such the GP practice must not identify that the patient is registered at this location), the provider system MUST NOT return any clinical records and instead return the error Patient not found
.
Where a patient is flagged on the Personal Demographics Service (PDS) as sensitive (and as such it is not possible to confirm their registered GP practice), the consumer system MUST NOT use GP Connect.
Section retrieval
Error handling
If a GP principal system can’t meaningfully supply content for a requested HTML section (or subset of the Summary View) then the system MUST return the following HTML fragment in place of the HTML table.
Supported but hasn’t been recorded
- system can store the data
- BUT no data has been recorded for the patient
<div>
<p>No '[section]' data is recorded for this patient.</p>
</div>
Supported but can’t be technically provided
- system can store the data
- BUT no data is available for the patient via the GP Connect APIs due to a technical limitation
<div>
<p>This system does not support retrieval of '[section]' data.</p>
<p>This data may still exist in the source system.</p>
</div>
Supported but is masked/access denied
- system can store the data
- BUT no data is available for the patient via the GP Connect APIs due to a IG/DS rule
<div>
<p>Access is denied to '[section]' data for this patient.</p>
<p>This data may still exist in the source system.</p>
</div>
Not supported
- system doesn’t store the data
<div>
<p>'[section]' data is not supported by this system.</p>
</div>
HTML section views
Provider systems MUST use XHTML constructs as defined in the FHIR narrative guidance contained within the FHIR® standard.
XHTML narrative
As outlined in the Narrative section of the FHIR® standard:
Note that the XHTML is contained in general XML so there is no support for HTML entities like
or ©
. Unicode characters MUST be used instead. Unicode  
substitutes for
.\r\n
, as these may cause inconsistent rendering within consumer applications, with potential impacts on clinical safety.Styling the XHTML
As outlined in the ‘Styling the XHTML’ section of the FHIR® standard:
Please see the FHIR Runtime CSS or Styling the XHTML on the FHIR website for full details.
CSS IDs and classes
The following HTML IDs MUST be applied across the HTML views:
ID name | Description | HTML view(s) |
---|---|---|
adm-tab |
Applied within the <table> tag of the Administrative Items table |
Administrative Items |
all-tab-curr |
Applied within the <table> tag of the Current Allergies and Adverse Reactions table |
Allergies and Adverse Reactions & Summary |
all-tab-hist |
Applied within the <table> tag of the Historical Allergies and Adverse Reactions table |
Allergies and Adverse Reactions |
cli-tab |
Applied within the <table> tag of the Clinical Item table |
Clinical Items |
enc-tab |
Applied within the <table> tag of the Encounters table |
Encounters & Summary |
imm-tab |
Applied within the <table> tag of the Immunisations table |
Immunisations |
med-tab-acu-med |
Applied within the <table> tag of the Acute Medication (Last 12 Months) |
Medications & Summary |
med-tab-curr-rep |
Applied within the <table> tag of the Current Repeat Medication table |
Medications & Summary |
med-tab-dis-rep |
Applied within the <table> tag of the Discontinued Repeat Medication table |
Medications |
med-tab-all-sum |
Applied within the <table> tag of the All Medication table |
Medications |
med-tab-all-iss |
Applied within the <table> tag of the All Medication Issues table |
Medications |
obs-tab |
Applied within the <table> tag of the Observations table |
Observations |
prb-tab-act |
Applied within the <table> tag of the Active Problems and Issues table |
Problems and Issues & Summary |
prb-tab-majinact |
Applied within the <table> tag of the Major Inactive Problems and Issues table |
Problems and Issues & Summary |
prb-tab-othinact |
Applied within the <table> tag of the Other Inactive Problems and Issues table |
Problems and Issues |
ref-tab |
Applied within the <table> tag of the Referrals table |
Referrals |
The following HTML classes MUST be applied across the HTML view:
Class name | Description | HTML view(s) |
---|---|---|
content-banner |
Applied within the <div> tag of any section/subsection content banner |
All views |
date-banner |
Applied within the <div> tag of any section/subsection date filter banner |
All views |
exclusion-banner |
Applied within the <div> tag of any section/subsection exclusion banner |
All views |
gptransfer-banner |
Applied within the <div> tag of any section/subsection exclusion banner |
All views |
date-column |
Applied within the <td> tag of any table column with a dd-Mmm-yyyy date format |
All views |
med-item-column |
Applied within the <td> tag of a grouped distinct Medication Item |
Medications (All Medication (Summary) & All Medication Issues only) |