@awell-health/awell-extensions 2.0.132 → 2.0.133

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,18 +1,23 @@
1
1
  import * as z from 'zod';
2
+ export declare const bulletCategoryEnum: z.ZodEnum<["Problem", "Past", "Family", "Social", "Instr", "PE", "ROS", "Med", "Data", "Assessment", "Test", "Tx", "Narrative", "Followup", "Reason", "Plan", "Objective", "Hpi", "Allergies", "Habits", "Assessplan", "Consultant", "Attending", "Dateprocedure", "Surgical", "Orders", "Referenced", "Procedure"]>;
2
3
  export declare const bulletSchema: z.ZodObject<{
3
4
  id: z.ZodOptional<z.ZodNumber>;
4
5
  text: z.ZodString;
5
6
  author: z.ZodNumber;
6
- category: z.ZodDefault<z.ZodEnum<["Problem", "Past", "Family", "Social", "Instr", "PE", "ROS", "Med", "Data", "Assessment", "Test", "Tx", "Narrative", "Followup", "Reason", "Plan", "Objective", "Hpi", "Allergies", "Habits", "Assessplan", "Consultant", "Attending", "Dateprocedure", "Surgical", "Orders", "Referenced", "Procedure"]>>;
7
+ /**
8
+ * Hotfix, see https://awellhealth.slack.com/archives/C074XR57N0G/p1736802124866829
9
+ * TODO: Remove this once we have a proper solution for the category field
10
+ */
11
+ category: z.ZodOptional<z.ZodString>;
7
12
  }, "strip", z.ZodTypeAny, {
8
- category: "Reason" | "Past" | "Family" | "Social" | "Habits" | "Problem" | "Instr" | "PE" | "ROS" | "Med" | "Data" | "Assessment" | "Test" | "Tx" | "Narrative" | "Followup" | "Plan" | "Objective" | "Hpi" | "Allergies" | "Assessplan" | "Consultant" | "Attending" | "Dateprocedure" | "Surgical" | "Orders" | "Referenced" | "Procedure";
9
13
  text: string;
10
14
  author: number;
15
+ category?: string | undefined;
11
16
  id?: number | undefined;
12
17
  }, {
13
18
  text: string;
14
19
  author: number;
15
- category?: "Reason" | "Past" | "Family" | "Social" | "Habits" | "Problem" | "Instr" | "PE" | "ROS" | "Med" | "Data" | "Assessment" | "Test" | "Tx" | "Narrative" | "Followup" | "Plan" | "Objective" | "Hpi" | "Allergies" | "Assessplan" | "Consultant" | "Attending" | "Dateprocedure" | "Surgical" | "Orders" | "Referenced" | "Procedure" | undefined;
20
+ category?: string | undefined;
16
21
  id?: number | undefined;
17
22
  }>;
