-
Notifications
You must be signed in to change notification settings - Fork 61
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(j-s): Update substances and combine drugs and prescribed medica…
…tion lists
- Loading branch information
1 parent
504f520
commit 7802db8
Showing
5 changed files
with
121 additions
and
87 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,101 +1,24 @@ | ||
import { | ||
ILLEGAL_DRUGS_AND_PRESCRIPTION_DRUGS_DRIVING, | ||
Substance, | ||
} from './substances' | ||
|
||
export enum IndictmentCountOffense { | ||
DRIVING_WITHOUT_LICENCE = 'DRIVING_WITHOUT_LICENCE', | ||
DRUNK_DRIVING = 'DRUNK_DRIVING', | ||
ILLEGAL_DRUGS_DRIVING = 'ILLEGAL_DRUGS_DRIVING', | ||
PRESCRIPTION_DRUGS_DRIVING = 'PRESCRIPTION_DRUGS_DRIVING', | ||
} | ||
|
||
export enum Substance { | ||
ALCOHOL = 'ALCOHOL', | ||
AMPHETAMINE = 'AMPHETAMINE', | ||
ETIZOLAM = 'ETIZOLAM', | ||
PHENAZEPAM = 'PHENAZEPAM', | ||
KETAMINE = 'KETAMINE', | ||
KETOBEMIDONE = 'KETOBEMIDONE', | ||
COCAINE = 'COCAINE', | ||
MDMA = 'MDMA', | ||
METHAMPHETAMINE = 'METHAMPHETAMINE', | ||
METHYLPHENIDATE = 'METHYLPHENIDATE', | ||
O_DESMETHYLTRAMADOL = 'O_DESMETHYLTRAMADOL', | ||
TETRAHYDROCANNABINOL = 'TETRAHYDROCANNABINOL', | ||
TRAMADOL = 'TRAMADOL', | ||
ZOPICLONE = 'ZOPICLONE', | ||
ALPRAZOLAM = 'ALPRAZOLAM', | ||
BROMAZEPAM = 'BROMAZEPAM', | ||
BUPRENORPHINE = 'BUPRENORPHINE', | ||
DEMOXEAPAM = 'DEMOXEAPAM', | ||
DESMETHYLCHLORDIAZEPOXIDE = 'DESMETHYLCHLORDIAZEPOXIDE', | ||
DIAZEPAM = 'DIAZEPAM', | ||
FENTANYL = 'FENTANYL', | ||
FLUNITRAZEPAM = 'FLUNITRAZEPAM', | ||
GABAPENTIN = 'GABAPENTIN', | ||
CLONAZEPAM = 'CLONAZEPAM', | ||
CHLORDIAZEPOXIDE = 'CHLORDIAZEPOXIDE', | ||
CODEINE = 'CODEINE', | ||
LORAZEPAM = 'LORAZEPAM', | ||
METHADONE = 'METHADONE', | ||
MIDAZOLAM = 'MIDAZOLAM', | ||
MORPHINE = 'MORPHINE', | ||
NITRAZEPAM = 'NITRAZEPAM', | ||
NORBUPRENORPHINE = 'NORBUPRENORPHINE', | ||
NORDIAZEPAM = 'NORDIAZEPAM', | ||
OXAZEPAM = 'OXAZEPAM', | ||
OXYCODONE = 'OXYCODONE', | ||
PREGABALIN = 'PREGABALIN', | ||
QUETIAPINE = 'QUETIAPINE', | ||
TEMAZEPAM = 'TEMAZEPAM', | ||
TRIAZOLAM = 'TRIAZOLAM', | ||
ZOLPIDEM = 'ZOLPIDEM', | ||
} | ||
|
||
export type SubstanceMap = { [key in Substance]?: string } | ||
|
||
export const offenseSubstances: { | ||
[key in IndictmentCountOffense]: Substance[] | ||
} = { | ||
[IndictmentCountOffense.DRIVING_WITHOUT_LICENCE]: [], | ||
[IndictmentCountOffense.DRUNK_DRIVING]: [Substance.ALCOHOL], | ||
[IndictmentCountOffense.ILLEGAL_DRUGS_DRIVING]: [ | ||
Substance.AMPHETAMINE, | ||
Substance.ETIZOLAM, | ||
Substance.PHENAZEPAM, | ||
Substance.KETAMINE, | ||
Substance.KETOBEMIDONE, | ||
Substance.COCAINE, | ||
Substance.MDMA, | ||
Substance.METHAMPHETAMINE, | ||
Substance.METHYLPHENIDATE, | ||
Substance.O_DESMETHYLTRAMADOL, | ||
Substance.TETRAHYDROCANNABINOL, | ||
Substance.TRAMADOL, | ||
Substance.ZOPICLONE, | ||
], | ||
[IndictmentCountOffense.PRESCRIPTION_DRUGS_DRIVING]: [ | ||
Substance.ALPRAZOLAM, | ||
Substance.BROMAZEPAM, | ||
Substance.BUPRENORPHINE, | ||
Substance.DEMOXEAPAM, | ||
Substance.DESMETHYLCHLORDIAZEPOXIDE, | ||
Substance.DIAZEPAM, | ||
Substance.FENTANYL, | ||
Substance.FLUNITRAZEPAM, | ||
Substance.GABAPENTIN, | ||
Substance.CLONAZEPAM, | ||
Substance.CHLORDIAZEPOXIDE, | ||
Substance.CODEINE, | ||
Substance.LORAZEPAM, | ||
Substance.METHADONE, | ||
Substance.MIDAZOLAM, | ||
Substance.MORPHINE, | ||
Substance.NITRAZEPAM, | ||
Substance.NORBUPRENORPHINE, | ||
Substance.NORDIAZEPAM, | ||
Substance.OXAZEPAM, | ||
Substance.OXYCODONE, | ||
Substance.PREGABALIN, | ||
Substance.QUETIAPINE, | ||
Substance.TEMAZEPAM, | ||
Substance.TRIAZOLAM, | ||
Substance.ZOLPIDEM, | ||
], | ||
[IndictmentCountOffense.ILLEGAL_DRUGS_DRIVING]: | ||
ILLEGAL_DRUGS_AND_PRESCRIPTION_DRUGS_DRIVING, | ||
[IndictmentCountOffense.PRESCRIPTION_DRUGS_DRIVING]: | ||
ILLEGAL_DRUGS_AND_PRESCRIPTION_DRUGS_DRIVING, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
export enum Substance { | ||
ALCOHOL = 'ALCOHOL', | ||
ALPRAZOLAM = 'ALPRAZOLAM', | ||
AMPHETAMINE = 'AMPHETAMINE', | ||
BROMAZEPAM = 'BROMAZEPAM', | ||
BROMAZOLAM = 'BROMAZOLAM', | ||
BUPRENORPHINE = 'BUPRENORPHINE', | ||
CHLORDIAZEPOXIDE = 'CHLORDIAZEPOXIDE', | ||
CLONAZEPAM = 'CLONAZEPAM', | ||
COCAINE = 'COCAINE', | ||
CODEINE = 'CODEINE', | ||
DEMOXEAPAM = 'DEMOXEAPAM', | ||
DESMETHYLCHLORDIAZEPOXIDE = 'DESMETHYLCHLORDIAZEPOXIDE', | ||
DIAZEPAM = 'DIAZEPAM', | ||
ETIZOLAM = 'ETIZOLAM', | ||
FENTANYL = 'FENTANYL', | ||
FLUALPRAZOLAM = 'FLUALPRAZOLAM', | ||
FLUNITRAZEPAM = 'FLUNITRAZEPAM', | ||
GABAPENTIN = 'GABAPENTIN', | ||
KETAMINE = 'KETAMINE', | ||
KETOBEMIDONE = 'KETOBEMIDONE', | ||
LORAZEPAM = 'LORAZEPAM', | ||
MDMA = 'MDMA', | ||
METHADONE = 'METHADONE', | ||
METHAMPHETAMINE = 'METHAMPHETAMINE', | ||
METHYLPHENIDATE = 'METHYLPHENIDATE', | ||
MIDAZOLAM = 'MIDAZOLAM', | ||
MORPHINE = 'MORPHINE', | ||
NITRAZEPAM = 'NITRAZEPAM', | ||
NORBUPRENORPHINE = 'NORBUPRENORPHINE', | ||
NORDIAZEPAM = 'NORDIAZEPAM', | ||
O_DESMETHYLTRAMADOL = 'O_DESMETHYLTRAMADOL', | ||
OXAZEPAM = 'OXAZEPAM', | ||
OXYCODONE = 'OXYCODONE', | ||
PHENAZEPAM = 'PHENAZEPAM', | ||
PREGABALIN = 'PREGABALIN', | ||
QUETIAPINE = 'QUETIAPINE', | ||
TEMAZEPAM = 'TEMAZEPAM', | ||
TETRAHYDROCANNABINOL = 'TETRAHYDROCANNABINOL', | ||
TRAMADOL = 'TRAMADOL', | ||
TRIAZOLAM = 'TRIAZOLAM', | ||
ZOLPIDEM = 'ZOLPIDEM', | ||
ZOPICLONE = 'ZOPICLONE', | ||
} | ||
|
||
export const ILLEGAL_DRUGS_AND_PRESCRIPTION_DRUGS_DRIVING = [ | ||
Substance.AMPHETAMINE, | ||
Substance.ALPRAZOLAM, | ||
Substance.BROMAZEPAM, | ||
Substance.BROMAZOLAM, | ||
Substance.BUPRENORPHINE, | ||
Substance.CHLORDIAZEPOXIDE, | ||
Substance.CLONAZEPAM, | ||
Substance.COCAINE, | ||
Substance.CODEINE, | ||
Substance.DEMOXEAPAM, | ||
Substance.DESMETHYLCHLORDIAZEPOXIDE, | ||
Substance.DIAZEPAM, | ||
Substance.ETIZOLAM, | ||
Substance.FENTANYL, | ||
Substance.FLUALPRAZOLAM, | ||
Substance.FLUNITRAZEPAM, | ||
Substance.GABAPENTIN, | ||
Substance.KETAMINE, | ||
Substance.KETOBEMIDONE, | ||
Substance.LORAZEPAM, | ||
Substance.MDMA, | ||
Substance.METHADONE, | ||
Substance.METHAMPHETAMINE, | ||
Substance.METHYLPHENIDATE, | ||
Substance.MIDAZOLAM, | ||
Substance.MORPHINE, | ||
Substance.NITRAZEPAM, | ||
Substance.NORBUPRENORPHINE, | ||
Substance.NORDIAZEPAM, | ||
Substance.O_DESMETHYLTRAMADOL, | ||
Substance.OXAZEPAM, | ||
Substance.OXYCODONE, | ||
Substance.PHENAZEPAM, | ||
Substance.PREGABALIN, | ||
Substance.QUETIAPINE, | ||
Substance.TEMAZEPAM, | ||
Substance.TETRAHYDROCANNABINOL, | ||
Substance.TRAMADOL, | ||
Substance.TRIAZOLAM, | ||
Substance.ZOLPIDEM, | ||
Substance.ZOPICLONE, | ||
] |