@natch-the-storage/heathershaw-platform-types 1.3.3 → 1.3.5

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.
@@ -138,9 +138,6 @@ export interface PartnerPharmacyProfile {
138
138
  xeroContactId?: string | null;
139
139
  }
140
140
  export type PartnerPharmacyProfileCreate = Omit<PartnerPharmacyProfile, "id">;
141
- export interface GetPatientRecordsQuery extends GetAll {
142
- partner_pharmacy_profile_id?: number;
143
- }
144
141
  export interface PatientRecord {
145
142
  id: number;
146
143
  partnerPharmacyProfileId?: number | null;
@@ -156,6 +153,7 @@ export interface PatientRecord {
156
153
  reminderEnabled?: boolean;
157
154
  scripts?: ScriptSelect[];
158
155
  orderHistory?: OrderSelect[];
156
+ relationship?: string | null;
159
157
  }
160
158
  export type PatientRecordCreate = Omit<PatientRecord, "id">;
161
159
  export interface Prescriber {
@@ -234,7 +232,7 @@ export declare const apiRoutes: {
234
232
  };
235
233
  patientRecords: {
236
234
  list: string;
237
- get: (id: number) => string;
235
+ get: (id?: number, type?: "partner" | "direct") => string;
238
236
  getByUser: (userId: string) => string;
239
237
  create: string;
240
238
  update: string;
@@ -19,100 +19,104 @@ export const repeatStorageValues = [
19
19
  ];
20
20
  export const scriptTypeValues = ["eRx", "PAPER"];
21
21
  export const shippingTypeValues = ["STANDARD", "COLD_CHAIN"];
22
- export const hazardTagsValues = ["Hazardous", "Cytotoxic", "High-Risk"];
22
+ export const hazardTagsValues = [
23
+ "Hazardous",
24
+ "Cytotoxic",
25
+ "High-Risk",
26
+ ];
23
27
  export const apiRoutes = {
24
28
  orders: {
25
- list: '/api/orders',
29
+ list: "/api/orders",
26
30
  get: (id) => `/api/orders/${id}`,
27
- create: '/api/orders',
28
- update: '/api/orders',
31
+ create: "/api/orders",
32
+ update: "/api/orders",
29
33
  delete: (id) => `/api/orders/${id}`,
30
34
  },
31
35
  patientRecords: {
32
- list: '/api/patient-records',
33
- get: (id) => `/api/patient-records/${id}`,
36
+ list: "/api/patient-records",
37
+ get: (id, type) => "/api/patient-records" + `${type ? "?" + type + "=" + id : ""}`,
34
38
  getByUser: (userId) => `/api/patient-records/user/${userId}`,
35
- create: '/api/patient-records',
36
- update: '/api/patient-records',
39
+ create: "/api/patient-records",
40
+ update: "/api/patient-records",
37
41
  delete: (id) => `/api/patient-records/${id}`,
38
42
  },
39
43
  prescribers: {
40
- list: '/api/prescribers',
44
+ list: "/api/prescribers",
41
45
  get: (id) => `/api/prescribers/${id}`,
42
- create: '/api/prescribers',
43
- update: '/api/prescribers',
46
+ create: "/api/prescribers",
47
+ update: "/api/prescribers",
44
48
  delete: (id) => `/api/prescribers/${id}`,
45
49
  },
46
50
  scripts: {
47
- list: '/api/scripts',
51
+ list: "/api/scripts",
48
52
  get: (id) => `/api/scripts/${id}`,
49
- create: '/api/scripts',
50
- update: '/api/scripts',
53
+ create: "/api/scripts",
54
+ update: "/api/scripts",
51
55
  delete: (id) => `/api/scripts/${id}`,
52
56
  },
53
57
  products: {
54
- list: '/api/products',
58
+ list: "/api/products",
55
59
  get: (id) => `/api/products/${id}`,
56
- create: '/api/products',
57
- update: '/api/products',
60
+ create: "/api/products",
61
+ update: "/api/products",
58
62
  delete: (id) => `/api/products/${id}`,
59
63
  },
60
64
  quotes: {
61
- list: '/api/quotes',
65
+ list: "/api/quotes",
62
66
  get: (id) => `/api/quotes/${id}`,
63
- create: '/api/quotes',
64
- update: '/api/quotes',
67
+ create: "/api/quotes",
68
+ update: "/api/quotes",
65
69
  delete: (id) => `/api/quotes/${id}`,
66
70
  },
67
71
  paperScriptReminders: {
68
- list: '/api/paper-script-reminders',
72
+ list: "/api/paper-script-reminders",
69
73
  get: (id) => `/api/paper-script-reminders/${id}`,
70
- create: '/api/paper-script-reminders',
71
- update: '/api/paper-script-reminders',
74
+ create: "/api/paper-script-reminders",
75
+ update: "/api/paper-script-reminders",
72
76
  delete: (id) => `/api/paper-script-reminders/${id}`,
73
77
  },
74
78
  repeatReminders: {
75
- list: '/api/reminders/repeats',
79
+ list: "/api/reminders/repeats",
76
80
  get: (id) => `/api/reminders/repeats/${id}`,
77
81
  history: (id) => `/api/reminders/repeats/${id}/history`,
78
- create: '/api/reminders/repeats',
79
- update: '/api/reminders/repeats',
82
+ create: "/api/reminders/repeats",
83
+ update: "/api/reminders/repeats",
80
84
  delete: (id) => `/api/reminders/repeats/${id}`,
81
85
  },
82
86
  priceMatches: {
83
- list: '/api/price-matches',
87
+ list: "/api/price-matches",
84
88
  get: (id) => `/api/price-matches/${id}`,
85
- create: '/api/price-matches',
86
- update: '/api/price-matches',
89
+ create: "/api/price-matches",
90
+ update: "/api/price-matches",
87
91
  delete: (id) => `/api/price-matches/${id}`,
88
92
  },
89
93
  directUserProfiles: {
90
- list: '/api/profiles/direct-users',
94
+ list: "/api/profiles/direct-users",
91
95
  get: (id) => `/api/profiles/direct-users/${id}`,
92
96
  getByUser: (userId) => `/api/profiles/direct-users/user/${userId}`,
93
- create: '/api/profiles/direct-users',
97
+ create: "/api/profiles/direct-users",
94
98
  onboard: (userId) => `/api/profiles/direct-users/${userId}`,
95
- update: '/api/profiles/direct-users',
99
+ update: "/api/profiles/direct-users",
96
100
  delete: (id) => `/api/profiles/direct-users/${id}`,
97
101
  },
98
102
  partnerPharmacyProfiles: {
99
- list: '/api/profiles/partner-pharmacies',
103
+ list: "/api/profiles/partner-pharmacies",
100
104
  get: (id) => `/api/profiles/partner-pharmacies/${id}`,
101
105
  getByUser: (userId) => `/api/profiles/partner-pharmacies/user/${userId}`,
102
- create: '/api/profiles/partner-pharmacies',
103
- update: '/api/profiles/partner-pharmacies',
106
+ create: "/api/profiles/partner-pharmacies",
107
+ update: "/api/profiles/partner-pharmacies",
104
108
  delete: (id) => `/api/profiles/partner-pharmacies/${id}`,
105
109
  },
106
110
  users: {
107
111
  data: (userId) => `/api/users/data/${userId}`,
108
112
  },
109
113
  uploads: {
110
- presign: '/api/uploads/presign',
111
- delete: '/api/uploads',
114
+ presign: "/api/uploads/presign",
115
+ delete: "/api/uploads",
112
116
  },
113
117
  sms: {
114
- twilioStatus: '/api/webhooks/twilio/status',
115
- send: '/api/reminders/sms',
118
+ twilioStatus: "/api/webhooks/twilio/status",
119
+ send: "/api/reminders/sms",
116
120
  },
117
121
  email: {},
118
122
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@natch-the-storage/heathershaw-platform-types",
3
- "version": "1.3.3",
3
+ "version": "1.3.5",
4
4
  "description": "Interfaces and routes to use on the client",
5
5
  "license": "ISC",
6
6
  "author": "Natch Surana",