18
23
  export declare const nonVisitNoteSchema: z.ZodObject<{
@@ -21,16 +26,20 @@ export declare const nonVisitNoteSchema: z.ZodObject<{
21
26
  id: z.ZodOptional<z.ZodNumber>;
22
27
  text: z.ZodString;
23
28
  author: z.ZodNumber;
24
- category: z.ZodDefault<z.ZodEnum<["Problem", "Past", "Family", "Social", "Instr", "PE", "ROS", "Med", "Data", "Assessment", "Test", "Tx", "Narrative", "Followup", "Reason", "Plan", "Objective", "Hpi", "Allergies", "Habits", "Assessplan", "Consultant", "Attending", "Dateprocedure", "Surgical", "Orders", "Referenced", "Procedure"]>>;
29
+ /**
30
+ * Hotfix, see https://awellhealth.slack.com/archives/C074XR57N0G/p1736802124866829
31
+ * TODO: Remove this once we have a proper solution for the category field
32
+ */
33
+ category: z.ZodOptional<z.ZodString>;
25
34
  }, "strip", z.ZodTypeAny, {
26
- category: "Reason" | "Past" | "Family" | "Social" | "Habits" | "Problem" | "Instr" | "PE" | "ROS" | "Med" | "Data" | "Assessment" | "Test" | "Tx" | "Narrative" | "Followup" | "Plan" | "Objective" | "Hpi" | "Allergies" | "Assessplan" | "Consultant" | "Attending" | "Dateprocedure" | "Surgical" | "Orders" | "Referenced" | "Procedure";
27
35
  text: string;
28
36
  author: number;
37
+ category?: string | undefined;
29
38
  id?: number | undefined;
30
39
  }, {
31
40
  text: string;
32
41
  author: number;
33
- category?: "Reason" | "Past" | "Family" | "Social" | "Habits" | "Problem" | "Instr" | "PE" | "ROS" | "Med" | "Data" | "Assessment" | "Test" | "Tx" | "Narrative" | "Followup" | "Plan" | "Objective" | "Hpi" | "Allergies" | "Assessplan" | "Consultant" | "Attending" | "Dateprocedure" | "Surgical" | "Orders" | "Referenced" | "Procedure" | undefined;
42
+ category?: string | undefined;
34
43
  id?: number | undefined;
35
44
  }>, "many">;
36
45
  patient: z.ZodNumber;
@@ -45,9 +54,9 @@ export declare const nonVisitNoteSchema: z.ZodObject<{
45
54
  patient: number;
46
55
  document_date: string;
47
56
  bullets: {
48
- category: "Reason" | "Past" | "Family" | "Social" | "Habits" | "Problem" | "Instr" | "PE" | "ROS" | "Med" | "Data" | "Assessment" | "Test" | "Tx" | "Narrative" | "Followup" | "Plan" | "Objective" | "Hpi" | "Allergies" | "Assessplan" | "Consultant" | "Attending" | "Dateprocedure" | "Surgical" | "Orders" | "Referenced" | "Procedure";
49
57
  text: string;
50
58
  author: number;
59
+ category?: string | undefined;
51
60
  id?: number | undefined;
52
61
  }[];
53
62
  chart_date: string;
@@ -61,7 +70,7 @@ export declare const nonVisitNoteSchema: z.ZodObject<{
61
70
  bullets: {
62
71
  text: string;
63
72
  author: number;
64
- category?: "Reason" | "Past" | "Family" | "Social" | "Habits" | "Problem" | "Instr" | "PE" | "ROS" | "Med" | "Data" | "Assessment" | "Test" | "Tx" | "Narrative" | "Followup" | "Plan" | "Objective" | "Hpi" | "Allergies" | "Assessplan" | "Consultant" | "Attending" | "Dateprocedure" | "Surgical" | "Orders" | "Referenced" | "Procedure" | undefined;
73
+ category?: string | undefined;
65
74
  id?: number | undefined;
66
75
  }[];
67
76
  chart_date: Date;
@@ -33,12 +33,12 @@ var __importStar = (this && this.__importStar) || (function () {
33
33
  };
34
34
  })();
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
- exports.nonVisitNoteSchema = exports.bulletSchema = void 0;
36
+ exports.nonVisitNoteSchema = exports.bulletSchema = exports.bulletCategoryEnum = void 0;
37
37
  const z = __importStar(require("zod"));
38
38
  const extensions_core_1 = require("@awell-health/extensions-core");
39
39
  const nonVisitNoteTypeEnum = z.enum(['email', 'nonvisit', 'phone']);
40
40
  // All values taken from Elation's API
41
- const bulletCategoryEnum = z.enum([
41
+ exports.bulletCategoryEnum = z.enum([
42
42
  'Problem',
43
43
  'Past',
44
44
  'Family',
@@ -70,9 +70,14 @@ const bulletCategoryEnum = z.enum([
70
70
  ]);
71
71
  exports.bulletSchema = z.object({
72
72
  id: extensions_core_1.NumericIdSchema.optional(),
73
- text: z.string().nonempty(),
73
+ text: z.string().min(1),
74
74
  author: extensions_core_1.NumericIdSchema,
75
- category: bulletCategoryEnum.default(bulletCategoryEnum.enum.Problem),
75
+ /**
76
+ * Hotfix, see https://awellhealth.slack.com/archives/C074XR57N0G/p1736802124866829
77
+ * TODO: Remove this once we have a proper solution for the category field
78
+ */
79
+ // category: bulletCategoryEnum.default(bulletCategoryEnum.enum.Problem),
80
+ category: z.string().optional(),
76
81
  });
77
82
  exports.nonVisitNoteSchema = z.object({
78
83
  type: nonVisitNoteTypeEnum.default(nonVisitNoteTypeEnum.enum.nonvisit),
@@ -1 +1 @@
1
- {"version":3,"file":"nonVisitNote.zod.js","sourceRoot":"","sources":["../../../../extensions/elation/validation/nonVisitNote.zod.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,uCAAwB;AACxB,mEAIsC;AAEtC,MAAM,oBAAoB,GAAG,CAAC,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,UAAU,EAAE,OAAO,CAAC,CAAC,CAAA;AAEnE,sCAAsC;AACtC,MAAM,kBAAkB,GAAG,CAAC,CAAC,IAAI,CAAC;IAChC,SAAS;IACT,MAAM;IACN,QAAQ;IACR,QAAQ;IACR,OAAO;IACP,IAAI;IACJ,KAAK;IACL,KAAK;IACL,MAAM;IACN,YAAY;IACZ,MAAM;IACN,IAAI;IACJ,WAAW;IACX,UAAU;IACV,QAAQ;IACR,MAAM;IACN,WAAW;IACX,KAAK;IACL,WAAW;IACX,QAAQ;IACR,YAAY;IACZ,YAAY;IACZ,WAAW;IACX,eAAe;IACf,UAAU;IACV,QAAQ;IACR,YAAY;IACZ,WAAW;CACZ,CAAC,CAAA;AAEW,QAAA,YAAY,GAAG,CAAC,CAAC,MAAM,CAAC;IACnC,EAAE,EAAE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packageManager": "yarn@4.5.3",
5
5
  "main": "dist/src/index.js",
6
6
  "repository": {