@uxland/primary-shell 5.6.8 → 5.6.9
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/index.js +6 -5
- package/dist/index.js.map +1 -1
- package/dist/index.umd.cjs +2 -2
- package/dist/index.umd.cjs.map +1 -1
- package/dist/primary/shell/src/features/open-hes-visor/open-hes-visor.d.ts +1 -0
- package/package.json +1 -1
- package/src/UI/internal-views/upper-nav-views.ts +2 -1
- package/src/features/open-hes-visor/open-hes-visor.ts +6 -0
- package/src/internal-plugins/activity-history/activity-history-item/list/merge-history-items-and-subgroups/merge-history-items-and-subgroups.ts +2 -2
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const openHesVisor: () => void;
|
package/package.json
CHANGED
|
@@ -8,6 +8,7 @@ import { QuickActionItem } from "../shared-components/quick-action-item/quick-ac
|
|
|
8
8
|
import { PrimariaNavItem } from "../shared-components/primaria-nav-item/primaria-nav-item";
|
|
9
9
|
import { PrimariaNavTreeMenu } from "../shared-components/primaria-nav-tree-menu/primaria-nav-tree-menu";
|
|
10
10
|
import { GetVisitId } from "../../features/visit/get-visit-id/request";
|
|
11
|
+
import { openHesVisor } from "../../features/open-hes-visor/open-hes-visor";
|
|
11
12
|
|
|
12
13
|
type MenuItemConfig =
|
|
13
14
|
| {
|
|
@@ -218,7 +219,7 @@ const upperNavMenuItems: MenuItemConfig[] = [
|
|
|
218
219
|
label: "Visor",
|
|
219
220
|
type: "item",
|
|
220
221
|
sortHint: "0140",
|
|
221
|
-
callbackFn:
|
|
222
|
+
callbackFn: openHesVisor,
|
|
222
223
|
},
|
|
223
224
|
];
|
|
224
225
|
|
|
@@ -12,7 +12,7 @@ export const mergeHistoryItemsAndSubgroups = (
|
|
|
12
12
|
group: IActivityHistoryGroup,
|
|
13
13
|
): ActivityHistoryEntry[] => {
|
|
14
14
|
// 1. Prepara los items sueltos
|
|
15
|
-
const itemEntries: ActivityHistoryEntry[] = group
|
|
15
|
+
const itemEntries: ActivityHistoryEntry[] = group?.items.map((item) => ({
|
|
16
16
|
type: "item",
|
|
17
17
|
date: new Date(item.date),
|
|
18
18
|
item,
|
|
@@ -21,7 +21,7 @@ export const mergeHistoryItemsAndSubgroups = (
|
|
|
21
21
|
// 2. Prepara los subGroups, usando la fecha del ítem más reciente de cada subgrupo
|
|
22
22
|
const subGroupEntries: ActivityHistoryEntry[] = group.subGroups.map((subGroup) => {
|
|
23
23
|
// Asumimos que subGroup.items ya está ordenado de más reciente a más antiguo
|
|
24
|
-
const mostRecent = subGroup
|
|
24
|
+
const mostRecent = subGroup?.items.length ? new Date(subGroup.items[0].date) : new Date(0);
|
|
25
25
|
return {
|
|
26
26
|
type: "subGroup",
|
|
27
27
|
date: mostRecent,
|