hvp-shared 13.16.0 → 13.18.0

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.
@@ -0,0 +1,47 @@
1
+ /**
2
+ * Controlled Prescription (Receta cuantificada, Grupo I) Metadata
3
+ *
4
+ * Single source of truth for the controlled-substance metadata attached to a
5
+ * Product. Feeds the SITPV portal capture orientation and the monthly report.
6
+ * Shared because both backend (entity/service) and frontend (form/views) use it.
7
+ * See GH#425.
8
+ */
9
+ import { AdministrationRoute } from '../constants/administration-route.enums';
10
+ /**
11
+ * Patient profile for the portal Paso 2 (representative averages).
12
+ * NOTE: the male/female split is NOT stored per product — it's meaningless there.
13
+ * It's computed at receta-generation time (half/half over the purchased quantity).
14
+ */
15
+ export interface ControlledRxPatient {
16
+ weightKg: number;
17
+ ageMonths: number;
18
+ }
19
+ /**
20
+ * Treatment scheme for the portal Paso 3.
21
+ * - Periodicity is ALWAYS in hours, duration ALWAYS in days (portal-fixed units).
22
+ * - Both are empty when `singleDose` is true (one application, no recurrence).
23
+ */
24
+ export interface ControlledRxTreatment {
25
+ dose: string;
26
+ route: AdministrationRoute;
27
+ frequencyHours?: number;
28
+ durationDays?: number;
29
+ singleDose: boolean;
30
+ }
31
+ export interface ControlledRxInfo {
32
+ registro: string;
33
+ qvetName: string;
34
+ presentation: string;
35
+ species: 'CANINO' | 'FELINO';
36
+ /**
37
+ * true = el portal usa el formulario SIMPLIFICADO para este producto: solo pide
38
+ * "Tratamiento" (texto libre) + vía de administración, sin campos estructurados
39
+ * de dosis/periodicidad/duración (ej. SOFLORAN, GOTIKAS). En ese caso se captura
40
+ * el texto de tratamiento y la vía únicamente.
41
+ */
42
+ simplifiedForm: boolean;
43
+ patient: ControlledRxPatient;
44
+ treatment: ControlledRxTreatment;
45
+ factorL: number;
46
+ needsReview?: boolean;
47
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -16,3 +16,4 @@ export * from './coverage.types';
16
16
  export * from './job-promotion-stats.types';
17
17
  export * from './job-snapshot.types';
18
18
  export * from './employment-sections.types';
19
+ export * from './controlled-rx.types';
@@ -32,3 +32,4 @@ __exportStar(require("./coverage.types"), exports);
32
32
  __exportStar(require("./job-promotion-stats.types"), exports);
33
33
  __exportStar(require("./job-snapshot.types"), exports);
34
34
  __exportStar(require("./employment-sections.types"), exports);
35
+ __exportStar(require("./controlled-rx.types"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hvp-shared",
3
- "version": "13.16.0",
3
+ "version": "13.18.0",
4
4
  "description": "Shared types and utilities for HVP backend and frontend",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",