Skip to content

Commit

Permalink
Work
Browse files Browse the repository at this point in the history
  • Loading branch information
Quentin Ligier committed Jun 9, 2022
1 parent 7e4bdd1 commit ba3d3a3
Show file tree
Hide file tree
Showing 7 changed files with 149 additions and 12 deletions.
13 changes: 13 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Top-level config
root = true

[*]
charset = utf-8
indent_style = space
indent_size = 2
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true

[*.md]
trim_trailing_whitespace = false
14 changes: 9 additions & 5 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Publish docs via GitHub Pages
name: Publish docs on GitHub Pages
on:
push:
branches:
Expand All @@ -10,12 +10,16 @@ jobs:
steps:
- name: Checkout master
uses: actions/checkout@v2
- uses: actions/setup-python@v2
- name: Setup Python 3
uses: actions/setup-python@v2
with:
python-version: 3.x
- uses: actions/cache@v2
- name: Cache some files
uses: actions/cache@v2
with:
key: ${{ github.ref }}
path: .cache
- run: pip install mkdocs-material
- run: mkdocs gh-deploy --force
- name: Install mkdocs
run: pip install mkdocs-material
- name: Build and deploy
run: mkdocs gh-deploy --force
6 changes: 6 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"yaml.schemas": {
"https://squidfunk.github.io/mkdocs-material/schema.json": "mkdocs.yml",
"https://json.schemastore.org/github-workflow.json": "file:///Users/qlig/git/cara-emed-ig/.github/workflows/build.yml"
}
}
47 changes: 43 additions & 4 deletions docs/cdachemed/dosage.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@

