@bahmni/admin-app 0.0.1-dev.443 → 0.0.1-dev.445
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/{AdminDashboard-Bm_9sBiW.js → AdminDashboard-DKVK2iRm.js} +2 -2
- package/dist/{AuditLog-CQLulRo4.js → AuditLog-kHPttZtH.js} +1 -1
- package/dist/{CsvExport-BwEMLFIj.js → CsvExport-DPsugWqm.js} +3 -3
- package/dist/{CsvUpload-dsZIFIhG.js → CsvUpload-DSbbVrTi.js} +1 -1
- package/dist/{DocumentsTable-v6NhgJsj-B-c91aR4.js → DocumentsTable-BX6swgtN-BJtoA-2r.js} +1 -1
- package/dist/{FormsTable-DiD-aWUg-Le560lMJ.js → FormsTable-9ylMl24e-CberXfj1.js} +29 -29
- package/dist/{LNWAZHJI-Cx5TzXrH.js → LNWAZHJI-PY-1Yhvq.js} +2 -2
- package/dist/{MWZ6AO7Z-BtkCNgXL.js → MWZ6AO7Z-Cb-ZcFLH.js} +2 -2
- package/dist/{Observations-B2kwkXq0-D64xFEow.js → Observations-Dci35cGN-siZqjUoD.js} +62 -62
- package/dist/{YPM2AS64-xjQ40sBa.js → YPM2AS64-7x86dV9L.js} +1 -1
- package/dist/{index-JLCGGo7t.js → index-DI87tGQ1.js} +27687 -27687
- package/dist/index.js +1 -1
- package/package.json +1 -1
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import { C as o,
|
|
2
|
+
import { C as o, E as a, F as s, G as N } from "./index-DI87tGQ1.js";
|
|
3
3
|
import "react";
|
|
4
4
|
import "@tanstack/react-query";
|
|
5
5
|
const i = () => /* @__PURE__ */ e(o, { children: /* @__PURE__ */ e(
|
|
6
6
|
a,
|
|
7
7
|
{
|
|
8
|
-
extensionPointId:
|
|
8
|
+
extensionPointId: N,
|
|
9
9
|
appName: s,
|
|
10
10
|
loadingLabelKey: "ADMIN_LOADING_MODULES",
|
|
11
11
|
errorMessageKey: "ADMIN_ERROR_FETCH_CONFIG",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as d, jsxs as S } from "react/jsx-runtime";
|
|
2
|
-
import { _ as ee, a0 as te, a1 as se, a2 as K, u as ae, a3 as ne, a4 as re, C as ie, U as oe, a5 as ue, a6 as de, a7 as U, Y as V, a8 as le } from "./index-
|
|
2
|
+
import { _ as ee, a0 as te, a1 as se, a2 as K, u as ae, a3 as ne, a4 as re, C as ie, U as oe, a5 as ue, a6 as de, a7 as U, Y as V, a8 as le } from "./index-DI87tGQ1.js";
|
|
3
3
|
import { useState as l, useRef as C, useEffect as k, useMemo as ce, useCallback as me } from "react";
|
|
4
4
|
import { useQuery as _e } from "@tanstack/react-query";
|
|
5
5
|
const G = Symbol.for("constructDateFrom");
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as n, jsxs as d } from "react/jsx-runtime";
|
|
2
|
-
import { u as A, z as M,
|
|
2
|
+
import { u as A, z as M, I as R, K as O, N as h, O as P, P as g, C as V, U as f, V as D, Y as x, Z as b } from "./index-DI87tGQ1.js";
|
|
3
3
|
import { useState as E, useMemo as y } from "react";
|
|
4
4
|
import { useQuery as L, useMutation as v } from "@tanstack/react-query";
|
|
5
5
|
const X = "CsvExport-module_tile__yBrLM", U = "CsvExport-module_title__epZnI", B = "CsvExport-module_form__w-cN-", H = "CsvExport-module_search__G82i7", r = {
|
|
@@ -66,7 +66,7 @@ const X = "CsvExport-module_tile__yBrLM", U = "CsvExport-module_title__epZnI", B
|
|
|
66
66
|
}
|
|
67
67
|
};
|
|
68
68
|
return /* @__PURE__ */ n(V, { breadcrumbLabel: t("BREADCRUMB_CSV_EXPORT"), children: /* @__PURE__ */ d(
|
|
69
|
-
|
|
69
|
+
f,
|
|
70
70
|
{
|
|
71
71
|
id: "admin-csv-export-page",
|
|
72
72
|
"data-testid": "admin-csv-export-page-test-id",
|
|
@@ -76,7 +76,7 @@ const X = "CsvExport-module_tile__yBrLM", U = "CsvExport-module_title__epZnI", B
|
|
|
76
76
|
/* @__PURE__ */ n("h2", { className: r.title, children: t("ADMIN_CSV_EXPORT_TITLE") }),
|
|
77
77
|
/* @__PURE__ */ d("form", { className: r.form, onSubmit: N, noValidate: !0, children: [
|
|
78
78
|
/* @__PURE__ */ n("div", { className: r.search, children: /* @__PURE__ */ n(
|
|
79
|
-
|
|
79
|
+
D,
|
|
80
80
|
{
|
|
81
81
|
id: "csv-export-concept-search",
|
|
82
82
|
"data-testid": "csv-export-concept-search-test-id",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as d, jsxs as h, Fragment as x } from "react/jsx-runtime";
|
|
2
|
-
import { d as G, u as J, z as W,
|
|
2
|
+
import { d as G, u as J, z as W, i as Y, J as X, h as Z, $ as ee, a as te } from "./index-DI87tGQ1.js";
|
|
3
3
|
import { useQuery as ae } from "@tanstack/react-query";
|
|
4
4
|
import { useState as l, useCallback as _, useEffect as I, useMemo as p } from "react";
|
|
5
5
|
const ne = "DocumentsTable-module_documentsTableBody__6iR3w", oe = "DocumentsTable-module_viewAttachmentsLink__aQ1on", de = "DocumentsTable-module_documentViewerContainer__F5m8D", re = "DocumentsTable-module_attachmentItem__17KA7", se = "DocumentsTable-module_attachmentCounter__WFiI3", me = "DocumentsTable-module_attachmentError__RI4U2", ce = "DocumentsTable-module_documentIframe__ptq5I", le = "DocumentsTable-module_documentImage__KQVgS", r = {
|
|
@@ -1,28 +1,28 @@
|
|
|
1
1
|
import { jsx as n, jsxs as q, Fragment as ne } from "react/jsx-runtime";
|
|
2
|
-
import { u as ie, d as de,
|
|
3
|
-
import { useQueryClient as
|
|
4
|
-
import { useState as
|
|
5
|
-
const
|
|
6
|
-
formsTableBody:
|
|
2
|
+
import { u as ie, d as de, x as le, k as me, H as ue, b as ce, y as fe, e as ye, w as Te, S as he, D as Ne, R as ge, h as pe, L as V, T as $, J as Oe, $ as x, W as be, q as Ie, a as Ee, c as _e, M as Ae } from "./index-DI87tGQ1.js";
|
|
3
|
+
import { useQueryClient as Le, useQuery as E } from "@tanstack/react-query";
|
|
4
|
+
import { useState as K, useMemo as i, useCallback as d } from "react";
|
|
5
|
+
const Re = "FormsTable-module_formsTableBody__SvGha", Ce = "FormsTable-module_modalHeading__wnTmA", ve = "FormsTable-module_customAccordianItem__isszs", N = {
|
|
6
|
+
formsTableBody: Re,
|
|
7
7
|
modalHeading: Ce,
|
|
8
8
|
customAccordianItem: ve
|
|
9
|
-
}, Be = "startConsultation",
|
|
9
|
+
}, Be = "startConsultation", Ue = ({
|
|
10
10
|
episodeOfCareUuids: _,
|
|
11
11
|
encounterUuids: l,
|
|
12
|
-
config:
|
|
13
|
-
disableActions:
|
|
12
|
+
config: j,
|
|
13
|
+
disableActions: z = !1,
|
|
14
14
|
activeEncounterUuid: y = null
|
|
15
15
|
}) => {
|
|
16
|
-
const { t: o } = ie(), m = de(), [g, A] =
|
|
17
|
-
numberOfVisits:
|
|
16
|
+
const { t: o } = ie(), m = de(), [g, A] = K(!1), [t, L] = K(null), {
|
|
17
|
+
numberOfVisits: Q,
|
|
18
18
|
hideThumbnail: G = !1,
|
|
19
19
|
forms: T
|
|
20
|
-
} =
|
|
20
|
+
} = j ?? {}, J = le(
|
|
21
21
|
Ae.EDIT_OBSERVATIONS
|
|
22
|
-
), { userPrivileges: h } = me(), p = J && !
|
|
22
|
+
), { userPrivileges: h } = me(), p = J && !z && !!y, R = ue(
|
|
23
23
|
_,
|
|
24
24
|
l
|
|
25
|
-
), P =
|
|
25
|
+
), P = Le(), {
|
|
26
26
|
data: C = [],
|
|
27
27
|
isLoading: v,
|
|
28
28
|
isError: B,
|
|
@@ -30,8 +30,8 @@ const Le = "FormsTable-module_formsTableBody__SvGha", Ce = "FormsTable-module_mo
|
|
|
30
30
|
refetch: Y
|
|
31
31
|
} = E({
|
|
32
32
|
queryKey: ["forms", m, _],
|
|
33
|
-
queryFn: () => ce(m, void 0,
|
|
34
|
-
enabled: !!m && !
|
|
33
|
+
queryFn: () => ce(m, void 0, Q),
|
|
34
|
+
enabled: !!m && !R
|
|
35
35
|
}), D = i(() => {
|
|
36
36
|
let e = C;
|
|
37
37
|
return l && l.length > 0 && (e = e.filter(
|
|
@@ -42,7 +42,7 @@ const Le = "FormsTable-module_formsTableBody__SvGha", Ce = "FormsTable-module_mo
|
|
|
42
42
|
}, [C, l, T]), { data: F = [] } = E({
|
|
43
43
|
queryKey: ["observationForms"],
|
|
44
44
|
queryFn: () => fe()
|
|
45
|
-
}),
|
|
45
|
+
}), S = d(
|
|
46
46
|
(e) => {
|
|
47
47
|
const r = F.find(
|
|
48
48
|
(s) => s.name.toLowerCase() === e.toLowerCase()
|
|
@@ -56,8 +56,8 @@ const Le = "FormsTable-module_formsTableBody__SvGha", Ce = "FormsTable-module_mo
|
|
|
56
56
|
},
|
|
57
57
|
[F, h]
|
|
58
58
|
), u = d(
|
|
59
|
-
(e) => !y || e.encounterUuid !== y ? !1 :
|
|
60
|
-
[y,
|
|
59
|
+
(e) => !y || e.encounterUuid !== y ? !1 : S(e.formName),
|
|
60
|
+
[y, S]
|
|
61
61
|
), {
|
|
62
62
|
data: O,
|
|
63
63
|
isLoading: X,
|
|
@@ -83,19 +83,19 @@ const Le = "FormsTable-module_formsTableBody__SvGha", Ce = "FormsTable-module_mo
|
|
|
83
83
|
{ key: "recordedBy", header: o("RECORDED_BY") }
|
|
84
84
|
],
|
|
85
85
|
[o]
|
|
86
|
-
),
|
|
86
|
+
), M = i(
|
|
87
87
|
() => [...c, { key: "actions", header: o("ACTIONS") }],
|
|
88
88
|
[c, o]
|
|
89
89
|
), ae = d(
|
|
90
|
-
(e) => p && e.some((r) => u(r)) ?
|
|
91
|
-
[p, u,
|
|
90
|
+
(e) => p && e.some((r) => u(r)) ? M : c,
|
|
91
|
+
[p, u, M, c]
|
|
92
92
|
), oe = c, te = i(
|
|
93
93
|
() => [
|
|
94
94
|
{ key: "recordedOn", sortable: !0 },
|
|
95
95
|
{ key: "recordedBy", sortable: !0 }
|
|
96
96
|
],
|
|
97
97
|
[]
|
|
98
|
-
),
|
|
98
|
+
), U = i(() => {
|
|
99
99
|
const e = D.reduce(
|
|
100
100
|
(r, a) => {
|
|
101
101
|
const s = a.formName;
|
|
@@ -121,9 +121,9 @@ const Le = "FormsTable-module_formsTableBody__SvGha", Ce = "FormsTable-module_mo
|
|
|
121
121
|
})
|
|
122
122
|
).sort((r, a) => r.formName.localeCompare(a.formName));
|
|
123
123
|
}, [D, o]), k = d((e) => {
|
|
124
|
-
|
|
124
|
+
L(e), A(!0);
|
|
125
125
|
}, []), w = d(() => {
|
|
126
|
-
A(!1),
|
|
126
|
+
A(!1), L(null);
|
|
127
127
|
}, []), I = d((e) => {
|
|
128
128
|
globalThis.dispatchEvent(
|
|
129
129
|
new CustomEvent(Be, {
|
|
@@ -162,8 +162,8 @@ const Le = "FormsTable-module_formsTableBody__SvGha", Ce = "FormsTable-module_mo
|
|
|
162
162
|
[k, I, u, o]
|
|
163
163
|
);
|
|
164
164
|
return /* @__PURE__ */ q(ne, { children: [
|
|
165
|
-
/* @__PURE__ */ n("div", { id: "forms-table", "data-testid": "forms-table", children: v || B ||
|
|
166
|
-
|
|
165
|
+
/* @__PURE__ */ n("div", { id: "forms-table", "data-testid": "forms-table", children: v || B || U.length === 0 || R ? /* @__PURE__ */ n(
|
|
166
|
+
x,
|
|
167
167
|
{
|
|
168
168
|
headers: oe,
|
|
169
169
|
ariaLabel: o("FORMS_HEADING"),
|
|
@@ -175,7 +175,7 @@ const Le = "FormsTable-module_formsTableBody__SvGha", Ce = "FormsTable-module_mo
|
|
|
175
175
|
className: N.formsTableBody,
|
|
176
176
|
dataTestId: "forms-table"
|
|
177
177
|
}
|
|
178
|
-
) : /* @__PURE__ */ n(be, { align: "start", children:
|
|
178
|
+
) : /* @__PURE__ */ n(be, { align: "start", children: U.map((e, r) => {
|
|
179
179
|
const { formName: a, records: s } = e, f = ae(s);
|
|
180
180
|
return /* @__PURE__ */ n(
|
|
181
181
|
Ie,
|
|
@@ -185,7 +185,7 @@ const Le = "FormsTable-module_formsTableBody__SvGha", Ce = "FormsTable-module_mo
|
|
|
185
185
|
testId: `accordian-title-${a}`,
|
|
186
186
|
open: r === 0,
|
|
187
187
|
children: /* @__PURE__ */ n(
|
|
188
|
-
|
|
188
|
+
x,
|
|
189
189
|
{
|
|
190
190
|
headers: f,
|
|
191
191
|
ariaLabel: o("FORMS_HEADING"),
|
|
@@ -248,5 +248,5 @@ const Le = "FormsTable-module_formsTableBody__SvGha", Ce = "FormsTable-module_mo
|
|
|
248
248
|
] });
|
|
249
249
|
};
|
|
250
250
|
export {
|
|
251
|
-
|
|
251
|
+
Ue as default
|
|
252
252
|
};
|
|
@@ -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 { a9 as d, aa as f, ab as e } from "./index-
|
|
1
|
+
import { c, T as l, P as m, a as u, D as v, Q as i } from "./YPM2AS64-7x86dV9L.js";
|
|
2
|
+
import { a9 as d, aa as f, ab as e } from "./index-DI87tGQ1.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 { a9 as v, aa as C, ab as e } from "./index-
|
|
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-7x86dV9L.js";
|
|
2
|
+
import { a9 as v, aa as C, ab as e } from "./index-DI87tGQ1.js";
|
|
3
3
|
var h = (t) => {
|
|
4
4
|
const [r, o] = s({
|
|
5
5
|
prefix: "TanstackQueryDevtools"
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { jsxs as S, jsx as n } from "react/jsx-runtime";
|
|
2
|
-
import { d as H, z as
|
|
2
|
+
import { d as H, z as M, u as V, r as j, H as x, o as G, n as X, w as J, f as P, g as Y, m as Z, j as W, l as ee, $ as ae, p as se, s as B, t as re, v as te, h as ie, A as oe, X as ne, B as de, Q as le } from "./index-DI87tGQ1.js";
|
|
3
3
|
import { useQueries as ue, useQuery as ce } from "@tanstack/react-query";
|
|
4
|
-
import { useRef as pe, useEffect as L, useMemo as
|
|
5
|
-
const me = "Observations-module_observations__RKSyo", be = "Observations-module_title__TJL3z", he = "Observations-module_wrapper__muk2L", ve = "Observations-module_secondary__14nuS",
|
|
4
|
+
import { useRef as pe, useEffect as L, useMemo as E } from "react";
|
|
5
|
+
const me = "Observations-module_observations__RKSyo", be = "Observations-module_title__TJL3z", he = "Observations-module_wrapper__muk2L", ve = "Observations-module_secondary__14nuS", f = {
|
|
6
6
|
observations: me,
|
|
7
7
|
title: be,
|
|
8
8
|
wrapper: he,
|
|
9
9
|
secondary: ve
|
|
10
|
-
}, w = (s, l, o, d, c,
|
|
11
|
-
const
|
|
10
|
+
}, w = (s, l, o, d, c, r) => {
|
|
11
|
+
const t = re(s, l, c), e = t.value, p = te(e);
|
|
12
12
|
let i = e;
|
|
13
13
|
p === "Image" && (i = /* @__PURE__ */ n(
|
|
14
14
|
ne,
|
|
@@ -16,38 +16,38 @@ const me = "Observations-module_observations__RKSyo", be = "Observations-module_
|
|
|
16
16
|
imageSrc: e,
|
|
17
17
|
alt: e,
|
|
18
18
|
id: `${e}-img`,
|
|
19
|
-
hideThumbnail:
|
|
19
|
+
hideThumbnail: r
|
|
20
20
|
}
|
|
21
21
|
)), p === "Video" && (i = /* @__PURE__ */ n(
|
|
22
22
|
de,
|
|
23
23
|
{
|
|
24
24
|
id: `${e}-video`,
|
|
25
25
|
videoSrc: e,
|
|
26
|
-
hideThumbnail:
|
|
26
|
+
hideThumbnail: r
|
|
27
27
|
}
|
|
28
28
|
)), p === "PDF" && (i = /* @__PURE__ */ n(le, { id: `${e}-pdf`, src: e }));
|
|
29
|
-
const m = /* @__PURE__ */ S("div", { className:
|
|
30
|
-
/* @__PURE__ */ n("span", { children:
|
|
31
|
-
|
|
29
|
+
const m = /* @__PURE__ */ S("div", { className: f.wrapper, children: [
|
|
30
|
+
/* @__PURE__ */ n("span", { children: t.header.display }),
|
|
31
|
+
t.header.referenceRange && /* @__PURE__ */ n("span", { className: f.secondary, children: t.header.referenceRange })
|
|
32
32
|
] }), u = c("OBSERVATIONS_RECORDED_BY", {
|
|
33
|
-
provider:
|
|
34
|
-
}), b = s.effectiveDateTime ? ie(s.effectiveDateTime, c, !0).formattedResult : void 0,
|
|
33
|
+
provider: t.provider
|
|
34
|
+
}), b = s.effectiveDateTime ? ie(s.effectiveDateTime, c, !0).formattedResult : void 0, g = /* @__PURE__ */ S("div", { className: f.wrapper, children: [
|
|
35
35
|
/* @__PURE__ */ n("span", { children: u }),
|
|
36
|
-
b && /* @__PURE__ */ n("span", { className:
|
|
37
|
-
] }), h = s.display, v = s.observationValue?.isAbnormal ? "abnormal-obs" : "obs",
|
|
36
|
+
b && /* @__PURE__ */ n("span", { className: f.secondary, children: b })
|
|
37
|
+
] }), h = s.display, v = s.observationValue?.isAbnormal ? "abnormal-obs" : "obs", O = d ? `${d}-${v}-${h}-${o}-${l}` : `${v}-${h}-${o}-${l}`;
|
|
38
38
|
return /* @__PURE__ */ n(
|
|
39
39
|
oe,
|
|
40
40
|
{
|
|
41
41
|
header: m,
|
|
42
42
|
value: i,
|
|
43
|
-
info:
|
|
44
|
-
id:
|
|
45
|
-
testId:
|
|
46
|
-
ariaLabel:
|
|
43
|
+
info: g,
|
|
44
|
+
id: O,
|
|
45
|
+
testId: O,
|
|
46
|
+
ariaLabel: O
|
|
47
47
|
},
|
|
48
48
|
`obs-${s.id}`
|
|
49
49
|
);
|
|
50
|
-
}, ye = (s, l, o, d, c,
|
|
50
|
+
}, ye = (s, l, o, d, c, r, t) => /* @__PURE__ */ n(
|
|
51
51
|
B,
|
|
52
52
|
{
|
|
53
53
|
title: s.display,
|
|
@@ -58,28 +58,28 @@ const me = "Observations-module_observations__RKSyo", be = "Observations-module_
|
|
|
58
58
|
e,
|
|
59
59
|
p,
|
|
60
60
|
c,
|
|
61
|
-
|
|
61
|
+
r,
|
|
62
62
|
l,
|
|
63
|
-
|
|
63
|
+
t
|
|
64
64
|
)
|
|
65
65
|
)
|
|
66
66
|
},
|
|
67
67
|
`grouped-obs-${s.id}`
|
|
68
|
-
),
|
|
68
|
+
), fe = ({
|
|
69
69
|
groupedData: s,
|
|
70
70
|
title: l = "",
|
|
71
71
|
hideThumbnail: o
|
|
72
72
|
}) => {
|
|
73
|
-
const { t: d } = V(), c = (
|
|
74
|
-
const p = se(
|
|
73
|
+
const { t: d } = V(), c = (r, t, e) => {
|
|
74
|
+
const p = se(r.encounterDetails, d);
|
|
75
75
|
return /* @__PURE__ */ S(
|
|
76
76
|
B,
|
|
77
77
|
{
|
|
78
78
|
title: p,
|
|
79
|
-
id: `encounter-${
|
|
80
|
-
open:
|
|
79
|
+
id: `encounter-${r.encounterId}`,
|
|
80
|
+
open: t,
|
|
81
81
|
children: [
|
|
82
|
-
|
|
82
|
+
r.observations.map(
|
|
83
83
|
(i, m) => w(
|
|
84
84
|
i,
|
|
85
85
|
m,
|
|
@@ -89,11 +89,11 @@ const me = "Observations-module_observations__RKSyo", be = "Observations-module_
|
|
|
89
89
|
o
|
|
90
90
|
)
|
|
91
91
|
),
|
|
92
|
-
|
|
92
|
+
r.groupedObservations.map(
|
|
93
93
|
(i, m) => ye(
|
|
94
94
|
i,
|
|
95
95
|
d,
|
|
96
|
-
|
|
96
|
+
t,
|
|
97
97
|
m,
|
|
98
98
|
e,
|
|
99
99
|
l,
|
|
@@ -102,7 +102,7 @@ const me = "Observations-module_observations__RKSyo", be = "Observations-module_
|
|
|
102
102
|
)
|
|
103
103
|
]
|
|
104
104
|
},
|
|
105
|
-
`encounter-${
|
|
105
|
+
`encounter-${r.encounterId}`
|
|
106
106
|
);
|
|
107
107
|
};
|
|
108
108
|
return /* @__PURE__ */ n(
|
|
@@ -112,11 +112,11 @@ const me = "Observations-module_observations__RKSyo", be = "Observations-module_
|
|
|
112
112
|
"data-testid": "obs-by-encounter-test-id",
|
|
113
113
|
"aria-label": "obs-by-encounter-aria-label",
|
|
114
114
|
children: s.map(
|
|
115
|
-
(
|
|
115
|
+
(r, t) => c(r, t === 0, t)
|
|
116
116
|
)
|
|
117
117
|
}
|
|
118
118
|
);
|
|
119
|
-
},
|
|
119
|
+
}, Oe = (s) => ["conceptUuid", s], Re = (s, l, o, d) => [
|
|
120
120
|
"observations",
|
|
121
121
|
s,
|
|
122
122
|
...l,
|
|
@@ -129,13 +129,13 @@ const me = "Observations-module_observations__RKSyo", be = "Observations-module_
|
|
|
129
129
|
}) => {
|
|
130
130
|
const d = s, {
|
|
131
131
|
conceptNames: c = [],
|
|
132
|
-
conceptUuid:
|
|
133
|
-
hideThumbnail:
|
|
132
|
+
conceptUuid: r = [],
|
|
133
|
+
hideThumbnail: t = !1,
|
|
134
134
|
scope: e = "all"
|
|
135
|
-
} = d, p = pe(/* @__PURE__ */ new Set()), i = H(), { addNotification: m } =
|
|
135
|
+
} = d, p = pe(/* @__PURE__ */ new Set()), i = H(), { addNotification: m } = M(), { t: u } = V(), b = ue({
|
|
136
136
|
queries: c.map((a) => ({
|
|
137
|
-
queryKey:
|
|
138
|
-
queryFn: () =>
|
|
137
|
+
queryKey: Oe(a),
|
|
138
|
+
queryFn: () => j(a),
|
|
139
139
|
enabled: !!a
|
|
140
140
|
}))
|
|
141
141
|
});
|
|
@@ -147,14 +147,14 @@ const me = "Observations-module_observations__RKSyo", be = "Observations-module_
|
|
|
147
147
|
type: "error"
|
|
148
148
|
}), p.current.add(0)) : !a && y && p.current.clear();
|
|
149
149
|
}, [b, m, u]);
|
|
150
|
-
const
|
|
150
|
+
const g = E(() => b.map((a) => a.data?.uuid).filter((a) => !!a), [b]), h = E(() => [.../* @__PURE__ */ new Set([...g, ...r])], [g, r]), v = E(() => c.length === 0 ? !0 : b.every((a) => !a.isLoading), [b, c.length]), O = e === "latest" || e === "latest-encounter", F = x(
|
|
151
151
|
l,
|
|
152
152
|
o
|
|
153
153
|
), {
|
|
154
154
|
data: R,
|
|
155
155
|
isLoading: U,
|
|
156
|
-
isError:
|
|
157
|
-
refetch:
|
|
156
|
+
isError: $,
|
|
157
|
+
refetch: I
|
|
158
158
|
} = ce({
|
|
159
159
|
queryKey: Re(
|
|
160
160
|
i,
|
|
@@ -162,66 +162,66 @@ const me = "Observations-module_observations__RKSyo", be = "Observations-module_
|
|
|
162
162
|
o,
|
|
163
163
|
e
|
|
164
164
|
),
|
|
165
|
-
queryFn: () =>
|
|
165
|
+
queryFn: () => O ? G(
|
|
166
166
|
i,
|
|
167
167
|
h,
|
|
168
168
|
o
|
|
169
|
-
) :
|
|
169
|
+
) : X(
|
|
170
170
|
i,
|
|
171
171
|
h,
|
|
172
172
|
o
|
|
173
173
|
),
|
|
174
174
|
enabled: !!i && h.length > 0 && v && !F
|
|
175
175
|
});
|
|
176
|
-
|
|
176
|
+
J(
|
|
177
177
|
(a) => {
|
|
178
178
|
a.patientUUID === i && a.updatedConcepts.size > 0 && [...a.updatedConcepts.keys()].some(
|
|
179
179
|
(y) => h.includes(y)
|
|
180
|
-
) &&
|
|
180
|
+
) && I();
|
|
181
181
|
},
|
|
182
|
-
[i,
|
|
182
|
+
[i, I]
|
|
183
183
|
), L(() => {
|
|
184
|
-
|
|
184
|
+
$ && m({
|
|
185
185
|
title: u("ERROR_DEFAULT_TITLE"),
|
|
186
186
|
message: u("ERROR_FETCHING_OBSERVATIONS"),
|
|
187
187
|
type: "error"
|
|
188
188
|
});
|
|
189
|
-
}, [
|
|
190
|
-
const
|
|
189
|
+
}, [$]);
|
|
190
|
+
const N = E(() => {
|
|
191
191
|
if (!R) return [];
|
|
192
192
|
let a = P(R);
|
|
193
193
|
e === "latest-encounter" && (a = Y(a));
|
|
194
|
-
const y =
|
|
195
|
-
return
|
|
194
|
+
const y = Z(a);
|
|
195
|
+
return W(y);
|
|
196
196
|
}, [R, e]), C = [
|
|
197
197
|
{ key: "name", header: "name" },
|
|
198
198
|
{ key: "value", header: "value" },
|
|
199
199
|
{ key: "form", header: "form" }
|
|
200
|
-
], A = U || !v, D =
|
|
200
|
+
], A = U || !v, D = $ && v, K = (!R || R.entry?.length === 0 || h.length === 0) && v, Q = D ? u("ERROR_FETCHING_OBSERVATIONS") : null, k = K ? u("NO_OBSERVATIONS_FOUND") : void 0, q = N.length > 0 && !A && !D, T = d.titleTranslationKey, _ = T ? u(T) : "";
|
|
201
201
|
return /* @__PURE__ */ S(
|
|
202
202
|
"div",
|
|
203
203
|
{
|
|
204
204
|
id: "observations",
|
|
205
|
-
"data-testid":
|
|
205
|
+
"data-testid": T ? `observations-${_}` : "observations",
|
|
206
206
|
"aria-label": "observations-aria-label",
|
|
207
|
-
className:
|
|
207
|
+
className: f.observations,
|
|
208
208
|
children: [
|
|
209
209
|
/* @__PURE__ */ n(
|
|
210
210
|
ee,
|
|
211
211
|
{
|
|
212
212
|
id: "observations-title",
|
|
213
|
-
testId:
|
|
213
|
+
testId: T ? `observations-title-${_}` : "observations-title",
|
|
214
214
|
title: _,
|
|
215
|
-
className:
|
|
215
|
+
className: f.title,
|
|
216
216
|
children: /* @__PURE__ */ n("p", { children: _ })
|
|
217
217
|
}
|
|
218
218
|
),
|
|
219
|
-
|
|
220
|
-
|
|
219
|
+
q ? /* @__PURE__ */ n(
|
|
220
|
+
fe,
|
|
221
221
|
{
|
|
222
|
-
groupedData:
|
|
222
|
+
groupedData: N,
|
|
223
223
|
title: _,
|
|
224
|
-
hideThumbnail:
|
|
224
|
+
hideThumbnail: t
|
|
225
225
|
}
|
|
226
226
|
) : /* @__PURE__ */ n(
|
|
227
227
|
ae,
|
|
@@ -230,8 +230,8 @@ const me = "Observations-module_observations__RKSyo", be = "Observations-module_
|
|
|
230
230
|
rows: [],
|
|
231
231
|
ariaLabel: u("OBSERVATIONS"),
|
|
232
232
|
loading: A,
|
|
233
|
-
errorStateMessage:
|
|
234
|
-
emptyStateMessage:
|
|
233
|
+
errorStateMessage: Q,
|
|
234
|
+
emptyStateMessage: k ?? u("NO_OBSERVATIONS_AVAILABLE"),
|
|
235
235
|
dataTestId: "observations-table"
|
|
236
236
|
}
|
|
237
237
|
)
|
|
@@ -240,7 +240,7 @@ const me = "Observations-module_observations__RKSyo", be = "Observations-module_
|
|
|
240
240
|
);
|
|
241
241
|
};
|
|
242
242
|
export {
|
|
243
|
-
|
|
243
|
+
Oe as conceptUuidQueryKeys,
|
|
244
244
|
Se as default,
|
|
245
245
|
Re as observationsQueryKeys
|
|
246
246
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ac as we, ad as z, ae as xt, af as B, aa as q, ab as y, ag as Ro, ah as ye, ai as R, aj as _, ak as k, al as N, am as A, an as bs, ao as ir, ap as $e, aq as U, ar as Hn, as as Vn, at as dt, au as D, av as xs, aw as cn, ax as Be, ay as ws, az as qt, aA as zt, aB as $s, aC as Cs, aD as $n, aE as Ss, aF as Nr, aG as Bt, aH as zo, aI as ks, aJ as Es, aK as j, aL as Ur, aM as Ms, aN as Ds, aO as sr, aP as As, aQ as Ts, aR as zn, aS as Fs, aT as Is, aU as Z, aV as Ps, aW as Ls } from "./index-
|
|
1
|
+
import { ac as we, ad as z, ae as xt, af as B, aa as q, ab as y, ag as Ro, ah as ye, ai as R, aj as _, ak as k, al as N, am as A, an as bs, ao as ir, ap as $e, aq as U, ar as Hn, as as Vn, at as dt, au as D, av as xs, aw as cn, ax as Be, ay as ws, az as qt, aA as zt, aB as $s, aC as Cs, aD as $n, aE as Ss, aF as Nr, aG as Bt, aH as zo, aI as ks, aJ as Es, aK as j, aL as Ur, aM as Ms, aN as Ds, aO as sr, aP as As, aQ as Ts, aR as zn, aS as Fs, aT as Is, aU as Z, aV as Ps, aW as Ls } from "./index-DI87tGQ1.js";
|
|
2
2
|
var Os = (e) => e != null, qs = (e) => e.filter(Os);
|
|
3
3
|
function _s(e) {
|
|
4
4
|
return (...t) => {
|