@bahmni/appointments-app 0.0.1-dev.265 → 0.0.1-dev.267
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/{DocumentsTable-CTpGjHXi-DaIYOjsy.js → DocumentsTable-B5KzNxpE-CUSNylHl.js} +1 -1
- package/dist/{FormsTable-BIz1A-5g-Br7XXz78.js → FormsTable-E-Ya0wBK-IfmNlxVm.js} +21 -21
- package/dist/{LNWAZHJI-CNpGrcrh.js → LNWAZHJI-DR-n1eVc.js} +2 -2
- package/dist/{MWZ6AO7Z-Bc1dOC2R.js → MWZ6AO7Z-emQ-_7WP.js} +2 -2
- package/dist/{Observations-Cf7HY6Zc-Dq0gq0mO.js → Observations-DO36Czp5-BRurfsiy.js} +6 -6
- package/dist/{YPM2AS64-CcAuIkxI.js → YPM2AS64-3NniT021.js} +1 -1
- package/dist/{index-ZYiZcEk7.js → index-4jqbsDOS.js} +19 -19
- package/dist/index-BXvg2o0e.js +630 -0
- package/dist/{index-Ck1OwLu_.js → index-Dd5zlHOS.js} +68440 -62942
- package/dist/index.css +1 -1
- package/dist/index.js +1 -1
- package/dist/locales/locale_en.json +43 -0
- package/dist/locales/locale_es.json +44 -0
- package/dist/pages/admin/appointmentUnavailability/__mocks__/unavailabilityMock.d.ts +23 -0
- package/dist/pages/admin/appointmentUnavailability/__mocks__/unavailabilityMock.d.ts.map +1 -0
- package/dist/pages/admin/appointmentUnavailability/components/UnavailabilityForm.d.ts +10 -0
- package/dist/pages/admin/appointmentUnavailability/components/UnavailabilityForm.d.ts.map +1 -0
- package/dist/pages/admin/appointmentUnavailability/constants.d.ts +5 -0
- package/dist/pages/admin/appointmentUnavailability/constants.d.ts.map +1 -0
- package/dist/pages/admin/appointmentUnavailability/hook.d.ts +10 -0
- package/dist/pages/admin/appointmentUnavailability/hook.d.ts.map +1 -0
- package/dist/pages/admin/appointmentUnavailability/index.d.ts +4 -0
- package/dist/pages/admin/appointmentUnavailability/index.d.ts.map +1 -0
- package/dist/pages/admin/appointmentUnavailability/models.d.ts +46 -0
- package/dist/pages/admin/appointmentUnavailability/models.d.ts.map +1 -0
- package/dist/pages/admin/appointmentUnavailability/utils.d.ts +23 -0
- package/dist/pages/admin/appointmentUnavailability/utils.d.ts.map +1 -0
- package/dist/routes/index.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as r, jsxs as p, Fragment as Y } from "react/jsx-runtime";
|
|
2
|
-
import { d as K, u as Q, a as W, b as J, c as X, m as Z, e as ee, r as te, F as ae } from "./index-
|
|
2
|
+
import { d as K, u as Q, a as W, b as J, c as X, m as Z, e as ee, r as te, F as ae } from "./index-Dd5zlHOS.js";
|
|
3
3
|
import { useState as m, useCallback as h, useEffect as f, useMemo as T } from "react";
|
|
4
4
|
const ne = "_documentsTableBody_1voj8_1", oe = "_viewAttachmentsLink_1voj8_11", re = "_documentViewerContainer_1voj8_15", de = "_attachmentItem_1voj8_23", se = "_attachmentCounter_1voj8_27", ce = "_attachmentError_1voj8_36", ie = "_documentIframe_1voj8_44", me = "_documentImage_1voj8_50", d = {
|
|
5
5
|
documentsTableBody: ne,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as s, jsxs as J, Fragment as W } from "react/jsx-runtime";
|
|
2
|
-
import { u as Z, d as ee, f as re, g as ae, b as c, X as te, R as
|
|
2
|
+
import { u as Z, d as ee, f as re, g as ae, b as c, X as te, R as v, m as oe, c as se, e as U, A as ne, _ as de, r as ie, Y as ue, I as me, j as le, B as ce, P as fe, k as ye } from "./index-Dd5zlHOS.js";
|
|
3
3
|
import { useState as S, useMemo as d, useCallback as f } from "react";
|
|
4
|
-
const pe = "_formsTableBody_ourq9_5", be = "_customAccordianItem_ourq9_10",
|
|
4
|
+
const pe = "_formsTableBody_ourq9_5", be = "_customAccordianItem_ourq9_10", A = {
|
|
5
5
|
formsTableBody: pe,
|
|
6
6
|
customAccordianItem: be
|
|
7
7
|
}, ge = (u) => u ? u.extension?.find(
|
|
@@ -14,12 +14,12 @@ const pe = "_formsTableBody_ourq9_5", be = "_customAccordianItem_ourq9_10", I =
|
|
|
14
14
|
const { t: o } = Z(), m = ee(), [l, h] = S(!1), [t, O] = S(null), { numberOfVisits: k, hideThumbnail: j = !1 } = C ?? {}, B = re(
|
|
15
15
|
u,
|
|
16
16
|
n
|
|
17
|
-
),
|
|
17
|
+
), H = ae(), {
|
|
18
18
|
data: y = [],
|
|
19
19
|
isLoading: _,
|
|
20
20
|
isError: E,
|
|
21
|
-
error:
|
|
22
|
-
refetch:
|
|
21
|
+
error: K,
|
|
22
|
+
refetch: x
|
|
23
23
|
} = c({
|
|
24
24
|
queryKey: ["forms", m, u],
|
|
25
25
|
queryFn: () => le(m, void 0, k),
|
|
@@ -55,7 +55,7 @@ const pe = "_formsTableBody_ourq9_5", be = "_customAccordianItem_ourq9_10", I =
|
|
|
55
55
|
});
|
|
56
56
|
te(
|
|
57
57
|
(e) => {
|
|
58
|
-
e.patientUUID === m && e.updatedConcepts.size > 0 && (
|
|
58
|
+
e.patientUUID === m && e.updatedConcepts.size > 0 && (x(), H.invalidateQueries({ queryKey: ["formsEncounterFHIR"] }));
|
|
59
59
|
},
|
|
60
60
|
[m]
|
|
61
61
|
);
|
|
@@ -64,9 +64,9 @@ const pe = "_formsTableBody_ourq9_5", be = "_customAccordianItem_ourq9_10", I =
|
|
|
64
64
|
return !r || r.includes(t.formName);
|
|
65
65
|
}), [g, t?.formName]), Y = d(() => {
|
|
66
66
|
if (b)
|
|
67
|
-
return
|
|
67
|
+
return v(b).message;
|
|
68
68
|
if (N)
|
|
69
|
-
return
|
|
69
|
+
return v(N).message;
|
|
70
70
|
}, [b, N]), L = d(
|
|
71
71
|
() => [
|
|
72
72
|
{ key: "recordedOn", header: o("RECORDED_ON") },
|
|
@@ -84,12 +84,12 @@ const pe = "_formsTableBody_ourq9_5", be = "_customAccordianItem_ourq9_10", I =
|
|
|
84
84
|
(r, a) => {
|
|
85
85
|
const i = a.formName;
|
|
86
86
|
r[i] ??= [];
|
|
87
|
-
const
|
|
87
|
+
const I = a.providers.map((X) => X.providerName).filter(Boolean).join(", ");
|
|
88
88
|
return r[i].push({
|
|
89
89
|
id: a.encounterUuid,
|
|
90
90
|
formName: a.formName,
|
|
91
91
|
recordedOn: oe(a.encounterDateTime, o, !0).formattedResult,
|
|
92
|
-
recordedBy:
|
|
92
|
+
recordedBy: I ?? "--",
|
|
93
93
|
encounterDateTime: a.encounterDateTime,
|
|
94
94
|
encounterUuid: a.encounterUuid
|
|
95
95
|
}), r;
|
|
@@ -100,26 +100,26 @@ const pe = "_formsTableBody_ourq9_5", be = "_customAccordianItem_ourq9_10", I =
|
|
|
100
100
|
([r, a]) => ({
|
|
101
101
|
formName: r,
|
|
102
102
|
records: a.sort(
|
|
103
|
-
(i,
|
|
103
|
+
(i, I) => I.encounterDateTime - i.encounterDateTime
|
|
104
104
|
)
|
|
105
105
|
})
|
|
106
106
|
).sort((r, a) => r.formName.localeCompare(a.formName));
|
|
107
|
-
}, [T, o]),
|
|
107
|
+
}, [T, o]), D = f((e) => {
|
|
108
108
|
O(e), h(!0);
|
|
109
109
|
}, []), G = f(() => {
|
|
110
110
|
h(!1), O(null);
|
|
111
|
-
}, []),
|
|
111
|
+
}, []), q = f(
|
|
112
112
|
(e, r) => {
|
|
113
113
|
switch (r) {
|
|
114
114
|
case "recordedOn":
|
|
115
|
-
return /* @__PURE__ */ s(se, { onClick: () =>
|
|
115
|
+
return /* @__PURE__ */ s(se, { onClick: () => D(e), children: e.recordedOn });
|
|
116
116
|
case "recordedBy":
|
|
117
117
|
return e.recordedBy;
|
|
118
118
|
default:
|
|
119
119
|
return null;
|
|
120
120
|
}
|
|
121
121
|
},
|
|
122
|
-
[
|
|
122
|
+
[D]
|
|
123
123
|
);
|
|
124
124
|
return /* @__PURE__ */ J(W, { children: [
|
|
125
125
|
/* @__PURE__ */ s("div", { id: "forms-table", "data-testid": "forms-table", children: _ || E || M.length === 0 || B ? /* @__PURE__ */ s(
|
|
@@ -129,10 +129,10 @@ const pe = "_formsTableBody_ourq9_5", be = "_customAccordianItem_ourq9_10", I =
|
|
|
129
129
|
ariaLabel: o("FORMS_HEADING"),
|
|
130
130
|
rows: [],
|
|
131
131
|
loading: _,
|
|
132
|
-
errorStateMessage: E ?
|
|
132
|
+
errorStateMessage: E ? K?.message : void 0,
|
|
133
133
|
emptyStateMessage: o("FORMS_UNAVAILABLE"),
|
|
134
|
-
renderCell:
|
|
135
|
-
className:
|
|
134
|
+
renderCell: q,
|
|
135
|
+
className: A.formsTableBody,
|
|
136
136
|
dataTestId: "forms-table"
|
|
137
137
|
}
|
|
138
138
|
) : /* @__PURE__ */ s(ne, { align: "start", children: M.map((e, r) => {
|
|
@@ -141,7 +141,7 @@ const pe = "_formsTableBody_ourq9_5", be = "_customAccordianItem_ourq9_10", I =
|
|
|
141
141
|
de,
|
|
142
142
|
{
|
|
143
143
|
title: a,
|
|
144
|
-
className:
|
|
144
|
+
className: A.customAccordianItem,
|
|
145
145
|
testId: `accordian-title-${a}`,
|
|
146
146
|
open: r === 0,
|
|
147
147
|
children: /* @__PURE__ */ s(
|
|
@@ -154,8 +154,8 @@ const pe = "_formsTableBody_ourq9_5", be = "_customAccordianItem_ourq9_10", I =
|
|
|
154
154
|
errorStateMessage: "",
|
|
155
155
|
sortable: z,
|
|
156
156
|
emptyStateMessage: o("FORMS_UNAVAILABLE"),
|
|
157
|
-
renderCell:
|
|
158
|
-
className:
|
|
157
|
+
renderCell: q,
|
|
158
|
+
className: A.formsTableBody,
|
|
159
159
|
dataTestId: `forms-table-${a}`
|
|
160
160
|
}
|
|
161
161
|
)
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { c, T as l, P as m, a as u, D as v, Q as i } from "./YPM2AS64-
|
|
2
|
-
import {
|
|
1
|
+
import { c, T as l, P as m, a as u, D as v, Q as i } from "./YPM2AS64-3NniT021.js";
|
|
2
|
+
import { ak as d, al as f, am as e } from "./index-Dd5zlHOS.js";
|
|
3
3
|
var p = (a) => {
|
|
4
4
|
const [r, t] = c({
|
|
5
5
|
prefix: "TanstackQueryDevtools"
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { c as s, T as c, P as u, a as i, b as m, C as P, Q as d } from "./YPM2AS64-
|
|
2
|
-
import {
|
|
1
|
+
import { c as s, T as c, P as u, a as i, b as m, C as P, Q as d } from "./YPM2AS64-3NniT021.js";
|
|
2
|
+
import { ak as v, al as C, am as e } from "./index-Dd5zlHOS.js";
|
|
3
3
|
var h = (t) => {
|
|
4
4
|
const [r, o] = s({
|
|
5
5
|
prefix: "TanstackQueryDevtools"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as I, jsx as u } from "react/jsx-runtime";
|
|
2
|
-
import { d as V, a as w, u as S, h as q, $ as G, b as H, X as Q, i as X, G as k, J as M, x as W, e as j, W as J, E as D, K as P, v as Y, l as Z, H as z, D as ee, N as ae, Z as te } from "./index-
|
|
3
|
-
import { useRef as se, useEffect as
|
|
2
|
+
import { d as V, a as w, u as S, h as q, $ as G, b as H, X as Q, i as X, G as k, J as M, x as W, e as j, W as J, E as D, K as P, v as Y, l as Z, H as z, D as ee, N as ae, Z as te } from "./index-Dd5zlHOS.js";
|
|
3
|
+
import { useRef as se, useEffect as f, useMemo as R } from "react";
|
|
4
4
|
const F = (a, n, d, l, p, r) => {
|
|
5
5
|
const t = P(a, n, p), s = t.value, i = Y(s);
|
|
6
6
|
let o = s;
|
|
@@ -119,7 +119,7 @@ const F = (a, n, d, l, p, r) => {
|
|
|
119
119
|
enabled: !!e
|
|
120
120
|
}))
|
|
121
121
|
});
|
|
122
|
-
|
|
122
|
+
f(() => {
|
|
123
123
|
o.forEach((e, h) => {
|
|
124
124
|
if (e.isError && !r.current.has(h)) {
|
|
125
125
|
const K = d[h];
|
|
@@ -148,7 +148,7 @@ const F = (a, n, d, l, p, r) => {
|
|
|
148
148
|
) && g();
|
|
149
149
|
},
|
|
150
150
|
[t, g]
|
|
151
|
-
),
|
|
151
|
+
), f(() => {
|
|
152
152
|
T && s({
|
|
153
153
|
title: i("ERROR_DEFAULT_TITLE"),
|
|
154
154
|
message: i("ERROR_FETCHING_OBSERVATIONS"),
|
|
@@ -163,7 +163,7 @@ const F = (a, n, d, l, p, r) => {
|
|
|
163
163
|
{ key: "name", header: "name" },
|
|
164
164
|
{ key: "value", header: "value" },
|
|
165
165
|
{ key: "form", header: "form" }
|
|
166
|
-
],
|
|
166
|
+
], O = A || !v, _ = T && v, C = (!c || c.entry?.length === 0 || m.length === 0) && v, U = _ ? i("ERROR_FETCHING_OBSERVATIONS") : null, x = C ? i("NO_OBSERVATIONS_FOUND") : void 0, B = $.length > 0 && !O && !_, E = n.titleTranslationKey, y = E ? i(E) : "";
|
|
167
167
|
return /* @__PURE__ */ I(
|
|
168
168
|
"div",
|
|
169
169
|
{
|
|
@@ -195,7 +195,7 @@ const F = (a, n, d, l, p, r) => {
|
|
|
195
195
|
headers: L,
|
|
196
196
|
rows: [],
|
|
197
197
|
ariaLabel: i("OBSERVATIONS"),
|
|
198
|
-
loading:
|
|
198
|
+
loading: O,
|
|
199
199
|
errorStateMessage: U,
|
|
200
200
|
emptyStateMessage: x,
|
|
201
201
|
dataTestId: "observations-table"
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { an as we, ao as z, ap as xt, aq as B, al as q, am as y, ar as Ro, as as ye, at as R, au as _, av as k, aw as N, ax as A, ay as bs, az as ir, aA as $e, aB as U, aC as Hn, aD as Vn, aE as dt, aF as D, aG as xs, aH as cn, aI as Be, aJ as ws, aK as qt, aL as zt, aM as $s, aN as Cs, aO as $n, aP as Ss, aQ as Nr, aR as Bt, aS as zo, aT as ks, aU as Es, aV as j, aW as Ur, aX as Ms, aY as Ds, aZ as sr, a_ as As, a$ as Ts, b0 as zn, b1 as Fs, b2 as Is, b3 as Z, b4 as Ps, b5 as Ls } from "./index-Dd5zlHOS.js";
|
|
2
2
|
var Os = (e) => e != null, qs = (e) => e.filter(Os);
|
|
3
3
|
function _s(e) {
|
|
4
4
|
return (...t) => {
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { jsx as n, jsxs as f } from "react/jsx-runtime";
|
|
2
|
-
import { n as V, o as O, u as C, y as h,
|
|
2
|
+
import { n as V, o as O, u as C, y as h, p as P, g as B, a as G, q as x, z as A, b as q, s as U, w, t as F, C as $, L as k, M as Q, O as j, Q as H } from "./index-Dd5zlHOS.js";
|
|
3
3
|
import { useState as I, useMemo as _ } from "react";
|
|
4
4
|
const K = V(
|
|
5
5
|
O,
|
|
6
6
|
"useAppointmentsConfig",
|
|
7
7
|
"AppointmentsConfigProvider"
|
|
8
|
-
),
|
|
8
|
+
), z = ({
|
|
9
9
|
serviceName: e,
|
|
10
10
|
isDeleting: a,
|
|
11
11
|
onConfirm: t,
|
|
@@ -35,7 +35,7 @@ const K = V(
|
|
|
35
35
|
"speciality",
|
|
36
36
|
"durationMins",
|
|
37
37
|
"description"
|
|
38
|
-
],
|
|
38
|
+
], W = "app:appointments:manageServices", Y = "app:appointments:adminTab", J = "_page_10v94_1", X = "_noPrivilegeContainer_10v94_1", Z = "_table_10v94_18", d = {
|
|
39
39
|
page: J,
|
|
40
40
|
noPrivilegeContainer: X,
|
|
41
41
|
table: Z
|
|
@@ -76,26 +76,26 @@ function ae(e, a) {
|
|
|
76
76
|
const re = () => {
|
|
77
77
|
const { t: e } = C(), a = B(), { addNotification: t } = G(), { userPrivileges: s } = x(), { appointmentsConfig: i } = K(), [E, c] = I(null), [v, u] = I(!1), l = i?.serviceTableFields ?? [
|
|
78
78
|
...p
|
|
79
|
-
], S = A(s,
|
|
79
|
+
], S = A(s, Y), M = A(
|
|
80
80
|
s,
|
|
81
|
-
|
|
81
|
+
W
|
|
82
82
|
), m = _(
|
|
83
83
|
() => ee(l),
|
|
84
84
|
[l]
|
|
85
|
-
), { data: L, isLoading: b, isError:
|
|
85
|
+
), { data: L, isLoading: b, isError: R } = q({
|
|
86
86
|
queryKey: ["allAppointmentServices"],
|
|
87
|
-
queryFn:
|
|
87
|
+
queryFn: H,
|
|
88
88
|
enabled: S
|
|
89
|
-
}),
|
|
89
|
+
}), D = _(
|
|
90
90
|
() => te(l, e),
|
|
91
91
|
[l]
|
|
92
|
-
),
|
|
92
|
+
), N = _(
|
|
93
93
|
() => ae(L ?? [], m),
|
|
94
94
|
[L, m]
|
|
95
95
|
), g = async () => {
|
|
96
96
|
u(!0);
|
|
97
97
|
try {
|
|
98
|
-
await
|
|
98
|
+
await j(E.id), t({
|
|
99
99
|
title: e("ADMIN_ALL_SERVICES_DELETE_SUCCESS_TITLE"),
|
|
100
100
|
message: e("ADMIN_ALL_SERVICES_DELETE_SUCCESS_MESSAGE"),
|
|
101
101
|
type: "success",
|
|
@@ -111,7 +111,7 @@ const re = () => {
|
|
|
111
111
|
u(!1);
|
|
112
112
|
}
|
|
113
113
|
}, T = (r, o) => o === "actions" ? /* @__PURE__ */ n(
|
|
114
|
-
|
|
114
|
+
k,
|
|
115
115
|
{
|
|
116
116
|
id: `delete-service-${r.id}-btn`,
|
|
117
117
|
testId: `delete-service-${r.id}-btn-test-id`,
|
|
@@ -120,16 +120,16 @@ const re = () => {
|
|
|
120
120
|
label: e("ADMIN_ALL_SERVICES_DELETE_ICON_LABEL"),
|
|
121
121
|
disabled: !M,
|
|
122
122
|
onClick: () => c(r),
|
|
123
|
-
children: /* @__PURE__ */ n(
|
|
123
|
+
children: /* @__PURE__ */ n(Q, {})
|
|
124
124
|
}
|
|
125
125
|
) : p.includes(o) ? r[o] ?? "-" : r.attributes[o] ?? "-", y = [
|
|
126
126
|
{ id: "home", label: e("BREADCRUMB_HOME"), href: U },
|
|
127
127
|
{ id: "admin", label: e("BREADCRUMB_ADMIN"), isCurrentPage: !0 }
|
|
128
128
|
];
|
|
129
129
|
return /* @__PURE__ */ n(
|
|
130
|
-
|
|
130
|
+
w,
|
|
131
131
|
{
|
|
132
|
-
header: /* @__PURE__ */ n(
|
|
132
|
+
header: /* @__PURE__ */ n($, { breadcrumbItems: y }),
|
|
133
133
|
main: S ? /* @__PURE__ */ f(
|
|
134
134
|
"div",
|
|
135
135
|
{
|
|
@@ -139,22 +139,22 @@ const re = () => {
|
|
|
139
139
|
className: d.page,
|
|
140
140
|
children: [
|
|
141
141
|
/* @__PURE__ */ n(
|
|
142
|
-
|
|
142
|
+
F,
|
|
143
143
|
{
|
|
144
144
|
id: "all-services",
|
|
145
145
|
title: e("ADMIN_ALL_SERVICES_TITLE"),
|
|
146
|
-
headers:
|
|
147
|
-
rows:
|
|
146
|
+
headers: D,
|
|
147
|
+
rows: N,
|
|
148
148
|
ariaLabel: "all-services-table",
|
|
149
149
|
loading: b,
|
|
150
|
-
errorStateMessage:
|
|
150
|
+
errorStateMessage: R ? e("ADMIN_ALL_SERVICES_ERROR_MESSAGE") : null,
|
|
151
151
|
emptyStateMessage: e("ADMIN_ALL_SERVICES_EMPTY_MESSAGE"),
|
|
152
152
|
renderCell: T,
|
|
153
153
|
className: d.table
|
|
154
154
|
}
|
|
155
155
|
),
|
|
156
156
|
E && /* @__PURE__ */ n(
|
|
157
|
-
|
|
157
|
+
z,
|
|
158
158
|
{
|
|
159
159
|
serviceName: E.name,
|
|
160
160
|
isDeleting: v,
|