[ArtDecor template](https://art-decor.org/art-decor/decor-templates--cdachemed-?id=2.16.756.5.30.1.1.10.4.35).


## Dose regime

The dose regime is described by a templateId.
The dose regime is described by an additional templateId in the `#!xml <hl7:substanceAdministration>` or the `#!xml <hl7:supply>`.

!!! bug inline end "Not fully supported"

Expand Down Expand Up @@ -34,10 +35,14 @@ The repeat number is mandatory and can be used to limit the number of allowed re
<hl7:repeatNumber nullFlavor="NI" /><!-- The refills are unlimited -->
```

The refill quantity is defined as:
The refill quantity is the same as the one provided in the item entry.

## Route of administration

!!! warning "CARA: additional requirement"

The eMedication service restricts the unit to the ["RouteOfAdministration (Ambu)" value set](https://art-decor.org/art-decor/decor-valuesets--cdachemed-?id=2.16.756.5.30.1.1.11.3).

## Approach site code

!!! bug "Not implemented"
Expand All @@ -46,18 +51,52 @@ The refill quantity is defined as:

## Dose quantity

The quantity of medication to take at each .

The value can be a positive, non-zero, non-infinite decimal value or a double.

1. A decimal value can be "1.23", "21", "1.0". See the [XML Schema decimal specification](https://www.w3.org/TR/xmlschema-2/#decimal).
2. A double value can be "1", "3E2". See the [XML Schema double specification](https://www.w3.org/TR/xmlschema-2/#double).

!!! warning "CARA: additional requirement"

The eMedication service restricts the unit to the ["RegularUnitCode (Ambu)" value set](https://art-decor.org/art-decor/decor-valuesets--cdachemed-?id=2.16.756.5.30.1.127.77.12.11.3).

!!! error "Please avoid"

Please avoid using values that can confuse the reader, are weird or do not make sense, as "0.333", "0.42", "1.618", "INF", "-1E4", "0", "12678967.543233".

```xml title="Examples"
<hl7:doseQuantity value="1" unit="732936001" /><!-- One tablet -->
<hl7:doseQuantity value="10" unit="732994000" /><!-- Ten drops -->
<hl7:doseQuantity value="0.5" unit="[tsp_m]" /><!-- Half a teaspoon -->
```

## Rate quantity

!!! bug "Not implemented"

This is not yet described in CDA-CH-EMED. As it mainly concerns perfusions and are uncommon in the XXX, it's not a priority to support it.
This is not yet described in CDA-CH-EMED. As it mainly concerns perfusions and are uncommon for outpatients, it's not a priority to support it.

## Narrative dosage instructions

The narrative dosage instructions can only appear in the normal dose regime.

```xml title="Usage of the narrative dosage instructions"

<hl7:entryRelationship typeCode="COMP">
<hl7:substanceAdministration moodCode="INT" classCode="SBADM">
<hl7:templateId root="2.16.756.5.30.1.1.10.4.52" />
<hl7:text>
Take one pill in the morning and two pills in the evening with some water.
<hl7:reference value="#dosageinstructions" />
</hl7:text>
<hl7:consumable>
<hl7:manufacturedProduct>
<hl7:manufacturedMaterial nullFlavor="NA" />
</hl7:manufacturedProduct>
</hl7:consumable>
</hl7:substanceAdministration>
</hl7:entryRelationship>
```

## Examples
Expand Down
57 changes: 57 additions & 0 deletions docs/cdachemed/packaging.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,59 @@
# Packaging

## Code

The GTIN or ATC code that caracterizes the medication package (GTIN) or the medication substance (ATC).

## Name

## Form code

This code represents the pharmaceutical dose form (e.g. tablet, capsule, liquid).

??? info "Recommended usage"

table

## Lot number text

The lot number text is a free text used to indicate the medication lot number.

!!! abstract "Usage in MTP and PRE"

The main usage is controlled trials, so usually not in the scope of the eMedication service; it's not expected of healthcare professionals to fill it.

!!! abstract "Usage in DIS"

Dispensers may provide it for documentation.

## Expiration time

The medication expiration time.

!!! abstract "Usage in MTP and PRE"

No usage.

!!! abstract "Usage in DIS"

Dispensers should provide it, as it'll enable patient applications to alert them about incomming expiration of active treatment to allow timely re-dispensiation and avoid treatment interuption or expired medication usage.

## As content: code

This shall be a GTIN.

## As content: name

## As content: form code

## As content: capacity quantity

!!! warning "CARA: additional requirement"

The eMedication service restricts the unit to the ["RegularUnitCode (Ambu)" value set](https://art-decor.org/art-decor/decor-valuesets--cdachemed-?id=2.16.756.5.30.1.127.77.12.11.3).

## Ingredients

!!! info "Not supported"

Currently, ingredients are ignored by the eMedication service.
9 changes: 9 additions & 0 deletions docs/cdachemed/workflow.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Workflow

An MTP item is to insert a medication into the patient's treatment plan and instruct the patient to take it, even if it wasn't prescribed or dispensed: the patient may already have it.

A PRE item is purely a logistic document. It instructs the pharmacist to dispense that medication and allow reimbursment by insurances. Paper prescriptions combine these two usages.

A DIS item is to indicate the medication has been dispensed. It's useful to pharmacists to determine if a prescription may still be dispensed.

A PADV item is used to modify the content or the status, or to comment the previous items.
15 changes: 12 additions & 3 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,19 @@ nav:
- Transactions: transactions/index.md
- CDA-CH-EMED:
- cdachemed/index.md
- 'Dosage Instructions': cdachemed/dosage.md
- Packaging: cdachemed/packaging.md
- Documents:
- cdachemed/documents.md
- 'Dosage Instructions': cdachemed/dosage.md
- Packaging: cdachemed/packaging.md
- Workflow:
- cdachemed/workflow.md
- CH-APPC: chappc/index.md
- CH-EMED: chemed/index.md
markdown_extensions:
- smarty
# - smarty
- admonition
- attr_list
- md_in_html
- pymdownx.details
- pymdownx.inlinehilite
- pymdownx.snippets
Expand All @@ -29,6 +35,7 @@ theme:
- navigation.tabs
- navigation.indexes
- toc.integrate
- content.code.annotate
palette:
- scheme: slate
primary: blue
Expand All @@ -41,4 +48,6 @@ theme:
icon: material/toggle-switch
name: Switch to dark mode
#plugins:
# - minify:
# minify_html: true
# - privacy

0 comments on commit ba3d3a3

Please sign in to comment.