@tekkare/romulus 0.1.280 → 0.1.282
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/module.json +1 -1
- package/layer/app/components/oip-drugs/fiches/AssociationFiche.vue +78 -3
- package/layer/app/components/oip-drugs/heart/associations/NationalAssemblyAmendmentCard.vue +308 -0
- package/layer/app/components/oip-italy/AifaAct.vue +27 -206
- package/layer/app/components/oip-italy/AifaBrandFiche.vue +369 -0
- package/layer/app/components/oip-italy/BrandPrices.vue +247 -0
- package/layer/app/oip-drugs/composables/useAssociationDetail.ts +20 -4
- package/layer/app/oip-drugs/esIndices.ts +2 -0
- package/layer/app/oip-drugs/locales/en.json +21 -3
- package/layer/app/oip-drugs/locales/fr.json +21 -3
- package/layer/app/oip-drugs/utils/associationFields.ts +92 -0
- package/layer/app/oip-italy/useAifaSource.ts +47 -0
- package/layer/app/utils/italyApprovals.ts +92 -0
- package/layer/server/api/oip/pdf.get.ts +2 -0
- package/package.json +1 -1
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
// Actes reglementaires de l'AIFA (it__drug_opinion__aifa) : forme d'un acte,
|
|
2
|
+
// libelles et schema d'export, communs a la fiche marque du layer
|
|
3
|
+
// (components/oip-italy) et aux pages d'Italy One.
|
|
4
|
+
//
|
|
5
|
+
// `tekkare_pdf_url` porte le meme lien tronque sur tous les documents :
|
|
6
|
+
// `aifa_url` est le seul lien utilisable.
|
|
7
|
+
|
|
8
|
+
export type OpinionDoc = {
|
|
9
|
+
opinion_id: string;
|
|
10
|
+
document_type: string;
|
|
11
|
+
has_code: string;
|
|
12
|
+
decision_date: string;
|
|
13
|
+
brand: string;
|
|
14
|
+
molecule: string;
|
|
15
|
+
company: string;
|
|
16
|
+
atc5_code: string;
|
|
17
|
+
nature_of_request: string;
|
|
18
|
+
nature_of_request_en: string;
|
|
19
|
+
theme: string;
|
|
20
|
+
theme_en: string;
|
|
21
|
+
indication: string;
|
|
22
|
+
indication_en: string;
|
|
23
|
+
essential: string;
|
|
24
|
+
essential_en: string;
|
|
25
|
+
aifa_url: string;
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
export const OPINION_FIELDS = [
|
|
29
|
+
"opinion_id",
|
|
30
|
+
"document_type",
|
|
31
|
+
"has_code",
|
|
32
|
+
"decision_date",
|
|
33
|
+
"brand",
|
|
34
|
+
"molecule",
|
|
35
|
+
"company",
|
|
36
|
+
"atc5_code",
|
|
37
|
+
"nature_of_request",
|
|
38
|
+
"nature_of_request_en",
|
|
39
|
+
"theme",
|
|
40
|
+
"theme_en",
|
|
41
|
+
"indication",
|
|
42
|
+
"indication_en",
|
|
43
|
+
"essential",
|
|
44
|
+
"essential_en",
|
|
45
|
+
"aifa_url",
|
|
46
|
+
];
|
|
47
|
+
|
|
48
|
+
// Le texte d'un acte tel que le lecteur le voit : la traduction DeepL quand
|
|
49
|
+
// elle existe, l'original italien sinon (essential_en reste vide, ou vaut
|
|
50
|
+
// « None », une fois le quota mensuel de traduction epuise).
|
|
51
|
+
export const essentialOf = (x: { essential_en?: string; essential?: string } | null) =>
|
|
52
|
+
(x?.essential_en && x.essential_en !== "None" ? x.essential_en : "") || x?.essential || "";
|
|
53
|
+
|
|
54
|
+
// Les cinq canaux de publication du portail Trovanorme, nommes comme lui
|
|
55
|
+
// (detGU / modSecFar / detTNF / docAIFA / news).
|
|
56
|
+
export const DOCUMENT_TYPES = [
|
|
57
|
+
{ code: "GU", label: "Gazzetta Ufficiale" },
|
|
58
|
+
{ code: "MSF", label: "Modifiche secondarie di farmaci" },
|
|
59
|
+
{ code: "TNF", label: "Testi normativi farmaceutici" },
|
|
60
|
+
{ code: "AIFA", label: "Documenti AIFA" },
|
|
61
|
+
{ code: "NEWS", label: "News" },
|
|
62
|
+
];
|
|
63
|
+
|
|
64
|
+
export const documentTypeLabel = (code: string) =>
|
|
65
|
+
DOCUMENT_TYPES.find((x) => x.code === code)?.label ?? (code || "-");
|
|
66
|
+
|
|
67
|
+
// "MUSCULO-SKELETAL SYSTEM" -> "Musculo-skeletal system"
|
|
68
|
+
export function titleCase(value: string) {
|
|
69
|
+
const clean = (value ?? "").trim();
|
|
70
|
+
if (!clean) return "";
|
|
71
|
+
return clean.charAt(0).toUpperCase() + clean.slice(1).toLowerCase();
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
const day = (value?: string) => (value ?? "").slice(0, 10);
|
|
75
|
+
|
|
76
|
+
/** Colonnes d'export d'un acte, partagees par la fiche marque et les pages d'Italy One. */
|
|
77
|
+
export function actSheetSchema(fr: boolean) {
|
|
78
|
+
return [
|
|
79
|
+
{ column: fr ? "Date de décision" : "Decision date", type: String, value: (x: OpinionDoc) => day(x.decision_date) },
|
|
80
|
+
{ column: fr ? "Marque" : "Brand", type: String, width: 25, value: (x: OpinionDoc) => x.brand },
|
|
81
|
+
{ column: fr ? "Molécule" : "Molecule", type: String, width: 35, value: (x: OpinionDoc) => x.molecule },
|
|
82
|
+
{ column: fr ? "Laboratoire" : "Company", type: String, width: 35, value: (x: OpinionDoc) => x.company },
|
|
83
|
+
{ column: "ATC5", type: String, value: (x: OpinionDoc) => x.atc5_code },
|
|
84
|
+
{ column: fr ? "Nature de la demande" : "Nature of request", type: String, width: 30, value: (x: OpinionDoc) => x.nature_of_request_en },
|
|
85
|
+
{ column: fr ? "Aire thérapeutique" : "Therapeutic area", type: String, width: 35, value: (x: OpinionDoc) => x.theme_en },
|
|
86
|
+
{ column: fr ? "Type de document" : "Document type", type: String, value: (x: OpinionDoc) => x.document_type },
|
|
87
|
+
{ column: fr ? "Code du document" : "Document code", type: String, value: (x: OpinionDoc) => x.has_code },
|
|
88
|
+
{ column: "Indication", type: String, width: 80, value: (x: OpinionDoc) => x.indication_en },
|
|
89
|
+
{ column: fr ? "Texte (IT)" : "Text (IT)", type: String, width: 100, value: (x: OpinionDoc) => x.essential },
|
|
90
|
+
{ column: fr ? "Lien AIFA" : "AIFA link", type: String, width: 60, value: (x: OpinionDoc) => x.aifa_url },
|
|
91
|
+
];
|
|
92
|
+
}
|
|
@@ -23,6 +23,8 @@ const ALLOWED_HOSTS = new Set([
|
|
|
23
23
|
"ansm.sante.fr",
|
|
24
24
|
"has-sante.fr",
|
|
25
25
|
"www.has-sante.fr",
|
|
26
|
+
// Amendements de l'Assemblee nationale (`<url de l'amendement>.pdf`).
|
|
27
|
+
"www.assemblee-nationale.fr",
|
|
26
28
|
]);
|
|
27
29
|
|
|
28
30
|
const PASS_THROUGH = ["content-length", "content-range", "accept-ranges", "etag", "last-modified"];
|